# Utility class

Namespace: [Grasshopper](https://developer.rhino3d.com/api/gh1/namespace/grasshopper.md) · Assembly: [Grasshopper](https://developer.rhino3d.com/api/gh1/assembly/grasshopper.md)

```cs
public sealed class Utility
```

Class with useful static methods.

## Methods

- [DocumentAngleTolerance](https://developer.rhino3d.com/api/gh1/type/grasshopper.utility/documentangletolerance.md): (static) Returns the Angle Tolerance in degrees for the model document
- [DocumentTolerance](https://developer.rhino3d.com/api/gh1/type/grasshopper.utility/documenttolerance.md): (static) Returns the Absolute Tolerance of the model document
- [DocumentUnits](https://developer.rhino3d.com/api/gh1/type/grasshopper.utility/documentunits.md): (static) Returns the unit system for the model document
- [FixNewlines](https://developer.rhino3d.com/api/gh1/type/grasshopper.utility/fixnewlines.md): (2 overloads, static) Make sure all newlines in a string have a specific pattern.
- [InvokeDownloader](https://developer.rhino3d.com/api/gh1/type/grasshopper.utility/invokedownloader.md): (static) Start an asynchronous download operation. The download runs in a separate appdomain. After triggering that process this method returns immediately.
- [InvokeGetter](https://developer.rhino3d.com/api/gh1/type/grasshopper.utility/invokegetter.md): (static) Call a getter property via its name.
- [InvokeGetterSafe](https://developer.rhino3d.com/api/gh1/type/grasshopper.utility/invokegettersafe.md): (static) Call a getter property via its name. No exceptions are thrown.
- [InvokeMethod](https://developer.rhino3d.com/api/gh1/type/grasshopper.utility/invokemethod.md): (2 overloads, static) Call a method via its name.
- [InvokeMethodSafe](https://developer.rhino3d.com/api/gh1/type/grasshopper.utility/invokemethodsafe.md): (2 overloads, static) Call a method via its name. No exceptions are thrown.
- [InvokeSetter](https://developer.rhino3d.com/api/gh1/type/grasshopper.utility/invokesetter.md): (static) Call a setter property via its name.
- [InvokeSetterSafe](https://developer.rhino3d.com/api/gh1/type/grasshopper.utility/invokesettersafe.md): (static) Call a setter property via its name. No exceptions are thrown.
- [LikeOperator](https://developer.rhino3d.com/api/gh1/type/grasshopper.utility/likeoperator.md): (static) Exposes the VB.NET Like operator as a static method.
- [SetDefaultTolerances](https://developer.rhino3d.com/api/gh1/type/grasshopper.utility/setdefaulttolerances.md): (static) Utility function to set absolute and angle tolerance fields.
- [SetDefaultUnits](https://developer.rhino3d.com/api/gh1/type/grasshopper.utility/setdefaultunits.md): (static) Utility function to set model unit fields
- [TernaryIf<T>](https://developer.rhino3d.com/api/gh1/type/grasshopper.utility/ternaryif.md): (static, obsolete) Type safe implementation of the IIf conditional statement.
