Beispiel #1
0
        public ApolloRouteInfoBase CopyInstance()
        {
            ApolloRouteInfoBase base2 = this.onCopyInstance();

            if (base2 != null)
            {
                base2.RouteType = this.RouteType;
            }
            return(base2);
        }
Beispiel #2
0
        public ApolloRouteInfoBase CopyInstance()
        {
            ApolloRouteInfoBase apolloRouteInfoBase = this.onCopyInstance();

            if (apolloRouteInfoBase != null)
            {
                apolloRouteInfoBase.RouteType = this.RouteType;
            }
            return(apolloRouteInfoBase);
        }
Beispiel #3
0
 public ApolloResult SetRouteInfo(ApolloRouteInfoBase routeInfo)
 {
     if (routeInfo == null)
     {
         return(ApolloResult.InvalidArgument);
     }
     byte[] array;
     routeInfo.Encode(out array);
     if (array == null)
     {
         ADebug.LogError("WriteData Encode error!");
         return(ApolloResult.InnerError);
     }
     return(ApolloConnector.apollo_connector_setRouteInfo(base.ObjectId, array, array.Length));
 }
Beispiel #4
0
 public ApolloResult SetRouteInfo(ApolloRouteInfoBase routeInfo)
 {
     byte[] buffer;
     if (routeInfo == null)
     {
         return(ApolloResult.InvalidArgument);
     }
     routeInfo.Encode(out buffer);
     if (buffer == null)
     {
         ADebug.LogError("WriteData Encode error!");
         return(ApolloResult.InnerError);
     }
     return(apollo_connector_setRouteInfo(base.ObjectId, buffer, buffer.Length));
 }
Beispiel #5
0
 public ApolloResult WriteData(byte[] data, int len, ApolloRouteInfoBase routeInfo, bool allowLost = false)
 {
     if (routeInfo == null)
     {
         return(ApolloResult.InvalidArgument);
     }
     if (!this.Connected)
     {
         return(ApolloResult.NoConnection);
     }
     if (len == -1)
     {
         len = data.Length;
     }
     byte[] array;
     routeInfo.Encode(out array);
     if (array == null)
     {
         ADebug.LogError("WriteData Encode error!");
         return(ApolloResult.InnerError);
     }
     return(ApolloConnector.apollo_connector_writeData_with_route_info(base.ObjectId, data, len, array, array.Length, allowLost));
 }