Class SnippetFile

java.lang.Object
software.amazon.smithy.codegen.core.docs.SnippetFile
All Implemented Interfaces:
ToSmithyBuilder<SnippetFile>

public class SnippetFile extends Object implements ToSmithyBuilder<SnippetFile>
Represents a single file that is part of a snippet. This could be a config file, a source code file, or some logically differentiated file type.
  • Method Details

    • getLanguage

      public String getLanguage()
      Gets the language used by the file.

      This will be used for syntax highlighting.

      Returns:
      Returns a string representation of the file's language.
    • getFilename

      public String getFilename()
      Returns:
      Returns the name of the file.
    • getContent

      public String getContent()
      Returns:
      Returns the content of the file.
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toBuilder

      public SnippetFile.Builder toBuilder()
      Description copied from interface: ToSmithyBuilder
      Take this object and create a builder that contains all of the current property values of this object.
      Specified by:
      toBuilder in interface ToSmithyBuilder<SnippetFile>
      Returns:
      a builder for type T
    • builder

      public static SnippetFile.Builder builder()
      Returns:
      Returns a new SnippetFile builder.