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

au.org.consumerdatastandards.api.common.models.ResponseCommonCustomerData Maven / Gradle / Ivy

Go to download

This artefact describes the Consumer Data Standards using Java classes and annotations in a way suitable for automatic generation of Open API Specification, documentation, Server Stub, Client Libraries and Reference Test.

There is a newer version: 1.1.1
Show newest version
package au.org.consumerdatastandards.api.common.models;

import au.org.consumerdatastandards.support.data.*;

@DataDefinition(
    referenced = false
)
public class ResponseCommonCustomerData {

    public enum CustomerUType {
        person,
        organisation
    }

    @Property(
        description = "The type of customer object that is present",
        required = true
    )
    CustomerUType customerUType;

    @Property(
        requiredIf = { @Condition(propertyName = "customerUType", values = {"person"}) },
        nullIf = { @Condition(propertyName = "customerUType", values = {"organisation"}) }
    )
    CommonPerson person;

    @Property(
        requiredIf = { @Condition(propertyName = "customerUType", values = {"organisation"}) },
        nullIf = { @Condition(propertyName = "customerUType", values = {"person"}) }
    )
    CommonOrganisation organisation;
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy