Service retainAll(Schema schema, MarkSet markSet) { // If this service is not retained, prune it. if (!markSet.contains(protoType)) { return null; } ImmutableList.Builder<Rpc> retainedRpcs = ImmutableList.builder(); for (Rpc rpc : rpcs) { Rpc retainedRpc = rpc.retainAll(schema, markSet); if (retainedRpc != null && markSet.contains(ProtoMember.get(protoType, rpc.name()))) { retainedRpcs.add(retainedRpc); } } return new Service(protoType, location, documentation, name, retainedRpcs.build(), options.retainAll(schema, markSet)); }
static Service fromElement(ProtoType protoType, ServiceElement element) { ImmutableList<Rpc> rpcs = Rpc.fromElements(element.rpcs()); Options options = new Options(Options.SERVICE_OPTIONS, element.options()); return new Service(protoType, element.location(), element.documentation(), element.name(), rpcs, options); }
Service retainAll(Schema schema, MarkSet markSet) { // If this service is not retained, prune it. if (!markSet.contains(protoType)) { return null; } ImmutableList.Builder<Rpc> retainedRpcs = ImmutableList.builder(); for (Rpc rpc : rpcs) { Rpc retainedRpc = rpc.retainAll(schema, markSet); if (retainedRpc != null && markSet.contains(ProtoMember.get(protoType, rpc.name()))) { retainedRpcs.add(retainedRpc); } } return new Service(protoType, location, documentation, name, retainedRpcs.build(), options.retainAll(schema, markSet)); }
Service retainAll(Schema schema, MarkSet markSet) { // If this service is not retained, prune it. if (!markSet.contains(protoType)) { return null; } ImmutableList.Builder<Rpc> retainedRpcs = ImmutableList.builder(); for (Rpc rpc : rpcs) { Rpc retainedRpc = rpc.retainAll(schema, markSet); if (retainedRpc != null && markSet.contains(ProtoMember.get(protoType, rpc.name()))) { retainedRpcs.add(retainedRpc); } } return new Service(protoType, location, documentation, name, retainedRpcs.build(), options.retainAll(schema, markSet)); }
static Service fromElement(ProtoType protoType, ServiceElement element) { ImmutableList<Rpc> rpcs = Rpc.fromElements(element.rpcs()); Options options = new Options(Options.SERVICE_OPTIONS, element.options()); return new Service(protoType, element.location(), element.documentation(), element.name(), rpcs, options); }
static Service fromElement(ProtoType protoType, ServiceElement element) { ImmutableList<Rpc> rpcs = Rpc.fromElements(element.rpcs()); Options options = new Options(Options.SERVICE_OPTIONS, element.options()); return new Service(protoType, element.location(), element.documentation(), element.name(), rpcs, options); }