Beispiel #1
0
        public static TivoTree FromDictionary(IDictionary <string, string> dictionary)
        {
            TivoTree tree = new TivoTree();

            foreach (var entry in dictionary)
            {
                tree.Add(entry.Key, entry.Value);
            }
            return(tree);
        }
Beispiel #2
0
        public static TivoTree FromNameValueCollection(System.Collections.Specialized.NameValueCollection collection)
        {
            TivoTree tree  = new TivoTree();
            int      count = collection.Count;

            for (int i = 0; i < count; ++i)
            {
                tree.AddRange(collection.GetKey(i), collection.GetValues(i));
            }
            return(tree);
        }
Beispiel #3
0
        public void Add(string key, TivoTree value)
        {
            List <object> values;

            if (_internalDictionary.TryGetValue(key, out values))
            {
                values.Add(value);
            }
            else
            {
                values = new List <object>();
                values.Add(value);
                _internalDictionary.Add(key, values);
            }
        }
 public ApplicationParametersReceivedArgs(TivoTree parameters, byte[] data)
 {
     Parameters = parameters;
     SavedData  = data;
 }
Beispiel #5
0
 public bool Remove(TivoTree item)
 {
     return(_values.Remove(item));
 }
Beispiel #6
0
 public bool Contains(TivoTree item)
 {
     return(_values.Contains(item));
 }
Beispiel #7
0
 public void Add(TivoTree item)
 {
     _values.Add(item);
 }
Beispiel #8
0
 public void Insert(int index, TivoTree item)
 {
     _values.Insert(index, item);
 }
Beispiel #9
0
 public int IndexOf(TivoTree item)
 {
     return(_values.IndexOf(item));
 }
Beispiel #10
0
 public bool TryGetTivoTreeValue(string key, int index, out TivoTree value)
 {
     return(TryGetValue <TivoTree>(key, index, out value));
 }
Beispiel #11
0
 public void TransitionStartNew(Uri destination, TivoTree parameters)
 {
     TransitionStartNew(destination.OriginalString, parameters);
 }
Beispiel #12
0
 public void TransitionStartNew(string destination, TivoTree parameters)
 {
     PostCommand(new ReceiverTransition(destination, Transition.Teleport, parameters, null));
 }
Beispiel #13
0
 public void TransitionBack(TivoTree parameters)
 {
     PostCommand(new ReceiverTransition(null, Transition.Back, parameters, null));
 }
Beispiel #14
0
 public void TransitionForward(Uri destination, TivoTree parameters, byte[] savedData)
 {
     TransitionForward(destination.OriginalString, parameters, savedData);
 }
Beispiel #15
0
 public void TransitionForward(string destination, TivoTree parameters, byte[] savedData)
 {
     PostCommand(new ReceiverTransition(destination, Transition.Forward, parameters, savedData));
 }