@Immutable public interface Rule
Modifier and Type | Method and Description |
---|---|
Spec |
drain()
Get drain spec.
|
String |
failure()
Read description of failure or empty string if there is no failure.
|
void |
failure(String desc)
Mark it as failed.
|
String |
name()
Get its name.
|
Spec |
spec()
Get spec.
|
void |
update(Spec spec,
Spec drain)
Save spec.
|
Wallet |
wallet(Coordinates work,
com.jcabi.urn.URN taker,
String rule)
Wallet of the rule.
|
void update(@NotNull(message="spec can\'t be NULL") Spec spec, @NotNull(message="drain can\'t be NULL") Spec drain)
spec
- Spec to savedrain
- Spec of drainvoid failure(@NotNull(message="desc can\'t be NULL") String desc)
desc
- Description of a failureString failure()
@NotNull(message="wallet is never NULL") Wallet wallet(Coordinates work, com.jcabi.urn.URN taker, String rule) throws Wallet.NotEnoughFundsException
work
- Which work fortaker
- Who is going to take money from my wallet?rule
- What this money is for?Wallet.NotEnoughFundsException
- If not enough fundsCopyright © 2009–2014 Rultor Inc.. All rights reserved.