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

com.softlayer.api.service.account.Contact Maven / Gradle / Ivy

The newest version!
package com.softlayer.api.service.account;

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.Entity;
import com.softlayer.api.service.account.contact.Type;
import java.util.GregorianCalendar;
import java.util.List;
import java.util.concurrent.Future;

/**
 * @see SoftLayer_Account_Contact
 */
@ApiType("SoftLayer_Account_Contact")
public class Contact extends Entity {

    @ApiProperty
    protected Account account;

    public Account getAccount() {
        return account;
    }

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

    @ApiProperty
    protected Type type;

    public Type getType() {
        return type;
    }

    public void setType(Type type) {
        this.type = type;
    }

    @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;
    }

    @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;
    }

    @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;
    }

    @ApiProperty(canBeNullOrNotSet = true)
    protected String alternatePhone;

    public String getAlternatePhone() {
        return alternatePhone;
    }

    public void setAlternatePhone(String alternatePhone) {
        alternatePhoneSpecified = true;
        this.alternatePhone = alternatePhone;
    }

    protected boolean alternatePhoneSpecified;

    public boolean isAlternatePhoneSpecified() {
        return alternatePhoneSpecified;
    }

    public void unsetAlternatePhone() {
        alternatePhone = null;
        alternatePhoneSpecified = false;
    }

    @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;
    }

    @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;
    }

    @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;
    }

    @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 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;
    }

    @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;
    }

    @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;
    }

    @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;
    }

    @ApiProperty(canBeNullOrNotSet = true)
    protected String jobTitle;

    public String getJobTitle() {
        return jobTitle;
    }

    public void setJobTitle(String jobTitle) {
        jobTitleSpecified = true;
        this.jobTitle = jobTitle;
    }

    protected boolean jobTitleSpecified;

    public boolean isJobTitleSpecified() {
        return jobTitleSpecified;
    }

    public void unsetJobTitle() {
        jobTitle = null;
        jobTitleSpecified = false;
    }

    @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;
    }

    @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;
    }

    @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;
    }

    @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 profileName;

    public String getProfileName() {
        return profileName;
    }

    public void setProfileName(String profileName) {
        profileNameSpecified = true;
        this.profileName = profileName;
    }

    protected boolean profileNameSpecified;

    public boolean isProfileNameSpecified() {
        return profileNameSpecified;
    }

    public void unsetProfileName() {
        profileName = null;
        profileNameSpecified = false;
    }

    @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;
    }

    @ApiProperty(canBeNullOrNotSet = true)
    protected Long typeId;

    public Long getTypeId() {
        return typeId;
    }

    public void setTypeId(Long typeId) {
        typeIdSpecified = true;
        this.typeId = typeId;
    }

    protected boolean typeIdSpecified;

    public boolean isTypeIdSpecified() {
        return typeIdSpecified;
    }

    public void unsetTypeId() {
        typeId = null;
        typeIdSpecified = false;
    }

    @ApiProperty(canBeNullOrNotSet = true)
    protected String url;

    public String getUrl() {
        return url;
    }

    public void setUrl(String url) {
        urlSpecified = true;
        this.url = url;
    }

    protected boolean urlSpecified;

    public boolean isUrlSpecified() {
        return urlSpecified;
    }

    public void unsetUrl() {
        url = null;
        urlSpecified = false;
    }

    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());
    }

    /**
     * @see SoftLayer_Account_Contact
     */
    @com.softlayer.api.annotation.ApiService("SoftLayer_Account_Contact")
    public static interface Service extends com.softlayer.api.Service {

        public ServiceAsync asAsync();
        public Mask withNewMask();
        public Mask withMask();
        public void setMask(Mask mask);

        /**
         * <SoftLayer_Account_Contact::createComplianceReportRequestorContact
         */
        @ApiMethod
        public Contact createComplianceReportRequestorContact(Contact requestorTemplate);

        /**
         * This method creates an account contact. The accountId is fixed, other properties can be set during creation. The typeId indicates the SoftLayer_Account_Contact_Type for the contact. This method returns the SoftLayer_Account_Contact object that is created. 
         *
         * @see SoftLayer_Account_Contact::createObject
         */
        @ApiMethod
        public Contact createObject(Contact templateObject);

        /**
         * deleteObject permanently removes an account contact 
         *
         * @see SoftLayer_Account_Contact::deleteObject
         */
        @ApiMethod(instanceRequired = true)
        public Boolean deleteObject();

        /**
         * This method allows you to modify an account contact. Only master users are permitted to modify an account contact. 
         *
         * @see SoftLayer_Account_Contact::editObject
         */
        @ApiMethod(instanceRequired = true)
        public Boolean editObject(Contact templateObject);

        /**
         * This method will return an array of SoftLayer_Account_Contact_Type objects which can be used when creating or editing an account contact. 
         *
         * @see SoftLayer_Account_Contact::getAllContactTypes
         */
        @ApiMethod
        public List getAllContactTypes();

        /**
         * @see SoftLayer_Account_Contact::getObject
         */
        @ApiMethod(instanceRequired = true)
        public Contact getObject();

        /**
         * @see SoftLayer_Account_Contact::getAccount
         */
        @ApiMethod(instanceRequired = true)
        public Account getAccount();

        /**
         * @see SoftLayer_Account_Contact::getType
         */
        @ApiMethod(instanceRequired = true)
        public Type getType();

    }

    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#createComplianceReportRequestorContact}
         */
        public Future createComplianceReportRequestorContact(Contact requestorTemplate);

        public Future createComplianceReportRequestorContact(Contact requestorTemplate, ResponseHandler callback);

        /**
         * Async version of {@link Service#createObject}
         */
        public Future createObject(Contact templateObject);

        public Future createObject(Contact templateObject, ResponseHandler callback);

        /**
         * Async version of {@link Service#deleteObject}
         */
        public Future deleteObject();

        public Future deleteObject(ResponseHandler callback);

        /**
         * Async version of {@link Service#editObject}
         */
        public Future editObject(Contact templateObject);

        public Future editObject(Contact templateObject, ResponseHandler callback);

        /**
         * Async version of {@link Service#getAllContactTypes}
         */
        public Future> getAllContactTypes();

        public Future getAllContactTypes(ResponseHandler> callback);

        /**
         * Async version of {@link Service#getObject}
         */
        public Future getObject();

        public Future getObject(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#getType}
         */
        public Future getType();

        /**
         * Async callback version of {@link Service#getType}
         */
        public Future getType(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 com.softlayer.api.service.account.contact.Type.Mask type() {
            return withSubMask("type", com.softlayer.api.service.account.contact.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 alternatePhone() {
            withLocalProperty("alternatePhone");
            return this;
        }

        public Mask city() {
            withLocalProperty("city");
            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 email() {
            withLocalProperty("email");
            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 jobTitle() {
            withLocalProperty("jobTitle");
            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 profileName() {
            withLocalProperty("profileName");
            return this;
        }

        public Mask state() {
            withLocalProperty("state");
            return this;
        }

        public Mask typeId() {
            withLocalProperty("typeId");
            return this;
        }

        public Mask url() {
            withLocalProperty("url");
            return this;
        }

    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy