icecoder/ICEcoder

Index usages in indexer

Opened this issue · 0 comments

Relies on #901 being done first.

When indexing, if it finds we have a list of files, functions and classes but no list of usages, it's on it's 2nd of 2 runs and can index a list of usages this time.

The usages list filenames, class names and function names (from the 1st run) that appear within the file. If found, simply add to the usages array. In the case of my-page.php it may add the usages:

"my-page.php" => [
    "files" => [
        "banner-anim.js",
        "login.js"
    ],
    "classes" => [
        "loginProcess",
        "templateLoader"
    ],
    "functions => [
        "validateUserName",
        "validatePassword"
    ]
];

...as an example.

This data can then be used by a new plugin described in #903.