org.opennms.netmgt.config.microblog
Class MicroblogConfiguration

java.lang.Object
  extended by org.opennms.netmgt.config.microblog.MicroblogConfiguration
All Implemented Interfaces:
Serializable

public class MicroblogConfiguration
extends Object
implements Serializable

Microblog configuration groups

Version:
$Revision$ $Date$
See Also:
Serialized Form

Constructor Summary
MicroblogConfiguration()
           
 
Method Summary
 void addMicroblogProfile(int index, MicroblogProfile vMicroblogProfile)
           
 void addMicroblogProfile(MicroblogProfile vMicroblogProfile)
           
 Enumeration<MicroblogProfile> enumerateMicroblogProfile()
          Method enumerateMicroblogProfile.
 boolean equals(Object obj)
          Overrides the java.lang.Object.equals method.
 String getDefaultMicroblogProfileName()
          Returns the value of field 'defaultMicroblogProfileName'.
 MicroblogProfile[] getMicroblogProfile()
          Method getMicroblogProfile.Returns the contents of the collection in an Array.
 MicroblogProfile getMicroblogProfile(int index)
          Method getMicroblogProfile.
 List<MicroblogProfile> getMicroblogProfileCollection()
          Method getMicroblogProfileCollection.Returns a reference to '_microblogProfileList'.
 int getMicroblogProfileCount()
          Method getMicroblogProfileCount.
 int hashCode()
          Overrides the java.lang.Object.hashCode method.
 boolean isValid()
          Method isValid.
 Iterator<MicroblogProfile> iterateMicroblogProfile()
          Method iterateMicroblogProfile.
 void marshal(ContentHandler handler)
           
 void marshal(Writer out)
           
 void removeAllMicroblogProfile()
           
 boolean removeMicroblogProfile(MicroblogProfile vMicroblogProfile)
          Method removeMicroblogProfile.
 MicroblogProfile removeMicroblogProfileAt(int index)
          Method removeMicroblogProfileAt.
 void setDefaultMicroblogProfileName(String defaultMicroblogProfileName)
          Sets the value of field 'defaultMicroblogProfileName'.
 void setMicroblogProfile(int index, MicroblogProfile vMicroblogProfile)
           
 void setMicroblogProfile(List<MicroblogProfile> vMicroblogProfileList)
          Sets the value of '_microblogProfileList' by copying the given Vector.
 void setMicroblogProfile(MicroblogProfile[] vMicroblogProfileArray)
           
 void setMicroblogProfileCollection(List<MicroblogProfile> microblogProfileList)
          Deprecated.  
static MicroblogConfiguration unmarshal(Reader reader)
          Method unmarshal.
 void validate()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MicroblogConfiguration

public MicroblogConfiguration()
Method Detail

addMicroblogProfile

public void addMicroblogProfile(MicroblogProfile vMicroblogProfile)
                         throws IndexOutOfBoundsException
Parameters:
vMicroblogProfile -
Throws:
IndexOutOfBoundsException - if the index given is outside the bounds of the collection

addMicroblogProfile

public void addMicroblogProfile(int index,
                                MicroblogProfile vMicroblogProfile)
                         throws IndexOutOfBoundsException
Parameters:
index -
vMicroblogProfile -
Throws:
IndexOutOfBoundsException - if the index given is outside the bounds of the collection

enumerateMicroblogProfile

public Enumeration<MicroblogProfile> enumerateMicroblogProfile()
Method enumerateMicroblogProfile.

Returns:
an Enumeration over all possible elements of this collection

equals

public boolean equals(Object obj)
Overrides the java.lang.Object.equals method.

Overrides:
equals in class Object
Parameters:
obj -
Returns:
true if the objects are equal.

getDefaultMicroblogProfileName

public String getDefaultMicroblogProfileName()
Returns the value of field 'defaultMicroblogProfileName'.

Returns:
the value of field 'DefaultMicroblogProfileName'.

getMicroblogProfile

public MicroblogProfile getMicroblogProfile(int index)
                                     throws IndexOutOfBoundsException
Method getMicroblogProfile.

Parameters:
index -
Returns:
the value of the org.opennms.netmgt.config.microblog.MicroblogProfile at the given index
Throws:
IndexOutOfBoundsException - if the index given is outside the bounds of the collection

getMicroblogProfile

public MicroblogProfile[] getMicroblogProfile()
Method getMicroblogProfile.Returns the contents of the collection in an Array.

Note: Just in case the collection contents are changing in another thread, we pass a 0-length Array of the correct type into the API call. This way we know that the Array returned is of exactly the correct length.

Returns:
this collection as an Array

getMicroblogProfileCollection

public List<MicroblogProfile> getMicroblogProfileCollection()
Method getMicroblogProfileCollection.Returns a reference to '_microblogProfileList'. No type checking is performed on any modifications to the Vector.

Returns:
a reference to the Vector backing this class

getMicroblogProfileCount

public int getMicroblogProfileCount()
Method getMicroblogProfileCount.

Returns:
the size of this collection

hashCode

public int hashCode()
Overrides the java.lang.Object.hashCode method.

The following steps came from Effective Java Programming Language Guide by Joshua Bloch, Chapter 3

Overrides:
hashCode in class Object
Returns:
a hash code value for the object.

isValid

public boolean isValid()
Method isValid.

Returns:
true if this object is valid according to the schema

iterateMicroblogProfile

public Iterator<MicroblogProfile> iterateMicroblogProfile()
Method iterateMicroblogProfile.

Returns:
an Iterator over all possible elements in this collection

marshal

public void marshal(Writer out)
             throws org.exolab.castor.xml.MarshalException,
                    org.exolab.castor.xml.ValidationException
Parameters:
out -
Throws:
org.exolab.castor.xml.MarshalException - if object is null or if any SAXException is thrown during marshaling
org.exolab.castor.xml.ValidationException - if this object is an invalid instance according to the schema

marshal

public void marshal(ContentHandler handler)
             throws IOException,
                    org.exolab.castor.xml.MarshalException,
                    org.exolab.castor.xml.ValidationException
Parameters:
handler -
Throws:
IOException - if an IOException occurs during marshaling
org.exolab.castor.xml.ValidationException - if this object is an invalid instance according to the schema
org.exolab.castor.xml.MarshalException - if object is null or if any SAXException is thrown during marshaling

removeAllMicroblogProfile

public void removeAllMicroblogProfile()

removeMicroblogProfile

public boolean removeMicroblogProfile(MicroblogProfile vMicroblogProfile)
Method removeMicroblogProfile.

Parameters:
vMicroblogProfile -
Returns:
true if the object was removed from the collection.

removeMicroblogProfileAt

public MicroblogProfile removeMicroblogProfileAt(int index)
Method removeMicroblogProfileAt.

Parameters:
index -
Returns:
the element removed from the collection

setDefaultMicroblogProfileName

public void setDefaultMicroblogProfileName(String defaultMicroblogProfileName)
Sets the value of field 'defaultMicroblogProfileName'.

Parameters:
defaultMicroblogProfileName - the value of field 'defaultMicroblogProfileName'.

setMicroblogProfile

public void setMicroblogProfile(int index,
                                MicroblogProfile vMicroblogProfile)
                         throws IndexOutOfBoundsException
Parameters:
index -
vMicroblogProfile -
Throws:
IndexOutOfBoundsException - if the index given is outside the bounds of the collection

setMicroblogProfile

public void setMicroblogProfile(MicroblogProfile[] vMicroblogProfileArray)
Parameters:
vMicroblogProfileArray -

setMicroblogProfile

public void setMicroblogProfile(List<MicroblogProfile> vMicroblogProfileList)
Sets the value of '_microblogProfileList' by copying the given Vector. All elements will be checked for type safety.

Parameters:
vMicroblogProfileList - the Vector to copy.

setMicroblogProfileCollection

public void setMicroblogProfileCollection(List<MicroblogProfile> microblogProfileList)
Deprecated. 

Sets the value of '_microblogProfileList' by setting it to the given Vector. No type checking is performed.

Parameters:
microblogProfileList - the Vector to set.

unmarshal

public static MicroblogConfiguration unmarshal(Reader reader)
                                        throws org.exolab.castor.xml.MarshalException,
                                               org.exolab.castor.xml.ValidationException
Method unmarshal.

Parameters:
reader -
Returns:
the unmarshaled org.opennms.netmgt.config.microblog.MicroblogConfiguration
Throws:
org.exolab.castor.xml.MarshalException - if object is null or if any SAXException is thrown during marshaling
org.exolab.castor.xml.ValidationException - if this object is an invalid instance according to the schema

validate

public void validate()
              throws org.exolab.castor.xml.ValidationException
Throws:
org.exolab.castor.xml.ValidationException - if this object is an invalid instance according to the schema


Copyright © 2011. All Rights Reserved.