// Create the new OPC type IltOffPageConnector.Type opcType = new IltOffPageConnector.Type("MyType"); // Retrieve the image and create the base renderer factory Image img = IltSystem.GetDefaultContext().getImageRepository().getImage("type.png"); IltOPCImageBaseRendererFactory factory = new IltOPCImageBaseRendererFactory(img); // Associate the new OPC type with the image base renderer factory IltSettings.SetValue("OffPageConnector.Type.MyType.Renderer", factory);
setting."ilog.tgo.model.IltOffPageConnector"{ types[0]: @+opcType0; } Subobject#opcType0 { class: 'ilog.tgo.model.IltOffPageConnector$Type'; name: "MyType"; }
renderer
. In the example below, the name of the renderer factory class
that is included in the search path is
MyOPCRendererFactory
.
setting."ilog.tgo.model.IltOffPageConnector.Type"[name="MyType"] { renderer: @+opcRendererFactory1; } Subobject#opcRendererFactory1 { class: 'MyOPCRendererFactory'; }
IltOffPageConnector.Type opcType = new IltOffPageConnector.Type("MyType");
setting."ilog.tgo.model.IltOffPageConnector"{ types[0]: @+opcType0; } Subobject#opcType0 { class: 'ilog.tgo.model.IltOffPageConnector.Type'; name: "MyType"; }
IltSettings.SetValue("OffPageConnector.Type.MyType.Renderer", new IltOPCDirectImageBaseRendererFactory());
setting."ilog.tgo.model.IltOffPageConnector.Type"[name="MyType"] { renderer: @+opcRendererFactory1; } Subobject#opcRendererFactory1 { class: 'ilog.tgo.graphic.renderer.IltOPCDirectImageRendererFactory'; }
object."ilog.tgo.model.IltOffPageConnector"["type"=MyType]["objectState.Bell core.State"=EnabledIdle] { sourceImage: '@|image("OPCMyType_EnabledIdle.png")'; alarmColorLevel: 128; } object."ilog.tgo.model.IltOffPageConnector"["type"=MyType]["objectState.Bell core.State"=DisabledIdle] { sourceImage: '@|image("OPCMyType_DisabledIdle.png")'; alarmColorLevel: 140; }
ilog.tgo.OPC_Type_<TYPE NAME>
: off-page connector type labels
ilog.tgo.OPC_Type_<TYPE
NAME>_ToolTip
: off-page connector type tooltips
IltOffPageConnector.Type opcType = new IltOffPageConnector.Type("MyType");
JTGOMessages.properties
file:
ilog.tgo.OPC_Type_MyType=My Type
ilog.tgo.OPC_Type_MyType_ToolTip=My
Off-Page Connector Type