Class StyleClassConfig


  • public class StyleClassConfig
    extends java.lang.Object
    Represents a style class's stored configuration. This class is meant to be used by GSON for json serialization and deserialization.
    • Field Detail

      • RESOURCE_TYPE

        public static final ResourceType RESOURCE_TYPE
      • ROOT_FOLDER

        public static final java.util.UUID ROOT_FOLDER
      • VALID_NAME_PATTERN

        public static final java.util.regex.Pattern VALID_NAME_PATTERN
        Restrictive naming pattern for a CSS identifier - starts with letter or underscore, and contains only letters, numbers, underscores, and hyphens
    • Method Detail

      • fromProjectResource

        public static StyleClassConfig fromProjectResource​(ProjectResource resource,
                                                           com.inductiveautomation.ignition.common.gson.Gson gson)
      • getEscapedName

        public static java.lang.String getEscapedName​(@Nonnull
                                                      ProjectResource resource)
        Get the name and path to a style, escaped for use in a compiled .css file
      • getRawName

        public static java.lang.String getRawName​(@Nonnull
                                                  ProjectResource resource)
        Get the name and path to a style, directly (suitable for use on actual component style classes)
      • toCss

        public java.lang.String toCss​(java.lang.String className)
      • equals

        public boolean equals​(java.lang.Object obj)
        Overrides:
        equals in class java.lang.Object