Enum Class ArticleCode

java.lang.Object
java.lang.Enum<ArticleCode>
net.tangly.erp.invoices.domain.ArticleCode
All Implemented Interfaces:
Serializable, Comparable<ArticleCode>, Constable, net.tangly.core.codes.Code

public enum ArticleCode extends Enum<ArticleCode> implements net.tangly.core.codes.Code
Defines the product categories we offer in our shop. Categories are handled differently in invoices and accounting. For example, expenses are added at the end of an invoice and do not carry any VAT tax because VAT was already paid when buying the expense related item like a transportation ticket.
  • work is a regular product code for services
  • material is a regular product code for goods
  • guaranty is a service performed under guaranty and should not be invoiced to the customer
  • licenses is a bought software product invoiced to the customer
  • expenses are travel expenses invoiced to the customer one to one without additional VAT
  • Enum Constant Details

  • Method Details

    • values

      public static ArticleCode[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static ArticleCode valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • id

      public int id()
      Specified by:
      id in interface net.tangly.core.codes.Code
    • code

      public String code()
      Specified by:
      code in interface net.tangly.core.codes.Code
    • enabled

      public boolean enabled()
      Specified by:
      enabled in interface net.tangly.core.codes.Code