Adding swagger annotations to beans

revert-70aa11f8
Madhawa Perera 9 years ago
commit 66c12a8b1c

@ -83,7 +83,7 @@
javax.xml.bind, javax.xml.bind,
org.wso2.carbon.utils.*, org.wso2.carbon.utils.*,
org.wso2.carbon.device.mgt.common.*, org.wso2.carbon.device.mgt.common.*,
io.swagger.annotations.*, io.swagger.annotations.*;resolution:=optional,
org.wso2.carbon.device.mgt.core.*, org.wso2.carbon.device.mgt.core.*,
org.bouncycastle.pkcs.jcajce org.bouncycastle.pkcs.jcajce
</Import-Package> </Import-Package>

@ -48,6 +48,10 @@
<Export-Package> <Export-Package>
org.wso2.carbon.device.mgt.common.* org.wso2.carbon.device.mgt.common.*
</Export-Package> </Export-Package>
<Import-Package>
javax.xml.bind.annotation,
io.swagger.annotations.*;resolution:=optional
</Import-Package>
</instructions> </instructions>
</configuration> </configuration>
</plugin> </plugin>

@ -18,26 +18,41 @@
*/ */
package org.wso2.carbon.device.mgt.common.app.mgt; package org.wso2.carbon.device.mgt.common.app.mgt;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.io.Serializable; import java.io.Serializable;
import java.util.Properties; import java.util.Properties;
@ApiModel(value = "Application", description = "This class carries all information related application")
public class Application implements Serializable { public class Application implements Serializable {
private static final long serialVersionUID = 1998101711L; private static final long serialVersionUID = 1998101711L;
@ApiModelProperty(name = "id", value = "The ID given to the application when it is stored in the EMM database", required = true)
private int id; private int id;
@ApiModelProperty(name = "platform", value = "The mobile device platform. It can be android, ios or windows", required = true)
private String platform; private String platform;
@ApiModelProperty(name = "category", value = "The application category", required = true)
private String category; private String category;
@ApiModelProperty(name = "name", value = "The application's name", required = true)
private String name; private String name;
private String locationUrl; private String locationUrl;
@ApiModelProperty(name = "imageUrl", value = "The icon url of the application", required = true)
private String imageUrl; private String imageUrl;
@ApiModelProperty(name = "version", value = "The application's version", required = true)
private String version; private String version;
@ApiModelProperty(name = "type", value = "The application type", required = true)
private String type; private String type;
@ApiModelProperty(name = "appProperties", value = "The properties of the application", required = true)
private Properties appProperties; private Properties appProperties;
@ApiModelProperty(name = "applicationIdentifier", value = "The application identifier", required = true)
private String applicationIdentifier; private String applicationIdentifier;
@ApiModelProperty(name = "memoryUsage", value = "AMount of memory used by the application", required = true)
private int memoryUsage; private int memoryUsage;
public String getType() { public String getType() {
return type; return type;
} }

@ -83,7 +83,7 @@
org.apache.catalina.core, org.apache.catalina.core,
org.apache.commons.collections, org.apache.commons.collections,
org.wso2.carbon.email.sender.*, org.wso2.carbon.email.sender.*,
io.swagger.annotations.*, io.swagger.annotations.*;resolution:=optional,
org.wso2.carbon, org.wso2.carbon,
org.wso2.carbon.base org.wso2.carbon.base
</Import-Package> </Import-Package>

Loading…
Cancel
Save