com.kuka.roboticsAPI.deviceModel
Class DeviceFactory

java.lang.Object
  extended by com.kuka.roboticsAPI.AbstractEngine
      extended by com.kuka.roboticsAPI.deviceModel.DeviceFactory
All Implemented Interfaces:
IDeviceFactory, IEngine

public class DeviceFactory
extends AbstractEngine
implements IDeviceFactory

Base implementation of a device factory. Custom implementations may subclass from here.

This element is an undocumented internal feature. It is not intended to be used by applications as it might change or be removed in future versions.

Constructor Summary
DeviceFactory(RoboticsAPIContext context)
          Creates a new instance of the device factory.
 
Method Summary
 Device createDevice(Controller controller, String name, String fqcn, ITransformation deviceRoot)
          Creates the device for the given controller, device name and the proposed class name.
 Class<? extends IEngine> getEngineType()
          Gets the type of the engine.
 
Methods inherited from class com.kuka.roboticsAPI.AbstractEngine
dispose, getContext, initialize, setParameters
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.kuka.roboticsAPI.IEngine
dispose, getContext, initialize, setParameters
 

Constructor Detail

DeviceFactory

public DeviceFactory(RoboticsAPIContext context)
Creates a new instance of the device factory.

Parameters:
context - The context to which the factory is bound.
This element is an undocumented internal feature. It is not intended to be used by applications as it might change or be removed in future versions.
Method Detail

createDevice

public Device createDevice(Controller controller,
                           String name,
                           String fqcn,
                           ITransformation deviceRoot)
Creates the device for the given controller, device name and the proposed class name. This is just a proposal and may be ignored by the concrete factory implementation.

Please note that the device must be initialized after this call.

The call should fail with a runtime exception when the device could not be created.

Specified by:
createDevice in interface IDeviceFactory
Parameters:
controller - The controller to which the device is attached.
name - The name of the device.
fqcn - The full qualified class name as a proposal for the device type. Will be a subclass of Device.
deviceRoot - The desired root frame for this device.
Returns:
The created device.
This element is an undocumented internal feature. It is not intended to be used by applications as it might change or be removed in future versions.

getEngineType

public Class<? extends IEngine> getEngineType()
Gets the type of the engine. This should be the concrete IEngine interface which the engine is implementing.

Specified by:
getEngineType in interface IEngine
Specified by:
getEngineType in class AbstractEngine
Returns:
The type of the engine. This should be the concrete IEngine interface which the engine is implementing.
This element is an undocumented internal feature. It is not intended to be used by applications as it might change or be removed in future versions.


Copyright © 2019. All rights reserved.