Package tigase.conf

Class ConfiguratorOld

All Implemented Interfaces:
ClusteredComponentIfc, Configurable, RepositoryChangeListenerIfc<ConfigItem>, XMPPService, ConfigurationChangedAware, Initializable, ComponentRegistrator, ServerComponent, StatisticsContainer, StatisticsContainerIfc, VHostListener

public class ConfiguratorOld extends ConfiguratorAbstract
Class ConfiguratorOld
Created: Tue Nov 22 07:07:11 2005
Author:
Artur Hefczyc
  • Constructor Details

    • ConfiguratorOld

      public ConfiguratorOld()
  • Method Details

    • getMXBean

      public static Object getMXBean(String objName)
    • main

      public static void main(String[] args) throws Exception
      Throws:
      Exception
    • putMXBean

      public static void putMXBean(String objName, Object bean)
    • componentAdded

      public void componentAdded(Configurable component) throws ConfigurationException
      Description copied from class: AbstractComponentRegistrator
      Method provides a callback mechanism signaling that a new component implementing special interface has been added to the internal components collection.
      Overrides:
      componentAdded in class ConfiguratorAbstract
      Parameters:
      component - is a reference to the component just added to the collection.
      Throws:
      ConfigurationException
    • init

      public void init(String[] args) throws ConfigurationException
      Overrides:
      init in class ConfiguratorAbstract
      Throws:
      ConfigurationException
    • initializationCompleted

      public void initializationCompleted()
      Description copied from interface: ServerComponent
      Method is called by MessageRouter when all the startup components of the server have been loaded and configured through setProperties(...) call. At this point the whole server should be loaded and functional, except initializations taking place in this routine.
      Specified by:
      initializationCompleted in interface ServerComponent
      Overrides:
      initializationCompleted in class ConfiguratorAbstract
    • parseArgs

      public void parseArgs(String[] args)
      Overrides:
      parseArgs in class ConfiguratorAbstract
    • processPacket

      public void processPacket(Packet packet, Queue<Packet> results)
      Description copied from interface: ServerComponent
      processPacket is a blocking processing method implemented by all components. This method processes packet and returns results instantly without waiting for any resources.
      Specified by:
      processPacket in interface ServerComponent
      Overrides:
      processPacket in class BasicComponent
      Parameters:
      packet - a Packet value
    • setup

      public void setup(String name) throws ConfigurationException
      Throws:
      ConfigurationException
    • getAllProperties

      public Map<String,Object> getAllProperties(String key) throws ConfigurationException
      Throws:
      ConfigurationException
    • getComponents

      public String[] getComponents()
    • getDefaults

      public Map<String,Object> getDefaults(Map<String,Object> params)
      Description copied from interface: Configurable
      Returns default configuration settings for the component as a Map with keys as configuration property IDs and values as the configuration property values. All the default parameters returned from this method are later passed to the setProperties(...) method. Some of them may have changed value if they have been overwritten in the server configuration. The configuration property value can be of any of the basic types: int, long, boolean, String.
      Specified by:
      getDefaults in interface Configurable
      Overrides:
      getDefaults in class ConfiguratorAbstract
      Parameters:
      params - is a Map with some initial properties set for the starting up server. These parameters can be used as a hints to generate component's default configuration.
      Returns:
      a Map with the component default configuration.
    • getDefConfigParams

      public Map<String,Object> getDefConfigParams()
      Overrides:
      getDefConfigParams in class ConfiguratorAbstract
    • getDiscoFeatures

      public List<Element> getDiscoFeatures(JID from)
      Description copied from class: BasicComponent
      Method returns list of features provided by this component for provided JID.
      Specified by:
      getDiscoFeatures in interface XMPPService
      Overrides:
      getDiscoFeatures in class BasicComponent
      Parameters:
      from - a request sender address. Some service disco elements are meant to be available only to system administrarors. The component is responsible to check whether the sender is the component administrator and return results appropriate.
      Returns:
      list of features
    • getDiscoInfo

      public Element getDiscoInfo(String node, JID jid, JID from)
      Description copied from interface: XMPPService
      Returns service discovery info for the component. If the jid is null then this is info for the top level request. SM may return disco info on the top level. Other components should not.
      Specified by:
      getDiscoInfo in interface XMPPService
      Overrides:
      getDiscoInfo in class BasicComponent
      Parameters:
      node - is service discovery node for which the request is made. Is normally null for the component top level request.
      jid - is the jid to which the request has been made.
      from - is the request sender address. Some service discovery information is only meant for administrators.
      Returns:
      returns an XML Element with service discovery data.
    • getDiscoItems

      public List<Element> getDiscoItems(String node, JID jid, JID from)
      Description copied from interface: XMPPService
      Returns service discovery items for the component. If the JID is null then this is request for the top level request. SM may return disco items on the top level, other components should just return it's top level service discovery item for null node.
      Specified by:
      getDiscoItems in interface XMPPService
      Overrides:
      getDiscoItems in class BasicComponent
      Parameters:
      node - is a service discovery node for which the request has been made.
      jid - is the jid to which the request has been made.
      from - is the request sender address. Some service discovery information is only meant for administrators.
      Returns:
      a list of service discovery items for this component or the component itself disco item for the top level request.
    • setName

      public void setName(String name)
      Description copied from interface: ServerComponent
      Method used to assign component name (localpart of the component)
      Specified by:
      setName in interface ServerComponent
      Overrides:
      setName in class BasicComponent
      Parameters:
      name - to be assigned
    • setProperties

      public void setProperties(Map<String,Object> props) throws ConfigurationException
      Description copied from interface: Configurable
      Sets all configuration properties for the object.
      Specified by:
      setProperties in interface Configurable
      Overrides:
      setProperties in class ConfiguratorAbstract
      Parameters:
      props - Map with the configuration
      Throws:
      ConfigurationException - - if setting configuration will fail which will make it unable to work
    • setPropertyValue

      public Object setPropertyValue(String key, String val, Packet result_pack, boolean admin)
    • setValue

      public Object setValue(String node_key, String value, boolean add, boolean feedback, Map<String,Object> orig) throws Exception
      Throws:
      Exception