Package com.iizix.urn
Interface IURNProvider
- All Known Subinterfaces:
IFileURNProvider
,IImageURNProvider
- All Known Implementing Classes:
BarcodeURNFactory
,FileURNFactory
,FileURNProvider
,ImageURNFactory
,ImageURNProvider
,SVG_URNFactory
,URL_URNFactory
,UserProfileImageURNFactory
,UserProfileStringURNFactory
public interface IURNProvider
Interface used to map a URN string to an external URL string to use by a device, accessing the iiziServer or the iiziGo Designer web server. The interface is used by the{@link URLFactory}
for setup by URL providers and is then able to satisfy requests for different types of resources, e.g. strings, files or identifications referencing a database entry.An IURNProvider could be a provider of PDF's, Barcodes's, etc.
- Author:
- Christopher Mindus
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description NID
getNID()
Gets the Naming IDentifier of the provider.java.util.List<URNResourceType>
getResourceTypes()
Gets the URN Resource Type supported by the provider.default java.lang.String
paramString0()
Returns a parameter string part used to produce the "toString()" or "paramString()".URN
parse(java.lang.String urnString, java.lang.String nss, java.lang.String req, java.lang.String query, java.lang.String fragment)
Parses the URN after the NID specification, i.e.
Method Detail
getNID
NID getNID()
Gets the Naming IDentifier of the provider.- Returns:
- The NID.
getResourceTypes
java.util.List<URNResourceType> getResourceTypes()
Gets the URN Resource Type supported by the provider.- Returns:
- The supported resource type, empty list when not resource based.
parse
URN parse(java.lang.String urnString, java.lang.String nss, java.lang.String req, java.lang.String query, java.lang.String fragment) throws URNException
Parses the URN after the NID specification, i.e. after "urn:NID:".- Parameters:
urnString
- The full unparsed original URN string.nss
- The NSS part of the string (before request/query/fragment).req
- The decoded request String (without "?+"),null
for none.query
- The decoded query String (without "?="),null
for none.fragment
- The decoded fragment,null
for none.- Returns:
- The URN instance.
- Throws:
URNException
- For URN exceptions.
paramString0
default java.lang.String paramString0()
Returns a parameter string part used to produce the "toString()" or "paramString()".- Returns:
- A part of the string for the provider type.