public interface SubjectInfo
Provides an object representation of a subject request. This also provides protection in the case where the subject is changed as the implementation can be added to in a single place.
Parsing of a subject into a SubjectInfo instance should be achieve by
using a SubjectParser
.
Example:
Consider the subject:
/FX/GBPUSD/SPOT/GBP
The following class would be used to represent the subject:
public class FXSubjectInfo implements SubjectInfo { public FXSubjectInfo(String subject, String ccyPair, String tenor, String dealtCcy) { // assign args. ... } @Override public String getSubject() { return subject; } public String getCurrencyPair() { return ccyPair; } public String getTenor() { return tenor; } public String getDealtCurrency() { return dealtCurrency; } }
Modifier and Type | Method and Description |
---|---|
String |
getSubject()
Returns the original subject that was parsed to create this SubjectInfo
|
String getSubject()
Copyright © 2015 Caplin Systems.