예제 #1
0
 internal void UpdateFrom(Proxy_SDN_controller proxy)
 {
     uuid     = proxy.uuid == null ? null : proxy.uuid;
     protocol = proxy.protocol == null ? (sdn_controller_protocol)0 : (sdn_controller_protocol)Helper.EnumParseDefault(typeof(sdn_controller_protocol), (string)proxy.protocol);
     address  = proxy.address == null ? null : proxy.address;
     port     = proxy.port == null ? 0 : long.Parse(proxy.port);
 }
예제 #2
0
        public Proxy_SDN_controller ToProxy()
        {
            Proxy_SDN_controller result_ = new Proxy_SDN_controller();

            result_.uuid     = uuid ?? "";
            result_.protocol = sdn_controller_protocol_helper.ToString(protocol);
            result_.address  = address ?? "";
            result_.port     = port.ToString();
            return(result_);
        }
예제 #3
0
        public Proxy_SDN_controller ToProxy()
        {
            Proxy_SDN_controller result_ = new Proxy_SDN_controller();

            result_.uuid     = (uuid != null) ? uuid : "";
            result_.protocol = sdn_controller_protocol_helper.ToString(protocol);
            result_.address  = (address != null) ? address : "";
            result_.port     = port.ToString();
            return(result_);
        }
예제 #4
0
 /// <summary>
 /// Creates a new SDN_controller from a Proxy_SDN_controller.
 /// </summary>
 /// <param name="proxy"></param>
 public SDN_controller(Proxy_SDN_controller proxy)
 {
     UpdateFrom(proxy);
 }
예제 #5
0
 /// <summary>
 /// Creates a new SDN_controller from a Proxy_SDN_controller.
 /// </summary>
 /// <param name="proxy"></param>
 public SDN_controller(Proxy_SDN_controller proxy)
 {
     this.UpdateFromProxy(proxy);
 }