# BitsAndBytes class

Namespace: [Grasshopper2.Types.Conversion](https://developer.rhino3d.com/api/gh2/namespace/grasshopper2.types.conversion.md) · Assembly: [Grasshopper2](https://developer.rhino3d.com/api/gh2/assembly/grasshopper2.md)

```cs
public static class BitsAndBytes
```

Provides conversion methods for bit and byte arrays to and from strings.

## Methods

- [BitArrayToString](https://developer.rhino3d.com/api/gh2/type/grasshopper2.types.conversion.bitsandbytes/bitarraytostring.md): (static) Convert a bitarray to a sequence of '0' and '1' characters.
- [ByteArrayToString](https://developer.rhino3d.com/api/gh2/type/grasshopper2.types.conversion.bitsandbytes/bytearraytostring.md): (static) Convert a byte array to a string.
- [StringToBitArray](https://developer.rhino3d.com/api/gh2/type/grasshopper2.types.conversion.bitsandbytes/stringtobitarray.md): (static) Convert a string created with the BitArrayToString method back into a bit array.
- [StringToByteArray](https://developer.rhino3d.com/api/gh2/type/grasshopper2.types.conversion.bitsandbytes/stringtobytearray.md): (static) Convert a string to a byte array.
