.. seealso:: :attr:`probe`
175481
def probe(self, hosts):
        '''
        
        '''

        def __send_probe(host):
            ping = self.m(
                '',
                cmdd=dict(
                    cmd=' '.join([
                        self.__ping_cmd,
                        self.__num,
                        self.__net_if,
                        self.__packetsize,
                        host
                    ])
                ),
                critical=False,
                verbose=False
            )

            up = True if ping.get('returncode') == 0 else False
            self.__probe_results[host] = {'up': up}

            if up:
                p = ping.get('out')

                loss = _search(rxlss, p)
                ms = _findall(rxmst, p)
                rtt = _search(rxrtt, p)

                if loss:
                    loss = loss.group('loss')
                self.__probe_results[host].update(dict(
                    ms=ms,
                    loss=loss,
                    rtt=rtt.groupdict()
                ))

        hosts = to_list(hosts)
        pool_size = (
            len(hosts)
            if len(hosts) <= self.__max_pool_size else
            self.__max_pool_size
        )

        pool = _Pool(pool_size)
        pool.map(__send_probe, hosts)
        pool.close()
        pool.join()
559289
final void fireProbe(long probeId, @Sensitive Object instance, @Sensitive Object target, @Sensitive Object payload) {
        try {
            //new Exception().printStackTrace();
            ProbeImpl probe = activeProbesById.get(probeId);
            ConcurrentMap<ProbeImpl, Set<ProbeListener>> listenersByProbe = this.listenersByProbe;
            if (shuttingDown || listenersByProbe == null || probe == null) {
                return;
            }
            Set<ProbeListener> listeners = listenersByProbe.get(probe);
            if (listeners == null) {
                return;
            }
            for (ProbeListener listener : listeners) {
                try {
                    Method method = listener.getTargetMethod();
                    //Class<?>[] parameterTypes = method.getParameterTypes();
                    Class<?>[] parameterTypes = listener.getParameterTypes();
                    //Annotation[][] parameterAnnotations = method.getParameterAnnotations();
                    //Annotation[][] parameterAnnotations = listener.getparameterannotations();//Performance Improvement
                    Object[] args = listener.getdefaultvalues();
                    if (args != null)
                        args = Arrays.copyOf(args, args.length);
                    boolean validated = listener.isValidated();
                    ArrayList<Integer> annList = listener.getAnnotationsList();
                    for (int i = 0; i < parameterTypes.length; i++) {

                        switch (annList.get(i)) {
                            case MonitorConstants.This:
                                if (validated || parameterTypes[i].isInstance(instance)) {
                                    args[i] = instance;
                                }
                                break;
                            case MonitorConstants.Args:
                                if (validated || Object[].class.isInstance(payload)) {
                                    args[i] = payload;
                                }
                                break;
                            case MonitorConstants.Elapsed:
                                break;
                            case MonitorConstants.Returned:
                                if (validated || parameterTypes[i].isInstance(payload)) {
                                    args[i] = payload;
                                }
                                break;
                            case MonitorConstants.FieldValue:
                                if (parameterTypes[i].isInstance(payload)) {
                                    args[i] = payload;
                                }
                                break;
                            case MonitorConstants.TargetInstance:
                                if (parameterTypes[i].isInstance(target)) {
                                    args[i] = target;
                                }
                                break;
                            case MonitorConstants.TargetMember:
                                break;
                            case MonitorConstants.Thrown:
                                if (Throwable.class.isInstance(payload) && parameterTypes[i].isInstance(payload)) {
                                    args[i] = payload;
                                }
                                break;
                            case MonitorConstants.Arg:
                                break;
                            default:
                                break;
                        }
//Below code causes performance overhead ..specifically the instanceof tag is causing overhead hence using switch case which is based on
//                        structures built the ProbeListener constructor
//                        Annotation[] annotations = parameterAnnotations[i];
//                        for (Annotation a : annotations) {
//                            if (a instanceof This) {
//                                if (parameterTypes[i].isInstance(instance)) {
//                                    System.out.println("i is " + i + " ins is This");
//                                    args[i] = instance;
//                                }
//                            } else if (a instanceof Args) { // @Args
//                                // payload instance of Object[] and Object[] can be assigned to parameter
//                                if (Object[].class.isInstance(payload) && parameterTypes[i].isAssignableFrom(Object[].class)) {
//                                    args[i] = payload;
//                                }
//                            }
//                            else if (a instanceof Elapsed) {
//                                // TODO
//                                System.out.println("elapsed");
//                                //args[i] = getDefaultValue(parameterTypes[i]);
//                            } else if (a instanceof Returned) {
//                                System.out.println("Returned");
//                                if (parameterTypes[i].isInstance(payload)) {
//                                    args[i] = payload;
//                                }
//                            } else if (a instanceof FieldValue) {
//                                System.out.println("FieldValue");
//                                if (parameterTypes[i].isInstance(payload)) {
//                                    args[i] = payload;
//                                }
//                            } else if (a instanceof TargetInstance) {
//                                System.out.println("TargetInstance");
//                                if (parameterTypes[i].isInstance(target)) {
//                                    args[i] = target;
//                                }
//                            } else if (a instanceof TargetMember) {
//                                System.out.println("TargetInstance");
//                                // TODO
//                                // args[i] = getDefaultValue(parameterTypes[i]);
//                            } else if (a instanceof Thrown) {
//                                System.out.println("Thrown");
//                                if (Throwable.class.isInstance(payload) && parameterTypes[i].isInstance(payload)) {
//                                    args[i] = payload;
//                                }
//                            } else if (a instanceof Arg) { // @Arg(n)
//                                System.out.println("Arg");
//                                Arg arg = (Arg) a;
//                                int index = arg.value() - 1;
//                                Object[] params = null;
//                                if (Object[].class.isInstance(payload)) {
//                                    params = (Object[]) payload;
//                                    if (params.length >= index && parameterTypes[i].isInstance(params[index])) {
//                                        args[i] = params[index];
//                                    }
//                                }
//                            }
//                        }
//                    }
                    }
                    listener.setValidated(true);
                    method.invoke(listener.getProbeTarget(), args);
                } catch (Throwable t) {
                    if (tc.isDebugEnabled()) {
                        Tr.debug(tc, t.getMessage());
                    }
                }
            }
        } catch (Throwable t) {
            Tr.error(tc, "PMI9999E", t.toString());
        }
    }
971411
static int index() {
    int probe = UnsafeAccess.UNSAFE.getInt(Thread.currentThread(), PROBE);
    if (probe == 0) {
      ThreadLocalRandom.current(); // force initialization
      probe = UnsafeAccess.UNSAFE.getInt(Thread.currentThread(), PROBE);
    }
    return (probe & ARENA_MASK);
  }
224667
def list_probes():
    """"""
    curdir = op.realpath(op.dirname(__file__))
    return [op.splitext(fn)[0] for fn in os.listdir(op.join(curdir, 'probes'))
            if fn.endswith('.prb')]
711328
def enable_irb
      IRB::Inspector.class_eval {
        unless method_defined?(:inspect_value_with_colour)
          alias_method :inspect_value_without_colour, :inspect_value

          def inspect_value_with_colour(value)
            Colours.colourize(inspect_value_without_colour(value))
          end
        end

        alias_method :inspect_value, :inspect_value_with_colour
      }
    end
1190286
def peek_step(self, val: ObjectValue,
                  sn: "DataNode") -> Tuple[None, "DataNode"]:
        """"""
        cn = sn.get_child(self.name, self.namespace)
        return (None, cn)
977540
def add_probe(self, probe):
        """"""
        if self.probes:
            probe_last = self.probes[-1]
            if not probe.ip:
                probe.ip = probe_last.ip
                probe.name = probe_last.name
        self.probes.append(probe)
618751
function attr(proto, attrName) {
    var metadataManager = Vessel$$1.$container.get('@metadata_manager'), className = proto.getClassName();
    metadataManager.setAttribute(className, attrName);
}
1312612
function(probeId, callback) {
      var t = this, probeImpl = t.runningProbesById[probeId];
      if (!probeImpl) {return callback('Probe not running');}
      if (--probeImpl.refCount === 0) {

        // Release probe resources & internal references if still no references after a while
        setTimeout(function() {
          if (probeImpl.refCount === 0) {
            try {
              probeImpl.release();
            } catch (e){}
            delete t.runningProbesByKey[probeImpl.probeKey];
            delete t.runningProbesById[probeId];
          }
        }, PROBE_TIMEOUT_MS);
      }
      callback(null, probeImpl);
    }
553537
synchronized void deactivateProbe(ProbeImpl probe) {
        listenersByProbe.remove(probe);
        activeProbesById.remove(probe.getIdentifier());

        Class<?> clazz = probe.getSourceClass();
        Map<String, ProbeImpl> classProbesByKey = probesByKey.get(clazz);
        classProbesByKey.remove(probe.getName());
        if (classProbesByKey.isEmpty()) {
            probesByKey.remove(clazz);
        }
    }
26758
function inspect(data, depth) {
    if (Type.isObject(data)) {
        return util.inspect(data, {depth: depth || 10});
    }
    return data;
}
593245
def probes(self, fromtime, totime=None):
        """"""

        args = {'from': fromtime}
        if totime:
            args['to'] = totime

        response = self.pingdom.request('GET', 'summary.probes/%s' % self.id,
                                        args)

        return response.json()['probes']
341333
public function probe(): void
    {
        if(!isset($this->settings["constraints"])) 
            return;
        $constraints = $this->settings["constraints"];
        foreach($constraints as $constraint=>$constraint_val) {
            if(is_null($constraint_val))
                continue;
            switch($constraint) {
                case "format":
                    if(!in_array($constraint_val, [
                         "numeric",
                         "ip",
                         "email",
                         "url",
                         "creditCard",
                         "alpha",
                         "alphaNum"
                         // "date" // there is already the Date field
                    ])) {
                        /*
                        if($constraint_val == "uuid" || $constraint_val == "udid") {
                            try {
                                ID::fromString($this->value);
                            }
                            catch(LibGraph\Exceptions\MalformedIDException $e) {
                                throw new \InvalidArgumentException;
                            }
                        }
                        else {
                            throw new \InvalidArgumentException;
                        }
                        */
                        throw new \InvalidArgumentException;
                    }
                    $v = new Validator(["field"=>$this->value]);
                    $v->rule($constraint_val, "field");
                    if(!$v->validate()) {
                        throw new \InvalidArgumentException;
                    }
                    break;
                //case "dateFormat":
                case "dateBefore":
                case "dateAfter":
                    $v = new Validator(["field"=>$this->value]);
                    $v->rule($constraint, "field", $constraint_val);
                    if(!$v->validate()) {
                        throw new \InvalidArgumentException;
                    }
                    break;
                case "minLength":
                case "maxLength":
                case "greaterThan":
                case "lessThan":
                    Assert::$constraint($this->value, $constraint_val);
                    break;
                               
                case "id":
                    try {
                        ID::fromString($this->value);
                    }
                    catch(LibGraph\Exceptions\MalformedIDException $e) {
                        throw new \InvalidArgumentException;
                    }
                    break;
                
                case "regex":
                    /*
                    if($constraint_val[0]!="/")
                        Assert::$constraint($this->value, "/".addslashes($constraint_val)."/");
                    else*/
                        Assert::$constraint($this->value, $constraint_val);
                    break;
             } 
        }
    }
138964
def instance_readers
      _attrs.map { |k, v| [:attr_writer].any? { |t| v[:type] == t } ? nil : k }.compact
    end
195183
def show(objectish=nil, path=nil)
      arr_opts = []

      arr_opts << (path ? "#{objectish}:#{path}" : objectish)

      command('show', arr_opts.compact)
    end
9460
def dig(key, *args)
      value = send(key)
      args.empty? ? value : value&.dig(*args)
    end
105905
def probe_async(self, callback):
        """"""

        future = self._loop.launch_coroutine(self._adapter.probe())
        future.add_done_callback(lambda x: self._callback_future(None, x, callback))