public void RemoveControlled(IControlled cntrld)
 {
     if (this.cntrld == cntrld)
     {
         this.cntrld = null;
     }
 }
Exemple #2
0
        public virtual ControlledParameterTemplate BuildTemplate(IControlled controlledParameter)
        {
            switch (controlledParameter.ControlledBasis)
            {
            case ControlledBasis.FloatingPoint:
                return(new ControlledDoubleParameterTemplate(controlledParameter));

            case ControlledBasis.Integer:
                return(new ControlledIntParameterTemplate(controlledParameter));

            case ControlledBasis.String:
                return(new ControlledStringParameterTemplate(controlledParameter));

            default:
                UnityEngine.Debug.LogError($"Unexpected ControlledBasis: {controlledParameter.ControlledBasis}");
                return(null);
            }
        }
 public void SetView(IControlled view)
 {
     View = view;
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="MobileClientCommunication"/> class.
 /// </summary>
 /// <param name="view">The view.</param>
 /// <param name="ipaddress">The ipaddress.</param>
 public ClientCommunication(IControlled view, string ipaddress)
 {
     View    = view;
     IP      = ipaddress;
     _client = CreateClient();
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="ClientCommunication"/> class.
 /// </summary>
 /// <param name="view">The view.</param>
 public ClientCommunication(IControlled view)
 {
     View = view;
 }
 public ControlledDoubleParameterTemplate(IControlled controlledParameter)
     : base(controlledParameter)
 {
 }
 public ControlledParameterTemplate(IControlled controlledParameter)
 {
     this.controlledParameter = controlledParameter;
 }
 public ControlledStringParameterTemplate(IControlled controlledParameter)
     : base(controlledParameter)
 {
 }
 public void SetControlled(IControlled cntrld)
 {
     this.cntrld = cntrld;
 }
 public void SetView(IControlled view)
 {
     View = view;
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="MobileClientCommunication"/> class.
 /// </summary>
 /// <param name="view">The view.</param>
 /// <param name="ipaddress">The ipaddress.</param>
 public ClientCommunication(IControlled view, string ipaddress)
 {
     View = view;
     IP = ipaddress;
     _client = CreateClient();
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="ClientCommunication"/> class.
 /// </summary>
 /// <param name="view">The view.</param>
 public ClientCommunication(IControlled view)
 {
     View = view;
 }