Interface Namespace
-
- All Known Implementing Classes:
PrefixNamespace
,RegexNamespace
public interface Namespace
A
Namespace
is used to determine if a subject is of interest to anDataProvider
.A subject name is defined within a DataSource namespace. For example, if the DataSource namespace is the prefix "/FX" the subject name "/FX/EURUSD" is within that namespace, but "/FY/EURUSD" is not.
Namespace
is the interface that represents a DataSource namespace.A
Namespace
is used to construct aPublisher
and to ensure that the associatedDataProvider
only receives requests for subjects that it can supply.DataSource for Java includes the following implementations of
NameSpace
:PrefixNamespace
, which matches the start of a subject name.RegexNamespace
, for more complex subject matching requirements.
In particular, the
RegexNamespace
provides a flexible way to match subjects against inclusion and exclusion patterns, so you should not normally need to useNamespace
directly. However, should the supplied DataSource namespace implementations not match your requirements you can write your own custom subject matching logic in an implementation ofNamespace
.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description boolean
match(java.lang.String subject)
Tests aString
to see if it falls within thisNamespace
.
-