Class ImmutableSiteState

    • Method Detail

      • withName

        public final ImmutableSiteState withName​(String value)
        Copy the current immutable object by setting a value for the name attribute. An equals check used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for name
        Returns:
        A modified copy of the this object
      • withContentType

        public final ImmutableSiteState withContentType​(StencilClient.SiteContentType value)
        Copy the current immutable object by setting a value for the contentType attribute. A value equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for contentType
        Returns:
        A modified copy of the this object
      • withReleases

        public final ImmutableSiteState withReleases​(Map<String,​? extends StencilClient.Entity<StencilClient.Release>> entries)
        Copy the current immutable object by replacing the releases map with the specified map. Nulls are not permitted as keys or values. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        entries - The entries to be added to the releases map
        Returns:
        A modified copy of this object
      • withLocales

        public final ImmutableSiteState withLocales​(Map<String,​? extends StencilClient.Entity<StencilClient.Locale>> entries)
        Copy the current immutable object by replacing the locales map with the specified map. Nulls are not permitted as keys or values. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        entries - The entries to be added to the locales map
        Returns:
        A modified copy of this object
      • withPages

        public final ImmutableSiteState withPages​(Map<String,​? extends StencilClient.Entity<StencilClient.Page>> entries)
        Copy the current immutable object by replacing the pages map with the specified map. Nulls are not permitted as keys or values. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        entries - The entries to be added to the pages map
        Returns:
        A modified copy of this object
      • withLinks

        public final ImmutableSiteState withLinks​(Map<String,​? extends StencilClient.Entity<StencilClient.Link>> entries)
        Copy the current immutable object by replacing the links map with the specified map. Nulls are not permitted as keys or values. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        entries - The entries to be added to the links map
        Returns:
        A modified copy of this object
      • withArticles

        public final ImmutableSiteState withArticles​(Map<String,​? extends StencilClient.Entity<StencilClient.Article>> entries)
        Copy the current immutable object by replacing the articles map with the specified map. Nulls are not permitted as keys or values. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        entries - The entries to be added to the articles map
        Returns:
        A modified copy of this object
      • withWorkflows

        public final ImmutableSiteState withWorkflows​(Map<String,​? extends StencilClient.Entity<StencilClient.Workflow>> entries)
        Copy the current immutable object by replacing the workflows map with the specified map. Nulls are not permitted as keys or values. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        entries - The entries to be added to the workflows map
        Returns:
        A modified copy of this object
      • equals

        public boolean equals​(@Nullable
                              Object another)
        This instance is equal to all instances of ImmutableSiteState that have equal attribute values.
        Overrides:
        equals in class Object
        Returns:
        true if this is equal to another instance
      • hashCode

        public int hashCode()
        Computes a hash code from attributes: name, contentType, releases, locales, pages, links, articles, workflows.
        Overrides:
        hashCode in class Object
        Returns:
        hashCode value
      • toString

        public String toString()
        Prints the immutable value SiteState with attribute values.
        Overrides:
        toString in class Object
        Returns:
        A string representation of the value
      • copyOf

        public static ImmutableSiteState copyOf​(StencilClient.SiteState instance)
        Creates an immutable copy of a StencilClient.SiteState value. Uses accessors to get values to initialize the new immutable instance. If an instance is already immutable, it is returned as is.
        Parameters:
        instance - The instance to copy
        Returns:
        A copied immutable SiteState instance
      • builder

        public static ImmutableSiteState.Builder builder()
        Creates a builder for ImmutableSiteState.
         ImmutableSiteState.builder()
            .name(String) // required name
            .contentType(io.thestencil.client.api.StencilClient.SiteContentType) // required contentType
            .putReleases|putAllReleases(String => io.thestencil.client.api.StencilClient.Entity&lt;io.thestencil.client.api.StencilClient.Release&gt;) // releases mappings
            .putLocales|putAllLocales(String => io.thestencil.client.api.StencilClient.Entity&lt;io.thestencil.client.api.StencilClient.Locale&gt;) // locales mappings
            .putPages|putAllPages(String => io.thestencil.client.api.StencilClient.Entity&lt;io.thestencil.client.api.StencilClient.Page&gt;) // pages mappings
            .putLinks|putAllLinks(String => io.thestencil.client.api.StencilClient.Entity&lt;io.thestencil.client.api.StencilClient.Link&gt;) // links mappings
            .putArticles|putAllArticles(String => io.thestencil.client.api.StencilClient.Entity&lt;io.thestencil.client.api.StencilClient.Article&gt;) // articles mappings
            .putWorkflows|putAllWorkflows(String => io.thestencil.client.api.StencilClient.Entity&lt;io.thestencil.client.api.StencilClient.Workflow&gt;) // workflows mappings
            .build();
         
        Returns:
        A new ImmutableSiteState builder