code: public void initializeChannels(GateDeploymentDescriptor descriptor) {
  		int numChannels = descriptor.getNumberOfChannelDescriptors();
  		this.channels = new OutputChannel[numChannels];
  
  		setChannelType(descriptor.getChannelType());
  
  		for (int i = 0; i < numChannels; i++) {
  			ChannelDeploymentDescriptor channelDescriptor = descriptor.getChannelDescriptor(i);
  
  			ChannelID id = channelDescriptor.getOutputChannelID();
  			ChannelID connectedId = channelDescriptor.getInputChannelID();
  
  			this.channels[i] = new OutputChannel(this, i, id, connectedId, getChannelType());
  		}
  	}
docs: -----------------------------------------------------------------------------------------------------------------