Return introspect object that can be delivered to openplacos server
345389
def introspect
      iface = Hash.new
      pin = Hash.new
      meth = Array.new
      
      if self.respond_to?(:read)
        meth << "read"
      end
      if self.respond_to?(:write)
        meth << "write"
      end
      iface[@interface] = meth
      pin[@name] = iface
      return pin
    end
1178181
def rec_introspect(node, path)
      xml = bus.introspect_data(@name, path)
      intfs, subnodes = IntrospectXMLParser.new(xml).parse
      subnodes.each do |nodename|
        subnode = node[nodename] = Node.new(nodename)
        subpath = if path == "/"
                    "/" + nodename
                  else
                    path + "/" + nodename
                  end
        rec_introspect(subnode, subpath)
      end
      return if intfs.empty?
      node.object = ProxyObjectFactory.new(xml, @bus, @name, path).build
    end
271712
def __create(self, opcode):
        """"""
        tftpassert(opcode in self.classes,
                   "Unsupported opcode: %d" % opcode)

        packet = self.classes[opcode]()

        return packet
189113
def inspect_io_obj(obj):
    
    itype = guess_io_type(obj)

    if itype == IOI_PATH_STR:
        ipath = anyconfig.utils.normpath(obj)
        ext = anyconfig.utils.get_file_extension(ipath)
        opener = open
    elif itype == IOI_PATH_OBJ:
        ipath = anyconfig.utils.normpath(obj.as_posix())
        ext = anyconfig.utils.get_file_extension(ipath)
        opener = obj.open
    elif itype == IOI_STREAM:
        ipath = anyconfig.utils.get_path_from_stream(obj)
        ext = anyconfig.utils.get_file_extension(ipath) if ipath else None
        opener = anyconfig.utils.noop
    elif itype == IOI_NONE:
        ipath = ext = None
        opener = anyconfig.utils.noop
    else:
        raise UnknownFileTypeError("%r" % obj)

    return (itype, ipath, opener, ext)
909572
void introspectThisClassOnly(com.ibm.ws.rsadapter.FFDCLogger info) {
        info.createFFDCHeader(this);

        info.append("ManagedConnection:", ivManagedConnection);
        info.append("Underlying XAResource Object: " + AdapterUtil.toString(ivXaRes), ivXaRes);
        info.append("Xid: ", AdapterUtil.toString(ivXid)); 
    }
297382
def get_object(request, pid):
    """"""
    sciobj = d1_gmn.app.models.ScienceObject.objects.get(pid__did=pid)
    content_type_str = d1_gmn.app.object_format_cache.get_content_type(
        sciobj.format.format
    )
    # Return local or proxied SciObj bytes
    response = django.http.StreamingHttpResponse(
        _get_sciobj_iter(sciobj), content_type_str
    )
    d1_gmn.app.views.headers.add_sciobj_properties_headers_to_response(response, sciobj)
    d1_gmn.app.event_log.log_read_event(pid, request)
    return response
1316737
def fromBasicServiceEndpoint(cls, endpoint):
        """"""
        type_uris = endpoint.matchTypes(cls.openid_type_uris)

        # If any Type URIs match and there is an endpoint URI
        # specified, then this is an OpenID endpoint
        if type_uris and endpoint.uri is not None:
            openid_endpoint = cls()
            openid_endpoint.parseService(
                endpoint.yadis_url,
                endpoint.uri,
                endpoint.type_uris,
                endpoint.service_element)
        else:
            openid_endpoint = None

        return openid_endpoint
90910
def _make_pull_imethod_resp(objs, eos, context_id):
        
        eos_tup = (u'EndOfSequence', None, eos)
        enum_ctxt_tup = (u'EnumerationContext', None, context_id)

        return [("IRETURNVALUE", {}, objs), enum_ctxt_tup, eos_tup]
996759
public List<String> introspect() {
        List<String> rc = new LinkedList<String>();
        String prefix = getClass().getSimpleName() + "@" + hashCode() + ": ";
        rc.add(prefix + "tcpChannel=" + this.tcpChannel);
        rc.add(prefix + "closed=" + this.closed);
        rc.add(prefix + "socketIOChannel=" + this.socketIOChannel);
        if (null != this.socketIOChannel) {
            rc.addAll(this.socketIOChannel.introspect());
        }
        rc.add(prefix + "numReads=" + this.numReads);
        rc.add(prefix + "numWrites=" + this.numWrites);
        rc.add(prefix + "callCompleteLocal=" + this.callCompleteLocal);
        return rc;
    }
789624
def read_single_xso(src, type_):
    

    result = None

    def cb(instance):
        nonlocal result
        result = instance

    read_xso(src, {type_: cb})

    return result
223537
def from_json(cls, service_dict):
        """"""
        sd = service_dict.copy()
        service_endpoint = sd.get(cls.SERVICE_ENDPOINT)
        if not service_endpoint:
            logger.error(
                'Service definition in DDO document is missing the "serviceEndpoint" key/value.')
            raise IndexError

        _type = sd.get('type')
        if not _type:
            logger.error('Service definition in DDO document is missing the "type" key/value.')
            raise IndexError

        sd.pop(cls.SERVICE_ENDPOINT)
        sd.pop('type')
        return cls(
            service_endpoint,
            _type,
            sd
        )
43798
def get_import_code(tlobject):
    """"""
    kind = 'functions' if tlobject.is_function else 'types'
    ns = '.' + tlobject.namespace if tlobject.namespace else ''
    return 'from telethon.tl.{}{} import {}'\
        .format(kind, ns, tlobject.class_name)
296335
def from_cli(cls, ifo, args, maxlen):
        
        state_channel = analyze_flags = None
        if args.state_channel and ifo in args.state_channel \
                and args.analyze_flags and ifo in args.analyze_flags:
            state_channel = ':'.join([ifo, args.state_channel[ifo]])
            analyze_flags = args.analyze_flags[ifo].split(',')

        dq_channel = dq_flags = None
        if args.data_quality_channel and ifo in args.data_quality_channel \
                and args.data_quality_flags and ifo in args.data_quality_flags:
            dq_channel = ':'.join([ifo, args.data_quality_channel[ifo]])
            dq_flags = args.data_quality_flags[ifo].split(',')

        if args.frame_type:
            frame_src = pycbc.frame.frame_paths(args.frame_type[ifo],
                                                args.start_time,
                                                args.end_time)
        else:
            frame_src = [args.frame_src[ifo]]
        strain_channel = ':'.join([ifo, args.channel_name[ifo]])

        return cls(frame_src, strain_channel,
                   args.start_time, max_buffer=maxlen * 2,
                   state_channel=state_channel,
                   data_quality_channel=dq_channel,
                   sample_rate=args.sample_rate,
                   low_frequency_cutoff=args.low_frequency_cutoff,
                   highpass_frequency=args.highpass_frequency,
                   highpass_reduction=args.highpass_reduction,
                   highpass_bandwidth=args.highpass_bandwidth,
                   psd_samples=args.psd_samples,
                   trim_padding=args.trim_padding,
                   psd_segment_length=args.psd_segment_length,
                   psd_inverse_length=args.psd_inverse_length,
                   autogating_threshold=args.autogating_threshold,
                   autogating_cluster=args.autogating_cluster,
                   autogating_window=args.autogating_window,
                   autogating_pad=args.autogating_pad,
                   psd_abort_difference=args.psd_abort_difference,
                   psd_recalculate_difference=args.psd_recalculate_difference,
                   force_update_cache=args.force_update_cache,
                   increment_update_cache=args.increment_update_cache[ifo],
                   analyze_flags=analyze_flags,
                   data_quality_flags=dq_flags,
                   dq_padding=args.data_quality_padding)
1272526
def factory(opts, **kwargs):
        '''
        
        '''
        import salt.transport.ipc
        return salt.transport.ipc.IPCMessageServer(opts, **kwargs)
1129475
function OpenApiResponse(httpCode, description, type) {
    return function (target, propertyKey, descriptor) {
        let m = exports.globalKCState.getOrInsertController(target.constructor).getOrInsertMethod(propertyKey);
        httpCode = httpCode.toString();
        m.openApiResponses[httpCode] = { description: description, type: type };
    };
}
121810
public static void introspect(Object bean, ServletRequest request) throws JspCoreException {
        Enumeration e = request.getParameterNames();
        while (e.hasMoreElements()) {
            String name = (String) e.nextElement();
            String value = request.getParameter(name);
            introspecthelper(bean, name, value, request, name, true);
        }
    }
112650
private ReadOnlyDiscoveryClient getDiscoveryClient(Map<String, String> params) throws IOException {
        final UUID discoveryId = getDiscoveryId(params);

        final ReadOnlyDiscoveryClient discoveryClient = DISCO_CLIENTS.get(discoveryId);

        if (discoveryClient == null) {
            throw new IOException("No discovery client registered for id " + discoveryId);
        }
        return discoveryClient;
    }