Retrives a specifc SofuObject from this Map indentified by key.

C# |
public SofuObject Object( string key )

- key (String)
- Identifies the SofuObject to get

The Object requested


Sofu.Sofu.Map file = SofuReader.LoadFile("file.sofu"); bool debug=false; try { SofuObject val = file.Object("Debug"); debug=true; if (val.isMap()) { Console.Out.WriteLine("Debug Info"); val.AsMap().Write(Console.Out); } if (val.isValue()) { Console.Out.WriteLine(val.AsValue().ToString()); } } catch (SofuNoElementException e){ debug=false; }

Exception | Condition |
---|---|
SofuNoElementException | Will throw SofuNoElementException when the Key is not in this Map |