OpenKeyWord  Build_ID: 457, Datum: 01.02.2020 07:45:48
Dont repeat yourself. - Do it once and only once!
AnyWindow.java
1 /*
2 ==============================================================================
3  Author: Zoltán Hrabovszki <zh@openkeyword.de>
4 
5  Copyright © 2012 - 2019 IT-Beratung Hrabovszki
6  www.OpenKeyWord.de
7 ==============================================================================
8 
9 This file is part of OpenKeyWord.
10 
11 OpenKeyWord is free software: you can redistribute it and/or modify
12 it under the terms of the GNU General Public License as published by
13 the Free Software Foundation, either version 3 of the License, or
14 (at your option) any later version.
15 
16 OpenKeyWord is distributed in the hope that it will be useful,
17 but WITHOUT ANY WARRANTY; without even the implied warranty of
18 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 GNU General Public License for more details.
20 
21 You should have received a copy of the GNU General Public License
22 along with OpenKeyWord. If not, see <http://www.gnu.org/licenses/>.
23 
24 Diese Datei ist Teil von OpenKeyWord.
25 
26 OpenKeyWord ist Freie Software: Sie können es unter den Bedingungen
27 der GNU General Public License, wie von der Free Software Foundation,
28 Version 3 der Lizenz oder (nach Ihrer Wahl) jeder späteren
29 veröffentlichten Version, weiterverbreiten und/oder modifizieren.
30 
31 OpenKeyWord wird in der Hoffnung, dass es nützlich sein wird, aber
32 OHNE JEDE GEWÄHRLEISTUNG, bereitgestellt; sogar ohne die implizite
33 Gewährleistung der MARKTFÄHIGKEIT oder EIGNUNG FÜR EINEN BESTIMMTEN ZWECK.
34 Siehe die GNU General Public License für weitere Details.
35 
36 Sie sollten eine Kopie der GNU General Public License zusammen mit
37 OpenKeyWord erhalten haben. Wenn nicht, siehe <http://www.gnu.org/licenses/>.
38 */
39 package okw.gui;
40 
41 import java.util.ArrayList;
42 
43 import okw.FrameObjectDictionary_Sngltn;
44 import okw.OKW;
45 import okw.OKW_TimeOut;
46 import okw.core.IOKW_FN;
47 import okw.exceptions.OKWFrameObjectMethodNotImplemented;
48 
52 public class AnyWindow extends AnyWinBase implements IGUIWindow, IOKW_FN
53 {
54 
55  public AnyWindow( )
56  {
57  super();
58  }
59 
60 
61  public AnyWindow( String fpsLocator, OKWLocator... fpLocators )
62  {
63  this.setLocator( fpsLocator, fpLocators );
64  }
65 
66 
85  public Boolean getExists()
86  {
87  // TODO: /todo Meldung in xml-Auslagern
88  throw new OKWFrameObjectMethodNotImplemented("The method Boolean getExists() is not definden for the current GUI-Object. Please define first this method in your GUI-Class!");
89  }
90 
110  public ArrayList<String> getCaption()
111  {
112  // TODO: /todo Meldung in xml-Auslagern
113  throw new OKWFrameObjectMethodNotImplemented("The method ArrayList<String> getCaption() is not definden for you GUI-Object. Please define first the methode!");
114  }
115 
116 
136  public Boolean getIsActive()
137  {
138  // TODO: /todo Meldung in xml-Auslagern
139  throw new OKWFrameObjectMethodNotImplemented("The method Boolean getIsActive() is not definden for this GUI-Object. Please define first this methode!");
140  }
141 
142 
143  public void TypeKeyWindow(ArrayList<String> Val)
144  {
145  // TODO: /todo Meldung in xml-Auslagern
146  throw new OKWFrameObjectMethodNotImplemented("The method void TypekeyWindow(ArrayList<String> Val) is not definden for this GUI-Object. Please define first this methode!");
147  }
148 
149 
150  public void SelectWindow()
151  {
152  // TODO: /todo Meldung in xml-Auslagern
153  throw new OKWFrameObjectMethodNotImplemented("The method void SelectWindow() is not definden for this GUI-Object. Please define first this methode!");
154  }
155 
156 
157  public void StartApp()
158  {
159  // TODO: /todo Meldung in xml-Auslagern
160  throw new OKWFrameObjectMethodNotImplemented("The method void void StartApp() is not definden for this GUI-Object. Please define first this methode!");
161  }
162 
163 
164  public void StopApp()
165  {
166  // TODO: /todo Meldung in xml-Auslagern
167  throw new OKWFrameObjectMethodNotImplemented("The method void StopApp() is not definden for this GUI-Object. Please define first this methode!");
168  }
169 
170 
171  public Boolean VerifyWindowExists()
172  {
173  // TODO: /todo Meldung in xml-Auslagern
174  throw new OKWFrameObjectMethodNotImplemented("The method Boolean VerifyWindowExists() is not definden for this GUI-Object. Please define first this methode!");
175  }
176 
177 
178  public Boolean VerifyIsWindowActive()
179  {
180  // TODO: /todo Meldung in xml-Auslagern
181  throw new OKWFrameObjectMethodNotImplemented("The method Boolean VerifyIsWindowActive() is not definden for this GUI-Object. Please define first this methode!");
182  }
183 
184 
185  public ArrayList<String> VerifyWindowCaption()
186  {
187  // TODO: /todo Meldung in xml-Auslagern
188  throw new OKWFrameObjectMethodNotImplemented("The method ArrayList<String> VerifyWindowCaption() is not definden for this GUI-Object. Please define first this methode!");
189  }
190 
191 
209  public Boolean WaitForMe()
210  {
211  Boolean lvbReturn = false;
212 
213  Integer Count = 0;
214 
215  try{
216  OKW MyOKW = FrameObjectDictionary_Sngltn.getInstance().getOKW( this.getKN() );
217 
218  // TimeOut-Werte Ermitteln
219  OKW_TimeOut timeout = new OKW_TimeOut( MyOKW.WaitForMe_TO(),MyOKW.WaitForMe_PT());
220 
221  Count = 0;
222 
223  while ( Count <= timeout.getMaxCount() )
224  {
225  if ( this.getExists() )
226  {
227  lvbReturn = true;
228  break;
229  }
230  else
231  {
232  Thread.sleep( timeout.getPT() );
233  }
234  Count++;
235  }
236  }
237  catch(Exception e)
238  {
239  throw new RuntimeException( e );
240  }
241  return lvbReturn;
242  }
243 }
okw.FrameObjectDictionary_Sngltn
Verwaltet zentral die Frame-Klassen: Instanziert Frame-Klassen zu Frame-Objekten und liefert die Refe...
Definition: FrameObjectDictionary_Sngltn.java:73
okw.gui.AnyWindow.getIsActive
Boolean getIsActive()
Ermittelt ob das aktuelle Objekt aktiv ist.
Definition: AnyWindow.java:136
okw.FrameObjectDictionary_Sngltn.getOKW
OKW getOKW(String fpKN)
Holt für einen GUI-Object die angehängte Annotation.
Definition: FrameObjectDictionary_Sngltn.java:829
okw.gui.IGUIWindow
Definition: IGUIWindow.java:5
okw.gui.AnyWinBase.getKN
String getKN()
Setzten des Objekt KN.
Definition: AnyWinBase.java:523
okw.gui.AnyWindow.WaitForMe
Boolean WaitForMe()
Methode, wartet auf das aktuelle GUI-Object bis es erscheint oder der eingestellte TimeOut erreicht i...
Definition: AnyWindow.java:209
okw.OKW.WaitForMe_PT
int WaitForMe_PT() default 1000
Polling Time in [ms] für das aktuelle Object.
okw.gui.AnyWinBase
Description of AnyWin.
Definition: AnyWinBase.java:48
okw.core.IOKW_FN
Definition: IOKW_FN.java:3
okw.OKW.WaitForMe_TO
int WaitForMe_TO() default 30
TimeOut in Sekunden [s] für das erscheinen des aktuellen Objektes.
okw.exceptions.OKWFrameObjectMethodNotImplemented
Die Ausnahme OKWFrameObjectMethodNotImplemented wird ausgelöst, wenn im Frame Objekt eine gegebene Me...
Definition: OKWFrameObjectMethodNotImplemented.java:65
okw.OKW_TimeOut.getPT
Integer getPT()
Wartezeit zwischen zwei Pollings in [ms].
Definition: OKW_TimeOut.java:18
okw.gui.AnyWinBase.setLocator
void setLocator(String fpsLocator, OKWLocatorBase... fpLocators)
Setzt den Locator für den aktuellen GUI-Adapter.
Definition: AnyWinBase.java:148
okw.gui.OKWLocator
Definition: OKWLocator.java:104
okw.gui.AnyWindow.getExists
Boolean getExists()
Prüft die Existenz des aktuellen Objektes.
Definition: AnyWindow.java:85
okw.OKW
Annotations-Klasses für die Zuordnung von.
Definition: OKW.java:38
okw.gui.AnyWindow.getCaption
ArrayList< String > getCaption()
Ermittelt die Caption/Überschrift des aktuellen Objektes.
Definition: AnyWindow.java:110
okw.OKW_TimeOut.getMaxCount
Integer getMaxCount()
Anzahl der berechnetten Zyklen.
Definition: OKW_TimeOut.java:46
okw.OKW_TimeOut
Definition: OKW_TimeOut.java:3
okw.gui.AnyWindow
Description of AnyWin.
Definition: AnyWindow.java:52