private byte[] AddParameterToArray(byte[] part1, LLCPParameter parameter) { byte[] parData = parameter.Data; byte[] result = new byte[part1.Length + parData.Length]; part1.CopyTo(result, 0); parData.CopyTo(result, part1.Length); return(result); }
public LLCPParameters(byte[] rawData) { int index = 0; while (index < rawData.Length) { LLCPParameter parameter = new LLCPParameter(rawData, index); switch (parameter.Type) { case LLCParameterType.Version: Version = new LLCParameterVersion(parameter); break; case LLCParameterType.MIUX: MIUX = new LLCParameterMiux(parameter); break; case LLCParameterType.WellKnownServiceList: WellKnownServiceList = new LLCParameterWellKnownServiceList(parameter); break; case LLCParameterType.LinkTimeOut: LinkTimeOut = new LLCParameterLinkTimeOut(parameter); break; case LLCParameterType.ReceiveWindowSize: ReceiveWindowSize = new LLCParameterReceiveWindowSize(parameter); break; case LLCParameterType.ServiceName: ServiceName = new LLCParameterServiceName(parameter); break; case LLCParameterType.Option: Option = new LLCParameterOption(parameter); break; case LLCParameterType.ServiceDiscoveryRequest: ServiceDiscoveryRequest = new LLCParameterServiceDiscoveryRequest(parameter); break; case LLCParameterType.ServiceDiscoveryResponse: ServiceDiscoveryResponse = new LLCParameterServiceDiscoveryResponse(parameter); break; } index += (parameter.Length + 2); } }
public LLCParameterServiceName(LLCPParameter param) : base(param.Data, 0) { }
public LLCParameterServiceDiscoveryRequest(LLCPParameter param) : base(param.Data, 0) { }
public LLCParameterMiux(LLCPParameter param) : base(param.Data, 0) { }
public LLCParameterVersion(LLCPParameter param) : base(param.Data, 0) { }