Published Business Service Variable Names
The variable name should clarify the type of data in the field or compound. For example, if multiple entity type objects exist, the class called Entity would be the data type, but ProcessPurchaseOrder would contain objects of type Entity called supplier and shipTo. In this example, the Entity class can be reused from the EntityProcessor utility business service.
In the following code sample, the AddAddressBook value object has three top-level field names and contains an entityAddress, which is subsequently made up of an entity with three fields and an address with ten fields:
public class AddAddressBook extends ValueObject implements Serializable{ private EntityAddress entityAddress = new EntityAddress(); private String entityName; private String entityTypeCode; private String version; .... } public class EntityAddress extends ValueObject implements Serializable { private Entity entity = new Entity(); private Address address = new Address(); .... } public class Address extends ValueObject implements Serializable{ private String mailingName; private String addressLine1; private String addressLine2; private String addressLine3; private String addressLine4; private String city; private String countyCode; private String stateCode; private String postalCode; private String countryCode; .... } public class Entity extends ValueObject implements Serializable{ private Integer entityId; private String entityLongId; private String entityTaxId; .... }