Interface ILayoutUnitWidth

    • Method Summary

      All Methods Instance Methods Abstract Methods Default Methods 
      Modifier and Type Method Description
      <VALUE> VALUE getPropValue​(java.lang.String name, java.lang.Class<VALUE> clazz)
      Gets the value of the property by the name.
      default GUnit getWidthUnit()
      Returns the width of the component.
      <VALUE> boolean setPropValue​(java.lang.String name, VALUE value, java.lang.Class<? extends GProp<VALUE>> propClass)
      Sets a property value in the container.
      default boolean setWidth​(GUnit width)
      Set the width of the component.
    • Method Detail

      • getPropValue

        <VALUE> VALUE getPropValue​(java.lang.String name,
                                   java.lang.Class<VALUE> clazz)
        Gets the value of the property by the name. An error is logged if the value is not of specified class.
        Parameters:
        name - the name of the property to locate in the array.
        clazz - the class the property must be or extend, null for no checking.
        Returns:
        Object the property or null for uninitialized container or the property with specified name is not found.
      • setPropValue

        <VALUE> boolean setPropValue​(java.lang.String name,
                                     VALUE value,
                                     java.lang.Class<? extends GProp<VALUE>> propClass)
        Sets a property value in the container.
        Parameters:
        name - The name of the property.
        value - The value to set, null to remove the property.
        propClass - The property class.
        Returns:
        true if value was changed, false for no changes.
        Throws:
        java.lang.InternalError - If the property could not be removed or set due to errors.
      • getWidthUnit

        default GUnit getWidthUnit()
        Returns the width of the component.
        Returns:
        The unit, or null if width is not defined.
      • setWidth

        default boolean setWidth​(GUnit width)
        Set the width of the component.
        Parameters:
        width - The width, null to remove the value.
        Returns:
        true for value changed, false for no change.