Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit f9ec26b

Browse filesBrowse files
author
Devendra
committed
changing jar names for non master branches
1 parent cf9bb76 commit f9ec26b
Copy full SHA for f9ec26b

File tree

Expand file treeCollapse file tree

56 files changed

+656
-304
lines changed
Open diff view settings
Filter options

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Dismiss banner
Expand file treeCollapse file tree

56 files changed

+656
-304
lines changed
Open diff view settings
Collapse file
71 KB
Binary file not shown.
Collapse file

‎android/Pubnub-Android-3.7.4.jar‎

Copy file name to clipboard
-49 Bytes
Binary file not shown.
Collapse file
-31 Bytes
Binary file not shown.
Collapse file

‎android/build.xml‎

Copy file name to clipboardExpand all lines: android/build.xml
+19-1Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,25 @@
11
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
22
<project basedir="." default="build-all" name="PubnubApi" xmlns:artifact="antlib:org.apache.maven.artifact.ant">
3+
<exec executable="git" outputproperty="git.branch"
4+
failifexecutionfails="false">
5+
<arg line="rev-parse --abbrev-ref HEAD"/>
6+
</exec>
7+
<exec executable="git" outputproperty="git.revision" failifexecutionfails="false" errorproperty="">
8+
<arg value="rev-parse"/>
9+
<arg value="--short"/>
10+
<arg value="HEAD"/>
11+
</exec>
12+
<loadfile property="VERSION1" srcFile="../VERSION"><filterchain><striplinebreaks/></filterchain></loadfile>
13+
14+
<condition property="isMaster">
15+
<equals arg1="${git.branch}" arg2="master" />
16+
</condition>
17+
<condition property="VERSION" value="${VERSION1}" else="${VERSION1}-${git.branch}-${git.revision}">
18+
<isset property="isMaster"/>
19+
</condition>
20+
321
<property environment="env"/>
4-
<loadfile property="VERSION" srcFile="../VERSION"><filterchain><striplinebreaks/></filterchain></loadfile>
22+
<property name="VERSION" value="${VERSION1}-${git.branch}"/>
523
<property name="pubnub_lib_jar" value="Pubnub-Android-${VERSION}.jar"/>
624
<property name="pubnub_debug_lib_jar" value="Pubnub-Android-Debug-${VERSION}.jar"/>
725
<property name="java_core_path" value="../java"/>
Binary file not shown.
Collapse file
-49 Bytes
Binary file not shown.
Binary file not shown.
Collapse file
-49 Bytes
Binary file not shown.
Collapse file

‎android/src/com/pubnub/api/Pubnub.java‎

Copy file name to clipboardExpand all lines: android/src/com/pubnub/api/Pubnub.java
-252Lines changed: 0 additions & 252 deletions
Original file line numberDiff line numberDiff line change
@@ -123,256 +123,4 @@ protected String getUserAgent() {
123123
" Build) PubNub-Java/Android/" + VERSION;
124124
}
125125

126-
127-
/**
128-
* Enable Push Notifications (Google Cloud Messaging)
129-
* @param channel
130-
* Channel for which to enable push notifications
131-
* @param gcmRegistrationId
132-
* Google Cloud Messaging registration id
133-
*/
134-
public void enablePushNotificationsOnChannel(String channel, String gcmRegistrationId) {
135-
enablePushNotificationsOnChannels(new String[]{channel}, gcmRegistrationId, null);
136-
}
137-
138-
/**
139-
* Enable Push Notifications (Google Cloud Messaging)
140-
* @param channels
141-
* Channels for which to enable push notifications
142-
* @param gcmRegistrationId
143-
* Google Cloud Messaging registration id
144-
*/
145-
public void enablePushNotificationsOnChannels(String[] channels, String gcmRegistrationId) {
146-
enablePushNotificationsOnChannels(channels, gcmRegistrationId, null);
147-
}
148-
149-
/**
150-
* Enable Push Notifications (Google Cloud Messaging)
151-
* @param channel
152-
* Channel for which to enable push notifications
153-
* @param gcmRegistrationId
154-
* Google Cloud Messaging registration id
155-
* @param callback
156-
* Callback object
157-
*/
158-
public void enablePushNotificationsOnChannel(String channel, String gcmRegistrationId, Callback callback) {
159-
enablePushNotificationsOnChannels(new String[]{channel}, gcmRegistrationId, callback);
160-
}
161-
162-
163-
/**
164-
* Enable Push Notifications (Google Cloud Messaging)
165-
* @param channels
166-
* Channels for which to enable push notifications
167-
* @param gcmRegistrationId
168-
* Google Cloud Messaging registration id
169-
* @param callback
170-
* Callback object
171-
*/
172-
public void enablePushNotificationsOnChannels(final String[] channels, String gcmRegistrationId, final Callback callback) {
173-
final Callback cb = getWrappedCallback(callback);
174-
175-
Hashtable parameters = PubnubUtil.hashtableClone(params);
176-
String[] urlargs = null;
177-
urlargs = new String[]{ getPubnubUrl(), "v1", "push", "sub-key",
178-
this.SUBSCRIBE_KEY, "devices", gcmRegistrationId
179-
};
180-
181-
parameters.put("type", "gcm");
182-
parameters.put("add", PubnubUtil.joinString(channels, ","));
183-
184-
HttpRequest hreq = new HttpRequest(urlargs, parameters,
185-
new ResponseHandler() {
186-
public void handleResponse(HttpRequest hreq, String response) {
187-
JSONArray jsarr;
188-
try {
189-
jsarr = new JSONArray(response);
190-
} catch (JSONException e) {
191-
handleError(hreq,
192-
PubnubError.getErrorObject(PubnubError.PNERROBJ_INVALID_JSON, 1, response));
193-
return;
194-
}
195-
cb.successCallback("", jsarr);
196-
}
197-
198-
public void handleError(HttpRequest hreq, PubnubError error) {
199-
cb.errorCallback("", error);
200-
return;
201-
}
202-
});
203-
204-
_request(hreq, nonSubscribeManager);
205-
}
206-
207-
/**
208-
* Disable Push Notifications (Google Cloud Messaging)
209-
* @param channel
210-
* Channel for which to disable push notifications
211-
* @param gcmRegistrationId
212-
* Google Cloud Messaging registration id
213-
*/
214-
public void disablePushNotificationsOnChannel(String channel, String gcmRegistrationId) {
215-
disablePushNotificationsOnChannels(new String[]{channel}, gcmRegistrationId, null);
216-
}
217-
218-
/**
219-
* Disable Push Notifications (Google Cloud Messaging)
220-
* @param channels
221-
* Channels for which to disable push notifications
222-
* @param gcmRegistrationId
223-
* Google Cloud Messaging registration id
224-
*/
225-
public void disablePushNotificationsOnChannels(String[] channels, String gcmRegistrationId) {
226-
disablePushNotificationsOnChannels(channels, gcmRegistrationId, null);
227-
}
228-
229-
/**
230-
* Disable Push Notifications (Google Cloud Messaging)
231-
* @param channel
232-
* @param gcmRegistrationId
233-
* @param callback
234-
*/
235-
public void disablePushNotificationsOnChannel(String channel, String gcmRegistrationId, Callback callback) {
236-
disablePushNotificationsOnChannels(new String[]{channel}, gcmRegistrationId, callback);
237-
}
238-
239-
/**
240-
* Disable Push Notifications (Google Cloud Messaging)
241-
* @param channel
242-
* @param callback
243-
*/
244-
/**
245-
* @param channels
246-
* Channels for which to disable push notifications
247-
* @param gcmRegistrationId
248-
* Google Cloud Messaging registration id
249-
* @param callback
250-
* Callback object
251-
*/
252-
public void disablePushNotificationsOnChannels(final String[] channels, String gcmRegistrationId, final Callback callback) {
253-
final Callback cb = getWrappedCallback(callback);
254-
255-
256-
Hashtable parameters = PubnubUtil.hashtableClone(params);
257-
String[] urlargs = null;
258-
urlargs = new String[]{ getPubnubUrl(), "v1", "push", "sub-key",
259-
this.SUBSCRIBE_KEY, "devices", gcmRegistrationId
260-
};
261-
262-
263-
parameters.put("type", "gcm");
264-
parameters.put("remove", PubnubUtil.joinString(channels, ","));
265-
266-
HttpRequest hreq = new HttpRequest(urlargs, parameters,
267-
new ResponseHandler() {
268-
public void handleResponse(HttpRequest hreq, String response) {
269-
JSONArray jsarr;
270-
try {
271-
jsarr = new JSONArray(response);
272-
} catch (JSONException e) {
273-
handleError(hreq,
274-
PubnubError.getErrorObject(PubnubError.PNERROBJ_INVALID_JSON, 1, response));
275-
return;
276-
}
277-
cb.successCallback("", jsarr);
278-
}
279-
280-
public void handleError(HttpRequest hreq, PubnubError error) {
281-
cb.errorCallback("", error);
282-
return;
283-
}
284-
});
285-
286-
_request(hreq, nonSubscribeManager);
287-
}
288-
289-
290-
/**
291-
* Get channels for which push notification is enabled (Google Cloud Messaging)
292-
* @param gcmRegistrationId
293-
* Google Cloud Messaging registration id
294-
* @param callback
295-
* Callback object
296-
*/
297-
public void requestPushNotificationEnabledChannelsForDeviceRegistrationId(String gcmRegistrationId, final Callback callback) {
298-
final Callback cb = getWrappedCallback(callback);
299-
Hashtable parameters = PubnubUtil.hashtableClone(params);
300-
String[] urlargs = null;
301-
urlargs = new String[]{ getPubnubUrl(), "v1", "push", "sub-key",
302-
this.SUBSCRIBE_KEY, "devices", gcmRegistrationId
303-
};
304-
305-
306-
parameters.put("type", "gcm");
307-
308-
HttpRequest hreq = new HttpRequest(urlargs, parameters,
309-
new ResponseHandler() {
310-
public void handleResponse(HttpRequest hreq, String response) {
311-
JSONArray jsarr;
312-
try {
313-
jsarr = new JSONArray(response);
314-
} catch (JSONException e) {
315-
handleError(hreq,
316-
PubnubError.getErrorObject(PubnubError.PNERROBJ_INVALID_JSON, 1, response));
317-
return;
318-
}
319-
cb.successCallback("", jsarr);
320-
}
321-
322-
public void handleError(HttpRequest hreq, PubnubError error) {
323-
cb.errorCallback("", error);
324-
return;
325-
}
326-
});
327-
_request(hreq, nonSubscribeManager);
328-
}
329-
330-
/**
331-
* Disable push notifications for all channels (Google Cloud Messaging)
332-
* @param gcmRegistrationId
333-
* Google Cloud Messaging registration id
334-
*/
335-
public void removeAllPushNotificationsForDeviceRegistrationId(String gcmRegistrationId) {
336-
removeAllPushNotificationsForDeviceRegistrationId(gcmRegistrationId, null);
337-
}
338-
339-
/**
340-
* Disable push notifications for all channels (Google Cloud Messaging)
341-
* @param gcmRegistrationId
342-
* Google Cloud Messaging registration id
343-
* @param callback
344-
* Callback object
345-
*/
346-
public void removeAllPushNotificationsForDeviceRegistrationId(String gcmRegistrationId, final Callback callback) {
347-
final Callback cb = getWrappedCallback(callback);
348-
Hashtable parameters = PubnubUtil.hashtableClone(params);
349-
String[] urlargs = null;
350-
urlargs = new String[]{ getPubnubUrl(), "v1", "push", "sub-key",
351-
this.SUBSCRIBE_KEY, "devices", gcmRegistrationId, "remove"
352-
};
353-
354-
355-
parameters.put("type", "gcm");
356-
357-
HttpRequest hreq = new HttpRequest(urlargs, parameters,
358-
new ResponseHandler() {
359-
public void handleResponse(HttpRequest hreq, String response) {
360-
JSONArray jsarr;
361-
try {
362-
jsarr = new JSONArray(response);
363-
} catch (JSONException e) {
364-
handleError(hreq,
365-
PubnubError.getErrorObject(PubnubError.PNERROBJ_INVALID_JSON, 1, response));
366-
return;
367-
}
368-
cb.successCallback("", jsarr);
369-
}
370-
371-
public void handleError(HttpRequest hreq, PubnubError error) {
372-
cb.errorCallback("", error);
373-
return;
374-
}
375-
});
376-
_request(hreq, nonSubscribeManager);
377-
}
378126
}
Collapse file
66 KB
Binary file not shown.

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.