예제 #1
0
        public string SetCamera(string json)
        {
            if (_channel == null)
            {
                return(cNeedConnect);
            }

            try
            {
                if (_channel.SetCamera(json))
                {
                    return(cSuccess);
                }
            }
            catch (Exception ex)
            {
                if (ex is FaultException <EarthNamedpipeFault> )
                {
                    return((ex as FaultException <EarthNamedpipeFault>).Message);
                }
                else
                {
                    return(ex.Message);
                }
            }

            return(cFailed);
        }
예제 #2
0
        public bool SetCamera(string json)
        {
            if (_channel == null)
            {
                return(false);
            }

            try
            {
                if (_channel.SetCamera(json))
                {
                    return(true);
                }
                else
                {
                    return(false);
                }
            }
            catch
            {
                return(false);
            }
        }