Interface ISubscription
- All Superinterfaces:
ISubscriptionInfo
This represents the relationship between a Thing interested in events (usually a Principal) and Thing
that generates events (usually an information resource).
It has a 'from' and a 'to'.
-
The 'from' identifies the resource that will generate events.
- from.id - Thing ID. A ThingID that specifies ThingType but leave the instance ID as 0 will subscribe to all Things of the specified type.
-
from.criteria[] - list of criterion specifying property and operation. Optional.
- from.criteria[].property - ThingID of Relation that defines this property
- from.criteria[].operation - operations to listen for as bitfield (see IEventOperation)
-
The 'to' represents where notifications will be delivered.
- to.thing - Thing ID of user or group interested in events
-
to.deliveryMode - Delivery mechanisms. Multiple values are OR'ed together.
-
Valid values are:
- EMAIL_DELIVERY If the target is an IUser, an e-mail will be sent
- PORTAL_DELIVERY If the target is an IUser, a notification will be placed in their Inbox
- THING_DELIVERY The target Thing will be instantiated and its onMessage method will be called
- HTTP_DELIVERY The message will be forwarded to the target ID via a JMS Queue
- See Also:
-
Field Summary
Fields inherited from interface com.webmethods.portal.service.meta2.subscription.ISubscriptionInfo
DAILY_DELIVERY, DELIVERY_TYPE_MASK, DIGEST_DELIVERY_MASK, DISABLED_BY_SYSTEM, DISABLED_BY_USER, EMAIL_DELIVERY, ENABLED, HTTP_DELIVERY, IM_DELIVERY, PORTAL_DELIVERY, THING_DELIVERY, WEEKLY_DELIVERY
-
Method Summary
Modifier and TypeMethodDescriptionadd
(IMetaContext mc) Adds a new ISubscriptionInfo data to the database.save()
Saves any changes to the database for the existing subscription.void
unsubscribe this subscriptionMethods inherited from interface com.webmethods.portal.service.meta2.subscription.ISubscriptionInfo
findCriterion, getCriteriaList, getDeliveryModes, getOwner, getResource, getStatus, getSubscriber, hasCriterion, hasCriterion, isRecursive, setCriteriaIDs, setDeliveryModes, setOwner, setRecursive, setResource, setStatus, setSubscriber
-
Method Details
-
save
Saves any changes to the database for the existing subscription.- Returns:
- IThingID of saved subscription
- Throws:
MetaException
-
add
Adds a new ISubscriptionInfo data to the database.- Parameters:
mc
-- Returns:
- IThingID of the created subscription
- Throws:
MetaException
- See Also:
-
unsubscribe
unsubscribe this subscription- Throws:
MetaException
-