BrightSide Workbench Full Report + Source Code
org.turro.elephant.util.ZkossUtils Class Reference

Static Public Member Functions

static Component getParent (Page page, Class jClass)
 
static Component getParent (Component component, Class jClass)
 
static void confirmDeletion (String message, Command command)
 
static void confirmCutting (String message, Command command)
 
static void confirmProcess (String message, Command command)
 
static void confirmMove (String message, Command command)
 
static void confirmAcceptation (String message, Command command)
 
static void confirmMessage (String message, final Command command)
 
static void showMessage (String title, String message)
 

Detailed Description

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

Definition at line 37 of file ZkossUtils.java.

Member Function Documentation

◆ confirmAcceptation()

static void org.turro.elephant.util.ZkossUtils.confirmAcceptation ( String  message,
Command  command 
)
static

Definition at line 90 of file ZkossUtils.java.

90  {
91  PhraseBuilder pb = new PhraseBuilder(I_.get("Confirm acceptation"));
92  if(!Strings.isEmpty(message)) {
93  pb.addWord(message);
94  }
95  confirmMessage(pb.toString(), command);
96  }
static void confirmMessage(String message, final Command command)
Definition: ZkossUtils.java:98
Here is the call graph for this function:
Here is the caller graph for this function:

◆ confirmCutting()

static void org.turro.elephant.util.ZkossUtils.confirmCutting ( String  message,
Command  command 
)
static

Definition at line 66 of file ZkossUtils.java.

66  {
67  PhraseBuilder pb = new PhraseBuilder(I_.get("Confirm element cut"));
68  if(!Strings.isEmpty(message)) {
69  pb.addWord(message);
70  }
71  confirmMessage(pb.toString(), command);
72  }
Here is the call graph for this function:
Here is the caller graph for this function:

◆ confirmDeletion()

static void org.turro.elephant.util.ZkossUtils.confirmDeletion ( String  message,
Command  command 
)
static

Definition at line 58 of file ZkossUtils.java.

58  {
59  PhraseBuilder pb = new PhraseBuilder(I_.get("Confirm element deletion"));
60  if(!Strings.isEmpty(message)) {
61  pb.addWord(message);
62  }
63  confirmMessage(pb.toString(), command);
64  }
Here is the call graph for this function:
Here is the caller graph for this function:

◆ confirmMessage()

static void org.turro.elephant.util.ZkossUtils.confirmMessage ( String  message,
final Command  command 
)
static

Definition at line 98 of file ZkossUtils.java.

98  {
99  Messagebox.show(message, I_.get("Question"),
100  Messagebox.OK | Messagebox.CANCEL, Messagebox.QUESTION,
101  new EventListener<Event>() {
102  @Override
103  public void onEvent(Event event) throws Exception {
104  Context ctx = new Context();
105  switch ((Integer) event.getData()) {
106  case Messagebox.OK: command.execute(ctx); break;
107  }
108  }
109  });
110  }
Here is the call graph for this function:
Here is the caller graph for this function:

◆ confirmMove()

static void org.turro.elephant.util.ZkossUtils.confirmMove ( String  message,
Command  command 
)
static

Definition at line 82 of file ZkossUtils.java.

82  {
83  PhraseBuilder pb = new PhraseBuilder(I_.get("Confirm element move"));
84  if(!Strings.isEmpty(message)) {
85  pb.addWord(message);
86  }
87  confirmMessage(pb.toString(), command);
88  }
Here is the call graph for this function:

◆ confirmProcess()

static void org.turro.elephant.util.ZkossUtils.confirmProcess ( String  message,
Command  command 
)
static

Definition at line 74 of file ZkossUtils.java.

74  {
75  PhraseBuilder pb = new PhraseBuilder(I_.get("Confirm process"));
76  if(!Strings.isEmpty(message)) {
77  pb.addWord(message);
78  }
79  confirmMessage(pb.toString(), command);
80  }
Here is the call graph for this function:
Here is the caller graph for this function:

◆ getParent() [1/2]

static Component org.turro.elephant.util.ZkossUtils.getParent ( Component  component,
Class  jClass 
)
static

Definition at line 46 of file ZkossUtils.java.

46  {
47  if(component != null) {
48  Component p = component;
49  while((p = p.getParent()) != null) {
50  if(ReflectionUtil.representsClass(p.getClass(), jClass)) {
51  return p;
52  }
53  }
54  }
55  return null;
56  }

◆ getParent() [2/2]

static Component org.turro.elephant.util.ZkossUtils.getParent ( Page  page,
Class  jClass 
)
static

Definition at line 39 of file ZkossUtils.java.

39  {
40  if(page instanceof PageImpl) {
41  return getParent(((PageImpl) page).getOwner(), jClass);
42  }
43  return null;
44  }
static Component getParent(Page page, Class jClass)
Definition: ZkossUtils.java:39
Here is the caller graph for this function:

◆ showMessage()

static void org.turro.elephant.util.ZkossUtils.showMessage ( String  title,
String  message 
)
static

Definition at line 112 of file ZkossUtils.java.

112  {
113  Messagebox.show(message, title, Messagebox.OK, Messagebox.INFORMATION, 0, null);
114  }
Here is the caller graph for this function:

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