Type Naming Rules

In Universe products, interface methods of services are most often formalized by accepting objects similar in design to http://www.corej2eepatterns.com/ContextObject.html and known as Request Context.

They have a changeable part (stack data) and an unchangeable part (user input).

The return types of such methods must be formatted as composite DTOs. There is a mandatory naming scheme for them as [Type/Subsystem] / [Action] / Context for the input parameters and [Type/Subsystem] / [Action] / Result for the result. Example:

/**
* Loads draft object(s) by supplied criteria.
* @param ctx the context
* @return draft object
*/
DraftGetResult get(DraftGetContext ctx);
/**
* Initiates a draft creation or update for a subject.
* @param ctx the context
* @return result
*/
DraftUpsertResult upsert(DraftUpsertContext ctx);
/**
* Removes a draft object and all its descendants.
* @param ctx the context
* @return true, is successful, false otherwise
*/
DraftRemoveResult remove(DraftRemoveContext ctx);
/**
* Triggers publication process for a draft object.
* @param ctx the context
* @return result
*/
DraftPublishResult publish(DraftPublishContext ctx);