You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

llama.native.llamagrammarelement.md 1.8 kB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596
  1. # LLamaGrammarElement
  2. Namespace: LLama.Native
  3. An element of a grammar
  4. ```csharp
  5. public struct LLamaGrammarElement
  6. ```
  7. Inheritance [Object](https://docs.microsoft.com/en-us/dotnet/api/system.object) → [ValueType](https://docs.microsoft.com/en-us/dotnet/api/system.valuetype) → [LLamaGrammarElement](./llama.native.llamagrammarelement.md)<br>
  8. Implements [IEquatable&lt;LLamaGrammarElement&gt;](https://docs.microsoft.com/en-us/dotnet/api/system.iequatable-1)
  9. ## Fields
  10. ### **Type**
  11. The type of this element
  12. ```csharp
  13. public LLamaGrammarElementType Type;
  14. ```
  15. ### **Value**
  16. Unicode code point or rule ID
  17. ```csharp
  18. public uint Value;
  19. ```
  20. ## Constructors
  21. ### **LLamaGrammarElement(LLamaGrammarElementType, UInt32)**
  22. Construct a new LLamaGrammarElement
  23. ```csharp
  24. LLamaGrammarElement(LLamaGrammarElementType type, uint value)
  25. ```
  26. #### Parameters
  27. `type` [LLamaGrammarElementType](./llama.native.llamagrammarelementtype.md)<br>
  28. `value` [UInt32](https://docs.microsoft.com/en-us/dotnet/api/system.uint32)<br>
  29. ## Methods
  30. ### **Equals(LLamaGrammarElement)**
  31. ```csharp
  32. bool Equals(LLamaGrammarElement other)
  33. ```
  34. #### Parameters
  35. `other` [LLamaGrammarElement](./llama.native.llamagrammarelement.md)<br>
  36. #### Returns
  37. [Boolean](https://docs.microsoft.com/en-us/dotnet/api/system.boolean)<br>
  38. ### **Equals(Object)**
  39. ```csharp
  40. bool Equals(object obj)
  41. ```
  42. #### Parameters
  43. `obj` [Object](https://docs.microsoft.com/en-us/dotnet/api/system.object)<br>
  44. #### Returns
  45. [Boolean](https://docs.microsoft.com/en-us/dotnet/api/system.boolean)<br>
  46. ### **GetHashCode()**
  47. ```csharp
  48. int GetHashCode()
  49. ```
  50. #### Returns
  51. [Int32](https://docs.microsoft.com/en-us/dotnet/api/system.int32)<br>
  52. ### **IsCharElement()**
  53. ```csharp
  54. bool IsCharElement()
  55. ```
  56. #### Returns
  57. [Boolean](https://docs.microsoft.com/en-us/dotnet/api/system.boolean)<br>