refactor packages in virtual fire alarm feature

dev
Amalka Subasinghe 2 years ago
parent 7c0804b847
commit 6181f983d8

@ -52,8 +52,8 @@
<archive> <archive>
<manifest> <manifest>
<mainClass> <mainClass>
org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.Bootstrap io.entgra.device.mgt.plugins.virtualfirealarm.agent.Bootstrap
</mainClass> </mainClass>
</manifest> </manifest>
</archive> </archive>
<descriptorRefs> <descriptorRefs>

@ -16,9 +16,9 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent; package io.entgra.device.mgt.plugins.virtualfirealarm.agent;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.core.AgentManager; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.core.AgentManager;
public class Bootstrap { public class Bootstrap {

@ -16,19 +16,19 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.communication.http; package io.entgra.device.mgt.plugins.virtualfirealarm.agent.communication.http;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
import org.eclipse.jetty.http.HttpStatus; import org.eclipse.jetty.http.HttpStatus;
import org.eclipse.jetty.server.Request; import org.eclipse.jetty.server.Request;
import org.eclipse.jetty.server.handler.AbstractHandler; import org.eclipse.jetty.server.handler.AbstractHandler;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.core.AgentConstants; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.core.AgentConstants;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.core.AgentManager; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.core.AgentManager;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.exception.AgentCoreOperationException; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.exception.AgentCoreOperationException;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport.TransportHandlerException; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.transport.TransportHandlerException;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport.TransportUtils; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.transport.TransportUtils;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport.http.HTTPTransportHandler; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.transport.http.HTTPTransportHandler;
import javax.servlet.ServletException; import javax.servlet.ServletException;
import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletRequest;

@ -16,19 +16,19 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.communication.mqtt; package io.entgra.device.mgt.plugins.virtualfirealarm.agent.communication.mqtt;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
import org.eclipse.paho.client.mqttv3.MqttException; import org.eclipse.paho.client.mqttv3.MqttException;
import org.eclipse.paho.client.mqttv3.MqttMessage; import org.eclipse.paho.client.mqttv3.MqttMessage;
import org.eclipse.paho.client.mqttv3.MqttSecurityException; import org.eclipse.paho.client.mqttv3.MqttSecurityException;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.core.AgentConstants; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.core.AgentConstants;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.core.AgentManager; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.core.AgentManager;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.core.AgentUtilOperations; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.core.AgentUtilOperations;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.exception.AgentCoreOperationException; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.exception.AgentCoreOperationException;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport.TransportHandlerException; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.transport.TransportHandlerException;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport.mqtt.MQTTTransportHandler; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.transport.mqtt.MQTTTransportHandler;
import java.nio.charset.StandardCharsets; import java.nio.charset.StandardCharsets;
import java.util.concurrent.Executors; import java.util.concurrent.Executors;

@ -16,18 +16,17 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.communication.xmpp; package io.entgra.device.mgt.plugins.virtualfirealarm.agent.communication.xmpp;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
import org.jivesoftware.smack.packet.Message; import org.jivesoftware.smack.packet.Message;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.core.AgentConfiguration; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.core.AgentConstants;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.core.AgentConstants; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.core.AgentManager;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.core.AgentManager; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.core.AgentUtilOperations;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.core.AgentUtilOperations; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.exception.AgentCoreOperationException;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.exception.AgentCoreOperationException; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.transport.TransportHandlerException;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport.TransportHandlerException; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.transport.xmpp.XMPPTransportHandler;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport.xmpp.XMPPTransportHandler;
import java.util.concurrent.Executors; import java.util.concurrent.Executors;
import java.util.concurrent.ScheduledExecutorService; import java.util.concurrent.ScheduledExecutorService;

@ -16,7 +16,7 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.core; package io.entgra.device.mgt.plugins.virtualfirealarm.agent.core;
/** /**
* A Configuration class that holds all the Agent specific details that are read from the * A Configuration class that holds all the Agent specific details that are read from the

@ -16,7 +16,7 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.core; package io.entgra.device.mgt.plugins.virtualfirealarm.agent.core;
public class AgentConstants { public class AgentConstants {
public static final String DEVICE_TYPE = "virtual_firealarm"; public static final String DEVICE_TYPE = "virtual_firealarm";

@ -16,19 +16,18 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.core; package io.entgra.device.mgt.plugins.virtualfirealarm.agent.core;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.communication.http.FireAlarmHTTPCommunicator; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.communication.http.FireAlarmHTTPCommunicator;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.communication.mqtt.FireAlarmMQTTCommunicator; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.communication.mqtt.FireAlarmMQTTCommunicator;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.communication.xmpp.FireAlarmXMPPCommunicator; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.communication.xmpp.FireAlarmXMPPCommunicator;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.enrollment.EnrollmentManager; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.exception.AgentCoreOperationException;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.exception.AgentCoreOperationException; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.transport.TransportHandler;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport.TransportHandler; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.transport.TransportHandlerException;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport.TransportHandlerException; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.transport.TransportUtils;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport.TransportUtils; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.virtual.VirtualHardwareManager;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.virtual.VirtualHardwareManager;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.HashMap; import java.util.HashMap;

@ -16,7 +16,7 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.core; package io.entgra.device.mgt.plugins.virtualfirealarm.agent.core;
import org.apache.commons.codec.binary.Base64; import org.apache.commons.codec.binary.Base64;
import org.apache.commons.configuration.ConfigurationException; import org.apache.commons.configuration.ConfigurationException;
@ -25,11 +25,11 @@ import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
import org.eclipse.jetty.http.HttpStatus; import org.eclipse.jetty.http.HttpStatus;
import org.json.JSONObject; import org.json.JSONObject;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.enrollment.EnrollmentManager; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.enrollment.EnrollmentManager;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.exception.AgentCoreOperationException; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.exception.AgentCoreOperationException;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport.CommunicationUtils; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.transport.CommunicationUtils;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport.TransportHandlerException; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.transport.TransportHandlerException;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport.TransportUtils; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.transport.TransportUtils;
import javax.net.ssl.HostnameVerifier; import javax.net.ssl.HostnameVerifier;
import javax.net.ssl.HttpsURLConnection; import javax.net.ssl.HttpsURLConnection;

@ -16,7 +16,7 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.enrollment; package io.entgra.device.mgt.plugins.virtualfirealarm.agent.enrollment;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
@ -39,12 +39,11 @@ import org.jscep.client.verification.CertificateVerifier;
import org.jscep.client.verification.OptimisticCertificateVerifier; import org.jscep.client.verification.OptimisticCertificateVerifier;
import org.jscep.transaction.TransactionException; import org.jscep.transaction.TransactionException;
import org.jscep.transport.response.Capabilities; import org.jscep.transport.response.Capabilities;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.core.AgentConstants; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.core.AgentConstants;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.core.AgentManager; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.core.AgentManager;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.exception.AgentCoreOperationException; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.exception.AgentCoreOperationException;
import sun.security.x509.X509CertImpl; import sun.security.x509.X509CertImpl;
import java.io.FileInputStream;
import java.io.FileOutputStream; import java.io.FileOutputStream;
import java.io.IOException; import java.io.IOException;
import java.math.BigInteger; import java.math.BigInteger;

@ -16,7 +16,7 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.exception; package io.entgra.device.mgt.plugins.virtualfirealarm.agent.exception;
public class AgentCoreOperationException extends Exception{ public class AgentCoreOperationException extends Exception{

@ -16,7 +16,7 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport; package io.entgra.device.mgt.plugins.virtualfirealarm.agent.transport;
import org.apache.commons.codec.binary.Base64; import org.apache.commons.codec.binary.Base64;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;

@ -16,7 +16,7 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport; package io.entgra.device.mgt.plugins.virtualfirealarm.agent.transport;
/** /**
* This interface consists of the core functionality related to the transport between any device and the server. The * This interface consists of the core functionality related to the transport between any device and the server. The

@ -16,7 +16,7 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport; package io.entgra.device.mgt.plugins.virtualfirealarm.agent.transport;
public class TransportHandlerException extends Exception { public class TransportHandlerException extends Exception {
private static final long serialVersionUID = 2736466230451105440L; private static final long serialVersionUID = 2736466230451105440L;

@ -16,15 +16,13 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport; package io.entgra.device.mgt.plugins.virtualfirealarm.agent.transport;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.core.AgentConstants; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.core.AgentConstants;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport.TransportHandlerException;
import java.io.BufferedReader; import java.io.BufferedReader;
import java.io.File;
import java.io.IOException; import java.io.IOException;
import java.io.InputStreamReader; import java.io.InputStreamReader;
import java.net.DatagramSocket; import java.net.DatagramSocket;
@ -42,7 +40,6 @@ import java.util.ArrayList;
import java.util.Enumeration; import java.util.Enumeration;
import java.util.HashMap; import java.util.HashMap;
import java.util.Map; import java.util.Map;
import java.util.Random;
public class TransportUtils { public class TransportUtils {
private static final Log log = LogFactory.getLog(TransportUtils.class); private static final Log log = LogFactory.getLog(TransportUtils.class);

@ -16,13 +16,13 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport.http; package io.entgra.device.mgt.plugins.virtualfirealarm.agent.transport.http;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
import org.eclipse.jetty.server.Server; import org.eclipse.jetty.server.Server;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport.TransportHandler; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.transport.TransportHandler;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport.TransportUtils; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.transport.TransportUtils;
/** /**
* This is an abstract class that implements the "TransportHandler" interface. The interface is an abstraction for * This is an abstract class that implements the "TransportHandler" interface. The interface is an abstraction for

@ -16,7 +16,7 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport.mqtt; package io.entgra.device.mgt.plugins.virtualfirealarm.agent.transport.mqtt;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
@ -27,9 +27,8 @@ import org.eclipse.paho.client.mqttv3.MqttConnectOptions;
import org.eclipse.paho.client.mqttv3.MqttException; import org.eclipse.paho.client.mqttv3.MqttException;
import org.eclipse.paho.client.mqttv3.MqttMessage; import org.eclipse.paho.client.mqttv3.MqttMessage;
import org.eclipse.paho.client.mqttv3.MqttSecurityException; import org.eclipse.paho.client.mqttv3.MqttSecurityException;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.core.AgentManager; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.transport.TransportHandler;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport.TransportHandler; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.transport.TransportHandlerException;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport.TransportHandlerException;
import java.io.File; import java.io.File;
import java.nio.charset.StandardCharsets; import java.nio.charset.StandardCharsets;

@ -16,7 +16,7 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport.xmpp; package io.entgra.device.mgt.plugins.virtualfirealarm.agent.transport.xmpp;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
@ -33,8 +33,8 @@ import org.jivesoftware.smack.filter.PacketTypeFilter;
import org.jivesoftware.smack.filter.ToContainsFilter; import org.jivesoftware.smack.filter.ToContainsFilter;
import org.jivesoftware.smack.packet.Message; import org.jivesoftware.smack.packet.Message;
import org.jivesoftware.smack.packet.Packet; import org.jivesoftware.smack.packet.Packet;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport.TransportHandler; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.transport.TransportHandler;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.transport.TransportHandlerException; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.transport.TransportHandlerException;
/** /**
* This is an abstract class that implements the "TransportHandler" interface. The interface is an abstraction for * This is an abstract class that implements the "TransportHandler" interface. The interface is an abstraction for

@ -16,13 +16,13 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.virtual; package io.entgra.device.mgt.plugins.virtualfirealarm.agent.virtual;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.core.AgentConstants; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.core.AgentConstants;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.core.AgentUtilOperations; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.core.AgentUtilOperations;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.virtual.ui.AgentUI; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.virtual.ui.AgentUI;
import javax.sound.midi.InvalidMidiDataException; import javax.sound.midi.InvalidMidiDataException;
import javax.sound.midi.MidiSystem; import javax.sound.midi.MidiSystem;

@ -16,11 +16,11 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.virtual.ui; package io.entgra.device.mgt.plugins.virtualfirealarm.agent.virtual.ui;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.core.AgentConstants; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.core.AgentConstants;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.core.AgentManager; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.core.AgentManager;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.virtual.VirtualHardwareManager; import io.entgra.device.mgt.plugins.virtualfirealarm.agent.virtual.VirtualHardwareManager;
import java.awt.*; import java.awt.*;
import java.net.URL; import java.net.URL;

@ -16,7 +16,7 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl; package io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl;
import io.swagger.annotations.*; import io.swagger.annotations.*;
import org.wso2.carbon.apimgt.annotations.api.Scope; import org.wso2.carbon.apimgt.annotations.api.Scope;

@ -16,7 +16,7 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl; package io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
@ -33,17 +33,17 @@ import org.wso2.carbon.device.mgt.common.exceptions.InvalidDeviceException;
import org.wso2.carbon.device.mgt.common.group.mgt.DeviceGroupConstants; import org.wso2.carbon.device.mgt.common.group.mgt.DeviceGroupConstants;
import org.wso2.carbon.device.mgt.common.operation.mgt.OperationManagementException; import org.wso2.carbon.device.mgt.common.operation.mgt.OperationManagementException;
import org.wso2.carbon.device.mgt.core.operation.mgt.ConfigOperation; import org.wso2.carbon.device.mgt.core.operation.mgt.ConfigOperation;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.constants.VirtualFireAlarmConstants; import io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.constants.VirtualFireAlarmConstants;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.dao.DeviceEventsDAO; import io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.dao.DeviceEventsDAO;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.dao.DeviceEventsDAOImpl; import io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.dao.DeviceEventsDAOImpl;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.dto.SensorRecord; import io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.dto.SensorRecord;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.util.APIUtil; import io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.util.APIUtil;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.util.ZipArchive; import io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.util.ZipArchive;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.util.ZipUtil; import io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.util.ZipUtil;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.xmpp.VirtualFirealarmXMPPException; import io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.xmpp.VirtualFirealarmXMPPException;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.xmpp.XmppAccount; import io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.xmpp.XmppAccount;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.xmpp.XmppConfig; import io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.xmpp.XmppConfig;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.xmpp.XmppServerClient; import io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.xmpp.XmppServerClient;
import org.wso2.carbon.identity.jwt.client.extension.JWTClient; import org.wso2.carbon.identity.jwt.client.extension.JWTClient;
import org.wso2.carbon.identity.jwt.client.extension.dto.AccessTokenInfo; import org.wso2.carbon.identity.jwt.client.extension.dto.AccessTokenInfo;
import org.wso2.carbon.identity.jwt.client.extension.exception.JWTClientException; import org.wso2.carbon.identity.jwt.client.extension.exception.JWTClientException;

@ -16,7 +16,7 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.constants; package io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.constants;
public class VirtualFireAlarmConstants { public class VirtualFireAlarmConstants {
public final static String DEVICE_TYPE = "virtual_firealarm"; public final static String DEVICE_TYPE = "virtual_firealarm";

@ -17,9 +17,9 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.dao; package io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.dao;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.dto.SensorRecord; import io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.dto.SensorRecord;
public interface DeviceEventsDAO { public interface DeviceEventsDAO {

@ -17,7 +17,7 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.dao; package io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.dao;
import org.wso2.carbon.device.mgt.common.exceptions.*; import org.wso2.carbon.device.mgt.common.exceptions.*;
import org.wso2.carbon.device.mgt.core.dao.util.*; import org.wso2.carbon.device.mgt.core.dao.util.*;

@ -17,11 +17,11 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.dao; package io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.dao;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.dto.SensorRecord; import io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.dto.SensorRecord;
import org.wso2.carbon.device.mgt.common.exceptions.*; import org.wso2.carbon.device.mgt.common.exceptions.*;
import java.sql.Connection; import java.sql.Connection;

@ -1,12 +1,9 @@
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.dto; package io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.dto;
import org.codehaus.jackson.annotate.JsonIgnoreProperties; import org.codehaus.jackson.annotate.JsonIgnoreProperties;
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlElementWrapper; import javax.xml.bind.annotation.XmlElementWrapper;
import javax.xml.bind.annotation.XmlRootElement; import javax.xml.bind.annotation.XmlRootElement;
import java.util.ArrayList;
import java.util.List;
import java.util.Map; import java.util.Map;
@XmlRootElement @XmlRootElement

@ -16,7 +16,7 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.exception; package io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.exception;
public class VirtualFireAlarmException extends Exception { public class VirtualFireAlarmException extends Exception {
private static final long serialVersionUID = 118512086957330189L; private static final long serialVersionUID = 118512086957330189L;

@ -13,13 +13,13 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.listener; package io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.listener;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
import org.wso2.carbon.CarbonConstants; import org.wso2.carbon.CarbonConstants;
import org.wso2.carbon.context.PrivilegedCarbonContext; import org.wso2.carbon.context.PrivilegedCarbonContext;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.constants.VirtualFireAlarmConstants; import io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.constants.VirtualFireAlarmConstants;
import org.wso2.carbon.user.api.AuthorizationManager; import org.wso2.carbon.user.api.AuthorizationManager;
import org.wso2.carbon.user.api.Permission; import org.wso2.carbon.user.api.Permission;
import org.wso2.carbon.user.api.UserStoreException; import org.wso2.carbon.user.api.UserStoreException;

@ -1,4 +1,4 @@
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.util; package io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.util;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;

@ -16,9 +16,7 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.util; package io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.util;
import java.util.zip.ZipOutputStream;
/** /**
* This is an utility class to hold zip files. * This is an utility class to hold zip files.

@ -16,7 +16,7 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.util; package io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.util;
import org.apache.commons.codec.binary.Base64; import org.apache.commons.codec.binary.Base64;
import org.apache.commons.io.IOUtils; import org.apache.commons.io.IOUtils;
@ -29,7 +29,7 @@ import org.wso2.carbon.device.mgt.common.exceptions.DeviceManagementException;
import org.wso2.carbon.device.mgt.common.configuration.mgt.ConfigurationEntry; import org.wso2.carbon.device.mgt.common.configuration.mgt.ConfigurationEntry;
import org.wso2.carbon.device.mgt.common.configuration.mgt.ConfigurationManagementException; import org.wso2.carbon.device.mgt.common.configuration.mgt.ConfigurationManagementException;
import org.wso2.carbon.device.mgt.common.configuration.mgt.PlatformConfiguration; import org.wso2.carbon.device.mgt.common.configuration.mgt.PlatformConfiguration;
import org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.xmpp.XmppConfig; import io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.xmpp.XmppConfig;
import org.wso2.carbon.utils.CarbonUtils; import org.wso2.carbon.utils.CarbonUtils;
import java.io.BufferedOutputStream; import java.io.BufferedOutputStream;

@ -15,7 +15,7 @@
* specific language governing permissions and limitations * specific language governing permissions and limitations
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.xmpp; package io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.xmpp;
public class VirtualFirealarmXMPPException extends Exception{ public class VirtualFirealarmXMPPException extends Exception{

@ -16,7 +16,7 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.xmpp; package io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.xmpp;
/** /**
* holds the information related to account that needs to be created on xmpp server. * holds the information related to account that needs to be created on xmpp server.

@ -16,7 +16,7 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.xmpp; package io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.xmpp;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;

@ -16,7 +16,7 @@
* under the License. * under the License.
*/ */
package org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.xmpp; package io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.xmpp;
import org.jivesoftware.smack.AccountManager; import org.jivesoftware.smack.AccountManager;
import org.jivesoftware.smack.ConnectionConfiguration; import org.jivesoftware.smack.ConnectionConfiguration;

@ -26,7 +26,7 @@
<jaxrs:server id="VirtualFireAlarm" address="/"> <jaxrs:server id="VirtualFireAlarm" address="/">
<jaxrs:serviceBeans> <jaxrs:serviceBeans>
<bean id="VirtualFireAlarmService" <bean id="VirtualFireAlarmService"
class="org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.VirtualFireAlarmServiceImpl"> class="io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.VirtualFireAlarmServiceImpl">
</bean> </bean>
</jaxrs:serviceBeans> </jaxrs:serviceBeans>
<jaxrs:providers> <jaxrs:providers>

@ -32,7 +32,7 @@
</context-param> </context-param>
<listener> <listener>
<listener-class>org.wso2.carbon.device.mgt.iot.virtualfirealarm.service.impl.listener.VirtualFireAlarmPermissionUpdateListener</listener-class> <listener-class>io.entgra.device.mgt.plugins.virtualfirealarm.api.service.impl.listener.VirtualFireAlarmPermissionUpdateListener</listener-class>
</listener> </listener>
</web-app> </web-app>
Loading…
Cancel
Save