Class ReadOnlyUICustomWidgetFactory

java.lang.Object
com.apgar.common.lib.ui.widget.readonlywidget.ReadOnlyUICustomWidgetFactory
All Implemented Interfaces:
com.orchestranetworks.ui.form.widget.UIWidgetFactory<ReadOnlyUICustomWidget>

public class ReadOnlyUICustomWidgetFactory extends Object implements com.orchestranetworks.ui.form.widget.UIWidgetFactory<ReadOnlyUICustomWidget>
Factory class for creating instances of ReadOnlyUICustomWidget.

This factory implements UIWidgetFactory and is responsible for instantiating and setting up ReadOnlyUICustomWidget, which enforces read-only rights on a field within a form.

This class is defined as follows under the field to be displayed as Read-Only in the XSD.

 <xs:element name="sampleField" minOccurs="0" maxOccurs="1">
     <xs:annotation>
         <xs:documentation xml:lang="en-US">
             <osd:label>Sample Field</osd:label>
         </xs:documentation>
         <xs:appinfo>
             <osd:defaultView>
                 <widget osd:class="com.apgar.common.lib.ui.widget.passwordwidget.ReadOnlyUICustomWidgetFactory"/>
             </osd:defaultView>
         </xs:appinfo>
     </xs:annotation>
 </xs:element>
 
Author:
APGAR Consulting
  • Constructor Details

    • ReadOnlyUICustomWidgetFactory

      public ReadOnlyUICustomWidgetFactory()
  • Method Details

    • newInstance

      public ReadOnlyUICustomWidget newInstance(com.orchestranetworks.ui.form.widget.WidgetFactoryContext context)
      Creates a new instance of ReadOnlyUICustomWidget using the provided WidgetFactoryContext.
      Specified by:
      newInstance in interface com.orchestranetworks.ui.form.widget.UIWidgetFactory<ReadOnlyUICustomWidget>
      Parameters:
      context - the context providing information necessary for widget creation, including the path to the field that this widget will represent
      Returns:
      a new instance of ReadOnlyUICustomWidget associated with the specified path
    • setup

      public void setup(com.orchestranetworks.ui.form.widget.WidgetFactorySetupContext context)
      Sets up the ReadOnlyUICustomWidgetFactory during its initialization phase.
      Specified by:
      setup in interface com.orchestranetworks.ui.form.widget.UIWidgetFactory<ReadOnlyUICustomWidget>
      Parameters:
      context - the setup context providing additional information and services that may be used during the factory's setup