Example #1
0
        /// <summary>
        /// 实例对象调用链映射测试
        /// </summary>
        /// <returns></returns>
        internal static bool TestCase()
        {
            RemoteKey value = new RemoteKey {
                Id = 1
            };

#if NotSegmentation
            if (value.Remote.NextId != value.NextId)
            {
                return(false);
            }

            if (value.Remote.AddId(2) != value.AddId(2))
            {
                return(false);
            }

            if (value.Remote.RemoteLinkNextId != value.RemoteLink.NextId)
            {
                return(false);
            }

            if (value.Remote.RemoteLink_AddId(3) != value.RemoteLink.AddId(3))
            {
                return(false);
            }
#else
            TcpCall.RemoteKey.RemoteExtension remote = TcpCall.RemoteKey.Remote(value.Id);
            if (remote.NextId != value.NextId)
            {
                return(false);
            }

            if (remote.AddId(2) != value.AddId(2))
            {
                return(false);
            }

            if (remote.RemoteLinkNextId != value.RemoteLink.NextId)
            {
                return(false);
            }

            if (remote.RemoteLink_AddId(3) != value.RemoteLink.AddId(3))
            {
                return(false);
            }
#endif
            return(true);
        }
Example #2
0
 internal int AddId(int value)
 {
     return(Value.AddId(value));
 }