Esempio n. 1
0
 /// <summary>
 /// Exports PlantUML
 /// </summary>
 /// <param name="Output">Output</param>
 /// <param name="Indentation">Number of tabs to indent.</param>
 /// <param name="QuoteChar">Quote character.</param>
 public override void ExportPlantUml(StreamWriter Output, int Indentation, char QuoteChar)
 {
     Indent(Output, Indentation);
     Output.Write(":ReportFields(");
     Output.Write(NewMomentaryValues.Join(NewMomentaryValues.GetThingReferences(this.fields)));
     Output.WriteLine(");");
 }
Esempio n. 2
0
        /// <summary>
        /// Gets referenced node references
        /// </summary>
        /// <param name="Nodes">Node references</param>
        /// <returns>Node references</returns>
        public static string[] GetThingReferences(ThingReference[] Nodes)
        {
            SortedDictionary <string, bool> Sorted = new SortedDictionary <string, bool>();

            foreach (ThingReference Node in Nodes)
            {
                Sorted[NewMomentaryValues.GetReference(Node)] = true;
            }

            string[] Result = new string[Sorted.Count];
            Sorted.Keys.CopyTo(Result, 0);

            return(Result);
        }
Esempio n. 3
0
        /// <summary>
        /// Exports PlantUML
        /// </summary>
        /// <param name="Output">Output</param>
        /// <param name="Indentation">Number of tabs to indent.</param>
        /// <param name="QuoteChar">Quote character.</param>
        public override void ExportPlantUml(StreamWriter Output, int Indentation, char QuoteChar)
        {
            Indent(Output, Indentation);
            Output.Write(":ControlActuator(");
            Output.Write(this.controller.Value);
            Output.Write(", ");
            Output.Write(this.to.Value);

            string s = NewMomentaryValues.Join(GetThingReferences(this.nodes));

            if (!string.IsNullOrEmpty(s))
            {
                Output.Write(", ");
                Output.Write(s);
            }

            Output.WriteLine(");");
        }