java.lang.Object
com.inductiveautomation.perspective.common.config.styles.StyleClassConfig

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

    • SCHEMA

      public static final JsonSchema SCHEMA
    • RESOURCE_TYPE

      public static final ResourceType RESOURCE_TYPE
    • FILENAME

      public static final String FILENAME
      See Also:
    • ROOT_FOLDER

      public static final UUID ROOT_FOLDER
    • VALID_NAME_PATTERN

      public static final Pattern VALID_NAME_PATTERN
      Restrictive naming pattern for a CSS identifier - starts with letter or underscore, and contains only letters, numbers, underscores, and hyphens
    • base

      public StyleVariantConfig base
    • variants

      public final List<StyleVariantConfig> variants
  • Constructor Details

  • Method Details

    • fromProjectResource

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

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

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

      public String toCss(String className)
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object