All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.softlayer.api.service.billing.Invoice Maven / Gradle / Ivy

There is a newer version: 0.3.4
Show newest version
package com.softlayer.api.service.billing;

import com.softlayer.api.ApiClient;
import com.softlayer.api.ResponseHandler;
import com.softlayer.api.annotation.ApiMethod;
import com.softlayer.api.annotation.ApiProperty;
import com.softlayer.api.annotation.ApiType;
import com.softlayer.api.service.Account;
import com.softlayer.api.service.Brand;
import com.softlayer.api.service.Entity;
import com.softlayer.api.service.billing.invoice.Item;
import com.softlayer.api.service.billing.invoice.receivable.Payment;
import com.softlayer.api.service.billing.invoice.tax.Info;
import com.softlayer.api.service.billing.invoice.tax.Type;
import com.softlayer.api.service.container.billing.invoice.Email;
import com.softlayer.api.service.container.product.item.category.zerofee.Count;
import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.GregorianCalendar;
import java.util.List;
import java.util.concurrent.Future;

/**
 * The SoftLayer_Billing_Invoice data type contains general information relating to an individual invoice applied to a SoftLayer customer account. Personal information in this type such as names, addresses, and phone numbers are taken from the account's contact information at the time the invoice is generated. 
 *
 * @see SoftLayer_Billing_Invoice
 */
@ApiType("SoftLayer_Billing_Invoice")
public class Invoice extends Entity {

    /**
     * The account that an invoice belongs to.
     */
    @ApiProperty
    protected Account account;

    public Account getAccount() {
        return account;
    }

    public void setAccount(Account account) {
        this.account = account;
    }

    /**
     * This is the amount of this invoice.
     */
    @ApiProperty
    protected BigDecimal amount;

    public BigDecimal getAmount() {
        return amount;
    }

    public void setAmount(BigDecimal amount) {
        this.amount = amount;
    }

    @ApiProperty
    protected Brand brandAtInvoiceCreation;

    public Brand getBrandAtInvoiceCreation() {
        return brandAtInvoiceCreation;
    }

    public void setBrandAtInvoiceCreation(Brand brandAtInvoiceCreation) {
        this.brandAtInvoiceCreation = brandAtInvoiceCreation;
    }

    /**
     * A flag that will reflect whether the detailed version of the pdf has been generated.
     */
    @ApiProperty
    protected Boolean detailedPdfGeneratedFlag;

    public Boolean getDetailedPdfGeneratedFlag() {
        return detailedPdfGeneratedFlag;
    }

    public void setDetailedPdfGeneratedFlag(Boolean detailedPdfGeneratedFlag) {
        this.detailedPdfGeneratedFlag = detailedPdfGeneratedFlag;
    }

    /**
     * A list of top-level invoice items that are on the currently pending invoice.
     */
    @ApiProperty
    protected List invoiceTopLevelItems;

    public List getInvoiceTopLevelItems() {
        if (invoiceTopLevelItems == null) {
            invoiceTopLevelItems = new ArrayList();
        }
        return invoiceTopLevelItems;
    }

    /**
     * The total amount of this invoice.
     */
    @ApiProperty
    protected BigDecimal invoiceTotalAmount;

    public BigDecimal getInvoiceTotalAmount() {
        return invoiceTotalAmount;
    }

    public void setInvoiceTotalAmount(BigDecimal invoiceTotalAmount) {
        this.invoiceTotalAmount = invoiceTotalAmount;
    }

    /**
     * The total one-time charges for this invoice. This is the sum of one-time charges + setup fees + labor fees. This does not include taxes.
     */
    @ApiProperty
    protected BigDecimal invoiceTotalOneTimeAmount;

    public BigDecimal getInvoiceTotalOneTimeAmount() {
        return invoiceTotalOneTimeAmount;
    }

    public void setInvoiceTotalOneTimeAmount(BigDecimal invoiceTotalOneTimeAmount) {
        this.invoiceTotalOneTimeAmount = invoiceTotalOneTimeAmount;
    }

    /**
     * A sum of all the taxes related to one time charges for this invoice.
     */
    @ApiProperty
    protected BigDecimal invoiceTotalOneTimeTaxAmount;

    public BigDecimal getInvoiceTotalOneTimeTaxAmount() {
        return invoiceTotalOneTimeTaxAmount;
    }

    public void setInvoiceTotalOneTimeTaxAmount(BigDecimal invoiceTotalOneTimeTaxAmount) {
        this.invoiceTotalOneTimeTaxAmount = invoiceTotalOneTimeTaxAmount;
    }

    /**
     * The total amount of this invoice. This does not include taxes.
     */
    @ApiProperty
    protected BigDecimal invoiceTotalPreTaxAmount;

    public BigDecimal getInvoiceTotalPreTaxAmount() {
        return invoiceTotalPreTaxAmount;
    }

    public void setInvoiceTotalPreTaxAmount(BigDecimal invoiceTotalPreTaxAmount) {
        this.invoiceTotalPreTaxAmount = invoiceTotalPreTaxAmount;
    }

    /**
     * The total Recurring amount of this invoice. This amount does not include taxes or one time charges.
     */
    @ApiProperty
    protected BigDecimal invoiceTotalRecurringAmount;

    public BigDecimal getInvoiceTotalRecurringAmount() {
        return invoiceTotalRecurringAmount;
    }

    public void setInvoiceTotalRecurringAmount(BigDecimal invoiceTotalRecurringAmount) {
        this.invoiceTotalRecurringAmount = invoiceTotalRecurringAmount;
    }

    /**
     * The total amount of the recurring taxes on this invoice.
     */
    @ApiProperty
    protected BigDecimal invoiceTotalRecurringTaxAmount;

    public BigDecimal getInvoiceTotalRecurringTaxAmount() {
        return invoiceTotalRecurringTaxAmount;
    }

    public void setInvoiceTotalRecurringTaxAmount(BigDecimal invoiceTotalRecurringTaxAmount) {
        this.invoiceTotalRecurringTaxAmount = invoiceTotalRecurringTaxAmount;
    }

    /**
     * The items that belong to this invoice.
     */
    @ApiProperty
    protected List items;

    public List getItems() {
        if (items == null) {
            items = new ArrayList();
        }
        return items;
    }

    /**
     * This is the total payment made on this invoice.
     */
    @ApiProperty
    protected BigDecimal payment;

    public BigDecimal getPayment() {
        return payment;
    }

    public void setPayment(BigDecimal payment) {
        this.payment = payment;
    }

    /**
     * The payments for the invoice.
     */
    @ApiProperty
    protected List payments;

    public List getPayments() {
        if (payments == null) {
            payments = new ArrayList();
        }
        return payments;
    }

    /**
     * This is the seller's tax registration.
     */
    @ApiProperty
    protected String sellerRegistration;

    public String getSellerRegistration() {
        return sellerRegistration;
    }

    public void setSellerRegistration(String sellerRegistration) {
        this.sellerRegistration = sellerRegistration;
    }

    /**
     * This is the tax information that applies to tax auditing. This is the official tax record for this invoice.
     */
    @ApiProperty
    protected Info taxInfo;

    public Info getTaxInfo() {
        return taxInfo;
    }

    public void setTaxInfo(Info taxInfo) {
        this.taxInfo = taxInfo;
    }

    /**
     * This is the set of tax information for any tax calculation for this invoice. Note that not all of these are necessarily official, so use the taxInfo key to get the final information.
     */
    @ApiProperty
    protected List taxInfoHistory;

    public List getTaxInfoHistory() {
        if (taxInfoHistory == null) {
            taxInfoHistory = new ArrayList();
        }
        return taxInfoHistory;
    }

    /**
     * This is a message explaining the tax treatment for this invoice.
     */
    @ApiProperty
    protected String taxMessage;

    public String getTaxMessage() {
        return taxMessage;
    }

    public void setTaxMessage(String taxMessage) {
        this.taxMessage = taxMessage;
    }

    /**
     * This is the strategy used to calculate tax on this invoice.
     */
    @ApiProperty
    protected Type taxType;

    public Type getTaxType() {
        return taxType;
    }

    public void setTaxType(Type taxType) {
        this.taxType = taxType;
    }

    /**
     * The SoftLayer customer account that an invoice belongs to.
     */
    @ApiProperty(canBeNullOrNotSet = true)
    protected Long accountId;

    public Long getAccountId() {
        return accountId;
    }

    public void setAccountId(Long accountId) {
        accountIdSpecified = true;
        this.accountId = accountId;
    }

    protected boolean accountIdSpecified;

    public boolean isAccountIdSpecified() {
        return accountIdSpecified;
    }

    public void unsetAccountId() {
        accountId = null;
        accountIdSpecified = false;
    }

    /**
     * The first line of an address belonging to an account at the time an invoice is created.
     */
    @ApiProperty(canBeNullOrNotSet = true)
    protected String address1;

    public String getAddress1() {
        return address1;
    }

    public void setAddress1(String address1) {
        address1Specified = true;
        this.address1 = address1;
    }

    protected boolean address1Specified;

    public boolean isAddress1Specified() {
        return address1Specified;
    }

    public void unsetAddress1() {
        address1 = null;
        address1Specified = false;
    }

    /**
     * The second line of an address belonging to an account at the time an invoice is created.
     */
    @ApiProperty(canBeNullOrNotSet = true)
    protected String address2;

    public String getAddress2() {
        return address2;
    }

    public void setAddress2(String address2) {
        address2Specified = true;
        this.address2 = address2;
    }

    protected boolean address2Specified;

    public boolean isAddress2Specified() {
        return address2Specified;
    }

    public void unsetAddress2() {
        address2 = null;
        address2Specified = false;
    }

    /**
     * The city portion of an address belonging to an account at the time an invoice is created.
     */
    @ApiProperty(canBeNullOrNotSet = true)
    protected String city;

    public String getCity() {
        return city;
    }

    public void setCity(String city) {
        citySpecified = true;
        this.city = city;
    }

    protected boolean citySpecified;

    public boolean isCitySpecified() {
        return citySpecified;
    }

    public void unsetCity() {
        city = null;
        citySpecified = false;
    }

    /**
     * Whether an account was exempt from taxes on their invoices at the time an invoice is created.
     */
    @ApiProperty(canBeNullOrNotSet = true)
    protected Boolean claimedTaxExemptTxFlag;

    public Boolean getClaimedTaxExemptTxFlag() {
        return claimedTaxExemptTxFlag;
    }

    public void setClaimedTaxExemptTxFlag(Boolean claimedTaxExemptTxFlag) {
        claimedTaxExemptTxFlagSpecified = true;
        this.claimedTaxExemptTxFlag = claimedTaxExemptTxFlag;
    }

    protected boolean claimedTaxExemptTxFlagSpecified;

    public boolean isClaimedTaxExemptTxFlagSpecified() {
        return claimedTaxExemptTxFlagSpecified;
    }

    public void unsetClaimedTaxExemptTxFlag() {
        claimedTaxExemptTxFlag = null;
        claimedTaxExemptTxFlagSpecified = false;
    }

    /**
     * The date an invoice was closed. Open invoices have a null closed date.
     */
    @ApiProperty(canBeNullOrNotSet = true)
    protected GregorianCalendar closedDate;

    public GregorianCalendar getClosedDate() {
        return closedDate;
    }

    public void setClosedDate(GregorianCalendar closedDate) {
        closedDateSpecified = true;
        this.closedDate = closedDate;
    }

    protected boolean closedDateSpecified;

    public boolean isClosedDateSpecified() {
        return closedDateSpecified;
    }

    public void unsetClosedDate() {
        closedDate = null;
        closedDateSpecified = false;
    }

    /**
     * The company name belonging to an account at the time an invoice is created.
     */
    @ApiProperty(canBeNullOrNotSet = true)
    protected String companyName;

    public String getCompanyName() {
        return companyName;
    }

    public void setCompanyName(String companyName) {
        companyNameSpecified = true;
        this.companyName = companyName;
    }

    protected boolean companyNameSpecified;

    public boolean isCompanyNameSpecified() {
        return companyNameSpecified;
    }

    public void unsetCompanyName() {
        companyName = null;
        companyNameSpecified = false;
    }

    /**
     * A two-letter abbreviation of the country portion of an address belonging to an account at the time an invoice is created.
     */
    @ApiProperty(canBeNullOrNotSet = true)
    protected String country;

    public String getCountry() {
        return country;
    }

    public void setCountry(String country) {
        countrySpecified = true;
        this.country = country;
    }

    protected boolean countrySpecified;

    public boolean isCountrySpecified() {
        return countrySpecified;
    }

    public void unsetCountry() {
        country = null;
        countrySpecified = false;
    }

    /**
     * The date an invoice was created.
     */
    @ApiProperty(canBeNullOrNotSet = true)
    protected GregorianCalendar createDate;

    public GregorianCalendar getCreateDate() {
        return createDate;
    }

    public void setCreateDate(GregorianCalendar createDate) {
        createDateSpecified = true;
        this.createDate = createDate;
    }

    protected boolean createDateSpecified;

    public boolean isCreateDateSpecified() {
        return createDateSpecified;
    }

    public void unsetCreateDate() {
        createDate = null;
        createDateSpecified = false;
    }

    @ApiProperty(canBeNullOrNotSet = true)
    protected Boolean documentsGeneratedFlag;

    public Boolean getDocumentsGeneratedFlag() {
        return documentsGeneratedFlag;
    }

    public void setDocumentsGeneratedFlag(Boolean documentsGeneratedFlag) {
        documentsGeneratedFlagSpecified = true;
        this.documentsGeneratedFlag = documentsGeneratedFlag;
    }

    protected boolean documentsGeneratedFlagSpecified;

    public boolean isDocumentsGeneratedFlagSpecified() {
        return documentsGeneratedFlagSpecified;
    }

    public void unsetDocumentsGeneratedFlag() {
        documentsGeneratedFlag = null;
        documentsGeneratedFlagSpecified = false;
    }

    /**
     * The email address belonging to an account at the time an invoice is created.
     */
    @ApiProperty(canBeNullOrNotSet = true)
    protected String email;

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        emailSpecified = true;
        this.email = email;
    }

    protected boolean emailSpecified;

    public boolean isEmailSpecified() {
        return emailSpecified;
    }

    public void unsetEmail() {
        email = null;
        emailSpecified = false;
    }

    /**
     * An SoftLayer account's balance at the time an invoice is closed. This value is measured in US Dollar ($USD) currency.
     */
    @ApiProperty(canBeNullOrNotSet = true)
    protected BigDecimal endingBalance;

    public BigDecimal getEndingBalance() {
        return endingBalance;
    }

    public void setEndingBalance(BigDecimal endingBalance) {
        endingBalanceSpecified = true;
        this.endingBalance = endingBalance;
    }

    protected boolean endingBalanceSpecified;

    public boolean isEndingBalanceSpecified() {
        return endingBalanceSpecified;
    }

    public void unsetEndingBalance() {
        endingBalance = null;
        endingBalanceSpecified = false;
    }

    /**
     * The fax telephone number belonging to an account at the time an invoice is created.
     */
    @ApiProperty(canBeNullOrNotSet = true)
    protected String faxPhone;

    public String getFaxPhone() {
        return faxPhone;
    }

    public void setFaxPhone(String faxPhone) {
        faxPhoneSpecified = true;
        this.faxPhone = faxPhone;
    }

    protected boolean faxPhoneSpecified;

    public boolean isFaxPhoneSpecified() {
        return faxPhoneSpecified;
    }

    public void unsetFaxPhone() {
        faxPhone = null;
        faxPhoneSpecified = false;
    }

    /**
     * The first name of the account holder at the time an invoice is created.
     */
    @ApiProperty(canBeNullOrNotSet = true)
    protected String firstName;

    public String getFirstName() {
        return firstName;
    }

    public void setFirstName(String firstName) {
        firstNameSpecified = true;
        this.firstName = firstName;
    }

    protected boolean firstNameSpecified;

    public boolean isFirstNameSpecified() {
        return firstNameSpecified;
    }

    public void unsetFirstName() {
        firstName = null;
        firstNameSpecified = false;
    }

    /**
     * An invoice's internal identifier.
     */
    @ApiProperty(canBeNullOrNotSet = true)
    protected Long id;

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        idSpecified = true;
        this.id = id;
    }

    protected boolean idSpecified;

    public boolean isIdSpecified() {
        return idSpecified;
    }

    public void unsetId() {
        id = null;
        idSpecified = false;
    }

    /**
     * The last name of the account holder at the time an invoice is created.
     */
    @ApiProperty(canBeNullOrNotSet = true)
    protected String lastName;

    public String getLastName() {
        return lastName;
    }

    public void setLastName(String lastName) {
        lastNameSpecified = true;
        this.lastName = lastName;
    }

    protected boolean lastNameSpecified;

    public boolean isLastNameSpecified() {
        return lastNameSpecified;
    }

    public void unsetLastName() {
        lastName = null;
        lastNameSpecified = false;
    }

    /**
     * The date an invoice was last modified.
     */
    @ApiProperty(canBeNullOrNotSet = true)
    protected GregorianCalendar modifyDate;

    public GregorianCalendar getModifyDate() {
        return modifyDate;
    }

    public void setModifyDate(GregorianCalendar modifyDate) {
        modifyDateSpecified = true;
        this.modifyDate = modifyDate;
    }

    protected boolean modifyDateSpecified;

    public boolean isModifyDateSpecified() {
        return modifyDateSpecified;
    }

    public void unsetModifyDate() {
        modifyDate = null;
        modifyDateSpecified = false;
    }

    /**
     * The telephone number belonging to an account at the time an invoice is created.
     */
    @ApiProperty(canBeNullOrNotSet = true)
    protected String officePhone;

    public String getOfficePhone() {
        return officePhone;
    }

    public void setOfficePhone(String officePhone) {
        officePhoneSpecified = true;
        this.officePhone = officePhone;
    }

    protected boolean officePhoneSpecified;

    public boolean isOfficePhoneSpecified() {
        return officePhoneSpecified;
    }

    public void unsetOfficePhone() {
        officePhone = null;
        officePhoneSpecified = false;
    }

    /**
     * The postal code portion of an address belonging to an account at the time an invoice is created.
     */
    @ApiProperty(canBeNullOrNotSet = true)
    protected String postalCode;

    public String getPostalCode() {
        return postalCode;
    }

    public void setPostalCode(String postalCode) {
        postalCodeSpecified = true;
        this.postalCode = postalCode;
    }

    protected boolean postalCodeSpecified;

    public boolean isPostalCodeSpecified() {
        return postalCodeSpecified;
    }

    public void unsetPostalCode() {
        postalCode = null;
        postalCodeSpecified = false;
    }

    @ApiProperty(canBeNullOrNotSet = true)
    protected String purchaseOrderNumber;

    public String getPurchaseOrderNumber() {
        return purchaseOrderNumber;
    }

    public void setPurchaseOrderNumber(String purchaseOrderNumber) {
        purchaseOrderNumberSpecified = true;
        this.purchaseOrderNumber = purchaseOrderNumber;
    }

    protected boolean purchaseOrderNumberSpecified;

    public boolean isPurchaseOrderNumberSpecified() {
        return purchaseOrderNumberSpecified;
    }

    public void unsetPurchaseOrderNumber() {
        purchaseOrderNumber = null;
        purchaseOrderNumberSpecified = false;
    }

    /**
     * An SoftLayer account's balance at the time an invoice is created. This value is measured in US Dollar ($USD) currency.
     */
    @ApiProperty(canBeNullOrNotSet = true)
    protected BigDecimal startingBalance;

    public BigDecimal getStartingBalance() {
        return startingBalance;
    }

    public void setStartingBalance(BigDecimal startingBalance) {
        startingBalanceSpecified = true;
        this.startingBalance = startingBalance;
    }

    protected boolean startingBalanceSpecified;

    public boolean isStartingBalanceSpecified() {
        return startingBalanceSpecified;
    }

    public void unsetStartingBalance() {
        startingBalance = null;
        startingBalanceSpecified = false;
    }

    /**
     * A two-letter abbreviation of the state portion of an address belonging to an account at the time an invoice is created. If the account that the invoice was generated for resides outside a province then this is set to "other".
     */
    @ApiProperty(canBeNullOrNotSet = true)
    protected String state;

    public String getState() {
        return state;
    }

    public void setState(String state) {
        stateSpecified = true;
        this.state = state;
    }

    protected boolean stateSpecified;

    public boolean isStateSpecified() {
        return stateSpecified;
    }

    public void unsetState() {
        state = null;
        stateSpecified = false;
    }

    /**
     * An invoice's status. The "OPEN" status means SoftLayer has not yet received payment for this invoice. "CLOSED" status means that SoftLayer has received payment and closed the invoice. The "CLOSED_FAILED" status code means SoftLayer closed the invoice without receiving a payment. Invoices are usually set to CLOSED_FAILED status in cases where customer accounts are terminated for non-payment. 
     */
    @ApiProperty(canBeNullOrNotSet = true)
    protected String statusCode;

    public String getStatusCode() {
        return statusCode;
    }

    public void setStatusCode(String statusCode) {
        statusCodeSpecified = true;
        this.statusCode = statusCode;
    }

    protected boolean statusCodeSpecified;

    public boolean isStatusCodeSpecified() {
        return statusCodeSpecified;
    }

    public void unsetStatusCode() {
        statusCode = null;
        statusCodeSpecified = false;
    }

    @ApiProperty(canBeNullOrNotSet = true)
    protected Long taxStatusId;

    public Long getTaxStatusId() {
        return taxStatusId;
    }

    public void setTaxStatusId(Long taxStatusId) {
        taxStatusIdSpecified = true;
        this.taxStatusId = taxStatusId;
    }

    protected boolean taxStatusIdSpecified;

    public boolean isTaxStatusIdSpecified() {
        return taxStatusIdSpecified;
    }

    public void unsetTaxStatusId() {
        taxStatusId = null;
        taxStatusIdSpecified = false;
    }

    @ApiProperty(canBeNullOrNotSet = true)
    protected Long taxTypeId;

    public Long getTaxTypeId() {
        return taxTypeId;
    }

    public void setTaxTypeId(Long taxTypeId) {
        taxTypeIdSpecified = true;
        this.taxTypeId = taxTypeId;
    }

    protected boolean taxTypeIdSpecified;

    public boolean isTaxTypeIdSpecified() {
        return taxTypeIdSpecified;
    }

    public void unsetTaxTypeId() {
        taxTypeId = null;
        taxTypeIdSpecified = false;
    }

    /**
     * An invoice's type. SoftLayer invoices and service credits are differentiated by their type. The "NEW" type code signifies an invoice for new service. A SoftLayer customer's first invoice has the NEW type code. "RECURRING" invoices are generated on a SoftLayer customer's anniversary billing date for monthly services. "ONE-TIME-CHARGE" invoices are generated when one-time charges are applied to an account. "CREDIT" invoices are generated whenever SoftLayer applies a credit against an account's balance. There are two special types of service credits. "REFUND" type credits are applied against a customer's account balance along with the receivables on their account. "MANUAL_PAYMENT_CREDIT" invoice credits are generated whenever a customer makes an unscheduled payment. 
     */
    @ApiProperty(canBeNullOrNotSet = true)
    protected String typeCode;

    public String getTypeCode() {
        return typeCode;
    }

    public void setTypeCode(String typeCode) {
        typeCodeSpecified = true;
        this.typeCode = typeCode;
    }

    protected boolean typeCodeSpecified;

    public boolean isTypeCodeSpecified() {
        return typeCodeSpecified;
    }

    public void unsetTypeCode() {
        typeCode = null;
        typeCodeSpecified = false;
    }

    /**
     * A count of a list of top-level invoice items that are on the currently pending invoice.
     */
    @ApiProperty
    protected Long invoiceTopLevelItemCount;

    public Long getInvoiceTopLevelItemCount() {
        return invoiceTopLevelItemCount;
    }

    public void setInvoiceTopLevelItemCount(Long invoiceTopLevelItemCount) {
        this.invoiceTopLevelItemCount = invoiceTopLevelItemCount;
    }

    /**
     * A count of the items that belong to this invoice.
     */
    @ApiProperty
    protected Long itemCount;

    public Long getItemCount() {
        return itemCount;
    }

    public void setItemCount(Long itemCount) {
        this.itemCount = itemCount;
    }

    /**
     * A count of the payments for the invoice.
     */
    @ApiProperty
    protected Long paymentCount;

    public Long getPaymentCount() {
        return paymentCount;
    }

    public void setPaymentCount(Long paymentCount) {
        this.paymentCount = paymentCount;
    }

    /**
     * A count of this is the set of tax information for any tax calculation for this invoice. Note that not all of these are necessarily official, so use the taxInfo key to get the final information.
     */
    @ApiProperty
    protected Long taxInfoHistoryCount;

    public Long getTaxInfoHistoryCount() {
        return taxInfoHistoryCount;
    }

    public void setTaxInfoHistoryCount(Long taxInfoHistoryCount) {
        this.taxInfoHistoryCount = taxInfoHistoryCount;
    }

    public Service asService(ApiClient client) {
        return service(client, id);
    }

    public static Service service(ApiClient client) {
        return client.createService(Service.class, null);
    }

    public static Service service(ApiClient client, Long id) {
        return client.createService(Service.class, id == null ? null : id.toString());
    }

    /**
     * The SoftLayer_Billing_Invoice service controls the invoices that are created whenever a SoftLayer customer's account balance changes. Invoices exist in three states: 
* *'''OPEN''': Invoices which have not been paid yet. Invoices are created in the OPEN state.
* *'''CLOSED''': Invoices that SoftLayer has received payment for.
* *'''CLOSED_FAILED''': Invoices which were closed but were not paid for. Customers who are terminated for non-payment typically have invoices in this state.
*
*
* Once an invoice is paid it moves from OPEN to CLOSED state. Invoices are created under varying types, which are defined in the type property of the [[SoftLayer_Invoice (type)|SoftLayer_Invoice data type]]. Invoices are created under one of the following type categories:
* *'''NEW''': An invoice for new service. A SoftLayer customer's first invoice is of the NEW type.
* *'''RECURRING''': Invoices that are generated on a SoftLayer customer's anniversary billing date for monthly services.
* *'''ONE-TIME-CHARGE''': Invoices that are generated when one-time charges are applied to an account for fees incurred from products or services procured outside of the standard purchasing processes.
* *'''CREDIT''': Invoices that are generated whenever SoftLayer applies a credit against an account's balance.
* *'''REFUND''': Account credits that are applied against a customer's account balance along with the receivables on their account. REFUND type invoices are generated whenever a customer receives a service credit on their account balance and has their invoice items changed due to the credit.
* *'''MANUAL_PAYMENT_CREDIT''': Invoice credits that are generated whenever a customer makes an manual payment.
*
*
* Invoices are created with contact information duplicated from the [[SoftLayer_Account (type)|SoftLayer_Account data type]]. We do this in order to maintain a history of an account's contact information as invoices are generated. Likewise each invoice record keeps track of an account's balance as the invoice is opened and closed.
*
* Query the [[SoftLayer_Account]] service to get a list of invoices for your account. * * @see SoftLayer_Billing_Invoice */ @com.softlayer.api.annotation.ApiService("SoftLayer_Billing_Invoice") public static interface Service extends com.softlayer.api.Service { public ServiceAsync asAsync(); public Mask withNewMask(); public Mask withMask(); public void setMask(Mask mask); /** * Create a transaction to email PDF and/or Excel invoices to the requesting user's email address. You must have a PDF reader installed in order to view these files. * * @see SoftLayer_Billing_Invoice::emailInvoices */ @ApiMethod public Void emailInvoices(Email options); /** * Retrieve a Microsoft Excel spreadsheet of a SoftLayer invoice. You must have a Microsoft Excel reader installed in order to view these invoice files. * * @see SoftLayer_Billing_Invoice::getExcel */ @ApiMethod(instanceRequired = true) public byte[] getExcel(); /** * getObject retrieves the SoftLayer_Billing_Invoice object whose ID number corresponds to the ID number of the init parameter passed to the SoftLayer_Billing_Invoice service. You can only retrieve invoices that are assigned to your portal user's account. * * @see SoftLayer_Billing_Invoice::getObject */ @ApiMethod(instanceRequired = true) public Invoice getObject(); /** * Retrieve a PDF record of a SoftLayer invoice. SoftLayer keeps PDF records of all closed invoices for customer retrieval from the portal and API. You must have a PDF reader installed in order to view these invoice files. * * @see SoftLayer_Billing_Invoice::getPdf */ @ApiMethod(instanceRequired = true) public byte[] getPdf(); /** * Retrieve a PDF record of a SoftLayer detailed invoice summary. SoftLayer keeps PDF records of all closed invoices for customer retrieval from the portal and API. You must have a PDF reader installed in order to view these files. * * @see SoftLayer_Billing_Invoice::getPdfDetailed */ @ApiMethod(instanceRequired = true) public byte[] getPdfDetailed(); /** * @see SoftLayer_Billing_Invoice::getPdfDetailedFilename */ @ApiMethod(instanceRequired = true) public String getPdfDetailedFilename(); /** * Retrieve the size of a PDF record of a SoftLayer invoice. SoftLayer keeps PDF records of all closed invoices for customer retrieval from the portal and API. * * @see SoftLayer_Billing_Invoice::getPdfFileSize */ @ApiMethod(instanceRequired = true) public Long getPdfFileSize(); /** * @see SoftLayer_Billing_Invoice::getPdfFilename */ @ApiMethod(instanceRequired = true) public String getPdfFilename(); /** * Retrieve a Microsoft Excel record of a SoftLayer invoice. SoftLayer generates Microsoft Excel records of all closed invoices for customer retrieval from the portal and API. You must have a Microsoft Excel reader installed in order to view these invoice files. * * @see SoftLayer_Billing_Invoice::getPreliminaryExcel */ @ApiMethod(instanceRequired = true) public byte[] getPreliminaryExcel(); /** * Retrieve a PDF record of a SoftLayer invoice. SoftLayer keeps PDF records of all closed invoices for customer retrieval from the portal and API. You must have a PDF reader installed in order to view these invoice files. * * @see SoftLayer_Billing_Invoice::getPreliminaryPdf */ @ApiMethod(instanceRequired = true) public byte[] getPreliminaryPdf(); /** * Retrieve a PDF record of the detailed version of a SoftLayer invoice. SoftLayer keeps PDF records of all closed invoices for customer retrieval from the portal and API. * * @see SoftLayer_Billing_Invoice::getPreliminaryPdfDetailed */ @ApiMethod(instanceRequired = true) public byte[] getPreliminaryPdfDetailed(); /** * @see SoftLayer_Billing_Invoice::getXlsFilename */ @ApiMethod(instanceRequired = true) public String getXlsFilename(); /** * @see SoftLayer_Billing_Invoice::getZeroFeeItemCounts */ @ApiMethod(instanceRequired = true) public List getZeroFeeItemCounts(); /** * The account that an invoice belongs to. * * @see SoftLayer_Billing_Invoice::getAccount */ @ApiMethod(instanceRequired = true) public Account getAccount(); /** * This is the amount of this invoice. * * @see SoftLayer_Billing_Invoice::getAmount */ @ApiMethod(instanceRequired = true) public BigDecimal getAmount(); /** * @see SoftLayer_Billing_Invoice::getBrandAtInvoiceCreation */ @ApiMethod(instanceRequired = true) public Brand getBrandAtInvoiceCreation(); /** * A flag that will reflect whether the detailed version of the pdf has been generated. * * @see SoftLayer_Billing_Invoice::getDetailedPdfGeneratedFlag */ @ApiMethod(instanceRequired = true) public Boolean getDetailedPdfGeneratedFlag(); /** * A list of top-level invoice items that are on the currently pending invoice. * * @see SoftLayer_Billing_Invoice::getInvoiceTopLevelItems */ @ApiMethod(instanceRequired = true) public List getInvoiceTopLevelItems(); /** * The total amount of this invoice. * * @see SoftLayer_Billing_Invoice::getInvoiceTotalAmount */ @ApiMethod(instanceRequired = true) public BigDecimal getInvoiceTotalAmount(); /** * The total one-time charges for this invoice. This is the sum of one-time charges + setup fees + labor fees. This does not include taxes. * * @see SoftLayer_Billing_Invoice::getInvoiceTotalOneTimeAmount */ @ApiMethod(instanceRequired = true) public BigDecimal getInvoiceTotalOneTimeAmount(); /** * A sum of all the taxes related to one time charges for this invoice. * * @see SoftLayer_Billing_Invoice::getInvoiceTotalOneTimeTaxAmount */ @ApiMethod(instanceRequired = true) public BigDecimal getInvoiceTotalOneTimeTaxAmount(); /** * The total amount of this invoice. This does not include taxes. * * @see SoftLayer_Billing_Invoice::getInvoiceTotalPreTaxAmount */ @ApiMethod(instanceRequired = true) public BigDecimal getInvoiceTotalPreTaxAmount(); /** * The total Recurring amount of this invoice. This amount does not include taxes or one time charges. * * @see SoftLayer_Billing_Invoice::getInvoiceTotalRecurringAmount */ @ApiMethod(instanceRequired = true) public BigDecimal getInvoiceTotalRecurringAmount(); /** * The total amount of the recurring taxes on this invoice. * * @see SoftLayer_Billing_Invoice::getInvoiceTotalRecurringTaxAmount */ @ApiMethod(instanceRequired = true) public BigDecimal getInvoiceTotalRecurringTaxAmount(); /** * The items that belong to this invoice. * * @see SoftLayer_Billing_Invoice::getItems */ @ApiMethod(instanceRequired = true) public List getItems(); /** * This is the total payment made on this invoice. * * @see SoftLayer_Billing_Invoice::getPayment */ @ApiMethod(instanceRequired = true) public BigDecimal getPayment(); /** * The payments for the invoice. * * @see SoftLayer_Billing_Invoice::getPayments */ @ApiMethod(instanceRequired = true) public List getPayments(); /** * This is the seller's tax registration. * * @see SoftLayer_Billing_Invoice::getSellerRegistration */ @ApiMethod(instanceRequired = true) public String getSellerRegistration(); /** * This is the tax information that applies to tax auditing. This is the official tax record for this invoice. * * @see SoftLayer_Billing_Invoice::getTaxInfo */ @ApiMethod(instanceRequired = true) public Info getTaxInfo(); /** * This is the set of tax information for any tax calculation for this invoice. Note that not all of these are necessarily official, so use the taxInfo key to get the final information. * * @see SoftLayer_Billing_Invoice::getTaxInfoHistory */ @ApiMethod(instanceRequired = true) public List getTaxInfoHistory(); /** * This is a message explaining the tax treatment for this invoice. * * @see SoftLayer_Billing_Invoice::getTaxMessage */ @ApiMethod(instanceRequired = true) public String getTaxMessage(); /** * This is the strategy used to calculate tax on this invoice. * * @see SoftLayer_Billing_Invoice::getTaxType */ @ApiMethod(instanceRequired = true) public Type getTaxType(); } public static interface ServiceAsync extends com.softlayer.api.ServiceAsync { public Mask withNewMask(); public Mask withMask(); public void setMask(Mask mask); /** * Async version of {@link Service#emailInvoices} */ public Future emailInvoices(Email options); public Future emailInvoices(Email options, ResponseHandler callback); /** * Async version of {@link Service#getExcel} */ public Future getExcel(); public Future getExcel(ResponseHandler callback); /** * Async version of {@link Service#getObject} */ public Future getObject(); public Future getObject(ResponseHandler callback); /** * Async version of {@link Service#getPdf} */ public Future getPdf(); public Future getPdf(ResponseHandler callback); /** * Async version of {@link Service#getPdfDetailed} */ public Future getPdfDetailed(); public Future getPdfDetailed(ResponseHandler callback); /** * Async version of {@link Service#getPdfDetailedFilename} */ public Future getPdfDetailedFilename(); public Future getPdfDetailedFilename(ResponseHandler callback); /** * Async version of {@link Service#getPdfFileSize} */ public Future getPdfFileSize(); public Future getPdfFileSize(ResponseHandler callback); /** * Async version of {@link Service#getPdfFilename} */ public Future getPdfFilename(); public Future getPdfFilename(ResponseHandler callback); /** * Async version of {@link Service#getPreliminaryExcel} */ public Future getPreliminaryExcel(); public Future getPreliminaryExcel(ResponseHandler callback); /** * Async version of {@link Service#getPreliminaryPdf} */ public Future getPreliminaryPdf(); public Future getPreliminaryPdf(ResponseHandler callback); /** * Async version of {@link Service#getPreliminaryPdfDetailed} */ public Future getPreliminaryPdfDetailed(); public Future getPreliminaryPdfDetailed(ResponseHandler callback); /** * Async version of {@link Service#getXlsFilename} */ public Future getXlsFilename(); public Future getXlsFilename(ResponseHandler callback); /** * Async version of {@link Service#getZeroFeeItemCounts} */ public Future> getZeroFeeItemCounts(); public Future getZeroFeeItemCounts(ResponseHandler> callback); /** * Async version of {@link Service#getAccount} */ public Future getAccount(); /** * Async callback version of {@link Service#getAccount} */ public Future getAccount(ResponseHandler callback); /** * Async version of {@link Service#getAmount} */ public Future getAmount(); /** * Async callback version of {@link Service#getAmount} */ public Future getAmount(ResponseHandler callback); /** * Async version of {@link Service#getBrandAtInvoiceCreation} */ public Future getBrandAtInvoiceCreation(); /** * Async callback version of {@link Service#getBrandAtInvoiceCreation} */ public Future getBrandAtInvoiceCreation(ResponseHandler callback); /** * Async version of {@link Service#getDetailedPdfGeneratedFlag} */ public Future getDetailedPdfGeneratedFlag(); /** * Async callback version of {@link Service#getDetailedPdfGeneratedFlag} */ public Future getDetailedPdfGeneratedFlag(ResponseHandler callback); /** * Async version of {@link Service#getInvoiceTopLevelItems} */ public Future> getInvoiceTopLevelItems(); /** * Async callback version of {@link Service#getInvoiceTopLevelItems} */ public Future getInvoiceTopLevelItems(ResponseHandler> callback); /** * Async version of {@link Service#getInvoiceTotalAmount} */ public Future getInvoiceTotalAmount(); /** * Async callback version of {@link Service#getInvoiceTotalAmount} */ public Future getInvoiceTotalAmount(ResponseHandler callback); /** * Async version of {@link Service#getInvoiceTotalOneTimeAmount} */ public Future getInvoiceTotalOneTimeAmount(); /** * Async callback version of {@link Service#getInvoiceTotalOneTimeAmount} */ public Future getInvoiceTotalOneTimeAmount(ResponseHandler callback); /** * Async version of {@link Service#getInvoiceTotalOneTimeTaxAmount} */ public Future getInvoiceTotalOneTimeTaxAmount(); /** * Async callback version of {@link Service#getInvoiceTotalOneTimeTaxAmount} */ public Future getInvoiceTotalOneTimeTaxAmount(ResponseHandler callback); /** * Async version of {@link Service#getInvoiceTotalPreTaxAmount} */ public Future getInvoiceTotalPreTaxAmount(); /** * Async callback version of {@link Service#getInvoiceTotalPreTaxAmount} */ public Future getInvoiceTotalPreTaxAmount(ResponseHandler callback); /** * Async version of {@link Service#getInvoiceTotalRecurringAmount} */ public Future getInvoiceTotalRecurringAmount(); /** * Async callback version of {@link Service#getInvoiceTotalRecurringAmount} */ public Future getInvoiceTotalRecurringAmount(ResponseHandler callback); /** * Async version of {@link Service#getInvoiceTotalRecurringTaxAmount} */ public Future getInvoiceTotalRecurringTaxAmount(); /** * Async callback version of {@link Service#getInvoiceTotalRecurringTaxAmount} */ public Future getInvoiceTotalRecurringTaxAmount(ResponseHandler callback); /** * Async version of {@link Service#getItems} */ public Future> getItems(); /** * Async callback version of {@link Service#getItems} */ public Future getItems(ResponseHandler> callback); /** * Async version of {@link Service#getPayment} */ public Future getPayment(); /** * Async callback version of {@link Service#getPayment} */ public Future getPayment(ResponseHandler callback); /** * Async version of {@link Service#getPayments} */ public Future> getPayments(); /** * Async callback version of {@link Service#getPayments} */ public Future getPayments(ResponseHandler> callback); /** * Async version of {@link Service#getSellerRegistration} */ public Future getSellerRegistration(); /** * Async callback version of {@link Service#getSellerRegistration} */ public Future getSellerRegistration(ResponseHandler callback); /** * Async version of {@link Service#getTaxInfo} */ public Future getTaxInfo(); /** * Async callback version of {@link Service#getTaxInfo} */ public Future getTaxInfo(ResponseHandler callback); /** * Async version of {@link Service#getTaxInfoHistory} */ public Future> getTaxInfoHistory(); /** * Async callback version of {@link Service#getTaxInfoHistory} */ public Future getTaxInfoHistory(ResponseHandler> callback); /** * Async version of {@link Service#getTaxMessage} */ public Future getTaxMessage(); /** * Async callback version of {@link Service#getTaxMessage} */ public Future getTaxMessage(ResponseHandler callback); /** * Async version of {@link Service#getTaxType} */ public Future getTaxType(); /** * Async callback version of {@link Service#getTaxType} */ public Future getTaxType(ResponseHandler callback); } public static class Mask extends com.softlayer.api.service.Entity.Mask { public com.softlayer.api.service.Account.Mask account() { return withSubMask("account", com.softlayer.api.service.Account.Mask.class); } public Mask amount() { withLocalProperty("amount"); return this; } public com.softlayer.api.service.Brand.Mask brandAtInvoiceCreation() { return withSubMask("brandAtInvoiceCreation", com.softlayer.api.service.Brand.Mask.class); } public Mask detailedPdfGeneratedFlag() { withLocalProperty("detailedPdfGeneratedFlag"); return this; } public com.softlayer.api.service.billing.invoice.Item.Mask invoiceTopLevelItems() { return withSubMask("invoiceTopLevelItems", com.softlayer.api.service.billing.invoice.Item.Mask.class); } public Mask invoiceTotalAmount() { withLocalProperty("invoiceTotalAmount"); return this; } public Mask invoiceTotalOneTimeAmount() { withLocalProperty("invoiceTotalOneTimeAmount"); return this; } public Mask invoiceTotalOneTimeTaxAmount() { withLocalProperty("invoiceTotalOneTimeTaxAmount"); return this; } public Mask invoiceTotalPreTaxAmount() { withLocalProperty("invoiceTotalPreTaxAmount"); return this; } public Mask invoiceTotalRecurringAmount() { withLocalProperty("invoiceTotalRecurringAmount"); return this; } public Mask invoiceTotalRecurringTaxAmount() { withLocalProperty("invoiceTotalRecurringTaxAmount"); return this; } public com.softlayer.api.service.billing.invoice.Item.Mask items() { return withSubMask("items", com.softlayer.api.service.billing.invoice.Item.Mask.class); } public Mask payment() { withLocalProperty("payment"); return this; } public com.softlayer.api.service.billing.invoice.receivable.Payment.Mask payments() { return withSubMask("payments", com.softlayer.api.service.billing.invoice.receivable.Payment.Mask.class); } public Mask sellerRegistration() { withLocalProperty("sellerRegistration"); return this; } public com.softlayer.api.service.billing.invoice.tax.Info.Mask taxInfo() { return withSubMask("taxInfo", com.softlayer.api.service.billing.invoice.tax.Info.Mask.class); } public com.softlayer.api.service.billing.invoice.tax.Info.Mask taxInfoHistory() { return withSubMask("taxInfoHistory", com.softlayer.api.service.billing.invoice.tax.Info.Mask.class); } public Mask taxMessage() { withLocalProperty("taxMessage"); return this; } public com.softlayer.api.service.billing.invoice.tax.Type.Mask taxType() { return withSubMask("taxType", com.softlayer.api.service.billing.invoice.tax.Type.Mask.class); } public Mask accountId() { withLocalProperty("accountId"); return this; } public Mask address1() { withLocalProperty("address1"); return this; } public Mask address2() { withLocalProperty("address2"); return this; } public Mask city() { withLocalProperty("city"); return this; } public Mask claimedTaxExemptTxFlag() { withLocalProperty("claimedTaxExemptTxFlag"); return this; } public Mask closedDate() { withLocalProperty("closedDate"); return this; } public Mask companyName() { withLocalProperty("companyName"); return this; } public Mask country() { withLocalProperty("country"); return this; } public Mask createDate() { withLocalProperty("createDate"); return this; } public Mask documentsGeneratedFlag() { withLocalProperty("documentsGeneratedFlag"); return this; } public Mask email() { withLocalProperty("email"); return this; } public Mask endingBalance() { withLocalProperty("endingBalance"); return this; } public Mask faxPhone() { withLocalProperty("faxPhone"); return this; } public Mask firstName() { withLocalProperty("firstName"); return this; } public Mask id() { withLocalProperty("id"); return this; } public Mask lastName() { withLocalProperty("lastName"); return this; } public Mask modifyDate() { withLocalProperty("modifyDate"); return this; } public Mask officePhone() { withLocalProperty("officePhone"); return this; } public Mask postalCode() { withLocalProperty("postalCode"); return this; } public Mask purchaseOrderNumber() { withLocalProperty("purchaseOrderNumber"); return this; } public Mask startingBalance() { withLocalProperty("startingBalance"); return this; } public Mask state() { withLocalProperty("state"); return this; } public Mask statusCode() { withLocalProperty("statusCode"); return this; } public Mask taxStatusId() { withLocalProperty("taxStatusId"); return this; } public Mask taxTypeId() { withLocalProperty("taxTypeId"); return this; } public Mask typeCode() { withLocalProperty("typeCode"); return this; } public Mask invoiceTopLevelItemCount() { withLocalProperty("invoiceTopLevelItemCount"); return this; } public Mask itemCount() { withLocalProperty("itemCount"); return this; } public Mask paymentCount() { withLocalProperty("paymentCount"); return this; } public Mask taxInfoHistoryCount() { withLocalProperty("taxInfoHistoryCount"); return this; } } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy