websIDE
  • webside
    • Overview
  • API
    • General
      • Dialect
      • Version
      • Colors
      • Logo
      • Stats
      • Themes
      • Icons
      • Save Image
    • Changes
      • Retrieve changes
      • Apply a change
    • Changesets
      • Convert chunks to JSON changes
      • Convert JSON changes to chunks
    • Code
      • Autocompletions
        • Retrieve autocompletions
      • Categories
        • Retrieve categories
        • Retrieve usual categories
      • Classes
        • Retrieve classes
        • Retrieve a class
        • Retrieve categories
        • Retrieve variables
        • Retrieve class variables
        • Retrieve instance variables
        • Retrieve selectors
        • Retrieve methods
        • Retrieve method
        • Retrieve method history
        • Retrieve subclasses
        • Retrieve superclasses
        • Retrieve used categories
      • Methods
        • Retrieve methods
      • Packages
        • Retrieve packages
        • Retrieve a package
        • Retrieve package classes
        • Retrieve package methods
      • Search
      • Selectors
        • Find selector in source code
      • Templates
        • Retrieve class template
        • Retrieve method template
    • Debuggers
      • Retrieve active debuggers
      • Create a debugger
      • Delete debugger
      • Retrieve debugger frames
      • Retrieve debugger frame
      • Retrieve frame bindings
      • Restart debugger
      • Resume debugger
      • Step into debugger
      • Step over debugger
      • Step through debugger
      • Terminate debugger
    • Evaluations
      • Retrieve evaluations
      • Evaluate an expression
      • Cancel evaluation
      • Retrieve evaluation
      • Pause evaluation
      • Resume evaluation
    • Extensions
      • Retrieve extensions
      • Changes extensions
      • Export extensions
      • Search extensions
    • Commands
      • Retrieve command definitions
      • Invoke commands
    • Objects
      • Retrieve pinned objects
      • Pin object
      • Retrieve pinned object
      • Retrieve pinned object slots
        • Custom views
      • Unpin an object
      • Unpin all objects
    • Processes
      • Retrieve active processes
    • Profilers
      • Retrieve active profilers
      • Create a new profiler
      • Delete a profiler
      • Retrieve a profiler
      • Retrieve profiler ranking results
      • Retrieve profiler tree results
    • Testing
      • Run tests
      • Retrieve test run status
      • Retrieve test run results
    • Workspaces
      • Retrieve active workspaces
      • Create a new workspace
      • Delete a workspace
      • Retrieve a workspace
      • Update a workspace
      • Retrieve workspace bindings
Powered by GitBook
On this page
  • Specification
  • Example
  • Get mechanism
  1. API
  2. Extensions

Search extensions

PreviousExport extensionsNextCommands

Last updated 2 months ago

This type of extension allows us to define and perform specific searches (method searches by the moment) on the backend. Like other extensions, these ones will enlarge the list of options available on the IDE.

Specification

A search extension must be like this:

{
	"type": "search",
	"elementType": "string",
	"label": "string",
	"description": "string",
	"get": "string",
	"section": "string"
}

Where:

  • type this property should be search.

  • get the URI to perform the actual search (see below).

For basic properties refer to .

Example

Lets suppose we want to add a "Unary methods" search option to packages and that we count on a endpoint for that (/packages/{packagename}/unaries for instance), that searches for unary methods on a given package. We could specify our extension like this:

{
	"type": "search",
	"elementType": "package",
	"label": "Unary methods",
	"get": "/packages/{element.name}/unaries"
}

Get mechanism

get property should be the URI corresponding to the endpoint associated to the search of interest. The value might contain {element.xxxx} expressions, where element represents the meta-model object for which the search is requested (most likely the object selected in IDE), and xxxx is an valid attribute for such element. This expression will be replaced by the actual value element's attribute.\

In the example, assuming the action was triggered from the package MyPackage, the contents will be retrieved from the URI /pacakges/MyPackage/unaries.

Valid attributes can be extracted from the corresponding endpoints in the documentation (, , , , ).

pacakges
classes
variables
categories
methods
basic extension properties