/// <summary> /// Read unknown instruction as <see cref="SwfOp.ByteCode.Actions.UnknownAction">UnknownAction</see> object /// </summary> private UnknownAction ReadUnknownAction(byte code, BinaryReader br) { byte[] bytecode; if (code < 0x80) { bytecode = new byte[1] { code }; } else { int len = Convert.ToInt32(br.ReadUInt16()); br.BaseStream.Position -= 3; bytecode = br.ReadBytes(len + 3); } UnknownAction u = new UnknownAction(code, bytecode); //u.ByteSize = bytecode.Length; return(u); }
public QueryService(ConfigService configService, RegistryService registryService, ClientFactory clientFactory, UnknownAction unknownAction, DescribeAction describeAction, CommandAction commandAction, QueryAction queryAction) { this.config = configService ?? throw new ArgumentNullException(nameof(configService)); this.registry = registryService ?? throw new ArgumentNullException(nameof(registryService)); this.clients = clientFactory ?? throw new ArgumentNullException(nameof(clientFactory)); this.unknownAction = unknownAction ?? throw new ArgumentNullException(nameof(unknownAction)); this.describeAction = describeAction ?? throw new ArgumentNullException(nameof(describeAction)); this.commandAction = commandAction ?? throw new ArgumentNullException(nameof(commandAction)); this.queryAction = queryAction ?? throw new ArgumentNullException(nameof(queryAction)); }