Warning, /frameworks/syntax-highlighting/autotests/input/test.fbs is written in an unsupported language. File is not indexed.
0001 // Example IDL file for our monster's schema. 0002 0003 namespace MyGame.Sample; 0004 0005 enum Color:byte { Red = 0, Green, Blue = 2 } 0006 0007 union Equipment { Weapon } // Optionally add more tables. 0008 0009 struct Vec3 { 0010 x:float; 0011 y:float; 0012 z:float; 0013 } 0014 0015 table Monster { 0016 pos:Vec3; // Struct. 0017 mana:short = 150; 0018 hp:short = 100; 0019 name:string; 0020 friendly:bool = false (deprecated); 0021 inventory:[ubyte]; // Vector of scalars. 0022 color:Color = Blue; // Enum. 0023 weapons:[Weapon]; // Vector of tables. 0024 equipped:Equipment; // Union. 0025 path:[Vec3]; // Vector of structs. 0026 } 0027 0028 table Weapon { 0029 name:string; 0030 damage:short; 0031 } 0032 0033 root_type Monster;