HomeSort by relevance Sort by last modified time
    Searched refs:Subscription (Results 1 - 21 of 21) sorted by null

  /external/grpc-grpc/src/python/grpcio/grpc/framework/interfaces/base/
utilities.py 30 class _Subscription(base.Subscription,
38 """A trivial implementation of base.Subscription."""
41 _NONE_SUBSCRIPTION = _Subscription(base.Subscription.Kind.NONE, None, None,
60 """Creates a "full" base.Subscription for the given base.Operator.
67 A base.Subscription of kind base.Subscription.Kind.FULL wrapping the given
70 return _Subscription(base.Subscription.Kind.FULL, None, None, operator,
base.py 189 class Subscription(six.with_metaclass(abc.ABCMeta)):
232 A Subscription via which this object may or may not accept more values of
280 subscription,
291 subscription: A Subscription to which the results of the operation will be
  /developers/samples/android/tv/ChannelsPrograms/Application/src/main/java/com/example/android/tv/channelsprograms/model/
Subscription.java 17 public class Subscription {
26 public Subscription() {}
28 private Subscription(
36 public static Subscription createSubscription(
38 return new Subscription(name, description, appLinkIntentUri, channelLogo);
MockDatabase.java 37 * Returns a subscription to mock content representing tv shows.
40 * @return a subscription with tv show data.
42 public static Subscription getTvShowSubscription(Context context) {
52 * Returns a subscription to mock content representing your videos.
55 * @return a subscription with your video data.
57 public static Subscription getVideoSubscription(Context context) {
67 * Returns a subscription to mock content representing cat videos.
70 * @return a subscription with cat videos.
72 public static Subscription getCatVideosSubscription(Context context) {
81 private static Subscription findOrCreateSubscription
89 Subscription subscription = findSubscriptionByTitle(context, title); local
    [all...]
MockMovieService.java 38 public static List<Subscription> createUniversalSubscriptions(Context context) {
41 Subscription flagshipSubscription =
42 Subscription.createSubscription(
49 Subscription videoSubscription =
50 Subscription.createSubscription(
57 Subscription filmsSubscription =
58 Subscription.createSubscription(
  /developers/samples/android/tv/ChannelsPrograms/Application/src/main/java/com/example/android/tv/channelsprograms/
MainActivity.java 28 import com.example.android.tv.channelsprograms.model.Subscription;
56 final Subscription tvShowSubscription =
60 final Subscription videoSubscription =
64 final Subscription catVideosSubscription =
71 private void setupButtonState(Button button, final Subscription subscription) {
72 boolean channelExists = subscription.getChannelId() > 0L;
75 view -> new AddChannelTask(getApplicationContext()).execute(subscription));
78 private class AddChannelTask extends AsyncTask<Subscription, Void, Long> {
87 protected Long doInBackground(Subscription... varArgs)
92 Subscription subscription = subscriptions.get(0); local
    [all...]
SyncChannelJobService.java 25 import com.example.android.tv.channelsprograms.model.Subscription;
73 List<Subscription> subscriptions = MockDatabase.getSubscriptions(mContext);
83 for (Subscription subscription : subscriptions) {
84 long channelId = TvUtil.createChannel(mContext, subscription);
85 subscription.setChannelId(channelId);
94 for (Subscription channel : subscriptions) {
AppLinkActivity.java 27 import com.example.android.tv.channelsprograms.model.Subscription;
71 Subscription subscription = local
73 if (subscription == null) {
74 Log.e(TAG, "Invalid subscription " + action.getSubscriptionName());
76 // TODO: Open an activity that has the movies for the subscription.
SyncProgramsJobService.java 33 import com.example.android.tv.channelsprograms.model.Subscription;
230 Subscription subscription = local
232 if (subscription != null) {
  /external/libchrome/base/
callback_list.h 29 // std::unique_ptr<base::CallbackList<void(const Foo&)>::Subscription>
53 // // Subscription gets deleted automatically and will deregister
62 // std::unique_ptr<base::CallbackList<void(const Foo&)>::Subscription>
75 class Subscription {
77 Subscription(CallbackListBase<CallbackType>* list,
83 ~Subscription() {
97 DISALLOW_COPY_AND_ASSIGN(Subscription);
101 // returned Subscription is destroyed, which must occur before the
103 std::unique_ptr<Subscription> Add(const CallbackType& cb) WARN_UNUSED_RESULT {
105 return std::make_unique<Subscription>(
    [all...]
callback_list_unittest.cc 41 std::unique_ptr<CallbackList<void(void)>::Subscription> sub) {
49 std::unique_ptr<CallbackList<void(void)>::Subscription> removal_subscription_;
77 std::unique_ptr<CallbackList<void(void)>::Subscription> subscription_;
121 std::unique_ptr<CallbackList<void(int)>::Subscription> subscription1 =
128 std::unique_ptr<CallbackList<void(int, int)>::Subscription> subscription2 =
135 std::unique_ptr<CallbackList<void(int, int, int)>::Subscription>
142 std::unique_ptr<CallbackList<void(int, int, int, int)>::Subscription>
149 std::unique_ptr<CallbackList<void(int, int, int, int, int)>::Subscription>
157 CallbackList<void(int, int, int, int, int, int)>::Subscription>
170 std::unique_ptr<CallbackList<void(void)>::Subscription> a_subscription
312 std::unique_ptr<CallbackList<void(void)>::Subscription> subscription = local
    [all...]
  /cts/hostsidetests/statsd/src/android/cts/statsd/alarm/
AlarmTests.java 24 import com.android.internal.os.StatsdConfigProto.Subscription;
73 .addSubscription(Subscription.newBuilder()
75 .setRuleType(Subscription.RuleType.ALARM)
  /external/grpc-grpc/examples/ruby/pubsub/tech/pubsub/proto/
pubsub_services.rb 56 rpc :CreateSubscription, Subscription, Subscription
57 rpc :GetSubscription, GetSubscriptionRequest, Subscription
pubsub.rb 55 add_message "tech.pubsub.Subscription" do
59 optional :truncation_policy, :message, 4, "tech.pubsub.Subscription.TruncationPolicy"
64 add_message "tech.pubsub.Subscription.TruncationPolicy" do
72 optional :subscription, :string, 1
78 optional :subscription, :string, 1
86 repeated :subscription, :message, 1, "tech.pubsub.Subscription"
90 optional :subscription, :string, 1
93 optional :subscription, :string, 1
96 optional :subscription, :string,
    [all...]
  /developers/samples/android/tv/ChannelsPrograms/Application/src/main/java/com/example/android/tv/channelsprograms/util/
SharedPreferencesHelper.java 23 import com.example.android.tv.channelsprograms.model.Subscription;
35 * Helper class to store {@link Subscription}s and {@link Movie}s in {@link SharedPreferences}.
55 * Reads the {@link List <Subscription>} from {@link SharedPreferences}.
60 public static List<Subscription> readSubscriptions(Context context) {
61 return getList(context, Subscription.class, PREFS_SUBSCRIPTIONS_KEY);
70 public static void storeSubscriptions(Context context, List<Subscription> subscriptions) {
TvUtil.java 41 import com.example.android.tv.channelsprograms.model.Subscription;
56 * Converts a {@link Subscription} into a {@link Channel} and adds it to the tv provider.
59 * @param subscription to be converted to a channel and added to the tv provider.
63 public static long createChannel(Context context, Subscription subscription) {
65 // Checks if our subscription has been added to the channels before.
77 if (subscription.getName().equals(channel.getDisplayName())) {
89 Uri appLinkIntentUri = Uri.parse(subscription.getAppLinkIntentUri());
93 .setDisplayName(subscription.getName())
94 .setDescription(subscription.getDescription()
    [all...]
  /external/Reactive-Extensions/RxCpp/Rx/v2/src/rxcpp/
rx-trace.hpp 78 template<class SubscriptionState, class Subscription>
79 inline void subscription_add_enter(const SubscriptionState&, const Subscription&) {}
  /cts/hostsidetests/statsd/src/android/cts/statsd/alert/
AnomalyDetectionTests.java 30 import com.android.internal.os.StatsdConfigProto.Subscription;
285 .addSubscription(Subscription.newBuilder()
287 .setRuleType(Subscription.RuleType.ALERT)
452 .addSubscription(Subscription.newBuilder()
454 .setRuleType(Subscription.RuleType.ALERT)
  /cts/hostsidetests/statsd/src/android/cts/statsd/metadata/
MetadataTests.java 22 import com.android.internal.os.StatsdConfigProto.Subscription;
  /external/grpc-grpc/examples/ruby/pubsub/
pubsub_demo.rb 134 @sub.create_subscription(Subscription.new(name: sub_name,
142 batch = @sub.pull_batch(PullBatchRequest.new(subscription: sub_name,
146 @sub.acknowledge(AcknowledgeRequest.new(subscription: sub_name,
148 p "Test messages were acknowledged OK, deleting the subscription"
149 del_req = DeleteSubscriptionRequest.new(subscription: sub_name)
166 # test_sub_name is the subscription name to use in this test.
  /device/linaro/bootloader/edk2/AppPkg/Applications/Python/Python-2.7.10/Lib/pydoc_data/
topics.py 4 'assignment': u'\nAssignment statements\n*********************\n\nAssignment statements are used to (re)bind names to values and to\nmodify attributes or items of mutable objects:\n\n assignment_stmt ::= (target_list "=")+ (expression_list | yield_expression)\n target_list ::= target ("," target)* [","]\n target ::= identifier\n | "(" target_list ")"\n | "[" target_list "]"\n | attributeref\n | subscription\n | slicing\n\n(See section Primaries for the syntax definitions for the last three\nsymbols.)\n\nAn assignment statement evaluates the expression list (remember that\nthis can be a single expression or a comma-separated list, the latter\nyielding a tuple) and assigns the single resulting object to each of\nthe target lists, from left to right.\n\nAssignment is defined recursively depending on the form of the target\n(list). When a target is part of a mutable object (an attribute\nreference, subscription or slicing), the mutable object must\nultimately perform the assignment and decide about its validity, and\nmay raise an exception if the assignment is unacceptable. The rules\nobserved by various types and the exceptions raised are given with the\ndefinition of the object types (see section The standard type\nhierarchy).\n\nAssignment of an object to a target list is recursively defined as\nfollows.\n\n* If the target list is a single target: The object is assigned to\n that target.\n\n* If the target list is a comma-separated list of targets: The\n object must be an iterable with the same number of items as there\n are targets in the target list, and the items are assigned, from\n left to right, to the corresponding targets.\n\nAssignment of an object to a single target is recursively defined as\nfollows.\n\n* If the target is an identifier (name):\n\n * If the name does not occur in a "global" statement in the\n current code block: the name is bound to the object in the current\n local namespace.\n\n * Otherwise: the name is bound to the object in the current global\n namespace.\n\n The name is rebound if it was already bound. This may cause the\n reference count for the object previously bound to the name to reach\n zero, causing the object to be deallocated and its destructor (if it\n has one) to be called.\n\n* If the target is a target list enclosed in parentheses or in\n square brackets: The object must be an iterable with the same number\n of items as there are targets in the target list, and its items are\n assigned, from left to right, to the corresponding targets.\n\n* If the target is an attribute reference: The primary expression in\n the reference is evaluated. It should yield an object with\n assignable attributes; if this is not the case, "TypeError" is\n raised. That object is then asked to assign the assigned object to\n the given attribute; if it cannot perform the assignment, it raises\n an exception (usually but not necessarily "AttributeError").\n\n Note: If the object is a class instance and the attribute reference\n occurs on both sides of the assignment operator, the RHS expression,\n "a.x" can access either an instance attribute or (if no instance\n attribute exists) a class attribute. The LHS target "a.x" is always\n set as an instance attribute, creating it if necessary. Thus, the\n two occurrences of "a.x" do not necessarily refer to the same\n attribute: if the RHS expression refers to a class attribute, the\n LHS creates a new instance attribute as the target of the\n assignment:\n\n class Cls:\n x = 3 # class variable\n inst = Cls()\n inst.x = inst.x + 1 # writes inst.x as 4 leaving Cls.x as 3\n\n This description does not necessarily apply to descriptor\n attributes, such as properties created with "property()".\n\n* If the target is a subscription: The primary expression in the\n reference is evaluated. It should yield either a mutable sequence\n object (such as a list) or a mapping object (such as a dictionary).\n Next, the subscript expression is evaluated.\n\n If the primary is a mutable sequence object (such as a list), the\n subscript must yield a plain integer. If it is negative, the\n sequence\'s length is added to it. The resulting value must be a\n nonnegative integer less than the sequence\'s length, and the\n sequence is asked to assign the assigned object to its item with\n that index. If the index is out of range, "IndexError" is raised\n (assignment to a subscripted sequence cannot add new items to a\n list).\n\n If the primary is a mapping object (such as a dictionary), the\n subscript must have a type compatible with the mapping\'s key type,\n and the mapping is then asked to create a key/datum pair which maps\n the subscript to the assigned object. This can either replace an\n existing key/value pair with the same key value, or insert a new\n key/value pair (if no key with the same value existed).\n\n* If the target is a slicing: The primary expression in the\n reference is evaluated. It should yield a mutable sequence object\n (such as a list). The assigned object should be a sequence object\n of the same type. Next, the lower and upper bound expressions are\n evaluated, insofar they are present; defaults are zero and the\n sequence\'s length. The bounds should evaluate to (small) integers.\n If either bound is negative, the sequence\'s length is added to it.\n The resulting bounds are clipped to lie between zero and the\n sequence\'s length, inclusive. Finally, the sequence object is asked\n to replace the slice with the items of the assigned sequence. The\n length of the slice may be different from the length of the assigned\n sequence, thus changing the length of the target sequence, if the\n object allows it.\n\n**CPython implementation detail:** In the current implementation, the\nsyntax for targets is taken to be the same as for expressions, and\ninvalid syntax is rejected during the code generation phase, causing\nless detailed error messages.\n\nWARNING: Although the definition of assignment implies that overlaps\nbetween the left-hand side and the right-hand side are \'safe\' (for\nexample "a, b = b, a" swaps two variables), overlaps *within* the\ncollection of assigned-to variables are not safe! For instance, the\nfollowing program prints "[0, 2]":\n\n x = [0, 1]\n i = 0\n i, x[i] = 1, 2\n print x\n\n\nAugmented assignment statements\n===============================\n\nAugmented assignment is the combination, in a single statement, of a\nbinary operation and an assignment statement:\n\n augmented_assignment_stmt ::= augtarget augop (expression_list | yield_expression)\n augtarget ::= identifier | attributeref | subscription | slicing\n augop ::= "+=" | "-=" | "*=" | "/=" | "//=" | "%=" | "**="\n | ">>=" | "<<=" | "&=" | "^=" | "|="\n\n(See section Primaries for the syntax definitions for the last three\nsymbols.)\n\nAn augmented assignment evaluates the target (which, unlike normal\nassignment statements, cannot be an unpacking) and the expression\nlist, performs the binary operation specific to the type of assignment\non the two operands, and assigns the result to the original target.\nThe target is only evaluated once.\n\nAn augmented assignment expression like "x += 1" can be rewritten as\n"x = x + 1" to achieve a similar, but not exactly equal effect. In the\naugmented version, "x" is only evaluated once. Also, when possible,\nthe actual operation is performed *in-place*, meaning that rather than\ncreating a new object and assigning that to the target, the old object\nis modified instead.\n\nWith the exception of assigning to tuples and multiple targets in a\nsingle statement, the assignment done by augmented assignment\nstatements is handled the same way as normal assignments. Similarly,\nwith the exception of the possible *in-place* behavior, the binary\noperation performed by augmented assignment is the same as the normal\nbinary operations.\n\nFor targets which are attribute references, the same caveat about\nclass and instance attributes applies as for regular assignments.\n',
9 'augassign': u'\nAugmented assignment statements\n*******************************\n\nAugmented assignment is the combination, in a single statement, of a\nbinary operation and an assignment statement:\n\n augmented_assignment_stmt ::= augtarget augop (expression_list | yield_expression)\n augtarget ::= identifier | attributeref | subscription | slicing\n augop ::= "+=" | "-=" | "*=" | "/=" | "//=" | "%=" | "**="\n | ">>=" | "<<=" | "&=" | "^=" | "|="\n\n(See section Primaries for the syntax definitions for the last three\nsymbols.)\n\nAn augmented assignment evaluates the target (which, unlike normal\nassignment statements, cannot be an unpacking) and the expression\nlist, performs the binary operation specific to the type of assignment\non the two operands, and assigns the result to the original target.\nThe target is only evaluated once.\n\nAn augmented assignment expression like "x += 1" can be rewritten as\n"x = x + 1" to achieve a similar, but not exactly equal effect. In the\naugmented version, "x" is only evaluated once. Also, when possible,\nthe actual operation is performed *in-place*, meaning that rather than\ncreating a new object and assigning that to the target, the old object\nis modified instead.\n\nWith the exception of assigning to tuples and multiple targets in a\nsingle statement, the assignment done by augmented assignment\nstatements is handled the same way as normal assignments. Similarly,\nwith the exception of the possible *in-place* behavior, the binary\noperation performed by augmented assignment is the same as the normal\nbinary operations.\n\nFor targets which are attribute references, the same caveat about\nclass and instance attributes applies as for regular assignments.\n',
    [all...]

Completed in 590 milliseconds