Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LPS-51954 #4049

Closed
wants to merge 4 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Binary file not shown.
Expand Up @@ -217,10 +217,6 @@ public com.liferay.pushnotifications.model.PushNotificationsDevice getPushNotifi
public java.util.List<com.liferay.pushnotifications.model.PushNotificationsDevice> getPushNotificationsDevices(
int start, int end);

@Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
public java.util.List<com.liferay.pushnotifications.model.PushNotificationsDevice> getPushNotificationsDevices(
long toUserId, java.lang.String platform, int start, int end);

/**
* Returns the number of push notifications devices.
*
Expand All @@ -234,6 +230,14 @@ public java.lang.Object invokeMethod(java.lang.String name,
java.lang.String[] parameterTypes, java.lang.Object[] arguments)
throws java.lang.Throwable;

public void sendPushNotification(long fromUserId,
com.liferay.portal.kernel.json.JSONObject jsonObject)
throws com.liferay.portal.kernel.exception.PortalException;

public void sendPushNotification(long fromUserId, long toUserId,
com.liferay.portal.kernel.json.JSONObject jsonObject)
throws com.liferay.portal.kernel.exception.PortalException;

/**
* Sets the Spring bean ID for this bean.
*
Expand Down
Expand Up @@ -125,23 +125,29 @@ public PushNotificationsDeviceLocalServiceClp(

_methodParameterTypes18 = new String[] { "int", "int" };

_methodName19 = "getPushNotificationsDevices";
_methodName19 = "getPushNotificationsDevicesCount";

_methodParameterTypes19 = new String[] {
"long", "java.lang.String", "int", "int"
_methodParameterTypes19 = new String[] { };

_methodName21 = "sendPushNotification";

_methodParameterTypes21 = new String[] {
"long", "com.liferay.portal.kernel.json.JSONObject"
};

_methodName20 = "getPushNotificationsDevicesCount";
_methodName22 = "sendPushNotification";

_methodParameterTypes20 = new String[] { };
_methodParameterTypes22 = new String[] {
"long", "long", "com.liferay.portal.kernel.json.JSONObject"
};

_methodName22 = "setBeanIdentifier";
_methodName23 = "setBeanIdentifier";

_methodParameterTypes22 = new String[] { "java.lang.String" };
_methodParameterTypes23 = new String[] { "java.lang.String" };

_methodName23 = "updatePushNotificationsDevice";
_methodName24 = "updatePushNotificationsDevice";

_methodParameterTypes23 = new String[] {
_methodParameterTypes24 = new String[] {
"com.liferay.pushnotifications.model.PushNotificationsDevice"
};
}
Expand Down Expand Up @@ -672,22 +678,12 @@ public java.util.List<com.liferay.pushnotifications.model.PushNotificationsDevic
}

@Override
public java.util.List<com.liferay.pushnotifications.model.PushNotificationsDevice> getPushNotificationsDevices(
long toUserId, java.lang.String platform, int start, int end) {
public int getPushNotificationsDevicesCount() {
Object returnObj = null;

try {
returnObj = _invokableLocalService.invokeMethod(_methodName19,
_methodParameterTypes19,
new Object[] {
toUserId,

ClpSerializer.translateInput(platform),

start,

end
});
_methodParameterTypes19, new Object[] { });
}
catch (Throwable t) {
t = ClpSerializer.translateThrowable(t);
Expand All @@ -701,20 +697,36 @@ public java.util.List<com.liferay.pushnotifications.model.PushNotificationsDevic
}
}

return (java.util.List<com.liferay.pushnotifications.model.PushNotificationsDevice>)ClpSerializer.translateOutput(returnObj);
return ((Integer)returnObj).intValue();
}

@Override
public int getPushNotificationsDevicesCount() {
Object returnObj = null;
public java.lang.Object invokeMethod(java.lang.String name,
java.lang.String[] parameterTypes, java.lang.Object[] arguments)
throws java.lang.Throwable {
throw new UnsupportedOperationException();
}

@Override
public void sendPushNotification(long fromUserId,
com.liferay.portal.kernel.json.JSONObject jsonObject)
throws com.liferay.portal.kernel.exception.PortalException {
try {
returnObj = _invokableLocalService.invokeMethod(_methodName20,
_methodParameterTypes20, new Object[] { });
_invokableLocalService.invokeMethod(_methodName21,
_methodParameterTypes21,
new Object[] {
fromUserId,

ClpSerializer.translateInput(jsonObject)
});
}
catch (Throwable t) {
t = ClpSerializer.translateThrowable(t);

if (t instanceof com.liferay.portal.kernel.exception.PortalException) {
throw (com.liferay.portal.kernel.exception.PortalException)t;
}

if (t instanceof RuntimeException) {
throw (RuntimeException)t;
}
Expand All @@ -723,22 +735,45 @@ public int getPushNotificationsDevicesCount() {
" is not a valid exception");
}
}

return ((Integer)returnObj).intValue();
}

@Override
public java.lang.Object invokeMethod(java.lang.String name,
java.lang.String[] parameterTypes, java.lang.Object[] arguments)
throws java.lang.Throwable {
throw new UnsupportedOperationException();
public void sendPushNotification(long fromUserId, long toUserId,
com.liferay.portal.kernel.json.JSONObject jsonObject)
throws com.liferay.portal.kernel.exception.PortalException {
try {
_invokableLocalService.invokeMethod(_methodName22,
_methodParameterTypes22,
new Object[] {
fromUserId,

toUserId,

ClpSerializer.translateInput(jsonObject)
});
}
catch (Throwable t) {
t = ClpSerializer.translateThrowable(t);

if (t instanceof com.liferay.portal.kernel.exception.PortalException) {
throw (com.liferay.portal.kernel.exception.PortalException)t;
}

if (t instanceof RuntimeException) {
throw (RuntimeException)t;
}
else {
throw new RuntimeException(t.getClass().getName() +
" is not a valid exception");
}
}
}

@Override
public void setBeanIdentifier(java.lang.String beanIdentifier) {
try {
_invokableLocalService.invokeMethod(_methodName22,
_methodParameterTypes22,
_invokableLocalService.invokeMethod(_methodName23,
_methodParameterTypes23,
new Object[] { ClpSerializer.translateInput(beanIdentifier) });
}
catch (Throwable t) {
Expand All @@ -760,8 +795,8 @@ public com.liferay.pushnotifications.model.PushNotificationsDevice updatePushNot
Object returnObj = null;

try {
returnObj = _invokableLocalService.invokeMethod(_methodName23,
_methodParameterTypes23,
returnObj = _invokableLocalService.invokeMethod(_methodName24,
_methodParameterTypes24,
new Object[] {
ClpSerializer.translateInput(pushNotificationsDevice)
});
Expand Down Expand Up @@ -822,10 +857,12 @@ public com.liferay.pushnotifications.model.PushNotificationsDevice updatePushNot
private String[] _methodParameterTypes18;
private String _methodName19;
private String[] _methodParameterTypes19;
private String _methodName20;
private String[] _methodParameterTypes20;
private String _methodName21;
private String[] _methodParameterTypes21;
private String _methodName22;
private String[] _methodParameterTypes22;
private String _methodName23;
private String[] _methodParameterTypes23;
private String _methodName24;
private String[] _methodParameterTypes24;
}
Expand Up @@ -243,12 +243,6 @@ public static java.util.List<com.liferay.pushnotifications.model.PushNotificatio
return getService().getPushNotificationsDevices(start, end);
}

public static java.util.List<com.liferay.pushnotifications.model.PushNotificationsDevice> getPushNotificationsDevices(
long toUserId, java.lang.String platform, int start, int end) {
return getService()
.getPushNotificationsDevices(toUserId, platform, start, end);
}

/**
* Returns the number of push notifications devices.
*
Expand All @@ -264,6 +258,18 @@ public static java.lang.Object invokeMethod(java.lang.String name,
return getService().invokeMethod(name, parameterTypes, arguments);
}

public static void sendPushNotification(long fromUserId,
com.liferay.portal.kernel.json.JSONObject jsonObject)
throws com.liferay.portal.kernel.exception.PortalException {
getService().sendPushNotification(fromUserId, jsonObject);
}

public static void sendPushNotification(long fromUserId, long toUserId,
com.liferay.portal.kernel.json.JSONObject jsonObject)
throws com.liferay.portal.kernel.exception.PortalException {
getService().sendPushNotification(fromUserId, toUserId, jsonObject);
}

/**
* Sets the Spring bean ID for this bean.
*
Expand Down
Expand Up @@ -254,13 +254,6 @@ public java.util.List<com.liferay.pushnotifications.model.PushNotificationsDevic
end);
}

@Override
public java.util.List<com.liferay.pushnotifications.model.PushNotificationsDevice> getPushNotificationsDevices(
long toUserId, java.lang.String platform, int start, int end) {
return _pushNotificationsDeviceLocalService.getPushNotificationsDevices(toUserId,
platform, start, end);
}

/**
* Returns the number of push notifications devices.
*
Expand All @@ -279,6 +272,22 @@ public java.lang.Object invokeMethod(java.lang.String name,
parameterTypes, arguments);
}

@Override
public void sendPushNotification(long fromUserId,
com.liferay.portal.kernel.json.JSONObject jsonObject)
throws com.liferay.portal.kernel.exception.PortalException {
_pushNotificationsDeviceLocalService.sendPushNotification(fromUserId,
jsonObject);
}

@Override
public void sendPushNotification(long fromUserId, long toUserId,
com.liferay.portal.kernel.json.JSONObject jsonObject)
throws com.liferay.portal.kernel.exception.PortalException {
_pushNotificationsDeviceLocalService.sendPushNotification(fromUserId,
toUserId, jsonObject);
}

/**
* Sets the Spring bean ID for this bean.
*
Expand Down
Expand Up @@ -59,6 +59,11 @@ public interface PushNotificationsEntryLocalService extends BaseLocalService,
public com.liferay.pushnotifications.model.PushNotificationsEntry addPushNotificationsEntry(
com.liferay.pushnotifications.model.PushNotificationsEntry pushNotificationsEntry);

public com.liferay.pushnotifications.model.PushNotificationsEntry addPushNotificationsEntry(
long userId, long parentPushNotificationsEntryId,
com.liferay.portal.kernel.json.JSONObject payloadJSONObject)
throws com.liferay.portal.kernel.exception.PortalException;

public com.liferay.pushnotifications.model.PushNotificationsEntry addPushNotificationsEntry(
long userId, com.liferay.portal.kernel.json.JSONObject payloadJSONObject)
throws com.liferay.portal.kernel.exception.PortalException;
Expand Down Expand Up @@ -102,10 +107,6 @@ public com.liferay.pushnotifications.model.PushNotificationsEntry deletePushNoti
long pushNotificationsEntryId)
throws com.liferay.portal.kernel.exception.PortalException;

public com.liferay.pushnotifications.model.PushNotificationsEntry dislikePushNotificationsEntry(
long userId, long pushNotificationsEntryId)
throws com.liferay.portal.kernel.exception.PortalException;

public com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery();

/**
Expand Down Expand Up @@ -241,11 +242,7 @@ public com.liferay.pushnotifications.model.PushNotificationsEntry likePushNotifi
throws com.liferay.portal.kernel.exception.PortalException;

public void sendPushNotification(long fromUserId,
com.liferay.portal.kernel.json.JSONObject payloadJSONObject)
throws com.liferay.portal.kernel.exception.PortalException;

public void sendPushNotification(long fromUserId, long toUserId,
com.liferay.portal.kernel.json.JSONObject payloadJSONObject)
com.liferay.pushnotifications.model.PushNotificationsEntry pushNotificationsEntry)
throws com.liferay.portal.kernel.exception.PortalException;

/**
Expand All @@ -255,6 +252,10 @@ public void sendPushNotification(long fromUserId, long toUserId,
*/
public void setBeanIdentifier(java.lang.String beanIdentifier);

public com.liferay.pushnotifications.model.PushNotificationsEntry unlikePushNotificationsEntry(
long userId, long pushNotificationsEntryId)
throws com.liferay.portal.kernel.exception.PortalException;

public com.liferay.pushnotifications.model.PushNotificationsEntry updateChildrenPushNotificationsEntriesCount(
long parentPushNotificationsEntryId)
throws com.liferay.portal.kernel.exception.PortalException;
Expand Down