# Connections class

Namespace: [Grasshopper2.Parameters](https://developer.rhino3d.com/api/gh2/namespace/grasshopper2.parameters.md) · Assembly: [Grasshopper2](https://developer.rhino3d.com/api/gh2/assembly/grasshopper2.md)

```cs
[IoId("00000000-79ac-4cfd-be35-e0ac16d15c1e")]
public sealed class Connections : IStorable
```

Provides access to a list of parameters as well as static methods for connecting and disconnecting parameters. The only way for external code to create or remove connections is via the static methods on this class.

## Constructors

- [Connections](https://developer.rhino3d.com/api/gh2/type/grasshopper2.parameters.connections/ctor.md): (2 overloads) Create a new parameter collection.

## Properties

- [Backwards](https://developer.rhino3d.com/api/gh2/type/grasshopper2.parameters.connections/backwards.md): Enumerate all guids in a backward fashion.
- [Count](https://developer.rhino3d.com/api/gh2/type/grasshopper2.parameters.connections/count.md): Gets the number of parameters in this list.
- [Forwards](https://developer.rhino3d.com/api/gh2/type/grasshopper2.parameters.connections/forwards.md): Enumerate all guids in a forward fashion.

## Indexers

- [this[]](https://developer.rhino3d.com/api/gh2/type/grasshopper2.parameters.connections/item.md): Gets the parameter at the specific index.

## Methods

- [Connect](https://developer.rhino3d.com/api/gh2/type/grasshopper2.parameters.connections/connect.md): (2 overloads, static) Create a connection between a source and a target parameter.
- [CopyAllInputs](https://developer.rhino3d.com/api/gh2/type/grasshopper2.parameters.connections/copyallinputs.md): (static) Copy all incoming wires from one parameter to another.
- [CopyAllOutputs](https://developer.rhino3d.com/api/gh2/type/grasshopper2.parameters.connections/copyalloutputs.md): (static) Copy all outgoing wires from one parameter to another.
- [CutOutMiddleMan](https://developer.rhino3d.com/api/gh2/type/grasshopper2.parameters.connections/cutoutmiddleman.md): (static) Attempt to cut out the middle man from a triplet of connected parameters.
- [Disconnect](https://developer.rhino3d.com/api/gh2/type/grasshopper2.parameters.connections/disconnect.md): (static) Remove the connection between a source and a target parameter.
- [DisconnectAllInputs](https://developer.rhino3d.com/api/gh2/type/grasshopper2.parameters.connections/disconnectallinputs.md): (static) Remove all sources from a specific parameter.
- [DisconnectAllInputsExcept](https://developer.rhino3d.com/api/gh2/type/grasshopper2.parameters.connections/disconnectallinputsexcept.md): (2 overloads, static) Remove all sources but one from a specific parameter.
- [DisconnectAllOutputs](https://developer.rhino3d.com/api/gh2/type/grasshopper2.parameters.connections/disconnectalloutputs.md): (static) Remove all targets from a specific parameter.
- [DisconnectAllOutputsExcept](https://developer.rhino3d.com/api/gh2/type/grasshopper2.parameters.connections/disconnectalloutputsexcept.md): (2 overloads, static) Remove all targets but one from a specific parameter.
- [IStorable.Store](https://developer.rhino3d.com/api/gh2/type/grasshopper2.parameters.connections/grasshopperio-istorable-store.md)
- [IndexOf](https://developer.rhino3d.com/api/gh2/type/grasshopper2.parameters.connections/indexof.md): Find the index of a specific parameter within this list.
- [MigrateAllInputs](https://developer.rhino3d.com/api/gh2/type/grasshopper2.parameters.connections/migrateallinputs.md): (static) Migrate all incoming wires from one parameter to another.
- [MigrateAllOutputs](https://developer.rhino3d.com/api/gh2/type/grasshopper2.parameters.connections/migratealloutputs.md): (static) Migrate all outgoing wires from one parameter to another.
- [Mimic](https://developer.rhino3d.com/api/gh2/type/grasshopper2.parameters.connections/mimic.md): (2 overloads) Duplicate another set of connections. This is a low level method which should only be used with utmost care. If at all possible consider the static methods on this class for creating, removing, and copying connections.
- [Reorder](https://developer.rhino3d.com/api/gh2/type/grasshopper2.parameters.connections/reorder.md): Sort the connections so that the ID order matches the given list.
- [ReplaceSource](https://developer.rhino3d.com/api/gh2/type/grasshopper2.parameters.connections/replacesource.md): (static) Replace one source with another.
- [ReplaceTarget](https://developer.rhino3d.com/api/gh2/type/grasshopper2.parameters.connections/replacetarget.md): (static) Replace one target with another.
- [SwapSources](https://developer.rhino3d.com/api/gh2/type/grasshopper2.parameters.connections/swapsources.md): (static) Swap the sources of two parameters. I.e. cross the wires.
- [ToArray](https://developer.rhino3d.com/api/gh2/type/grasshopper2.parameters.connections/toarray.md): Create a duplicate of the Guid array.

## Events

- [ParameterAdded](https://developer.rhino3d.com/api/gh2/type/grasshopper2.parameters.connections/parameteradded.md): Raised whenever a parameter is added or inserted into this list.
- [ParameterRemoved](https://developer.rhino3d.com/api/gh2/type/grasshopper2.parameters.connections/parameterremoved.md): Raised whenever a parameter is removed from this list.
