@param IntrospectedTransition[] $introspectedTransitions
@param string[] $colors

@return array
349823
private function createTransitionsRepresentation(array $introspectedTransitions, array $colors)
    {
        $jsonableTransitions = array();
        foreach ($introspectedTransitions as $introspectedTransition) {
            $jsonableTransitions[] = array(
                'data' => array(
                    'source' => $introspectedTransition->getFromIntrospectedState()->getKey(),
                    'target' => $introspectedTransition->getToIntrospectedState()->getKey(),
                    'faveColor' => $colors[$introspectedTransition->getFromIntrospectedState()->getKey()],
                    'strength' => self::DEFAULT_TRANSITION_STRENGTH
                )
            );
        }

        return $jsonableTransitions;
    }
655349
public function massColor(array $strings, string $color)
    {
        $len_array = count($strings);
        for ($i = 0; $i < $len_array; $i++) {
            $strings[$i] = $this->colorize->{$color}($strings[$i]);
        }
        return $strings;
    }
286006
@Override
    public List<String> introspect() {
        List<String> rc = super.introspect();
        String prefix = getClass().getSimpleName() + "@" + hashCode() + ": ";
        rc.add(prefix + "callback=" + this.callback);
        rc.add(prefix + "jitAllocateSize=" + this.jitAllocateSize);
        rc.add(prefix + "jitAllocateAction=" + this.jitAllocateAction);
        return rc;
    }
661212
public static function getKnownColors()
    {
        $colors = array(
            static::BLACK  => static::BASH_BACKGROUND_BLACK,
            static::RED    => static::BASH_BACKGROUND_RED,
            static::GREEN  => static::BASH_BACKGROUND_GREEN,
            static::YELLOW => static::BASH_BACKGROUND_YELLOW,
            static::BLUE   => static::BASH_BACKGROUND_BLUE,
            static::PURPLE => static::BASH_BACKGROUND_PURPLE,
            static::CYAN   => static::BASH_BACKGROUND_CYAN,
            static::WHITE  => static::BASH_BACKGROUND_WHITE
        );

        return $colors;
    }
582990
@SuppressWarnings("unchecked")
    private PropertyDescriptor[] introspectProperties(Class<?> stopClass)
            throws IntrospectionException {

        // Get descriptors for the public methods
        MethodDescriptor[] methodDescriptors = introspectMethods();

        if (methodDescriptors == null) {
            return null;
        }

        ArrayList<MethodDescriptor> methodList = new ArrayList<MethodDescriptor>();
        // Loop over the methods found, looking for public non-static methods
        for (int index = 0; index < methodDescriptors.length; index++) {
            int modifiers = methodDescriptors[index].getMethod().getModifiers();
            if (!Modifier.isStatic(modifiers)) {
                methodList.add(methodDescriptors[index]);
            }
        }

        // Get the list of public non-static methods into an array
        int methodCount = methodList.size();
        MethodDescriptor[] theMethods = null;
        if (methodCount > 0) {
            theMethods = new MethodDescriptor[methodCount];
            theMethods = methodList.toArray(theMethods);
        }

        if (theMethods == null) {
            return null;
        }

        HashMap<String, HashMap> propertyTable = new HashMap<String, HashMap>(
                theMethods.length);

        // Search for methods that either get or set a Property
        for (int i = 0; i < theMethods.length; i++) {
            introspectGet(theMethods[i].getMethod(), propertyTable);
            introspectSet(theMethods[i].getMethod(), propertyTable);
        }

        // fix possible getter & setter collisions
        fixGetSet(propertyTable);

        // If there are listener methods, should be bound.
        MethodDescriptor[] allMethods = introspectMethods(true);
        if (stopClass != null) {
            MethodDescriptor[] excludeMethods = introspectMethods(true,
                    stopClass);
            if (excludeMethods != null) {
                ArrayList<MethodDescriptor> tempMethods = new ArrayList<MethodDescriptor>();
                for (MethodDescriptor method : allMethods) {
                    if (!isInSuper(method, excludeMethods)) {
                        tempMethods.add(method);
                    }
                }
                allMethods = tempMethods
                        .toArray(new MethodDescriptor[0]);
            }
        }
        for (int i = 0; i < allMethods.length; i++) {
            introspectPropertyListener(allMethods[i].getMethod());
        }
        // Put the properties found into the PropertyDescriptor array
        ArrayList<PropertyDescriptor> propertyList = new ArrayList<PropertyDescriptor>();

        for (Map.Entry<String, HashMap> entry : propertyTable.entrySet()) {
            String propertyName = entry.getKey();
            HashMap table = entry.getValue();
            if (table == null) {
                continue;
            }
            String normalTag = (String) table.get(STR_NORMAL);
            String indexedTag = (String) table.get(STR_INDEXED);

            if ((normalTag == null) && (indexedTag == null)) {
                continue;
            }

            Method get = (Method) table.get(STR_NORMAL + PREFIX_GET);
            Method set = (Method) table.get(STR_NORMAL + PREFIX_SET);
            Method indexedGet = (Method) table.get(STR_INDEXED + PREFIX_GET);
            Method indexedSet = (Method) table.get(STR_INDEXED + PREFIX_SET);

            PropertyDescriptor propertyDesc = null;
            if (indexedTag == null) {
                propertyDesc = new PropertyDescriptor(propertyName, get, set);
            } else {
                try {
                    propertyDesc = new IndexedPropertyDescriptor(propertyName,
                            get, set, indexedGet, indexedSet);
                } catch (IntrospectionException e) {
                    // If the getter and the indexGetter is not compatible, try
                    // getter/setter is null;
                    propertyDesc = new IndexedPropertyDescriptor(propertyName,
                            null, null, indexedGet, indexedSet);
                }
            }
            // RI set propretyDescriptor as bound. FIXME
            // propertyDesc.setBound(true);
            if (canAddPropertyChangeListener && canRemovePropertyChangeListener) {
                propertyDesc.setBound(true);
            } else {
                propertyDesc.setBound(false);
            }
            if (table.get(STR_IS_CONSTRAINED) == Boolean.TRUE) { //$NON-NLS-1$
                propertyDesc.setConstrained(true);
            }
            propertyList.add(propertyDesc);
        }

        PropertyDescriptor[] theProperties = new PropertyDescriptor[propertyList
                .size()];
        propertyList.toArray(theProperties);
        return theProperties;
    }
100064
public static function introspect( $class = null, array $seedConstants = array(), $overwrite = true )
    {
        $_key = static::_cacheKey( $class );

        if ( true === $overwrite || !isset( static::$_constants[$_key] ) )
        {
            $_mirror = new \ReflectionClass( $class ?: \get_called_class() );

            static::$_constants[$_key] = array_merge(
                $seedConstants,
                $_mirror->getConstants()
            );

            unset( $_mirror );
        }

        return $_key;
    }
513484
@Override
    public String[] introspectSelf() {
        List<String> rc = new ArrayList<String>();
        rc.add(Thread.currentThread().getName());
        rc.add("selectorTimeout: " + this.selectorTimeout);
        rc.add("usageCount: " + this.usageCount);
        rc.add("quit: " + this.quit);
        rc.add("waitingToQuit: " + this.waitingToQuit);
        rc.add("firstErrorTime: " + this.firstErrorTime + "=" + new Date(this.firstErrorTime));
        rc.add("Total exceptions: " + this.numExceptions);
        rc.add("\tIOExceptions on accept: " + this.numAcceptIOExceptions);
        rc.add("\tnull sockets on accept: " + this.numAcceptNulls);
        rc.add("\tIOExceptions on configure: " + this.numConfigureIOExceptions);
        rc.add("\tnumber of cancelled keys: " + this.numCancelledKeys);

        rc.add("# of keys=" + this.selector.keys().size());
        try {
            for (SelectionKey key : this.selector.keys()) {
                rc.add("key: " + key.channel());
            }
        } catch (Throwable x) {
            // If we get any exception, just return what we have so far.
            // This routine is not thread safe, and could get an exception, but
            // since it is only invoked when we are dumping data, due to a problem or
            // during debug this should be acceptable.
            rc.add("Exception Occurred Gathering Dump Data: " + x);
        }

        return rc.toArray(new String[rc.size()]);
    }
718582
public function getThemeOptionsExcluding($excludedColors = [])
    {
        $themeColors = $this->owner->config()->get('theme_colors');
        $options = [];

        foreach ($themeColors as $themeColor) {
            if (in_array($themeColor['CSSClass'], $excludedColors)) {
                continue;
            }

            $options[] = $themeColor;
        }

        return $options;
    }
491003
public Method[] getArrayAccessMethods() throws IntrospectionException {
        if (!mCheckedForArrayLookup) {
            checkForArrayLookup();
        }

        return mArrayAccessMethods == null ? null :
            (Method[])mArrayAccessMethods.clone();
    }
416266
public Set<Integer> getTransitions(int state, int inputIdx) { // TODO: replace by primitive specialization
        Set<Integer> transition = transitions[toMemoryIndex(state, inputIdx)];

        return transition == null ? Collections.emptySet() : transition;
    }
1220807
void introspectThisClassOnly(com.ibm.ws.rsadapter.FFDCLogger info) {
        info.createFFDCHeader(this);
        info.append("Connection:", AdapterUtil.toString(ivSqlConn));
        info.append("ManagedConnection:", ivManagedConnection);
    }
1063171
public function getTransitionColor($transition)
    {
        return empty($this->colors['transition'][$transition])
            ? $this->options['transition']['default_color']
            : $this->colors['transition'][$transition]
        ;
    }
1356950
public static function getTypeAliasesFromComment(
        $comment,
        Aliases $aliases,
        array $type_aliases = null
    ) {
        $comments = DocComment::parse($comment);

        if (!isset($comments['specials']['psalm-type'])) {
            return [];
        }

        return self::getTypeAliasesFromCommentLines(
            $comments['specials']['psalm-type'],
            $aliases,
            $type_aliases
        );
    }
107818
private void introspectCollab(String name, EJBRequestCollaborator<?>[] collabArray, IntrospectionWriter writer) {

        if (collabArray != null && collabArray.length > 0) { // d742434
            int i = 0;
            for (Object element : collabArray) {
                String outString = name + "[" + i++ + "]";
                String format = String.format("%-55s = %s", outString, Util.identity(element)); // 619922.1
                writer.println(format);
            }
        } else {
            String outString = name + "[]";
            String format = String.format("%-55s %s", outString, "is empty.");
            writer.println(format);
        }

    }
749330
public List<String> introspect() {
        List<String> rc = new LinkedList<String>();
        String prefix = getClass().getSimpleName() + "@" + hashCode() + ": ";
        rc.add(prefix + "aborted=" + this.aborted);
        rc.add(prefix + "forceQueue=" + this.forceQueue);
        rc.add(prefix + "ioAmount=" + this.ioAmount);
        rc.add(prefix + "ioCompleteAmt=" + this.ioCompleteAmt);
        rc.add(prefix + "ioDoneAmt=" + this.ioDoneAmt);
        rc.add(prefix + "lastIOAmt=" + this.lastIOAmt);
        rc.add(prefix + "isRead=" + this.requestTypeRead);
        rc.add(prefix + "timeoutInterval=" + this.timeoutInterval);
        rc.add(prefix + "timeoutTime=" + this.timeoutTime);
        rc.add(prefix + "link=" + this.oTCPConnLink);
        if (null != this.oTCPConnLink) {
            rc.addAll(this.oTCPConnLink.introspect());
        }
        return rc;
    }
1066170
public void setTransitions(int state,
                               int inputIdx,
                               Collection<? extends Integer> successors) { // TODO: replace by primitive specialization
        int transIdx = toMemoryIndex(state, inputIdx);
        //TIntSet succs = transitions[transIdx];
        Set<Integer> succs = transitions[transIdx]; // TODO: replace by primitive specialization
        if (succs == null) {
            //succs = new TIntHashSet(successors);
            succs = Sets.newHashSetWithExpectedSize(successors.size()); // TODO: replace by primitive specialization
            transitions[transIdx] = succs;
        } else {
            succs.clear();
        }
        succs.addAll(successors);
    }
567190
@SuppressWarnings("unchecked")
    private EventSetDescriptor[] introspectEvents() throws IntrospectionException {
        // Get descriptors for the public methods
        // FIXME: performance
        MethodDescriptor[] theMethods = introspectMethods();

        if (theMethods == null)
            return null;

        HashMap<String, HashMap> eventTable = new HashMap<String, HashMap>(
                theMethods.length);

        // Search for methods that add an Event Listener
        for (int i = 0; i < theMethods.length; i++) {
            introspectListenerMethods(PREFIX_ADD, theMethods[i].getMethod(),
                    eventTable);
            introspectListenerMethods(PREFIX_REMOVE, theMethods[i].getMethod(),
                    eventTable);
            introspectGetListenerMethods(theMethods[i].getMethod(), eventTable);
        }

        ArrayList<EventSetDescriptor> eventList = new ArrayList<EventSetDescriptor>();
        for (Map.Entry<String, HashMap> entry : eventTable.entrySet()) {
            HashMap table = entry.getValue();
            Method add = (Method) table.get(PREFIX_ADD);
            Method remove = (Method) table.get(PREFIX_REMOVE);

            if ((add == null) || (remove == null)) {
                continue;
            }

            Method get = (Method) table.get(PREFIX_GET);
            Class<?> listenerType = (Class) table.get("listenerType"); //$NON-NLS-1$
            Method[] listenerMethods = (Method[]) table.get("listenerMethods"); //$NON-NLS-1$
            EventSetDescriptor eventSetDescriptor = new EventSetDescriptor(
                    decapitalize(entry.getKey()), listenerType, listenerMethods, add,
                    remove, get);

            eventSetDescriptor.setUnicast(table.get("isUnicast") != null); //$NON-NLS-1$
            eventList.add(eventSetDescriptor);
        }

        EventSetDescriptor[] theEvents = new EventSetDescriptor[eventList
                .size()];
        eventList.toArray(theEvents);

        return theEvents;
    }