/// <summary>
            /// Adds a fence identified by the given key
            /// </summary>
            /// <param name="fenceKey"></param>
            /// <param name="fence">The fence that is to be registered.</param>
            /// <returns>This <see cref="FenceUpdateRequest.Builder"/> object.</returns>
            public Builder AddFence(string fenceKey, AwarenessFence fence)
            {
                var intent = FenceClient.AwarenessManagerClass.AJCCallStaticOnceAJO("getPendingIntent", JniToolkitUtils.Activity);

                _ajo.CallAJO("addFence", fenceKey, fence.AJO, intent);
                return(this);
            }
Exemplo n.º 2
0
 /// <summary>
 ///     Create an awareness fence that is the logical NOT of the specified fence.
 /// </summary>
 /// <param name="fence">The fence that should be passed through a logical NOT.</param>
 /// <returns>The resulting awareness fence.</returns>
 public static AwarenessFence Not(AwarenessFence fence)
 {
     return(new AwarenessFence(AwarenessFenceClass.AJCCallStaticOnceAJO("not", fence.AJO)));
 }