All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.github.lunasaw.gb28181.common.entity.notify.DeviceUpdateNotify Maven / Gradle / Ivy

The newest version!
package io.github.lunasaw.gb28181.common.entity.notify;

import javax.xml.bind.annotation.*;

import io.github.lunasaw.gb28181.common.entity.base.DeviceBase;
import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
import org.assertj.core.util.Lists;

import java.util.List;

/**
 * 
 * 
 * Catalog
 * 422214
 * device_001
 * 1
 * 
 * 
 * 33010602011187000001
 * Channel 1
 * 
 * 0
 * ABC Inc.
 * 
 * 1
 * ON
 * Model 123
 *  John Doe
 * 123456
 * 
123 Main St.
* Event *
*
*
* @author luna */ @Getter @Setter @AllArgsConstructor @NoArgsConstructor @XmlRootElement(name = "Notify") @XmlAccessorType(XmlAccessType.FIELD) public class DeviceUpdateNotify extends DeviceBase { @XmlElement(name = "SumNum") private int sumNum; @XmlElement(name = "Item") @XmlElementWrapper(name = "DeviceList") private List deviceItemList; public DeviceUpdateNotify(String cmdType, String sn, String deviceId) { super(cmdType, sn, deviceId); } public static void main(String[] args) { DeviceUpdateNotify deviceUpdateNotify = new DeviceUpdateNotify(); deviceUpdateNotify.setDeviceId("123123"); DeviceUpdateItem deviceUpdateItem = new DeviceUpdateItem(); deviceUpdateItem.setDeviceId("33010602011187000001"); deviceUpdateItem.setName("Channel 1"); deviceUpdateItem.setParentId(null); deviceUpdateItem.setParental(0); deviceUpdateItem.setManufacturer("ABC Inc."); deviceUpdateItem.setSecrecy(0); deviceUpdateItem.setRegisterWay(1); deviceUpdateItem.setStatus("ON"); deviceUpdateItem.setModel("model"); deviceUpdateItem.setOwner("John Dow"); deviceUpdateItem.setCivilCode("123456"); deviceUpdateItem.setEvent("event"); deviceUpdateNotify.setDeviceItemList(Lists.newArrayList(deviceUpdateItem)); deviceUpdateNotify.setSumNum(1); System.out.println(deviceUpdateNotify); } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy