-
- All Superinterfaces:
Describable
public interface Platforms extends Describable
Platforms
- Version:
- $Id: $Id
- Author:
- Robert Savage (http://www.savagehomeautomation.com)
- See Also:
- http://www.pi4j.com/
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description Map<String,Platform>all()all.default <T extends Platform>
Map<String,T>all(Class<T> platformClass)Get all platforms of a specified io class/interface.<T extends Platform>
TdefaultPlatform()defaultPlatform.default Descriptordescribe()describe.default booleanexists(Class<? extends Platform> platformClass)booleanexists(String platformId)exists.default <T extends Platform>
booleanexists(String platformId, Class<T> platformClass)exists.default <T extends Platform>
Tget(Class<T> platformClass)get.Platformget(String platformId)get.default <T extends Platform>
Tget(String platformId, Class<T> platformClass)get.default Map<String,Platform>getAll()getAll.default <T extends Platform>
Map<String,T>getAll(Class<T> platformClass)getAll.default <T extends Platform>
TgetDefault()getDefault.default booleanhasDefault()hasDefault.
-
-
-
Method Detail
-
exists
boolean exists(String platformId)
exists.
- Parameters:
platformId- aStringobject.- Returns:
- a boolean.
-
get
Platform get(String platformId) throws PlatformNotFoundException
get.
- Parameters:
platformId- aStringobject.- Returns:
- a
Platformobject. - Throws:
PlatformNotFoundException- if any.
-
defaultPlatform
<T extends Platform> T defaultPlatform()
defaultPlatform.
- Type Parameters:
T- a T object.- Returns:
- a T object.
-
exists
default <T extends Platform> boolean exists(String platformId, Class<T> platformClass) throws PlatformNotFoundException
exists.
- Type Parameters:
T- a T object.- Parameters:
platformId- aStringobject.platformClass- aClassobject.- Returns:
- a boolean.
- Throws:
PlatformNotFoundException- if any.
-
hasDefault
default boolean hasDefault()
hasDefault.
- Returns:
- a boolean.
-
getDefault
default <T extends Platform> T getDefault()
getDefault.
- Type Parameters:
T- a T object.- Returns:
- a T object.
-
get
default <T extends Platform> T get(String platformId, Class<T> platformClass) throws PlatformNotFoundException, PlatformTypeException
get.
- Type Parameters:
T- a T object.- Parameters:
platformId- aStringobject.platformClass- aClassobject.- Returns:
- a T object.
- Throws:
PlatformNotFoundException- if any.PlatformTypeException- if any.
-
exists
default boolean exists(Class<? extends Platform> platformClass) throws PlatformNotFoundException
- Throws:
PlatformNotFoundException
-
get
default <T extends Platform> T get(Class<T> platformClass) throws PlatformNotFoundException
get.
- Type Parameters:
T- a T object.- Parameters:
platformClass- aClassobject.- Returns:
- a T object.
- Throws:
PlatformNotFoundException- if any.
-
all
default <T extends Platform> Map<String,T> all(Class<T> platformClass) throws PlatformNotFoundException
Get all platforms of a specified io class/interface.- Type Parameters:
T- platforms objects extending thePlatforminterface- Parameters:
platformClass- aClassobject.- Returns:
- a
Mapobject. - Throws:
PlatformNotFoundException- if any.
-
getAll
default <T extends Platform> Map<String,T> getAll(Class<T> platformClass) throws PlatformNotFoundException
getAll.
- Type Parameters:
T- a T object.- Parameters:
platformClass- aClassobject.- Returns:
- a
Mapobject. - Throws:
PlatformNotFoundException- if any.
-
describe
default Descriptor describe()
describe.
- Specified by:
describein interfaceDescribable- Returns:
- a
Descriptorobject.
-
-