Skip to content

Commit

Permalink
Fixup
Browse files Browse the repository at this point in the history
Signed-off-by: coduz <alberto.codutti@eurotech.com>
  • Loading branch information
Coduz committed Oct 5, 2020
1 parent db261a6 commit 554727c
Showing 6 changed files with 53 additions and 94 deletions.
Original file line number Diff line number Diff line change
@@ -16,6 +16,7 @@
import org.eclipse.kapua.model.id.KapuaIdAdapter;

import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlType;
import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;

/**
@@ -25,6 +26,7 @@
*
* @since 1.0.0
*/
@XmlType(propOrder = {"scopeId"})
public interface Storable extends KapuaSerializable {

/**
Original file line number Diff line number Diff line change
@@ -33,7 +33,6 @@
@XmlAccessorType(XmlAccessType.PROPERTY)
@XmlType(propOrder = {
"id",
"scopeId",
"clientId",
"name",
"firstMessageId",
@@ -44,19 +43,19 @@
public interface ChannelInfo extends Storable {

/**
* Get the record identifier
* Gets the {@link StorableId}
*
* @return
* @return The {@link StorableId}
* @since 1.0.0
*/
@XmlElement(name = "id")
@XmlJavaTypeAdapter(StorableIdXmlAdapter.class)
StorableId getId();

/**
* Set the record identifier
* Sets the {@link StorableId}
*
* @param id
* @param id The {@link StorableId}
* @since 1.0.0
*/
@XmlElement(name = "id")
Original file line number Diff line number Diff line change
@@ -24,7 +24,7 @@
* @since 1.0
*/
@XmlRootElement(name = "channelInfos")
@XmlType(factoryClass = ChannelInfoXmlRegistry.class, factoryMethod = "newResult")
@XmlType(factoryClass = ChannelInfoXmlRegistry.class, factoryMethod = "newListResult")
public interface ChannelInfoListResult extends StorableListResult<ChannelInfo> {

}
Original file line number Diff line number Diff line change
@@ -11,8 +11,6 @@
*******************************************************************************/
package org.eclipse.kapua.service.datastore.model;

import org.eclipse.kapua.model.id.KapuaId;
import org.eclipse.kapua.model.id.KapuaIdAdapter;
import org.eclipse.kapua.model.xml.DateXmlAdapter;
import org.eclipse.kapua.service.storable.model.Storable;
import org.eclipse.kapua.service.storable.model.id.StorableId;
@@ -35,7 +33,6 @@
@XmlAccessorType(XmlAccessType.PROPERTY)
@XmlType(propOrder = { //
"id", //
"scopeId", //
"clientId", //
"firstMessageId", //
"firstMessageOn", //
@@ -45,35 +42,25 @@
public interface ClientInfo extends Storable {

/**
* Get the record identifier
* Gets the {@link StorableId}
*
* @return
* @return The {@link StorableId}
* @since 1.0.0
*/
@XmlElement(name = "id")
@XmlJavaTypeAdapter(StorableIdXmlAdapter.class)
StorableId getId();

/**
* Set the record identifier
* Sets the {@link StorableId}
*
* @param id
* @param id The {@link StorableId}
* @since 1.0.0
*/
@XmlElement(name = "id")
@XmlJavaTypeAdapter(StorableIdXmlAdapter.class)
void setId(StorableId id);

/**
* Get the scope id
*
* @return
* @since 1.0.0
*/
@XmlElement(name = "scopeId")
@XmlJavaTypeAdapter(KapuaIdAdapter.class)
KapuaId getScopeId();

/**
* Get the client identifier
*
Original file line number Diff line number Diff line change
@@ -37,22 +37,36 @@
*/
@XmlRootElement(name = "message")
@XmlAccessorType(XmlAccessType.PROPERTY)
@XmlType(propOrder = { //
"id", //
"datastoreId", //
"timestamp", //
"scopeId", //
"deviceId", //
"clientId", //
"receivedOn", //
"sentOn", //
"capturedOn", //
"position", //
"channel", //
"payload", //
}) //
@XmlType(propOrder = {
"id",
"datastoreId",
"timestamp",
"deviceId",
"clientId",
"receivedOn",
"sentOn",
"capturedOn",
"position",
"channel",
"payload",
})
public interface DatastoreMessage extends Storable {

/**
* Get the message identifier
*
* @return
*/
@XmlElement(name = "id")
UUID getId();

/**
* Set the message identifier
*
* @param id
*/
void setId(UUID id);

/**
* Stored message identifier
*
@@ -79,37 +93,6 @@ public interface DatastoreMessage extends Storable {
*/
void setTimestamp(Date timestamp);

/**
* Get the message identifier
*
* @return
*/
@XmlElement(name = "id")
UUID getId();

/**
* Set the message identifier
*
* @param id
*/
void setId(UUID id);

/**
* Get scope identifier
*
* @return
*/
@XmlElement(name = "scopeId")
@XmlJavaTypeAdapter(KapuaIdAdapter.class)
KapuaId getScopeId();

/**
* Set scope identifier
*
* @param scopeId
*/
void setScopeId(KapuaId scopeId);

/**
* Get client identifier
*
Original file line number Diff line number Diff line change
@@ -11,8 +11,6 @@
*******************************************************************************/
package org.eclipse.kapua.service.datastore.model;

import org.eclipse.kapua.model.id.KapuaId;
import org.eclipse.kapua.model.id.KapuaIdAdapter;
import org.eclipse.kapua.model.xml.DateXmlAdapter;
import org.eclipse.kapua.service.storable.model.Storable;
import org.eclipse.kapua.service.storable.model.id.StorableId;
@@ -34,49 +32,39 @@
*/
@XmlRootElement(name = "metricInfo")
@XmlAccessorType(XmlAccessType.PROPERTY)
@XmlType(propOrder = { //
"id", //
"scopeId", //
"clientId", //
"channel", //
"name", //
"metricType", //
"firstMessageId", //
"firstMessageOn", //
"lastMessageId", //
@XmlType(propOrder = {
"id",
"clientId",
"channel",
"name",
"metricType",
"firstMessageId",
"firstMessageOn",
"lastMessageId",
"lastMessageOn"})
public interface MetricInfo extends Storable {


/**
* Get the record identifier
* Gets the {@link StorableId}
*
* @return
* @return The {@link StorableId}
* @since 1.0.0
*/
@XmlElement(name = "id")
@XmlJavaTypeAdapter(StorableIdXmlAdapter.class)
StorableId getId();

/**
* Set the record identifier
* Sets the {@link StorableId}
*
* @param id
* @param id The {@link StorableId}
* @since 1.0.0
*/
@XmlElement(name = "id")
@XmlJavaTypeAdapter(StorableIdXmlAdapter.class)
void setId(StorableId id);

/**
* Get the scope id
*
* @return
* @since 1.0.0
*/
@XmlElement(name = "scopeId")
@XmlJavaTypeAdapter(KapuaIdAdapter.class)
KapuaId getScopeId();

/**
* Get the client identifier
*

0 comments on commit 554727c

Please sign in to comment.