Record Class ContextBo

java.lang.Object
java.lang.Record
com.sankcrm.erp.contract.application.command.ContextBo
Record Components:
html - HTML模板
template - 模板信息
pdfFile - pdf 文件

public record ContextBo(com.sankcrm.erp.common.sensitive.SecretKey html, ContractTemplate template, com.sankcrm.erp.contract.application.command.PdfFileVo pdfFile, com.sankcrm.erp.contract.application.command.DocxFileVo docxFile) extends Record
合同内容信息
Since:
1.3.0
Author:
zhsxin
  • Constructor Summary

    Constructors
    Constructor
    Description
    ContextBo(com.sankcrm.erp.common.sensitive.SecretKey html, ContractTemplate template, com.sankcrm.erp.contract.application.command.PdfFileVo pdfFile, com.sankcrm.erp.contract.application.command.DocxFileVo docxFile)
    Creates an instance of a ContextBo record class.
  • Method Summary

    Modifier and Type
    Method
    Description
    static ContextBo
    docx(com.sankcrm.erp.contract.application.command.DocxFileVo docxFile)
     
    com.sankcrm.erp.contract.application.command.DocxFileVo
    Returns the value of the docxFile record component.
    final boolean
    Indicates whether some other object is "equal to" this one.
    final int
    Returns a hash code value for this object.
    com.sankcrm.erp.common.sensitive.SecretKey
    Returns the value of the html record component.
    static ContextBo
    html(com.sankcrm.erp.common.sensitive.SecretKey html)
     
    boolean
     
    boolean
    是否PDF 文件
    Optional<com.sankcrm.erp.auth.domain.model.OrganizationId>
     
    static ContextBo
    pdf(com.sankcrm.erp.contract.application.command.PdfFileVo pdfFile)
     
    com.sankcrm.erp.contract.application.command.PdfFileVo
    Returns the value of the pdfFile record component.
    Returns the value of the template record component.
    static ContextBo
     
     
    final String
    Returns a string representation of this record class.

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • ContextBo

      public ContextBo(com.sankcrm.erp.common.sensitive.SecretKey html, ContractTemplate template, com.sankcrm.erp.contract.application.command.PdfFileVo pdfFile, com.sankcrm.erp.contract.application.command.DocxFileVo docxFile)
      Creates an instance of a ContextBo record class.
      Parameters:
      html - the value for the html record component
      template - the value for the template record component
      pdfFile - the value for the pdfFile record component
      docxFile - the value for the docxFile record component
  • Method Details

    • isPdf

      public boolean isPdf()
      是否PDF 文件
      Returns:
      true:是 false:否
    • isDocx

      public boolean isDocx()
    • organizeIdOpt

      public Optional<com.sankcrm.erp.auth.domain.model.OrganizationId> organizeIdOpt()
    • templateOpt

      public Optional<ContractTemplate> templateOpt()
    • pdf

      public static ContextBo pdf(com.sankcrm.erp.contract.application.command.PdfFileVo pdfFile)
    • html

      public static ContextBo html(com.sankcrm.erp.common.sensitive.SecretKey html)
    • docx

      public static ContextBo docx(com.sankcrm.erp.contract.application.command.DocxFileVo docxFile)
    • template

      public static ContextBo template(ContractTemplate template)
    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • html

      public com.sankcrm.erp.common.sensitive.SecretKey html()
      Returns the value of the html record component.
      Returns:
      the value of the html record component
    • template

      public ContractTemplate template()
      Returns the value of the template record component.
      Returns:
      the value of the template record component
    • pdfFile

      public com.sankcrm.erp.contract.application.command.PdfFileVo pdfFile()
      Returns the value of the pdfFile record component.
      Returns:
      the value of the pdfFile record component
    • docxFile

      public com.sankcrm.erp.contract.application.command.DocxFileVo docxFile()
      Returns the value of the docxFile record component.
      Returns:
      the value of the docxFile record component