OSGi™ Service Platform
Release 4 Version 4.2

org.osgi.service.metatype
Interface MetaTypeProvider

All Known Subinterfaces:
MetaTypeInformation

public interface MetaTypeProvider

Provides access to metatypes.


Method Summary
 java.lang.String[] getLocales()
          Return a list of available locales.
 ObjectClassDefinition getObjectClassDefinition(java.lang.String id, java.lang.String locale)
          Returns an object class definition for the specified id localized to the specified locale.
 

Method Detail

getObjectClassDefinition

ObjectClassDefinition getObjectClassDefinition(java.lang.String id,
                                               java.lang.String locale)
Returns an object class definition for the specified id localized to the specified locale.

The locale parameter must be a name that consists of language[ "_" country[ "_" variation] ] as is customary in the Locale class. This Locale class is not used because certain profiles do not contain it.

Parameters:
id - The ID of the requested object class. This can be a pid or factory pid returned by getPids or getFactoryPids.
locale - The locale of the definition or null for default locale.
Returns:
A ObjectClassDefinition object.
Throws:
java.lang.IllegalArgumentException - If the id or locale arguments are not valid

getLocales

java.lang.String[] getLocales()
Return a list of available locales. The results must be names that consists of language [ _ country [ _ variation ]] as is customary in the Locale class.

Returns:
An array of locale strings or null if there is no locale specific localization can be found.

OSGi™ Service Platform
Release 4 Version 4.2

Copyright © OSGi Alliance (2000, 2010). All Rights Reserved. Licensed under the OSGi Specification License, Version 1.0