Class JamServiceImpl

  • All Implemented Interfaces:
    JamService

    public class JamServiceImpl
    extends java.lang.Object
    implements JamService
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      JClass[] getAllClasses()
      Returns all of the JClasses returned by getClasses() in a single array.
      JamClassIterator getClasses()
      Returns an iterator of the JClasses named in the array returned by getClassNames().
      JamClassLoader getClassLoader()
      Returns a JamClassLoader which can be used to load JClasses from class- and source-file locations specified in the JamServiceParams with which this service was instantiated.
      java.lang.String[] getClassNames()
      Returns the names of the classes that were described in the JamServiceParams object used to create this service.
      void setClassNames​(java.lang.String[] names)  
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • JamServiceImpl

        public JamServiceImpl​(ElementContext ctx,
                              java.lang.String[] classes)
    • Method Detail

      • getClassLoader

        public JamClassLoader getClassLoader()
        Description copied from interface: JamService
        Returns a JamClassLoader which can be used to load JClasses from class- and source-file locations specified in the JamServiceParams with which this service was instantiated. Note that it is possible to use this mechanism to load JClasses that are not returned by getClasses().
        Specified by:
        getClassLoader in interface JamService
      • getClassNames

        public java.lang.String[] getClassNames()
        Description copied from interface: JamService
        Returns the names of the classes that were described in the JamServiceParams object used to create this service. Note that this list will never change for a given service; though it is possible to use the service's JamClassLoader to load other types, this method will always return the initial set of classes.
        Specified by:
        getClassNames in interface JamService
      • getClasses

        public JamClassIterator getClasses()
        Description copied from interface: JamService
        Returns an iterator of the JClasses named in the array returned by getClassNames().
        Specified by:
        getClasses in interface JamService
      • getAllClasses

        public JClass[] getAllClasses()
        Description copied from interface: JamService
        Returns all of the JClasses returned by getClasses() in a single array. Use of this method (as opposed to getClasses()) is not advised if you expect to be dealing with a very large set of classes, as it makes it less likely that JClasses will be garbage collected when no longer needed.
        Specified by:
        getAllClasses in interface JamService
      • setClassNames

        public void setClassNames​(java.lang.String[] names)