BrightSide Workbench Full Report + Source Code
org.turro.action.content.ContentProviders Class Reference

Static Public Member Functions

static List< IContentProvidergetProviders ()
 
static List< String > getHelpCommands ()
 
static ContentRenderer loadCommand (String command, IContact contact, String idContext)
 
static String executeCommand (String command, IContact contact, String idContext)
 

Detailed Description

Author
Lluis TurrĂ³ Cutiller lluis.nosp@m.@tur.nosp@m.ro.or.nosp@m.g

Definition at line 31 of file ContentProviders.java.

Member Function Documentation

◆ executeCommand()

static String org.turro.action.content.ContentProviders.executeCommand ( String  command,
IContact  contact,
String  idContext 
)
static

Definition at line 56 of file ContentProviders.java.

56  {
57  ContentRenderer executor = loadCommand(command, contact, idContext);
58  return executor != null ? executor.execute() : null;
59  }
static ContentRenderer loadCommand(String command, IContact contact, String idContext)
Here is the call graph for this function:

◆ getHelpCommands()

static List<String> org.turro.action.content.ContentProviders.getHelpCommands ( )
static

Definition at line 39 of file ContentProviders.java.

39  {
40  List<String> commands = new ArrayList<>();
41  for(IContentProvider provider : getProviders()) {
42  commands.addAll(provider.getHelpCommands());
43  }
44  return commands;
45  }
static List< IContentProvider > getProviders()
Here is the call graph for this function:
Here is the caller graph for this function:

◆ getProviders()

static List<IContentProvider> org.turro.action.content.ContentProviders.getProviders ( )
static

Definition at line 35 of file ContentProviders.java.

35  {
36  return Instances.cached().byAnnotation(ContentProvider.class, IContentProvider.class);
37  }
Here is the caller graph for this function:

◆ loadCommand()

static ContentRenderer org.turro.action.content.ContentProviders.loadCommand ( String  command,
IContact  contact,
String  idContext 
)
static

Definition at line 47 of file ContentProviders.java.

47  {
48  for(IContentProvider provider : getProviders()) {
49  if(provider.itsMe(command)) {
50  return provider.loadCommand(command, contact, idContext);
51  }
52  }
53  return null;
54  }
Here is the call graph for this function:
Here is the caller graph for this function:

The documentation for this class was generated from the following file: