Exemplo n.º 1
0
 public V341QueryDefinition(
     ItemKind itemKind,
     string dataType,
     string[] appScopes,
     string[] itemNames,
     string queryExpr,
     DateTimeOffset asAtTime,
     long minimumUSN,
     bool excludeExisting,
     bool waitForExisting,
     bool excludeDeleted,
     bool excludeDataBody)
 {
     ItemKind        = V341Helpers.ToV341ItemKind(itemKind);
     DataType        = dataType;
     AppScopes       = appScopes;
     ItemNames       = itemNames;
     QueryExpr       = queryExpr;
     AsAtTime        = asAtTime;
     MinimumUSN      = minimumUSN;
     ExcludeExisting = excludeExisting;
     WaitForExisting = waitForExisting;
     ExcludeDeleted  = excludeDeleted;
     ExcludeDataBody = excludeDataBody;
 }
Exemplo n.º 2
0
        public static ItemKind ToItemKind(V341ItemKind itemKind)
        {
            switch (itemKind)
            {
            case V341ItemKind.Undefined: return(ItemKind.Undefined);

            case V341ItemKind.Object: return(ItemKind.Object);

            case V341ItemKind.System: return(ItemKind.System);

            case V341ItemKind.Event: return(ItemKind.Signal);

            case V341ItemKind.Debug: return(ItemKind.Debug);

            case V341ItemKind.Local: return(ItemKind.Local);

            default: throw new ArgumentException($"Unknown V341ItemKind: {itemKind}");
            }
        }
Exemplo n.º 3
0
 public V341TransportItem(CommonItem item, bool excludeDataBody)
 {
     ItemId    = item.Id;
     ItemKind  = V341Helpers.ToV341ItemKind(item.ItemKind);
     Transient = item.Transient;
     ItemName  = item.Name;
     AppProps  = item.AppProps.Serialise();
     SysProps  = item.SysProps.Serialise();
     DataType  = item.DataTypeName;
     AppScope  = item.AppScope;
     NetScope  = item.NetScope;
     Created   = item.Created;
     Expires   = item.Expires;
     SourceUSN = item.StoreUSN;
     if (!excludeDataBody)
     {
         YData = item.YData;
         YSign = item.YSign;
     }
 }