Class FileTransferNamespace
- java.lang.Object
- 
- org.eclipse.ecf.core.identity.Namespace
- 
- org.eclipse.ecf.provider.filetransfer.identity.FileTransferNamespace
 
 
- 
- All Implemented Interfaces:
- Serializable,- org.eclipse.core.runtime.IAdaptable
 
 public class FileTransferNamespace extends Namespace URL file namespace class. This defines a namespace that understands how to create IFileID instances from arbitary URLs- See Also:
- Serialized Form
 
- 
- 
Field SummaryFields Modifier and Type Field Description static StringPROTOCOL- 
Fields inherited from class org.eclipse.ecf.core.identity.NamespaceSCHEME_SEPARATOR
 
- 
 - 
Constructor SummaryConstructors Constructor Description FileTransferNamespace()
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description IDcreateInstance(Object[] args)Make an instance of this namespace.StringgetScheme()Get the primary scheme associated with this namespace.Class[][]getSupportedParameterTypes()Get the supported parameter types for IDs created via subsequent calls toNamespace.createInstance(Object[]).String[]getSupportedSchemes()Get an array of schemes supported by this Namespace instance.- 
Methods inherited from class org.eclipse.ecf.core.identity.Namespaceequals, getAdapter, getCompareToForObject, getDescription, getHashCodeForID, getInitStringFromExternalForm, getName, getNameForID, hashCode, initialize, testIDEquals, toExternalForm, toString
 
- 
 
- 
- 
- 
Field Detail- 
PROTOCOLpublic static final String PROTOCOL 
 
- 
 - 
Method Detail- 
createInstancepublic ID createInstance(Object[] args) throws IDCreateException Description copied from class:NamespaceMake an instance of this namespace. Namespace subclasses, provided by plugins must implement this method to construct ID instances for the given namespace.
 SeeNamespace.getSupportedParameterTypes()to get information relevant to deciding what parameter types are expected by this method.- Specified by:
- createInstancein class- Namespace
- Parameters:
- args- an Object[] of parameters for creating ID instances. May be null.
- Returns:
- a non-null ID instance. The class used may extend BaseID or may implement the ID interface directly
- Throws:
- IDCreateException- if construction fails
 
 - 
getSupportedSchemespublic String[] getSupportedSchemes() Description copied from class:NamespaceGet an array of schemes supported by this Namespace instance. Subclasses may override to support multiple schemes.- Overrides:
- getSupportedSchemesin class- Namespace
- Returns:
- String[] of schemes supported by this Namespace. Will not be
         null, but returned array may be of length 0.
 
 - 
getSchemepublic String getScheme() Description copied from class:NamespaceGet the primary scheme associated with this namespace. Subclasses must provide an implementation that returns a non-nullscheme identifier. Note that the returned scheme should not contain the Namespace.SCHEME_SEPARATOR (\":\").
 - 
getSupportedParameterTypespublic Class[][] getSupportedParameterTypes() Description copied from class:NamespaceGet the supported parameter types for IDs created via subsequent calls toNamespace.createInstance(Object[]). Callers may use this method to determine the available parameter types, and then create and pass in conforming Object arrays to toNamespace.createInstance(Object[]).
 An empty two-dimensional array (new Class[0][0]) is the default returned by this abstract superclass. This means that the Object [] passed toNamespace.createInstance(Object[])will be ignored.
 Subsclasses should override this method to specify the parameters that they will accept in calls toNamespace.createInstance(Object[]). The rows of the returned Class array are the acceptable types for a given invocation of createInstance.
 Consider the following example:public Class[][] getSupportedParameterTypes() { return new Class[][] { { String.class }, { String.class, String.class } }; }The above means that there are two acceptable values for the Object [] passed intoNamespace.createInstance(Object[]): 1) a single String, and 2) two Strings. These would therefore be acceptable as input to createInstance:ID newID1 = namespace.createInstance(new Object[] { "Hello" }); ID newID2 = namespace.createInstance(new Object[] { "Hello", "There"}};- Overrides:
- getSupportedParameterTypesin class- Namespace
- Returns:
- Class [][] an array of class []s. Rows of the returned
         two-dimensional array define the acceptable parameter types for a
         single call to Namespace.createInstance(Object[]). If zero-length Class arrays are returned (i.e. Class[0][0]), then Object [] parameters toNamespace.createInstance(Object[])will be ignored.
 
 
- 
 
-