query
stringlengths
7
33.1k
document
stringlengths
7
335k
metadata
dict
negatives
listlengths
3
101
negative_scores
listlengths
3
101
document_score
stringlengths
3
10
document_rank
stringclasses
102 values
Enables debug output (for all subsequent interpreter calls).
static void debug() { ProcessRunnerImpl.setGlobalDebug(true); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void enableDebug() {\n this.debug = true;\n }", "public static void enableDebugging(){\n DEBUG = true;\n }", "public void toggleDebug() {\n\t\tdebug = debug ? false : true;\n\t}", "void debug() {\n this.renderer.debug = !this.renderer.debug;\n reload();\n }", "void setDebugEnabled(boolean value) {\r\n debug_enabled = value;\r\n }", "public void setDebug(boolean b) { debug = b; }", "public void setDebug(boolean value) {\n\t\tdebug = value;\n\t}", "public void setDebugging(boolean on)\n\t{\n\t\t_options.setDebugging(on);\n\t}", "void k2h_set_debug_level_silent();", "public void disableDebug() {\n this.debug = false;\n }", "public void setDebug(boolean f) {\n debug = f;\n }", "@Override\n\tpublic void setDebugMode(boolean debug) {\n\n\t}", "public void debug() {\n\n }", "@Override\n protected boolean isDebugEnable() {\n return false;\n }", "public static void setDebug(boolean d) {\n\t\tdebug = d;\n\t}", "public void toggleDebugMode() {\r\n DEBUG = !DEBUG;\r\n }", "public void setDebugEnabled(boolean debugEnabled) {\n this.debugEnabled = debugEnabled;\n }", "static void debug(boolean b) {\n ProcessRunnerImpl.setGlobalDebug(b);\n }", "public static void normalDebug(){\n enableVerbos = false;\n }", "public static void disableDebugging(){\n DEBUG = false;\n }", "@Override\n\tpublic void setDebug(boolean isDebug) {\n\t\t\n\t}", "public void setDebug(IRubyObject debug) {\n this.debug = debug.isTrue();\n }", "public void setDebug(IRubyObject debug) {\n this.debug = debug.isTrue();\n }", "public void setDebug(boolean debug) {\n this.debug=debug;\n }", "public final void setDebug() {\r\n setLevel(org.apache.log4j.Level.DEBUG);\r\n }", "public void continueDebugStep() {\n \tthis.continueDebug = true;\n }", "public abstract void debug(PrintStream console);", "public void setDebug(boolean debug, PrintStream out)\n {\n session.setDebug(debug);\n if (debug)\n session.setDebugOut(out);\n }", "public void setDebug(boolean debug) {\n this.debug = debug;\n }", "public void setDebug(boolean debug) {\n this.debug = debug;\n }", "void debug(String msg)\n{\n if (yydebug)\n System.out.println(msg);\n}", "void debug(String msg)\n{\n if (yydebug)\n System.out.println(msg);\n}", "@Override\n\tpublic boolean isDebugEnabled() {\n\t\treturn debugEnabled;\n\t}", "public static boolean debugOn()\r\n {\r\n on = true;\r\n System.out.println(\"Debug Mode On\");\r\n return on;\r\n }", "public void setDebug(boolean isDebug)\n {\n this.isDebug = isDebug;\n this.repaint();\n }", "public void debug()\r\n {\n \t\treload();\r\n }", "public boolean isDebugEnabled();", "void setDebug(boolean mode) {\n\t\tdebug = mode;\n\t}", "public LagartoDOMBuilder enableDebug() {\n\t\tconfig.collectErrors = true;\n\t\tconfig.parserConfig.setCalculatePosition(true);\n\t\treturn this;\n\t}", "public static void debug(boolean d) {\n D = d;\n }", "public void setDebug(final boolean debug)\n {\n this.debug = debug;\n }", "public void setDebugMode(final boolean dMode) { debugMode = dMode; }", "void debug(String msg)\n {\n if (yydebug)\n System.out.println(msg);\n }", "public void setDisplayDebug(boolean displayDebug) {\n this.displayDebug = displayDebug;\n }", "public static boolean debugOff()\r\n {\r\n on = false;\r\n System.out.println(\"Debug Mode Off\");\r\n return on;\r\n }", "public static void setDebug(boolean debug) {\n IsDebug = debug;\n if (debug)\n setLevel(VERBOSE);\n else\n setLevel(INFO);\n }", "protected void debug(String string) {\n\t\tif (DEBUGMODE)\n\t\t\tSystem.out.println(string);\n\t}", "public Render setDebugPrint() {\r\n\t\t_print = true;\r\n\t\treturn this;\r\n\t}", "public void setDebug(boolean debug) {\n\t\tthis._debug = debug;\n\t}", "public void setDebugMode(boolean debugMode)\r\n {\r\n this.debugMode = debugMode;\r\n }", "@Override\n\tpublic void setDebugMode(int debugMode) {\n\n\t}", "boolean isDebugEnabled();", "public static void setDebug(boolean flag)\n\t{\n\t\tm_debugFlag = flag;\n\t}", "public void setDebuggable(boolean debug) {\n this.debug = debug;\n }", "public void setDebugMode(boolean debugMode) {\n this.debugMode = debugMode;\n }", "public void setDebugMode(boolean status)\n {\n debugMode = status;\n }", "protected static void setDebugLevel(int debugLevel) {\n Program.debugLevel = debugLevel;\n }", "private void debug(String s) {\r\n\t\tif (debug)\r\n\t\t\tSystem.out.println(s);\r\n\t}", "public void setDebug( boolean debugF ) {\n\t\tthis.debug = debugF;\n\t\t}", "public static void setDebugMode(boolean debugMode) {\n mDebug = debugMode;\n }", "private void debugInConsole() {\n String command = \"\";\n do {\n try {\n command = getCommandWithPrompt();\n doDebugCommand(command);\n } catch (Error e) {\n println(e.getMessage());\n }\n } while (!command.equals(\"exit\"));\n }", "public static void setDebug(int b) {\n debug = b;\n }", "public void debug() {\n\n\t\t// Establecemos el estado\n\t\tsetEstado(Estado.DEBUG);\n\n\t\t// Obtenemos la proxima tarea\n\t\ttarea = planificador.obtenerProximaTarea();\n\t}", "public boolean isDebugEnabled() {\n return debugEnabled;\n }", "public boolean isDebug();", "public boolean isDebugEnabled()\n/* */ {\n/* 250 */ return getLogger().isDebugEnabled();\n/* */ }", "public void debug(String msg);", "public void debug( int level ) {\r\n\t\tdebugLevel = level;\r\n\t\ts.debug(debugLevel);\r\n\t}", "protected void dbgOut(String text_out)\n {\n if (debugOn)\n System.out.println(text_out);\n }", "public static void traceOn() {\r\n\t\ttraceOn = true;\r\n\t}", "public static void setDebug(boolean db) {\n\n\t\tdebug = db;\n\n\t}", "@Input\n public boolean isDebuggable() {\n return debug;\n }", "public static void setDebugFlag(boolean flag) {\n\t\tPMA.setDebugFlag(flag);\n\t\tif (flag) {\n\t\t\tSystem.out.println(\n\t\t\t\t\t\"Debug flag enabled. You will receive extra feedback and messages from the Java SDK (like this one)\");\n\t\t\tif (PMA.logger != null) {\n\t\t\t\tPMA.logger.severe(\n\t\t\t\t\t\t\"Debug flag enabled. You will receive extra feedback and messages from the Java SDK (like this one)\");\n\t\t\t}\n\t\t}\n\t}", "public void setBufferDebug( boolean debug ) {\n\t\tthis.buffer.setDebug( debug );\n\t\t}", "public void setDebugSend( boolean debug_on_off )\n {\n debug_send = debug_on_off;\n }", "public boolean supportsDebugArgument();", "protected void setDebugging(boolean debugging) {\n\t\tthis.debugging = debugging;\n\t}", "public boolean getDebugMode() { return debugMode; }", "void setDebugPort(Integer debugPort);", "protected void setContinueDebug(boolean continueDebug) {\n\t\tthis.continueDebug = continueDebug;\n\t}", "public void debug(String message);", "private void debug(final String msg) {\n \t\tif (debug) System.out.println(msg);\n \t}", "private void debug(String post) {\n if (GameLauncher.isDebugging()) {\n System.out.println(post);\n }\n }", "public synchronized void setDebugTraceEnabled(TrcDbgTrace tracer, boolean enabled)\n {\n debugTracer = enabled ? tracer : null;\n }", "public abstract void debug(RobocodeFileOutputStream output);", "protected boolean isDebugEnable() {\n return BlurDialogEngine.DEFAULT_DEBUG_POLICY;\n }", "boolean isDebug();", "boolean isDebug();", "public void debug(PrintStream out) throws IOException {\n\t\tdebug(new PrintWriter(out));\n\t}", "@Override\n\tpublic boolean isDebugEnabled(Marker marker) {\n\t\treturn false;\n\t}", "public void debug(Writer out) throws IOException {\n\t\tlog = out;\n\t\tdebug = true;\n\t}", "public static void setVerbose(int b) {\n debug = b;\n }", "public void setDebugOn(boolean flag)\n {\n this.setProperty(GUILoggerSeverityProperty.DEBUG, flag);\n }", "public void activateConsoleMode() {\n logger.addHandler(mConsoleHandler);\n }", "@Override\n public void printDebug(String string) {\n if(allActive && active)\n System.out.println(SC + string + R);\n }", "public void printForDebug() {\n\t\tif(Globalconstantable.DEBUG)\n\t\t{\n\t\t\tSystem.out.println(this.getSID());\n\t\t\tSystem.out.println(this.getScores());\n\t\t}\n\t}", "public boolean isDebug( ) {\n\t\treturn debug;\n\t}", "public boolean isDisplayDebug() {\n return displayDebug;\n }", "final void out (String msg) { if (m_debugMode) { Logger.println (msg); } }", "private static void debug()\r\n\t{\r\n\t\tSystem.out.println(\"Keywords:\");\r\n\t\tfor(String word : keywords)\r\n\t\t{\r\n\t\t\tSystem.out.println(word);\r\n\t\t}\r\n\t\t\r\n\t\tSystem.out.println(\"-----------------\");\r\n\t\tSystem.out.println();\r\n\t\tSharedLink.debugLinks();\r\n\t\t\r\n\t\tSystem.out.println(\"-----------------\");\r\n\t\tSystem.out.println();\r\n\t\tSharedPage.debugPages();\r\n\t\t\r\n\t\tSystem.out.println();\r\n\t}" ]
[ "0.78846765", "0.74868345", "0.7361623", "0.72635984", "0.72507393", "0.7141432", "0.69533914", "0.68902963", "0.6866221", "0.6839589", "0.6827286", "0.6823235", "0.68112755", "0.68015707", "0.67953444", "0.6791693", "0.67801267", "0.67739767", "0.6770233", "0.676036", "0.67046535", "0.6675413", "0.6675413", "0.66606224", "0.6644063", "0.6639819", "0.66311973", "0.66105676", "0.6602166", "0.6602166", "0.6591914", "0.6591914", "0.6572811", "0.65634423", "0.65375924", "0.6528838", "0.651457", "0.64970636", "0.64966136", "0.64531183", "0.6447476", "0.64412755", "0.6438023", "0.643203", "0.6406748", "0.63773817", "0.6358381", "0.63565415", "0.6352177", "0.63301516", "0.6312908", "0.629866", "0.62559736", "0.6246255", "0.6243695", "0.6242969", "0.624184", "0.6205321", "0.6142779", "0.6118342", "0.6110631", "0.61029017", "0.60889775", "0.60881716", "0.60826993", "0.6075455", "0.60751766", "0.60226685", "0.5994465", "0.599385", "0.5991212", "0.597727", "0.59772587", "0.59747267", "0.59734267", "0.5961396", "0.5933895", "0.5930899", "0.59265053", "0.5898463", "0.5896538", "0.589276", "0.5889138", "0.5883008", "0.58801085", "0.5867177", "0.58644456", "0.58644456", "0.58639294", "0.5847058", "0.5845315", "0.5833881", "0.5815652", "0.58022565", "0.5793016", "0.5790554", "0.5789751", "0.57775545", "0.5766856", "0.5763932" ]
0.7588504
1
Enables debug output (for all subsequent interpreter calls).
static void debug(boolean b) { ProcessRunnerImpl.setGlobalDebug(b); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void enableDebug() {\n this.debug = true;\n }", "static void debug() {\n ProcessRunnerImpl.setGlobalDebug(true);\n }", "public static void enableDebugging(){\n DEBUG = true;\n }", "public void toggleDebug() {\n\t\tdebug = debug ? false : true;\n\t}", "void debug() {\n this.renderer.debug = !this.renderer.debug;\n reload();\n }", "void setDebugEnabled(boolean value) {\r\n debug_enabled = value;\r\n }", "public void setDebug(boolean b) { debug = b; }", "public void setDebug(boolean value) {\n\t\tdebug = value;\n\t}", "public void setDebugging(boolean on)\n\t{\n\t\t_options.setDebugging(on);\n\t}", "void k2h_set_debug_level_silent();", "public void disableDebug() {\n this.debug = false;\n }", "public void setDebug(boolean f) {\n debug = f;\n }", "@Override\n\tpublic void setDebugMode(boolean debug) {\n\n\t}", "public void debug() {\n\n }", "@Override\n protected boolean isDebugEnable() {\n return false;\n }", "public static void setDebug(boolean d) {\n\t\tdebug = d;\n\t}", "public void toggleDebugMode() {\r\n DEBUG = !DEBUG;\r\n }", "public void setDebugEnabled(boolean debugEnabled) {\n this.debugEnabled = debugEnabled;\n }", "public static void normalDebug(){\n enableVerbos = false;\n }", "public static void disableDebugging(){\n DEBUG = false;\n }", "@Override\n\tpublic void setDebug(boolean isDebug) {\n\t\t\n\t}", "public void setDebug(IRubyObject debug) {\n this.debug = debug.isTrue();\n }", "public void setDebug(IRubyObject debug) {\n this.debug = debug.isTrue();\n }", "public void setDebug(boolean debug) {\n this.debug=debug;\n }", "public final void setDebug() {\r\n setLevel(org.apache.log4j.Level.DEBUG);\r\n }", "public void continueDebugStep() {\n \tthis.continueDebug = true;\n }", "public abstract void debug(PrintStream console);", "public void setDebug(boolean debug, PrintStream out)\n {\n session.setDebug(debug);\n if (debug)\n session.setDebugOut(out);\n }", "public void setDebug(boolean debug) {\n this.debug = debug;\n }", "public void setDebug(boolean debug) {\n this.debug = debug;\n }", "void debug(String msg)\n{\n if (yydebug)\n System.out.println(msg);\n}", "void debug(String msg)\n{\n if (yydebug)\n System.out.println(msg);\n}", "@Override\n\tpublic boolean isDebugEnabled() {\n\t\treturn debugEnabled;\n\t}", "public static boolean debugOn()\r\n {\r\n on = true;\r\n System.out.println(\"Debug Mode On\");\r\n return on;\r\n }", "public void setDebug(boolean isDebug)\n {\n this.isDebug = isDebug;\n this.repaint();\n }", "public void debug()\r\n {\n \t\treload();\r\n }", "public boolean isDebugEnabled();", "void setDebug(boolean mode) {\n\t\tdebug = mode;\n\t}", "public LagartoDOMBuilder enableDebug() {\n\t\tconfig.collectErrors = true;\n\t\tconfig.parserConfig.setCalculatePosition(true);\n\t\treturn this;\n\t}", "public static void debug(boolean d) {\n D = d;\n }", "public void setDebug(final boolean debug)\n {\n this.debug = debug;\n }", "public void setDebugMode(final boolean dMode) { debugMode = dMode; }", "void debug(String msg)\n {\n if (yydebug)\n System.out.println(msg);\n }", "public void setDisplayDebug(boolean displayDebug) {\n this.displayDebug = displayDebug;\n }", "public static boolean debugOff()\r\n {\r\n on = false;\r\n System.out.println(\"Debug Mode Off\");\r\n return on;\r\n }", "public static void setDebug(boolean debug) {\n IsDebug = debug;\n if (debug)\n setLevel(VERBOSE);\n else\n setLevel(INFO);\n }", "protected void debug(String string) {\n\t\tif (DEBUGMODE)\n\t\t\tSystem.out.println(string);\n\t}", "public Render setDebugPrint() {\r\n\t\t_print = true;\r\n\t\treturn this;\r\n\t}", "public void setDebug(boolean debug) {\n\t\tthis._debug = debug;\n\t}", "public void setDebugMode(boolean debugMode)\r\n {\r\n this.debugMode = debugMode;\r\n }", "@Override\n\tpublic void setDebugMode(int debugMode) {\n\n\t}", "boolean isDebugEnabled();", "public static void setDebug(boolean flag)\n\t{\n\t\tm_debugFlag = flag;\n\t}", "public void setDebuggable(boolean debug) {\n this.debug = debug;\n }", "public void setDebugMode(boolean debugMode) {\n this.debugMode = debugMode;\n }", "public void setDebugMode(boolean status)\n {\n debugMode = status;\n }", "protected static void setDebugLevel(int debugLevel) {\n Program.debugLevel = debugLevel;\n }", "private void debug(String s) {\r\n\t\tif (debug)\r\n\t\t\tSystem.out.println(s);\r\n\t}", "public void setDebug( boolean debugF ) {\n\t\tthis.debug = debugF;\n\t\t}", "public static void setDebugMode(boolean debugMode) {\n mDebug = debugMode;\n }", "private void debugInConsole() {\n String command = \"\";\n do {\n try {\n command = getCommandWithPrompt();\n doDebugCommand(command);\n } catch (Error e) {\n println(e.getMessage());\n }\n } while (!command.equals(\"exit\"));\n }", "public static void setDebug(int b) {\n debug = b;\n }", "public void debug() {\n\n\t\t// Establecemos el estado\n\t\tsetEstado(Estado.DEBUG);\n\n\t\t// Obtenemos la proxima tarea\n\t\ttarea = planificador.obtenerProximaTarea();\n\t}", "public boolean isDebugEnabled() {\n return debugEnabled;\n }", "public boolean isDebug();", "public boolean isDebugEnabled()\n/* */ {\n/* 250 */ return getLogger().isDebugEnabled();\n/* */ }", "public void debug(String msg);", "public void debug( int level ) {\r\n\t\tdebugLevel = level;\r\n\t\ts.debug(debugLevel);\r\n\t}", "protected void dbgOut(String text_out)\n {\n if (debugOn)\n System.out.println(text_out);\n }", "public static void traceOn() {\r\n\t\ttraceOn = true;\r\n\t}", "public static void setDebug(boolean db) {\n\n\t\tdebug = db;\n\n\t}", "@Input\n public boolean isDebuggable() {\n return debug;\n }", "public static void setDebugFlag(boolean flag) {\n\t\tPMA.setDebugFlag(flag);\n\t\tif (flag) {\n\t\t\tSystem.out.println(\n\t\t\t\t\t\"Debug flag enabled. You will receive extra feedback and messages from the Java SDK (like this one)\");\n\t\t\tif (PMA.logger != null) {\n\t\t\t\tPMA.logger.severe(\n\t\t\t\t\t\t\"Debug flag enabled. You will receive extra feedback and messages from the Java SDK (like this one)\");\n\t\t\t}\n\t\t}\n\t}", "public void setBufferDebug( boolean debug ) {\n\t\tthis.buffer.setDebug( debug );\n\t\t}", "public void setDebugSend( boolean debug_on_off )\n {\n debug_send = debug_on_off;\n }", "public boolean supportsDebugArgument();", "protected void setDebugging(boolean debugging) {\n\t\tthis.debugging = debugging;\n\t}", "public boolean getDebugMode() { return debugMode; }", "void setDebugPort(Integer debugPort);", "protected void setContinueDebug(boolean continueDebug) {\n\t\tthis.continueDebug = continueDebug;\n\t}", "public void debug(String message);", "private void debug(final String msg) {\n \t\tif (debug) System.out.println(msg);\n \t}", "private void debug(String post) {\n if (GameLauncher.isDebugging()) {\n System.out.println(post);\n }\n }", "public synchronized void setDebugTraceEnabled(TrcDbgTrace tracer, boolean enabled)\n {\n debugTracer = enabled ? tracer : null;\n }", "public abstract void debug(RobocodeFileOutputStream output);", "protected boolean isDebugEnable() {\n return BlurDialogEngine.DEFAULT_DEBUG_POLICY;\n }", "boolean isDebug();", "boolean isDebug();", "public void debug(PrintStream out) throws IOException {\n\t\tdebug(new PrintWriter(out));\n\t}", "@Override\n\tpublic boolean isDebugEnabled(Marker marker) {\n\t\treturn false;\n\t}", "public void debug(Writer out) throws IOException {\n\t\tlog = out;\n\t\tdebug = true;\n\t}", "public static void setVerbose(int b) {\n debug = b;\n }", "public void setDebugOn(boolean flag)\n {\n this.setProperty(GUILoggerSeverityProperty.DEBUG, flag);\n }", "public void activateConsoleMode() {\n logger.addHandler(mConsoleHandler);\n }", "@Override\n public void printDebug(String string) {\n if(allActive && active)\n System.out.println(SC + string + R);\n }", "public void printForDebug() {\n\t\tif(Globalconstantable.DEBUG)\n\t\t{\n\t\t\tSystem.out.println(this.getSID());\n\t\t\tSystem.out.println(this.getScores());\n\t\t}\n\t}", "public boolean isDebug( ) {\n\t\treturn debug;\n\t}", "public boolean isDisplayDebug() {\n return displayDebug;\n }", "final void out (String msg) { if (m_debugMode) { Logger.println (msg); } }", "private static void debug()\r\n\t{\r\n\t\tSystem.out.println(\"Keywords:\");\r\n\t\tfor(String word : keywords)\r\n\t\t{\r\n\t\t\tSystem.out.println(word);\r\n\t\t}\r\n\t\t\r\n\t\tSystem.out.println(\"-----------------\");\r\n\t\tSystem.out.println();\r\n\t\tSharedLink.debugLinks();\r\n\t\t\r\n\t\tSystem.out.println(\"-----------------\");\r\n\t\tSystem.out.println();\r\n\t\tSharedPage.debugPages();\r\n\t\t\r\n\t\tSystem.out.println();\r\n\t}" ]
[ "0.78846765", "0.7588504", "0.74868345", "0.7361623", "0.72635984", "0.72507393", "0.7141432", "0.69533914", "0.68902963", "0.6866221", "0.6839589", "0.6827286", "0.6823235", "0.68112755", "0.68015707", "0.67953444", "0.6791693", "0.67801267", "0.6770233", "0.676036", "0.67046535", "0.6675413", "0.6675413", "0.66606224", "0.6644063", "0.6639819", "0.66311973", "0.66105676", "0.6602166", "0.6602166", "0.6591914", "0.6591914", "0.6572811", "0.65634423", "0.65375924", "0.6528838", "0.651457", "0.64970636", "0.64966136", "0.64531183", "0.6447476", "0.64412755", "0.6438023", "0.643203", "0.6406748", "0.63773817", "0.6358381", "0.63565415", "0.6352177", "0.63301516", "0.6312908", "0.629866", "0.62559736", "0.6246255", "0.6243695", "0.6242969", "0.624184", "0.6205321", "0.6142779", "0.6118342", "0.6110631", "0.61029017", "0.60889775", "0.60881716", "0.60826993", "0.6075455", "0.60751766", "0.60226685", "0.5994465", "0.599385", "0.5991212", "0.597727", "0.59772587", "0.59747267", "0.59734267", "0.5961396", "0.5933895", "0.5930899", "0.59265053", "0.5898463", "0.5896538", "0.589276", "0.5889138", "0.5883008", "0.58801085", "0.5867177", "0.58644456", "0.58644456", "0.58639294", "0.5847058", "0.5845315", "0.5833881", "0.5815652", "0.58022565", "0.5793016", "0.5790554", "0.5789751", "0.57775545", "0.5766856", "0.5763932" ]
0.67739767
18
Executes process with the specified arguments.
static ProcessRunner execute(String... arguments) { return ProcessRunnerImpl.execute(null, arguments); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public abstract void runProcess(String[] args) throws Exception;", "@Override\n public int execute(Parameters parameters) {\n\n final List<String> command = new ArrayList<>();\n final String b = binary.get();\n if (b == null) {\n throw new IllegalStateException(\"No binary found\");\n }\n command.add(binary.get());\n final ProcessBuilder pb = new ProcessBuilder(command);\n if (workdir != null) {\n pb.directory(workdir);\n }\n final Process p;\n try {\n if (commonArgs != null) {\n command.addAll(commonArgs.stream().map(Supplier::get).toList());\n }\n Collections.addAll(command, parameters.args);\n logger.info(toString(command));\n p = pb.start();\n parameters.onProcessCreation.accept(p);\n\n final ProcessTimeoutHandle handle;\n if (processTimeout != null) {\n handle = startProcessTimeoutMonitor(p, String.valueOf(command), processTimeout);\n } else {\n handle = null;\n }\n final Copier inputCopier = parameters.in != null ?\n copyThread(\n \"input -> process input copier\",\n parameters.in,\n p.getOutputStream(),\n (c) -> closeSilently(p.getOutputStream()),\n (e) -> {},\n p\n ) : null;\n\n final Copier copier;\n if (parameters.out != null) {\n InputStream commandOutput;\n if (useFileCache) {\n commandOutput = FileCachingInputStream\n .builder()\n .input(p.getInputStream())\n .noProgressLogging()\n .build();\n } else {\n commandOutput = p.getInputStream();\n }\n copier = copyThread(\"process output parameters out copier\",\n commandOutput,\n parameters.out,\n (c) -> closeSilently(commandOutput),\n (e) -> {\n Process process = p.destroyForcibly();\n logger.info(\"Killed {} because {}: {}\", process, e.getClass(), e.getMessage());\n }, p);\n } else {\n copier = null;\n }\n\n final Copier errorCopier = copyThread(\n \"error copier\",\n p.getErrorStream(),\n parameters.errors,\n (c) -> closeSilently(p.getErrorStream()),\n (e) -> {},\n p\n );\n if (inputCopier != null) {\n if (needsClose(p.getInputStream())) {\n inputCopier.waitForAndClose();\n } else {\n inputCopier.waitFor();\n }\n }\n\n p.waitFor();\n\n if (copier != null) {\n copier.waitForAndClose();\n }\n errorCopier.waitForAndClose();\n int result = p.exitValue();\n logger.log(exitCodeLogLevel.apply(result), \"Exit code {} for calling {}\", result, commandToString(command));\n\n if (parameters.out != null) {\n parameters.out.flush();\n }\n parameters.errors.flush();\n if (handle != null) {\n handle.cancel();\n }\n return result;\n } catch (InterruptedException e) {\n Thread.currentThread().interrupt();\n throw new RuntimeException(e);\n } catch (IOException e) {\n if (isBrokenPipe(e)) {\n logger.debug(e.getMessage());\n throw new BrokenPipe(e);\n } else {\n logger.error(e.getClass().getName() + \":\" + e.getMessage(), e);\n throw new RuntimeException(e);\n\n }\n } finally {\n this.logger.debug(\"Ready\");\n }\n }", "public static void main(String[] args) throws ExecuteException, IOException {\n\t\tString command = \"/home/pullmann/test\";\n\t\t\n\t\t\n\t\tByteArrayOutputStream outputStream = new ByteArrayOutputStream();\n\t CommandLine commandline = CommandLine.parse(command);\n\t DefaultExecutor exec = new DefaultExecutor();\n\t // Does not work - can't stop process\n\t ExecuteWatchdog watchdog = new ExecuteWatchdog(100);\n\t exec.setWatchdog(watchdog);\n\t PumpStreamHandler streamHandler = new PumpStreamHandler(outputStream);\n\t exec.setStreamHandler(streamHandler);\n\t exec.execute(commandline);\n\t System.out.println(outputStream.toString());\n\t}", "private static void process(String... args) throws Exception {\n Deque<String> params = new LinkedList<>(Arrays.asList(args));\n String command = params.pop().toUpperCase(Locale.ROOT);\n valueOf(command).run(params);\n }", "public static void main(String[] args) {\n\t\t\n\t\tRegistry aRegistry;\n\t\t\n\t\ttry {\n\t\t\tString RMIPortNum=args[0];\n\t\t\tint processID = Integer.parseInt(args[1]);\n\t\t\tint processCount = Integer.parseInt(args[2]);\n\t\t\tProcess exportedProcess = new Process(processID,processCount,RMIPortNum);\n\t\t\taRegistry = LocateRegistry.createRegistry(Integer.parseInt(RMIPortNum));\n\t\t\t\taRegistry.rebind(\"server\", exportedProcess);\n\t\t\tSystem.out.println(\"Process is Up and Running...\");\n\t\t\t//exportedProcess.moneyReceiveExecuter();\n\n\t\t\texportedProcess.snapShotTerminator();\n\t\t\tSystem.out.println(\"Press Enter when all Process are running\");\n\t\t\tScanner sc = new Scanner(System.in);\n\t\t\tsc.nextLine();\n\t\t\t//exportedProcess.markerExecuter();\t\t\t\n\t\t\tif(processID==1)\n\t\t\t\texportedProcess.snapShotexecuter();\n\t\t\tif(processID!=1)\n\t\t\t\texportedProcess.snapShotExecuterpassive();\n\n\t\t\t//exportedProcess.snapShotTerminator();\n\t\t\texportedProcess.transactionExecuter();\n\t\t\t\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t\t\n\t\t\t}\n\t\t\t\n\t\t}", "public static void main(String[] args) throws Exception {\n\t\tSystem.out.println(runRemoteProcess(args[0]));\n\t}", "public boolean execute(String[] args);", "void execute(Executable executable);", "public void main(String[] args) {\n try {\n execute(null, args);\n } catch (Exception e) {\n CommandLineHelper.handleException(e);\n }\n }", "private int handleExec(int file, int argc, int argv){\n\t\tSystem.out.print(\"EXECUTING...\");\n\n\t\tif(argc < 1) return INVALID;\n\n\t\tString filename = readVirtualMemoryString(file, MAXSTRLEN);\n\n\t\tif(filename == null || !filename.endsWith(\".coff\")) return INVALID;\n\n\t\tString[] args = new String[argc];\n\n\t\tfor(int i=0; i<argc; i++){\n\t\t\tbyte[] buffer = new byte[4];\n\t\t\tif(readVirtualMemory(argv + i * 4, buffer) != 4)return INVALID;\n\t\t\tif((args[i] = readVirtualMemoryString(Lib.bytesToInt(buffer, 0), MAXSTRLEN)) == null) return INVALID;\n\t\t}\n\n\t\tSystem.out.println(\"Read arguments creating Child... XD\");\n\n\t\t//This is so we can use a child class process like new Process\n\t\tUserProcess child = UserProcess.newUserProcess();\n\t\tSystem.out.println(\"mpid: \"+ processId);\n\t\tSystem.out.println(\"cpid: \"+ child.processId);\n\n\t\tif(child.execute(filename, args)){\n\t\t\tchildProcesses.put(child.processId,child);\n\t\t\tchild.parentProcess = this;\n\t\t\treturn child.processId;\n\t\t}\n\n\t\treturn INVALID;\n\t}", "public void process(String[] args) {\n ExitStatus status = parseCommand(args);\n System.err.println(status.getMessage());\n System.exit(status.getExitCode().getStatusCode());\n }", "public void run(String[] args) {\r\n\t\ttry {\r\n\t\t\t// Get the job id from argument, the first argument will be the Job process class\r\n\t\t\tint jobId = Integer.parseInt(args[1]);\r\n\t\t\t\r\n\t\t\t// Get the job name\r\n\t\t\tString jobName = args[2];\r\n\t\t\t\r\n\t\t\tint runMode = Integer.parseInt(args[3]);\r\n\t\t\t\r\n\t\t\t// Log start time to DB\r\n\t\t\tlong id = this.logStart(jobId, jobName, runMode);\r\n\t\t\t\r\n\t\t\t// Error message\r\n\t\t\tString errMsg = StringPool.BLANK;\r\n\t\t\t\r\n\t\t\ttry {\r\n\t\t\t\tthis.runProcess(args);\r\n\t\t\t} catch (Exception e) {\r\n\t\t\t\te.printStackTrace();\r\n\t\t\t\t// Get the error message during execution\r\n\t\t\t\terrMsg = e.getMessage() + e.toString();\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// Log the end status\r\n\t\t\tthis.logEnd(id, errMsg);\r\n\t\t\t\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t}", "public abstract void runProcess();", "@Override\n public void execute(String[] args) {\n\n }", "Optional<String> execute(String command, List<String> args);", "@Override\n\tpublic ShellStatus executeCommand(Environment env, String arguments) {\n\t\tList<String> argumentList;\n\n\t\ttry {\n\t\t\targumentList = Util.parseArguments(arguments);\n\t\t} catch (IllegalArgumentException ex) {\n\t\t\tenv.writeln(ex.getMessage());\n\t\t\treturn ShellStatus.CONTINUE;\n\t\t}\n\n\t\tif (argumentList.size() != 1) {\n\t\t\tenv.writeln(\"Expected 1 argument.\");\n\t\t\treturn ShellStatus.CONTINUE;\n\t\t}\n\n\t\tFile directory = new File(argumentList.get(0));\n\n\t\tif (!directory.exists()) {\n\t\t\tenv.writeln(\"The specified directory doesn't exist.\");\n\t\t\treturn ShellStatus.CONTINUE;\n\t\t}\n\n\t\tprintTree(directory, 0, env);\n\n\t\treturn ShellStatus.CONTINUE;\n\t}", "public static void main(String[] args) throws Exception {\n\t\tSystem.out.println(\"All processes: \");\n\t\tProcessHandle.allProcesses().filter(pa -> pa.info().command().isPresent()).forEach(pa -> System.out\n\t\t\t\t.println(pa.pid() + \": \" + pa.info().command() + \" - \" + pa.info().user().orElse(\"N/A\")));\n\n\t\t// spawn a new process and show more process infos\n\t\tProcessBuilder pb = new ProcessBuilder(\"jshell\");\n\t\tProcess p = pb.inheritIO().start();\n\t\tSystem.out.println(\"\\nProcess \" + p.pid() + \" started\");\n\t\tProcessHandle.Info info = p.info();\n\t\tStringBuilder sb = new StringBuilder();\n\t\tsb.append(\"PID: \" + p.pid()).append(\"\\n\").append(\"Command: \").append(info.command().orElse(\"N/A\")).append(\"\\n\")\n\t\t\t\t.append(\"Start: \").append(info.startInstant().isPresent() ? info.startInstant() : \"N/A\").append(\"\\n\")\n\t\t\t\t.append(info.user().orElse(\"N/A\")).append(\"\\n\").append(\"Output: \").append(\"\\n\");\n\t\tSystem.out.println(sb.toString());\n\n\t\t// trigger an oncomplete action and kill the process, wait for demo purposes\n\t\tp.onExit().thenAccept(ps -> System.out.println(\"Process \" + ps.pid() + \" killed\"));\n\t\tThread.sleep(2000);\n\t\tSystem.out.println(\"\\nDuration: \" + info.totalCpuDuration().orElse(Duration.ofMillis(0)));\n\t\tSystem.out.println(\"Kill process \" + p.pid());\n\t\tp.destroy();\n\t\tThread.sleep(2000);\n\t}", "private int exec(UnixRuntime r, String[] argv, String[] envp) {\n for(int i=0;i<OPEN_MAX;i++) if(closeOnExec[i]) closeFD(i);\n r.fds = fds;\n r.closeOnExec = closeOnExec;\n // make sure this doesn't get messed with these since we didn't copy them\n fds = null;\n closeOnExec = null;\n \n r.gs = gs;\n r.sm = sm;\n r.cwd = cwd;\n r.pid = pid;\n r.parent = parent;\n r.start(argv,envp);\n \n state = EXECED;\n execedRuntime = r;\n \n return 0; \n }", "public void run() {\n\t\t\t\tString command = \"psexec -u ACCUSYSARGBSAS\\\\martin.zaragoza -p Marzo2015 D:\\\\Temp\\\\testScripts\\\\a.exe a\";\n\t\t\t\tProcess process;\n\t\t\t\ttry {\n\t\t\t\t\tprocess = Runtime.getRuntime().exec(command);\n\t\t\t\t} catch (IOException e1) {\n\t\t\t\t\te1.printStackTrace();\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\ttry {\n\t\t\t\t\tint pid = getPid(process);\n\t\t\t\t\tSystem.out.println(\"pid=\" + pid);\n\t\t\t\t\tprintStdout(process.getInputStream());\n\t\t\t\t\tThread.sleep(500);\n\n\t\t\t\t\tProcess exec = Runtime.getRuntime().exec(\"echo %errorlevel%\");\n\t\t\t\t\tprintStdout(exec.getInputStream());\n\t\t\t\t} catch (Exception e) {\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t}", "public static void main(String[] args) {\r\n\t\tSystem.exit(createCommandLine().execute(args));\r\n\t}", "public static void exec(String cmd, String args) throws ewe.io.IOException{\r\n\t\tString plattform = Vm.getPlatform();\r\n\t\tif(plattform.equals(\"WinCE\")){\r\n\t\t\tVm.exec(cmd, args, 0, false);\r\n\t\t}\r\n\t\tif(plattform.equals(\"Win32\")){\r\n\t\t\tVm.exec(cmd, args, 0, false);\r\n\t\t}\r\n\t\tif(plattform.equals(\"Unix\")){\r\n\t\t\tString[] strarr = new String[1];\r\n\t\t\tstrarr[0] = \"\\\"\" + cmd + \"\\\" \"+args;\r\n\t\t\tString[] dummy = new String[1];\r\n\t\t\tVm.exec(strarr, dummy);\r\n\t\t}\r\n\t\tif(plattform.equals(\"Java\")){\r\n\t\t\tVm.exec(\"\\\"\" + cmd + \"\\\" \"+args, null);\r\n\t\t}\r\n\t}", "public void executeASync (ProcessInfo pi)\r\n\t {\r\n\t }", "public static void main(String[] args) {\n \targuments = args;\n launch(args);\n }", "@Override\n\tpublic int execute(String args) {\n\t\treturn 0;\n\t}", "public static void exec(String[] args) {\n if (args.length == 0) {\n writeShortManual();\n return;\n }\n\n switch (args[0].toLowerCase()) {\n case \"plan\":\n plan(args);\n break;\n case \"testgen\":\n testgen(args);\n break;\n default: API.throwCLIError(\"Invalid command: \" + args[0]);\n }\n }", "private void executeCommand(String command) throws Exception\r\n\t{\r\n\t\tProcess process = null;\r\n\r\n\t\tif (!command.equalsIgnoreCase(\"\"))\r\n\t\t{\r\n\t\t\tprocess = this.runtime.exec(command);\r\n\r\n\t\t\t// any error message?\r\n\t\t\tfinal StreamGobbler errorGobbler = new StreamGobbler(process.getErrorStream());\r\n\r\n\t\t\t// any output?\r\n\t\t\tfinal StreamGobbler outputGobbler = new StreamGobbler(process.getInputStream());\r\n\r\n\t\t\t// kick them off\r\n\t\t\terrorGobbler.start();\r\n\t\t\toutputGobbler.start();\r\n\r\n\t\t\tfinal int i = process.waitFor();\r\n\t\t\tprocess.destroy();\r\n\t\t\tSystem.out.println(\"exit val of process \" + process.exitValue());\r\n\t\t\tSystem.out.println(command + \":\" + i);\r\n\t\t}\r\n\t}", "private static void runProcess(String command) throws Exception {\n\t\tProcess pro;\n\t\tpro = Runtime.getRuntime().exec(path + \"\\\\\" + command);\n\t\t// prints regular output\n\t\tprintLines(command + \"> stdout: \", pro.getInputStream());\n\t\t// prints errors\n\t\tprintLines(command + \"> stderr: \", pro.getErrorStream());\n\t\t// waits until process is finished and prints return value\n\t\tpro.waitFor();\n\t\tSystem.out.println(command + \"> exitValue \" + pro.exitValue());\n\t}", "public static void main(String[] args) throws IOException {\n\t\tProcess process = Runtime.getRuntime().exec(\"cmd /c start cmd\");\r\n\r\n\t\tBufferedWriter in = new BufferedWriter(new OutputStreamWriter(process\r\n\t\t\t\t.getOutputStream()));\r\n\t\tString line = \"2967 \";\r\n\t\tin.write(line);\r\n\t\tin.flush();\r\n\t\tin.close();\r\n\t\tInputStream out = process.getInputStream();\r\n\t\t// clean up if any output in stdout\r\n\t\tBufferedReader brCleanUp = new BufferedReader(\r\n\t\t\t\tnew InputStreamReader(out));\r\n\t\twhile ((line = brCleanUp.readLine()) != null) {\r\n\t\t\tSystem.out.println(\"[Stdout] \" + line);\r\n\t\t}\r\n\t\tbrCleanUp.close();\r\n\t\tprocess.destroy();\r\n\t}", "@Override\n\tpublic void process() {\n\t\tport = Integer.parseInt(args);\n\t\tsuper.process();\n\t}", "@Nullable\n public static byte[] run(Output output, @Nullable File file, String ...args)\n {\n ProcessBuilder processBuilder = new ProcessBuilder();\n processBuilder.command(args);\n\n if (file != null)\n {\n processBuilder.redirectInput(file);\n }\n\n try\n {\n //start process\n Process process = processBuilder.start();\n\n //read bytes form streams\n byte[] bytes = Simple.readInputStreamToByteArray(process.getInputStream());\n byte[] error = Simple.readInputStreamToByteArray(process.getErrorStream());\n\n int exitVal = process.waitFor();\n\n if (exitVal == 0)\n {\n //\n // Execution was a success!\n //\n\n return (output == Output.STDOUT) ? bytes : null;\n }\n else\n {\n //\n // Execution failed!\n //\n\n return (output == Output.STDERR) ? error : null;\n }\n }\n catch (Exception exc)\n {\n exc.printStackTrace();\n }\n\n return null;\n }", "private void runProcess(String command) throws PaleoException {\n\t\ttry {\n\t\t\tprocess = Runtime.getRuntime().exec(command);\n\t\t\tinputStream = process.getErrorStream();\n\t\t\terreur = new StringBuilder(\"\");\n\t\t\tint c;\n\t\t\twhile ((c = inputStream.read()) != -1) {\n\t\t\t\terreur.append((char) c);\n\t\t\t}\n\t\t\tinputStream.close();\n\t\t} catch (IOException e) {\n\t\t\tthrow new ESException(e.getMessage());\n\t\t}\n\t}", "public abstract void exec(CommandSender sender, String[] args);", "private void runSubprocess (File directory, String... command) throws InterruptedException, IOException, MojoExecutionException {\n ProcessBuilder pBuilder = new ProcessBuilder(command);\n \n if (directory != null) {\n pBuilder.directory(directory);\n }\n pBuilder.redirectError(ProcessBuilder.Redirect.INHERIT);\n pBuilder.redirectOutput(ProcessBuilder.Redirect.INHERIT);\n pBuilder.redirectInput(ProcessBuilder.Redirect.INHERIT);\n \n Process runningProcess = pBuilder.start();\n runningProcess.waitFor();\n if (runningProcess.exitValue() != 0) {\n throw new MojoExecutionException(\"Error with command '\"+Arrays.toString(command)+\"', status code \"+runningProcess.exitValue());\n }\n }", "public void exec();", "public static void main(String[] args) throws IOException {\n String command, file, destination;\n Scanner in = new Scanner(System.in);\n System.out.print(\"Enter: command file destination\\n\");\n command = in.next();\n file = in.next();\n destination = in.next();\n\n Process process = new ProcessBuilder(\"EncryptionUtil\", command, file, destination).start();\n InputStream is = process.getInputStream();\n InputStreamReader isr = new InputStreamReader(is);\n BufferedReader br = new BufferedReader(isr);\n String line;\n\n System.out.printf(\"Output of running %s is:\", Arrays.toString(args));\n\n while ((line = br.readLine()) != null) {\n System.out.println(line);\n }\n// EncryptionUtil sec = null;\n// sec = new EncryptionUtil();\n//\n//\n// try {\n//\n// System.out.println(\"Testing file encrypting: \");\n// File input = new File(\"To Encrypt.txt\");\n// File output = new File(\"Encrypted Output.txt\");\n//\n// sec.encrypt(input, output);\n//\n// File deOut = new File(\"Decrypted Output.txt\");\n//\n// sec.decrypt(output, deOut);\n//\n//\n// } catch (Exception e) {\n// e.printStackTrace();\n// }\n }", "public static void main(String[] args) {\n process();\n }", "public abstract String run(String args);", "public static void main(String[] args) {\n\t\t\ttry {\n\t\t\t\tExecThread();\n\t\t\t} catch (Exception e) {\n\t\t\t\t// TODO: handle exception\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t}", "private void execute(String cmd[])\n {\n /* Begin process */\n Process p;\n String cmdLine = \"\";\n int i;\n \n for ( i = 0 ; i < cmd.length; i++ ) {\n cmdLine += cmd[i];\n cmdLine += \" \";\n }\n System.out.println(\"Starting: \" + cmdLine);\n \n try {\n p = Runtime.getRuntime().exec(cmd);\n } catch ( IOException e ) {\n throw new RuntimeException(\"Test failed - exec got IO exception\");\n }\n \n /* Save process output in StringBuffers */\n output = new MyInputStream(\"Input Stream\", p.getInputStream());\n error = new MyInputStream(\"Error Stream\", p.getErrorStream());\n \n /* Wait for process to complete, and if exit code is non-zero we fail */\n try {\n int exitStatus;\n exitStatus = p.waitFor();\n if ( exitStatus != 0) {\n System.out.println(\"Exit code is \" + exitStatus);\n error.dump(System.out);\n output.dump(System.out);\n throw new RuntimeException(\"Test failed - \" +\n \"exit return code non-zero \" +\n \"(exitStatus==\" + exitStatus + \")\");\n }\n } catch ( InterruptedException e ) {\n throw new RuntimeException(\"Test failed - process interrupted\");\n }\n System.out.println(\"Completed: \" + cmdLine);\n }", "public TProcess executeInBackground(String[] commandLine, File workingDir, File logFile, double timeoutInSeconds) {\n\t\tlogger.info(\"Running: \" + commandLine + \" workingDir=\" + workingDir + \" logFile=\" + logFile);\n\n\t\tTProcess result = null;\n\n\t\tRuntime rt = Runtime.getRuntime();\n\n\t\t// Executing the command\n\t\tProcess proc = null;\n\t\ttry {\n\t\t\tproc = rt.exec(commandLine, null, workingDir);\n\n\t\t\tresult = new TProcess(proc, timeoutInSeconds);\n\t\t\tif(logFile != null) {\n\t\t\t\tresult.registerOutput(logFile, \"\");\n\t\t\t}\n\n\t\t} catch(IOException e) {\n\t\t\te.printStackTrace();\n\t\t\ttestCase.addTestResult(false, \"An error occured during process execution\");\n\t\t}\n\n\t\treturn result;\n\t}", "public static void main(String[] args) {\n\t\tprocess();\r\n\r\n\t}", "public void run() throws Exception {\n if (getLog().isDebugEnabled()) {\n getLog().debug(\"Launching JVM with command line: \" + String.join(\" \", args));\n }\n process = new ProcessBuilder(args)\n .inheritIO()\n .directory(workingDir)\n .start();\n //https://github.com/quarkusio/quarkus/issues/232\n Runtime.getRuntime().addShutdownHook(new Thread(new Runnable() {\n @Override\n public void run() {\n process.destroy();\n }\n }, \"Development Mode Shutdown Hook\"));\n }", "protected void doExecute(String[] arguments, ContextStatus contextStatus) {\n // no action to do\n }", "public static void main(String[] args) throws IOException {\n\t\tFile directorio = new File(\".\\\\bin\");\n\t\tProcessBuilder pb = new ProcessBuilder (\"java\",\"LeerNombre\",\"prueba\");\n\t\tpb.directory(directorio);\n\t\tSystem.out.printf(\"Directorio de trabajo: %s \",pb.directory());\n\t\tProcess p = pb.start();\n\t\tint valor;\n\t\ttry {\n\t\t\tInputStream is = p.getErrorStream();\n\t\t\tint c;\n\t\t\twhile((c= is.read())!=-1) {\n\t\t\t\tSystem.out.print((char) c);\n\t\t\t\t\n\t\t\t}\n\t\t\tis.close();\n\t\t\tvalor=p.waitFor();\n\t\t\tSystem.out.println(valor);\n\t\t}catch(Exception e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t}", "void processCommandLineArguments(String[] args) throws ConfigurationException;", "public static void main(String [] args) throws MissingProcessException, Exception\r\n {\r\n new BatchApp().go(args);\r\n }", "public void _run() {\n String[] args = (String[])tEnv.getObjRelation(\"ARGS\");\n\n log.println(\"Running with arguments:\");\n for (int i=0; i< args.length; i++)\n log.println(\"#\" + i + \": \" + args[i]);\n\n oObj.run(args);\n\n tRes.tested(\"run()\", true);\n }", "public static void main(String[] args) {\n\t\ttry {\n\t\t\tBisSNP instance = new BisSNP();\n\t\t\tfor (String arg : args) {\n\t\t\t\targCommandline = argCommandline + \" \" + arg;\n\t\t\t}\n\t\t\tstart(instance, args);\n\n\t\t\tSystem.exit(CommandLineProgram.result);\n\t\t} catch (UserException e) {\n\t\t\texitSystemWithUserError(e);\n\t\t} catch (Exception e) {\n\t\t\texitSystemWithError(e);\n\t\t}\n\n\t}", "public Command(String[] arguments) {\n this.setArguments(arguments);\n }", "public static Process exec(\n String cmd,\n @SuppressWarnings(\"rawtypes\") Map envVars) throws IOException\n {\n return exec(cmd, envVars, true);\n }", "public static void main(String[] args) {\n\t\tCommandProcess cp = new CommandProcess();\n\t\tcp.process(new Command() {\n\t\t\t@Override\n\t\t\tpublic void execute() {\n\t\t\t\tSystem.out.println(\"내용보기 실행\");\n\t\t\t}\n\t\t});\n\t}", "@Override\n public void execute() throws BuildException {\n if (!isValidOs()) {\n return;\n }\n\n checkConfiguration();\n runExec(prepareExec());\n }", "abstract public void execute(Parameters p);", "public static void main(String[] args) {\n\t\tif (!processArguments(args)) {\n\t\t\tSystem.out.println(\"Invalid Arguments! Please try again..\");\n\t\t\tSystem.exit(1);\n\t\t}\n\t}", "private Process execute() throws IOException {\n Process process = builder.start();\n\n if (listener != null) {\n stdoutStreamListener = new StdoutStreamListener(process.getInputStream(), listener);\n stderrStreamListener = new StderrStreamListener(process.getErrorStream(), listener);\n }\n\n return process;\n }", "void exec(ICommandConsole console, List<String> options);", "void excuteCommand(Command commandToExecute, String [] params);", "public List<String> exec(SubProcessCommandLineArgs commands, SubProcessConfiguration configuration) throws Exception {\n try (CallingSubProcessUtilsAnemo.Permit permit =\n new CallingSubProcessUtilsAnemo.Permit(processBuilder.command().get(0))) {\n\n List<String> results = new ArrayList<>();\n String line = null;\n\n try {\n Process process = execBinary(processBuilder, commands, configuration);\n BufferedReader input =\n new BufferedReader\n (new InputStreamReader(process.getInputStream()));\n while ((line = input.readLine()) != null) {\n results.add(line);\n }\n input.close();\n } catch (Exception ex) {\n LOG.error(\"Error running executable \", ex);\n throw ex;\n }\n return results;\n }\n }", "ProcessTaskFactory<T> runAsCommand();", "protected void run(String classname, Vector args) throws BuildException {\r\n CommandlineJava cmdj = new CommandlineJava();\r\n cmdj.setClassname(classname);\r\n for (int i = 0; i < args.size(); i++) {\r\n cmdj.createArgument().setValue((String) args.elementAt(i));\r\n }\r\n run(cmdj);\r\n }", "void execute(String projectDir, Paths paths) throws CommandExecutionException;", "public static void main(String[] src) throws UnsupportedEncodingException {\n List<String> cmd = new ArrayList<>();\n cmd.add(\"C:\\\\Program Files (x86)\\\\Mozilla Firefox\\\\firefox.exe\");\n cmd.add(\"-no-remote\");\n cmd.add(\"-P\");\n cmd.add(\"aesha2\");\n// cmd.add(\"\\\"fileName\\\"\");\n ProcessBuilder builder = new ProcessBuilder().command(cmd);\n Process process = null;\n int exitCode=-1;\n\n try {\n process = builder.start();\n final Process finalProcess = process;\n Thread t=new Thread(new Runnable() {\n @Override\n public void run() {\n try {\n Thread.sleep(10000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n finalProcess.destroy();\n }\n });\n t.start();\n exitCode = process.waitFor();\n } catch (InterruptedException e) {\n String ed=new String(e.getMessage());\n System.out.println(ed);\n } catch (IOException e) {\n String ed=new String(e.getMessage());\n System.out.println(ed);\n }\n process.destroy();\n System.out.println(exitCode);\n }", "private void processArgs(String[] args)\n\t{\n\t\tboolean verbose = _verbose.getMatched();\n\n\t\t// disable console echo\n\t\t_writer.println(\"@echo off\");\n\n\t\tfor(int i = 0; i < args.length; ++i)\n\t\t{\n\t\t\ttry\n\t\t\t{\n\t\t\t\t// try and expand any wildcards not handled by DOS/Windows\n\t\t\t\tString[] xargs = expandArg(args[i]);\n\n\t\t\t\tfor(int j = 0; j < xargs.length; ++j)\n\t\t\t\t{\n\t\t\t\t\tif(verbose)\n\t\t\t\t\t{\n\t\t\t\t\t\tSystem.err.println(Strings.format(\"fProcessArg\", new Object[] { xargs[j] }));\n\t\t\t\t\t}\n\n\t\t\t\t\tFile pc = new File(xargs[j]);\n\t\t\t\t\t_writer.print(\"set CLASSPATH=%CLASSPATH%;\");\n\t\t\t\t\t_writer.println(pc.getCanonicalPath());\n\t\t\t\t}\n\t\t\t}\n\t\t\tcatch(IOException e)\n\t\t\t{\n\t\t\t\tSystem.err.println(Strings.format(\"fGeneralError\", new Object[] { e.getMessage() }));\n\t\t\t\t\n\t\t\t\tif(verbose)\n\t\t\t\t{\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\n\t\t\t\tSystem.exit(-1);\n\t\t\t}\n\t\t}\n\t}", "public static void main(String[] args) {\r\n MemoryManager memory = new MemoryManager(Integer.parseInt(args[0]));\r\n HashTable hasher = new HashTable(Integer.parseInt(args[1]), memory);\r\n if (args[2] != null) {\r\n File commands = new File(args[2]);\r\n Processor processor = new Processor(commands, hasher);\r\n processor.process();\r\n }\r\n //System.exit(0);\r\n \r\n }", "public static void run(String[] args) {\n launch(args);\n }", "@Override\n public void process(Serializable msg) {\n ((Command) msg).execute(arg);\n }", "public static void main(String[] args) {\n Scanner scanner = new Scanner(System.in);\n\n List<String> inputs = new InputsReader().read(scanner);\n\n List<Command> commands = new CommandsFactory().build(inputs);\n\n new CommandsProcessor().execute(commands);\n }", "public static void main(String[] args){\n DataProcess process = new DataProcess();\n }", "public static void main(String[] args) {\n\t\tBufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\t\tCreditCardProcess ccp = new CreditCardProcess();\n\t\ttry {\n\t\t\t// Read in the first line to check\n\t\t\tString line = br.readLine();\n\t\t\ttry {\n\t\t\t\t// Try use this first-line as file location\n\t\t\t\tBufferedReader fbr = new BufferedReader(new FileReader(line));\n\t\t\t\t// Success, then proceed to read in commands from file\n\t\t\t\twhile ((line = fbr.readLine()) != null) {\n\t\t\t\t\tccp.processCommand(line);\n\t\t\t\t}\n\t\t\t\tfbr.close();\n\t\t\t\t//Encountered error - file does not exist\n\t\t\t} catch (FileNotFoundException e) {\n\t\t\t\t//Use first line as command\n\t\t\t\tccp.processCommand(line);\n\t\t\t\t//Keep accepting command from console until an empty line is enter\n\t\t\t\twhile (!(line = br.readLine()).isEmpty()) {\n\t\t\t\t\tccp.processCommand(line);\n\t\t\t\t}\n\t\t\t} catch (IOException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t\tbr.close();\n\t\t} catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\tccp.print();\n\t}", "public int execute() throws IOException {\n\t\tCommandLine commandLine = createCommandLineForExecutable();\n\t\tappendGraphPathParameters(commandLine);\n\t\tappendThreadingParameters(commandLine);\n\t\tappendAlgorithmParameters(commandLine);\n\t\tappendOutputPathParameters(commandLine);\n\n\t\tLOG.debug(\"Starting job with command line: {}\", commandLine.toString());\n\n\t\tExecutor executor = createCommandExecutor();\n\t\texecutor.setStreamHandler(new PumpStreamHandler(System.out));\n\t\texecutor.setExitValue(0);\n\t\treturn executor.execute(commandLine);\n\t}", "public static void main(String[] args) {\n\t\tMain main = new Main(args);\n\t\tmain.execute();\n\t}", "public static void main(String args[]) {\n\t\tString cmd = \"java ExternalProgram \";//Need space in the end of the sentence , for adding the argument.\n\n/**\n*When you want to run the Windows program like 'notepad', you should del the following sentences.\t\t\n*\n*The argument that is transfered will be added to the string \"cmd\".\n*\n**/\n\t\tif (args.length == 0) {\n\t\t\tcmd += 0;\n\t\t\tSystem.out.println(\"Run \" + cmd);\n\t\t}\n\t\telse {\n\t\t\tcmd += args[0];//add the argument to the string \"cmd\"\n\t\t}\n\t\t\n\t\ttry {\n\t\t\tProcess ps = Runtime.getRuntime().exec(cmd);\n\t\t\tps.waitFor();\n\t\t\tif (ps.exitValue() == 0) {\n\t\t\t\tSystem.out.println(\"The program '\" + cmd + \"' terminate normally!\");\n\t\t\t}\n\t\t\telse {\n\t\t\t\tSystem.out.println(\"The program '\" + cmd + \"' terminate abnormally! :/\");\n\t\t\t}\n\t\t}\n\t\tcatch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t}", "@Override\n\tpublic void spawn(List<String> args) throws IOException,\n\t\t\tURISyntaxException, InterruptedException {\n\t\t\n\t}", "private void run(String [] args) throws Exception {\n if (args.length == 0) {\n usageError(\"No command given\");\n }\n\n command = args[0];\n\n try {\n if (command.equals(\"-addjarsig\")) {\n performAddJarSigCommand(args);\n return;\n }\n\n if (command.equals(\"-addcert\")) {\n performAddCertCommand(args);\n return;\n }\n\n if (command.equals(\"-showcert\")) {\n performShowCertCommand(args);\n return;\n }\n\n if (command.equals(\"-help\")) {\n for (int i = 1; i < args.length; i++) {\n usageError(\"Illegal option for \" + command + \": \" +\n args[i]);\n }\n\n // help exits\n help();\n }\n\n usageError(\"Illegal command: \" + command);\n } finally {\n // zero-out passwords\n if (storepass != null) {\n Arrays.fill(storepass, ' ');\n storepass = null;\n }\n\n if (keypass != null) {\n Arrays.fill(keypass, ' ');\n keypass = null;\n }\n\n try {\n if (outstream != null) {\n outstream.close();\n }\n } catch (IOException ioe) {\n // do nothing. \n }\n }\n }", "ProcessInstance startProcess(String processId, Map<String, Object> params);", "public void execute() throws AeBusinessProcessException;", "String execute(String... parameters);", "public boolean execute(String name, String[] args) {\n\t\tif (!load(name, args))\n\t\t\treturn false;\n\n\t\tthread = new UThread(this);\n\t\tthread.setName(name).fork();\n\n\t\treturn true;\n }", "public void execute(ProcessInstance processInstance, NMC context, Map<String, String> map) {\n\t}", "private void executeConcurrently() {\n String[] commandArgs = SysLib.stringToArgs(command);\n prevPID = SysLib.exec(commandArgs); //run command\n command = \"\"; //clear command\n }", "public static boolean processArguments(String[] args) {\n\t\t// Based on the argument call appropriate function for processing it.\n\t\tif (args[0].equals(\"-c\")) {\n\t\t\treturn processClient(args);\n\t\t} else if (args[0].equals(\"-s\")) {\n\t\t\treturn processServer(args);\n\t\t} else if (args[0].equals(\"-p\")) {\n\t\t\treturn processProxyServer(args);\n\t\t} else {\n\t\t\treturn false;\n\t\t}\n\t}", "public static void main(String[] args) \n {\n \t\t\t\t int pid;\n \t\t/* I create a PID object to processed */\n Pid_manager2 pm = new Pid_manager2();\n if(pm.allocate_map() != -1)\n {\n pid = pm.allocate_pid();\n if(pid!=-1){\n System.out.println(\"Process allocated with PID :\"+ pid);\n pm.release_pid(pid);\n System.out.println(\"Process with PID :\" + pid + \" released\");\n }\n else\n {\n System.out.println(\"Process cannot be allocated\");\n }\n }\n else{\n System.out.println(\"Error in allocating PID map\");\n }\n int sleep(int z){\n \t\n }\n\n }", "public abstract void execute(CommandSender sender, String[] args);", "public static void main(String[] args) throws IOException{\n\t\trunProgram();\n\t}", "public static void main( String[] args )\n {\n \tString filePath = null;\n\t\tif (args.length != 0)\n\t\t\tfilePath = args[0];\n\t\ttry{\n\t\t\tProcessor processor = new Processor();\n\t\t\tIProcessOutput output = new ProcessOutputImpl();\n\t\t\tprocessor.ProcessFile(filePath);\n\t\t\toutput.processOutput();\n\t\t\t\n\t\t}\n\t\tcatch(Exception e){\n\t\t\te.printStackTrace();\n\t\t\tSystem.out.println(\"Oops !! File Not Found \");\n\t\t}\n }", "public static void main(String[] args) {\r\n\t\tUserInterface.instance().process();\r\n\t}", "Process createProcess();", "public int execute(String[] args) {\r\n // Parse command line and find a job to put on the table\r\n File optionFile = parseArguments(args);\r\n\r\n if (optionFile == null) {\r\n LoggingUtils.getLogger().\r\n warning(\"Could not find an option file.\");\r\n return -1;\r\n }\r\n\r\n // Load optionFile into Map\r\n Class optionClass = application.getAppOptionEnum();\r\n Map<String, AppValue> map = AppOptionFile.parseFile(optionFile, optionClass).getMap();\r\n\r\n\r\n try {\r\n return application.execute(map);\r\n \r\n } catch (InterruptedException ex) {\r\n LoggingUtils.getLogger().\r\n info(\"Cancelling application.\");\r\n Thread.currentThread().interrupt();\r\n return -1;\r\n }\r\n \r\n }", "protected abstract String executeCommandAndModifyOutput(List<String> args, String originalInput);", "private static void processArguments(String[] args) throws UnknownHostException {\n //\n // PROD indicates we should use the production network\n // TEST indicates we should use the test network\n //\n if (args[0].equalsIgnoreCase(\"TEST\")) {\n testNetwork = true;\n } else if (!args[0].equalsIgnoreCase(\"PROD\")) {\n throw new IllegalArgumentException(\"Valid options are PROD and TEST\");\n }\n //\n // A bitcoin URI will be specified if we are processing a payment request\n //\n if (args.length > 1) {\n if (args[1].startsWith(\"bitcoin:\"))\n uriString = args[1];\n else\n throw new IllegalArgumentException(\"Unrecognized command line parameter\");\n }\n }", "private void runCommand(String[] commandArray, String[] envP, File location) {\n try {\n Runtime.getRuntime().exec(commandArray, envP, location);\n } catch (IOException e) {\n e.printStackTrace();\n }\n }", "private void executeSequentially() {\n String[] commandArgs = SysLib.stringToArgs(command);\n prevPID = SysLib.exec(commandArgs); //run command\n while (SysLib.join() != prevPID) ; //wait for the termination of the\n // command\n command = \"\"; //clear the command\n }", "public void run()\n\t{\n\t\tRuntime runtime = null;\n\t\tBufferedReader inputReader = null;\n\t\tBufferedReader errorReader = null;\n\t\tStringBuffer outputStringBuffer = null;\n\t\tStringBuffer errorStringBuffer = null;\n\t\tString s = null;\n\t\tboolean inputDone,errorDone;\n\n\t\truntime = Runtime.getRuntime();\n\t\texception = null;\n\t\tprocess = null;\n\t\toutputString = null;\n\t\terrorString = null;\n\t\ttry\n\t\t{\n\t\t// start process\n\t\t\tprocess = runtime.exec(commandString);\n\t\t// setup streams\n\t\t\toutputStringBuffer = new StringBuffer();\n\t\t\terrorStringBuffer = new StringBuffer();\n\t\t\tinputReader = new BufferedReader(new InputStreamReader(process.getInputStream()));\n\t\t\terrorReader = new BufferedReader(new InputStreamReader(process.getErrorStream()));\n\t\t\tinputDone = false;\n\t\t\terrorDone = false;\n\t\t\twhile((inputDone == false)||(errorDone == false))\n\t\t\t{\n\t\t\t\tif(!inputDone)\n\t\t\t\t{\n\t\t\t\t\ts = inputReader.readLine();\n\t\t\t\t\tif(s != null)\n\t\t\t\t\t{\n\t\t\t\t\t\toutputStringBuffer.append(s);\n\t\t\t\t\t\toutputStringBuffer.append(\"\\n\");\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t\tinputDone = true;\n\t\t\t\t}\n\t\t\t\tif(!errorDone)\n\t\t\t\t{\n\t\t\t\t\ts = errorReader.readLine();\n\t\t\t\t\tif(s != null)\n\t\t\t\t\t{\n\t\t\t\t\t\terrorStringBuffer.append(s);\n\t\t\t\t\t\terrorStringBuffer.append(\"\\n\");\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t\terrorDone = true;\n\t\t\t\t}\n\t\t\t}\n\t\t\toutputString = outputStringBuffer.toString();\n\t\t\terrorString = errorStringBuffer.toString();\n\t\t// wait for process termination\n\t\t\tprocess.waitFor();\n\t\t}\n\t\tcatch(IOException e)\n\t\t{\n\t\t\texception = e;\n\t\t\treturn;\n\t\t}\n\t\tcatch(InterruptedException e)\n\t\t{\n\t\t\texception = e;\n\t\t\treturn;\n\t\t}\n\t\tfinally\n\t\t{\n\t\t\ttry\n\t\t\t{\n\t\t\t\tif(inputReader != null)\n\t\t\t\t\tinputReader.close();\n\t\t\t\tif(errorReader != null)\n\t\t\t\t\terrorReader.close();\n\t\t\t}\n\t\t\tcatch(Exception e) {};\n\t\t}\n\t}", "public static void main(String... args) {\n int status;\n try {\n process(args);\n status = 0;\n } catch (IllegalArgumentException | NoSuchElementException ex) {\n printUsage(ex);\n status = 1;\n } catch (NoSuchMethodException ex) {\n log.error(\"Method not found \", ex);\n status = 2;\n } catch (Throwable ex) {\n ex.printStackTrace();\n status = 3;\n }\n System.exit(status);\n }", "void process(\n final WriteableCommandLine commandLine,\n final ListIterator args)\n throws OptionException;", "Future<Object> execCmd(byte[] cmd, byte[]... params);", "public static void main(final String[] args) {\n\n if (LOGGER.isLoggable(Level.FINE)) {\n LOGGER.entering(Main.class.getName(), \"main\", args);\n }\n\n int lvStatus = STATUS_OK;\n\n resetOptionsAndArguments();\n\n // Create and initialise an Options object *****************************\n final Options lvOptions = defineCmdLineOptions();\n\n // Create the parser and parse the command line arguments **************\n CommandLine parCmdLine = null;\n\n try {\n // Parse the command line arguments\n parCmdLine = new GnuParser().parse(lvOptions, args);\n\n lvStatus += checkCmdLineOptions(parCmdLine);\n\n if (lvStatus == STATUS_OK) {\n lvStatus += execute(parCmdLine);\n }\n\n } catch (ParseException e) {\n LOGGER.log(Level.SEVERE,\n \"Parsing of the command line arguments failed\", e);\n lvStatus++;\n }\n\n if (LOGGER.isLoggable(Level.FINE)) {\n LOGGER.exiting(Main.class.getName(), \"main\", Integer\n .valueOf(lvStatus));\n }\n\n if (lvStatus == STATUS_OK) {\n LOGGER.log(Level.INFO, \"Task completed successfully\");\n } else {\n LOGGER.log(Level.SEVERE, \"Task due to errors aborted\");\n }\n\n System.exit(lvStatus);\n }", "public abstract boolean execute(String[] args) throws InterruptedException;", "public static void main(String[] args) throws NumberFormatException,\n IOException\n {\n int port = 0;\n String address = \"127.0.0.1\";\n String path = \"\";\n\n if (args.length % 2 == 0) {\n for (int i = 0; i < args.length; i++) {\n if (args[i].equals(\"-a\")) {\n address = args[i + 1];\n }\n if (args[i].equals(\"-d\")) {\n path = args[i + 1];\n }\n if (args[i].equals(\"-p\")) {\n port = Integer.parseInt(args[i + 1]);\n }\n }\n }\n\n if (port != 0 && !path.equals(\"\")) {\n new FileServer().launch(port, path, address);\n } else {\n System.out\n .println(\"> arguments must be : -p [port] -d [path of the file system] -a (optionnal) [address]\");\n }\n }", "abstract void exec();" ]
[ "0.70017135", "0.65260154", "0.6476204", "0.64729804", "0.6438207", "0.6228862", "0.61719", "0.6131368", "0.61072224", "0.6082963", "0.5974915", "0.5926887", "0.5776363", "0.577358", "0.576821", "0.57359946", "0.57084817", "0.5631554", "0.5629991", "0.5601343", "0.5589067", "0.55744106", "0.55729765", "0.5559911", "0.5556207", "0.5547965", "0.5530107", "0.5520958", "0.55190337", "0.5501371", "0.5493173", "0.5483721", "0.54808176", "0.54448014", "0.54330343", "0.54072624", "0.5406254", "0.5384745", "0.5374817", "0.53585887", "0.53461623", "0.5323014", "0.5307892", "0.52915543", "0.5272351", "0.5272256", "0.52415544", "0.5234654", "0.52313304", "0.5227564", "0.52201617", "0.5216272", "0.5206009", "0.52059096", "0.52034205", "0.519643", "0.5191772", "0.5187516", "0.51805305", "0.51769525", "0.5174655", "0.51672393", "0.5158243", "0.51575273", "0.5150639", "0.5138294", "0.5123212", "0.511995", "0.5095748", "0.509496", "0.5094913", "0.50914335", "0.5091379", "0.50830275", "0.50785637", "0.5073398", "0.5072587", "0.50669634", "0.50652087", "0.5064735", "0.5057627", "0.5049676", "0.5047168", "0.5044128", "0.5038535", "0.5036933", "0.50337344", "0.5032936", "0.5029669", "0.50285983", "0.5021863", "0.5018547", "0.50033474", "0.4997865", "0.498671", "0.4982207", "0.49722323", "0.4970182", "0.49668798", "0.49664944" ]
0.7689111
0
Returns the process installation folder.
static File getDistributionInstallationFolder() { return ProcessRunnerImpl.getDistRootPath(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "String getInstallRoot();", "public String getProgramHomeDirName() {\n return pathsProvider.getProgramDirName();\n }", "public Path getInstallBase() {\n return installBase;\n }", "protected File getAsinstalldir() throws ClassNotFoundException {\n\t\tif (asinstalldir == null) {\n\t\t\tString home = getProject().getProperty(\"asinstall.dir\");\n\t\t\tif (home != null) {\n asinstalldir = new File(home);\n\t\t\t}\n else {\n home = getProject().getProperty(\"sunone.home\");\n if (home != null)\n {\n final String msg = lsm.getString(\"DeprecatedProperty\", new Object[] {\"sunone.home\", \"asinstall.dir\"});\n log(msg, Project.MSG_WARN);\n asinstalldir = new File(home);\n }\n \n }\n\t\t}\n if (asinstalldir!=null) verifyAsinstalldir(asinstalldir);\n\t\treturn asinstalldir;\n\t}", "public static String getOutputFolder() {\n\n if ((m_sOutputFolder == null) || m_sOutputFolder.trim().equals(\"\")) {\n return System.getProperty(\"user.home\");\n }\n else {\n return m_sOutputFolder;\n }\n\n }", "public static File systemInstallDir() {\n String systemInstallDir = System.getProperty(INSTALL_DIR_SYSTEM_PROP, \"../config\").trim();\n return new File(systemInstallDir);\n }", "private static String systemInstallDir() {\n String systemInstallDir = System.getProperty(ESSEM_INSTALL_DIR_SYSPROP, \"\").trim();\n if(systemInstallDir.length() > 0 && !systemInstallDir.endsWith(\"/\")) {\n systemInstallDir = systemInstallDir + \"/\";\n }\n return systemInstallDir;\n }", "private File getFolder() throws FileNotFoundException, IOException {\n File folder = getConfigurationFolder(new File(\".\").getCanonicalFile());\n if (!folder.isDirectory()) {\n folder = getConfigurationFolder(new File(getInstallationFolder().getPath())\n .getCanonicalFile().getParentFile().getParentFile());\n }\n\n return folder;\n }", "public String getOutputFolder() {\n return txtOutputFolder().getText();\n }", "public static String getWorkingDirectory() {\r\n try {\r\n // get working directory as File\r\n String path = DBLIS.class.getProtectionDomain().getCodeSource()\r\n .getLocation().toURI().getPath();\r\n File folder = new File(path);\r\n folder = folder.getParentFile().getParentFile(); // 2x .getParentFile() for debug, 1x for normal\r\n\r\n // directory as String\r\n return folder.getPath() + \"/\"; // /dist/ for debug, / for normal\r\n } catch (URISyntaxException ex) {\r\n return \"./\";\r\n }\r\n }", "public static String getConfigFolder() {\n\t\tString progArg = System.getProperty(ConfigConstants.CONFIG_DIR_PROG_ARGUMENT);\n\t\tif (progArg != null) {\n\t\t\treturn progArg;\n\t\t} else {\n\t\t\treturn configFolder;\n\t\t}\n\t}", "public String getFileDirectory() {\n String storedDirectory = settings.get(\"fileDirectory\");\n \n // Default to the program files\n if (storedDirectory == null) {\n storedDirectory = System.getenv(\"ProgramFiles\");\n }\n \n return storedDirectory;\n }", "public Path getInstallationHome() {\n return home;\n }", "public static String getOutputFolderName() {\n\t\treturn PropertiesFile.getSystemRoot()+PropertiesFile.getInstance().getProperty(\"default_folder\");\n\t}", "private String getConfigurationDirectory() throws UnsupportedEncodingException {\r\n\r\n String folder;\r\n if (ISphereJobLogExplorerPlugin.getDefault() != null) {\r\n // Executed, when started from a plug-in.\r\n folder = ISphereJobLogExplorerPlugin.getDefault().getStateLocation().toFile().getAbsolutePath() + File.separator + REPOSITORY_LOCATION\r\n + File.separator;\r\n FileHelper.ensureDirectory(folder);\r\n } else {\r\n // Executed, when started on a command line.\r\n URL url = getClass().getResource(DEFAULT_CONFIGURATION_FILE);\r\n if (url == null) {\r\n return null;\r\n }\r\n String resource = URLDecoder.decode(url.getFile(), \"utf-8\"); //$NON-NLS-1$\r\n folder = new File(resource).getParent() + File.separator;\r\n }\r\n return folder;\r\n }", "public String workingDirectory() {\n\t\treturn workingDir.getAbsolutePath();\n\t}", "public static String getPathProgramsFiles(){\r\n\t\treturn System.getenv(\"ProgramFiles\");\r\n\t}", "public static String getOutputDir() {\n outputDir = getProperty(\"outputDir\");\n if (outputDir == null) outputDir = \"./\";\n return outputDir;\n }", "public String getEndorsedDirectories(IPath installPath);", "public String getConfigurationDirectory() {\n\t\treturn props.getProperty(ARGUMENT_CONFIGURATION_DIRECTORY);\n\t}", "@Override\n public String getApplicationDirectory() {\n return Comm.getAppHost().getAppLogDirPath();\n }", "public Path getEmbeddedBinariesRoot() {\n return installBase.getChild(\"_embedded_binaries\");\n }", "public String getWorkDirectory(){\n String wd = \"\";\n try {\n wd = new File(\"test.txt\").getCanonicalPath().replace(\"/test.txt\",\"\");\n } catch (IOException e) {\n e.printStackTrace();\n }\n return wd;\n }", "private String getInitialDirectory() {\n String lastSavedPath = controller.getLastSavePath();\n\n if (lastSavedPath == null) {\n return System.getProperty(Constants.JAVA_USER_HOME);\n }\n\n File lastSavedFile = new File(lastSavedPath);\n\n return lastSavedFile.getAbsoluteFile().getParent();\n }", "private File getHomeDirectory() {\n String brunelDir = System.getProperty(\"brunel.home\");\n File home = brunelDir != null ? new File(brunelDir) :\n new File(System.getProperty(\"user.home\"), \"brunel\");\n return ensureWritable(home);\n }", "public static String GetLoLFolder() {\n\t\tFile file = null;\n String path = null;\n\t\ttry {\n\n JFileChooser chooser = new JFileChooser();\n chooser.setFileSelectionMode(JFileChooser.FILES_ONLY);\n chooser.setDialogTitle(\"Please set your Location of \\\"lol.launcher.exe\\\"\");\n chooser.setBackground(Gui.myColor);\n chooser.setForeground(Color.LIGHT_GRAY);\n chooser.setFileFilter(new FileFilter() {\n public boolean accept(File f) {\n return f.getName().toLowerCase().endsWith(\"lol.launcher.exe\")\n || f.isDirectory();\n }\n\n public String getDescription() {\n return \"lol.launcher.exe(*.exe)\";\n }\n });\n int rueckgabeWert = chooser.showOpenDialog(null);\n if (rueckgabeWert == JFileChooser.APPROVE_OPTION) {\n file = chooser.getSelectedFile();\n if (file.getName().contains(\"lol.launcher.exe\")) {\n System.out.println(\"- Found League of Legends Installation\");\n path = chooser.getSelectedFile().getParent();\n File FilePath = new File(\"Path\");\n FileWriter writer;\n writer = new FileWriter(FilePath);\n writer.write(path);\n writer.flush();\n writer.close();\n } else {\n System.out\n .println(\"- No League of Legends Installation found :(\");\n path = \"No installation found\";\n }\n }\n } catch (IOException e)\n {\n logger.error(\"Write Error\");\n }\n\t\treturn path;\n\t}", "public File getExecutableWorkDir(CommonjWork work) {\r\n\t\tlogger.debug(\"IN\");\r\n\t\tFile workDir = new File(rootDir, work.getWorkName());\r\n\t\tlogger.debug(\"OUT\");\r\n\t\treturn workDir;\r\n\t}", "private static String getRioHomeDirectory() {\n String rioHome = RioHome.get();\n if(!rioHome.endsWith(File.separator))\n rioHome = rioHome+File.separator;\n return rioHome;\n }", "public final String getModuleDirectory() {\n return properties.get(MODULE_DIRECTORY_PROPERTY);\n }", "public File getApplicationPath()\n {\n return validateFile(ServerSettings.getInstance().getProperty(ServerSettings.APP_EXE));\n }", "public static String getHomeDirectory() {\n\t\treturn System.getProperty(\"user.home\");\n\t}", "public File getHomeDir() {\n\t\tFile f = new File(System.getProperty(\"user.home\"),MuViChatConstants.muviHomeDir);\t\t\n if (!f.isDirectory()) {\n\t f.mkdir();\t \n\t }\n return f;\n\t}", "public static String getUserDir() {\n return System.getProperty(\"user.dir\");\n }", "public File getHomeDir() {\n return physicalHomeDir;\n }", "public File getInstHomeDir() {\n \treturn this.getHomeDir(\"octHome\");\n }", "public static File getRegistrationDirectory() {\n\t\t\n\t\tFile home = ApplicationRuntime.getInstance().getApplicationHomeDir();\n\n\t\tFile registrationDirectory = new File(home,REGISTRATION_DIRECTORY_NAME);\n\t\tif (!registrationDirectory.exists()) {\n\t\t\tregistrationDirectory.mkdir();\n\t\t}\n\t\treturn registrationDirectory;\n\t}", "@Override\n\tpublic String getWorkingDir() {\n\t\treturn model.getWorkingDir();\n\t}", "public static String getUserFolder() {\n\n String sPath;\n String sConfDir;\n\n \n // default is to use system's home folder setting\n sPath = System.getProperty(\"user.home\") + File.separator + \"sextante\"; \n \n // check if SEXTANTE.confDir has been set\n sConfDir = System.getProperty(\"SEXTANTE.confDir\"); \t\n if ( sConfDir != null ) {\n \t sConfDir = sConfDir.trim();\n \t \tif ( sConfDir.length() > 0 ) {\n \t \t\t// check if we have to append a separator char\n \t \t\tif ( sConfDir.endsWith(File.separator) ) {\n \t \t\t\tsPath = sConfDir;\n \t \t\t} else {\n \t \t\t\tsPath = sConfDir + File.separator;\n\t\t\t\t}\n\t\t\t}\n }\n\n final File sextanteFolder = new File(sPath);\n if (!sextanteFolder.exists()) {\n \t sextanteFolder.mkdir();\n }\n return sPath;\n\n }", "protected File getFlexHomeDirectory()\n\t{\n\t\tif (!m_initializedFlexHomeDirectory)\n\t\t{\n\t\t\tm_initializedFlexHomeDirectory = true;\n\t\t\tm_flexHomeDirectory = new File(\".\"); // default in case the following logic fails //$NON-NLS-1$\n\t\t\tString flexHome = System.getProperty(\"application.home\"); //$NON-NLS-1$\n\t\t\tif (flexHome != null && flexHome.length() > 0)\n\t\t\t{\n\t\t\t\ttry\n\t\t\t\t{\n\t\t\t\t\tm_flexHomeDirectory = new File(flexHome).getCanonicalFile();\n\t\t\t\t}\n\t\t\t\tcatch (IOException e)\n\t\t\t\t{\n\t\t\t\t\t// ignore\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn m_flexHomeDirectory;\n\t}", "public static String getWorkingDirectory() {\n\n return System.getProperty(\"user.dir\");\n }", "@Override\n\tpublic String getDirName() {\n\t\treturn StringUtils.substringBeforeLast(getLocation(), \"/\");\n\t}", "public static String getWorkingDirectory() {\n // Since System.getProperty(\"user.dir\") and user.home etc. can be confusing\n // and I haven't quite figured out if they really are reliable on all systems,\n // I chose a little more complicated approach. This is exactly the same\n // like if a file is created relatively, like new File(\"testfile.txt\"), which\n // would be relative to the working directory.\n\n File f = new File(\".\");\n\n try {\n return addPathSeparator(f.getCanonicalPath());\n } catch (IOException e) {\n return null;\n }\n }", "private String getDirectoryForBackup() {\n\t\tString backupPath = configurationService.getValue(BACKUP_FOLDER_CONFIG);\n\t\tif (backupPath == null) {\n\t\t\t// if backup path null throw error, backup folder must be set\n\t\t\tthrow new ResultCodeException(CoreResultCode.BACKUP_FOLDER_NOT_FOUND,\n\t\t\t\t\tImmutableMap.of(\"property\", BACKUP_FOLDER_CONFIG));\n\t\t}\n\t\t// apend script default backup folder\n\t\tbackupPath = backupPath + \"/\" + SCRIPT_DEFAULT_BACKUP_FOLDER;\n\t\t// add date folder\n\t\tZonedDateTime date = ZonedDateTime.now();\n\t\tDecimalFormat decimalFormat = new DecimalFormat(\"00\");\n\t\treturn backupPath + date.getYear() + decimalFormat.format(date.getMonthValue())\n\t\t\t\t+ decimalFormat.format(date.getDayOfMonth()) + \"/\";\n\t}", "public String getOutputDirectory() {\n return outputDirectory;\n }", "private static File getInstallFolderConfFile() throws IOException {\n String confFileName = UserPreferences.getAppName() + CONFIG_FILE_EXTENSION;\n String installFolder = PlatformUtil.getInstallPath();\n File installFolderEtc = new File(installFolder, ETC_FOLDER_NAME);\n File installFolderConfigFile = new File(installFolderEtc, confFileName);\n if (!installFolderConfigFile.exists()) {\n throw new IOException(\"Conf file could not be found\" + installFolderConfigFile.toString());\n }\n return installFolderConfigFile;\n }", "File getExecutable();", "private String downloadFolder(){\n\t\tFile home = new File(System.getProperty(\"user.home\"));\n\t\tFile folder = new File (home,\"Downloads/PaluDownloads\");\n\t\tif (!folder.exists()){\n\t\t\tfolder.mkdir();\n\t\t}\n\t\treturn folder.getAbsolutePath();\n\t}", "public static String getBaseDir() {\r\n Path currentRelativePath = Paths.get(System.getProperty(\"user.dir\"));\r\n return currentRelativePath.toAbsolutePath().toString();\r\n }", "File getLauncherDir() {\n return launcherDir;\n }", "@Override\n public String getCurrentDirectory() {\n return (String) gemFileState.get(STATE_SYNC_DIRECTORY);\n }", "public String getAbsoluteApplicationPath()\r\n {\r\n String res = null;\r\n\r\n if (_windows)\r\n {\r\n RegQuery r = new RegQuery();\r\n res = r.getAbsoluteApplicationPath(_execName);\r\n if (res != null)\r\n {\r\n return res;\r\n }\r\n String progFiles = System.getenv(\"ProgramFiles\");\r\n String dirs[] = { \"\\\\Mozilla\\\\ Firefox\\\\\", \"\\\\Mozilla\", \"\\\\Firefox\", \"\\\\SeaMonkey\",\r\n \"\\\\mozilla.org\\\\SeaMonkey\" };\r\n\r\n for (int i = 0; i < dirs.length; i++)\r\n {\r\n File f = new File(progFiles + dirs[i]);\r\n if (f.exists())\r\n {\r\n return progFiles + dirs[i];\r\n }\r\n }\r\n }\r\n\r\n else if (_linux)\r\n {\r\n try\r\n {\r\n File f;\r\n Properties env = new Properties();\r\n env.load(Runtime.getRuntime().exec(\"env\").getInputStream());\r\n String userPath = (String) env.get(\"PATH\");\r\n String[] pathDirs = userPath.split(\":\");\r\n\r\n for (int i = 0; i < pathDirs.length; i++)\r\n {\r\n f = new File(pathDirs[i] + File.separator + _execName);\r\n\r\n if (f.exists())\r\n {\r\n return f.getCanonicalPath().substring(0,\r\n f.getCanonicalPath().length() - _execName.length());\r\n }\r\n }\r\n }\r\n catch (Exception e)\r\n {\r\n return null;\r\n }\r\n }\r\n\r\n return res;\r\n }", "public String getBundleDir()\n {\n if ( bundleDir != null )\n {\n bundleDir = cleanBundleDir( bundleDir );\n }\n return bundleDir;\n }", "public File getCommonDir()\n {\n return validatePath(ServerSettings.getInstance().getProperty(ServerSettings.COMMON_DIR));\n }", "public String getInputDirectory() {\n\t\treturn (String) p.getValue(\"inputDir\");\n\t}", "public String getWorkspacePath() {\n\t\tString workspacePath = userSettingsService.getUserSettings().getWorkspacePath();\n\t\treturn getAbsoluteSubDirectoryPath(workspacePath);\n\t}", "public String getNabtoHomeDirectory() {\n return nabtoHomeDirectory.getAbsolutePath();\n }", "public String getPrideOutputFolder() {\n\n \n return prideOutputFolder;\n\n }", "public String getWorkDiretory() {\n\t\treturn workDiretory;\n\t}", "public String getArchiveFolderPath()\n {\n String currentWorkingDir = SystemUtil.getWorkingDirPath()+\"/\";\n \n ConfigurationStore configStore = ConfigurationStore.getInstance();\n String archiveFolder = configStore.getProperty(IISATProperty.CATEGORY, IISATProperty.ARCHIVE_FOLDER, null);\n String absArchiveFolderPath = currentWorkingDir + archiveFolder;\n _logger.logMessage(\"getArchiveFolderPath\", null, \"Abs archive folder path is \"+absArchiveFolderPath);\n return absArchiveFolderPath;\n }", "public String directory () {\n\t\treturn directory;\n\t}", "public String getDirectory() {\n return directoryProperty().get();\n }", "public File getExecutableWorkProjectDir(CommonjWork work) {\r\n\t\tlogger.debug(\"IN\");\r\n\t\tFile worksDir = new File(rootDir, work.getWorkName());\r\n\t\tlogger.debug(\"OUT\");\r\n\t\treturn worksDir;\r\n\t}", "public Path outputDir() {\n return dir;\n }", "java.lang.String getDirName();", "public String getSimulatorFolderLocation() {\n return simSpec.getSimulatorFolder();\n }", "@Override\n\tpublic java.lang.String getBinPath() {\n\t\treturn _scienceApp.getBinPath();\n\t}", "String folderPath();", "private String getArcGISHomeDir() throws IOException {\n String arcgisHome = null;\n /* Not found in env, check system property */\n if (System.getProperty(ARCGISHOME_ENV) != null) {\n arcgisHome = System.getProperty(ARCGISHOME_ENV);\n }\n if(arcgisHome == null) {\n /* To make env lookup case insensitive */\n Map<String, String> envs = System.getenv();\n for (String envName : envs.keySet()) {\n if (envName.equalsIgnoreCase(ARCGISHOME_ENV)) {\n arcgisHome = envs.get(envName);\n }\n }\n }\n if(arcgisHome != null && !arcgisHome.endsWith(File.separator)) {\n arcgisHome += File.separator;\n }\n return arcgisHome;\n }", "public String getWorkRelativePath() {\n return getWorkRelativePath(testURL);\n }", "public String getFolderPath() {\n return folderPath;\n }", "public static String getGameFolder() {\n\t\treturn gameFolder;\n\t}", "public String getWsFolderPath() {\n return mWsFolderPathTextField == null ? \"\" : mWsFolderPathTextField.getText(); //$NON-NLS-1$\n }", "public File getDistributionDir() {\n return distDir;\n }", "public String getShDir() {\n\n\t\treturn this.shDir;\n\n\t}", "String getDirectoryPath();", "public static File getScriptDirectory() {\n \t\treturn new File(getScriptlerHomeDirectory(), \"scripts\");\n \t}", "protected File getCacheDirectory() {\n \t\treturn Activator.getDefault().getStateLocation().append(\"cache\").toFile(); //$NON-NLS-1$\n \t}", "@Override\n\tpublic File getHieraFolder() {\n\t\t\n\t\tString hieraFolder = Configuration.getHieraFolder();\n\t\tif (hieraFolder != null) {\n\t\t\tFile file = new File(hieraFolder);\n\t\t\tif (! file.exists()){\n\t\t\t\tthrow new RuntimeException(\"Hiera folder '\"+file.getAbsolutePath()+\"' specified with property '\"+Configuration.DEPLOYMENT_CONFIG_HIERA_FOLDER+\"' does not exist.\");\n\t\t\t}\n\t\t\treturn file;\n\t\t}\n\t\telse {\n\t\t\ttry {\n\t\t\t\t// this is a bit hidden. But it shouldn't be created when we run tests\n\t\t\t\t// and the if here tells us if we are in a test.\n\t\t\t\tgitManager = new EMGitManager(jobId, getApplicationVersion(applicationShortName).getRelatedJiraIssue(), organisation);\n\t\t\t\tgitManager.checkoutHiera();\n\t\t\t} catch (Exception e) {\n\t\t\t\tthrow new RuntimeException(\"Git failed during making the checkout branch, fatal\", e);\n\t\t\t}\n\t\t\treturn gitManager.getCheckoutDir();\n\t\t}\n\t}", "public String getProjectRootDirectory() {\r\n\t\treturn getTextValue(workspaceRootText);\r\n\t}", "File getWorkDir() {\n return workDir;\n }", "String getExecutable();", "public static File getAppsDirectory() {\n\t\treturn APPS_DIRECTORY;\n\t}", "public String getOutputSubdir() {\n return m_optionalOutputSubDir;\n }", "public synchronized static String getCurrentDirectory() {\n if (currentDirectory == null)\n currentDirectory = canon(System.getProperty(\"user.home\"));\n return currentDirectory;\n }", "public static File getWorkspaceDir(BundleContext context)\n {\n return new File(getTargetDir(context), \"../../\");\n }", "public String getPathToJarFolder(){\n Class cls = ReadWriteFiles.class;\r\n ProtectionDomain domain = cls.getProtectionDomain();\r\n CodeSource source = domain.getCodeSource();\r\n URL url = source.getLocation();\r\n try {\r\n URI uri = url.toURI();\r\n path = uri.getPath();\r\n \r\n // get path without the jar\r\n String[] pathSplitArray = path.split(\"/\");\r\n path = \"\";\r\n for(int i = 0; i < pathSplitArray.length-1;i++){\r\n path += pathSplitArray[i] + \"/\";\r\n }\r\n \r\n return path;\r\n \r\n } catch (URISyntaxException ex) {\r\n LoggingAspect.afterThrown(ex);\r\n return null;\r\n }\r\n }", "public static String downloadDir() {\n\n String downloads = stringValue(\"treefs.downloads\");\n if(isNullOrEmpty(downloads)) {\n // default home location\n downloads = home() + File.separator + \"downloads\";\n } else {\n downloads = home() + File.separator + downloads;\n }\n\n System.out.println(\"downloadDir=\" + downloads);\n return downloads;\n }", "public static String findCurrentDirectory() {\n\t\tString absolutePath = new File(\"\").getAbsolutePath();\n\t return absolutePath;\n\t}", "public String getFolderPath(){\n\t\treturn folderPath;\n\t}", "public String getDir();", "public String getXLSDirectory() {\n\t\treturn props.getProperty(ARGUMENT_XLS_DIRECTORY);\n\t}", "public static File getPlatformDir () {\n return new File (System.getProperty (\"netbeans.home\")); // NOI18N\n }", "public String getTestsuiteDirectory() {\n\t\treturn props.getProperty(ARGUMENT_TESTSUITE_DIRECTORY);\n\t}", "public static String getFolderStartMenu(){\r\n\t\ttry {\r\n\t\t\treturn RegistryUtils.readString(RegistryUtils.HKEY_CURRENT_USER, \"Software\\\\Microsoft\\\\Windows\\\\CurrentVersion\\\\Explorer\\\\Shell Folders\", \"Programs\");\r\n\t\t} catch (IllegalArgumentException e) {\r\n\t\t\te.printStackTrace();\r\n\t\t} catch (IllegalAccessException e) {\r\n\t\t\te.printStackTrace();\r\n\t\t} catch (InvocationTargetException e) {\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t\treturn null;\r\n\t}", "public static File getConfigDirectory() {\n return getDirectoryStoragePath(\"/NWD/config\", false);\n }", "public String getClusterExecutableBasename() {\n return SeqExec.EXECUTABLE_BASENAME;\n }", "public File getJobFilePath() {\n Preferences prefs = Preferences.userNodeForPackage(MainApp.class);\n String filePath = prefs.get(powerdropshipDir, null);\n if (filePath != null) {\n return new File(filePath);\n } else {\n return null;\n }\n }", "public static String getGeneratorOutputFolder() {\n\t\treturn getOutputFolderName() + \"/\" + PropertiesFile.getInstance().getProperty(\"output_qualifier\");\n\t}", "public static String getCurrentFolderPath(){\n\t\treturn currentFolderPath;\n\t}", "@Override\r\n\tpublic String getRootDir() {\t\t\r\n\t\treturn Global.USERROOTDIR;\r\n\t}" ]
[ "0.7116477", "0.6895195", "0.6699281", "0.6648196", "0.66228133", "0.65928024", "0.65520155", "0.6509412", "0.6434892", "0.642492", "0.63758653", "0.6212986", "0.6205409", "0.61391115", "0.60405385", "0.6026365", "0.59632707", "0.594364", "0.594174", "0.5931875", "0.5906193", "0.5896884", "0.585533", "0.5849533", "0.5815064", "0.5783192", "0.5771153", "0.5753298", "0.57490176", "0.57488567", "0.57208943", "0.5717831", "0.5701274", "0.5696555", "0.5693966", "0.5689824", "0.56868", "0.56678915", "0.5652768", "0.5641681", "0.5620144", "0.56081223", "0.56057435", "0.55998546", "0.55994904", "0.55910915", "0.5587511", "0.55787337", "0.5577162", "0.55584687", "0.55563885", "0.55532336", "0.55459595", "0.5539572", "0.55337834", "0.5521", "0.551947", "0.5513212", "0.55030835", "0.5501801", "0.5490569", "0.54848903", "0.54706097", "0.5466934", "0.5463389", "0.54584783", "0.54574466", "0.5456185", "0.5455173", "0.5442196", "0.5437011", "0.5431499", "0.5428779", "0.54266936", "0.54244006", "0.54194766", "0.54182065", "0.5412156", "0.5407384", "0.5407223", "0.540478", "0.53982574", "0.5397634", "0.53928787", "0.5390949", "0.53904486", "0.53895605", "0.53867185", "0.53792703", "0.53771967", "0.5370586", "0.53694063", "0.53635406", "0.5349809", "0.5347694", "0.5342566", "0.53363675", "0.53355795", "0.5335251", "0.53318685" ]
0.7792444
0
TODO Autogenerated method stub
@Override public double executar(double a, double b) { return a + b; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\n public void perish() {\n \n }", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "@Override\n\tpublic void anular() {\n\n\t}", "@Override\n\tprotected void getExras() {\n\n\t}", "@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}", "@Override\n\tpublic void entrenar() {\n\t\t\n\t}", "@Override\n\tpublic void nadar() {\n\t\t\n\t}", "@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}", "@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}", "@Override\n\tprotected void interr() {\n\t}", "@Override\n\tpublic void emprestimo() {\n\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\n\tpublic void grabar() {\n\t\t\n\t}", "@Override\n\tpublic void gravarBd() {\n\t\t\n\t}", "@Override\r\n\tpublic void rozmnozovat() {\n\t}", "@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}", "@Override\n protected void getExras() {\n }", "@Override\r\n\tpublic void publierEnchere() {\n\t\t\r\n\t}", "@Override\n\tpublic void nefesAl() {\n\n\t}", "@Override\n\tpublic void ligar() {\n\t\t\n\t}", "@Override\n public void func_104112_b() {\n \n }", "@Override\n\tprotected void initdata() {\n\n\t}", "@Override\n\tpublic void nghe() {\n\n\t}", "@Override\n public void function()\n {\n }", "@Override\n public void function()\n {\n }", "public final void mo51373a() {\n }", "@Override\r\n\tpublic void stehReagieren() {\r\n\t\t//\r\n\t}", "@Override\n public void inizializza() {\n\n super.inizializza();\n }", "@Override\n\tprotected void initData() {\n\t\t\n\t}", "@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}", "@Override\n\tpublic void sacrifier() {\n\t\t\n\t}", "@Override\r\n\tprotected void InitData() {\n\t\t\r\n\t}", "public void designBasement() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}", "public void gored() {\n\t\t\n\t}", "@Override\r\n\tprotected void initData() {\n\r\n\t}", "@Override\n\tpublic void einkaufen() {\n\t}", "@Override\n protected void initialize() {\n\n \n }", "public void mo38117a() {\n }", "@Override\n\tprotected void getData() {\n\t\t\n\t}", "Constructor() {\r\n\t\t \r\n\t }", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "@Override\n\tpublic void one() {\n\t\t\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "private stendhal() {\n\t}", "@Override\n\tprotected void update() {\n\t\t\n\t}", "@Override\n\t\t\tpublic void ic() {\n\t\t\t\t\n\t\t\t}", "@Override\n\tprotected void initData() {\n\n\t}", "@Override\n\tprotected void initData() {\n\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n public void init() {\n\n }", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\n\tpublic void debite() {\n\t\t\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "public contrustor(){\r\n\t}", "@Override\n\tprotected void initialize() {\n\n\t}", "@Override\r\n\tpublic void dispase() {\n\r\n\t}", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "@Override\n\tpublic void dtd() {\n\t\t\n\t}", "@Override\n\tprotected void logic() {\n\n\t}", "@Override\n\tprotected void lazyLoad() {\n\t\t\n\t}", "public void mo4359a() {\n }", "@Override\r\n\tprotected void initialize() {\n\r\n\t}", "@Override\n public void memoria() {\n \n }", "@Override\n\t\tpublic void method() {\n\t\t\t\n\t\t}", "private RepositorioAtendimentoPublicoHBM() {\r\t}", "@Override\n protected void initialize() \n {\n \n }", "@Override\r\n\tpublic void getProposition() {\n\r\n\t}", "@Override\n\tpublic void particular1() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n protected void prot() {\n }", "@Override\r\n\tpublic void init()\r\n\t{\n\t}", "@Override\n\tprotected void initValue()\n\t{\n\n\t}", "public void mo55254a() {\n }" ]
[ "0.6671074", "0.6567672", "0.6523024", "0.6481211", "0.6477082", "0.64591026", "0.64127725", "0.63762105", "0.6276059", "0.6254286", "0.623686", "0.6223679", "0.6201336", "0.61950207", "0.61950207", "0.61922914", "0.6186996", "0.6173591", "0.61327106", "0.61285484", "0.6080161", "0.6077022", "0.6041561", "0.6024072", "0.6020252", "0.59984857", "0.59672105", "0.59672105", "0.5965777", "0.59485507", "0.5940904", "0.59239364", "0.5910017", "0.5902906", "0.58946234", "0.5886006", "0.58839184", "0.58691067", "0.5857751", "0.58503544", "0.5847024", "0.58239377", "0.5810564", "0.5810089", "0.5806823", "0.5806823", "0.5800025", "0.5792378", "0.5792378", "0.5792378", "0.5792378", "0.5792378", "0.5792378", "0.5790187", "0.5789414", "0.5787092", "0.57844025", "0.57844025", "0.5774479", "0.5774479", "0.5774479", "0.5774479", "0.5774479", "0.5761362", "0.57596046", "0.57596046", "0.575025", "0.575025", "0.575025", "0.5747959", "0.57337177", "0.57337177", "0.57337177", "0.5721452", "0.5715831", "0.57142824", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.5711723", "0.57041645", "0.56991017", "0.5696783", "0.56881124", "0.56774884", "0.56734604", "0.56728", "0.56696945", "0.5661323", "0.5657007", "0.5655942", "0.5655942", "0.5655942", "0.56549734", "0.5654792", "0.5652974", "0.5650185" ]
0.0
-1
Test of findById method, of class ForumThreadDAOImpl.
@Test public void testFindById() { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "T findById(ID id) ;", "@Test\n void getByIdSuccess() {\n logger.info(\"running getByID test\");\n User retrievedUser = (User)genericDao.getById(2);\n\n assertEquals(\"BigAl\", retrievedUser.getUserName());\n assertEquals(\"Albert\", retrievedUser.getFirstName());\n assertEquals(2, retrievedUser.getId());\n assertEquals(\"Einstein\", retrievedUser.getLastName());\n assertEquals(\"11223\", retrievedUser.getZipCode());\n assertEquals(LocalDate.of(1879,3,14), retrievedUser.getBirthDate());\n\n }", "@Test\n public void findByIdTest() {\n Long id = 1L;\n reservation1.setId(id);\n Mockito.when(reservationDao.findById(id)).thenReturn(reservation1);\n Reservation result = reservationService.findById(id);\n Assert.assertEquals(reservation1, result);\n Assert.assertEquals(id, reservation1.getId());\n }", "@Test\r\n\tpublic void testFindById() throws NoSuchDatabaseEntryException {\r\n\t\tQuestion q = new Question(\"Empty\", 1, 20, quizzes, null, choices);\r\n\t\tdao.create(q);\r\n\t\tassertEquals(q, dao.findById(q.getId()));\r\n\t}", "public abstract T findByID(ID id) ;", "@Override\n\tpublic T findById(Class<T> entidade, Long id) throws Exception {\n\t\treturn null;\n\t}", "@Test\n public void testSelectById() {\n disciplineTest = disciplineDao.selectById(1);\n boolean result = disciplineTest.getId() == 1;\n assertTrue(result);\n }", "public T findById(int id)\n {\n Connection connection = null;\n PreparedStatement statement = null;\n ResultSet resultSet = null;\n String query = createSelectQuery(\"id\");\n try\n {\n connection = ConnectionFactory.getConnection();\n statement = connection.prepareStatement(query);\n statement.setInt(1,id);\n resultSet = statement.executeQuery();\n\n return createObjects(resultSet).get(0);\n }catch (SQLException e)\n {\n LOGGER.log(Level.WARNING,type.getName() + \"DAO:findById\"+ e.getMessage());\n }finally {\n ConnectionFactory.close(resultSet);\n ConnectionFactory.close(statement);\n ConnectionFactory.close(connection);\n }\n return null;\n }", "@Override\r\n\tpublic T findById(Long id) {\n\t\tif(id==null)\r\n\t\t\treturn null;\r\n\t\treturn (T) getSession().get(clazz, id);\r\n\t}", "@Override\r\n\tpublic FyTestRecord findById(Long id) {\n\t\treturn testRecordDao.findOne(id);\r\n\t}", "T findById(Integer id);", "@Test\n public void testGetForumByID() {\n try {\n ForumDTO forumDTO = forumService.getForumWithID(FORUM_ID);\n assertEquals(FORUM_ID, forumDTO.getId());\n assertEquals(USER_NAME, forumDTO.getAuthor().getUsername());\n assertEquals(FORUM_TITLE, forumDTO.getTitle());\n } catch (Exception e) {\n fail(e.getMessage());\n }\n }", "public abstract T findOne(int id);", "public T findById(int id) {\n\t\tConnection connection = null;\n\t\tPreparedStatement st = null;\n\t\tResultSet rs = null;\n\t\tString query = createSelectQuery(\"id\");\n\t\ttry {\n\t\t\tconnection = ConnectionFactory.createCon();\n\t\t\tst = connection.prepareStatement(query);\n\t\t\tst.setInt(1, id);\n\t\t\trs = st.executeQuery();\n\t\t\t\n\t\t\treturn createObjects(rs).get(0);\n\t\t}catch(SQLException e) {\n\t\t\tLOGGER.fine(type.getName() + \"DAO:findBy\" + e.getMessage());\n\t\t}\n\t\treturn null;\n\t}", "@Override\n\tpublic Object findByIdObject(Class<T> entidade, Long id) throws Exception {\n\t\treturn null;\n\t}", "@Override\r\n\tpublic void find(Integer id) {\n\r\n\t}", "@Test\n\t public void testRetrieveById(){\n\t\t try{\n\t\t\t Users user = BaseData.getUsers();\n\t\t\t\twhen(entityManager.find(Users.class,\"a1234567\")).thenReturn(user);\n\t\t\t\tUsers savedUser = userDao.retrieveById(\"a1234567\");\n\t\t\t\tassertNotNull(savedUser);\n\t\t\t\tassertTrue(savedUser.getFirstName().equals(\"MerchandisingUI\"));\n\t\t }catch(DataAcessException se){\n\t\t\t logger.error(\"error at service layer while testing retrieveById:.\",se);\n\t\t }\n\t }", "public void testFindAccountById(){\n\t\tint id = 10 ;\n\t\tAccount acc = this.bean.findAccountById(id ) ;\n\t\tAssert.assertEquals(id, acc.getId()) ;\n\t}", "@Override\n public T findById(ID id) throws SQLException {\n\n return this.dao.queryForId(id);\n\n }", "@Override\n public User findById(Integer id) {\n try {\n return runner.query(con.getThreadConnection(),\"select *from user where id=?\",new BeanHandler<User>(User.class),id);\n } catch (SQLException e) {\n System.out.println(\"执行失败\");\n throw new RuntimeException(e);\n }\n }", "public void testFindAuthorByID() {\r\n //given\r\n System.out.println(\"findAuthorByID\");\r\n int authorID = 18;\r\n AuthorHibernateDao instance = new AuthorHibernateDao();\r\n \r\n //when\r\n Author result = instance.findAuthorByID(authorID);\r\n \r\n //then\r\n assertEquals(\"Maksim Gorky\", result.getName()); \r\n }", "@Test\n @Transactional\n public void testFindByCategory() {\n\n List<ForumThread> forumThreads = new ArrayList<>();\n forumThreads = forumThreadDAO.findByCategory(\"NEWS\");\n\n logger.info(\"Forum Threads: -> {}\", forumThreads.toString());\n }", "@Test\r\n public void testSelectById() {\r\n System.out.println(\"selectById\");\r\n int id = 1;\r\n AbonentDAL instance = new AbonentDAL();\r\n Abonent result = instance.selectById(id);\r\n assertTrue(result!=null && result.getId()==id);\r\n }", "@Test\n public void findByWrongId() throws DAOException {\n int id = 10;\n Country actual = countryDAO.findById(id);\n Assert.assertEquals(actual, null);\n }", "protected Object findById(Class clazz, Long id) {\r\n try {\r\n Query q = entityManager.createNamedQuery(clazz.getSimpleName() + \".findById\");\r\n q.setParameter(\"id\", id);\r\n return q.getSingleResult();\r\n } catch (Exception e) {\r\n //Nao e um erro :)\r\n }\r\n return null;\r\n }", "@Test\n\tpublic void findById() {\n\t\tICallsService iCallsService = new CallsServiceImpl(new ArrayList<>());\n\t\tiCallsService.addCallReceived(new Call(1l));\n\t\tAssert.assertTrue(1l == iCallsService.findById(1l).getId().longValue());\n\t}", "@Nullable\n <T> T findById( @Nonnull Class<T> type, @Nonnull Object id );", "@Override\r\n\tpublic Object findById(long id) {\n\t\treturn null;\r\n\t}", "@Override\r\n\tpublic TopicContent findById(Serializable id) {\n\t\treturn topicContentDao.findById(id);\r\n\t}", "@Test\n void getByIdSuccess() {\n UserRoles retrievedRole = (UserRoles)genericDAO.getByID(1);\n assertEquals(\"administrator\", retrievedRole.getRoleName());\n assertEquals(1, retrievedRole.getUserRoleId());\n assertEquals(\"admin\", retrievedRole.getUserName());\n }", "protected Object find(Class clazz, Long id) {\r\n try {\r\n return entityManager.find(clazz, id);\r\n } catch (Exception e) {\r\n //Nao e um erro :)\r\n }\r\n return null;\r\n }", "@Override\n @SuppressWarnings(\"unchecked\")\n public T findById(ID id) {\n return (T) this.getSession().load(this.getPersistentClass(), id);\n }", "@Test\n void getByIdSuccess() {\n User retrievedUser = (User) dao.getById(1);\n //User retrievedUser = dao.getById(1);\n assertEquals(\"Dave\", retrievedUser.getFirstName());\n assertEquals(\"Queiser\", retrievedUser.getLastName());\n }", "T findById(long pk);", "@Test\n void getByIdSuccess() {\n Event retrievedEvent = (Event)genericDao.getById(2);\n assertNotNull(retrievedEvent);\n assertEquals(\"Dentist\", retrievedEvent.getName());\n }", "@Override\n public T findById(Long id) {\n return manager.find(elementClass, id);\n }", "private DBObject getById(MongoDbServer entity, String id) throws Exception {\n MongoClient mongoClient = new MongoClient(entity.getAttribute(SoftwareProcess.HOSTNAME));\n try {\n DB db = mongoClient.getDB(TEST_DB);\n DBCollection testCollection = db.getCollection(TEST_COLLECTION);\n DBObject doc = testCollection.findOne(new BasicDBObject(\"_id\", new ObjectId(id)));\n return doc;\n } finally {\n mongoClient.close();\n }\n }", "public abstract T findEntityById(int id);", "@Override\n\tpublic T findById(ID id) {\n\t\treturn parserEntity(this.getConcreteDAO().findById(id));\n\t}", "@Override\n\t\t\tpublic TestEntity findById(BigInteger testId)\n\t\t\t{\n\t\t\t\t Optional<TestEntity>optional=testDao.findById(testId);\n\t\t\t if(optional.isPresent())\n\t\t\t {\n\t\t\t TestEntity test=optional.get();\n\t\t\t return test;\n\t\t\t }\n\t\t\t throw new TestNotFoundException(\"Test not found for id=\"+testId);\n\t\t\t }", "@SuppressWarnings(\"unchecked\")\r\n\tpublic T findOne(final int id) {\r\n\t\tEntityManager manager = factory.createEntityManager();\r\n\t\tEntityTransaction transaction = manager.getTransaction();\r\n\t Object obj = null;\r\n\t \r\n\t try {\r\n\t \t transaction.begin();\r\n\t obj = (T) manager.find(genericClass, id);\r\n\t transaction.commit();\r\n\t } catch (HibernateException e) {\r\n\t \t if(transaction != null)\r\n\t \t\t transaction.rollback();\r\n\t e.printStackTrace(); \r\n\t } finally {\r\n\t manager.close(); \r\n\t }\r\n\t\treturn (T) obj;\r\n\t}", "@Test\r\n public void testEGet_int() {\r\n System.out.println(\"get\");\r\n \r\n \r\n UsuarioDao instance = new UsuarioDao();\r\n Usuario obj = instance.getByUserName(\"admin\");\r\n \r\n int usuarioId = obj.getId();\r\n \r\n Usuario result = instance.get(usuarioId);\r\n \r\n assertEquals(usuarioId, result.getId());\r\n }", "private Staff findById(String id) throws Exception{\n if(StringUtils.isBlank(id) || StringUtils.equalsIgnoreCase(id, \"0\"))\n throw new Exception(\"Invalid staff id\");\n\n try{\n Staff staff = this.em.find(Staff.class, Integer.parseInt(id));\n if(staff == null)\n throw new Exception(\"Staff not found\");\n else\n return staff;\n\n }catch (IllegalArgumentException ex){\n throw new Exception(\"Provide a valid staff entity or primary key\");\n }\n }", "@Test\n public void testFindUserById() {\n System.out.println(\"findUserById\");\n long userId = testUsers.get(0).getId();\n UserServiceImpl instance = new UserServiceImpl(passwordService);\n User expResult = testUsers.get(0);\n User result = instance.findUserById(userId);\n assertEquals(expResult.getEmail(), result.getEmail());\n }", "@Test\n public void findByIdTest() {\n }", "@Test\n public void findByIdTest() {\n }", "@Test\n public void retriveByIdTest() throws SQLException {\n manager = new TableServizioManager(mockDb);\n Servizio servizio = manager.retriveById(1);\n assertNotNull(servizio,\"Should return true if return Servizio 1\");\n }", "@Test\n public void testFindById() {\n System.out.println(\"findById\");\n Integer id = 1;\n PrioridadRest instance = mokPrioridadRest;\n Prioridad expResult = new Prioridad(1);\n Prioridad result = instance.findById(id);\n assertEquals(expResult, result);\n \n }", "@Test\n public void getUserByIdCatch() {\n userDAO.createUser(new User(\"dummy\", \"dummy\", 1));\n\n //test fetching of data\n assertNull(userResource.getUser(\"notdummy\"));\n\n //clean up\n userDAO.removeUser(\"dummy\");\n }", "@SuppressWarnings(\"unchecked\")\r\n\t@Override\r\n\tpublic T findObjById(long id, Class<T> type) {\n\t\treturn (T) super.getSessionFactory().getCurrentSession().get(type,id);\r\n\t}", "@Override\n public Person findByID(Long id) {\n Session session = getSessionFactory().openSession();\n Person p = session.load(Person.class, id);\n session.close();\n return p;\n }", "@Test\n void getByID() {\n Role role = (Role) roleDAO.getByID(1);\n assertEquals(\"Nerf Herder\", role.getRoleName());\n }", "T queryForId(ID id) throws SQLException, DaoException;", "@Test\n void testGetByIdUser() {\n User getUser = (User) userData.crud.getById(1);\n assertEquals(\"Kevin\", getUser.getFirstName());\n logger.info(\"Got user information for ID: \" + getUser.getId());\n }", "public void findbyid() throws Exception {\n try {\n Con_contadorDAO con_contadorDAO = getCon_contadorDAO();\n List<Con_contadorT> listTemp = con_contadorDAO.getByPK( con_contadorT);\n\n con_contadorT= listTemp.size()>0?listTemp.get(0):new Con_contadorT();\n \n } catch (Exception e) {\n e.printStackTrace();\n setMsg(\"Falha ao realizar consulta!\");\t\n } finally {\n\tclose();\n }\n }", "public Data findById(Object id);", "@Test\n void getByIdSuccess() {\n UserRoles retrievedUserRole = (UserRoles) genericDao.getById(2);\n assertEquals(\"all\", retrievedUserRole.getRoleName());\n assertEquals(\"fhensen\", retrievedUserRole.getUserName());\n\n assertNotNull(retrievedUserRole);\n }", "@Override\n public User findById(long id) {\n return dao.findById(id);\n }", "@Override\n\tpublic User find(int id) {\n\t\tSystem.out.println(\"OracleDao is find\");\n\t\treturn null;\n\t}", "T findById(final ID id) throws RequiredValueException, NoEntityFoundException;", "@Test\r\n\tpublic void findByFileInfoID() {\n\t\tSystem.out.println(123);\r\n\t\tint file_id = 1;\r\n\t\tFileInfo f= fileInfoDao.findByFileInfoID(file_id);\r\n\t\tdd(f);\r\n\t\t\r\n\t}", "public T find(int id) {\n\t \treturn getEntityManager().find(getEntityClass(), id);\n\t }", "@Test\r\n public void testFindById() throws Exception {\r\n }", "public int findId(@NotNull T object) {\n Logger logger = getLogger();\n int id = -1;\n try (Connection connection = getConnection();\n PreparedStatement preparedStatement = connection.prepareStatement(getFind())) {\n\n setStatement(preparedStatement, object);\n logger.info(\"Executing statement: \" + preparedStatement);\n ResultSet rs = preparedStatement.executeQuery();\n\n while (rs.next()) {\n id = rs.getInt(\"id\");\n }\n } catch (SQLException | NotEnoughDataException e) {\n logger.error(e.getMessage());\n }\n logger.info(\"Select by id: success\");\n return id;\n }", "<T> T findById(String typeName, String id, Class<T> clazz);", "@Override\n public BookmarkEntity findById(String id) {\n logger.info(\"Entering findById() in BookmarkDAO\");\n return bookmarkRepository.findByID(id);\n }", "@Test\n public void test4FindPk() {\n SpecialityFactory factory = new MysqlSpecialityDAOFactry();\n SpecialityDAO dao = factory.create();\n SpecialityDTO respuesta = dao.findPk(\"telecomunicaciones\");\n assertEquals(respuesta,spec2);\n }", "Optional<T> find(long id);", "@Test\n\tpublic void shouldFindUserWithGivenId() throws UserNotFoundException\n\t{\n\t\tUserProfile user = new UserProfile();\n\t\tuser.setId(1);\n\t\t\n\t\twhen(userDao.findUserById(user.getId())).thenReturn(user);\n\t\t\n\t\tassertEquals(user, userService.findUserById(user.getId()));\n\t}", "T findOne(I id);", "@Test\n public void getUserById() {\n userDAO.createUser(new User(\"dummy\", \"dummy\", 1));\n\n //test fetching of data\n assertNotNull(userResource.getUser(\"dummy\"));\n\n //clean up\n userDAO.removeUser(\"dummy\");\n }", "@Test\n void findById() {\n when(ownerRepository.findById(anyLong())).thenReturn(Optional.of(returnOwner));\n\n Owner owner = service.findById(1L);\n\n assertNotNull(owner);\n }", "T getById(PK id);", "@Override\n public T findById(ID id) {\n return crudRepository.findById(id).orElseThrow(\n () -> new ResourceNotFoundException(\"Can not find an entity with id: \" + id));\n }", "public T getFromId(U id, Class<T> clazz) throws DaoException ;", "@Test (expected = NoSuchDatabaseEntryException.class)\r\n\tpublic void failOnFindByIdWithNoMatch() throws NoSuchDatabaseEntryException {\n\t\tdao.findById(-1);\r\n\t}", "@Test\n\tpublic void testFindUserById() throws Exception {\n\t\tSqlSession sqlSession = factory.openSession();\n\t\tUser user = sqlSession.selectOne(\"com.wistron.meal.user.findUserById\",3);\n\t\tSystem.out.println(user);\n\t\tsqlSession.close();\n\t\t\n\t}", "@Test\n void getNoteByIdSuccess() {\n Note retrievedNote = (Note) noteDao.getById(1);\n assertEquals(1, retrievedNote.getId());\n assertEquals(\"Amari Rodgers\", retrievedNote.getProspect());\n }", "@Override\n public Optional<T> findById(ID id) {\n T entity = getSession().get(this.getPersistentClass(), id);\n return Optional.ofNullable(entity);\n }", "E find(Id id) throws RepositoryException;", "public <T> T find(Class<T> entityClass, String id);", "@Test\n void getByIdSuccess() {\n RunCategory retrievedCat = (RunCategory)dao.getById(1);\n assertEquals(\"A Ending, New Game\", retrievedCat.getCategoryName());\n }", "@Override\r\n\tpublic User findById(int id) {\n\t\treturn userDAO.findById(id);\r\n\t}", "public void findbyid() throws Exception {\n try {\n Ume_unidade_medidaDAO ume_unidade_medidaDAO = getUme_unidade_medidaDAO();\n List<Ume_unidade_medidaT> listTemp = ume_unidade_medidaDAO.getByPK( ume_unidade_medidaT);\t \n\n ume_unidade_medidaT= listTemp.size()>0?listTemp.get(0):new Ume_unidade_medidaT();\n \n } catch (Exception e) {\n e.printStackTrace();\n setMsg(\"Falha ao realizar consulta!\");\t\n } finally {\n\tclose();\n }\n }", "@Test\n public void givenEntity_whenFindById_thenReturnEntity() {\n int id = 0;\n ThreeEntity entity = new ThreeEntity(1,1);\n\n given(threeDao.findById(0)).willReturn(entity);\n\n ThreeEntity found = threeService.findById(id);\n\n assertEquals(id, entity.getId());\n assertEquals(found.getParentId(), entity.getParentId());\n assertEquals(found.getValue(), entity.getValue());\n }", "@Override\n\tpublic DomainObject find(long id) {\n\t\treturn null;\n\t}", "priorizedListObject find( int id ) throws DAOException;", "@Test\n void findOne() {\n UserEntity userEntity = new UserEntity();\n userEntity.setId(1);\n userEntity.setFirstName(\"mickey\");\n userEntity.setLastName(\"mouse\");\n UserEntity save = repository.save(userEntity);\n\n // then find\n UserEntity byId = repository.getById(1);\n\n System.out.println(\"byId.getId() = \" + byId.getId());\n\n Assert.isTrue(1 == byId.getId());\n }", "T getById(int id);", "T getById(Long id);", "@Test\n void getByIdSuccess() {\n //Get User\n GenericDao<User> userDao = new GenericDao(User.class);\n User user = userDao.getById(2);\n\n //Create Test Car\n Car testCar = new Car(1,user,\"2016\",\"Jeep\",\"Wrangler\",\"1C4BJWFG2GL133333\");\n\n //Ignore Create/Update times\n testCar.setCreateTime(null);\n testCar.setUpdateTime(null);\n\n //Get Existing Car\n Car retrievedCar = carDao.getById(1);\n assertNotNull(retrievedCar);\n\n //Compare Cars\n assertEquals(testCar,retrievedCar);\n }", "@Test\r\n\tpublic void testDeleteById() {\r\n\t\tList<E> entities = dao.findAll();\r\n\t\tfor (E e : entities) {\r\n\t\t\tInteger id = supplyId(e);\r\n\t\t\tdao.deleteById(id);\r\n\t\t\tE read = dao.read(id);\r\n\t\t\tassertNull(read);\r\n\t\t}\r\n\t}", "public void findById() {\n String answer = view.input(message_get_id);\n if (answer != null){\n try{\n long id = Long.parseLong(answer);\n Customer c = model.findById(id);\n if(c!=null)\n view.showCustomerForm(c);\n else\n view.showMessage(not_found_error);\n }catch(NumberFormatException nfe){\n view.showMessage(\"ID must be number\");\n }\n }\n }", "@Test\n public void selectById() {\n }", "public abstract T byId(ID id);", "@Override\n\tpublic User findById(int userid) {\n\t\tSystem.out.println(\"Inside findOne of UserService\");\n\t\tOptional<User> user = userdao.findById(userid);\n//\t\treturn dao.findById(id);\n\t\treturn user.get();\n\t}", "@Override\n public MyBook findById(final int id) {\n System.err.println(\"MyBookRepositoryImpl:159 - not implement\");\n System.exit(1);\n return null;\n }", "@Test\n void getByIdSuccess () {\n TestEntity testEntity = buildEntity();\n Api2 instance = new Api2();\n Long result = instance.save(testEntity);\n System.out.println(\"Result\" + result);\n\n if (result != null) {\n Optional<TestEntity> optionalEntity = instance.getById(TestEntity.class, result);\n\n TestEntity entity = optionalEntity.orElse(null);\n\n if (entity != null) {\n Assertions.assertEquals(result, entity.getId());\n Assertions.assertNotNull(result);\n } else {\n Assertions.fail();\n }\n } else {\n Assertions.fail();\n }\n }", "public void test_getId() {\n assertEquals(\"'id' value should be properly retrieved.\", id, instance.getId());\n }", "@Override\n\tpublic Session sessionFindById(int id) {\n\t\treturn null;\n\t}", "@Override\r\n\tpublic Person findbyid(int id) {\n\t\tQuery query=em.createQuery(\"Select p from Person p where p.id= \"+id);\r\n\t\tPerson p=(Person) query.getSingleResult();\r\n\t\treturn p;\r\n\t\r\n\t}" ]
[ "0.7003683", "0.6910795", "0.6867049", "0.67452437", "0.67304724", "0.66934323", "0.66882354", "0.6654338", "0.6641506", "0.6636669", "0.66294944", "0.6628881", "0.6574959", "0.6551327", "0.65482634", "0.6545877", "0.6498939", "0.64964366", "0.6490649", "0.6486426", "0.6476925", "0.64693004", "0.6450103", "0.6431117", "0.6430679", "0.64282167", "0.6422452", "0.64178175", "0.64097154", "0.6394802", "0.6394415", "0.6391461", "0.6388803", "0.6383852", "0.6380441", "0.6377719", "0.63478094", "0.63461286", "0.6330101", "0.6328283", "0.63274324", "0.630618", "0.63003975", "0.62861246", "0.6277478", "0.6277478", "0.6277137", "0.6273715", "0.6271157", "0.62650216", "0.6251178", "0.62430114", "0.62325335", "0.62286675", "0.6226728", "0.6222422", "0.6219758", "0.62077", "0.6203854", "0.6191787", "0.61738867", "0.61728245", "0.6159033", "0.6153484", "0.6124114", "0.61170197", "0.61142117", "0.6094992", "0.60939205", "0.6085882", "0.6084862", "0.6077643", "0.6077392", "0.60750854", "0.607341", "0.60666203", "0.60664284", "0.6062625", "0.605782", "0.60554606", "0.60501647", "0.60449845", "0.6039613", "0.60355663", "0.60351825", "0.6035071", "0.6032947", "0.602607", "0.602114", "0.6018168", "0.6016497", "0.6012147", "0.6009764", "0.6008083", "0.6007441", "0.6000261", "0.5988005", "0.598052", "0.5975604", "0.5969397", "0.59692764" ]
0.0
-1
Test of findByCategory method, of class ForumThreadDAOImpl.
@Test @Transactional public void testFindByCategory() { List<ForumThread> forumThreads = new ArrayList<>(); forumThreads = forumThreadDAO.findByCategory("NEWS"); logger.info("Forum Threads: -> {}", forumThreads.toString()); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Test\n public void findCategoryById() {\n\n Long categoryId = (long) 1;\n CategoryEto category = this.dishmanagement.findCategory(categoryId);\n assertThat(category).isNotNull();\n }", "ArrayList<News> findByCategory(String category) throws DAOException, ConnectionPoolDataSourceException;", "@Override\n public ArrayList<News> findByCategory(String foundCategory) throws DAOException, ConnectionPoolDataSourceException {\n ArrayList<News> news = new ArrayList<>();\n PreparedStatement preparedStatement = null;\n ResultSet resultSet = null;\n Connection connection = connectionPool.takeConnection();\n try {\n preparedStatement = connection.prepareStatement(SQL_SELECT_BY_CATEGORY);\n preparedStatement.setString(1, foundCategory);\n resultSet = preparedStatement.executeQuery();\n while (resultSet.next()) {\n String category = resultSet.getString(2);\n String title = resultSet.getString(3);\n String author = resultSet.getString(4);\n String date = resultSet.getString(5);\n news.add(new News(category, title, author, date));\n }\n if (news == null) {\n throw new DAOException(\"Error in findByCategory.\");\n }\n connectionPool.closeConnection(connection, preparedStatement, resultSet);\n } catch (SQLException e) {\n throw new DAOException(e);\n }\n return news;\n }", "@Test\n void getByIdSuccess() {\n RunCategory retrievedCat = (RunCategory)dao.getById(1);\n assertEquals(\"A Ending, New Game\", retrievedCat.getCategoryName());\n }", "@Test\n public void getEmployeeByCategory() {\n userDAO.createUser(new User(\"dummy\", \"dummy\", 1));\n\n //creating dummy employee\n employeeDAO.createEmployee(new Employee(\"dummy\", \"dummy\", \"dummy\", \"dummy\", \"dummy\", 1));\n\n assertNotNull(employeeResource.getEmployeeCategory(1));\n\n //clean up\n employeeDAO.removeEmployee(\"dummy\");\n userDAO.removeUser(\"dummy\");\n\n //test clean up\n assertNull(userResource.getUser(\"dummy\"));\n }", "@Test\n public void ShouldFindbyCategory() {\n Recipe curry = new Recipe();\n curry.setCategory(\"curry\");\n Recipe curryOne = new Recipe();\n curryOne.setCategory(\"curry\");\n Recipe breakfast = new Recipe();\n breakfast.setCategory(\"breakfast\");\n recipesRepository.save(curry);\n recipesRepository.save(curryOne);\n recipesRepository.save(breakfast);\n\n // When I check for curries\n List<Recipe> curries = recipesRepository.findByCategory(\"curry\");\n\n // Then only curries are returned\n assertThat(curries).containsExactly(curry, curryOne);\n }", "@Test\n\tpublic void testGetAllResourcesByCategory() throws ResourceNotFoundException\n\t{\n\t\tLocalDate resDate = null;\n\t\t\n\t\tCategory cat = new Category();\n\t\tcat.setCatId(10);\n\t\tcat.setCatName(\"Clothing\");\n\t\t\n\t\tResource res = new Resource();\n\t\tres.setResId(10);\n\t\tres.setResDate(resDate);\n\t\tres.setCategory(cat);\n\t\tres.setResDescription(\"100% Cotton\");\n\t\tres.setResTitle(\"Shirt\");\n\t\tres.setResPrice(1000);\n\t\t\n\t\tList<Resource> resources = new ArrayList<>();\n\t\tresources.add(res);\n\t\tMockito.when(resourceRepository.findByCategory(10)).thenReturn(resources);\n\t\tList<Resource> actualResource = resourceService.getAllResourcesByCategory(10);\n\t\tassertEquals(10,actualResource.get(0).getCategory().getCatId());\n\t\t\n\t}", "List<Post> findAllBycategory(Category category);", "public void newCategoryThread(String category, String title, String message) {\n\t\twait.until(ExpectedConditions.elementToBeClickable(By.xpath(\".//*[@id='fs-application-wrapper']/div[3]/div/div[1]/a\")));\n\t\tfind.byXpathNSNC(\".//*[@id='fs-application-wrapper']/div[3]/div/div[1]/a\");\n\t\tdriver.findElement(By.xpath(\".//*[@id='fs-application-wrapper']/div[3]/div/div[1]/a\")).click();\n\t\t\n\t\twait.until(ExpectedConditions.visibilityOfElementLocated(By.xpath(\".//*[@id='fs-application-wrapper']/div[3]/div/div[2]\")));\n\t\tString xpathExpression = \".//select[@name='categoryId']\";\n\t\twait.until(ExpectedConditions.elementToBeClickable(By.xpath(xpathExpression)));\n\t\tfind.byXpathNSNC(xpathExpression);\n\t\tSelect select = new Select(driver.findElement(By.xpath(xpathExpression)));\n\n\t\tswitch (category) {\n\n\t\tcase \"Announcements\":\n\t\t\tselect.selectByValue(\"0\");\n\t\t\tbreak;\n\t\tcase \"Welcome Center\":\n\t\t\tselect.selectByValue(\"1\");\n\t\t\tbreak;\n\t\tcase \"Tutorials and Tips\":\n\t\t\tselect.selectByValue(\"2\");\n\t\t\tbreak;\n\t\tcase \"Production\":\n\t\t\tselect.selectByValue(\"3\");\n\t\t\tbreak;\n\t\tcase \"Peer Support\":\n\t\t\tselect.selectByValue(\"4\");\n\t\t\tbreak;\n\t\tcase \"Collaboratory\":\n\t\t\tselect.selectByValue(\"5\");\n\t\t\tbreak;\n\t\tcase \"Meetups\":\n\t\t\tselect.selectByValue(\"6\");\n\t\t\tbreak;\n\t\tcase \"Creative Services\":\n\t\t\tselect.selectByValue(\"7\");\n\t\t\tbreak;\n\t\tcase \"Wanted\":\n\t\t\tselect.selectByValue(\"8\");\n\t\t\tbreak;\n\t\tcase \"For Sale\":\n\t\t\tselect.selectByValue(\"9\");\n\t\t\tbreak;\n\t\tcase \"YouTube\":\n\t\t\tselect.selectByValue(\"10\");\n\t\t\tbreak;\n\t\tcase \"Promotion Hub\":\n\t\t\tselect.selectByValue(\"11\");\n\t\t\tbreak;\n\t\tcase \"Gorilla\":\n\t\t\tselect.selectByValue(\"12\");\n\t\t\tbreak;\n\t\tcase \"General Discussion\":\n\t\t\tselect.selectByValue(\"13\");\n\t\t\tbreak;\n\t\tcase \"Achievement Bragging\":\n\t\t\tselect.selectByValue(\"14\");\n\t\t\tbreak;\n\t\tcase \"Shameless Self-Promotion\":\n\t\t\tselect.selectByValue(\"15\");\n\t\t\tbreak;\n\t\tcase \"Ideas and Suggestions\":\n\t\t\tselect.selectByValue(\"16\");\n\t\t\tbreak;\n\t\tcase \"Fullscreen em Português\":\n\t\t\tselect.selectByValue(\"17\");\n\t\t\tbreak;\n\t\tcase \"Fullscreen en Español\":\n\t\t\tselect.selectByValue(\"18\");\n\t\t\tbreak;\n\t\tcase \"Fullscreen en Français\":\n\t\t\tselect.selectByValue(\"19\");\n\t\t\tbreak;\n\n\t\tdefault:\n\t\t\tbreak;\n\t\t}\nfind.byXpathNSNC(\".//input[@name='postTitle']\");\n\t\tdriver.findElement(By.xpath(\".//input[@name='postTitle']\")).sendKeys(title);\n\t\tfind.byXpathNSNC(\".//textarea\");\n\t\tdriver.findElement(By.xpath(\".//textarea\")).sendKeys(message);\n\t\t//scroller.scrollTo(driver.findElement(By.xpath(\".//select[@name='categoryId']\")));\n\t\t\n\t\tjs.executeScript(\"window.scrollBy(0,0);\");\t\n\t\t//driver.findElement(By.xpath(\".//button\")).click();\n\t}", "@Test\n public void findByNameShouldReturnCategory() {\n \n List<Doctor> doctors = drepository.findByName(\"Jim Morgan\");\n assertThat(doctors).hasSize(1);\n assertThat(doctors.get(0).getDoctorid()).isNotNull();\n }", "@Test\n public void getCategory_CorrectInformation(){\n int returned = testDatabase.addCategory(category);\n Category retrieved = testDatabase.getCategory(returned);\n assertEquals(\"getCategory - Correct Name\", \"Lunch\", retrieved.getName());\n assertEquals(\"getCategory - Correct ID\", returned, retrieved.getKeyID());\n }", "@Override\n\tpublic JCRPageList getPageTopic(String categoryId, String forumId,\n\t\t\tString strQuery, String strOrderBy) throws Exception {\n\t\treturn null;\n\t}", "@Test\r\n\tpublic void findByIdMaterialCategoryTest() {\r\n\t\t// Your Code Here\r\n\r\n\t}", "@Test\n public void getCategory_ReturnsCategory(){\n int returned = testDatabase.addCategory(category);\n assertNotEquals(\"getCategory - Return Non-Null Category\",null, testDatabase.getCategory(returned));\n }", "@Override\n public List<Classroom> findByCategory(Category category) {\n List<Classroom> classrooms = null;\n Query query = entityManager.createQuery(\"Select c from Classroom c where c.categoryId= :category\");\n query.setParameter(\"category\",category);\n try {\n classrooms = query.getResultList();\n } catch (Exception e){\n e.printStackTrace();\n }\n return classrooms;\n }", "@Test\n\tpublic final void testGetCategoryFromProductByUid() {\n\t\tfinal long categoryUid = 234L;\n\t\tfinal Category mockCategory = context.mock(Category.class);\n\t\tcontext.checking(new Expectations() {\n\t\t\t{\n\t\t\t\tallowing(mockCategory).getUidPk();\n\t\t\t\twill(returnValue(categoryUid));\n\t\t\t}\n\t\t});\n\t\tfinal Set<Category> categories = new HashSet<Category>();\n\t\tcategories.add(mockCategory);\n\t\tfinal long productUid = 123L;\n\t\tfinal Product mockProduct = context.mock(Product.class);\n\t\tcontext.checking(new Expectations() {\n\t\t\t{\n\t\t\t\tallowing(mockProduct).getUidPk();\n\t\t\t\twill(returnValue(productUid));\n\n\t\t\t\tallowing(mockProduct).getCategories();\n\t\t\t\twill(returnValue(categories));\n\t\t\t}\n\t\t});\n\t\tfinal Product product = mockProduct;\n\t\t\n\t\tassertSame(\"Returned category should be the one the product belongs to\", mockCategory,\n\t\t\t\tproductServiceImpl.getCategoryFromProductByUid(product, categoryUid));\n\t\t\n\t\tassertNull(\"non-existent category should return a null result\", productServiceImpl.getCategoryFromProductByUid(product, 0L));\n\t\t\n\t}", "EmailTemplateSubCategoryMaster findbyId(long subcategoryId);", "@Test\n void getAllSuccess() {\n List<RunCategory> categories = dao.getAll();\n assertEquals(13, categories.size());\n }", "@Test\n public void testGetForumByID() {\n try {\n ForumDTO forumDTO = forumService.getForumWithID(FORUM_ID);\n assertEquals(FORUM_ID, forumDTO.getId());\n assertEquals(USER_NAME, forumDTO.getAuthor().getUsername());\n assertEquals(FORUM_TITLE, forumDTO.getTitle());\n } catch (Exception e) {\n fail(e.getMessage());\n }\n }", "@Test\n public void testGetForumByUser() {\n try {\n List<ForumDTO> forumDTOS = forumService.getForumsByUser(USER_ID);\n assertTrue(\n forumDTOS.stream()\n .map(ForumDTO::getId)\n .collect(Collectors.toSet())\n .contains(FORUM_ID)\n );\n assertTrue(\n forumDTOS.stream()\n .map(ForumDTO::getId)\n .collect(Collectors.toSet())\n .contains(FORUM_LOCKED_ID)\n );\n } catch (Exception e) {\n fail(e.getMessage());\n }\n }", "@Test\n @Transactional\n public void getAllCategoriesByOwnerIsEqualToSomething() throws Exception {\n User owner = category.getOwner();\n categoryRepository.saveAndFlush(category);\n Long ownerId = owner.getId();\n\n // Get all the categoryList where owner equals to ownerId\n defaultCategoryShouldBeFound(\"ownerId.equals=\" + ownerId);\n\n // Get all the categoryList where owner equals to ownerId + 1\n defaultCategoryShouldNotBeFound(\"ownerId.equals=\" + (ownerId + 1));\n }", "@Test\n public void validSessionTransactionsGetCategoryTest() {\n // Insert two different transactions with two different categories into the API.\n validSessionTransactionsGetOffsetTest();\n\n Object[] categories = given()\n .header(\"X-session-ID\", sessionId)\n .queryParam(\"category\", \"work\")\n .get(\"/api/v1/transactions\")\n .then()\n .assertThat()\n .statusCode(200)\n .body(matchesJsonSchema(TRANSACTION_LIST_SCHEMA_PATH))\n .contentType(ContentType.JSON)\n .extract()\n .jsonPath()\n .getList(\"$.category.name\")\n .toArray();\n\n for (Object category : categories) {\n assertThat(category, equalTo(\"work\"));\n }\n }", "@Test\n public void testGetComponentesByCategory() {\n System.out.println(\"getComponentesByCategory\");\n query = mock(Query.class);\n String nativeQuery = \"Componente.findByCategory\";\n List<Componente> expected = new ArrayList<>();\n when(this.em.createNativeQuery(nativeQuery)).thenReturn(query);\n when(cDao.getComponentesByCategory(anyInt(), anyInt(), anyString())).thenReturn(expected);\n List<Componente> result = cDao.getComponentesByCategory(anyInt(), anyInt(), anyString());\n assertThat(result, is(expected));\n }", "@Override\n\tpublic LazyPageList<Topic> getTopicList(String categoryId, String forumId,\n\t\t\tString string, String strOrderBy, int pageSize) throws Exception {\n\t\treturn null;\n\t}", "@Test\n\tpublic void getCategoryTest() {\n\t\tList<Map<String, String>> list = new ArrayList<Map<String, String>>();\n\t\tMap<String, String> map = new HashMap<String, String>();\n\t\tmap.put(\"category\", \"Placement\");\n\t\tlist.add(map);\n\t\twhen(TicketDao.getCategory()).thenReturn(list);\n\t\tString category = \"<option value='\" + \"Placement\" + \"'>\" + \"Placement\" + \"</option>\";\n\t\tassertEquals(category, Service.getCategory());\n\t}", "Category findCategoryById(Long id);", "@Test\n public void testFindAllForums() {\n try {\n List<ForumDTO> forumDTOS = forumService.getAllForum();\n assertTrue(forumDTOS.stream()\n .map(ForumDTO::getId)\n .collect(Collectors.toSet())\n .contains(FORUM_ID)\n );\n assertTrue(forumDTOS.stream()\n .map(ForumDTO::getId)\n .collect(Collectors.toSet())\n .contains(FORUM_LOCKED_ID)\n );\n } catch (Exception e) {\n fail(e.getMessage());\n }\n }", "@Test\n\tpublic void testSearchCategory() throws Exception {\n\n\t\tCategorySearchResponse categoryResponse = new CategorySearchResponse();\n\t\tList<CategorySearch> categories = new ArrayList<>();\n\t\tCategorySearch category = new CategorySearch();\n\t\tcategory.setTenantId(\"default\");\n\n\t\tAuditDetails auditDetails = new AuditDetails();\n\t\tcategory.setAuditDetails(auditDetails);\n\n\t\tcategories.add(category);\n\n\t\tcategoryResponse.setResponseInfo(new ResponseInfo());\n\t\tcategoryResponse.setCategories(categories);\n\n\t\ttry {\n\n\t\t\twhen(categoryService.getCategoryMaster(any(RequestInfo.class), any(String.class), any(Integer[].class),\n\t\t\t\t\tany(String.class), any(String.class), any(String.class), any(String.class), any(String.class), any(Integer.class),\n\t\t\t\t\tany(String.class), any(String.class), any(Integer.class), any(Integer.class), any(Integer.class))).thenReturn(categoryResponse);\n\n\t\t\tmockMvc.perform(post(\"/category/v1/_search\").param(\"tenantId\", \"default\").param(\"type\", \"SUBCATEGORY\")\n\t\t\t\t\t.contentType(MediaType.APPLICATION_JSON).content(getFileContents(\"categorySearchRequest.json\")))\n\t\t\t\t\t.andExpect(status().isOk())\n\t\t\t\t\t.andExpect(content().contentTypeCompatibleWith(MediaType.APPLICATION_JSON))\n\t\t\t\t\t.andExpect(content().json(getFileContents(\"categorySearchResponse.json\")));\n\n\t\t} catch (Exception e) {\n\t\t\tassertTrue(Boolean.FALSE);\n\t\t\te.printStackTrace();\n\t\t}\n\n\t\tassertTrue(Boolean.TRUE);\n\n\t}", "@Test\n\tpublic void getSubCategoryTest() {\n\t\tList<Map<String, String>> list = new ArrayList<Map<String, String>>();\n\t\tMap<String, String> map = new HashMap<String, String>();\n\t\tmap.put(\"subcategory\", \"Skype\");\n\t\tlist.add(map);\n\t\twhen(TicketDao.getSubCategory(Mockito.anyString())).thenReturn(list);\n\t\tassertEquals(list, Service.getSubCategory(Mockito.anyString()));\n\t}", "@Test\n public void addRecipeCategory_DatabaseUpdates(){\n int returnedRecipe = testDatabase.addRecipe(testRecipe);\n int returnedCategory = testDatabase.addRecipeCategory(recipeCategory);\n ArrayList<RecipeCategory> allCategories = testDatabase.getAllRecipeCategories(returnedRecipe);\n RecipeCategory retrieved = new RecipeCategory();\n if(allCategories != null){\n for(int i = 0; i < allCategories.size(); i++){\n if(allCategories.get(i).getKeyID() == returnedCategory){\n retrieved = allCategories.get(i);\n }\n }\n }\n assertEquals(\"addRecipeDirection - Correct RecipeID\", returnedRecipe, retrieved.getRecipeID());\n assertEquals(\"addRecipeDirection - Correct CategoryID\", categoryID, retrieved.getCategoryID());\n }", "public interface CategoryDAO extends DAO<AbsractCategory> {\n\n /**\n * getting exactly one category specified by the given id\n *\n * @param identificaitonNumber of the category to search for\n * @return exactely one category\n * @throws PersistenceException\n */\n AbsractCategory searchByID(int identificaitonNumber) throws PersistenceException;\n\n /**\n * getting a list of all equipment categorys\n *\n * @return a list of all equipment categorys like, kurzhantel, langhantel, springschnur ...\n * @throws PersistenceException\n */\n List<EquipmentCategory> getAllEquipment() throws PersistenceException;\n\n /**\n * getting a list of all muscle groups\n *\n * @return a list of all muslce groups like, bauchmuskeln, oberschenkel, unterschenkel ...\n * @throws PersistenceException\n */\n List<MusclegroupCategory> getAllMusclegroup() throws PersistenceException;\n\n /**\n * getting a list of all trainingstypes\n *\n * @return a list of all trainingstypes: ausdauer, kraft, balance, flexibilitaet\n * @throws PersistenceException\n */\n List<TrainingsCategory> getAllTrainingstype() throws PersistenceException;\n\n}", "public Category find_Category(Integer category_id, Integer branch_id) {\n return category_dao.find(category_id, branch_id);\n }", "@Test\n public void deleteRecipeCategory_Deletes(){\n int returnedRecipe = testDatabase.addRecipe(testRecipe);\n int returnedCategory = testDatabase.addRecipeCategory(recipeCategory);\n testDatabase.deleteRecipeCategory(returnedCategory);\n ArrayList<RecipeCategory> allCategories = testDatabase.getAllRecipeCategories(returnedRecipe);\n boolean deleted = true;\n if(allCategories != null){\n for(int i = 0; i < allCategories.size(); i++){\n if(allCategories.get(i).getCategoryID() == returnedCategory){\n deleted = false;\n }\n }\n }\n assertEquals(\"deleteRecipeCategory - Deletes From Database\", true, deleted);\n }", "@Override\n\tpublic List<Topic> getTopics(String categoryId, String forumId)\n\t\t\tthrows Exception {\n\t\treturn null;\n\t}", "List<Category> getCategories() throws DAOExceptionHandler;", "Category getCategoryById(int categoryId);", "@Override\n\tpublic List<Forum> getForums(String categoryId, String strQuery)\n\t\t\tthrows Exception {\n\t\treturn null;\n\t}", "public interface ForumService{\r\n\r\n\t/**\r\n\t * Method return list forum which crated between dates. If forums\r\n\t * are not exist return empty list.\r\n\t * \r\n\t * @type Date\r\n\t * @param minDate\r\n\t * @param maxDate\r\n\t * \r\n\t * @exception DataRetrievalFailureException\r\n\t * @exception DataAccessException\r\n\t * \r\n\t * @return List<Forum>\r\n\t */\r\n\tpublic List<Forum> getListForumCreatedBetweenDateByIdForum(Date minDate,Date maxDate); \r\n\t\r\n\t/**\r\n\t * Method return total count of forums. If forums are not exist return zero. \r\n\t * \r\n\t * @type int\r\n\t * @exception DataAccessException\r\n\t * \r\n\t * @return int\r\n\t */\r\n\tpublic int getCountForum();\r\n\r\n\t/**\r\n\t * Method return list forum by forum name. If forums are not\r\n\t * exist return empty list\r\n\t * \r\n\t * @type String \r\n\t * @param forumName\r\n\t * \r\n\t * @exception DataRetrievalFailureException\r\n\t * @exception DataAccessException\r\n\t * \r\n\t * @return List<Forum>\r\n\t */\r\n\tpublic List<Forum> searchForumByForumName(String forumName);\r\n\t\r\n\t/**\r\n\t * Method return list forum with view status. If forums are not\r\n\t * exist return empty list.\r\n\t * \r\n\t * @type String \r\n\t * @param viewStatus\r\n\t * \r\n\t * @exception DataRetrievalFailureException\r\n\t * @exception DataAccessException\r\n\t * \r\n\t * @return List<Forum>\r\n\t */\r\n\tpublic List<Forum> getListForumWithStatus(String viewStatus);\r\n\t\r\n\t/**\r\n\t * Method return result of check forum on private view status.\r\n\t * \r\n\t * @type Long\r\n\t * @type Boolean\r\n\t * @param idForum\r\n\t * \r\n\t * @exception DataRetrievalFailureException\r\n\t * @exception DataAccessException\r\n\t * \r\n\t * @return Boolean\r\n\t */\r\n\tpublic Boolean isPrivateForum(Long idForum);\r\n\t\r\n\t/**\r\n\t * This method is basic for all entities.The method is one of CRUD methods.\r\n\t * Method return entity by idEntity. If entity not exist return null(use\r\n\t * hibernateTamplate method get)\r\n\t * \r\n\t * @type Long\r\n\t * @param idForum\r\n\t * \r\n\t * @exception DataRetrievalFailureException\r\n\t * @exception DataAccessException\r\n\t * \r\n\t * @return Forum\r\n\t */\r\n\tpublic Forum getForumById(Long idForum);\r\n\t\r\n\t/**\r\n\t * This method is basic for all entities.The method is one of CRUD methods.\r\n\t * Method save entity if entity not null.\r\n\t * \r\n\t * @type Forum\r\n\t * @param forum\r\n\t * \r\n\t * @exception TypeMismatchDataAccessException\r\n\t * @exception DataAccessException\r\n\t */\r\n\tpublic void saveForum(Forum forum);\r\n\t\r\n\t/**\r\n\t * This method is basic for all entities.The method is one of CRUD methods.\r\n\t * Method update entity if entity not null.\r\n\t * \r\n\t * @type Forum\r\n\t * @param forum\r\n\t * \r\n\t * @exception TypeMismatchDataAccessException\r\n\t * @exception DataAccessException\r\n\t */\r\n\tpublic void updateForum(Forum forum);\r\n\t\r\n\t/**\r\n\t * This method is basic for all entities.The method is one of CRUD methods.\r\n\t * Method delete entity by id if entity not null.\r\n\t * \r\n\t * @type Long\r\n\t * @param idForum\r\n\t * \r\n\t * @exception DataRetrievalFailureException\r\n\t * @exception DataAccessException\r\n\t */\r\n\tpublic void deleteForumById(Long idForum);\r\n\t\r\n\t/**\r\n\t * This method is basic for all entities.The method is one of CRUD methods.\r\n\t * Method delete entity if entity not null.\r\n\t * \r\n\t * @type Forum\r\n\t * @param forum\r\n\t * @exception DataAccessException\r\n\t */\r\n\tpublic void deleteForum(Forum forum);\r\n\t\r\n\t/**\r\n\t * This method is basic for all entities. Method return list of entity. If entyty\r\n\t * list not load return empty list.\r\n\t * \r\n\t * @exception DataRetrievalFailureException\r\n\t * @exception DataAccessException\r\n\t * \r\n\t * @return List<Object>\r\n\t */\r\n\tpublic List<Object> getListForum(); \r\n}", "@Override\n\tpublic List<Category> findcategory() {\n\t\t\n\t\tConnection conn=null;\n\t\tPreparedStatement pst=null;\n\t\tResultSet rs=null;\n\t\t\n\t\tList<Category> list=new ArrayList<Category>();\n\t\ttry {\n\t\t\tconn=DBUtils.getConnection();\n\t\t\tpst=conn.prepareStatement(\"select id,parent_id,name,status,sort_order,create_time,update_time from category\");\n\t\t\t\n\t\t\trs=pst.executeQuery();\n\t\t\t\n\t\t\twhile (rs.next()) {\n\t\t\t\tCategory category=new Category(rs.getInt(\"id\"),rs.getInt(\"parent_id\"),rs.getString(\"name\"),rs.getInt(\"status\"),rs.getInt(\"sort_order\"),rs.getDate(\"create_time\"),rs.getDate(\"update_time\"));\n\t\t\t\tlist.add(category);\n\t\t\t\t\n\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t} catch (SQLException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}finally {\n\t\t\ttry {\n\t\t\t\tDBUtils.Close(conn, pst, rs);\n\t\t\t} catch (SQLException e) {\n\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t\treturn list;\n\t\t\n\t\t\n\n\t}", "@Test\n public void deleteCategory_Deletes(){\n int returned = testDatabase.addCategory(category);\n testDatabase.deleteCategory(returned);\n assertEquals(\"deleteCategory - Deletes From Database\", null, testDatabase.getCategory(returned));\n }", "public interface CategoryDao {\n\n /**\n * Method adds category to database\n * @param category\n */\n void addCategory(Category category);\n\n /**\n * Method updates category in database\n * @param category\n */\n void updateCategory(Category category);\n\n /**\n * Methods returns category by id\n * @param id\n * @return\n */\n Category selectCategory(long id);\n\n /**\n * Methods returns category by category name\n * @param name\n * @return category\n */\n Category selectCategory(String name);\n\n /**\n * Method returns category list\n * @return category list\n */\n List<Category> selectCategoryList();\n\n /**\n * Method deletes category by id\n * @param id\n */\n void deleteCategory(long id);\n\n /**\n * Method deletes category parameter\n * @param id\n */\n void deleteParameter(long id);\n\n /**\n * Method deletes category products\n * @param id\n */\n void deleteCategoryProducts(long id);\n\n /**\n * Method delete category parameter product details\n * @param id\n */\n void deleteCategoryParameterProductDetails(long id);\n}", "@Override\n\tpublic List<Forum> getForumSummaries(String categoryId, String strQuery)\n\t\t\tthrows Exception {\n\t\treturn null;\n\t}", "@Test\n public void findDishesByCategoryName1() {\n\n String categoryName = \"Main Dishes\";\n DishSearchCriteriaTo criteria = new DishSearchCriteriaTo();\n List<CategoryEto> categories = new ArrayList<>();\n\n criteria.setCategories(categories);\n criteria.setSearchBy(\"\");\n PageRequest pageable = PageRequest.of(0, 8, Sort.by(Direction.DESC, \"price\"));\n criteria.setPageable(pageable);\n\n Page<DishCto> result = this.dishmanagement.findDishesByCategory(criteria, categoryName);\n assertThat(result).isNotNull();\n assertThat(result.getContent().size()).isGreaterThan(0);\n\n }", "Category selectCategory(long id);", "@Test\n public void findDishesByCategoryName2() {\n\n String categoryName = \"Starter\";\n DishSearchCriteriaTo criteria = new DishSearchCriteriaTo();\n List<CategoryEto> categories = new ArrayList<>();\n\n criteria.setCategories(categories);\n criteria.setSearchBy(\"\");\n PageRequest pageable = PageRequest.of(0, 8, Sort.by(Direction.DESC, \"price\"));\n criteria.setPageable(pageable);\n\n Page<DishCto> result = this.dishmanagement.findDishesByCategory(criteria, categoryName);\n assertThat(result).isNotNull();\n assertThat(result.getContent().size()).isGreaterThan(0);\n\n }", "Category getCategoryById(Integer categoryId);", "@Override\n public Forum getForum(String categoryId, String forumId) {\n\t\treturn null;\n\t}", "ProductCategory find(int id)throws IllegalArgumentException;", "@Test\r\n public void testGetALL() {\r\n CategoriaDAO instance = new CategoriaDAO();\r\n List<Categoria> result = instance.getALL();\r\n Categoria itera = new Categoria();\r\n Iterator it = result.iterator();\r\n while (it.hasNext()) {\r\n itera = (Categoria) it.next();\r\n System.out.println(itera.getIdcategoria() + \" \" + itera.getDescricao());\r\n }\r\n }", "@Test\r\n\tpublic void findAllMaterialCategoryTest() {\r\n\t\t// Your Code Here\r\n\r\n\t}", "boolean codeCategoryExists(UUID id)\n throws DAOException;", "Category getCategoryById(int id);", "@Test\n public void findDishesByCategoryName3() {\n\n String categoryName = \"Vegan\";\n DishSearchCriteriaTo criteria = new DishSearchCriteriaTo();\n List<CategoryEto> categories = new ArrayList<>();\n\n criteria.setCategories(categories);\n criteria.setSearchBy(\"\");\n PageRequest pageable = PageRequest.of(0, 8, Sort.by(Direction.DESC, \"price\"));\n criteria.setPageable(pageable);\n\n Page<DishCto> result = this.dishmanagement.findDishesByCategory(criteria, categoryName);\n assertThat(result).isNotNull();\n assertThat(result.getContent().size()).isGreaterThan(0);\n\n }", "Category findByName(String name);", "@Test\n public void findDishesByCategoryName4() {\n\n String categoryName = \"Rice\";\n DishSearchCriteriaTo criteria = new DishSearchCriteriaTo();\n List<CategoryEto> categories = new ArrayList<>();\n\n criteria.setCategories(categories);\n criteria.setSearchBy(\"\");\n PageRequest pageable = PageRequest.of(0, 8, Sort.by(Direction.DESC, \"price\"));\n criteria.setPageable(pageable);\n\n Page<DishCto> result = this.dishmanagement.findDishesByCategory(criteria, categoryName);\n assertThat(result).isNotNull();\n assertThat(result.getContent().size()).isGreaterThan(0);\n\n }", "public List<Question> getQuestions(Category category) {\n List<Question> questions = null;\n try {\n DataBaseBroker dbb = new DataBaseBroker();\n dbb.loadDriver();\n dbb.establishConnection();\n questions = dbb.getQuestion(category);\n dbb.commit();\n dbb.closeConnection();\n } catch (Exception ex) {\n Logger.getLogger(GameDBLogic.class.getName()).log(Level.SEVERE, null, ex);\n }\n return questions;\n }", "@Test\n public void findDishesByCategoryName5() {\n\n String categoryName = \"Curry\";\n DishSearchCriteriaTo criteria = new DishSearchCriteriaTo();\n List<CategoryEto> categories = new ArrayList<>();\n\n criteria.setCategories(categories);\n criteria.setSearchBy(\"\");\n PageRequest pageable = PageRequest.of(0, 8, Sort.by(Direction.DESC, \"price\"));\n criteria.setPageable(pageable);\n\n Page<DishCto> result = this.dishmanagement.findDishesByCategory(criteria, categoryName);\n assertThat(result).isNotNull();\n assertThat(result.getContent().size()).isGreaterThan(0);\n\n }", "@Test\n public void getConsultarCategoriaTest() throws ApiException {\n CategoryReturn response = api.getConsultarCategoria();\n\n // TODO: test validations\n }", "@Test\r\n\tpublic void catTest() {\r\n\t\tItem item = new Item();\r\n\t\ttry {\r\n\t\t\tString tempSet[] = item.getCats();\r\n\t\t\tassertNotSame(tempSet.length, 0);\r\n\t\t\tfor (int i = 0; i < tempSet.length; i++) { // check if categories are empty\r\n\t\t\t\tassertNotNull(tempSet[i]);\r\n\t\t\t\tassertNotSame(tempSet[i], \"\");\r\n\t\t\t}\r\n\t\t} catch (SQLException e) {\r\n\t\t\tfail(\"Failed to execute the retrieval of the list of categories: SQLException\");\r\n\t\t}\r\n\t\t\r\n\t}", "@Test\n public void findDishesByCategoryName7() {\n\n String categoryName = \"Vegetarian\";\n DishSearchCriteriaTo criteria = new DishSearchCriteriaTo();\n List<CategoryEto> categories = new ArrayList<>();\n\n criteria.setCategories(categories);\n criteria.setSearchBy(\"\");\n PageRequest pageable = PageRequest.of(0, 8, Sort.by(Direction.DESC, \"price\"));\n criteria.setPageable(pageable);\n\n Page<DishCto> result = this.dishmanagement.findDishesByCategory(criteria, categoryName);\n assertThat(result).isNotNull();\n assertThat(result.getContent().size()).isGreaterThan(0);\n\n }", "Category findById(int id);", "@Before\n public void getTestCategory() {\n if (sessionId == null) {\n getTestSession();\n }\n\n if (testCategoryId == null) {\n testCategoryId = Util.createTestCategory(TEST_CATEGORY_NAME, sessionId);\n }\n }", "@Dao\npublic interface CategoryDao {\n @Query(\"SELECT * FROM categoryTable\")\n List<Category> getAll();\n\n @Query(\"SELECT * FROM categoryTable WHERE id IN (:categoryIds)\")\n List<Category> loadAllByIds(Integer[] categoryIds);\n\n @Query(\"SELECT * FROM categoryTable WHERE id LIKE :id LIMIT 1\")\n Category findById(Integer id);\n\n @Query(\"SELECT * FROM categoryTable WHERE name LIKE :name LIMIT 1\")\n Category findByName(String name);\n\n @Query(\"SELECT id FROM categoryTable ORDER BY id DESC LIMIT 1\")\n Integer getLastUsedId();\n\n @Query(\"UPDATE categoryTable SET name = :name WHERE id = :id\")\n void updateCategory(Integer id, String name);\n\n @Insert\n void insertOne(Category category);\n\n @Insert\n void insertAll(List<Category> categories);\n\n @Update\n void updateCategorys(List<Category> categories);\n\n @Delete\n void delete(Category category);\n\n @Query(\"DELETE FROM categoryTable\")\n void clearTable();\n\n}", "@Test\n public void testFindByLogin() throws Exception {\n String userName = String.valueOf(databaseTester.getConnection().createDataSet().getTable(\"User\")\n .getValue(0, \"login\"));\n// User user = jdbcUserDao.findByLogin(userName);\n// assertNotNull(\"Should find user by login\", user);\n }", "public interface ITopicDao {\n public List<Topic> findTopicswithplatOption( platForumType type);\n\n}", "public Category getCategoryById()\r\n {\r\n return cdb.getCategoryById();\r\n }", "@Test\r\n\tpublic void notNullMaterialCategoryDAOTest() {\r\n\t\t// Your Code Here\r\n\t\r\n\t}", "@Repository\npublic interface UserCategoryDao extends JpaRepository<UserCategory, Long> {\n\n UserCategory findByUserIdAndCategory(long userId, String category);\n\n List<UserCategory> findByUserId(long userId);\n\n List<UserCategory> findByUserIdOrderBySortAsc(long userId);\n\n}", "@Test\n public void findDishesByCategoryName6() {\n\n String categoryName = \"Drinks\";\n DishSearchCriteriaTo criteria = new DishSearchCriteriaTo();\n List<CategoryEto> categories = new ArrayList<>();\n\n criteria.setCategories(categories);\n criteria.setSearchBy(\"\");\n PageRequest pageable = PageRequest.of(0, 8, Sort.by(Direction.DESC, \"price\"));\n criteria.setPageable(pageable);\n\n Page<DishCto> result = this.dishmanagement.findDishesByCategory(criteria, categoryName);\n assertThat(result).isNotNull();\n assertThat(result.getContent().size()).isGreaterThan(0);\n\n }", "public interface ConfigCategoryDao {\n /**\n * get all categories for specific type.\n * @param typeConstant type name.\n * @return list of categories for specific type\n */\n List getCategoriesOfType(String typeConstant);\n\n /**\n * get specific category by type and name.\n * @param typeConstant typeConstant\n * @param categoryCode categoryCode\n * @return category\n */\n ConfigCategory getCategoryOfTypeAndCode(String typeConstant, String categoryCode);\n\n /**\n * get specific category by id.\n * @param categoryId categoryId\n * @return category\n */\n ConfigCategory getCategoryById(long categoryId);\n\n /**\n * insert configCategory.\n * @param configCategory configCategory\n */\n void insertConfigCategory(ConfigCategory configCategory);\n\n /**\n * get config type by code.\n * @param typeCode typeCode\n * @return ConfigType\n */\n ConfigType getConfigTypeByCode(String typeCode);\n\n /**\n * get category by type and display name.\n * @param typeConstant typeConstant\n * @param catDisplayName catDisplayName\n * @return ConfigCategory\n */\n List<ConfigCategory> getCategoryOfTypeAndDisplayName(String typeConstant, String catDisplayName);\n}", "List<Product> findByCategory(Category category);", "@Transactional(propagation=Propagation.SUPPORTS,readOnly=true)\r\n\tpublic List<Music> queryCategory(Integer page,Integer rows,String category) {\n\t\tList<Music> list = musicdao.selectcategory(page,rows,category);\r\n\t\tSystem.out.println(page+rows+category+\"-------------service\");\r\n\t\treturn list;\r\n\t}", "@Test\n public void testDeleteForum() {\n try {\n ForumDTO forumDTO = forumService.deleteForum(FORUM_ID);\n assertEquals(FORUM_ID, forumDTO.getId());\n } catch (Exception e) {\n fail(e.getMessage());\n }\n }", "public Forum getForumById(Long idForum);", "@Test\n public void categoryTest() {\n // TODO: test category\n }", "@Test\r\n\tpublic void testGetCategoryString() {\r\n\t\tManagedIncident incident = new ManagedIncident(\"jsmith\", Category.NETWORK, Priority.LOW, \"Johnny\", \"lol\");\r\n\t\tassertEquals(\"Network\", incident.getCategoryString());\r\n\t\t\r\n\t\tManagedIncident incident1 = new ManagedIncident(\"jsmith\", Category.DATABASE, Priority.LOW, \"Johnny\", \"lol\");\r\n\t\tassertEquals(\"Database\", incident1.getCategoryString());\r\n\t\t\r\n\t\tManagedIncident incident2 = new ManagedIncident(\"jsmith\", Category.INQUIRY, Priority.LOW, \"Johnny\", \"lol\");\r\n\t\tassertEquals(\"Inquiry\", incident2.getCategoryString());\r\n\t\t\r\n\t\tManagedIncident incident3 = new ManagedIncident(\"jsmith\", Category.HARDWARE, Priority.LOW, \"Johnny\", \"lol\");\r\n\t\tassertEquals(\"Hardware\", incident3.getCategoryString());\r\n\t\t\r\n\t\tManagedIncident incident4 = new ManagedIncident(\"jsmith\", Category.SOFTWARE, Priority.LOW, \"Johnny\", \"lol\");\r\n\t\tassertEquals(\"Software\", incident4.getCategoryString());\r\n\t\t\r\n\t}", "List<Category> findAll(Integer page,Integer pageSize)throws Exception;", "public Category getTicketCategory() { return ticketCategory; }", "@Test\n public void getAllRecipeCategories_RecipeInfo(){\n int returned = testDatabase.addRecipe(testRecipe);\n ArrayList<RecipeCategory> allCategories = testDatabase.getAllRecipeCategories(returned);\n RecipeCategory retrieved = allCategories.get(allCategories.size()-1);\n //Retrieved should now contain all the same information as testRecipe\n assertEquals(\"getAllRecipeCategories - Correct Recipe ID\", returned, retrieved.getRecipeID());\n assertEquals(\"getAllRecipeCategories - Correct Category ID\", categoryID, retrieved.getCategoryID());\n }", "@Override\n\tpublic Category fetchByPrimaryKey(long categoryId) {\n\t\treturn fetchByPrimaryKey((Serializable)categoryId);\n\t}", "@Test\n\tpublic void testSearchCategoryDetails() throws Exception {\n\n\t\tCategorySearchResponse categoryResponse = new CategorySearchResponse();\n\t\tList<CategorySearch> categories = new ArrayList<>();\n\t\tCategorySearch category = new CategorySearch();\n\t\tcategory.setTenantId(\"default\");\n\t\tcategory.setParentId(Long.parseLong(\"2\"));\n\n\t\tAuditDetails auditDetails = new AuditDetails();\n\t\tcategory.setAuditDetails(auditDetails);\n\n\t\tcategories.add(category);\n\t\tCategoryDetailSearch details = new CategoryDetailSearch();\n\t\tdetails.setId(Long.valueOf(5));\n\t\tdetails.setCategoryId(Long.valueOf(10));\n\t\tdetails.setFeeType(FeeTypeEnum.fromValue(\"License\"));\n\t\tdetails.setRateType(RateTypeEnum.fromValue(\"Flat_By_Percentage\"));\n\t\tdetails.setUomId(Long.valueOf(1));\n\n\t\tList<CategoryDetailSearch> catDetails = new ArrayList<CategoryDetailSearch>();\n\t\tcatDetails.add(details);\n\t\tcategory.setDetails(catDetails);\n\t\tcategoryResponse.setResponseInfo(new ResponseInfo());\n\t\tcategoryResponse.setCategories(categories);\n\n\t\ttry {\n\n\t\t\twhen(categoryService.getCategoryMaster(any(RequestInfo.class), any(String.class), any(Integer[].class),\n\t\t\t\t\tany(String.class), any(String.class), any(String.class), any(String.class), any(String.class), any(Integer.class),\n\t\t\t\t\tany(String.class), any(String.class), any(Integer.class), any(Integer.class), any(Integer.class))).thenReturn(categoryResponse);\n\n\t\t\tmockMvc.perform(post(\"/category/v1/_search\").param(\"tenantId\", \"default\").param(\"type\", \"SUBCATEGORY\")\n\t\t\t\t\t.contentType(MediaType.APPLICATION_JSON)\n\t\t\t\t\t.content(getFileContents(\"categoryDetailsSearchRequest.json\"))).andExpect(status().isOk())\n\t\t\t\t\t.andExpect(content().contentTypeCompatibleWith(MediaType.APPLICATION_JSON))\n\t\t\t\t\t.andExpect(content().json(getFileContents(\"categoryDetailsSearchResponse.json\")));\n\n\t\t} catch (Exception e) {\n\t\t\tassertTrue(Boolean.FALSE);\n\t\t\te.printStackTrace();\n\t\t}\n\t\tassertTrue(Boolean.TRUE);\n\n\t}", "List<Category> findAll();", "@Override\n\tpublic Categories findById(Integer catId) {\n\t\treturn categoriesDAO.findById(catId);\n\t}", "public interface CategoryDao {\n List<Category> findAll();\n}", "AbsractCategory searchByID(int identificaitonNumber) throws PersistenceException;", "CodeCategory getCodeCategory(UUID id)\n throws DAOException;", "CachedCodeCategory getCachedCodeCategory(UUID id)\n throws DAOException;", "boolean hasForumCategoryId();", "@Test\n public void testCategoryAccessControl() {\n // set permissions\n PermissionData data = new PermissionData(true, false, false, true);\n pms.configureCategoryPermissions(testUser, data);\n\n // test access control\n assertTrue(accessControlService.canViewCategories(), \"Test user should be able to view categories!\");\n assertTrue(accessControlService.canAddCategory(), \"Test user should be able to create categories!\");\n assertFalse(accessControlService.canEditCategory(category), \"Test user should not be able to edit category!\");\n assertFalse(accessControlService.canRemoveCategory(category), \"Test user should not be able to remove category!\");\n }", "@Test\n public void testGetCantComponentesByCategory() {\n System.out.println(\"getCantComponentesByCategory\");\n query = mock(Query.class);\n String nativeQuery = \"Componente.CountComponentsByCategory\";\n int expected = Integer.SIZE;\n when(this.em.createNativeQuery(nativeQuery)).thenReturn(query);\n when(cDao.getCantComponentesByCategory(anyInt(), anyString())).thenReturn(expected);\n int result = cDao.getCantComponentesByCategory(anyInt(), anyString());\n assertThat(result, is(expected));\n }", "boolean cachedCodeCategoryExists(UUID id)\n throws DAOException;", "@Test\n\tvoid testGetDepartmentsByCrit() {\n\t\tDepartmentDAO ddao = new DepartmentDAO();\n\t\tList<Department> ls = ddao.getDepartmentsByCrit();\n\t\tIterator<Department> it = ls.iterator();\n\n\t\twhile (it.hasNext()) {\n\t\t\tDepartment dpt = it.next();\n\t\t\tSystem.out.println(dpt.getDepartment_name() + \" \" + dpt.getLocation_id() + \" \" + dpt.getManager_id());\n\t\t}\n\t\t// assertEquals(203, ls.get(0).getManager_id());\n\t}", "public interface CategoryDao {\n\n\tList<Category> getAll() throws Exception;\n\n\tvoid save(Category category) throws Exception;\n\n\tvoid update(Category category) throws Exception;\n\n\tvoid delete(String cid) throws Exception;\n\n\tCategory getById(String cid) throws Exception;\n\t\n}", "@Transactional\n\tpublic CategoryEntity getCategoryEntity(int idCategory) {\n\t\t\n\t\tSession session = sessionFactory.getCurrentSession();\n\t\t\n\t\tCategoryEntity categoryEntity = (CategoryEntity) session.createQuery(\"from category where idCategory='\"+idCategory+\"'\").getSingleResult();\n\t\t\n\t\treturn categoryEntity;\n\t}", "public interface ForumDao {\n List<Forum> getAllForum();\n List<Forum> getForumByStatus(int status);\n Forum getForumById(Long id);\n List<Forum> getLastTwoForum();\n List<Forum> getTopFiveCommentedForum();\n Forum deleteForum(Forum forum);\n Forum addForum(Forum forum);\n Forum editForum(Forum forum);\n}", "@Override\n\tpublic Category findById(String id) {\n\t\treturn null;\n\t}", "private void defaultCategoryShouldBeFound(String filter) throws Exception {\n restCategoryMockMvc.perform(get(\"/api/categories?sort=id,desc&\" + filter))\n .andExpect(status().isOk())\n .andExpect(content().contentType(MediaType.APPLICATION_JSON_VALUE))\n .andExpect(jsonPath(\"$.[*].id\").value(hasItem(category.getId().intValue())))\n .andExpect(jsonPath(\"$.[*].label\").value(hasItem(DEFAULT_LABEL)))\n .andExpect(jsonPath(\"$.[*].primaryColor\").value(hasItem(DEFAULT_PRIMARY_COLOR)))\n .andExpect(jsonPath(\"$.[*].secondaryColor\").value(hasItem(DEFAULT_SECONDARY_COLOR)));\n\n // Check, that the count call also returns 1\n restCategoryMockMvc.perform(get(\"/api/categories/count?sort=id,desc&\" + filter))\n .andExpect(status().isOk())\n .andExpect(content().contentType(MediaType.APPLICATION_JSON_VALUE))\n .andExpect(content().string(\"1\"));\n }", "public Categorie getCategorieById(long id);", "@Test\n public void getAllRecipeCategories_ReturnsNull(){\n int returned = testDatabase.addRecipe(testRecipe);\n testDatabase.deleteRecipeCategory(returned);\n assertEquals(\"getAllRecipeCategories - Empty List Returned\", null, testDatabase.getAllRecipeCategories(returned));\n }", "@Test\n public void findDishesByCategoryNameNotExist() {\n\n try {\n String categoryName = \"Dessert\";\n DishSearchCriteriaTo criteria = new DishSearchCriteriaTo();\n List<CategoryEto> categories = new ArrayList<>();\n\n criteria.setCategories(categories);\n criteria.setSearchBy(\"\");\n PageRequest pageable = PageRequest.of(0, 8, Sort.by(Direction.DESC, \"price\"));\n criteria.setPageable(pageable);\n\n Page<DishCto> result = this.dishmanagement.findDishesByCategory(criteria, categoryName);\n assertThat(result).isNull();\n\n } catch (Exception e) {\n IllegalArgumentException iae = new IllegalArgumentException();\n assertThat(e.getClass()).isEqualTo(iae.getClass());\n }\n }" ]
[ "0.62869036", "0.6284216", "0.62156916", "0.59294254", "0.5902688", "0.58772016", "0.58185077", "0.5729531", "0.5667329", "0.56584466", "0.5612834", "0.55805576", "0.5578763", "0.55704564", "0.55659467", "0.55300814", "0.5529113", "0.55020595", "0.5495706", "0.5482351", "0.54750186", "0.54668397", "0.5460583", "0.54598635", "0.5421271", "0.5414132", "0.54133344", "0.540824", "0.53969747", "0.53655225", "0.53531003", "0.53491116", "0.53301007", "0.5325268", "0.53197217", "0.53039587", "0.5298317", "0.52798545", "0.5267809", "0.52606255", "0.52604085", "0.5259092", "0.5254128", "0.5235255", "0.523359", "0.52274746", "0.5220206", "0.5205901", "0.5196875", "0.5195957", "0.5194015", "0.519063", "0.51807725", "0.5179431", "0.5178023", "0.51720935", "0.51461625", "0.5141944", "0.5135365", "0.5134503", "0.5134423", "0.51313615", "0.5130318", "0.5120604", "0.5114863", "0.5106046", "0.51039004", "0.51028466", "0.5101745", "0.509609", "0.5093169", "0.5092093", "0.5092043", "0.50700706", "0.506668", "0.50544053", "0.50523967", "0.5049455", "0.5046901", "0.5043882", "0.5037745", "0.5035183", "0.5034558", "0.5002605", "0.49939775", "0.49936932", "0.499264", "0.49885195", "0.498641", "0.49672914", "0.4961686", "0.49607626", "0.49557564", "0.49528906", "0.49518642", "0.49472278", "0.49417356", "0.49414834", "0.49410093", "0.49372202" ]
0.8168979
0
Test of findByUsername method, of class ForumThreadDAOImpl.
@Test public void testFindByUsername() { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@NotNull TUser findByUserName(String username) throws NotFoundException, ErrorConnectionException, TException;", "@Test\n\tpublic void FindUserByUsername() {\n\n\t\tUser user = new User(\"moviewatcher\", \"$2a$10$37jGlxDwJK4mRpYqYvPmyu8mqQJfeQJVSdsyFY5UNAm9ckThf2Zqa\", \"USER\");\n\t\tuserRepository.save(user);\n\t\t\n\t\tString username = user.getUsername();\n\t\tUser user4 = userRepository.findByUsername(username);\n\t\n\t\tassertThat(user4).isNotNull();\n\t\tassertThat(user4).hasFieldOrPropertyWithValue(\"username\", \"moviewatcher\");\n\t\t\n\t}", "User findByUsername(String username) throws UserDaoException;", "@Test\n public void test_getByUsername_1() throws Exception {\n clearDB();\n\n User res = instance.getByUsername(\"not_exist\");\n\n assertNull(\"'getByUsername' should be correct.\", res);\n }", "@Test\r\n public void testDGetByUserName() {\r\n System.out.println(\"getByUserName\");\r\n \r\n String userName = \"admin\";\r\n UsuarioDao instance = new UsuarioDao();\r\n Usuario result = instance.getByUserName(userName);\r\n \r\n assertNotNull(result);\r\n }", "@Test\n public void testFindByLogin() throws Exception {\n String userName = String.valueOf(databaseTester.getConnection().createDataSet().getTable(\"User\")\n .getValue(0, \"login\"));\n// User user = jdbcUserDao.findByLogin(userName);\n// assertNotNull(\"Should find user by login\", user);\n }", "User findByUsername(String username) throws DataAccessException;", "@Test\n @Transactional\n public void testFindByCategory() {\n\n List<ForumThread> forumThreads = new ArrayList<>();\n forumThreads = forumThreadDAO.findByCategory(\"NEWS\");\n\n logger.info(\"Forum Threads: -> {}\", forumThreads.toString());\n }", "@Test\n\tpublic void testUserServiceUsername() {\n\t\twhen(uDAO.selectByName(anyString())).thenReturn(testEmployee);\n\t\t\n\t\tassertEquals(new UserService(uDAO).getByUsername(\"user1\"), testEmployee);\n\t}", "@Test\n\tvoid shouldFindUserWithCorrectUsername() throws Exception {\n\t\tUser user = this.userService.findUserByUsername(\"antonio98\");\n\t\tAssertions.assertThat(user.getUsername()).isEqualTo(\"antonio98\");\n\t}", "@Override\r\n\tpublic User findUserByUsername(String username) {\n\t\tSystem.out.println(\"aa\");\r\n\t\treturn dao.selectUserByUsername(username);\r\n\t}", "public User readByUsername(String username) throws DaoException;", "public User findByUserName(String username) throws Exception;", "@Test\n public void test_getByUsername_3() throws Exception {\n User user1 = createUser(1, false);\n\n User res = instance.getByUsername(user1.getUsername());\n\n assertEquals(\"'getByUsername' should be correct.\", user1.getUsername(), res.getUsername());\n assertEquals(\"'getByUsername' should be correct.\", user1.getDefaultTab(), res.getDefaultTab());\n assertEquals(\"'getByUsername' should be correct.\", user1.getNetworkId(), res.getNetworkId());\n assertEquals(\"'getByUsername' should be correct.\", user1.getRole().getId(), res.getRole().getId());\n assertEquals(\"'getByUsername' should be correct.\", user1.getFirstName(), res.getFirstName());\n assertEquals(\"'getByUsername' should be correct.\", user1.getLastName(), res.getLastName());\n assertEquals(\"'getByUsername' should be correct.\", user1.getEmail(), res.getEmail());\n assertEquals(\"'getByUsername' should be correct.\", user1.getTelephone(), res.getTelephone());\n assertEquals(\"'getByUsername' should be correct.\", user1.getStatus().getId(), res.getStatus().getId());\n }", "Login findByUserName (String username);", "@Override\r\n\tpublic User findByUsername(String username) throws SQLException {\n\t\tUserDao userDao = (UserDao) BeanFactory.getBean(\"userDao\");\r\n\t\treturn userDao.findByUsername(username);\r\n\t}", "@Test\n public void test_getByUsername_2() throws Exception {\n User user1 = createUser(1, true);\n\n User res = instance.getByUsername(user1.getUsername());\n\n assertNull(\"'getByUsername' should be correct.\", res);\n }", "@Override\n\tpublic void findUserByUsername(String username) {\n\n\t}", "User findByUsername(String username, String password) throws Exception;", "@Test\n public void testGetUser() throws Exception {\n //tests that the given user is in the database\n //by feeding the query a preset name, in this case,\n //\"Thomas\" and verifying that it returns the same name\n System.out.println(\"getUser\");\n Connection conn = DriverManager.getConnection(\"jdbc:mysql://localhost/users\", \"root\", \"tech\");\n Statement stmt= (Statement) conn.createStatement();\n sql = \"SELECT * FROM user WHERE userName='\"+uName+\"'\";\n rs = stmt.executeQuery(sql);\n while (rs.next()){\n assertTrue(rs.getString(\"userName\").equals(uName));\n assertFalse(rs.getString(\"userName\").equals(\"thuff\"));\n //u.testLogonSuccses();\n //assertTrue(u.uName.equals(uName)); \n }\n //u.testLogonSuccses();\n }", "User findByUsername(String userName);", "@Test\n\tpublic void testFindByFirstName() throws Exception {\n\t\tOptional<User> user = users.findByUsername(\"agooniaOn\");\n\t\tassert user.isPresent();\n\t\tassert user.get().equals(ago);\n\t}", "@Override\n\tpublic User findByName(String username) {\n\t\treturn userDao.findByName(username);\n\t}", "@Override\n public List<User> findByName(String username){\n try {\n return runner.query(con.getThreadConnection(),\"select * from user where username like ?\",new BeanListHandler<User>(User.class),username);\n } catch (SQLException e) {\n System.out.println(\"执行失败\");\n throw new RuntimeException(e);\n }\n }", "User findByUsername(String username);", "User findByUsername(String username);", "User findByUsername(String username);", "User findByUsername(String username);", "User findByUsername(String username);", "User findByUsername(String username);", "@Test\n public void testSysUser() {\n\n SysUser user = sysUserService.findByUsername(\"admin\");\n System.out.println(\"user: \" + user);\n }", "User findUserByUsername(String username);", "public User findByUsername(String username);", "public User findByUsername(String username);", "public User findByUsername(String username);", "public User findByUsername(String username);", "public User getUserByUsername(String username);", "public User getUserByUserName(String username);", "private void testUserName(){\r\n\t\t//get user with the 'test' userName\r\n\t\tString command = \"SELECT userName FROM users \"\r\n\t\t\t\t+ \"WHERE userName = \\\"\" + commandList.get(1) + \"\\\";\";\r\n\t\tSystem.out.println(command);//print command\r\n\t\ttry {//send command\r\n\t\t\trs = stmt.executeQuery(command);\r\n\t\t\t\r\n\t\t\tif(rs.next()){//if it returns user, userName exists\r\n\t\t\t\tout.println(\"exists\");\r\n\t\t\t} else {//no results returned, empty\r\n\t\t\t\tout.println(\"free\");\r\n\t\t\t}\r\n\t\t} catch (SQLException e) {\r\n\t\t\t// TODO Auto-generated catch block\r\n\t\t\te.printStackTrace();\r\n\t\t\tout.println(e.getMessage());//send back error message\r\n\t\t}\r\n\t\t\r\n\r\n\t}", "User getByUsername(String username);", "public BlogUser getUserByNick(String nick) throws DAOException;", "public User getSpecificUser(String username);", "@Test\n\tvoid shouldFindUserWithIncorrectUsername() throws Exception {\n\t\tUser user = this.userService.findUserByUsername(\"antonio98\");\n\t\tAssertions.assertThat(user.getUsername()).isNotEqualTo(\"fernando98\");\n\t}", "public SecurityUser findByName(String username);", "User getUserByUsername(String username);", "User getUserByUsername(String username);", "User getUserByUsername(String username);", "public void testFindUserByName() throws Exception\r\n {\r\n createUser(\"testFindUserByName\");\r\n\r\n // try to find existed user\r\n User u = uHandler.findUserByName(\"demo\");\r\n\r\n assertNotNull(u);\r\n assertEquals(\"demo@localhost\", u.getEmail());\r\n assertEquals(\"Demo\", u.getFirstName());\r\n assertEquals(\"exo\", u.getLastName());\r\n assertEquals(\"demo\", u.getUserName());\r\n assertTrue(u.isEnabled());\r\n\r\n // try to find a non existing user. We are supposed to get \"null\" instead of Exception.\r\n try\r\n {\r\n assertNull(uHandler.findUserByName(\"not-existed-user\"));\r\n }\r\n catch (Exception e)\r\n {\r\n fail(\"Exception should not be thrown\");\r\n }\r\n try\r\n {\r\n assertNull(uHandler.findUserByName(\"not-existed-user\", UserStatus.ENABLED));\r\n }\r\n catch (Exception e)\r\n {\r\n fail(\"Exception should not be thrown\");\r\n }\r\n try\r\n {\r\n assertNull(uHandler.findUserByName(\"not-existed-user\", UserStatus.DISABLED));\r\n }\r\n catch (Exception e)\r\n {\r\n fail(\"Exception should not be thrown\");\r\n }\r\n try\r\n {\r\n assertNull(uHandler.findUserByName(\"not-existed-user\", UserStatus.BOTH));\r\n }\r\n catch (Exception e)\r\n {\r\n fail(\"Exception should not be thrown\");\r\n }\r\n\r\n assertNotNull(uHandler.findUserByName(\"testFindUserByName\"));\r\n assertTrue(uHandler.findUserByName(\"testFindUserByName\").isEnabled());\r\n assertNotNull(uHandler.findUserByName(\"testFindUserByName\", UserStatus.ENABLED));\r\n assertTrue(uHandler.findUserByName(\"testFindUserByName\", UserStatus.ENABLED).isEnabled());\r\n assertNotNull(uHandler.findUserByName(\"testFindUserByName\", UserStatus.BOTH));\r\n assertTrue(uHandler.findUserByName(\"testFindUserByName\", UserStatus.BOTH).isEnabled());\r\n\r\n boolean unsupportedOperation = false;\r\n try\r\n {\r\n // Disable the user testFindUserByName\r\n uHandler.setEnabled(\"testFindUserByName\", false, true);\r\n\r\n // We should not find the user testFindUserByName anymore from the normal method\r\n assertNull(uHandler.findUserByName(\"testFindUserByName\"));\r\n assertNull(uHandler.findUserByName(\"testFindUserByName\", UserStatus.ENABLED));\r\n // We should find it using the method that includes the disabled user account\r\n assertNotNull(uHandler.findUserByName(\"testFindUserByName\", UserStatus.BOTH));\r\n assertFalse(uHandler.findUserByName(\"testFindUserByName\", UserStatus.BOTH).isEnabled());\r\n // We should find it using the method that queries only the disabled user account\r\n assertNotNull(uHandler.findUserByName(\"testFindUserByName\", UserStatus.DISABLED));\r\n assertFalse(uHandler.findUserByName(\"testFindUserByName\", UserStatus.DISABLED).isEnabled());\r\n\r\n // Enable the user testFindUserByName\r\n uHandler.setEnabled(\"testFindUserByName\", true, true);\r\n\r\n // We should find it again whatever the value of the parameter status\r\n assertNotNull(uHandler.findUserByName(\"testFindUserByName\"));\r\n assertTrue(uHandler.findUserByName(\"testFindUserByName\").isEnabled());\r\n assertNotNull(uHandler.findUserByName(\"testFindUserByName\", UserStatus.ENABLED));\r\n assertTrue(uHandler.findUserByName(\"testFindUserByName\", UserStatus.ENABLED).isEnabled());\r\n assertNotNull(uHandler.findUserByName(\"testFindUserByName\", UserStatus.BOTH));\r\n assertTrue(uHandler.findUserByName(\"testFindUserByName\", UserStatus.BOTH).isEnabled());\r\n // We should not find the user using the method that queries only the disabled user account\r\n assertNull(uHandler.findUserByName(\"testFindUserByName\", UserStatus.DISABLED));\r\n }\r\n catch (UnsupportedOperationException e)\r\n {\r\n // This operation can be unsupported\r\n unsupportedOperation = true;\r\n }\r\n\r\n // Remove the user testFindUserByName\r\n uHandler.removeUser(\"testFindUserByName\", true);\r\n\r\n // try to find a user that doesn't exist anymore. We are supposed to get \"null\" instead of Exception.\r\n try\r\n {\r\n assertNull(uHandler.findUserByName(\"testFindUserByName\"));\r\n }\r\n catch (Exception e)\r\n {\r\n fail(\"Exception should not be thrown\");\r\n }\r\n try\r\n {\r\n assertNull(uHandler.findUserByName(\"testFindUserByName\", UserStatus.ENABLED));\r\n }\r\n catch (Exception e)\r\n {\r\n fail(\"Exception should not be thrown\");\r\n }\r\n try\r\n {\r\n assertNull(uHandler.findUserByName(\"testFindUserByName\", UserStatus.DISABLED));\r\n }\r\n catch (Exception e)\r\n {\r\n fail(\"Exception should not be thrown\");\r\n }\r\n try\r\n {\r\n assertNull(uHandler.findUserByName(\"testFindUserByName\", UserStatus.BOTH));\r\n }\r\n catch (Exception e)\r\n {\r\n fail(\"Exception should not be thrown\");\r\n }\r\n\r\n // Check the listener's counters\r\n assertEquals(1, listener.preSaveNew);\r\n assertEquals(1, listener.postSaveNew);\r\n assertEquals(0, listener.preSave);\r\n assertEquals(0, listener.postSave);\r\n assertEquals(unsupportedOperation ? 0 : 2, listener.preSetEnabled);\r\n assertEquals(unsupportedOperation ? 0 : 2, listener.postSetEnabled);\r\n assertEquals(1, listener.preDelete);\r\n assertEquals(1, listener.postDelete);\r\n }", "@Override\r\n\tpublic User findByUsername(String username) {\n\t\treturn userDAO.findByUsername(username);\r\n\t}", "@Test(expected = IllegalArgumentException.class)\n public void test_getByUsername_usernameNull() throws Exception {\n instance.getByUsername(null);\n }", "public User getUserByName(String username);", "public User getUserByName(String username);", "@Test\n public void testGetForumByID() {\n try {\n ForumDTO forumDTO = forumService.getForumWithID(FORUM_ID);\n assertEquals(FORUM_ID, forumDTO.getId());\n assertEquals(USER_NAME, forumDTO.getAuthor().getUsername());\n assertEquals(FORUM_TITLE, forumDTO.getTitle());\n } catch (Exception e) {\n fail(e.getMessage());\n }\n }", "@Test\n\tpublic void shouldFindUserByLogin()\n\t{\n\t\tUserProfile user = new UserProfile();\n\t\tuser.setId(100);\n\t\tuser.setLogin(\"testUser\");\n\t\twhen(userDao.findUserByLogin(user.getLogin())).thenReturn(user);\n\t\t\n\t\tassertEquals(user, userService.findUserByLogin(user.getLogin()));\n\t}", "@Override\n public User findByUsername( String username ) {\n return this.userRepository.findByUsername( username );\n }", "public AgtUser findUserByName(String username);", "@Override\n\tpublic User findUserByUsername(String username) throws SQLException {\n User user = null;\n String sql = \"SELECT * FROM user WHERE username = ?\";\n \n connect();\n \n PreparedStatement statement = jdbcConnection.prepareStatement(sql);\n statement.setString(1, username);\n \n \n ResultSet resultSet = statement.executeQuery();\n \n while (resultSet.next()) {\n String usrname = resultSet.getString(\"username\");\n String pwd = resultSet.getString(\"password\");\n \n user = new User(usrname, pwd);\n }\n \n resultSet.close();\n statement.close();\n \n return user;\n\t}", "@Override\r\n\tpublic User getByUsername(String username) throws UsernameNotFoundException {\r\n\t\tQuery query = sessionfactory.getCurrentSession().createQuery(\"FROM User WHERE username = :username\");\r\n\t\tquery.setParameter(\"username\", username);\r\n\t\tUser user = (User) query.uniqueResult();\r\n\t\tif (user == null) {\r\n\t\t\tthrow new UsernameNotFoundException(\"User with username '\" + username + \"' does not exist.\");\r\n\t\t}\r\n\t\treturn user;\r\n\t}", "@Override\n @SuppressWarnings(\"unchecked\")\n public boolean checkExists(String username) throws DAOException{\n \n try{\n Session session = HibernateConnectionUtil.getSession();\n \n Criteria crit = session.createCriteria(UserProfile.class);\n crit.add(Restrictions.eq(\"username\", username));\n List<UserProfile> userList = crit.list();\n session.close();\n return !userList.isEmpty();\n }\n catch(HibernateException e){\n throw new DAOException(\"HibernateException: \" + e.getMessage());\n }\n\n }", "@Override\n\tpublic Login findByUsername(String username) throws LoginNotFoundException {\n\t\treturn userRepo.findByUsername(username).orElseThrow(()->new LoginNotFoundException(\"User not found !\"));\n\t}", "User loadUser( String username ) throws UserNotFoundException;", "@Override\n public User getUserByUsername(String name) {\n \tSession session = this.sessionFactory.getCurrentSession(); \n \tQuery query = session.createQuery(\"from User where username=:username\");\n\t\tquery.setParameter(\"username\", name);\n\t\tUser u = (User) query.uniqueResult();\n logger.info(\"User loaded successfully, User details=\"+u);\n return u;\n }", "@Override\n @Query(\"SELECT u FROM User u WHERE u.login = LOWER(:username)\")\n User loadUserByUsername(@Param(\"username\") String username) throws UsernameNotFoundException;", "@Test\n public void userExist() {\n String username = argument.substring(0, 15);\n boolean found = false;\n\n for(int i = 0; i<users.size(); i++){\n if(users.get(i).substring(0, 15).trim().toLowerCase().contains(username.trim().toLowerCase())){\n found = true;\n }\n }\n assertTrue(\"User Not Found\", found);\n }", "@Override\r\n\tpublic LoginUser selectByUsername(String username) {\n\t\tlogger.info(\"根据用户名获得用户对象...\");\r\n\t\tList<LoginUser> userList = loginUserDao.selectByUsername(username);\r\n\t\tif(null != userList && !userList.isEmpty() && userList.size() > 0){\r\n\t\t\treturn userList.get(0);\r\n\t\t}else{\r\n\t\t\treturn null;\r\n\t\t}\r\n\t}", "@Override\r\n\tpublic Users findByName(String username) {\n\t\t\r\n\t\tCriteria criteria=sessionFactory.getCurrentSession().createCriteria(Users.class);\r\n\t\t\r\n\t\tcriteria.add(Restrictions.eqOrIsNull(\"username\", username));\r\n\t\t\r\n\t\treturn (Users) criteria.uniqueResult();\r\n\t}", "User findByUserName(String userName);", "User findByUserName(String userName);", "@Override\n\tpublic User findByUsername(String username) {\n\t\treturn userDao.findByUsername(username);\n\t}", "@Test\n public void testFindUserById() {\n System.out.println(\"findUserById\");\n long userId = testUsers.get(0).getId();\n UserServiceImpl instance = new UserServiceImpl(passwordService);\n User expResult = testUsers.get(0);\n User result = instance.findUserById(userId);\n assertEquals(expResult.getEmail(), result.getEmail());\n }", "public User queryUserByUsername(String username);", "private Boolean findUser(String username){\n return usersDataBase.containsKey(username);\n }", "@Test\n public void testGetUserByNickname() {\n System.out.println(\"getUser test ---\");\n String nickname = \"test_name\";\n User expected = new User(null, nickname);\n instance.users.add(expected);\n User result = instance.getUserByNickname(nickname);\n assertTrue(result == expected);\n assertTrue(null == instance.getUserByNickname(nickname+nickname));\n }", "@Test\n public void usernameTestTrue (){\n Accounts test = null;\n test.createAccounts();\n test = Accounts.getByUsername(\"bob\");\n assertNotNull(test);\n }", "public static User findUserByName(String username) {\n\n User user = null;\n User targetUser = new User();\n IdentityMap<User> userIdentityMap = IdentityMap.getInstance(targetUser);\n\n String findUserByName = \"SELECT * FROM public.member \"\n + \"WHERE name = '\" + username + \"'\";\n\n PreparedStatement stmt = DBConnection.prepare(findUserByName);\n\n try {\n ResultSet rs = stmt.executeQuery();\n while(rs.next()) {\n user = load(rs);\n }\n DBConnection.close(stmt);\n rs.close();\n } catch (SQLException e) {\n System.out.println(\"Exception!\");\n e.printStackTrace();\n }\n if(user != null) {\n targetUser = userIdentityMap.get(user.getId());\n if(targetUser == null) {\n userIdentityMap.put(user.getId(), user);\n return user;\n }\n else\n return targetUser;\n }\n\n return user;\n }", "public User getUserByUserName(String userName);", "public boolean userNameExist(String username);", "@Override\n\tpublic User getByUserName(String username) {\n\t\tUser user = userDao.getByUserName(username);\n\t\treturn user;\n\t}", "public User getUser(String username);", "@Override\n\tpublic UserDetails loadUserByUsername(String arg0) throws UsernameNotFoundException {\n\t\tList <UserDetailsPojo> list=dao.getUserByName(arg0);\n\t\tif(list==null || list.size()==0){\t\t\n\t\tthrow new UsernameNotFoundException(\"No user available\");\n\t\t}\n\t\t\n\t\tUserDetailsPojo user=list.get(0);\n\t\t\n\t\treturn user;\n\t}", "@Test\n public void testGetForumByUser() {\n try {\n List<ForumDTO> forumDTOS = forumService.getForumsByUser(USER_ID);\n assertTrue(\n forumDTOS.stream()\n .map(ForumDTO::getId)\n .collect(Collectors.toSet())\n .contains(FORUM_ID)\n );\n assertTrue(\n forumDTOS.stream()\n .map(ForumDTO::getId)\n .collect(Collectors.toSet())\n .contains(FORUM_LOCKED_ID)\n );\n } catch (Exception e) {\n fail(e.getMessage());\n }\n }", "@Override\n\tpublic User findByUsername(String username) throws UserNotFoundException {\n\t\treturn userRepo.findById(username).orElseThrow(()->new UserNotFoundException(\"Sorry User with username \"+ username+ \" is not found\"));\n\t\t\n\t}", "User loadUserByUserName(String userName);", "boolean existsByUsername(String username);", "public boolean existsByUsername(String username);", "public boolean findbyUser(String username) {\n\t\tString sql=\"select username from SCOTT.USERS where USERNAME='\"+username+\"'\";\n\t\t\n\t\t Dbobj dj=new Dbobj();\n\t\t JdbcUtils jdbcu=new JdbcUtils();\n\t\t dj=jdbcu.executeQuery(sql);\n\t\t ResultSet rs=dj.getRs(); \n\t\t System.out.println(\"\"+sql);\t\n\t\t String t=\"\";\n\t\t try {\n\t\t\twhile(rs.next())\n\t\t\t\t{\n\t\t\t\t\tt=rs.getString(1);\n\t\t\t\t}\n\t\t} catch (NumberFormatException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t} catch (SQLException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t\t\n\t\t\n\t\t if (t.isEmpty()) {\n\t\t\t return false;\n\t\t }else{\n\t\t\t return true; \n\t\t }\n\t\t\n\t\t\n\t\t\n\t}", "public boolean isUsernameTaken(String username) throws Exception {\n DataBaseBroker dbb = new DataBaseBroker();\n dbb.loadDriver();\n dbb.establishConnection();\n boolean taken = dbb.isUsernameTaken(username);\n dbb.commit();\n dbb.closeConnection();\n return taken;\n }", "User get(String username) throws UserNotFoundException, SQLException;", "@Test(expected = IllegalArgumentException.class)\n public void test_getByUsername_usernameEmpty() throws Exception {\n instance.getByUsername(TestsHelper.EMPTY_STRING);\n }", "@Test\n public void testAddForum() {\n User user = new User();\n user.setId(USER_ID);\n user.setUserName(USER_NAME);\n user.setEmail(USER_EMAIL);\n user.setPassword(USER_PASSWORD);\n\n try {\n ForumDTO forumDTO = forumService.addForum(FORUM_TITLE, user);\n assertEquals(USER_NAME, forumDTO.getAuthor().getUsername());\n assertEquals(FORUM_TITLE, forumDTO.getTitle());\n assertTrue(forumDTO.getSubscribers().stream()\n .map(UserDTO::getUsername)\n .collect(Collectors.toSet())\n .contains(USER_NAME)\n );\n } catch (Exception e) {\n fail(e.getMessage());\n }\n }", "@Override\n\tpublic User findUserByUserName(String userName) throws Exception {\n\t\treturn userDao.findUserByUserName(userName);\n\t}", "public Utente containUsername(String username) {\r\n \t\r\n \tfor(Utente ut: utenti) {\r\n \t\tString us=ut.getUsername();\r\n \t\tif(us.equals(username)) {\r\n \t\t\treturn ut;\r\n \t\t}\r\n \t}\r\n \t\r\n \treturn null;\r\n \t\r\n }", "User getUser(String username);", "@Transactional\n public User loadByUsername(String username) throws UsernameNotFoundException {\n User user = userRepository.findByUsername(username)\n .orElseThrow(() -> new UsernameNotFoundException(\"User not found with username : \" + username));\n\n checkForUnconfirmedAccount(user);\n\n validateLoginAttempt(user);\n return user;\n }", "public User findByUserName(String userName) {\n logger.log(Level.INFO, \"suppp it works\");\n List<User> users = entityManager.createNamedQuery(User.FIND_BY_USERNAME)\n .setParameter(\"userName\", userName)\n .getResultList();\n if (users.isEmpty()) {\n return null;\n }\n return users.get(0);\n }", "public Boolean isUsernameExist(String username);", "public Users findByUsername(String username) {\n\tthis.createConnection();\n\n try {\n Connection con = this.getCon();\n \tPreparedStatement stmnt = con.prepareStatement(this.getAllQuery() + \" where username=?;\");\n stmnt.setString(1, username);\n ResultSet rs = stmnt.executeQuery();\n return get(rs);\n } catch (SQLException e) {\n System.out.println(\"SQLException: \" + e.getErrorCode() + \":\" + e.getMessage());\n return new Users();\n }\n }", "public User searchByUsername(String username)\n {\n String query = \"SELECT * FROM user WHERE username = ?\";\n RowMapper<User> userRowMapper = new BeanPropertyRowMapper<>(User.class); // a collection type that holds the results of the query\n User user; // list of users that will be returned\n try\n {\n user = template.queryForObject(query, userRowMapper, username); // call the database and assign the results to the userList\n } catch (EmptyResultDataAccessException e)\n {\n user = null; // return null\n }\n return user;\n }", "public User getByUsername(Connection conn, String username) throws Exception {\n \n User resultUser = null;\n String sql = \"select * from jaltantra_users where username=?\";\n PreparedStatement ps = conn.prepareStatement(sql);\n ps.setString(1, username);\n ResultSet rs = ps.executeQuery();\n if(rs.next()) {\n resultUser = new User();\n //resultUser.setId(rs.getInt(\"id\"));\n resultUser.setUsername(rs.getString(\"username\"));\n resultUser.setPassword(rs.getString(\"password\"));\n }\n return resultUser;\n }", "@Test(dataProvider = \"getTestData\", priority = 4,alwaysRun = true)\n\tpublic void verifyUserNameTest(String userName, String passWord) {\n\t\tHomePage homePage = page.getInstance(LoginPage.class).loginSuccess(ExcelReader.getExcelData(0, 1, 0),\n\t\t\t\tExcelReader.getExcelData(0, 1, 1));\n\t\tString homePageHeader = homePage.homePageHeader();\n\t\tlogger.info(\"HomePage header is: \" + homePageHeader);\n\t\tAssert.assertEquals(homePageHeader, \"Welcome Admin\");\n\t\tContactsPage contactsPage = page.getInstance(HomePage.class).userManagementSearch(\"hannah.flores\");\n\t\t\n\t}" ]
[ "0.6544945", "0.65396315", "0.6526439", "0.64335406", "0.63736516", "0.63187486", "0.62960136", "0.6283056", "0.62297547", "0.62284565", "0.6178741", "0.6087071", "0.60778975", "0.6074943", "0.60405505", "0.596785", "0.5962425", "0.589347", "0.58787775", "0.58697903", "0.5862216", "0.5845399", "0.58385617", "0.5838046", "0.5835661", "0.5835661", "0.5835661", "0.5835661", "0.5835661", "0.5835661", "0.5828979", "0.5826329", "0.58142716", "0.58142716", "0.58142716", "0.58142716", "0.58133113", "0.58101124", "0.5805767", "0.5781104", "0.57578737", "0.57502776", "0.5734847", "0.5731744", "0.5716931", "0.5716931", "0.5716931", "0.5682949", "0.56785196", "0.56669635", "0.5662679", "0.5662679", "0.56317914", "0.56305933", "0.56168544", "0.5614955", "0.5599932", "0.5596654", "0.5592703", "0.55852985", "0.5578873", "0.5551905", "0.554774", "0.5542307", "0.5534441", "0.5520151", "0.5511522", "0.5511522", "0.5494562", "0.5478963", "0.5478243", "0.5472326", "0.5469748", "0.5469046", "0.54557186", "0.5451613", "0.5431825", "0.5429608", "0.54252785", "0.5424323", "0.5424103", "0.5413884", "0.5407734", "0.5403867", "0.54012483", "0.5393691", "0.53914344", "0.5390459", "0.53786737", "0.5374519", "0.5365426", "0.5361588", "0.5351908", "0.5339556", "0.5328748", "0.53247637", "0.5321293", "0.53199565", "0.5313156", "0.5308676" ]
0.601886
15
Test of create method, of class ForumThreadDAOImpl.
@Test public void testCreate() { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Test\r\n public void testCreate() {\r\n ActivityRecord record = setActivityRecord();\r\n recordDao.create(record);\r\n assertNotNull(record.getId());\r\n }", "@Test\n\tpublic void createTicketTest() {\n\t\tService.createTicket(new TicketCreation(), \"username\");\n\t\tMockito.verify(TicketDao, times(1)).createTicket(Mockito.any(TicketCreation.class), Mockito.anyString());\n\t}", "public void createThread() {\n }", "@Test\n public void createPost() {\n User bob = new User(\"Jasdeep\",\"Madan\",\"JD\",\"[email protected]\",\"password\", \"member\", true, true).save();\n\n //Create a new Category and save it\n Category category = new Category(\"Tech\", \"Some Description\").save();\n\n // Create a new post\n new Article(\"My first post\", \"Hello world\", bob, category, true, null, null).save();\n\n // Test that the post has been created\n assertEquals(1, Article.count());\n\n // Retrieve all posts created by Bob\n List<Article> bobPosts = Article.find(\"byAuthor\", bob).fetch();\n\n // Tests\n assertEquals(1, bobPosts.size());\n Article firstPost = bobPosts.get(0);\n assertNotNull(firstPost);\n assertEquals(bob, firstPost.author);\n assertEquals(\"My first post\", firstPost.title);\n assertEquals(\"Hello world\", firstPost.content);\n assertNotNull(firstPost.submit_date);\n }", "@RequestMapping(value = \"/threads\",\n method = RequestMethod.POST,\n produces = MediaType.APPLICATION_JSON_VALUE)\n @Timed\n @ResponseStatus(HttpStatus.CREATED)\n @ApiOperation(value = \"Create a new thread\")\n public Thread create(@RequestBody Thread thread) throws KalipoException {\n log.debug(\"REST request to save Thread : {}\", thread);\n\n if (thread.getId() == null) {\n return threadService.create(thread);\n } else {\n return threadService.update(thread);\n }\n }", "@Test\n @Transactional\n public void testFindByCategory() {\n\n List<ForumThread> forumThreads = new ArrayList<>();\n forumThreads = forumThreadDAO.findByCategory(\"NEWS\");\n\n logger.info(\"Forum Threads: -> {}\", forumThreads.toString());\n }", "@Test\n public void test1Insert() {\n\n System.out.println(\"Prueba de SpecialityDAO\");\n SpecialityFactory factory = new MysqlSpecialityDAOFactry();\n SpecialityDAO dao = factory.create();\n assertEquals(dao.insert(spec), 1);\n \n }", "@Test\n public void testLockForum() {\n try {\n ForumDTO forumDTO = forumService.lockForum(FORUM_ID);\n assertTrue(forumDTO.isLocked());\n } catch (Exception e) {\n fail(e.getMessage());\n }\n }", "@Test\n public void createTest2() {\n User user = new User(\"[email protected]\", \"password\", \"name\");\n Post post = new Post(user, \"This is a test!\", \"This message # contains zero hashtags\");\n\n when(replyDao.DidUserReply(user, post)).thenReturn(false);\n replyService.create(user, post);\n\n verify(replyDao, atLeastOnce()).create(new Reply(user, post));\n }", "public interface TopicDao {\r\n public boolean create(Topic topic);\r\n}", "@Test(expected = ReplyException.class)\n public void createTest1() {\n User user = new User(\"[email protected]\", \"password\", \"name\");\n Post post = new Post(user, \"This is a test!\", \"This message # contains zero hashtags\");\n\n when(replyDao.DidUserReply(user, post)).thenReturn(true);\n replyService.create(user, post);\n verify(replyDao, never()).create(new Reply(user, post));\n }", "public abstract boolean create(T entity) throws SQLException;", "@Test\n\tpublic void testCreateTicketFail() {\n\t}", "public void create(){}", "@Test\n public void shouldCreateCase() {\n assertThat(DatabaseHelper.getCaseDao().queryForAll().size(), is(0));\n\n TestEntityCreator.createCase();\n\n // Assure that the case has been successfully created\n assertThat(DatabaseHelper.getCaseDao().queryForAll().size(), is(1));\n }", "@Test\n public void testDeleteForum() {\n try {\n ForumDTO forumDTO = forumService.deleteForum(FORUM_ID);\n assertEquals(FORUM_ID, forumDTO.getId());\n } catch (Exception e) {\n fail(e.getMessage());\n }\n }", "@Test\n public void testGetForumByID() {\n try {\n ForumDTO forumDTO = forumService.getForumWithID(FORUM_ID);\n assertEquals(FORUM_ID, forumDTO.getId());\n assertEquals(USER_NAME, forumDTO.getAuthor().getUsername());\n assertEquals(FORUM_TITLE, forumDTO.getTitle());\n } catch (Exception e) {\n fail(e.getMessage());\n }\n }", "@Override\r\npublic int create(Detalle_pedido d) {\n\treturn detalle_pedidoDao.create(d);\r\n}", "@Override\n public void create(T entity) throws SQLException {\n\n this.dao.create(entity);\n\n }", "public void testCtor1() {\r\n assertNotNull(\"Failed to create DbTimeEntryDAO instance.\", instance);\r\n }", "@Test\n public void testAddForum() {\n User user = new User();\n user.setId(USER_ID);\n user.setUserName(USER_NAME);\n user.setEmail(USER_EMAIL);\n user.setPassword(USER_PASSWORD);\n\n try {\n ForumDTO forumDTO = forumService.addForum(FORUM_TITLE, user);\n assertEquals(USER_NAME, forumDTO.getAuthor().getUsername());\n assertEquals(FORUM_TITLE, forumDTO.getTitle());\n assertTrue(forumDTO.getSubscribers().stream()\n .map(UserDTO::getUsername)\n .collect(Collectors.toSet())\n .contains(USER_NAME)\n );\n } catch (Exception e) {\n fail(e.getMessage());\n }\n }", "int createTicket(Ticket ticket, int userId);", "@org.junit.Test\r\n public void testCreate() {\r\n System.out.println(\"create\");\r\n ContactRequest Crequest = new ContactRequest(\"DN Verma\",\"[email protected]\",\"9006745345\",\"faizabad\");\r\n ContactDao instance = new ContactDao();\r\n List<ContactResponse> expResult = new ArrayList<ContactResponse>();;\r\n List<ContactResponse> result = instance.create(Crequest);\r\n expResult=instance.getSingleContact(\"[email protected]\");\r\n String s=\"Duplicate entry '[email protected]' for key 1\";\r\n if(!result.get(0).getMessage().equals(s))\r\n {\r\n assertEquals(expResult.get(0).getName(), result.get(0).getName());\r\n assertEquals(expResult.get(0).getEmail(), result.get(0).getEmail());\r\n assertEquals(expResult.get(0).getCity(), result.get(0).getCity());\r\n assertEquals(expResult.get(0).getContact(), result.get(0).getContact());\r\n }\r\n }", "@Test\n public void create1Test1() throws SQLException {\n manager = new TableServizioManager(mockDb);\n manager.create1(false,false,false,false,false,false,false);\n Servizio servizio = manager.retriveById(5);\n assertNotNull(servizio,\"Should return true if create Servizio\");\n }", "public void testContentCreationTest() {\n\t\tQuestion question = new Question(\"Q title test\", \"Q body test\", \"Q author id test\");\n\t\tAnswer answer = new Answer(\"A body test\", \"A author id test\");\n\t\tReply reply = new Reply(\"R body test\", \"R author id test\");\n\t\tUser user = new User();\n\t\t//adds the question of the topic to an array of saved questions\n\t\tquestion.addAnswer(answer);\n\t\tquestion.addReply(reply);\n\t\t//question.setFavourite(user);\n\t\t//answer.setFavourite(user);\n\t\tanswer.addReply(reply);\n\t\t//tests if answer added to question is correct\n\t\tassertTrue(question.getAnswerCount() == 1);\n\t\t//smoke test code reply and answers.\n\t\tassertTrue(question.getReplies().get(0).getId().equals(reply.getId()));\n\t\tassertTrue(question.getAnswers().get(0).equals(answer));\n\t}", "@Test\r\n public void UserServiceTest_Create()\r\n {\r\n User user = new User();\r\n user.setId(\"1234\");\r\n user.setName(\"ABCDEFG\");\r\n ArrayList<Role> roles = new ArrayList<>();\r\n roles.add(new Role(\"Presenter\"));\r\n user.setRoles(roles);\r\n user.setPassword(\"12345678\");\r\n \r\n UserService service = new UserService();\r\n \r\n try {\r\n service.createAUser(user);\r\n } catch (SQLException e) {\r\n fail();\r\n System.out.println(e);\r\n }\r\n UserServiceTest_Edit();\r\n UserServiceTest_Delete();\r\n }", "@Override\n\tpublic void create(Board board) throws Exception {\n\t\tdao.insert(board);\n\t}", "TD createTD();", "public void create() {\n\t\t\n\t}", "void create(Authority authority) throws ExTrackDAOException;", "@Test\n\tpublic void testCreatePostLive() throws Exception\n\t{\n\t}", "@Override\n\tpublic void create(Teacher teacher) {\n\t\tdao.create(teacher);\n\t}", "@Override\n\tpublic int createTicket(Booking_ticket bt) {\n\t\treturn btr.createTicket(bt);\n\t}", "public void shouldCreate() {\n }", "public boolean create() throws Exception {\n\t\treturn tableDao.create();\r\n\t}", "@Test\r\n public void testCreate() throws Exception {\r\n System.out.println(\"create\");\r\n Bureau obj = new Bureau(0,\"Test\",\"000000000\",\"\");\r\n BureauDAO instance = new BureauDAO();\r\n instance.setConnection(dbConnect);\r\n Bureau expResult = new Bureau(0,\"Test\",\"000000000\",\"\");\r\n Bureau result = instance.create(obj);\r\n \r\n assertEquals(\"sigles différents\",expResult.getSigle(), result.getSigle());\r\n assertEquals(\"tel différents\",expResult.getTel(), result.getTel());\r\n //etc\r\n assertNotEquals(\"id non généré\",expResult.getIdbur(),result.getIdbur());\r\n int idclient=result.getIdbur();\r\n obj=new Bureau(0,\"Test\",\"000000000\",\"\");\r\n try{\r\n Bureau result2 = instance.create(obj);\r\n fail(\"exception de doublon non déclenchée\");\r\n instance.delete(result2);\r\n }\r\n catch(SQLException e){}\r\n instance.delete(result);\r\n \r\n obj=new Bureau(0,\"Test2\",\"000000001\",\"\");\r\n try{\r\n Bureau result3 = instance.create(obj);\r\n fail(\"exception de code postal non déclenchée\");\r\n instance.delete(result3);\r\n }\r\n catch(SQLException e){}\r\n \r\n }", "@Test\n public void create1Test2() throws SQLException {\n manager = new TableServizioManager(mockDb);\n manager.create1(true,true,true,true,true,true,true);\n Servizio servizio = manager.retriveById(5);\n assertNotNull(servizio,\"Should return true if create Servizio\");\n }", "@Test\n public void createTimelistCatch(){\n userDAO.createUser(new User(\"dummy\", \"dummy\", 1));\n assertFalse(timeListResource.createTimeList(new TimeList(\"Dumbdummy, but it has way too long of a name. Seriously!\", 1990, 0, 60, 0, 0)));\n\n //clean up\n userDAO.removeUser((\"dummy\"));\n }", "@Test\r\n\tpublic void testAddServices(){\r\n\t\tblog = new Blog();\r\n\t\t\r\n\t\tblog.setBlogId(1);\r\n\t\tblog.setBlogName(\"techZealot\");\r\n\t blog.setBlogDescription(\"for technical skills\");\r\n\t\tblog.setBlogStatus(\"approved\");\r\n\t\tblog.setNoOfComments(10);\r\n\t\tblog.setNoOfLikes(10);\r\n\t\tblog.setNoOfViews(12);\r\n\t\tblog.setPostDate(LocalDate.parse(\"2017-04-21\"));\r\n\t\tblog.setUserId(1);\r\n\t\tblog.setUserName(\"bhavna\");\r\n\t\t\r\n\t\tassertEquals(\"Successfully added a product inside the table!\",true,blogDao.addBlog(blog));\r\n\t}", "@Test(expected = NullPointerException.class)\r\n public void createNewPostTest(){\r\n\r\n Post post = new Post();\r\n post.setUserId(2l);\r\n post.setCreatedAt(new GregorianCalendar(2015,5,8).getTime());\r\n post.setDescription(\"PEOPLE ARE BAD AT TAKING OVER FROM AUTONOMOUS CARS.\");\r\n post.setLikes(15);\r\n \r\n entityTransaction.begin();\r\n assertNull(\"Post ID must be null\" , post.getPostId());\r\n entityManager.persist(post);\r\n entityTransaction.commit(); \r\n\r\n post = new Post();\r\n post.setUserId(3000l);\r\n post.setCreatedAt(new GregorianCalendar(2016,5,8).getTime());\r\n post.setDescription(\"ROBOTIC FOOD DELIVERY IS ROLLING INTO THE UNITED STATES IN FEBRUARY.\");\r\n post.setLikes(115);\r\n \r\n entityTransaction.begin();\r\n entityManager.persist(post);\r\n entityTransaction.commit(); \r\n \r\n\r\n \r\n \r\n post = new Post();\r\n post.setUserId(1l);\r\n post.setCreatedAt(new GregorianCalendar(2015,5,7).getTime());\r\n post.setDescription(null);\r\n post.setLikes(5);\r\n \r\n if(post.getDescription()== null || post.getDescription().equals(\"\"))\r\n throw new NullPointerException();\r\n\r\n }", "@Test\n void insertSuccess() {\n User newUser = new User(\"testname\",\"testpass\",\"Test\",\"name\",\"[email protected]\");\n UserRoles newRole = new UserRoles(1, \"administrator\", newUser, \"testname\");\n int id = genericDAO.insert(newRole);\n assertNotEquals(0,id);\n UserRoles insertedRole = (UserRoles)genericDAO.getByID(id);\n assertEquals(\"administrator\", insertedRole.getRoleName(), \"role is not equal\");\n }", "@Test\n void insertWithTripSuccess() {\n String newUserFirst = \"Dave\";\n String newUserLast = \"Bowman\";\n String newUserEmail = \"[email protected]\";\n String newUserUname = \"dbowman1\";\n String newUserPassword = \"Supersecret2!\";\n String tripCityLoc = \"MILWWI\";\n int tripCount = 6;\n String tripRating = \"5\";\n String tripComment = \"Definitely worth a second look\";\n Date today = new Date();\n User newUser = new User(newUserFirst, newUserLast, newUserEmail, newUserUname, newUserPassword, today);\n //Usertrip newUserTrip = new Usertrip(newUser, tripCityLoc, tripCount, tripRating, tripComment, today);\n //newUser.addTrip(newUserTrip);\n //int id = dao.insert(newUser);\n //assertNotEquals(0, id);\n //User insertedUser = (User) dao.getById(id);\n //assertNotNull(insertedUser);\n //assertEquals(\"dbowman1\", insertedUser.getUserName());\n //assertEquals(1, insertedUser.getUsertrips().size());\n\n }", "@Test\n public void validUserCreation() {\n boolean success = this.userDAO.insertNewUser(testUser);\n\n Assertions.assertTrue(success);\n }", "void create(T entity) throws Exception;", "@Override\r\n\tpublic void create() {\n\t\t\r\n\t}", "@Override\r\n\tpublic boolean create(Moteur obj, Connection conn) throws SQLException {\n\t\treturn false;\r\n\t}", "@Test\r\n\tpublic void testCreate() {\r\n\t\tQuestion q = new Question(\"Empty\", 1, 20, quizzes, null, choices);\r\n\t\tdao.create(q);\r\n\t}", "@Test\n public void testStaffFactoryCreate() {\n StaffController staffController = staffFactory.getStaffController();\n staffController.addStaff(STAFF_NAME, STAFF_GENDER, STAFf_ROLE);\n assertEquals(1, staffController.getStaffList().size());\n }", "@Test\n public void testCRD() throws Exception{\n \tSubmissionFileHandleDBO handle = new SubmissionFileHandleDBO();\n \thandle.setSubmissionId(submissionId);\n \thandle.setFileHandleId(Long.parseLong(fileHandleId));\n \t\n // Create it\n SubmissionFileHandleDBO clone = dboBasicDao.createNew(handle);\n assertNotNull(clone);\n assertEquals(handle, clone);\n \n // Fetch it\n MapSqlParameterSource params = new MapSqlParameterSource();\n params.addValue(DBOConstants.PARAM_SUBFILE_SUBMISSION_ID, submissionId);\n params.addValue(DBOConstants.PARAM_SUBFILE_FILE_HANDLE_ID, fileHandleId);\n SubmissionFileHandleDBO clone2 = dboBasicDao.getObjectByPrimaryKey(SubmissionFileHandleDBO.class, params).get();\n assertNotNull(clone2);\n assertEquals(handle, clone2); \n \n // Delete it\n boolean result = dboBasicDao.deleteObjectByPrimaryKey(SubmissionFileHandleDBO.class, params);\n assertTrue(\"Failed to delete the entry created\", result); \n }", "@Test\n public void testDeleteMissingForum() {\n try {\n ForumDTO forumDTO = forumService.deleteForum(0);\n assertNull(forumDTO);\n } catch (Exception e) {\n fail(e.getMessage());\n }\n }", "@Test\n public void testCreate() throws Exception {\n System.out.println(\"create\");\n Connection con = ConnexionMySQL.newConnexion();\n Timestamp timestamp = stringToTimestamp(\"2020/01/17 08:40:00\");\n Inscription result = Inscription.create(con, \"[email protected]\", timestamp);\n Inscription ins = Inscription.getLast(con);\n assertEquals(ins.getMail(), \"[email protected]\");\n result.delete(con);\n }", "@Test\n public void testCreate() {\n User user = new User(\"lgn\", \"[email protected]\", \"Login Name\", \n \"12345678\");\n userService.create(user);\n }", "@Test\n public void testCreaAlumno() {\n System.out.println(\"creaAlumno\");\n Alumno alumno = new Alumno();\n alumno.setNombre(\"Dulce\");\n alumno.setApellido(\"Alvarado\");\n Alumno result = instance.creaAlumno(alumno);\n assertNotNull(result.getId());\n }", "@SmallTest\n public void testCreate() {\n int result = -1;\n if (this.entity != null) {\n Settings settings = SettingsUtils.generateRandom(this.ctx);\n\n result = (int)this.adapter.insert(settings);\n\n Assert.assertTrue(result >= 0);\n }\n }", "public TestTicket() {\n\t}", "public abstract void create(T t);", "@Test\n public void createTest() {\n reservationService.create(reservation1);\n Mockito.verify(reservationDao).create(reservation1);\n }", "@Test\r\n\t public void addANullRouteFather(){\r\n\t\t RouteFather test = routeFatherDAO.create(new RouteFather(null, null, null, null, null));\r\n\t\t Assert.assertNull(\"it should returns null\", test);\r\n\t }", "public T create(T object) throws SQLException;", "@Test\n public void testReservationFactoryCreate() {\n ReservationController reservationController = reservationFactory.getReservationController();\n Customer customer = new Customer(CUSTOMER_NAME, CUSTOMER_CONTACT, false);\n Calendar date = Calendar.getInstance();\n // create a 2 seater table // default is vacant\n tableFactory.getTableController().addTable(2);\n Table table = tableFactory.getTableController().getTable(1);\n reservationController.addReservation(date, customer, 2, table);\n assertEquals(1, reservationController.getReservationList().size());\n }", "@Test\n @Order(1)\n void TC_UTENTE_DAO_1()\n {\n\n /*creo uno username valido*/\n Utente utente = new Utente();\n utente.setUsername(\"utenteTest1\");\n utente.setPassword(\"password\");\n utente.setNome(\"Test\");\n utente.setCognome(\"Test\");\n utente.setNazionalità(\"italiana\");\n utente.setEmail(\"[email protected]\");\n UtenteDAO utenteDAO = new UtenteDAO();\n\n assertTrue(utenteDAO.doSave(utente));\n }", "@Test\n public void addArticle(){\n User user = userDao.load(3);\n Article article = new Article();\n article.setUser(user);\n// article.setTitle(\"1896\");\n articleDao.add(article);\n }", "@Test\r\n\t public void addANonExistingRouteFather(){\r\n\t\t RouteFather test = routeFatherDAO.create(new RouteFather(\"rutatest\", \"desctest\", \"asdfas\",\"2012-02-02\", this.rafter));\r\n\t\t Assert.assertNotNull(\"it should returns not null\", test);\r\n\t\t routeFatherDAO.delete(test);\r\n\t\t \r\n\t }", "@Test\n public void shouldCreateEpiDataTravel() {\n assertThat(DatabaseHelper.getEpiDataTravelDao().queryForAll().size(), is(0));\n\n Case caze = TestEntityCreator.createCase();\n TestEntityCreator.createEpiDataTravel(caze);\n\n // Assure that the burial has been successfully created\n assertThat(DatabaseHelper.getEpiDataTravelDao().queryForAll().size(), is(1));\n }", "@Test\n public void testCreate() {\n\n List<JDBCDataObject> classList = new ArrayList<>();\n classList.add(new EnrollmentDTO(0, 5, 1, null));\n\n List<Integer> ids = manageClass.create(classList);\n assertEquals(1, ids.size());\n\n }", "@Test\n public void testLockMissingThread() {\n ForumException thrown = assertThrows(ForumException.class,\n () -> forumService.lockForum(0));\n assertTrue(thrown.getMessage().contains(\"No such forum thread.\"));\n }", "@Test\r\n public void testCreateMethod() {\r\n DailyBudget budget = new DailyBudget();\r\n\r\n budget.setName(\"Test budget\");\r\n RequestBuilder requestBuilder = MockMvcRequestBuilders\r\n .post(\"/api/budget\")\r\n .characterEncoding(\"utf-8\")\r\n .accept(MediaType.APPLICATION_JSON)\r\n .contentType(MediaType.APPLICATION_JSON)\r\n .header(\"authorization\", authUtils.generateToken(testUser.getEmail()))\r\n .content(String.format(\"{%s: %s}\",\r\n getEnclosedString(\"id\"),\r\n getEnclosedString(testUser.getId().toString())));\r\n\r\n try {\r\n MvcResult result = mockMvc.perform(requestBuilder).andReturn();\r\n MockHttpServletResponse response = result.getResponse();\r\n BudgetRole createdRole;\r\n\r\n assertEquals(HttpStatus.CREATED.value(), response.getStatus());\r\n assertEquals(1, testRoles.size()); // make sure only one instance was created\r\n\r\n createdRole = testRoles.get(0);\r\n assertEquals(testUser, createdRole.getUser());\r\n assertEquals(BudgetRoleType.CREATOR.rank, createdRole.getRoleType().rank);\r\n }\r\n catch (Exception ex) {\r\n log.error(ex.getMessage());\r\n }\r\n }", "public IThread createThread() throws IllegalWriteException, BBException;", "@Test\n public void create2Test() throws SQLException {\n manager = new TableServizioManager(mockDb);\n manager.create2(false,true,false,true,false,false,true);\n Servizio servizio = manager.retriveById(5);\n assertNotNull(servizio,\"Should return true if create Servizio\");\n }", "@Override\r\n\tpublic void create() {\n\r\n\t}", "static void testSavingDAO() {\n }", "@Test\n void insertSuccess() {\n String name = \"Testing a new event\";\n LocalDate date = LocalDate.parse(\"2020-05-23\");\n LocalTime startTime = LocalTime.parse(\"11:30\");\n LocalTime endTime = LocalTime.parse(\"13:45\");\n String notes = \"Here are some new notes for my new event.\";\n GenericDao userDao = new GenericDao(User.class);\n User user = (User)userDao.getById(1);\n\n Event newEvent = new Event(name, date, startTime, endTime, notes, user);\n int id = genericDao.insert(newEvent);\n assertNotEquals(0,id);\n Event insertedEvent = (Event)genericDao.getById(id);\n assertEquals(newEvent, insertedEvent);\n }", "boolean create(User user) throws Exception;", "public void createMessage(int tid, int uid, int rank, String detail);", "@Test\n public void createEmployeeCatch() {\n userDAO.createUser(new User(\"dummy\", \"dummy\", 1));\n assertFalse(employeeResource.createEmployee(new Employee(\"notdummy\", \"dummy\", \"dummy\", \"dummy\", \"dummy\", 1)));\n\n //removing test data after tests to avoid clutter in database\n employeeDAO.removeEmployee(\"dummy\");\n userDAO.removeUser(\"dummy\");\n\n //test clean up\n assertNull(userResource.getUser(\"dummy\"));\n }", "@Override\n\tpublic void create() {\n\t\t\n\t}", "@Test\n\tpublic void testMessage() {\n\t\tUserModel exampleUser = new UserModel();\n\t\texampleUser.setUserId(\"@tester_6\");\n\t\texampleUser.setUserPseudo(\"Test_pseudo\");\n\t\texampleUser.setUserEmail(\"[email protected]\");\n\t\texampleUser.setUserPassword(\"0e3e75234abc68f4378a86b3f4b32a198ba301845b0cd6e50106e874345700cc6663a86c1ea125dc5e92be17c98f9a0f85ca9d5f595db2012f7cc3571945c123\");\n\t\texampleUser.setUserDate(new Date(new java.util.Date().getTime()));\n\t\texampleUser.setUserAdmin(true);\n\t\ttry {\n\t\t\tUserDatabaseManager.insertUser(exampleUser);\n\t\t} catch (SQLException e) {\n\t\t\te.printStackTrace();\n\t\t\tfail(\"Cannot insert a new user for board testing !\");\n\t\t}\n\n\t\t// Test a new board to make new message\n\t\tBoardModel newBoard = new BoardModel();\n\t\tnewBoard.setBoardName(\"test_board2\");\n\t\tnewBoard.setBoardCreatorId(\"@tester_6\");\n\t\tnewBoard.setBoardDescription(\"This is the test board of the test user\");\n\t\ttry {\n\t\t\tBoardDatabaseManager.insertBoard(newBoard);\n\t\t} catch (SQLException e) {\n\t\t\te.printStackTrace();\n\t\t\tfail(\"Cannot insert a new board !\");\n\t\t}\n\n\t\t// Test message insertion\n\t\tMessageModel message = new MessageModel();\n\t\tmessage.setMessageBoardName(\"test_board2\");\n\t\tmessage.setMessageDate(new Date(new java.util.Date().getTime()));\n\t\tmessage.setMessageId(\"1\");\n\t\tmessage.setMessagePosterId(\"@tester\");\n\t\tmessage.setMessageText(\"This is a test message\");\n\t\ttry {\n\t\t\tassertEquals(\"1\", MessageDatabaseManager.getNextRootMessageId());\n\t\t\tMessageDatabaseManager.insertMessage(message);\n\t\t\tassertEquals(\"2\", MessageDatabaseManager.getNextRootMessageId());\n\t\t} catch (MongoException e) {\n\t\t\te.printStackTrace();\n\t\t\tfail(\"Cannot insert a new message !\");\n\t\t} catch (SQLException e) {\n\t\t\te.printStackTrace();\n\t\t\tfail(\"Cannot add the message to the board !\");\n\t\t}\n\n\t\t// Test answer insertion\n\t\tMessageModel answer = new MessageModel();\n\t\tanswer.setMessageBoardName(\"test_board2\");\n\t\tanswer.setMessageDate(new Date(new java.util.Date().getTime()));\n\t\tanswer.setMessageId(message.getNextAnswerId());\n\t\tanswer.setMessagePosterId(\"@tester\");\n\t\tanswer.setMessageText(\"This is a test answer\");\n\t\ttry {\n\t\t\tMessageDatabaseManager.insertMessage(answer);\n\t\t} catch (MongoException e) {\n\t\t\te.printStackTrace();\n\t\t\tfail(\"Cannot insert an answer !\");\n\t\t} catch (SQLException e) {\n\t\t\te.printStackTrace();\n\t\t\tfail(\"Cannot add the message to the board !\");\n\t\t}\n\n\t\t// Test updating\n\t\tanswer.setMessageText(\"LOL\");\n\t\ttry {\n\t\t\tMessageDatabaseManager.updateMessage(answer);\n\t\t} catch (MongoException e) {\n\t\t\te.printStackTrace();\n\t\t\tfail(\"Cannot update a message\");\n\t\t}\n\n\t\t// Test getting\n\t\tMessageFilter filter = new MessageFilter();\n\t\tfilter.addMessageId(\"1.\");\n\t\tList<MessageModel> messages = MessageDatabaseManager.getMessage(filter, true, true);\n\t\tassertEquals(\"1.1\", messages.get(0).getMessageId());\n\t\tassertEquals(\"LOL\", messages.get(0).getMessageText());\n\t\t\n\n\t\t// Test deleting\n\t\tMessageModel answerAnswer = new MessageModel();\n\t\tanswerAnswer.setMessageId(answer.getNextAnswerId());\n\t\tanswerAnswer.setMessageText(\"This is an answer to an answer\");\n\t\tanswerAnswer.setMessageBoardName(newBoard.getBoardName());\n\t\tanswerAnswer.setMessagePosterId(exampleUser.getUserId());\n\t\tanswerAnswer.setMessageDate(new Date(new java.util.Date().getTime()));\n\t\t\n\t\tBoardFilter newBoardFilter = new BoardFilter();\n\t\tnewBoardFilter.addBoardName(newBoard.getBoardName());\n\t\t\n\t\tmessage.addAnwserId(\"1.1\");\n\t\tanswer.addAnwserId(\"1.1.1\");\n\t\ttry {\n\t\t\tMessageDatabaseManager.insertMessage(answerAnswer);\n\t\t\tassertEquals(3, MessageDatabaseManager.getMessage(new MessageFilter(), false, true).size());\n\t\t\t\n\t\t\tBoardModel board = BoardDatabaseManager.getBoards(newBoardFilter, false).get(0);\n\t\t\tassertEquals(1, board.getBoardMessagesId().size());\n\n\t\t\tMessageDatabaseManager.deleteMessage(message);\n\t\t\tassertEquals(0, MessageDatabaseManager.getMessage(new MessageFilter(), false, true).size());\n\n\t\t\tboard = BoardDatabaseManager.getBoards(newBoardFilter, false).get(0);\n\t\t\tassertEquals(0, board.getBoardMessagesId().size());\n\t\t} catch (MongoException e) {\n\t\t\te.printStackTrace();\n\t\t\tfail(\"Cannot delete message !\");\n\t\t} catch (SQLException e) {\n\t\t\te.printStackTrace();\n\t\t\tfail(\"Cannot delete the message from the BELONGS_TO_BOARD table !\");\n\t\t}\n\n\t}", "@Override\n\tpublic void create() {\n\n\t}", "@Test\n public void testCrearBibliotecario() {\n System.out.println(\"BibliotecaController\");\n String email = \"mail\";\n String login = \"login\";\n String password = \"pass\";\n String nif = \"nif\";\n BibliotecarioController instance = new BibliotecarioController();\n Bibliotecario result = instance.crearBibliotecario(email, login, password, nif);\n assertEquals(email, result.getEmail());\n assertEquals(login, result.getLogin());\n assertEquals(password, result.getPassword());\n assertEquals(nif , result.getNif());\n // TODO review the generated test code and remove the default call to fail.\n //fail(\"The test case is a prototype.\");\n }", "@Test\r\n\t public void addAnEmptyRouteFather(){\r\n\t\t RouteFather test = routeFatherDAO.create(new RouteFather());\r\n\t\t Assert.assertNull(\"it should returns null\", test);\r\n\t }", "@Override\n\tpublic Post createPost(Post post) {\n\t\treturn postDao.createPost(post);\n\t}", "@Test\n @Order(3)\n void TC_UTENTE_DAO_3()\n {\n /*creo uno username valido*/\n Utente utente=new Utente();\n UtenteDAO utenteDAO = new UtenteDAO();\n\n assertThrows(NullPointerException.class, ()->utenteDAO.doSave(utente));\n\n }", "Klassenstufe createKlassenstufe();", "public int createDBEntry() {\n\t\tint i = 0;\n\t\ttry {\n\t\t\tConnection con;\n\t\t\tcon = ConnectionUtil.getConnection();\n\t\t\tStatement statement = con.createStatement();\n\n\t\t\tStringBuffer strBuf = new StringBuffer();\n\t\t\tstrBuf.append(\"insert into Ticket(ticketID,\");\n\t\t\tstrBuf.append(\"ticketDate, \");\n\t\t\tstrBuf.append(\"bugTitle, \");\n\t\t\tstrBuf.append(\"bugDescription, \");\n\t\t\tstrBuf.append(\"bugCategory, \");\n\t\t\tstrBuf.append(\"projectName, \");\n\t\t\tstrBuf.append(\"projectVersion, \");\n\t\t\tstrBuf.append(\"assignedToDev, \");\n\t\t\tstrBuf.append(\"priority, \");\n\t\t\tstrBuf.append(\"status, \");\n\t\t\tstrBuf.append(\"comments, \");\n\t\t\tstrBuf.append(\"targetDueDate, \");\n\t\t\tstrBuf.append(\"ticketCreatedBy \");\t\n\t\t\tstrBuf.append(\") values (last_insert_id(), \");\n\t\t\tstrBuf.append(\"'\" + this.ticketDate + \"', \");\n\t\t\tstrBuf.append(\"'\" + this.bugTitle + \"', \");\t\t\t\t\n\t\t\tstrBuf.append(\"'\" + this.bugDescription + \"', \");\n\t\t\tstrBuf.append(\"'\" + this.bugCategory + \"', \");\n\t\t\tstrBuf.append(\"'\" + this.projectName + \"', \");\n\t\t\tstrBuf.append(\"'\" + this.projectVersion + \"', \");\n\t\t\tstrBuf.append(\"'\" + this.assignedToDevName + \"', \");\n\t\t\tstrBuf.append(\"'\" + this.ticketPriority + \"', \");\n\t\t\tstrBuf.append(\"'\" + this.ticketStatus + \"', \");\n\t\t\tstrBuf.append(\"'\" + this.comments + \"', \");\n\t\t\tstrBuf.append(\"'\" + this.targetDueDate + \"', \");\n\t\t\tstrBuf.append(\"'\" + this.TicketCreatedBy + \"'\");\n\t\t\tstrBuf.append(\")\");\n\n\t\t\ti = statement.executeUpdate(strBuf.toString());\t\t\n\t\t\t\n\t\t} catch (Exception e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn i;\n\t}", "@Test\n public void testInserirCliente() {\n \n \n System.out.println(\"inserirCliente\");\n \n Cliente novoCliente = null;\n ClienteDAO ins = new ClienteDAO();\n boolean expResult = false;\n boolean result = ins.inserirCliente(novoCliente);\n assertEquals(expResult, result);\n // TODO review the generated test code and remove the default call to fail.\n //fail(\"The test case is a prototype.\");\n }", "public Forum create(Forum forum) throws ForumNotValidException {\n try {\n Forum newForum = new Forum(forum.getForumName(), forum.getDescription(), forum.getForumAdminId(), forum.getPicture());\n newForum.setCreationDate(new Date().toString());\n forumRepository.save(newForum);\n System.out.println(\"New Forum created.\");\n return newForum;\n } catch (Exception e) {\n throw new ForumNotValidException();\n }\n }", "public void create(Post post) {\r\n jdbcOp.update(SQL_INSERT_TICKET,\r\n post.getCustomerName(),\r\n post.getSubject(), \r\n post.getBody(),\r\n post.getCategories());\r\n// for (String role : user.getRoles()) {\r\n// jdbcOp.update(SQL_INSERT_ROLE,\r\n// user.getUsername(),\r\n// role); \r\n }", "@Test\n\t@DatabaseSetup(value = \"classpath:databaseEntries.xml\", type = DatabaseOperation.CLEAN_INSERT)\n\tpublic void testCreateLecturer() {\n\t\t\n\t\t//Confirm table row count\n\t\tlecturerJdbcDaoSupport = (LecturerJdbcDaoSupport) autoWireContext.getBean(\"lecturerJdbcDaoSupport\");\n\t\tlecturerJdbcDaoSupport.createLecturer(\"L004\", \"Jim\", \"Murphy\", \"[email protected]\");\n\t\tint rowCount = lecturerJdbcDaoSupport.countRows();\n\t\tassertEquals(4, rowCount);\n\t}", "public void create(CategoriaDTO dto) throws SQLException{\n getConnection();\n CallableStatement callableStatement = null;\n \n try {\n callableStatement = (CallableStatement) connection.prepareCall(SQL_INSERT);\n callableStatement.setString(1, dto.getEntidad().getNombreCategoria());\n callableStatement.setString(2, dto.getEntidad().getDescripcionCategoria());\n callableStatement.executeUpdate(); // review\n } finally {\n if(callableStatement != null){\n callableStatement.close();\n }\n if(connection != null){\n connection.close();\n }\n }\n }", "@Test\n\tpublic void testInsertObj() {\n\t}", "public static void createTicket(Ticket ticket) {\n try {\n Connection conn = Main.conn;\n PreparedStatement statement = conn.prepareStatement(\"INSERT INTO bs_tickets (username, admin, status, question, server, date_created, date_accepted, date_resolved) VALUES (?, ?, ?, ?, ?, ?, ?, ?)\");\n\n statement.setString(1, ticket.username);\n statement.setString(2, ticket.admin);\n statement.setString(3, ticket.status);\n statement.setString(4, ticket.question);\n statement.setString(5, ticket.server);\n statement.setInt(6, ticket.date_created);\n statement.setInt(7, ticket.date_accepted);\n statement.setInt(8, ticket.date_resolved);\n\n statement.executeUpdate();\n }\n catch (SQLException e) {\n e.printStackTrace();\n }\n }", "@Test\n public void insertUserTest(){\n }", "private Forum newForum(long id) {\n\t\tForum forum = new Forum();\n\t\tforum.setId(id);\n\t\tforum.setName(\"forum\" + id);\n\t\tforum.setDescription(\"forum\" + id + \" description\");\n\t\treturn forum;\n\t}", "@Test\n public void createTimelist(){\n userDAO.createUser(new User(\"dummy\", \"dummy\", 1));\n assertTrue(timeListResource.createTimeList(new TimeList(\"dummy\", 1990, 0, 60, 0, 0)));\n\n //clean up\n timeListDAO.removeTimeList(1990, 0, \"dummy\");\n userDAO.removeUser((\"dummy\"));\n }", "@Test\n public void testInserirUsuarioNovo() throws Exception {\n Usuario usu = new Usuario();\n usu.setNome(\"Fulano3\");\n usu.setSenha(\"abcde\");\n Long valorAleatorio = System.currentTimeMillis();\n String username = valorAleatorio.toString();\n usu.setUsername(username);\n usu.setEmail(\"[email protected]\");\n System.out.println(\"inserirUsuarioNovo\");\n boolean validado = new UsuarioDAO().inserir(usu);\n int idInserido = usu.getIdusuario();\n assertEquals(validado, true);\n //testExcluir();\n }", "public void testGetBlogEntry() {\n DailyBlog dailyBlog = rootBlog.getBlogForToday();\n BlogEntry blogEntry = dailyBlog.createBlogEntry();\n dailyBlog.addEntry(blogEntry);\n String id = blogEntry.getId();\n assertNotNull(blogEntry);\n blogEntry = rootBlog.getBlogEntry(id);\n assertNotNull(blogEntry);\n assertEquals(id, blogEntry.getId());\n }", "void create(T t);", "void create(T entity);", "@Test\n public void insert() {\n// int insert = iUserDao.insert(u);\n// System.out.println(u);\n\n }", "public void create(Branch branch) {\n branch_dao.create(branch);\n }", "@Test\n\tpublic void testPostNewMessageThenTheDatabaseContainsAMessageWithSameIdAsPosted() throws Exception{\n\t\tString postedId = \n\t\t this.restTemplate\n\t\t\t.postForObject(this.url, \n\t\t\t\t\tnew DummyBoundary(\"???\", \"test\"),\n\t\t\t\t\tDummyBoundary.class)\n\t\t\t.getId();\n\t\t\n\t\t// THEN the database contains a single message with same id as posted\n\t\tString actualId = \n\t\t this.restTemplate\n\t\t\t.getForObject(this.url + \"/{id}\", DummyBoundary.class, postedId)\n\t\t\t.getId();\n\t\t\n\t\tassertThat(actualId)\n\t\t\t.isNotNull()\n\t\t\t.isEqualTo(postedId);\n\t}" ]
[ "0.6264427", "0.62308943", "0.6070488", "0.60551196", "0.5905651", "0.58611405", "0.585856", "0.58146036", "0.58049875", "0.5793619", "0.5789297", "0.57886976", "0.5753254", "0.57530224", "0.57337123", "0.57120883", "0.5695835", "0.56506526", "0.56479347", "0.564779", "0.56347764", "0.5623246", "0.56188303", "0.56178933", "0.56066614", "0.5574943", "0.55733263", "0.5568136", "0.55558825", "0.5543251", "0.5540672", "0.55389524", "0.55348676", "0.5529652", "0.5526423", "0.55242175", "0.5517683", "0.54897684", "0.54897195", "0.54889137", "0.54818493", "0.54806495", "0.5475391", "0.5470466", "0.54691833", "0.54673886", "0.5466345", "0.5453095", "0.54514754", "0.54510725", "0.54403174", "0.5440125", "0.543657", "0.54306173", "0.5423134", "0.54040533", "0.5375527", "0.53675973", "0.53643894", "0.53596675", "0.5358069", "0.53580546", "0.5347015", "0.5341947", "0.5338131", "0.53281766", "0.5326939", "0.5326663", "0.5322023", "0.53172255", "0.53002626", "0.5299399", "0.5292207", "0.5281953", "0.5279032", "0.5277646", "0.527725", "0.527033", "0.52591974", "0.5258081", "0.52553904", "0.5251955", "0.524848", "0.5244266", "0.52426124", "0.52381915", "0.5234449", "0.5232935", "0.5226025", "0.52253735", "0.52186453", "0.5215526", "0.5215438", "0.52130324", "0.5208433", "0.52031106", "0.52031016", "0.5199255", "0.51982117", "0.51948583", "0.51932466" ]
0.0
-1
Test of update method, of class ForumThreadDAOImpl.
@Test public void testUpdate() { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Test\n public void testUpdateForum() {\n String newTitle = \"New title!\";\n try {\n ForumDTO forumDTO = forumService.updateForum(FORUM_ID, newTitle);\n assertEquals(newTitle, forumDTO.getTitle());\n } catch (Exception e) {\n fail(e.getMessage());\n }\n }", "@Test\r\n public void testBUpdate() throws Exception {\r\n System.out.println(\"update\");\r\n \r\n UsuarioDao instance = new UsuarioDao();\r\n \r\n Usuario obj = instance.login(\"admin\", \"admin\");\r\n obj.setFullName(\"Kevin Duran\");\r\n \r\n int expResult = 1;\r\n int result = instance.update(obj);\r\n assertEquals(expResult, result);\r\n }", "@Test\r\n public void testUpdate() {\r\n System.out.println(\"update\");\r\n Title t = new Title();\r\n t.setIsbn(\"test\");\r\n t.setTitle(\"aaaaaaaaaaaaaaaaaa\");\r\n t.setAuthor(\"kkkkkkkkkkkkkk\");\r\n t.setType(\"E\");\r\n int expResult = 1;\r\n int result = TitleDao.update(t);\r\n assertEquals(expResult, result);\r\n }", "@Test\n\tpublic void testUpdateTicketOk() {\n\t}", "@Test\r\n public void testUpdate() {\r\n }", "@Test\n public void testUpdate() {\n System.out.println(\"update\");\n Address obj = null;\n AddressDAO instance = null;\n boolean expResult = false;\n boolean result = instance.update(obj);\n assertEquals(expResult, result);\n // TODO review the generated test code and remove the default call to fail.\n fail(\"The test case is a prototype.\");\n }", "@Test\n public void updateTest() throws SQLException, IDAO.DALException {\n userDAO.create(user);\n user.setNavn(\"SørenBob\");\n user.setCpr(\"071199-4397\");\n user.setAktiv(false);\n user.setIni(\"SBO\");\n // Opdatere objektet i databasen, og sammenligner.\n userDAO.update(user);\n recivedUser = userDAO.get(-1);\n\n assertEquals(recivedUser.getId(), user.getId());\n assertEquals(recivedUser.getNavn(), user.getNavn());\n assertEquals(recivedUser.getIni(), user.getIni());\n assertEquals(recivedUser.getCpr(), user.getCpr());\n assertEquals(recivedUser.isAktiv(),user.isAktiv());\n }", "@Test\r\n\tpublic void testUpdate() {\r\n\t\tList<E> entities = dao.findAll();\r\n\t\tE updated = supplyUpdated(entities.get(0));\r\n\t\tdao.update(entities.get(0));\r\n\t\tentities = dao.findAll();\r\n\t\tassertEquals(updated, entities.get(0));\r\n\t}", "@Test\n public void update() {\n }", "@Test\n public void test2Update() {\n \n System.out.println(\"Prueba deSpecialityDAO\");\n SpecialityFactory factory = new MysqlSpecialityDAOFactry();\n SpecialityDAO dao = factory.create();\n assertEquals(dao.update(spec2,\"teleinformatica\"),1); \n }", "@Test\n @Ignore\n public void testUpdate() {\n System.out.println(\"update\");\n Index entity = null;\n IndexDaoImpl instance = null;\n Index expResult = null;\n Index result = instance.update(entity);\n assertEquals(expResult, result);\n // TODO review the generated test code and remove the default call to fail.\n fail(\"The test case is a prototype.\");\n }", "@Test\n public void updateTest() {\n reservation3.setId(13L);\n reservation3.setReserveDate(LocalDate.now().plusDays(2));\n reservationService.update(reservation3);\n Mockito.verify(reservationDao, Mockito.times(1)).update(reservation3);\n }", "public void updateForum(Forum forum);", "@Test\n void updateSuccess() {\n RunCategory categoryToUpdate = (RunCategory) dao.getById(2);\n categoryToUpdate.setCategoryName(\"New Name\");\n dao.saveOrUpdate(categoryToUpdate);\n RunCategory categoryAfterUpdate = (RunCategory) dao.getById(2);\n assertEquals(categoryToUpdate, categoryAfterUpdate);\n }", "@Test\r\n public void testUpdate() {\r\n ActivityRecord record = setActivityRecord();\r\n recordDao.create(record);\r\n assertNotNull(recordDao.findActivityRecord(record.getId()));\r\n\r\n record.setDistance(15);\r\n record.setTime(20L);\r\n recordDao.update(record);\r\n\r\n ActivityRecord recordFound = recordDao.findActivityRecord(record.getId());\r\n assertEquals(recordFound.getDistance(), new Integer(15));\r\n assertEquals(recordFound.getTime(), new Long(20));\r\n }", "@Test\n public void test() throws Exception{\n update(\"update user set username=? where id=?\",\"wangjian\",\"4\");\n }", "@Test\r\n public void testUpdate() {\r\n System.out.println(\"update\");\r\n Festivity object = new Festivity();\r\n object.setStart(Calendar.getInstance().getTime());\r\n object.setEnd(Calendar.getInstance().getTime());\r\n object.setName(\"Test Fest 2\");\r\n object.setPlace(\"Howards\");\r\n boolean expResult = true;\r\n boolean result = Database.update(object);\r\n assertEquals(expResult, result);\r\n \r\n }", "@Test\r\n\t public void updateAnExistingRouteFather(){\r\n\t\t this.routeFather.setDescription(\"yolo\");\r\n\t\t routeFatherDAO.update(this.routeFather);\r\n\t\t Assert.assertNotNull(\"it should returns not null\", this.routeFather);\r\n\t\t Assert.assertEquals(\"email should be yolo\", this.routeFather.getDescription(), \"yolo\");\r\n\t\t routeFatherDAO.delete(routeFather);\r\n\t\t \r\n\t }", "public void doUpdate(T objectToUpdate) throws SQLException;", "void updateEntry(BlogEntry entry) throws DAOException;", "@Test\n public void updateTest10() throws SQLException {\n manager = new TableServizioManager(mockDb);\n Servizio servizio = manager.retriveById(2);\n servizio.setBar(true);\n manager.update(servizio);\n servizio = manager.retriveById(2);\n assertEquals(true, servizio.isBar() ,\"Should return true if update Servizio\");\n }", "@Test\n\tpublic void testUpdateTask() {\n\t}", "@Test\npublic void testUpdateAStudentInformation() {\n//TODO: Test goes here...\n System.out.println(StudentDao.updateAStudentInformation(1006, \"6\", 99, 99, 99));\n}", "@Test\n public void update() {\n try{\n repo.save(s);\n repot.save(t);\n repon.save(n);\n Tema t2 = new Tema(1, 0, 6, \"GUI\");\n Student s2 = new Student(1,221, \"Pop Ion\",\"[email protected]\",\"prof\");\n Nota n2 = new Nota(1, 1, \"prof\", 10, \"Irelevant\");\n repo.save(s2);\n repot.save(t2);\n repon.save(n2);\n repo.update(s2);\n repot.update(t2);\n repon.update(n2);\n assert repo.findOne(1).getGrupa()==221;\n assert repot.findOne(1).getDeadline()==8;\n assert repon.findOne(\"11\").getFeedback()==\"Irelevant\";\n\n }\n catch (ValidationException e){\n }\n }", "private static void LessonDAOUpdate() {\n PersonDAO personDAO = new PersonDAOImpl();\n\n Person person = personDAO.getPersonById(7);\n person.setFirstName(\"Teddy\");\n\n if(personDAO.updatePerson(person)) {\n System.out.println(\"Person Update Success!\");\n } else {\n System.out.println(\"Person Update Fail!\");\n }\n }", "@Test\n\t public void testUpdateCollection(){\n\t\t try{\n\t\t\t List<Users> users = new ArrayList<Users>();\n\t\t\t users.add( BaseData.getUsers());\n\t\t\t\tusers.add(BaseData.getDBUsers());\n\t\t\t\tdoAnswer(new Answer() {\n\t\t\t \t public Object answer(InvocationOnMock invocation) {\n\t\t\t \t Object[] args = invocation.getArguments();\n\t\t\t \t EntityManager mock = (EntityManager) invocation.getMock();\n\t\t\t \t\t return null;\n\t\t\t \t }\n\t\t\t \t }).when(entityManager).persist(users);\n\t\t\t\tuserDao.update(users);\n\t\t }catch(DataAcessException se){\n\t\t\t logger.error(\"error at service layer while testing update:.\",se);\n\t\t }\n\t }", "@Test\r\n public void testUpdateEmployee1() throws Exception {\r\n try {\r\n\r\n int employee_id = 0;\r\n int department_id = 1;\r\n int position_id = 1;\r\n int status = 1;\r\n String date = \"\";\r\n EmployeeDAOImpl instance = new EmployeeDAOImpl();\r\n boolean expResult = false;\r\n boolean result = instance.updateEmployee(employee_id, department_id, position_id, status, date);\r\n assertEquals(expResult, result);\r\n } catch (Exception ex) {\r\n assertTrue(ex.getMessage().contains(\"Wrong Required Parameters\"));\r\n }\r\n }", "@Test\n\t public void testUpdate(){\n\t\t try{\n\t\t\t Users user = BaseData.getUsers();\n\t\t\t\twhen(entityManager.merge(user)).thenReturn(BaseData.getDBUsers());\n\t\t\t\tUsers savedUser = userDao.update(user);\n\t\t\t\tassertNotNull(savedUser);\n\t\t\t\tassertTrue(savedUser.getFirstName().equals(\"MerchandisingUI\"));\n\t\t }catch(DataAcessException se){\n\t\t\t logger.error(\"error at service layer while testing update:.\",se);\n\t\t }\n\t }", "@Test\r\n public void testUpdate() throws Exception {\r\n System.out.println(\"update\");\r\n Bureau obj = new Bureau(0,\"Test\",\"000000000\",\"\");\r\n BureauDAO instance = new BureauDAO();\r\n instance.setConnection(dbConnect);\r\n obj = instance.create(obj);\r\n obj.setSigle(\"Test2\");\r\n //etc\r\n obj.setTel(\"000000001\");\r\n //etc\r\n Bureau expResult=obj;\r\n Bureau result = instance.update(obj);\r\n assertEquals(expResult.getSigle(), result.getSigle());\r\n //etc\r\n assertEquals(expResult.getTel(), result.getTel());\r\n //etc\r\n instance.delete(obj);\r\n //TODO verifier que si met à jour vers un doublé sigle-tel déjà existant, on a une exception\r\n }", "@Test\r\n public void testUpdate() {\r\n assertTrue(false);\r\n }", "@Test\r\n\t public void updateANonExistingRouteFather(){\r\n\t\t RouteFather routeFather = new RouteFather(888988);\r\n\t\t routeFather = routeFatherDAO.update(routeFather);\r\n\t\t Assert.assertNull(\"it should returns null\", routeFather);\r\n\t }", "private static void testupdate() {\n\t\ttry {\n\t\t\tRoleModel model = new RoleModel();\n\t\t\tRoleBean bean = new RoleBean();\n\t\t\tbean = model.findByPK(7L);\n\t\t\tbean.setName(\"Finance\");\n\t\t\tbean.setDescription(\"Finance Dept\");\n\t\t\tbean.setCreatedBy(\"CCD MYSORE\");\n\t\t\tbean.setModifiedBy(\"CCD MYSORE\");\n\t\t\tbean.setCreatedDatetime(new Timestamp(new Date().getTime()));\n\t\t\tbean.setModifiedDatetime(new Timestamp(new Date().getTime()));\n\t\t\tmodel.update(bean);\n\t\t\tRoleBean updateBean = model.findByPK(1);\n\t\t\tif (\"12\".equals(updateBean.getName())) {\n\t\t\t\tSystem.out.println(\"UPDATE RECORD FAILED\");\n\t\t\t} else {\n\t\t\t\tSystem.out.println(\"RECORD UPDATED SUCCESSFULLY\");\n\t\t\t}\n\t\t} catch (ApplicationException e) {\n\t\t\te.printStackTrace();\n\t\t} catch (DuplicateRecordException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\n\t}", "@Test\n public void updateTest9() throws SQLException {\n manager = new TableServizioManager(mockDb);\n Servizio servizio = manager.retriveById(2);\n servizio.setCabina(true);\n manager.update(servizio);\n servizio = manager.retriveById(2);\n assertEquals(true, servizio.isCabina() ,\"Should return true if update Servizio\");\n }", "@Test\n public void updateTest6() throws SQLException {\n manager = new TableServizioManager(mockDb);\n Servizio servizio = manager.retriveById(2);\n servizio.setBeach_volley(false);\n manager.update(servizio);\n servizio = manager.retriveById(2);\n assertEquals(false, servizio.isBeach_volley() ,\"Should return true if update Servizio\");\n }", "@Test\n void updateSuccess() {\n String newEventName = \"Coffee meeting\";\n Event eventToUpdate = (Event)genericDao.getById(5);\n eventToUpdate.setName(newEventName);\n genericDao.saveOrUpdate(eventToUpdate);\n Event retrievedEvent = (Event)genericDao.getById(5);\n assertEquals(eventToUpdate, retrievedEvent);\n }", "public void testCmdUpdate() {\n\t\ttestCmdUpdate_taskID_field();\n\t\ttestCmdUpdate_taskName_field();\n\t\ttestCmdUpdate_time_field();\n\t\ttestCmdUpdate_priority_field();\n\t}", "@Test\n public void testUpdate() {\n int resultInt = disciplineDao.insert(disciplineTest);\n \n boolean result = false;\n \n if(resultInt > 0){\n disciplineTest.setId(resultInt);\n \n disciplineTest.setName(\"matiere_test2\");\n \n result = disciplineDao.update(disciplineTest);\n \n disciplineDao.delete(disciplineTest);\n }\n \n assertTrue(result);\n }", "@Test\n void testUpdateUser() {\n String password = \"testPassword\";\n User updateUser = (User) userData.crud.getById(1);\n updateUser.setPassword(password);\n userData.crud.updateRecords(updateUser);\n User getUser = (User) userData.crud.getById(1);\n assertEquals(getUser, updateUser);\n logger.info(\"Updated the password for ID: \" + updateUser.getId());\n }", "@Test\n public void testModifyUser() throws Exception {\n\n User user = userDao.retrieveById(\"uuid123123123\");\n user.setUsername(\"newbody4\");\n\n Boolean result = userDao.update(user);\n Assert.assertTrue(result);\n }", "@Test\n public void updateTest8() throws SQLException {\n manager = new TableServizioManager(mockDb);\n Servizio servizio = manager.retriveById(2);\n servizio.setCanoa(true);\n manager.update(servizio);\n servizio = manager.retriveById(2);\n assertEquals(true, servizio.isCanoa() ,\"Should return true if update Servizio\");\n }", "@Test\n public void updateTest11() throws SQLException {\n manager = new TableServizioManager(mockDb);\n Servizio servizio = manager.retriveById(2);\n servizio.setRistorante(true);\n manager.update(servizio);\n servizio = manager.retriveById(2);\n assertEquals(true, servizio.isRistorante() ,\"Should return true if update Servizio\");\n }", "@Test\n public void updateTest14() throws SQLException {\n manager = new TableServizioManager(mockDb);\n Servizio servizio = manager.retriveById(2);\n servizio.setBeach_volley(true);\n manager.update(servizio);\n servizio = manager.retriveById(2);\n assertEquals(true, servizio.isBeach_volley() ,\"Should return true if update Servizio\");\n }", "@SmallTest\n public void testUpdate() {\n int result = -1;\n if (this.entity != null) {\n Settings settings = SettingsUtils.generateRandom(this.ctx);\n settings.setId(this.entity.getId());\n\n result = (int) this.adapter.update(settings);\n\n Assert.assertTrue(result >= 0);\n }\n }", "@Test\n public void updateUserCatch() {\n userDAO.createUser(new User(\"dummy\", \"dummy\", 1));\n\n assertFalse(userDAO.updateUser(new User(\"notdummy\", \"dummyUPDATED\", 2)));\n\n //clean up\n userDAO.removeUser(\"dummy\");\n }", "boolean update(T entity) throws Exception;", "@Test\n public void updateTest3() throws SQLException {\n manager = new TableServizioManager(mockDb);\n Servizio servizio = manager.retriveById(2);\n servizio.setRistorante(false);\n manager.update(servizio);\n servizio = manager.retriveById(2);\n assertEquals(false, servizio.isRistorante() ,\"Should return true if update Servizio\");\n }", "@Test\n public void updateContact() {\n }", "Test update(TestData testData, Test test);", "@Test\n void updateSuccess() {\n String newFirstName = \"Artemis\";\n User userToUpdate = (User) dao.getById(1);\n userToUpdate.setFirstName(newFirstName);\n dao.saveOrUpdate(userToUpdate);\n User userAfterUpdate = (User) dao.getById(1);\n assertEquals(newFirstName, userAfterUpdate.getFirstName());\n }", "@Test\n public void testUpdate() throws Exception {\n String theTaskId = \"999\";\n String query = String.format(\"select empId from %s.%s where taskId = '%s'\",\n tableSchema.schemaName, TASK_TABLE_NAME, theTaskId);\n\n TestConnection connection = methodWatcher.getOrCreateConnection();\n connection.setAutoCommit(false);\n\n // insert good data\n PreparedStatement ps = methodWatcher.prepareStatement(\n String.format(\"insert into %s.%s (taskId, empId, startedAt, finishedAt) values (?,?,?,?)\",\n tableSchema.schemaName, TASK_TABLE_NAME));\n ps.setString(1, theTaskId);\n ps.setInt(2, 101);\n ps.setInt(3, 0600);\n ps.setInt(4, 0700);\n int rows = ps.executeUpdate();\n Assert.assertEquals(1, rows);\n\n ResultSet rs = connection.createStatement().executeQuery(query);\n rs.next();\n Assert.assertEquals(101, rs.getInt(1));\n Assert.assertFalse(\"Only one row expected.\", rs.next());\n\n ps = methodWatcher.prepareStatement(\n String.format(\"update %s.%s set empId = ? where taskId = ?\", tableSchema.schemaName, TASK_TABLE_NAME));\n ps.setInt(1, 102);\n ps.setString(2, theTaskId);\n rows = ps.executeUpdate();\n Assert.assertEquals(1, rows);\n\n rs = connection.createStatement().executeQuery(query);\n rs.next();\n Assert.assertEquals(102, rs.getInt(1));\n Assert.assertFalse(\"Only one row expected.\", rs.next());\n }", "public void update(Triplet t) throws DAOException;", "@Test\n public void updateTest1() throws SQLException {\n manager = new TableServizioManager(mockDb);\n Servizio servizio = manager.retriveById(2);\n servizio.setCabina(false);\n manager.update(servizio);\n servizio = manager.retriveById(2);\n assertEquals(false, servizio.isCabina() ,\"Should return true if update Servizio\");\n }", "@Test\n public void updateById() {\n User user = new User();\n user.setId(1259474874313797634L);\n user.setAge(30);\n boolean ifUpdate = user.updateById();\n System.out.println(ifUpdate);\n }", "@Test\n public void updateTest2() throws SQLException {\n manager = new TableServizioManager(mockDb);\n Servizio servizio = manager.retriveById(2);\n servizio.setBar(false);\n manager.update(servizio);\n servizio = manager.retriveById(2);\n assertEquals(false, servizio.isBar() ,\"Should return true if update Servizio\");\n }", "@Override\r\n\tpublic void update(Object obj) throws DAOException {\n\r\n\t}", "@Test\n public void updateTest7() throws SQLException {\n manager = new TableServizioManager(mockDb);\n Servizio servizio = manager.retriveById(2);\n servizio.setCanoa(false);\n manager.update(servizio);\n servizio = manager.retriveById(2);\n assertEquals(false, servizio.isCanoa() ,\"Should return true if update Servizio\");\n }", "public void testUpdateExistingAuthor() {\r\n //given\r\n /*System.out.println(\"updateExistingAuthor\");\r\n int authorID = 31;\r\n String newDescription = \"\";\r\n AuthorHibernateDao instance = new AuthorHibernateDao();\r\n boolean expResult = true;\r\n \r\n //when \r\n boolean result = instance.updateExistingAuthor(authorID, newDescription);\r\n \r\n //then\r\n assertEquals(expResult, result);*/ \r\n }", "@Test\n void testUpdateGoalie() {\n\n }", "@Test\r\n\tpublic void testUpdate() {\n\t\tint todos = modelo.getAll().size();\r\n\t\tCalificacion c = modelo.getById(1);\r\n\t\tCalificacion c2 = new Calificacion(7, \"Notable\");\r\n\t\tc2.setClave(c.getClave());\r\n\t\tc2.setDescripcion(c.getDescripcion());\r\n\t\tc2.setId(c.getId());\r\n\t\tc2.setClave(5);\r\n\t\tassertTrue(Calificacion.ID_NULL < modelo.update(c2));\r\n\t\tassertEquals(5, modelo.getById(1).getClave());\r\n\r\n\t\t// update de un registro null\r\n\t\tassertEquals(Calificacion.ID_NULL, modelo.update(null));\r\n\r\n\t\t// update de un registro que no existe\r\n\t\tCalificacion cInexistente = new Calificacion(0, \"nulo\");\r\n\t\tcInexistente.setId(14);\r\n\t\tassertEquals(Calificacion.ID_NULL, modelo.update(cInexistente));\r\n\t\tassertEquals(\"Debería ser las mismas calificaciones\", todos, modelo\r\n\t\t\t\t.getAll().size());\r\n\r\n\t}", "@Test \n\tpublic void testUpdateSetting() throws Exception\n\t{\n\t}", "@Test\n public void updateUser() {\n userDAO.createUser(new User(\"dummy\", \"dummy\", 1));\n\n assertTrue(userResource.updateUser(new User(\"dummy\", \"dummyUPDATED\", 2)));\n\n //clean up\n userDAO.removeUser(\"dummy\");\n }", "@Test @Ignore\n\tpublic void testUpdate() {\n\t\tlog.info(\"*** testUpdate ***\");\n\t}", "@Test\n public void updateTest12() throws SQLException {\n manager = new TableServizioManager(mockDb);\n Servizio servizio = manager.retriveById(2);\n servizio.setAnimazione(true);\n manager.update(servizio);\n servizio = manager.retriveById(2);\n assertEquals(true, servizio.isAnimazione() ,\"Should return true if update Servizio\");\n }", "@Test\n void updateSuccess() {\n String Vin = \"1111111111111111X\";\n Car carToUpdate = carDao.getById(1);\n carToUpdate.setVin(Vin);\n carDao.saveOrUpdate(carToUpdate);\n Car retrievedCar = carDao.getById(1);\n assertEquals(carToUpdate, retrievedCar);\n }", "public void update(RutaPk pk, Ruta dto) throws RutaDaoException;", "@Test\n public void testLockForum() {\n try {\n ForumDTO forumDTO = forumService.lockForum(FORUM_ID);\n assertTrue(forumDTO.isLocked());\n } catch (Exception e) {\n fail(e.getMessage());\n }\n }", "@Test\n void saveOrUpdateSuccess() {\n String newRoleName = \"readOnly\";\n UserRoles toUpdate = (UserRoles) genericDao.getById(3);\n toUpdate.setRoleName(newRoleName);\n genericDao.saveOrUpdate(toUpdate);\n UserRoles retrievedRole = (UserRoles) genericDao.getById(3);\n assertEquals(newRoleName, retrievedRole.getRoleName());\n log.info(\"update role success test\");\n\n }", "@Test\n public void updateTest13() throws SQLException {\n manager = new TableServizioManager(mockDb);\n Servizio servizio = manager.retriveById(2);\n servizio.setWifi(true);\n manager.update(servizio);\n servizio = manager.retriveById(2);\n assertEquals(true , servizio.isWifi() ,\"Should return true if update Servizio\");\n }", "@Test\n void updateTest() {\n admin.setSurname(\"Rossini\");\n Admin modifyied = adminJpa.update(admin);\n assertEquals(\"Rossini\", modifyied.getSurname());\n }", "void update(T entity) throws Exception;", "@Override\n\tpublic void updateTestCase(TestCaseStatus testCaseStatus) {\n\t\t\n\t}", "@Override\r\npublic int update(Detalle_pedido d) {\n\treturn detalle_pedidoDao.update(d);\r\n}", "@Test\n public void updateTaskAndGetById() {\n mDatabase.taskDao().insertTask(TASK);\n\n // When the task is updated\n Task updatedTask = new Task(\"title2\", \"description2\", \"id\", true);\n mDatabase.taskDao().updateTask(updatedTask);\n\n // When getting the task by id from the database\n Task loaded = mDatabase.taskDao().getTaskById(\"id\");\n\n // The loaded data contains the expected values\n assertTask(loaded, \"id\", \"title2\", \"description2\", true);\n }", "@Test\r\n\tpublic void updateUpdate() throws InterruptedException, ExecutionException {\r\n\t\tLOGGER.debugf(\"BEGINN\");\r\n\t\t\r\n\t\t// Given\r\n\t\tfinal Long zahlId = ZAHLUNGSINFORMATION_ID_UPDATE;\r\n \tfinal String neuerKontoinhaber = NEUER_KONTOINHABER;\r\n \tfinal String neuerKontoinhaber2 = NEUER_KONTOINHABER_2;\r\n\t\tfinal String username = USERNAME_ADMIN;\r\n\t\tfinal String password = PASSWORD_ADMIN;\r\n\t\t\r\n\t\t// When\r\n\t\tResponse response = given().header(ACCEPT, APPLICATION_JSON)\r\n\t\t\t\t .pathParameter(ZAHLUNGSINFORMATIONEN_ID_PATH_PARAM, zahlId)\r\n .get(ZAHLUNGSINFORMATIONEN_ID_PATH);\r\n\t\tJsonObject jsonObject;\r\n\t\ttry (final JsonReader jsonReader =\r\n\t\t\t\t getJsonReaderFactory().createReader(new StringReader(response.asString()))) {\r\n\t\t\tjsonObject = jsonReader.readObject();\r\n\t\t}\r\n\r\n \t// Konkurrierendes Update\r\n\t\t// Aus den gelesenen JSON-Werten ein neues JSON-Objekt mit neuem Nachnamen bauen\r\n \tfinal JsonObjectBuilder job2 = getJsonBuilderFactory().createObjectBuilder();\r\n \tSet<String> keys = jsonObject.keySet();\r\n \tfor (String k : keys) {\r\n \t\tif (\"kontoinhaber\".equals(k)) {\r\n \t\t\tjob2.add(\"kontoinhaber\", neuerKontoinhaber2);\r\n \t\t}\r\n \t\telse {\r\n \t\t\tjob2.add(k, jsonObject.get(k));\r\n \t\t}\r\n \t}\r\n \tfinal JsonObject jsonObject2 = job2.build();\r\n \tfinal ConcurrentUpdate concurrentUpdate = new ConcurrentUpdate(jsonObject2, ZAHLUNGSINFORMATIONEN_PATH,\r\n \t\t\t username, password);\r\n \tfinal ExecutorService executorService = Executors.newSingleThreadExecutor();\r\n\t\tfinal Future<Response> future = executorService.submit(concurrentUpdate);\r\n\t\tresponse = future.get(); // Warten bis der \"parallele\" Thread fertig ist\r\n\t\tassertThat(response.getStatusCode(), is(HTTP_NO_CONTENT));\r\n\t\t\r\n \t// Fehlschlagendes Update\r\n\t\t// Aus den gelesenen JSON-Werten ein neues JSON-Objekt mit neuem Nachnamen bauen\r\n\t\tfinal JsonObjectBuilder job1 = getJsonBuilderFactory().createObjectBuilder();\r\n \tkeys = jsonObject.keySet();\r\n \tfor (String k : keys) {\r\n \t\tif (\"kontoinhaber\".equals(k)) {\r\n \t\t\tjob1.add(\"kontoinhaber\", neuerKontoinhaber);\r\n \t\t}\r\n \t\telse {\r\n \t\t\tjob1.add(k, jsonObject.get(k));\r\n \t\t}\r\n \t}\r\n \tjsonObject = job1.build();\r\n\t\tresponse = given().contentType(APPLICATION_JSON)\r\n\t\t\t\t .body(jsonObject.toString())\r\n\t\t .auth()\r\n\t\t .basic(username, password)\r\n\t\t .put(ZAHLUNGSINFORMATIONEN_PATH);\r\n \t\r\n\t\t// Then\r\n\t\tassertThat(response.getStatusCode(), is(HTTP_CONFLICT));\r\n\t\t\r\n\t\tLOGGER.debugf(\"ENDE\");\r\n\t}", "@Test\r\n public void testUpdate() {\r\n System.out.println(\"update\");\r\n String doc = \"\";\r\n String xml = \"\";\r\n IwRepoDAOMarkLogicImplStud instance = new IwRepoDAOMarkLogicImplStud();\r\n boolean expResult = false;\r\n boolean result = instance.update(doc, xml);\r\n assertEquals(expResult, result);\r\n // TODO review the generated test code and remove the default call to fail.\r\n fail(\"The test case is a prototype.\");\r\n }", "@Test\n public void updateTest5() throws SQLException {\n manager = new TableServizioManager(mockDb);\n Servizio servizio = manager.retriveById(2);\n servizio.setWifi(false);\n manager.update(servizio);\n servizio = manager.retriveById(2);\n assertEquals(false, servizio.isWifi() ,\"Should return true if update Servizio\");\n }", "@Test\n\tpublic void updateTestPaperQuestion() throws Exception {\n\t}", "public void update(T t) {\n\t\tConnection connection = null;\n\t\tPreparedStatement statement = null;\n\t\tString query = createUpdate(t);\n\t\ttry {\n\t\t\tconnection = ConnectionDB.getConnection();\n\t\t\tstatement = connection.prepareStatement(query);\n\t\t\tstatement.executeUpdate();\n\t\t} catch (SQLException e) {\n\t\t\tLOGGER.log(Level.WARNING, type.getName() + \"DAO:Update \" + e.getMessage());\n\t\t} finally {\n\t\t\tConnectionDB.close(statement);\n\t\t\tConnectionDB.close(connection);\n\t\t}\n\t}", "@Test @Ignore\n\tpublic void testSQLUpdate() {\n\t\tlog.info(\"*** testSQLUpdate ***\");\n\t}", "boolean updateTicket(Ticket ticket, boolean createdByMe, boolean assignedToMe, boolean managedByMe);", "@Test\n public void updateTest4() throws SQLException {\n manager = new TableServizioManager(mockDb);\n Servizio servizio = manager.retriveById(2);\n servizio.setAnimazione(false);\n manager.update(servizio);\n servizio = manager.retriveById(2);\n assertEquals(false, servizio.isAnimazione() ,\"Should return true if update Servizio\");\n }", "@Override\n\tpublic void updateForum(String path) throws Exception {\n\n\t}", "@Test(expected = NoResultException.class)\r\n public void updatePosts(){\r\n\r\n Post post = entityManager.createNamedQuery(\"Post.fetchAllRecordsByUserId\", Post.class)\r\n .setParameter(\"value1\", 3000l)\r\n .getSingleResult();\r\n \r\n post.setDescription(\"TRASHED ELECTRONICS ARE PILING UP ACROSS ASIA\");\r\n post.setLikes(500);\r\n \r\n \r\n entityTransaction.begin();\r\n entityManager.createNamedQuery(\"Post.updateDescriptionAndLikesByPostId\", Post.class)\r\n .setParameter(\"value1\", post.getDescription())\r\n .setParameter(\"value2\", post.getLikes())\r\n .setParameter(\"value3\", post.getPostId())\r\n .executeUpdate();\r\n entityManager.refresh(post);\r\n entityTransaction.commit();\r\n\r\n post = entityManager.createNamedQuery(\"Post.fetchAllRecordsByUserId\", Post.class)\r\n .setParameter(\"value1\", 300l)\r\n .getSingleResult(); \r\n assertNotNull(post); \r\n }", "@Override\r\n\tpublic FyTestRecord update(FyTestRecord testRecord) {\n\t\tUpdater u = new Updater(testRecord);\r\n\t\treturn testRecordDao.updateByUpdater(u);\r\n\t}", "@org.junit.Test\r\n public void testUpdateReview6() throws Exception {\r\n System.out.println(\"updateReview6\");\r\n Long id = new Long(0);\r\n Review review = new Review(new Long(0), \"Max\", 9, \"It's excellent\");\r\n service.insertReview(review);\r\n Review review2 = new Review(new Long(0), \"Jack\", 2, null);\r\n try{\r\n Review result = service.updateReview(review2, id);\r\n }catch(BusinessException ex){\r\n return;\r\n }\r\n fail(\"Accepted null review text\");\r\n }", "@org.junit.Test\r\n public void testUpdatecon() {\r\n System.out.println(\"updatecon\");\r\n ContactRequest Urequest = new ContactRequest(\"DN Verma1\",\"[email protected]\",\"9006847351\",\"DBG\");\r\n ContactDao instance = new ContactDao();\r\n List<ContactResponse> expResult = new ArrayList<ContactResponse>();\r\n ContactResponse c = new ContactResponse(\"Contact Updated\");\r\n expResult.add(c);\r\n List<ContactResponse> result = instance.updatecon(Urequest);\r\n String s=\"No such ID exsits\";\r\n if(!result.get(0).getMessage().equals(s))\r\n assertEquals(expResult.get(0).getMessage(), result.get(0).getMessage());\r\n // TODO review the generated test code and remove the default call to fail.\r\n }", "@Override\r\n\tpublic void update(SimpleJdbcTemplate template) throws Exception {\n\t}", "@org.junit.Test\r\n public void testUpdateReview1() throws Exception {\r\n System.out.println(\"updateReview1\");\r\n Long id = new Long(0);\r\n Review review = new Review(new Long(0), \"Max\", 9, \"It's excellent\");\r\n service.insertReview(review);\r\n Review review2 = new Review(new Long(0), \"Jack\", 2, \"Disappointing\");\r\n Review result = service.updateReview(review2, id);\r\n assertEquals(review2, result);\r\n }", "@Test\n public void testUpdate() throws MainException, SQLException {\n System.out.println(\"update\");\n LinkingDb instance = new LinkingDb(new ConfigurazioneTO(\"jdbc:hsqldb:file:database/\",\n \"ADISysData\", \"asl\", \"\"));\n instance.connect();\n PreparedStatement stmt = instance.prepareStatement(\n \"insert into infermieri (nome, cognome) values ('luca', 'massa')\");\n boolean expResult = true;\n boolean result = instance.update(stmt);\n assertEquals(expResult, result);\n }", "public void attemptToUpdate();", "public void update(T object) throws SQLException;", "@Test\n public void test_update() throws Exception {\n User user1 = createUser(1, false);\n\n user1.setUsername(\"new\");\n\n entityManager.getTransaction().begin();\n instance.update(user1);\n entityManager.getTransaction().commit();\n entityManager.clear();\n\n User retrievedUser = instance.get(user1.getId());\n\n assertEquals(\"'update' should be correct.\", user1.getUsername(), retrievedUser.getUsername());\n }", "@Test\n\tpublic void testUpdateNote() {\n//\t\tlog.trace(\"Testing updating note\");\n\t\tfinal short week = 2;\n\n\t\t// get the list of individual notes for week 2\n\t\tList<Note> notes = noteDao.findIndividualNotes(TEST_QCBATCH_ID, week);\n\n\t\tassertTrue(!notes.isEmpty());\n\n\t\tNote note = notes.get(1);\n\n\t\t// Old Content = Superstar. Great communication skill and good solid knowledge.\n\t\tString oldContent = note.getContent();\n\n\t\tnote.setContent(\"Hello\");\n\n\t\t// update note\n\t\tnoteDao.save(note);\n\n\t\t// Old Content should not equal new Content if updated\n\t\tnotes = noteDao.findIndividualNotes(TEST_QCBATCH_ID, week);\n\t\tString newContentSet = notes.get(1).getContent();\n\t\tassertNotEquals(oldContent, newContentSet);\n\t}", "@Override\r\n\tpublic int do_update(DTO dto) {\n\t\treturn 0;\r\n\t}", "@Override\n public void update(Object object, Object id) throws DAOException {\n\n }", "@Test\n public void lastUpdateTest() {\n // TODO: test lastUpdate\n }", "int updateByPrimaryKey(TestEntity record);", "public void executeUpdate();", "@Test\n public void updatePage() {\n }", "void update(EmployeeDetail detail) throws DBException;" ]
[ "0.7140945", "0.6903508", "0.68968564", "0.68743443", "0.68717957", "0.68589604", "0.6857473", "0.67974406", "0.67561996", "0.67336106", "0.67117494", "0.66507334", "0.6645591", "0.6624675", "0.65845054", "0.6573575", "0.6570931", "0.65482", "0.64956295", "0.648368", "0.6481874", "0.6469305", "0.6468367", "0.64586097", "0.6454769", "0.6447345", "0.6431253", "0.64249164", "0.64139235", "0.6397516", "0.63751674", "0.6372001", "0.6367839", "0.6341894", "0.63276136", "0.63272655", "0.6318655", "0.6316137", "0.63036793", "0.63015807", "0.6292616", "0.62799", "0.62723356", "0.6269781", "0.6264073", "0.6258337", "0.6257024", "0.6256026", "0.6245904", "0.62440103", "0.62378985", "0.6228015", "0.6209239", "0.62069434", "0.6206438", "0.61944413", "0.6192658", "0.6183102", "0.6181732", "0.6176011", "0.6173737", "0.6146021", "0.61405176", "0.6127939", "0.6126609", "0.61197037", "0.6109002", "0.60953164", "0.60838705", "0.6083127", "0.6077281", "0.607545", "0.6072719", "0.6060557", "0.60531354", "0.6048244", "0.6036234", "0.60358834", "0.601889", "0.60164016", "0.60096633", "0.6008712", "0.59962285", "0.59912646", "0.5987671", "0.59814626", "0.59697294", "0.5969289", "0.59680814", "0.59679085", "0.59559226", "0.5954817", "0.59422266", "0.5941545", "0.5941276", "0.5931622", "0.5928611", "0.59239686", "0.59204996", "0.5907255" ]
0.676018
8
This interface defines some basic operations to setup properties for the hibernate configuration. There are situations where the DB configuration, mainly username and password shall not be visible in any configuration file but shall be retrieved programmatically from some other sources. If this is the case an implementation of this interface can be provided to the SIF3 Framework that sets some of the hibernate properties that are commonly found in either the hibernate.properties or hibernate.cfg.xml file through this class. The property names are the same as in the hibernate.cfg.xml file. If the SIF3 framework shall use an implementation of this interface then the fully qualified class name of the subclass must be listed in the consumer's or provider's property file in the "adapter.hbr.propertyClass" property. Note: Properties that are set in the hibernate.cfg.xml file will always take precedence over properties in the implementation of this class.
public interface HibernateProperties { /** * Returns all programmatically set properties that shall be used in the hibernate configuration. * * @return Null can be returned. The returned property class can be empty. */ public Properties getProperties(); /** * This method will replace the currently set properties with the given properties. This is not a * merge!. Existing properties will be wiped out. * * @param properties */ public void setProperties(Properties properties); /** * This method will set/replace the property given by its key with the given value. * * @param key The name of the property to set/replace. * @param value The value to set/replace the property with. */ public void addProperty(String key, String value); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public interface IDataSourceConfiguration {\r\n\r\n\t/**\r\n\t * \r\n\t * @return Nombre del driver \r\n\t */\r\n\tpublic String getDriverName();\r\n\t\r\n\t/**\r\n\t * \r\n\t * @param driverName Nombre del driver\r\n\t */\r\n\tpublic void setDriverName(String driverName);\r\n\t\r\n\t/**\r\n\t * \r\n\t * @return User name de conexion\r\n\t */\r\n\tpublic String getUserName();\r\n\t\r\n\t/**\r\n\t * \r\n\t * @param userName User name de conexion\r\n\t */\r\n\tpublic void setUserName(String userName);\r\n\t\r\n\t/**\r\n\t * \r\n\t * @return Password de conexion\r\n\t */\r\n\tpublic String getPassword();\r\n\t\r\n\t/**\r\n\t * \r\n\t * @param password Password de conexion\r\n\t */\r\n\tpublic void setPassword(String password);\r\n\t\r\n\t/**\r\n\t * \r\n\t * @return URL de conexion. Por ejemplo jdbc:postgresql://55.55.55.55:5432/ehcos\r\n\t */\r\n\tpublic String getUrl();\r\n\t\r\n\t/**\r\n\t * \r\n\t * @param url URL de conexion. Por ejemplo jdbc:postgresql://55.55.55.55:5432/ehcos\r\n\t */\r\n\tpublic void setUrl(String url);\r\n\t\r\n\t/**\r\n\t * \r\n\t * @return Alternative User name de conexion\r\n\t */\r\n\tpublic String getAltUserName();\r\n\t\r\n\t/**\r\n\t * \r\n\t * @param userName Alternative User name de conexion\r\n\t */\r\n\tpublic void setAltUserName(String altUserName);\r\n\t\r\n\t/**\r\n\t * \r\n\t * @return Password de conexion\r\n\t */\r\n\tpublic String getAltPassword();\r\n\t\r\n\t/**\r\n\t * \r\n\t * @param password Alternative Password de conexion\r\n\t */\r\n\tpublic void setAltPassword(String altPassword);\r\n\t\r\n}", "public interface JdbcProperties {\n\n /**\n * @return the database connection url\n */\n String getUrl();\n\n /**\n * @return the database user\n */\n String getUsername();\n\n /**\n * @return the database password\n */\n String getPassword();\n}", "private Properties hibernateProperties() {\r\n\t\tProperties properties = new Properties();\r\n\t\tproperties.put(org.hibernate.cfg.Environment.DIALECT, \"org.hibernate.dialect.MySQL5Dialect\");\r\n\t\tproperties.put(org.hibernate.cfg.Environment.SHOW_SQL, true);\r\n properties.put(org.hibernate.cfg.Environment.FORMAT_SQL, true);\r\n properties.put(org.hibernate.cfg.Environment.HBM2DDL_AUTO, \"update\");\r\n return properties;\r\n\t}", "public void setConfiguration(Properties props);", "public interface DBConfig_I {\r\n\r\n /**\r\n * Dateformat the user sends<br/>\r\n * If the DAO receives a DTO that has a column of type DATE/TIMESTAMP\r\n * then it looks up this format to \"know\" the syntax.\r\n * \r\n * @return Java Dateformat\r\n */\r\n public String getGUIDateFormat();\r\n \r\n/**\r\n * This is how the SQL database wants a date to be<br/>\r\n * This depends on the datasource one is using.<br/>\r\n * And it only applies, if one uses a String coded Date,\r\n * recommended is *always* to use a PreparedStatement and a\r\n * setDate()<br/>\r\n * \r\n * @return format of the SQL date\r\n */\r\n public String getSQLDateFormat();\r\n \r\n /**\r\n * User set a Timestamp (as String) inside a DTO<br/>\r\n * \r\n * @return Java Dateformat \r\n */\r\n \r\n public String getGUITimestampFormat();\r\n \r\n/**\r\n * This is how the database \"wants\" a Timestamp in String representation\r\n * \r\n * @return sql timestamp format, *very* database and country dependend...\r\n */\r\n public String getSQLTimestampFormat();\r\n \r\n public String getSQLTimestampFormatQuery();\r\n \r\n/**\r\n * java.sql.Connection\r\n * \r\n * For each instance of this class -> only one connection\r\n * \r\n * This means every call to \"getConnection\" will return the *same*\r\n * Connection object.\r\n * \r\n * This saves massively ressources, but has some other severe drawbacks!\r\n * \r\n * @return instance of java.sql.Connection\r\n */\r\n public Connection getConnection();\r\n \r\n public String getDatabaseType();\r\n \r\n/**\r\n * Class that creates a unique primary key<br/>\r\n * \r\n * Needed, since almost every database has its own mechanism\r\n * to provide a unique numeric value (Autonum, Sequence...)\r\n * \r\n * @return fully qualified classname of the primary key creator\r\n */\r\n public String getPKCClass();\r\n \r\n}", "public interface ConfigurationManager {\n\n String loadRunAsUser();\n\n void storeRunAsUser(String username);\n\n List<String> loadEnabledProjects();\n\n void storeEnabledProjects(List<String> projectKeys);\n\n Map<String, String> loadBranchFilters();\n \n void storeBranchFilters(Map<String, String> branchFilters);\n \n /**\n * @since v1.2\n */\n Collection<String> loadCrucibleUserNames();\n\n /**\n * @since v1.2\n */\n void storeCrucibleUserNames(Collection<String> usernames);\n\n /**\n * @since v1.3\n */\n Collection<String> loadCrucibleGroups();\n\n /**\n * @since v1.3\n */\n void storeCrucibleGroups(Collection<String> groupnames);\n\n CreateMode loadCreateMode();\n\n void storeCreateMode(CreateMode mode);\n\n /**\n * @since v1.4.1\n */\n boolean loadIterative();\n\n /**\n * @since v1.4.1\n */\n void storeIterative(boolean iterative);\n}", "private Properties getHibernateProperties() {\n\t\tProperties properties = new Properties();\n\t\tproperties.put(\"hibernate.show_sql\", \"true\");\n\t\tproperties.put(\"hibernate.dialect\", \"org.hibernate.dialect.MySQLDialect\");\n\t\tproperties.put(\"hbm2ddl.auto\", \"create\");\n\t\tproperties.put(\"hibernate.id.new_generator_mappings\", \"false\");\n\t\t\n\t\treturn properties;\n\t}", "private Properties getHibernateProperties() {\r\n\t\tProperties properties = new Properties();\r\n\t\tproperties.put(\"hibernate.dialect\", hibernateDialect); // -> database specific property\r\n\t\t// -> this will allow us to see the sql query executed.\r\n\t\tproperties.put(\"hibernate.show_sql\", showSql);\r\n\t\t// -> this will format the sql query.\r\n\t\tproperties.put(\"hibernate.format_sql\", formatSql);\r\n\t\t// -> this will allow us to automatically create, update or drop the table in\r\n\t\t// the database.\r\n\t\t// properties.put(\"hibernate.hbm2ddl.auto\", hbm2ddl);\r\n\t\treturn properties;\r\n\t}", "public interface HibernateConfigurationValidator\n{\n\tvoid validate(Configuration hibernateConfiguration,\n\t Properties hibernateProperties,\n\t GuiceConfig environmentConfiguration);\n}", "public BaseClass() {\n\t\t \n\t try {\n\t\t\t \n\t\t\t prop=new Properties();\n\t\t\t \n\t\t\tString path=System.getProperty(\"user.dir\");\n\t\t\t \n\t\t\t // FileInputStream is the pre-defined class\n\t\t\tFileInputStream ip=new FileInputStream(path+\"\\\\src\\\\main\\\\java\\\\com\\\\demoQA\\\\config\\\\Config.Properties\");\n\t\t\t prop.load(ip);\n\t\t} catch (FileNotFoundException e) {\n\t\t\t\n\t\t\te.printStackTrace();\n\t\t\t\n\t\t} catch (IOException e) {\n\t\t\t\n\t\t\te.printStackTrace();\n\t\t}\n\t\t \n\t\t \n\t }", "@Override\n public void afterPropertiesSet() {\n\n super.afterPropertiesSet();\n\n Assert.notNull(getDataSources(), \"Data sources not set\");\n\n /**\n * SettingServiceProvider setup.\n */\n setSettingService((SettingServiceProvider) getServiceFactory().makeService(SettingServiceProvider.class));\n Assert.notNull(getSettingService(), \"Settings Service Provider could be located.\");\n\n /**\n * IdGenerator setup.\n */\n setIdGenerator((IdGenerator) getServiceFactory().makeService(IdGenerator.class));\n Assert.notNull(getIdGenerator(), \"ID Generator could be located.\");\n\n /**\n * TransactionDAO setup.\n */\n setTransactionDao((JdbcTransactionDao) getServiceFactory().makeService(JdbcTransactionDao.class));\n Assert.notNull(getTransactionDao(), \"TransactionDAO could not be located.\");\n\n /**\n * PartnerDAO setup.\n */\n setPartnerDao((JdbcPartnerDao) getServiceFactory().makeService(JdbcPartnerDao.class));\n Assert.notNull(getTransactionDao(), \"PartnerDao could not be located.\");\n\n /**\n * CompressionService setup.\n */\n setCompressionService((CompressionService) getServiceFactory().makeService(CompressionService.class));\n Assert.notNull(getTransactionDao(), \"CompressionService could not be located.\");\n\n /**\n * Data Access Objects setup\n */\n HibernatePersistenceProvider provider = new HibernatePersistenceProvider();\n EntityManagerFactory emf = provider.createEntityManagerFactory(\n getDataSources().get(ARG_DS_SOURCE),\n new PluginPersistenceConfig()\n .classLoader(OrganizationDataType.class.getClassLoader())\n .debugSql(Boolean.FALSE)\n .rootEntityPackage(\"com.windsor.node.plugin.wqx.domain\")\n .setBatchFetchSize(1000));\n\n setEntityManager(emf.createEntityManager());\n\n /**\n * SubmissionHistoryDao setup\n */\n setSubmissionHistoryDao(new SubmissionHistoryDaoJpaImpl(getEntityManager()));\n\n /**\n * WqxDao setup\n */\n setWqxDao(new WqxDaoJpaImpl(getEntityManager()));\n Assert.notNull(getWqxDao(), \"WqxDao could not be located.\");\n }", "public StructureTownHallConfigDao() {\n\t\tsuper(StructureTownHallConfig.STRUCTURE_TOWN_HALL_CONFIG, StructureTownHallConfigPojo.class);\n\t}", "private Properties jpaProperties() {\n\n Properties props = new Properties();\n\n props.setProperty(\"hibernate.dialect\", jdbcPropsValues.getHibernateDialect());\n props.setProperty(\"hibernate.show_sql\", jdbcPropsValues.getHibernateShowSql());\n\n return props;\n }", "public void loadConfiguration() {\n Properties prop = new Properties();\n String propFileName = \".env_\" + this.dbmode.name().toLowerCase();\n InputStream inputStream = getClass().getClassLoader().getResourceAsStream(propFileName);\n try {\n if (inputStream != null) {\n prop.load(inputStream);\n } else {\n System.err.println(\"property file '\" + propFileName + \"' not found in the classpath\");\n }\n this.jdbc = prop.getProperty(\"jdbc\");\n this.host = prop.getProperty(\"host\");\n this.port = prop.getProperty(\"port\");\n this.database = prop.getProperty(\"database\");\n this.user = prop.getProperty(\"user\");\n this.password = prop.getProperty(\"password\");\n // this.sslFooter = prop.getProperty(\"sslFooter\");\n } catch (Exception e) {\n System.err.println(\"can't read property file\");\n }\n try {\n inputStream.close();\n } catch (IOException e) {\n e.printStackTrace();\n }\n }", "public interface Dao {\n\tpublic void setMySessionFactory(SessionFactory sf);\n}", "@Resource\n\t@Override\n\tpublic void setSqlSessionFactory(SqlSessionFactory sqlSessionFactory) {\n\t\tsuper.setSqlSessionFactory(sqlSessionFactory);\n\t}", "@ImplementedBy(ServerPropertiesClasspath.class)\npublic interface ServerProperties\n{\n /**\n * Gets an integer property with a default\n * @param key The name of the property to retrieve\n * @param def The default value of the property\n * @return The int value of the property\n */\n int getInt( String key, int def);\n\n /**\n * Gets a string property, returning a default if undefined\n * @param key The name of the property to retrieve\n * @param def The default value of the property\n * @return The retrieved property value\n */\n String getString( String key, String def);\n\n /**\n * Gets the port on which the server should run\n */\n default int getPort()\n {\n return getInt(\"port\", 80);\n }\n\n /**\n * Gets the host on which the server is running\n */\n default String getHost()\n {\n return getString( \"host\", \"localhost:80\");\n }\n\n /**\n * Gets the version of the current application\n */\n default String getVersion()\n {\n return getString( \"version\", \"Unknown Version\");\n }\n}", "public interface DatabaseConfiguration {\n\n\t/**\n\t * TODO (paulo 21/01/2011 14:52:38): escrever javadoc\n\t *\n\t * @return\n\t */\n\tDatabaseTypes getDatabaseType();\n\t\n\t/**\n\t * TODO (paulo 21/01/2011 14:52:40): escrever javadoc\n\t *\n\t * @return\n\t * @throws DatabaseConfigurationException {@link RuntimeException} throw when not retrieve connection.\n\t */\n\tConnection getConnection();\n\t\n}", "private SessionFactoryUtil() {\r\n try {\r\n LOG.info(\"Configurando hibernate.cfg.xml\");\r\n CfgFile cfgFile = new CfgFile();\r\n Configuration configure = new Configuration().configure(new File(cfgFile.getPathFile()));\r\n cfgFile.toBuildMetaData(configure);\r\n ServiceRegistry serviceRegistry = new StandardServiceRegistryBuilder().applySettings(configure.getProperties()).build();\r\n sessionFactory = configure.buildSessionFactory(serviceRegistry);\r\n LOG.info(\"Configuracion se cargo a memoria de forma correcta\");\r\n } // try\r\n catch (Exception e) {\r\n Error.mensaje(e);\r\n } // catch\r\n }", "public interface Configurable {\n\n void configure(Properties properties);\n}", "@RolesAllowed(RolesConstants.ADMIN_MANAGE_SETTINGS)\n @Override\n public Configuration getDbConfiguration() {\n return getRepository().getDbConnectionManager().getSqlSessionFactory().getConfiguration();\n }", "@Override\r\n\tpublic void configure(Type arg0, Properties arg1, Dialect arg2)\r\n\t\t\tthrows MappingException {\n\t\t\r\n\t}", "public interface IConfigurationDao {\n \n \t/**\n \t * Retrieves a <code>Configuration</code> value from a data source\n \t * \n \t * @param name\n \t * The name of the <code>Configuration</code> option to be queried\n \t * @return The value corresponding to the given <code>Configuration</code> option, or an\n \t * empty string if not set.\n \t */\n \tpublic String getConfigurationValue(String name);\n \n \t/**\n \t * Sets a <code>Configuration</code> option.\n \t * \n \t * @param name\n \t * The name of the <code>Configuration</code> option to be set\n \t * @param value\n \t * The value to be assigned to the given <code>Configuration</code> option\n \t */\n \tpublic void setConfigurationValue(String name, String value);\n \n \t/**\n \t * Removes a <code>Configuration</code> option entirely\n \t * \n \t * @param name\n \t * The name of the <code>Configuration</code> option to be removed (nothing\n \t * will be done if there is no <code>Configuration</code> option by that name)\n \t */\n \tpublic void deleteConfigurationValue(String name);\n \n \t/**\n \t * Checks if a <code>Configuration</code> option is set (i.e. if a <code>Configuration</code> option\n \t * by that name exists)\n \t * \n \t * @param name\n \t * The name of the <code>Configuration</code> option to check\n \t * @return true, iff the <code>Configuration</code> option is set\n \t */\n \tpublic boolean configurationValueExists(String name);\n \n \t// FIXME: do we really need an update method? how about overriding existing \n \t// values.\n \t/**\n \t * Updates the given <code>Configuration</code> Object in the database. Create it if it\n \t * doesn't exist.\n \t * \n \t * @param configuration\n \t * the <code>Configuration</code> object to be updated/created\n \t * @return the <code>Configuration</code> object updated.\n \t */\n \tpublic Configuration update(final Configuration configuration);\n \n \n \t/**\n \t * Returns a <code>List</code> of all known configuration options\n \t * \n \t * @return a <code>List</code> of Configuration options, empty <code>List</code> if no options are available\n \t */\n \tpublic List<Configuration> getAll();\n }", "public interface Configuration {\n\n}", "public interface IConfiguration extends ISessionAwareObject {\n\n\tString ENV_SOPECO_HOME = \"SOPECO_HOME\";\n\n\tString CONF_LOGGER_CONFIG_FILE_NAME = \"sopeco.config.loggerConfigFileName\";\n\n\tString CONF_SCENARIO_DESCRIPTION_FILE_NAME = \"sopeco.config.measurementSpecFileName\";\n\n\tString CONF_SCENARIO_DESCRIPTION = \"sopeco.config.measurementSpecification\";\n\n\tString CONF_MEASUREMENT_CONTROLLER_URI = \"sopeco.config.measurementControllerURI\";\n\n\tString CONF_MEASUREMENT_CONTROLLER_CLASS_NAME = \"sopeco.config.measurementControllerClassName\";\n\n\tString CONF_APP_NAME = \"sopeco.config.applicationName\";\n\n\tString CONF_MAIN_CLASS = \"sopeco.config.mainClass\";\n\n\tString CONF_MEC_ACQUISITION_TIMEOUT = \"sopeco.config.MECAcquisitionTimeout\";\n\n\n\tString CONF_MEC_SOCKET_RECONNECT_DELAY = \"sopeco.config.mec.reconnectDelay\";\n\n\tString CONF_HTTP_PROXY_HOST = \"sopeco.config.httpProxyHost\";\n\t\n\tString CONF_HTTP_PROXY_PORT = \"sopeco.config.httpProxyPort\";\n\n\t\n\tString CONF_DEFINITION_CHANGE_HANDLING_MODE = \"sopeco.config.definitionChangeHandlingMode\";\n\tString DCHM_ARCHIVE = \"archive\";\n\tString DCHM_DISCARD = \"discard\";\n\n\tString CONF_SCENARIO_DEFINITION_PACKAGE = \"sopeco.config.xml.scenarioDefinitionPackage\";\n\t/** Holds the path to the root folder of SoPeCo. */\n\tString CONF_APP_ROOT_FOLDER = \"sopeco.config.rootFolder\";\n\tString CONF_EXPERIMENT_EXECUTION_SELECTION = \"sopeco.engine.experimentExecutionSelection\";\n\t/**\n\t * Holds the path to the plugins folder, relative to the root folder of\n\t * SoPeCo.\n\t */\n\tString CONF_PLUGINS_DIRECTORIES = \"sopeco.config.pluginsDirs\";\n\n\tString CLA_EXTENSION_ID = \"org.sopeco.config.commandlinearguments\";\n\n\t/** Folder for configuration files relative to the application root folder */\n\tString DEFAULT_CONFIG_FOLDER_NAME = \"config\";\n\n\tString DEFAULT_CONFIG_FILE_NAME = \"sopeco-defaults.conf\";\n\n\tString DIR_SEPARATOR = \":\";\n\t\n\tString EXPERIMENT_RUN_ABORT = \"org.sopeco.experiment.run.abort\";\n\n\t/**\n\t * Export the configuration as a key-value map. Both, the default ones and the ones in the\n\t * system environment are included.\n\t * \n\t * @return a key-value representation of the configuration\n\t * \n\t * @deprecated Use {@code exportConfiguration()} and {@code exportDefaultConfiguration}.\n\t */\n\t@Deprecated\n\tMap<String, Object> getProperties();\n\t\n\t/**\n\t * Exports the configuration as a key-value map. The default configuration and the ones\n\t * defined in the system environment are not included. \n\t * \n\t * @return a key-value representation of the configuration\n\t */\n\tMap<String, Object> exportConfiguration();\n\t\n\t/**\n\t * Exports the default configuration as a key-value map. The actual configuration and the ones\n\t * defined in the system environment are not included. \n\t * \n\t * @return a key-value representation of the configuration\n\t */\n\tMap<String, Object> exportDefaultConfiguration();\n\t\n\t/**\n\t * Imports the configuration as a key-value map. \n\t * \n\t * @param config a key-value map representation of the configuration\n\t */\n\tvoid importConfiguration(Map<String, Object> config);\n\t\n\t/**\n\t * Imports the default configuration as a key-value map. \n\t * \n\t * @param config a key-value map representation of the configuration\n\t */\n\tvoid importDefaultConfiguration(Map<String, Object> config);\n\t\n\t/**\n\t * Overwrites the configuration with the given configuration. \n\t * \n\t * @param config a key-value map representation of the configuration\n\t */\n\tvoid overwriteConfiguration(Map<String, Object> config);\n\t\n\t/**\n\t * Overwrites the default configuration with the given configuration. \n\t * \n\t * @param config a key-value map representation of the default configuration\n\t */\n\tvoid overwriteDefaultConfiguration(Map<String, Object> config);\n\t\n\t/**\n\t * Returns the configured value of the given property in SoPeCo.\n\t * \n\t * It first looks up the current SoPeCo configuration, if there is no value\n\t * defined there, looks up the system properties, if no value is defined\n\t * there, then loads it from the default values; in case of no default\n\t * value, returns null.\n\t * \n\t * @param key\n\t * property key\n\t * @return Returns the configured value of the given property in SoPeCo.\n\t */\n\tObject getProperty(String key);\n\n\t/**\n\t * Returns the configured value of the given property as a String.\n\t * \n\t * This method calls the {@link Object#toString()} of the property value and\n\t * is for convenience only. If the given property is not set, it returns\n\t * <code>null</code>.\n\t * \n\t * @param key\n\t * property key\n\t * \n\t * @see #getProperty(String)\n\t * @return Returns the configured value of the given property as a String.\n\t */\n\tString getPropertyAsStr(String key);\n\n\t/**\n\t * Returns the configured value of the given property as a Boolean value.\n\t * \n\t * This method uses the {@link #getPropertyAsStr(String)} and interprets\n\t * values 'yes' and 'true' (case insensitive) as a Boolean <code>true</code>\n\t * value and all other values as <code>false</code>. If the value of the\n\t * given property is <code>null</code> it returns the passed default value.\n\t * \n\t * @param key\n\t * property key\n\t * @param defaultValue\n\t * the default value returned in case of a null property value\n\t * \n\t * @return the value of the given property as a boolean\n\t * \n\t * @see #getProperty(String)\n\t */\n\tboolean getPropertyAsBoolean(String key, boolean defaultValue);\n\n\t/**\n\t * Returns the configured value of the given property as a Long value.\n\t * \n\t * This method uses the {@link Long.#parseLong(String)} to interpret the\n\t * values. If the value of the given property is <code>null</code> it\n\t * returns the passed default value.\n\t * \n\t * @param key\n\t * property key\n\t * @param defaultValue\n\t * the default value returned in case of a null property value\n\t * \n\t * @return the value of the given property as a long\n\t * \n\t * @see #getProperty(String)\n\t */\n\tlong getPropertyAsLong(String key, long defaultValue);\n\n\t/**\n\t * Returns the configured value of the given property as a Double value.\n\t * \n\t * This method uses the {@link Double.#parseLong(String)} to interpret the\n\t * values. If the value of the given property is <code>null</code> it\n\t * returns the passed default value.\n\t * \n\t * @param key\n\t * property key\n\t * @param defaultValue\n\t * the default value returned in case of a null property value\n\t * \n\t * @return the value of the given property as a double\n\t * \n\t * @see #getProperty(String)\n\t */\n\tdouble getPropertyAsDouble(String key, double defaultValue);\n\n\t/**\n\t * Returns the configured value of the given property as an Integer value.\n\t * \n\t * This method uses the {@link Integer.#parseInt(String)} to interpret the\n\t * values. If the value of the given property is <code>null</code> it\n\t * returns the passed default value.\n\t * \n\t * @param key\n\t * property key\n\t * @param defaultValue\n\t * the default value returned in case of a null property value\n\t * \n\t * @return the value of the given property as an int\n\t * \n\t * @see #getProperty(String)\n\t */\n\tint getPropertyAsInteger(String key, int defaultValue);\n\n\t/**\n\t * Sets the value of a property for the current run.\n\t * \n\t * @param key\n\t * property key\n\t * @param value\n\t * property value\n\t */\n\tvoid setProperty(String key, Object value);\n\n\t/**\n\t * Clears the value of the given property in all layers of configuration,\n\t * including the system property environment.\n\t * \n\t * @param key the property\n\t */\n\tvoid clearProperty(String key);\n\n\t/**\n\t * Returns the default value (ignoring the current runtime configuration)\n\t * for a given property.\n\t * \n\t * @param key\n\t * porperty key\n\t * \n\t * @return Returns the default value for a given property.\n\t */\n\tObject getDefaultValue(String key);\n\n\t/**\n\t * Processes the given command line arguments, the effects of which will\n\t * reflect in the global property values.\n\t * \n\t * @param args\n\t * command line arguments\n\t * @throws ConfigurationException\n\t * if there is any problem with command line arguments\n\t */\n\tvoid processCommandLineArguments(String[] args) throws ConfigurationException;\n\n\t/**\n\t * Loads default configurations from a file name. If the file name is not an\n\t * absolute path, the file is searched in the following places:\n\t * <ol>\n\t * <li>the {@value #DEFAULT_CONFIG_FOLDER_NAME} directory,</li>\n\t * <li>current folder,</li>\n\t * <li>the {@value #DEFAULT_CONFIG_FOLDER_NAME} directory in classpath,</li>\n\t * <li>and finaly the classpath.</li>\n\t * </ol>\n\t * where classpath is determined by the system class loader. See\n\t * {@link #loadDefaultConfiguration(ClassLoader, String)} for loading\n\t * default configuration providing a class loader.\n\t * \n\t * The configuration is loaded in an incremental fashion; i.e., the loaded\n\t * configuration will be added to (and overriding) the existing default\n\t * configuration.\n\t * <p>\n\t * See {@link #getAppRootDirectory()} and {@link #getDefaultValue(String)}.\n\t * \n\t * @param fileName\n\t * the name of a properties file\n\t * @throws ConfigurationException\n\t * if initializing the configuration fails\n\t * \n\t */\n\tvoid loadDefaultConfiguration(String fileName) throws ConfigurationException;\n\n\t/**\n\t * Loads default configurations from a file name. If the file name is not an\n\t * absolute path, the file is searched in the following places:\n\t * <ol>\n\t * <li>the {@value #DEFAULT_CONFIG_FOLDER_NAME} directory,</li>\n\t * <li>current folder,</li>\n\t * <li>the {@value #DEFAULT_CONFIG_FOLDER_NAME} directory in classpath,</li>\n\t * <li>and finaly the classpath.</li>\n\t * </ol>\n\t * where classpath is determined by the given class loader.\n\t * \n\t * The configuration is loaded in an incremental fashion; i.e., the loaded\n\t * configuration will be added to (and overriding) the existing default\n\t * configuration.\n\t * <p>\n\t * See {@link #getAppRootDirectory()} and {@link #getDefaultValue(String)}.\n\t * \n\t * @param classLoader\n\t * an instance of a class loader\n\t * @param fileName\n\t * the name of a properties file\n\t * @throws ConfigurationException\n\t * if initializing the configuration fails\n\t */\n\tvoid loadDefaultConfiguration(ClassLoader classLoader, String fileName) throws ConfigurationException;\n\n\t/**\n\t * Loads user-level configurations from a file name. If the file name is not\n\t * an absolute path, the file is searched in the following places:\n\t * <ol>\n\t * <li>the {@value #DEFAULT_CONFIG_FOLDER_NAME} directory,</li>\n\t * <li>current folder,</li>\n\t * <li>the {@value #DEFAULT_CONFIG_FOLDER_NAME} directory in classpath,</li>\n\t * <li>and finaly the classpath.</li>\n\t * </ol>\n\t * where classpath is determined by the system class loader. See\n\t * {@link #loadConfiguration(ClassLoader, String)} for loading default\n\t * configuration providing a class loader.\n\t * \n\t * The configuration is loaded in an incremental fashion; i.e., the loaded\n\t * configuration will be added to (and overriding) the existing default\n\t * configuration.\n\t * <p>\n\t * See {@link #getAppRootDirectory()} and {@link #getDefaultValue(String)}.\n\t * \n\t * @param fileName\n\t * the name of a properties file\n\t * @throws ConfigurationException\n\t * if initializing the configuration fails\n\t */\n\tvoid loadConfiguration(String fileName) throws ConfigurationException;\n\n\t/**\n\t * Loads user-level configurations from a file name. If the file name is not\n\t * an absolute path, the file is searched in the following places:\n\t * <ol>\n\t * <li>the {@value #DEFAULT_CONFIG_FOLDER_NAME} directory,</li>\n\t * <li>current folder,</li>\n\t * <li>the {@value #DEFAULT_CONFIG_FOLDER_NAME} directory in classpath,</li>\n\t * <li>and finally the classpath.</li>\n\t * </ol>\n\t * where classpath is determined by the given class loader.\n\t * \n\t * The configuration is loaded in an incremental fashion; i.e., the loaded\n\t * configuration will be added to (and overriding) the existing default\n\t * configuration.\n\t * <p>\n\t * See {@link #getAppRootDirectory()} and {@link #getDefaultValue(String)}.\n\t * \n\t * @param classLoader\n\t * an instance of a class loader\n\t * @param fileName\n\t * the name of a properties file\n\t * @throws ConfigurationException\n\t * if initializing the configuration fails\n\t */\n\tvoid loadConfiguration(ClassLoader classLoader, String fileName) throws ConfigurationException;\n\n\t/**\n\t * Performs any post processing of configuration settings that may be\n\t * required.\n\t * \n\t * This method can be called after manually making changes to the\n\t * configuration values. It should be called automatically after a call to\n\t * {@link IConfiguration#loadConfiguration(String)}.\n\t */\n\tvoid applyConfiguration();\n\n\t/**\n\t * Sets the value of scenario description file name.\n\t * \n\t * @param fileName\n\t * file name\n\t * @see #CONF_SCENARIO_DESCRIPTION_FILE_NAME\n\t */\n\tvoid setScenarioDescriptionFileName(String fileName);\n\n\t/**\n\t * Sets the sceanrio description as the given object. This property in\n\t * effect overrides the value of scenario description file name (\n\t * {@link IConfiguration#CONF_SCENARIO_DESCRIPTION_FILE_NAME}).\n\t * \n\t * @param sceanrioDescription\n\t * an instance of a scenario description\n\t * @see #CONF_SCENARIO_DESCRIPTION\n\t */\n\tvoid setScenarioDescription(Object sceanrioDescription);\n\n\t/**\n\t * Sets the measurement controller URI.\n\t * \n\t * @param uriStr\n\t * a URI as an String\n\t * @throws ConfigurationException\n\t * if initializing the configuration fails\n\t * @see #CONF_MEASUREMENT_CONTROLLER_URI\n\t */\n\tvoid setMeasurementControllerURI(String uriStr) throws ConfigurationException;\n\n\t/**\n\t * Sets the measurement controller class name. This also sets the\n\t * measurement controller URI to be '<code>class://[CLASS_NAME]</code>'.\n\t * \n\t * @param className\n\t * the full name of the class\n\t * @see #CONF_MEASUREMENT_CONTROLLER_CLASS_NAME\n\t */\n\tvoid setMeasurementControllerClassName(String className);\n\n\t/**\n\t * Sets the application name for this executable instance.\n\t * \n\t * @param appName\n\t * an application name\n\t */\n\tvoid setApplicationName(String appName);\n\n\t/**\n\t * Sets the main class that runs this thread. This will also be used in\n\t * finding the root folder\n\t * \n\t * @param mainClass\n\t * class to be set as main class\n\t */\n\tvoid setMainClass(Class<?> mainClass);\n\n\t/**\n\t * Sets the logger configuration file name and triggers logger\n\t * configuration.\n\t * \n\t * @param fileName\n\t * a file name\n\t */\n\tvoid setLoggerConfigFileName(String fileName);\n\n\t/**\n\t * @return Returns the application root directory.\n\t */\n\tString getAppRootDirectory();\n\n\t/**\n\t * Sets the application root directory to the given folder.\n\t * \n\t * @param rootDir\n\t * path to a folder\n\t */\n\tvoid setAppRootDirectory(String rootDir);\n\n\t/**\n\t * @return Returns the application's configuration directory.\n\t */\n\tString getAppConfDirectory();\n\n\t/**\n\t * @return Returns the value of scenario description file name.\n\t * \n\t * @see #CONF_SCENARIO_DESCRIPTION_FILE_NAME\n\t */\n\tString getScenarioDescriptionFileName();\n\n\t/**\n\t * @return returns the sceanrio description as the given object.\n\t * \n\t * @see #CONF_SCENARIO_DESCRIPTION\n\t */\n\tObject getScenarioDescription();\n\n\t/**\n\t * @return Returns the measurement controller URI.\n\t * \n\t * @see #CONF_MEASUREMENT_CONTROLLER_URI\n\t */\n\tURI getMeasurementControllerURI();\n\n\t/**\n\t * @return Returns the measurement controller URI as a String.\n\t * \n\t * @see #CONF_MEASUREMENT_CONTROLLER_URI\n\t */\n\tString getMeasurementControllerURIAsStr();\n\n\t/**\n\t * @return Returns the measurement controller class name.\n\t * \n\t * @see #CONF_MEASUREMENT_CONTROLLER_CLASS_NAME\n\t */\n\tString getMeasurementControllerClassName();\n\n\t/**\n\t * @return Returns the application name for this executable instance.\n\t */\n\tString getApplicationName();\n\n\t/**\n\t * @return Returns the main class that runs this thread. This value must\n\t * have been set by a call to\n\t * {@link IConfiguration#setMainClass(Class)}.\n\t */\n\tClass<?> getMainClass();\n\n\t/**\n\t * Writes the current configuration values into a file.\n\t * \n\t * @param fileName\n\t * the name of the file\n\t * @throws IOException\n\t * if exporting the configuration fails\n\t */\n\tvoid writeConfiguration(String fileName) throws IOException;\n\n\t/**\n\t * Overrides the values of this configuration with those of the given\n\t * configuration.\n\t * \n\t * @param configuration\n\t * with the new values\n\t */\n\t void overwrite(IConfiguration configuration);\n\n\t /**\n\t * Adds a new command-line extension to the configuration component. \n\t * \n\t * The same extension will not be added twice. \n\t * \n\t * @param extension a command-line extension\n\t */\n\t void addCommandLineExtension(ICommandLineArgumentsExtension extension);\n\t \n\t /**\n\t * Removes a new command-line extension from the configuration component. \n\t * \n\t * @param extension a command-line extension\n\t */\n\t void removeCommandLineExtension(ICommandLineArgumentsExtension extension);\n}", "@Autowired\r\n\tpublic void setSqlSessionFactory(SqlSessionFactory sqlSessionFactory) {\n\t\tsuper.setSqlSessionFactory(sqlSessionFactory);\r\n\t}", "public void getConfigProperty() {\n Properties properties = new Properties();\n try(InputStream input = new FileInputStream(\"config.properties\");){\n properties.load(input);\n logger.info(\"BASE URL :\" + properties.getProperty(\"BASEURL\"));\n setBaseUrl(properties.getProperty(\"BASEURL\"));\n setLoginMode(properties.getProperty(\"LOGINMODE\"));\n setProjectId(properties.getProperty(\"PROJECTID\"));\n setReportId(properties.getProperty(\"REPORTID\"));\n if (!(properties.getProperty(\"PASSWORD\").trim().equals(\"\"))) {\n setPassword(properties.getProperty(\"PASSWORD\"));\n }\n if (!(properties.getProperty(\"USERNAME\").trim().equals(\"\"))) {\n setUserName(properties.getProperty(\"USERNAME\"));\n }\n }catch(IOException ex) {\n logger.debug(\"Failed to fetch value from configure file: \", ex);\n }\n\n }", "public void afterPropertiesSet() throws Exception {\n\t\tSessionFactory rawSf = buildSessionFactory();\n\t\tthis.sessionFactory = wrapSessionFactoryIfNecessary(rawSf);\n\t\tafterSessionFactoryCreation();\n\t}", "void configure(Properties properties);", "private static void createSessionFactory() {\n\t\ttry {\n\t\t\tif (sessionFactory == null) {\n\n\t\t\t\tProperties properties = new Properties();\n\t\t\t\tproperties.load(ClassLoader.getSystemResourceAsStream(\"hibernate.properties\"));\n\n\t\t\t\tConfiguration configuration = new Configuration();\n\t\t\t\tEntityScanner.scanPackages(\"musala.schoolapp.model\").addTo(configuration);\n\t\t\t\tconfiguration.mergeProperties(properties).configure();\n\t\t\t\tStandardServiceRegistry builder = new StandardServiceRegistryBuilder()\n\t\t\t\t\t\t.applySettings(configuration.getProperties()).build();\n\t\t\t\tsessionFactory = configuration.buildSessionFactory(builder);\n\t\t\t}\n\t\t} catch (Exception ex) {\n\t\t\tSystem.out.println(\"Failed to create session factory object.\");\n\t\t\tex.printStackTrace();\n\t\t}\n\t}", "public abstract AbstractProperties getProperties();", "public interface ConfigurationDAO\n{\n /**\n * Export table configuration information\n * \n * @param fullTableName\n * full table name, including schema\n * @return column configurations mapped by column name\n */\n public Map<String, ColumnConfig> exportColumns(String fullTableName);\n\n /**\n * Adds column comments to column configs\n * \n * @param fullTableName\n * full table name\n * @param configs\n * ColumnConfig objects mapped to column names\n */\n public void addColumnComments(String fullTableName, Map<String, ColumnConfig> configs);\n\n /**\n * Updates table configuration based on information available from TAP tables table\n * \n * @param fullTableName\n * full name of table to update\n * @param config\n * table configuration\n * @return false if the table does not exist, else true\n */\n public boolean updateTableFromTap(String fullTableName, TableConfig config);\n\n /**\n * Updates columns configuration based on information available from TAP columns table\n * \n * @param fullTableName\n * full name of table that the columns belong to\n * @param configs\n * columns configurations\n */\n public void updateColumnsFromTap(String fullTableName, Map<String, ColumnConfig> configs);\n\n /**\n * Get index definition statements\n * \n * @param fullTableName\n * full name of table that the columns belong to\n * @return index definition statements as Strings in a List\n */\n public Map<String, String> exportIndexDefs(String fullTableName);\n\n /**\n * Get constraints information\n * \n * @param fullDbTableName\n * full database name of table that the columns belong to\n * @param constraintType\n * ConfigurationDAOImpl.FOREIGN_KEYS for foreign keys, ConfigurationDAOImpl.PRIMARY_KEYS for primary keys\n * @return Map constraint name -$gt; encoded constraint string\n */\n public Map<String, String> exportConstraints(String fullDbTableName, String constraintType);\n\n /**\n * Query for strings using the template\n * \n * @param sql\n * sql query with params placeholders\n * @param params\n * an array of params\n * @return a list of String results\n */\n public List<String> queryForStrings(String sql, Object[] params);\n\n /**\n * Get description of given table in given schema\n * \n * @param fullTableName\n * full table name\n * \n * @return table description as a String\n */\n public String exportTableDescription(String fullTableName);\n\n /**\n * Executes a statement\n * \n * @param statement\n * sql statement\n */\n public void execute(String statement);\n\n /**\n * Drops a constraint\n * \n * @param constraint\n * constraint to drop\n * @throws ConfigurationException\n * if change is not allowed\n */\n public void dropConstraint(ConstraintConfig constraint) throws ConfigurationException;\n\n /**\n * Adds a constraint\n * \n * @param constraint\n * constraint to add\n * @throws ConfigurationException\n * if change is not allowed\n */\n public void addConstraint(ConstraintConfig constraint) throws ConfigurationException;\n\n /**\n * Drops an index\n * \n * @param index\n * index to drop\n * @throws ConfigurationException\n * if change is not allowed\n */\n public void dropIndex(IndexConfig index) throws ConfigurationException;\n\n /**\n * Adds an index\n * \n * @param index\n * index to add\n * @throws ConfigurationException\n * if change is not allowed\n */\n public void addIndex(IndexConfig index) throws ConfigurationException;\n\n /**\n * Begin transaction\n */\n public void begin();\n\n /**\n * Commit transaction\n */\n public void commit();\n\n /**\n * Rollback transaction\n */\n public void rollback();\n\n /**\n * Drops column\n * \n * @param columnConfig\n * column configuration object of the column to drop\n * @throws ConfigurationException\n * if change is not allowed\n */\n public void dropColumn(ColumnConfig columnConfig) throws ConfigurationException;\n\n /**\n * Creates column\n * \n * @param columnConfig\n * column attributes\n * @throws ConfigurationException\n * if change is not allowed\n */\n public void createColumn(ColumnConfig columnConfig) throws ConfigurationException;\n\n /**\n * Updates column\n * \n * @param current\n * current column attributes\n * @param updated\n * desired column attributes\n * @throws ConfigurationException\n * if change is not allowed\n */\n public void updateColumn(ColumnConfig current, ColumnConfig updated) throws ConfigurationException;\n\n /**\n * Creates foreign key constraint\n * \n * @param constraintConfig\n * constraint configuration\n * @throws ConfigurationException\n * if change is not allowed\n */\n public void createConstraint(ConstraintConfig constraintConfig) throws ConfigurationException;\n\n /**\n * Creates index\n * \n * @param indexConfig\n * index configuration\n * @throws ConfigurationException\n * if change is not allowed\n * \n */\n public void createIndex(IndexConfig indexConfig) throws ConfigurationException;\n\n /**\n * Creates a table\n * \n * @param tableConfig\n * table configuration\n * @throws ConfigurationException\n * if change is not allowed\n */\n public void createTable(TableConfig tableConfig) throws ConfigurationException;\n\n /**\n * Delete schema from TAP metadata tables\n * \n * @param schemaConfig\n * schema configuration\n * @throws ConfigurationException\n * if change is not allowed\n */\n public void deleteTapSchema(SchemaConfig schemaConfig) throws ConfigurationException;\n\n /**\n * Create schema in TAP metadata tables\n * \n * @param schemaConfig\n * schema configuration\n * @throws ConfigurationException\n * if change is not allowed\n */\n public void createTapSchema(SchemaConfig schemaConfig) throws ConfigurationException;\n\n /**\n * Update schema in TAP metadata tables\n * \n * @param newSchema\n * schema configuration\n * @param createOnly\n * do not update the record if it exists\n * @throws ConfigurationException\n * if change is not allowed\n */\n public void updateTapSchema(SchemaConfig newSchema, boolean createOnly) throws ConfigurationException;\n\n /**\n * Delete table from TAP metadata tables\n * \n * @param tableConfig\n * table configuration\n * @throws ConfigurationException\n * if change is not allowed\n */\n public void deleteTapTable(TableConfig tableConfig) throws ConfigurationException;\n\n /**\n * Create table in TAP metadata tables\n * \n * @param tableConfig\n * table configuration\n * @throws ConfigurationException\n * if change is not allowed\n */\n public void createTapTable(TableConfig tableConfig) throws ConfigurationException;\n\n /**\n * Update table in TAP metadata tables\n * \n * @param newTable\n * table configuration\n * @param createOnly\n * do not update the record if it exists\n * @throws ConfigurationException\n * if change is not allowed\n */\n public void updateTapTable(TableConfig newTable, boolean createOnly) throws ConfigurationException;\n\n /**\n * Adds missing records and references defined by the table's keys\n * \n * @param cfgTable\n * TableConfig object to process\n * @param createOnly\n * do not update the record if it exists\n * @throws ConfigurationException\n * if change is not allowed\n */\n void updateTapTableReferences(TableConfig cfgTable, boolean createOnly) throws ConfigurationException;\n\n /* =============================================================================== */\n /* Replacements for former JPA repositories functions */\n /* =============================================================================== */\n\n /**\n * Find all TAP schemas\n * \n * @return a collection of TapSchema objects\n */\n public Collection<TapSchema> findAllSchemas();\n\n /**\n * Find all TAP tables\n * \n * @return a collection of TapTable objects\n */\n public Collection<TapTable> findAllTables();\n\n /**\n * Find a TAP schema by name\n * \n * @param schemaName\n * schema name\n * @return TapSchema object\n */\n public TapSchema findOneSchema(String schemaName);\n\n /**\n * Find all TAP columns\n * \n * @return a collection of TapColumn objects\n */\n public Collection<TapColumn> findAllColumns();\n\n /**\n * Find a TAP table by name\n * \n * @param tableName\n * column name\n * @return TapTable object\n */\n public TapTable findOneTable(String tableName);\n\n /**\n * Find all TAP key columns\n * \n * @return a collection of TapKeyColumn objects\n */\n public Collection<TapKeyColumn> findAllKeyColumns();\n\n /**\n * Find a TAP column by its key\n * \n * @param tapColumnPK\n * column key\n * @return TapColumn object\n */\n public TapColumn findOneColumn(TapColumnPK tapColumnPK);\n\n /**\n * Find all TAP keys\n * \n * @return a collection of TapKey objects\n */\n public Collection<TapKey> findAllKeys();\n\n /**\n * Get JdbcTemplate\n * \n * @return JdbcTemplate used by this DAO\n */\n public JdbcTemplate getTemplate();\n\n /**\n * Get schema name\n * \n * @return schema name of any existing table or default schema name\n */\n public String getSchema();\n\n /**\n * Make sure that TAP tables satisfy current version requirements\n * \n * @throws ConfigurationException\n * if there were configuration problems\n */\n void checkTapDbVersion() throws ConfigurationException;\n\n /**\n * Refreshes the object cache, for TAP metadata cached by the application.\n */\n public void refreshObjectCache();\n \n /**\n * Convert project codes to project ids\n * \n * @param projectCodes\n * list of project codes\n * @param schema\n * Schema of the projects table\n * @return projectIds List of project ids for codes\n */\n public List<Long> convertProjectCodesToIds(List<String> projectCodes, String schema);\n \n}", "public interface IDatabaseManager {\n\tString USERNAME = \"spring.datasource.username\";\n\n\tString PASSWORD = \"spring.datasource.password\";\n\n\tString URL = \"spring.datasource.url\";\n\n\tpublic Connection getConnection() throws SQLException ;\n\t\n\t}", "@Config.LoadPolicy(Config.LoadType.MERGE)\[email protected]({\n \"classpath:test.properties\",\n \"system:properties\",\n \"system:env\"})\npublic interface UserConfiguration extends Config {\n\n @DefaultValue(\"default_Name\")\n @Key(\"user.name\")\n String name();\n @Key(\"user.email\")\n String email();\n @Key(\"user.password\")\n String password();\n}", "private final static void getProp() {\n try(InputStream fis = ConnectionBDD.class.getClassLoader().getResourceAsStream(\"conf.properties\")){\n \n props.load(fis);\n \n Class.forName(props.getProperty(\"jdbc.driver.class\"));\n \n url = props.getProperty(\"jdbc.url\");\n login = props.getProperty(\"jdbc.login\");\n password = props.getProperty(\"jdbc.password\");\n \n } catch (ClassNotFoundException e) {\n e.printStackTrace();\n } catch (FileNotFoundException e1) {\n e1.printStackTrace();\n } catch (IOException e1) {\n e1.printStackTrace();\n }\n }", "public static Configurable configure() {\n return new SqlServerManager.ConfigurableImpl();\n }", "public void setupProp() {\r\n\t\tprop = new Properties();\r\n\t\tInputStream in = getClass().getResourceAsStream(\"C:/Users/Marcus/git/EmailProgram/EmailProgram/resources/config.properties\");\r\n\t\ttry {\r\n\t\t\tprop.load(in);\r\n\t\t\tFileInputStream fin = new FileInputStream(\"C:/Users/Marcus/git/EmailProgram/EmailProgram/resources/config.properties\");\r\n\t\t\tObjectInputStream ois = new ObjectInputStream(fin);\r\n\t\t\tdblogic = (PatronDBLogic) ois.readObject();\r\n\t\t\tois.close();\r\n\r\n\t\t} catch (IOException | ClassNotFoundException e) {\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t}", "public abstract Configuration configuration();", "public PensionParametersDAO(Configuration properties) {\n this.properties = properties;\n\n }", "private static List<Configuration> configure() {\n Map<String, Configuration> configurations = new HashMap<String, Configuration>();\n try {\n Enumeration<URL> resources = Thread.currentThread().getContextClassLoader().getResources(\"jorm.properties\");\n \n while (resources.hasMoreElements()) {\n URL url = resources.nextElement();\n \n Database.get().log.debug(\"Found jorm configuration @ \" + url.toString());\n \n Properties properties = new Properties();\n InputStream is = url.openStream();\n properties.load(is);\n is.close();\n \n String database = null;\n String destroyMethodName = null;\n String dataSourceClassName = null;\n Map<String, String> dataSourceProperties = new HashMap<String, String>();\n int priority = 0;\n \n for (Entry<String, String> property : new TreeMap<String, String>((Map) properties).entrySet()) {\n String[] parts = property.getKey().split(\"\\\\.\");\n if (parts.length < 3 || !parts[0].equals(\"database\")) {\n continue;\n }\n if (database != null && !parts[1].equals(database)) {\n try {\n Configuration conf = configurations.get(database);\n if (conf == null || conf.priority < priority) {\n conf = new Configuration(database, dataSourceClassName, dataSourceProperties, destroyMethodName, priority);\n configurations.put(database, conf);\n Database.get().log.debug(\"Configured \" + conf);\n }\n } catch (Exception ex) {\n Database.get().log.warn(\"Failed to configure database: \" + ex.getMessage());\n }\n database = parts[1];\n destroyMethodName = null;\n dataSourceClassName = null;\n dataSourceProperties = new HashMap<String, String>();\n priority = 0;\n }\n\n if (parts.length == 3 && parts[2].equals(\"destroyMethod\")) {\n destroyMethodName = property.getValue();\n } else if (parts.length == 3 && parts[2].equals(\"priority\")) {\n try {\n priority = Integer.parseInt(property.getValue().trim());\n } catch (Exception ex) {\n \n }\n } else if (parts[2].equals(\"dataSource\")) {\n if (parts.length == 3) {\n dataSourceClassName = property.getValue();\n } else if (parts.length == 4) {\n dataSourceProperties.put(parts[3], property.getValue());\n } else {\n Database.get().log.warn(\"Invalid DataSource property '\" + property.getKey() + \"'\");\n }\n } else {\n Database.get().log.warn(\"Invalid property '\" + property.getKey() + \"'\");\n }\n }\n \n if (database != null) {\n try {\n Configuration conf = configurations.get(database);\n if (conf == null || conf.priority < priority) {\n conf = new Configuration(database, dataSourceClassName, dataSourceProperties, destroyMethodName, priority);\n configurations.put(database, conf);\n Database.get().log.debug(\"Configured \" + conf);\n }\n } catch (Exception ex) {\n Database.get().log.warn(\"Failed to configure database: \" + ex.getMessage());\n }\n }\n }\n \n for (Entry<String, Configuration> entry : configurations.entrySet()) {\n entry.getValue().apply();\n Database.get().log.debug(\"Configured \" + configuration);\n }\n } catch (IOException ex) {\n Database.get().log.warn(\"Failed to configure database: \" + ex.getMessage()); \n }\n \n return new ArrayList<Configuration>(configurations.values());\n }", "public AbstractRepositoryImplConfig() {\n\t}", "@Override\n protected void createConfigurationFile(Properties connectionProperties)\n {\n connectionPoolConfiguration.setDriverClassName(CPTADatabaseConstants.DB_POSTGRES_DRIVER_PROPERTY_VALUE);\n \n // Let super class do the rest\n super.createConfigurationFile(connectionProperties);\n }", "public interface ConfigProperties {\n ConfigFileReader config = new ConfigFileReader();\n // Common configuration properties\n String WORKING_DIRECTORY = System.getProperty(\"user.dir\");\n String TestAppName = config.getProperty(\"testappname\");\n String TestExecutionType = config.getProperty(\"testexecutiontype\");\n String OsType = config.getProperty(\"ostype\");\n // String AppType = config.getProperty(\"apptype\");\n String AppType = config.getProperty(\"apptype\");\n String AppiumVersion = config.getProperty(\"appiumversion\");\n long EXPLICIT_WAIT_TIME = Integer.parseInt(config.getProperty(\"explicit.wait\"));\n long IMPLICIT_WAIT_TIME = Integer.parseInt(config.getProperty(\"implicit.wait\"));\n long DEFAULT_WAIT_TIME = Integer.parseInt(config.getProperty(\"default.wait\"));\n String APPLICATION_NAME = config.getProperty(\"key\");\n String APPIUM_PORT = config.getProperty(\"appium.server.port\");\n String APPIUM_SYSTEM_PORT = config.getProperty(\"appium.system.port\");\n int NEW_COMMAND_TIMEOUT = Integer.parseInt(config.getProperty(\"new.command.timeout\"));\n String DEVICE_READY_TIMEOUT = config.getProperty(\"device.ready.timeout\");\n String HubAddress = config.getProperty(\"HubAddress\");\n String DEVICE_CATEGORY = config.getProperty(\"Device.category\");\n String TabletSize = config.getProperty(\"Tablet.size\");\n String ExecutionEnvironment = config.getProperty(\"execution.environment\");\n //String User_Type = config.getProperty(\"usertype\");\n String User_Type = config.getProperty(\"usertype\");\n String Full_Reset = config.getProperty(\"full.reset\");\n String No_Reset = config.getProperty(\"no.reset\");\n // iOS specific configuration properties\n String IOS_AUTOMATION_NAME = config.getProperty(\"ios.automation.name\");\n String IOS_BROWSER_NAME = config.getProperty(\"ios.browser.name\");\n String IOS_PLATFORM_NAME = config.getProperty(\"ios.platform.name\");\n String IOS_PLATFORM_VERSION = config.getProperty(\"ios.platform.version\");\n String IOS_DEVICE_NAME = config.getProperty(\"ios.device.name\");\n String IOS_BUNDLE_ID = config.getProperty(\"ios.bundle.id\");\n String IOS_APPLICATION_PATH = getConfigFileLocation(config.getProperty(\"ios.application.apppath\"));\n String IOS_UDID = config.getProperty(\"ios.udid\");\n // Android specific configuration properties\n String ANDROID_AUTOMATION_NAME = config.getProperty(\"android.automation.name\");\n String ANDROID_APP_PKG = config.getProperty(\"android.app.pkg\");\n String ANDROID_APP_ACTIVITY = config.getProperty(\"android.application.activity\");\n String ANDROID_APPlICATION_PATH = getConfigFileLocation(config.getProperty(\"android.application.apppath\"));\n String ANDROID_DEVICE_NAME = config.getProperty(\"android.device.name\");\n String ANDROID_PLATFORM_VERSION = config.getProperty(\"android.platform.version\");\n // Windows specific configuration properties\n String WINDOWS_APPlICATION_PATH = getConfigFileLocation(config.getProperty(\"windows.application.apppath\"));\n String WINDOWS_DEVICE_NAME = config.getProperty(\"windows.device.name\");\n boolean SCREENSHOT_ON_PASS = Boolean.parseBoolean(config.getProperty(\"screenshotOnPass\"));\n }", "public interface Config {\n\t\t/**\n\t\t * the IdentityX policy which should be used for authentication\n\t\t *\n\t\t * @return the policy name\n\t\t */\n\t\t@Attribute(order = 100, validators = { RequiredValueValidator.class })\n\t\tString policyName();\n\n\t\t/**\n\t\t * the IdentityX application to be used\n\t\t *\n\t\t * @return the application Id\n\t\t */\n\t\t@Attribute(order = 200, validators = { RequiredValueValidator.class })\n\t\tString applicationId();\n\t\t\n\t\t\n\t\t/**\n\t\t * the IdentityX Description to be used\n\t\t *\n\t\t * @return the transactionDescription\n\t\t */\n\t\t@Attribute(order = 300, validators = { RequiredValueValidator.class })\n\t\tdefault String transactionDescription() {\n\t\t\treturn \"OpenAM has Requested an Authentication\";\n\t\t}\n\t}", "public abstract void Configure( DataMap<String, Serializable> configuration);", "protected abstract SessionFactory buildSessionFactory() throws Exception;", "public void setupProperties() {\n // left empty for subclass to override\n }", "public AbstractHibernateDAOSupport() {\n super();\n }", "public ETLLogDAOImpl(Properties properties) {\r\n this(new Configuration().addProperties(properties));\r\n }", "public interface ConfigLogic extends Config\n{\n}", "@Create\n public void init() throws IOException {\n\n final Map<String, String> persistenceProperties;\n try {\n persistenceProperties = getPersistenceProperties();\n } catch (Exception e) {\n\n // Mihai : I know, it is not elegant to cathc all the\n // exception but in this case the try/catch sequence\n // will be to big.\n log.error(e.getMessage(), e);\n throw new IOException(e);\n }\n\n final String dialect = persistenceProperties.get(HIBERNATE_DIALECT_KEY);\n if (dialect == null) {\n final String msg =\n \"The hibernate dialect is null prove your persistence.xml file\";\n final IllegalArgumentException exception =\n new IllegalArgumentException(msg);\n log.error(msg, exception);\n throw exception;\n }\n databaseSystem = DatabaseSystem.getDatabaseForDialect(dialect);\n if (databaseSystem == null) {\n final IllegalArgumentException illegalArgException =\n new IllegalArgumentException(\"The \" + dialect\n + \" is not supported.\");\n log.warn(illegalArgException.getMessage(), illegalArgException);\n throw illegalArgException;\n }\n }", "public interface Configurable {\n void setConf(Configuration conf);\n Configuration getConf();\n}", "public interface IPropertyConfigDao {\n\n PropertyConfig findByPropertyTypeAndKey(String propertyType, String propertyKey);\n}", "public PropertiesHandler(final Configuration aConfig) {\n super(aConfig);\n }", "public void init() {\n\t\tProperties prop = new Properties();\n\t\tInputStream propStream = this.getClass().getClassLoader().getResourceAsStream(\"db.properties\");\n\n\t\ttry {\n\t\t\tprop.load(propStream);\n\t\t\tthis.host = prop.getProperty(\"host\");\n\t\t\tthis.port = prop.getProperty(\"port\");\n\t\t\tthis.dbname = prop.getProperty(\"dbname\");\n\t\t\tthis.schema = prop.getProperty(\"schema\");\n\t\t\tthis.passwd=prop.getProperty(\"passwd\");\n\t\t\tthis.user=prop.getProperty(\"user\");\n\t\t} catch (IOException e) {\n\t\t\tString message = \"ERROR: db.properties file could not be found\";\n\t\t\tSystem.err.println(message);\n\t\t\tthrow new RuntimeException(message, e);\n\t\t}\n\t}", "public interface DatabaseProvider {\n\n /**\n * Optionally make any property modifications before refreshing the application context.\n *\n * @param properties properties\n * @return modified properties\n */\n Properties modifyProperties(Properties properties);\n\n\n /**\n * Create and initialize the database.\n *\n * @param properties app properties\n * @param applicationContext app context\n * @return new initialized database\n */\n Database getDatabase(Properties properties, ApplicationContext applicationContext);\n}", "public void configure(PropertiesGetter properties) {\n\t\t// TODO Auto-generated method stub\n\n\t}", "public interface PersistenceFactory {\n /* Fields */\n\n /**\n * The property name for all classes stored at the column:row level to introspect the entity that contains the\n * properties persisted in a row's columns\n */\n String CLASS_PROPERTY = \"___class\";\n\n /* Misc */\n\n /**\n * Deletes columns by name from column family\n *\n * @param columnFamily the column family\n * @param key the key\n * @param columns the columns to be deleted by name\n */\n void deleteColumns(String columnFamily, String key, String... columns);\n\n /**\n * Executes a query\n *\n * @param expectedResult the result expected from the query execution\n * @param query the query\n * @param <T> the result type\n * @return the result\n */\n <T> T executeQuery(Class<T> expectedResult, Query query);\n\n /**\n * @param entityClass the class\n * @param key the id\n * @param <T> the entity type\n * @return an entity from the data store looked up by its id\n */\n <T> T get(Class<T> entityClass, String key);\n\n /**\n * Fetch a map of columns and their values\n *\n * @param columnFamily the column family\n * @param key the column family key\n * @param reversed if the order should be reversed\n * @param columns the column names\n * @return a map of columns and their values\n */\n Map<String, ByteBuffer> getColumns(String columnFamily, String key, boolean reversed, String... columns);\n\n /**\n * Fetch a map of columns and their values\n *\n * @param columnFamily the column family\n * @param key the column family key\n * @param limit of columns\n * @param reversed if the order should be reversed\n * @param fromColumn from column\n * @param toColumn to column\n * @return a map of columns and their values\n */\n Map<String, ByteBuffer> getColumns(String columnFamily, String key, int limit, boolean reversed, String fromColumn, String toColumn);\n\n /**\n * @return the default consistency level\n */\n ConsistencyLevel getDefaultConsistencyLevel();\n\n /**\n * @return the default keyspace\n */\n String getDefaultKeySpace();\n\n /**\n * @param entityClass the class type for this instance\n * @param <T> the type of class to be returned\n * @return an instance of this type after transformation of its accessors to notify the persistence context that there are ongoing changes\n */\n <T> T getInstance(Class<T> entityClass);\n\n /**\n * Obtains an entity key\n *\n * @param entity the entity\n * @return the key\n */\n String getKey(Object entity);\n\n /**\n * The list of managed class by this factory\n *\n * @return The list of managed class by this factory\n */\n List<Class<?>> getManagedClasses();\n\n /**\n * Get a list of entities given a query\n *\n * @param type the type of objects to expect back\n * @param query the query\n * @param <T> the result type\n * @return the list of entities\n */\n <T> List<T> getResultList(Class<T> type, Query query);\n\n /**\n * Get a single result from a CQL query\n *\n * @param type the type of objects to expect back\n * @param query the query\n * @param <T> the entity type\n * @return the resulting entity\n */\n <T> T getSingleResult(Class<T> type, Query query);\n\n /**\n * Inserts columns based on a map representing keys with properties and their corresponding values\n *\n * @param columnFamily the column family\n * @param key the column family key\n * @param keyValuePairs the map with keys and values\n */\n void insertColumns(String columnFamily, String key, Map<String, Object> keyValuePairs);\n\n /**\n * Entry point method to persist and arbitrary list of objects into the datastore\n *\n * @param entities the entities to be persisted\n */\n <T> void persist(T... entities);\n\n /**\n * @param entities the entities to be removed from the data store\n */\n <T> void remove(T... entities);\n \n /**\n * return cluster\n */\n Cluster getCluster(); \n}", "private static SessionFactory buildSessionFactory() {\n\n try {\n Configuration configuration = new Configuration();\n\n Properties properties = new Properties();\n properties.load(AuthDao.class.getResourceAsStream(\"/db.properties\"));\n configuration.setProperties(properties);\n\n// configuration.addAnnotatedClass(Driver.class);\n// configuration.addAnnotatedClass(DriverStatusChange.class);\n// configuration.addAnnotatedClass(Freight.class);\n// configuration.addAnnotatedClass(Location.class);\n configuration.addAnnotatedClass(Manager.class);\n// configuration.addAnnotatedClass(Order.class);\n// configuration.addAnnotatedClass(OrderDriver.class);\n// configuration.addAnnotatedClass(OrderWaypoint.class);\n// configuration.addAnnotatedClass(Truck.class);\n// configuration.addAnnotatedClass(Waypoint.class);\n\n ServiceRegistry serviceRegistry =\n new StandardServiceRegistryBuilder().applySettings(configuration.getProperties()).build();\n\n return configuration.buildSessionFactory(serviceRegistry);\n\n } catch (IOException e) {\n e.printStackTrace();\n throw new ExceptionInInitializerError(e);\n }\n }", "protected abstract void initializeImpl(Map<String,String> configuration);", "public MySqlEngine(PdbProperties properties) throws DatabaseEngineException {\n super(MYSQL_DRIVER, properties, Dialect.MYSQL);\n }", "@Override\r\n\tpublic void setProperties(Properties properties) \r\n\t{\n\t}", "@Override\r\n\tprotected String getSqlPropertiesPath() {\n\t\treturn null;\r\n\t}", "public static Properties getProperties(){\n properties=new Properties();\n // properties.setProperty(\"selectBindDefaults\",selectBindDefaults);\n properties.setProperty(\"urlString\",urlString);\n properties.setProperty(\"userName\",userName);\n properties.setProperty(\"password\",password);\n properties.setProperty(\"packageName\",packageName);\n properties.setProperty(\"outputDirectory\",outputDirectory);\n properties.setProperty(\"taglibName\",TagLibName);\n properties.setProperty(\"jarFilename\",jarFilename);\n properties.setProperty(\"whereToPlaceJar\",whereToPlaceJar);\n properties.setProperty(\"tmpWorkDir\",tmpWorkDir);\n properties.setProperty(\"aitworksPackageBase\",aitworksPackageBase);\n properties.setProperty(\"databaseDriver\",databaseDriver);\n \n if(includeSource)\n properties.setProperty(\"includeSource\",\"true\");\n else\n properties.setProperty(\"includeSource\",\"false\");\n \n if(includeClasses)\n properties.setProperty(\"includeClasses\",\"true\");\n else\n properties.setProperty(\"includeClasses\",\"false\");\n \n if(generatedClasses)\n properties.setProperty(\"generatedClasses\",\"true\");\n else\n properties.setProperty(\"generatedClasses\",\"false\");\n\n return properties;\n }", "public TFreightConfigDao() {\n super(T_FREIGHT_CONFIG, TFreightConfig.class);\n }", "public interface HibSession extends Serializable {\n /** Set up for a hibernate interaction. Throw the object away on exception.\n *\n * @param sessFactory\n * @throws HibException\n */\n public void init(SessionFactory sessFactory) throws HibException;\n\n /**\n * @return Session\n * @throws HibException\n */\n public Session getSession() throws HibException;\n\n /**\n * @return boolean true if open\n * @throws HibException\n */\n public boolean isOpen() throws HibException;\n\n /** Clear a session\n *\n * @throws HibException\n */\n public void clear() throws HibException;\n\n /** Disconnect a session\n *\n * @throws HibException\n */\n public void disconnect() throws HibException;\n\n /** set the flushmode\n *\n * @param val\n * @throws HibException\n */\n public void setFlushMode(FlushMode val) throws HibException;\n\n /** Begin a transaction\n *\n * @throws HibException\n */\n public void beginTransaction() throws HibException;\n\n /** Return true if we have a transaction started\n *\n * @return boolean\n */\n public boolean transactionStarted();\n\n /** Commit a transaction\n *\n * @throws HibException\n */\n public void commit() throws HibException;\n\n /** Rollback a transaction\n *\n * @throws HibException\n */\n public void rollback() throws HibException;\n\n /** Did we rollback the transaction?\n *\n * @return boolean\n * @throws HibException\n */\n public boolean rolledback() throws HibException;\n\n /** Create a Criteria ready for the additon of Criterion.\n *\n * @param cl Class for criteria\n * @return Criteria created Criteria\n * @throws HibException\n */\n public Criteria createCriteria(Class<?> cl) throws HibException;\n\n /** Evict an object from the session.\n *\n * @param val Object to evict\n * @throws HibException\n */\n public void evict(Object val) throws HibException;\n\n /** Create a query ready for parameter replacement or execution.\n *\n * @param s String hibernate query\n * @throws HibException\n */\n public void createQuery(String s) throws HibException;\n\n /** Create a query ready for parameter replacement or execution and flag it\n * for no flush. This assumes that any queued changes will not affect the\n * result of the query.\n *\n * @param s String hibernate query\n * @throws HibException\n */\n public void createNoFlushQuery(String s) throws HibException;\n\n /**\n * @return query string\n * @throws HibException\n */\n public String getQueryString() throws HibException;\n\n /** Create a sql query ready for parameter replacement or execution.\n *\n * @param s String hibernate query\n * @param returnAlias\n * @param returnClass\n * @throws HibException\n */\n public void createSQLQuery(String s, String returnAlias, Class<?> returnClass)\n throws HibException;\n\n /** Create a named query ready for parameter replacement or execution.\n *\n * @param name String named query name\n * @throws HibException\n */\n public void namedQuery(String name) throws HibException;\n\n /** Mark the query as cacheable\n *\n * @throws HibException\n */\n public void cacheableQuery() throws HibException;\n\n /** Set the named parameter with the given value\n *\n * @param parName String parameter name\n * @param parVal String parameter value\n * @throws HibException\n */\n public void setString(String parName, String parVal) throws HibException;\n\n /** Set the named parameter with the given value\n *\n * @param parName String parameter name\n * @param parVal Date parameter value\n * @throws HibException\n */\n public void setDate(String parName, Date parVal) throws HibException;\n\n /** Set the named parameter with the given value\n *\n * @param parName String parameter name\n * @param parVal boolean parameter value\n * @throws HibException\n */\n public void setBool(String parName, boolean parVal) throws HibException;\n\n /** Set the named parameter with the given value\n *\n * @param parName String parameter name\n * @param parVal int parameter value\n * @throws HibException\n */\n public void setInt(String parName, int parVal) throws HibException;\n\n /** Set the named parameter with the given value\n *\n * @param parName String parameter name\n * @param parVal long parameter value\n * @throws HibException\n */\n public void setLong(String parName, long parVal) throws HibException;\n\n /** Set the named parameter with the given value\n *\n * @param parName String parameter name\n * @param parVal Object parameter value\n * @throws HibException\n */\n public void setEntity(String parName, Object parVal) throws HibException;\n\n /** Set the named parameter with the given value\n *\n * @param parName String parameter name\n * @param parVal Object parameter value\n * @throws HibException\n */\n public void setParameter(String parName, Object parVal) throws HibException ;\n\n /** Set the named parameter with the given Collection\n *\n * @param parName String parameter name\n * @param parVal Collection parameter value\n * @throws HibException\n */\n public void setParameterList(String parName,\n Collection<?> parVal) throws HibException ;\n\n /** Set the first result for a paged batch\n *\n * @param val int first index\n * @throws HibException\n */\n public void setFirstResult(int val) throws HibException;\n\n /** Set the max number of results for a paged batch\n *\n * @param val int max number\n * @throws HibException\n */\n public void setMaxResults(int val) throws HibException;\n\n /** Return the single object resulting from the query.\n *\n * @return Object retrieved object or null\n * @throws HibException\n */\n public Object getUnique() throws HibException;\n\n /** Return a list resulting from the query.\n *\n * @return List list from query\n * @throws HibException\n */\n public List getList() throws HibException;\n\n /**\n * @return int number updated\n * @throws HibException\n */\n public int executeUpdate() throws HibException;\n\n /** Update an object which may have been loaded in a previous hibernate\n * session\n *\n * @param obj\n * @throws HibException\n */\n public void update(Object obj) throws HibException;\n\n /** Merge and update an object which may have been loaded in a previous hibernate\n * session\n *\n * @param obj\n * @return Object the persiatent object\n * @throws HibException\n */\n public Object merge(Object obj) throws HibException;\n\n /** Save a new object or update an object which may have been loaded in a\n * previous hibernate session\n *\n * @param obj\n * @throws HibException\n */\n public void saveOrUpdate(Object obj) throws HibException;\n\n /** Copy the state of the given object onto the persistent object with the\n * same identifier. If there is no persistent instance currently associated\n * with the session, it will be loaded. Return the persistent instance.\n * If the given instance is unsaved or does not exist in the database,\n * save it and return it as a newly persistent instance. Otherwise, the\n * given instance does not become associated with the session.\n *\n * @param obj\n * @return Object\n * @throws HibException\n */\n public Object saveOrUpdateCopy(Object obj) throws HibException;\n\n /** Return an object of the given class with the given id if it is\n * already associated with this session. This must be called for specific\n * key queries or we can get a NonUniqueObjectException later.\n *\n * @param cl Class of the instance\n * @param id A serializable key\n * @return Object\n * @throws HibException\n */\n public Object get(Class cl, Serializable id) throws HibException;\n\n /** Return an object of the given class with the given id if it is\n * already associated with this session. This must be called for specific\n * key queries or we can get a NonUniqueObjectException later.\n *\n * @param cl Class of the instance\n * @param id int key\n * @return Object\n * @throws HibException\n */\n public Object get(Class cl, int id) throws HibException;\n\n /** Save a new object.\n *\n * @param obj\n * @throws HibException\n */\n public void save(Object obj) throws HibException;\n\n /** Delete an object\n *\n * @param obj\n * @throws HibException\n */\n public void delete(Object obj) throws HibException;\n\n /** Save a new object with the given id. This should only be used for\n * restoring the db from a save.\n *\n * @param obj\n * @throws HibException\n */\n public void restore(Object obj) throws HibException;\n\n /**\n * @param val\n * @throws HibException\n */\n public void reAttach(UnversionedDbentity<?, ?> val) throws HibException;\n\n /**\n * @param o\n * @throws HibException\n */\n public void lockRead(Object o) throws HibException;\n\n /**\n * @param o\n * @throws HibException\n */\n public void lockUpdate(Object o) throws HibException;\n\n /**\n * @throws HibException\n */\n public void flush() throws HibException;\n\n /**\n * @throws HibException\n */\n public void close() throws HibException;\n}", "public interface DBManager {\n\n\t// Populate Data can have different Implementations\n\tvoid populateData();\n}", "public interface ConfigService {\n\n\n /**\n * eureka配置\n *\n * @param sb\n * @param addr\n */\n void eureka(StringBuilder sb, String addr);\n\n /**\n * redis配置\n *\n * @param sb\n * @param addr\n */\n void redis(StringBuilder sb, String addr);\n\n\n /**\n * 数据源配置\n *\n * @param sb\n */\n void thymeleafAndDatasource(StringBuilder sb);\n\n\n /**\n * 关于mybatis的配置\n *\n * @param sb\n * @param packages\n */\n void mybatis(StringBuilder sb, String packages);\n\n\n /**\n * 分页插件配置\n *\n * @param sb\n */\n void pagehelper(StringBuilder sb);\n\n /**\n * 生成application.yml\n *\n * @param name\n */\n void application(String name);\n\n\n /**\n * 生成application-xxx.yml\n *\n * @param branch\n * @param packages\n */\n void applicationBranch(String branch, String packages);\n\n\n /**\n * log文件\n *\n */\n void logBack();\n}", "public interface HubConfig {\n\n String HUB_MODULES_DEPLOY_TIMESTAMPS_PROPERTIES = \"hub-modules-deploy-timestamps.properties\";\n String USER_MODULES_DEPLOY_TIMESTAMPS_PROPERTIES = \"user-modules-deploy-timestamps.properties\";\n String USER_CONTENT_DEPLOY_TIMESTAMPS_PROPERTIES = \"user-content-deploy-timestamps.properties\";\n\n String HUB_CONFIG_DIR = \"hub-internal-config\";\n String USER_CONFIG_DIR = \"user-config\";\n String ENTITY_CONFIG_DIR = \"entity-config\";\n String STAGING_ENTITY_SEARCH_OPTIONS_FILE = \"staging-entity-options.xml\";\n String FINAL_ENTITY_SEARCH_OPTIONS_FILE = \"final-entity-options.xml\";\n\n String DEFAULT_STAGING_NAME = \"data-hub-STAGING\";\n String DEFAULT_FINAL_NAME = \"data-hub-FINAL\";\n String DEFAULT_TRACE_NAME = \"data-hub-TRACING\";\n String DEFAULT_JOB_NAME = \"data-hub-JOBS\";\n String DEFAULT_MODULES_DB_NAME = \"data-hub-MODULES\";\n String DEFAULT_TRIGGERS_DB_NAME = \"data-hub-TRIGGERS\";\n String DEFAULT_SCHEMAS_DB_NAME = \"data-hub-SCHEMAS\";\n\n String DEFAULT_ROLE_NAME = \"data-hub-role\";\n String DEFAULT_USER_NAME = \"data-hub-user\";\n\n Integer DEFAULT_STAGING_PORT = 8010;\n Integer DEFAULT_FINAL_PORT = 8011;\n Integer DEFAULT_TRACE_PORT = 8012;\n Integer DEFAULT_JOB_PORT = 8013;\n\n String DEFAULT_AUTH_METHOD = \"digest\";\n\n String DEFAULT_SCHEME = \"http\";\n\n Integer DEFAULT_FORESTS_PER_HOST = 4;\n\n String DEFAULT_CUSTOM_FOREST_PATH = \"forests\";\n\n String getHost();\n\n // staging\n String getStagingDbName();\n void setStagingDbName(String stagingDbName);\n\n String getStagingHttpName();\n void setStagingHttpName(String stagingHttpName);\n\n Integer getStagingForestsPerHost();\n void setStagingForestsPerHost(Integer stagingForestsPerHost);\n\n Integer getStagingPort();\n void setStagingPort(Integer stagingPort);\n\n String getStagingAuthMethod();\n void setStagingAuthMethod(String stagingAuthMethod);\n\n String getStagingScheme();\n void setStagingScheme(String stagingScheme);\n\n boolean getStagingSimpleSsl();\n void setStagingSimpleSsl(boolean stagingSimpleSsl);\n\n @JsonIgnore\n SSLContext getStagingSslContext();\n void setStagingSslContext(SSLContext stagingSslContext);\n\n @JsonIgnore\n DatabaseClientFactory.SSLHostnameVerifier getStagingSslHostnameVerifier();\n void setStagingSslHostnameVerifier(DatabaseClientFactory.SSLHostnameVerifier stagingSslHostnameVerifier);\n\n String getStagingCertFile();\n void setStagingCertFile(String stagingCertFile);\n\n String getStagingCertPassword();\n void setStagingCertPassword(String stagingCertPassword);\n\n String getStagingExternalName();\n void setStagingExternalName(String stagingExternalName);\n\n // final\n String getFinalDbName();\n void setFinalDbName(String finalDbName);\n\n String getFinalHttpName();\n void setFinalHttpName(String finalHttpName);\n\n Integer getFinalForestsPerHost();\n void setFinalForestsPerHost(Integer finalForestsPerHost);\n\n Integer getFinalPort();\n void setFinalPort(Integer finalPort);\n\n String getFinalAuthMethod();\n void setFinalAuthMethod(String finalAuthMethod);\n\n String getFinalScheme();\n void setFinalScheme(String finalScheme);\n\n @JsonIgnore\n boolean getFinalSimpleSsl();\n void setFinalSimpleSsl(boolean finalSimpleSsl);\n\n @JsonIgnore\n SSLContext getFinalSslContext();\n void setFinalSslContext(SSLContext finalSslContext);\n\n DatabaseClientFactory.SSLHostnameVerifier getFinalSslHostnameVerifier();\n void setFinalSslHostnameVerifier(DatabaseClientFactory.SSLHostnameVerifier finalSslHostnameVerifier);\n\n String getFinalCertFile();\n void setFinalCertFile(String finalCertFile);\n\n String getFinalCertPassword();\n void setFinalCertPassword(String finalCertPassword);\n\n String getFinalExternalName();\n void setFinalExternalName(String finalExternalName);\n\n // traces\n String getTraceDbName();\n void setTraceDbName(String traceDbName);\n\n String getTraceHttpName();\n void setTraceHttpName(String traceHttpName);\n\n Integer getTraceForestsPerHost();\n void setTraceForestsPerHost(Integer traceForestsPerHost);\n\n Integer getTracePort();\n void setTracePort(Integer tracePort);\n\n String getTraceAuthMethod();\n void setTraceAuthMethod(String traceAuthMethod);\n\n String getTraceScheme();\n void setTraceScheme(String traceScheme);\n\n @JsonIgnore\n boolean getTraceSimpleSsl();\n void setTraceSimpleSsl(boolean traceSimpleSsl);\n\n @JsonIgnore\n SSLContext getTraceSslContext();\n void setTraceSslContext(SSLContext traceSslContext);\n\n DatabaseClientFactory.SSLHostnameVerifier getTraceSslHostnameVerifier();\n void setTraceSslHostnameVerifier(DatabaseClientFactory.SSLHostnameVerifier traceSslHostnameVerifier);\n\n String getTraceCertFile();\n void setTraceCertFile(String traceCertFile);\n\n String getTraceCertPassword();\n void setTraceCertPassword(String traceCertPassword);\n\n String getTraceExternalName();\n void setTraceExternalName(String traceExternalName);\n\n // jobs\n String getJobDbName();\n void setJobDbName(String jobDbName);\n\n String getJobHttpName();\n void setJobHttpName(String jobHttpName);\n\n Integer getJobForestsPerHost();\n void setJobForestsPerHost(Integer jobForestsPerHost);\n\n Integer getJobPort();\n void setJobPort(Integer jobPort);\n\n String getJobAuthMethod();\n void setJobAuthMethod(String jobAuthMethod);\n\n String getJobScheme();\n void setJobScheme(String jobScheme);\n\n boolean getJobSimpleSsl();\n void setJobSimpleSsl(boolean jobSimpleSsl);\n\n @JsonIgnore\n SSLContext getJobSslContext();\n void setJobSslContext(SSLContext jobSslContext);\n\n @JsonIgnore\n DatabaseClientFactory.SSLHostnameVerifier getJobSslHostnameVerifier();\n void setJobSslHostnameVerifier(DatabaseClientFactory.SSLHostnameVerifier jobSslHostnameVerifier);\n\n String getJobCertFile();\n void setJobCertFile(String jobCertFile);\n\n String getJobCertPassword();\n void setJobCertPassword(String jobCertPassword);\n\n String getJobExternalName();\n void setJobExternalName(String jobExternalName);\n\n String getModulesDbName();\n void setModulesDbName(String modulesDbName);\n\n Integer getModulesForestsPerHost();\n void setModulesForestsPerHost(Integer modulesForestsPerHost);\n\n\n // triggers\n String getTriggersDbName();\n void setTriggersDbName(String triggersDbName);\n\n Integer getTriggersForestsPerHost();\n void setTriggersForestsPerHost(Integer triggersForestsPerHost);\n\n // schemas\n String getSchemasDbName();\n void setSchemasDbName(String schemasDbName);\n\n Integer getSchemasForestsPerHost();\n void setSchemasForestsPerHost(Integer schemasForestsPerHost);\n\n // roles and users\n String getHubRoleName();\n void setHubRoleName(String hubRoleName);\n\n String getHubUserName();\n void setHubUserName(String hubUserName);\n\n\n String[] getLoadBalancerHosts();\n void setLoadBalancerHosts(String[] loadBalancerHosts);\n\n String getCustomForestPath();\n void setCustomForestPath(String customForestPath);\n\n String getModulePermissions();\n void setModulePermissions(String modulePermissions);\n\n String getProjectDir();\n void setProjectDir(String projectDir);\n\n @JsonIgnore\n HubProject getHubProject();\n\n void initHubProject();\n\n @JsonIgnore\n String getHubModulesDeployTimestampFile();\n @JsonIgnore\n String getUserModulesDeployTimestampFile();\n @JsonIgnore\n File getUserContentDeployTimestampFile();\n\n @JsonIgnore\n ManageConfig getManageConfig();\n void setManageConfig(ManageConfig manageConfig);\n @JsonIgnore\n ManageClient getManageClient();\n void setManageClient(ManageClient manageClient);\n\n @JsonIgnore\n AdminConfig getAdminConfig();\n void setAdminConfig(AdminConfig adminConfig);\n @JsonIgnore\n AdminManager getAdminManager();\n void setAdminManager(AdminManager adminManager);\n\n DatabaseClient newAppServicesClient();\n\n /**\n * Creates a new DatabaseClient for accessing the Staging database\n * @return - a DatabaseClient\n */\n DatabaseClient newStagingClient();\n\n DatabaseClient newStagingClient(String databaseName);\n\n /**\n * Creates a new DatabaseClient for accessing the Final database\n * @return - a DatabaseClient\n */\n DatabaseClient newFinalClient();\n\n /**\n * Creates a new DatabaseClient for accessing the Job database\n * @return - a DatabaseClient\n */\n DatabaseClient newJobDbClient();\n\n /**\n * Creates a new DatabaseClient for accessing the Trace database\n * @return - a DatabaseClient\n */\n DatabaseClient newTraceDbClient();\n\n /**\n * Creates a new DatabaseClient for accessing the Hub Modules database\n * @return - a DatabaseClient\n */\n DatabaseClient newModulesDbClient();\n\n @JsonIgnore\n Path getHubPluginsDir();\n @JsonIgnore\n Path getHubEntitiesDir();\n\n @JsonIgnore\n Path getHubConfigDir();\n @JsonIgnore\n Path getHubDatabaseDir();\n @JsonIgnore\n Path getHubServersDir();\n @JsonIgnore\n Path getHubSecurityDir();\n @JsonIgnore\n Path getUserSecurityDir();\n @JsonIgnore\n Path getUserConfigDir();\n @JsonIgnore\n Path getUserDatabaseDir();\n @JsonIgnore\n Path getEntityDatabaseDir();\n @JsonIgnore\n Path getUserServersDir();\n @JsonIgnore\n Path getHubMimetypesDir();\n\n @JsonIgnore\n AppConfig getAppConfig();\n void setAppConfig(AppConfig config);\n\n void setAppConfig(AppConfig config, boolean skipUpdate);\n\n String getJarVersion() throws IOException;\n}", "public interface LogConfig {\n\tLogCfg getLogCfg();\n}", "public abstract Properties getProperties();", "public BLFacadeImplementation() {\t\t\r\n\t\tSystem.out.println(\"Creating BLFacadeImplementation instance\");\r\n\t\tConfigXML c=ConfigXML.getInstance();\r\n\t\t\r\n\t\tif (c.getDataBaseOpenMode().equals(\"initialize\")) {\r\n\t\t\tDataAccess dbManager=new DataAccess(c.getDataBaseOpenMode().equals(\"initialize\"));\r\n\t\t\tdbManager.initializeDB();\r\n\t\t\tdbManager.close();\r\n\t\t\t}\r\n\t\t\r\n\t}", "@Resource\r\n\tpublic void setHibernateSessionFactory(SessionFactory hibernateSessionFactory) {\r\n\t\tsetSessionFactory(hibernateSessionFactory);\r\n\t}", "private void initializeConnectionData() throws IOException, ClassNotFoundException {\n\n\t\tFileInputStream fileInputStream = new FileInputStream(new File(AlohaTransactionManager.CONNECTION_DATA_PATH));\n\t\tProperties properties = new Properties();\n\t\t\n\t\tproperties.load(fileInputStream);\n\t\tfileInputStream.close();\n\t\t\n\t\tthis.url = properties.getProperty(\"url\");\n\t\tthis.user = properties.getProperty(\"usuario\");\n\t\tthis.password = properties.getProperty(\"clave\");\n\t\tthis.driver = properties.getProperty(\"driver\");\n\t\t\n\t\t//Class.forName(driver);\n\t}", "@Override\r\n\tpublic void setProperties(Properties arg0) {\n\r\n\t}", "EntityConfiguration getConfiguration();", "private void initializeProperties () throws Exception {\n String userHome = System.getProperty(\"user.home\");\n String userDir = System.getProperty(\"user.dir\");\n String hackyHome = userHome + \"/.hackystat\";\n String sensorBaseHome = hackyHome + \"/sensorbase\"; \n String propFile = userHome + \"/.hackystat/sensorbase/sensorbase.properties\";\n this.properties = new Properties();\n // Set defaults\n properties.setProperty(ADMIN_EMAIL_KEY, \"[email protected]\");\n properties.setProperty(ADMIN_PASSWORD_KEY, \"[email protected]\");\n properties.setProperty(CONTEXT_ROOT_KEY, \"sensorbase\");\n properties.setProperty(DB_DIR_KEY, sensorBaseHome + \"/db\");\n properties.setProperty(DB_IMPL_KEY, \"org.hackystat.sensorbase.db.derby.DerbyImplementation\");\n properties.setProperty(HOSTNAME_KEY, \"localhost\");\n properties.setProperty(LOGGING_LEVEL_KEY, \"INFO\");\n properties.setProperty(SMTP_HOST_KEY, \"mail.hawaii.edu\");\n properties.setProperty(PORT_KEY, \"9876\");\n properties.setProperty(XML_DIR_KEY, userDir + \"/xml\");\n properties.setProperty(TEST_INSTALL_KEY, \"false\");\n properties.setProperty(TEST_DOMAIN_KEY, \"hackystat.org\");\n FileInputStream stream = null;\n try {\n stream = new FileInputStream(propFile);\n properties.load(stream);\n System.out.println(\"Loading SensorBase properties from: \" + propFile);\n }\n catch (IOException e) {\n System.out.println(propFile + \" not found. Using default sensorbase properties.\");\n }\n finally {\n if (stream != null) {\n stream.close();\n }\n }\n // Now add to System properties. Since the Mailer class expects to find this stuff on the \n // System Properties, we will add everything to it. In general, however, clients should not\n // use the System Properties to get at these values, since that precludes running several\n // SensorBases in a single JVM. And just is generally bogus. \n Properties systemProperties = System.getProperties();\n systemProperties.putAll(properties);\n System.setProperties(systemProperties);\n }", "@Override\r\n\tpublic void setProperties(Properties properties) {\n\t\t\r\n\t}", "private void initializeConnectionData() throws IOException, ClassNotFoundException {\n\n\t\tFileInputStream fileInputStream = new FileInputStream(new File(AlohandesTransactionManager.CONNECTION_DATA_PATH));\n\t\tProperties properties = new Properties();\n\n\t\tproperties.load(fileInputStream);\n\t\tfileInputStream.close();\n\n\t\tthis.url = properties.getProperty(\"url\");\n\t\tthis.user = properties.getProperty(\"usuario\");\n\t\tthis.password = properties.getProperty(\"clave\");\n\t\tthis.driver = properties.getProperty(\"driver\");\n\n\t\t//Class.forName(driver);\n\t}", "public void configure() throws ConfigurationException;", "public StructureTownHallConfigDao(Configuration configuration) {\n\t\tsuper(StructureTownHallConfig.STRUCTURE_TOWN_HALL_CONFIG, StructureTownHallConfigPojo.class, configuration);\n\t}", "@Override\n public void configure(Configuration conf) throws ConfigurationException\n {\n super.configure( conf );\n lazyLoading = conf.getAttributeAsBoolean( LAZY_LOADING, false);\n getLogger().debug(\"setting lazyLoading: \" + lazyLoading);\n }", "public interface ArchivaConfiguration\n{\n\n\n String USER_CONFIG_PROPERTY = \"archiva.user.configFileName\";\n String USER_CONFIG_ENVVAR = \"ARCHIVA_USER_CONFIG_FILE\";\n\n /**\n * Get the configuration.\n *\n * @return the configuration\n */\n Configuration getConfiguration();\n\n /**\n * Save any updated configuration.\n *\n * @param configuration the configuration to save\n * @throws org.apache.archiva.components.registry.RegistryException\n * if there is a problem saving the registry data\n * @throws IndeterminateConfigurationException\n * if the configuration cannot be saved because it was read from two sources\n */\n void save( Configuration configuration )\n throws RegistryException, IndeterminateConfigurationException;\n\n /**\n * Save any updated configuration. This method allows to add a tag to the thrown event.\n * This allows to verify the origin if the caller is the same as the listener.\n *\n * @param configuration the configuration to save\n * @param eventTag the tag to add to the thrown event\n * @throws org.apache.archiva.components.registry.RegistryException\n * if there is a problem saving the registry data\n * @throws IndeterminateConfigurationException\n * if the configuration cannot be saved because it was read from two sources\n */\n void save( Configuration configuration, String eventTag )\n throws RegistryException, IndeterminateConfigurationException;\n\n /**\n * Determines if the configuration in use was as a result of a defaulted configuration.\n *\n * @return true if the configuration was created from the default-archiva.xml as opposed\n * to being loaded from the usual locations of ${user.home}/.m2/archiva.xml or\n * ${appserver.base}/conf/archiva.xml\n */\n boolean isDefaulted();\n\n /**\n * Add a configuration listener to notify of changes to the configuration.\n *\n * @param listener the listener\n */\n void addListener( ConfigurationListener listener );\n\n /**\n * Remove a configuration listener to stop notifications of changes to the configuration.\n *\n * @param listener the listener\n */\n void removeListener( ConfigurationListener listener );\n\n /**\n * Add a registry listener to notify of events in spring-registry.\n *\n * @param listener the listener\n * TODO: Remove in future.\n */\n void addChangeListener( RegistryListener listener );\n\n void removeChangeListener( RegistryListener listener );\n\n /**\n * reload configuration from file included registry\n *\n * @since 1.4-M1\n */\n void reload();\n\n public Locale getDefaultLocale();\n\n public List<Locale.LanguageRange> getLanguagePriorities();\n\n public Path getAppServerBaseDir();\n\n /**\n * Returns the base directory for repositories that have a relative location path set.\n * @return\n */\n public Path getRepositoryBaseDir();\n\n /**\n * Returns the base directory for remote repositories\n * @return\n */\n public Path getRemoteRepositoryBaseDir();\n\n /**\n * Returns the base directory for repository group files.\n * @return\n */\n public Path getRepositoryGroupBaseDir();\n\n /**\n * Returns the data directory where repositories and metadata reside\n * @return\n */\n public Path getDataDirectory();\n\n /**\n * Return the used configuration registry\n * @return\n */\n Registry getRegistry( );\n}", "protected ETLLogDAOImpl(Configuration config) {\r\n config.addClass(ETLLog.class);\r\n factory = config.buildSessionFactory();\r\n }", "public void setConnectionProperties(String hostname, String dbName, String username, String password);", "@Override\n\tpublic void setProperties(Properties p) {\n\t\t\n\t}", "public interface ConfigProcessor {\n\n\tvoid inject2Instance(Object obj,String keyName);\n\n\tvoid storeOneFile(ConfigBaseModel configBaseModel);\n\n\tvoid inject2Conf();\n\n}", "public void setSessionFactory(SessionFactory sessionFactory) {\n template = new HibernateTemplate(sessionFactory);\n}", "private static SessionFactory buildSessionFactory() {\n\t\ttry {\n\t\t\tConfiguration config = new Configuration().configure(); \n\t\t\tServiceRegistry serviceRegistry =\n\t\t\t\t\tnew StandardServiceRegistryBuilder()\n\t\t\t.applySettings(config.getProperties()).build();\n\n\t\t\tHibernatePBEEncryptorRegistry registry = HibernatePBEEncryptorRegistry.getInstance();\n\t\t\t\n\t\t\tStandardPBEStringEncryptor myEncryptor = new StandardPBEStringEncryptor();\n\t\t\t// FIXME : this is insecure and needs to be fixed\n\t\t\tmyEncryptor.setPassword(\"123\");\n\t\t\tregistry.registerPBEStringEncryptor(\"myHibernateStringEncryptor\", myEncryptor);\n\t\t\t\n\t\t\t\n\t\t\treturn config.buildSessionFactory(serviceRegistry); \n\t\t}\n\t\tcatch (Throwable ex) {\n\t\t\t// Make sure you log the exception, as it might be swallowed\n\t\t\tSystem.err.println(\"Initial SessionFactory creation failed.\" + ex);\n\t\t\tthrow new ExceptionInInitializerError(ex);\n\t\t}\n\t}", "public interface IAppConfig {\n public List<String> getSpringProfileNames();\n public List<String> getSpringProfileClasses();\n public boolean isThreadPoolEnabled();\n public List<ThreadPoolConfig> getThreadPoolConfigs();\n public String getAppConfigClass();\n}", "protected void setUp() \r\n {\n System.out.println(\"Setting up User Test !\");\r\n \t//lProps = new Properties();\t\r\n //lProps.put(Context.INITIAL_CONTEXT_FACTORY,lContextFactory);\r\n //lProps.put(Context.PROVIDER_URL,lURL);\r\n //lProps.put(Context.URL_PKG_PREFIXES,lPrefixes);\r\n try\r\n {\r\n lProps.list(System.out);\r\n lIC = new InitialContext(lProps);\r\n //sLog.debug(\"Created Initial Context\");\r\n System.out.println(\"Created Initial Context-looking for UserHome\");\r\n Object homeObj = lIC.lookup(lJndiName);\r\n System.out.println(\"got Object!\");\r\n lHome = (UserHome) PortableRemoteObject.narrow(homeObj,UserHome.class); \r\n \r\n //lSessionHome = (PJVTProducerSessionHome) lIC.lookup(lJndiName);\r\n \r\n System.out.println(\"User Home:\"+lHome.toString());\r\n \r\n }\r\n catch(Throwable t)\r\n {\r\n t.printStackTrace();\r\n }\r\n\t}", "public ClassParametersPanel(Annotated propertiesClass) {\n initComponents();\n this.propertiesClass = propertiesClass;\n loadTableProperties(this.propertiesClass);\n\n }", "public interface AssociationClassConfiguration extends AssociationClass, ClassConfiguration, AssociationConfiguration {\n}", "public Properties getProperties() {\n \tProperties p = new Properties(); \n if (charSet != null) {\n \t p.put(\"charSet\",charSet);\n } \n\t\n\tif (user != null) {\n \t p.put(\"user\", user);\n }\n\t\n\tif (password != null) {\n \t p.put(\"password\", password);\n }\n\t\n\tif (url != null){\n\t p.put(\"url\",url);\t\n\t}\t\n\tp.put(\"loginTimeout\",\"\"+loginTimeout);\n \treturn p; \n }", "public TestBase() {\n try {\n properties = new Properties();\n FileInputStream fileInputStream = new FileInputStream(\"F:/LearningStuff/PracticalWork\" +\n \"/Frameworks/DataDrivenFrameworkSelenium/src/main/resources/config/config.properties\");\n properties.load(fileInputStream);\n } catch (FileNotFoundException f) {\n f.printStackTrace();\n } catch (IOException i) {\n i.printStackTrace();\n }\n }", "public void init(SessionFactory sessFactory) throws HibException;", "private void setUpConnection(DataBaseProps dataBaseConfig) {\n\t\tHikariConfig hikariConfig = new HikariConfig();\r\n\t\thikariConfig.setDriverClassName(dataBaseConfig.getDriverName());\r\n\t\thikariConfig.setJdbcUrl(dataBaseConfig.getUrl());\r\n\t\thikariConfig.setUsername(dataBaseConfig.getUsername());\r\n\t\thikariConfig.setPassword(dataBaseConfig.getPassword());\r\n\t\thikariConfig.setMaximumPoolSize(maximumPoolSize);\r\n\t\thikariConfig.setValidationTimeout(validationTimeout);\r\n\t\thikariConfig.setConnectionTimeout(connectionTimeout);\r\n\t\thikariConfig.setIdleTimeout(idleTimeout);\r\n\t\thikariConfig.setMinimumIdle(minimumIdle);\r\n\t\tHikariDataSource dataSource = new HikariDataSource(hikariConfig);\r\n\t\tthis.jdbcTemplate = new NamedParameterJdbcTemplate(dataSource);\r\n\t}", "public static void configuration() {\n\t\tProperties prop = new Properties();\n\t\tOutputStream output = null;\n\t\tInputStream input = null;\n\t\tString url = \"\", username = \"\", password;\n\t\tboolean test = false;\n\n\t\ttry {\n\t\t\tFile config = new File(configDirectory);\n\t\t\tif (!config.exists()) {\n\t\t\t\twhile (!test) {\n\t\t\t\t\toutput = new FileOutputStream(configDirectory);\n\n\t\t\t\t\tSystem.out\n\t\t\t\t\t\t\t.print(\"Configuration in progress, please answer the next set of questions to setup your database.\"\n\t\t\t\t\t\t\t\t\t+ \"\\n\"\n\t\t\t\t\t\t\t\t\t+ \"\\nDatabase URL: (Default localhost:3306/<database name>)\");\n\t\t\t\t\turl = UserInput.stringUserInput();\n\n\t\t\t\t\tSystem.out.print(\"Database Username: \");\n\t\t\t\t\tusername = UserInput.stringUserInput();\n\n\t\t\t\t\tSystem.out.print(\"Database password: \");\n\t\t\t\t\tpassword = UserInput.stringUserInput();\n\n\t\t\t\t\tDatabaseManager.setUrl(\"jdbc:mariadb://\" + url);\n\t\t\t\t\tDatabaseManager.setUser(username);\n\t\t\t\t\tDatabaseManager.setPass(password);\n\n\t\t\t\t\ttest = DatabaseManager.testDatabaseConnection();\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tDatabaseManager.createDB();\n\n\t\t\t\ttest = false;\n\n\t\t\t\tString adminPassword = \"\", adminPasswordVerify;\n\n\t\t\t\twhile (!test) {\n\t\t\t\t\tSystem.out\n\t\t\t\t\t\t\t.print(\"Admin Account Password for Application: \");\n\t\t\t\t\tadminPassword = HashGeneratorUtils.generateHash(UserInput\n\t\t\t\t\t\t\t.stringUserInput());\n\n\t\t\t\t\tSystem.out.print(\"Verify Admin Password for Application: \");\n\t\t\t\t\tadminPasswordVerify = UserInput.stringUserInput();\n\n\t\t\t\t\ttest = HashGeneratorUtils.hashCompareTest(\n\t\t\t\t\t\t\tadminPasswordVerify, adminPassword);\n\t\t\t\t}\n\n\t\t\t\t// set the properties value\n\t\t\t\tprop.setProperty(\"database\", \"jdbc:mariadb://\" + url);\n\t\t\t\tprop.setProperty(\"adminpass\", adminPassword);\n\n\t\t\t\t// save properties to project folder\n\t\t\t\tprop.store(output, null);\n\t\t\t} else {\n\t\t\t\tinput = new FileInputStream(configDirectory);\n\n\t\t\t\t// load the property file\n\t\t\t\tprop.load(input);\n\n\t\t\t\t// get and set the property value\n\t\t\t\tDatabaseManager.setUrl(prop.getProperty(\"database\"));\n\t\t\t}\n\n\t\t} catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t}", "public ComponentProperties() throws WebserverSystemException {\r\n\r\n // setting up some default values\r\n setCreatedById(UserContext.getId());\r\n setCreatedByName(UserContext.getRealName());\r\n }", "protected void configureConnectionPool() {\n JdbcPropertyAdapter adapter = getPropertyAdapter(dbType, properties);\n JdbcConnectionProvider cp = new JdbcConnectionProvider(this.translator, adapter);\n this.connectionPool = new PoolConnectionProvider(cp, this.maxConnectionPoolSize);\n this.transactionProvider = new SimpleTransactionProvider(this.connectionPool);\n }" ]
[ "0.6432677", "0.63463646", "0.6123049", "0.5951732", "0.5873454", "0.5748036", "0.5733386", "0.56082314", "0.5604343", "0.5582689", "0.55547935", "0.5523797", "0.55154186", "0.55123806", "0.55105764", "0.54532206", "0.5426894", "0.5399725", "0.5394757", "0.5392399", "0.5390745", "0.5380992", "0.53321916", "0.5326105", "0.53187674", "0.5302549", "0.5268794", "0.5268226", "0.52641594", "0.52602494", "0.5249638", "0.52356225", "0.52173144", "0.5209628", "0.5204359", "0.52035475", "0.51975733", "0.51919305", "0.51849556", "0.51829743", "0.51771474", "0.51763576", "0.5166309", "0.51650536", "0.51448244", "0.5139713", "0.51349473", "0.510779", "0.51042175", "0.50908047", "0.5066931", "0.50564075", "0.5054678", "0.5053108", "0.50493205", "0.50342906", "0.50309527", "0.5022187", "0.5019415", "0.501936", "0.5017895", "0.50154954", "0.5011567", "0.5009439", "0.50092536", "0.50044316", "0.49986422", "0.49886075", "0.49868327", "0.4962197", "0.49617583", "0.4958259", "0.4958174", "0.49555826", "0.49516082", "0.49515358", "0.49513388", "0.49510354", "0.49494737", "0.4949359", "0.49456638", "0.4932856", "0.4932379", "0.4929571", "0.4929078", "0.49207792", "0.491647", "0.49131754", "0.49117732", "0.49113885", "0.4910964", "0.49071488", "0.49003714", "0.48983625", "0.48945457", "0.4887431", "0.48865798", "0.4877895", "0.48711318", "0.48676762" ]
0.70460767
0
Returns all programmatically set properties that shall be used in the hibernate configuration.
public Properties getProperties();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private Properties hibernateProperties() {\r\n\t\tProperties properties = new Properties();\r\n\t\tproperties.put(org.hibernate.cfg.Environment.DIALECT, \"org.hibernate.dialect.MySQL5Dialect\");\r\n\t\tproperties.put(org.hibernate.cfg.Environment.SHOW_SQL, true);\r\n properties.put(org.hibernate.cfg.Environment.FORMAT_SQL, true);\r\n properties.put(org.hibernate.cfg.Environment.HBM2DDL_AUTO, \"update\");\r\n return properties;\r\n\t}", "private Properties getHibernateProperties() {\n\t\tProperties properties = new Properties();\n\t\tproperties.put(\"hibernate.show_sql\", \"true\");\n\t\tproperties.put(\"hibernate.dialect\", \"org.hibernate.dialect.MySQLDialect\");\n\t\tproperties.put(\"hbm2ddl.auto\", \"create\");\n\t\tproperties.put(\"hibernate.id.new_generator_mappings\", \"false\");\n\t\t\n\t\treturn properties;\n\t}", "private Properties getHibernateProperties() {\r\n\t\tProperties properties = new Properties();\r\n\t\tproperties.put(\"hibernate.dialect\", hibernateDialect); // -> database specific property\r\n\t\t// -> this will allow us to see the sql query executed.\r\n\t\tproperties.put(\"hibernate.show_sql\", showSql);\r\n\t\t// -> this will format the sql query.\r\n\t\tproperties.put(\"hibernate.format_sql\", formatSql);\r\n\t\t// -> this will allow us to automatically create, update or drop the table in\r\n\t\t// the database.\r\n\t\t// properties.put(\"hibernate.hbm2ddl.auto\", hbm2ddl);\r\n\t\treturn properties;\r\n\t}", "private Properties jpaProperties() {\n\n Properties props = new Properties();\n\n props.setProperty(\"hibernate.dialect\", jdbcPropsValues.getHibernateDialect());\n props.setProperty(\"hibernate.show_sql\", jdbcPropsValues.getHibernateShowSql());\n\n return props;\n }", "public interface HibernateProperties\r\n{\r\n /**\r\n * Returns all programmatically set properties that shall be used in the hibernate configuration.\r\n * \r\n * @return Null can be returned. The returned property class can be empty.\r\n */\r\n public Properties getProperties();\r\n \r\n /**\r\n * This method will replace the currently set properties with the given properties. This is not a\r\n * merge!. Existing properties will be wiped out.\r\n * \r\n * @param properties\r\n */\r\n public void setProperties(Properties properties);\r\n\r\n /**\r\n * This method will set/replace the property given by its key with the given value.\r\n * \r\n * @param key The name of the property to set/replace.\r\n * @param value The value to set/replace the property with.\r\n */\r\n public void addProperty(String key, String value);\r\n}", "private static Properties getProperties() {\n Properties properties = new Properties();\n\n try {\n properties.load(new FileInputStream(\"src/main/resources/hibernate.properties\"));\n } catch (IOException e) {\n throw new RuntimeException(e);\n }\n\n return properties;\n }", "Map<String, String> getConfigProperties();", "@Override\n public ConfigurablePropertyMap getProperties() {\n return properties;\n }", "public Properties getProperties() {\n \tProperties p = new Properties(); \n if (charSet != null) {\n \t p.put(\"charSet\",charSet);\n } \n\t\n\tif (user != null) {\n \t p.put(\"user\", user);\n }\n\t\n\tif (password != null) {\n \t p.put(\"password\", password);\n }\n\t\n\tif (url != null){\n\t p.put(\"url\",url);\t\n\t}\t\n\tp.put(\"loginTimeout\",\"\"+loginTimeout);\n \treturn p; \n }", "public Set getPropertyNames(){\n return this.vendorSpecificProperties;\n }", "@Override\n\t\tpublic Map<String, Object> getAllProperties() {\n\t\t\treturn null;\n\t\t}", "public Map<String, String> getAllProperties()\n {\n return _propertyEntries;\n }", "Properties getProperties();", "public static String getDbProps(){\n return properties.getProperty(\"dbprops\");\n }", "public abstract AbstractProperties getProperties();", "protected static Properties getProperties(boolean dflt) {\r\n Properties prop = new Properties();\r\n for (ConfigurationOption<?> option : OPTIONS.values()) {\r\n option.toProperties(prop, dflt);\r\n }\r\n return prop;\r\n }", "private static List<Configuration> configure() {\n Map<String, Configuration> configurations = new HashMap<String, Configuration>();\n try {\n Enumeration<URL> resources = Thread.currentThread().getContextClassLoader().getResources(\"jorm.properties\");\n \n while (resources.hasMoreElements()) {\n URL url = resources.nextElement();\n \n Database.get().log.debug(\"Found jorm configuration @ \" + url.toString());\n \n Properties properties = new Properties();\n InputStream is = url.openStream();\n properties.load(is);\n is.close();\n \n String database = null;\n String destroyMethodName = null;\n String dataSourceClassName = null;\n Map<String, String> dataSourceProperties = new HashMap<String, String>();\n int priority = 0;\n \n for (Entry<String, String> property : new TreeMap<String, String>((Map) properties).entrySet()) {\n String[] parts = property.getKey().split(\"\\\\.\");\n if (parts.length < 3 || !parts[0].equals(\"database\")) {\n continue;\n }\n if (database != null && !parts[1].equals(database)) {\n try {\n Configuration conf = configurations.get(database);\n if (conf == null || conf.priority < priority) {\n conf = new Configuration(database, dataSourceClassName, dataSourceProperties, destroyMethodName, priority);\n configurations.put(database, conf);\n Database.get().log.debug(\"Configured \" + conf);\n }\n } catch (Exception ex) {\n Database.get().log.warn(\"Failed to configure database: \" + ex.getMessage());\n }\n database = parts[1];\n destroyMethodName = null;\n dataSourceClassName = null;\n dataSourceProperties = new HashMap<String, String>();\n priority = 0;\n }\n\n if (parts.length == 3 && parts[2].equals(\"destroyMethod\")) {\n destroyMethodName = property.getValue();\n } else if (parts.length == 3 && parts[2].equals(\"priority\")) {\n try {\n priority = Integer.parseInt(property.getValue().trim());\n } catch (Exception ex) {\n \n }\n } else if (parts[2].equals(\"dataSource\")) {\n if (parts.length == 3) {\n dataSourceClassName = property.getValue();\n } else if (parts.length == 4) {\n dataSourceProperties.put(parts[3], property.getValue());\n } else {\n Database.get().log.warn(\"Invalid DataSource property '\" + property.getKey() + \"'\");\n }\n } else {\n Database.get().log.warn(\"Invalid property '\" + property.getKey() + \"'\");\n }\n }\n \n if (database != null) {\n try {\n Configuration conf = configurations.get(database);\n if (conf == null || conf.priority < priority) {\n conf = new Configuration(database, dataSourceClassName, dataSourceProperties, destroyMethodName, priority);\n configurations.put(database, conf);\n Database.get().log.debug(\"Configured \" + conf);\n }\n } catch (Exception ex) {\n Database.get().log.warn(\"Failed to configure database: \" + ex.getMessage());\n }\n }\n }\n \n for (Entry<String, Configuration> entry : configurations.entrySet()) {\n entry.getValue().apply();\n Database.get().log.debug(\"Configured \" + configuration);\n }\n } catch (IOException ex) {\n Database.get().log.warn(\"Failed to configure database: \" + ex.getMessage()); \n }\n \n return new ArrayList<Configuration>(configurations.values());\n }", "public static Properties getProperties() {\r\n return getProperties(false);\r\n }", "Map<String, String> properties();", "Map<String, String> properties();", "public Set<String> stringPropertyNames() {\n return userConfig.stringPropertyNames();\n }", "public Set<ConfigSetDTO> getSetProperties() {\n \t\treturn new HashSet<ConfigSetDTO>(setProperties.values());\n \t}", "Map<String, String> getProperties();", "Map<String, String> getProperties();", "public static Properties getProperties() {\n\t\tProperties properties = new Properties();\n\t\tproperties.setProperty(\"user\", \"root\");\n\t\tproperties.setProperty(\"password\", \"password1\");\n\t\tproperties.setProperty(\"useSSL\", \"false\");\n\n\t\treturn properties;\n\t}", "public abstract Properties getProperties();", "public Set<String> getDeclaredProperties() {\n \t\tfinal Set<String> ret = new HashSet<String>();\n \t\tret.addAll(complexProperties.keySet());\n \t\tret.addAll(simpleProperties.keySet());\n \t\tret.addAll(listProperties.keySet());\n \t\tret.addAll(setProperties.keySet());\n \t\tret.addAll(mapProperties.keySet());\n \t\treturn ret;\n \t}", "java.lang.String getProperties();", "public Hashtable getProperties() {\n PropertyHelper ph = PropertyHelper.getPropertyHelper(this);\n return ph.getProperties();\n }", "public Set<ConfigProperty> values() {\n return new HashSet<>(_properties.values());\n }", "private Properties getDbProperties() {\n if (dbProperties == null) {\n // like ~/Dropbox/ACM-UWR/config.properties\n File propertiesFile = getSandbox().inputFile(pathsProvider.getProgramConfigFile().toPath());\n if (propertiesFile.exists()) {\n try {\n BufferedInputStream in = new BufferedInputStream(\n new FileInputStream(propertiesFile));\n Properties props = new Properties();\n props.load(in);\n dbProperties = props;\n } catch (IOException e) {\n throw new RuntimeException(\"Unable to load configuration file: \"\n + propertiesFile.getName(), e);\n }\n }\n }\n return dbProperties;\n }", "public Iterator<String> getUserDefinedProperties();", "protected java.util.Map getProperties() {\n return properties;\n }", "public Hashtable getUserProperties() {\n PropertyHelper ph = PropertyHelper.getPropertyHelper(this);\n return ph.getUserProperties();\n }", "EProperties getProperties();", "CommonProperties getProperties();", "private ConfigProperties getProperties() {\n return properties;\n }", "public Properties getProperties() {\n\t\tif (isStale()) {\n\t\t\tlogger.info(\"getProperties: is stale (reloading\");\n\t\t\tload();\n\t\t}\n\t\treturn properties;\n\t}", "public Map<String, String> getProperties() {\n\t\tif (propertiesReader == null) {\n\t\t\tpropertiesReader = new PropertyFileReader();\n\t\t}\n\t\tpropertyMap = propertiesReader.getPropertyMap();\n\t\tlog.info(\"fetched all properties\");\n\t\treturn propertyMap;\n\t}", "public abstract List<BeanPropertyDefinition> findProperties();", "@Override\n\tpublic Set<OWLEntity> getAllProperties() {\n\t\tSet<OWLEntity> result = new HashSet<OWLEntity>();\n\t\tresult.addAll(ontology.getObjectPropertiesInSignature());\n\t\treturn result;\n\t}", "public Map getProperties();", "public Map getProperties() {\n HttpSession session = (HttpSession) _currentSession.get();\n if (session == null) {\n return new HashMap();\n }\n HashMap properties = new HashMap();\n Enumeration enuAttributes = session.getAttributeNames();\n while (enuAttributes.hasMoreElements()) {\n String nextAttribute = (String) enuAttributes.nextElement();\n Object value = session.getAttribute(nextAttribute);\n properties.put(nextAttribute, value);\n }\n return properties;\n }", "public Properties getProperties() {\n Properties properties = new Properties();\n properties.setProperty(\"advice\", \"method interceptor\");\n properties.setProperty(\"scope\", \"per-instance\");\n return properties;\n }", "public HashMap<String, String> getProperties() {\n return (HashMap<String, String>) properties.clone();\n }", "@Override\n\tpublic List<Property> findAll() {\n\t\treturn pr.findAll();\n\t}", "public Set<ConfigListDTO> getListProperties() {\n \t\treturn new HashSet<ConfigListDTO>(listProperties.values());\n \t}", "public Map<String, Property> getProperties()\n {\n return properties;\n }", "Map<String, Object> properties();", "private Map<String, String> getPersistenceProperties() throws Exception {\n final Map<String, String> result = new HashMap<String, String>();\n\n // mihai : I have this code from the hibernate classes, I\n // know it is not so nice but if it works for hibernate\n // it must also work for me.\n // I don't have any other 'decent' way to obtains the\n // information persistence layer informations.\n final Ejb3Configuration cfg = new Ejb3Configuration();\n final Enumeration<URL> persistenceXML =\n Thread.currentThread().getContextClassLoader()\n .getResources(\"META-INF/persistence.xml\");\n\n for (; persistenceXML.hasMoreElements();) {\n final URL nextURL = persistenceXML.nextElement();\n final HashMap overwrite = new HashMap();\n final List<PersistenceMetadata> metadataFiles =\n PersistenceXmlLoader.deploy(nextURL, overwrite, cfg\n .getHibernateConfiguration().getEntityResolver(),\n PersistenceUnitTransactionType.RESOURCE_LOCAL);\n for (final PersistenceMetadata metadata : metadataFiles) {\n for (final Object key : metadata.getProps().keySet()) {\n final String keyStr = key.toString();\n final String valueStr =\n metadata.getProps().get(key).toString();\n result.put(keyStr, valueStr);\n }\n }\n }\n\n return result;\n }", "public Properties getProperties()\n {\n Properties properties = null;\n List<Props.Entry> props = this.props.getEntry();\n if ( props.size() > 0 )\n {\n properties = new Properties();\n //int size = props.size();\n for ( Props.Entry entry : props )\n {\n String key = entry.getKey();\n String val = entry.getValue();\n properties.setProperty( key, val );\n }\n }\n return properties;\n }", "public Map<String, String> getProperties() {\n return properties;\n }", "Property[] getProperties();", "public Map<String, Object> getSessionProperties() {\n return sessionProperties;\n }", "public List<NamedThing> getProperties() {\n // TODO this should be changed to AnyProperty type but it as impact everywhere\n List<NamedThing> properties = new ArrayList<>();\n List<Field> propertyFields = getAnyPropertyFields();\n for (Field f : propertyFields) {\n try {\n if (NamedThing.class.isAssignableFrom(f.getType())) {\n f.setAccessible(true);\n Object fValue = f.get(this);\n if (fValue != null) {\n NamedThing se = (NamedThing) fValue;\n properties.add(se);\n } // else not initalized but this is already handled in the initProperties that must be called\n // before the getProperties\n }\n } catch (IllegalAccessException e) {\n throw new TalendRuntimeException(CommonErrorCodes.UNEXPECTED_EXCEPTION, e);\n }\n }\n return properties;\n }", "public Collection<ModuleProperty> getProperties();", "public Map<String, String> getProperties() {\n return properties;\n }", "public Map<String, String> getProperties() {\n return properties;\n }", "public static Properties getProperties(){\n properties=new Properties();\n // properties.setProperty(\"selectBindDefaults\",selectBindDefaults);\n properties.setProperty(\"urlString\",urlString);\n properties.setProperty(\"userName\",userName);\n properties.setProperty(\"password\",password);\n properties.setProperty(\"packageName\",packageName);\n properties.setProperty(\"outputDirectory\",outputDirectory);\n properties.setProperty(\"taglibName\",TagLibName);\n properties.setProperty(\"jarFilename\",jarFilename);\n properties.setProperty(\"whereToPlaceJar\",whereToPlaceJar);\n properties.setProperty(\"tmpWorkDir\",tmpWorkDir);\n properties.setProperty(\"aitworksPackageBase\",aitworksPackageBase);\n properties.setProperty(\"databaseDriver\",databaseDriver);\n \n if(includeSource)\n properties.setProperty(\"includeSource\",\"true\");\n else\n properties.setProperty(\"includeSource\",\"false\");\n \n if(includeClasses)\n properties.setProperty(\"includeClasses\",\"true\");\n else\n properties.setProperty(\"includeClasses\",\"false\");\n \n if(generatedClasses)\n properties.setProperty(\"generatedClasses\",\"true\");\n else\n properties.setProperty(\"generatedClasses\",\"false\");\n\n return properties;\n }", "@Override\r\n\tpublic Properties getProperties() {\n\t\treturn null;\r\n\t}", "List<? extends T> getDeclaredProperties();", "protected List getProperties() {\n return null;\n }", "private Properties getMailProperties() {\n Properties properties = new Properties();\n properties.setProperty(\"mail.transport.protocol\", \"smtp\");\n properties.setProperty(\"mail.smtps.auth\", \"true\");\n properties.setProperty(\"mail.smtp.starttls.required\", \"true\");\n properties.setProperty(\"mail.smpt.starttls.enable\", \"true\");\n properties.setProperty(\"mail.debug\", \"false\"); // set to true for debugging information\n \n return properties;\n }", "private static ChainedProperties getChainedProperties() {\n return new ChainedProperties(\"packagebuilder.conf\", BRMSPackageBuilder.class.getClassLoader(), // pass this as it searches currentThread anyway\n false);\n }", "public Set<Pp> getProperties() {\n return properties;\n }", "public StaticPropertyOracle[] getPropertyOracles() {\n return orderedPropertyOracles.toArray(new StaticPropertyOracle[orderedPropertyOracles.size()]);\n }", "private final static void getProp() {\n try(InputStream fis = ConnectionBDD.class.getClassLoader().getResourceAsStream(\"conf.properties\")){\n \n props.load(fis);\n \n Class.forName(props.getProperty(\"jdbc.driver.class\"));\n \n url = props.getProperty(\"jdbc.url\");\n login = props.getProperty(\"jdbc.login\");\n password = props.getProperty(\"jdbc.password\");\n \n } catch (ClassNotFoundException e) {\n e.printStackTrace();\n } catch (FileNotFoundException e1) {\n e1.printStackTrace();\n } catch (IOException e1) {\n e1.printStackTrace();\n }\n }", "@Override\n public Map<String, String> getProperties() {\n return null;\n }", "@Override\n public Map<String, String> getProperties()\n {\n return null;\n }", "PropertyRegistry getPropertyRegistry();", "@Override\n\tpublic List<Config_Entity> get_all_config() {\n\t\treturn config.get_all_config();\n\t}", "StringMap getProperties();", "default Map<String, Object> getProperties()\r\n {\r\n return emptyMap();\r\n }", "public static Properties getProperties() {\n \tif (!propertiesLoaded)\n \t\tSystem.err.println(\"Warning: Default properties loaded\");\n \t\n \t\n \tif (properties == null)\n \t\tproperties = new Properties();\n \t\n \t\n \treturn properties;\n }", "public Set<Property> getProperties() {\r\n\t\treturn properties;\r\n\t}", "public void setupProperties() {\n // left empty for subclass to override\n }", "public WorkbenchProperties getProperties() {\r\n return properties;\r\n }", "public java.util.Map<String,String> getProperties() {\n \n if (properties == null) {\n properties = new java.util.HashMap<String,String>();\n }\n return properties;\n }", "public Map<String, String> properties() {\n return this.properties;\n }", "@SuppressWarnings(\"unchecked\")\n\tpublic List<CustomerProperty> findAll() {\n\t\tlog.info(\"finding all CustomerProperty instances\");\n\t\ttry {\n\t\t\tfinal String queryString = \"select model from CustomerProperty model\";\n\t\t\tQuery query = getEntityManager().createQuery(queryString);\n\t\t\treturn query.getResultList();\n\t\t} catch (RuntimeException e) {\n\t\t\tlog.error(\"find all failed\", e);\n\t\t\tthrow e;\n\t\t}\n\t}", "@Override\n\t@SuppressWarnings(\"unchecked\")\n\t@Transactional(propagation = Propagation.SUPPORTS)\n\tpublic List<Property> findPropertyNames() \n\t{\n\t\tList<Property> details = entityManager.createNamedQuery(\"Property.readPropertyNames\").getResultList();\n\t\tlogger.info(\"Property Details are:\" + details);\n\t\treturn details;\n\t}", "@RolesAllowed(RolesConstants.ADMIN_MANAGE_SETTINGS)\n @Override\n public Configuration getDbConfiguration() {\n return getRepository().getDbConnectionManager().getSqlSessionFactory().getConfiguration();\n }", "public Properties getProperties() { return props; }", "protected Properties getMailProperties() {\n Properties props = System.getProperties();\n props.put(\"mail.smtp.host\", mailHost);\n props.put(\"mail.smtp.sendpartial\", \"true\");\n if (mailPort != null) {\n props.put(\"mail.smtp.port\", mailPort);\n }\n LOG.debug(\n \"mailHost is \" + mailHost + \", mailPort is \" + mailPort == null ? \"default\" : mailPort);\n if (userName != null && password != null) {\n props.put(\"mail.smtp.auth\", \"true\");\n }\n return props;\n }", "public String getPropertyDACConfig();", "public Map<String, Schema> getProperties() {\n\t\treturn properties;\n\t}", "public void getPropValues() throws IOException {\r\n try {\r\n Properties prop = new Properties();\r\n String path = System.getProperty(\"user.dir\") +\"\\\\src\\\\es\\\\udc\\\\redes\\\\webserver\\\\resources\\\\\";\r\n\t String filename = \"config.properties\";\r\n inputStream = new FileInputStream(path+filename);\r\n if (inputStream != null) {\r\n prop.load(inputStream);\r\n } else {\r\n\t\tthrow new FileNotFoundException(\"property file '\"+path + filename + \"' not found\");\r\n }\r\n\t // get the property value and set in attributes\r\n\t this.PORT = prop.getProperty(\"PORT\");\r\n this.DIRECTORY_INDEX = prop.getProperty(\"DIRECTORY_INDEX\");\r\n this.DIRECTORY = System.getProperty(\"user.dir\")+ prop.getProperty(\"DIRECTORY\");\r\n this.ALLOW = prop.getProperty(\"ALLOW\");\r\n this.HOSTNAME = prop.getProperty(\"HOSTNAME\");\r\n System.out.println();\r\n } catch (Exception e) {\r\n\t\tSystem.out.println(\"Exception: \" + e);\r\n\t} finally {\r\n\t\tinputStream.close();\r\n\t}\r\n }", "public Properties getProperties() {\n return properties;\n }", "public Map<String, Object> getProperties() {\n return properties;\n }", "@Override\n public Properties getProperties() {\n return null;\n }", "ArrayList<PropertyMetadata> getProperties();", "public Map<String, Object> getProperties() {\n return properties;\n }", "public Map<String, Object> getProperties() {\n return properties;\n }", "public Map<String, String> getProperties() {\n\t\treturn this.properties;\n\t}", "@Override\n public void afterPropertiesSet() {\n }", "public Properties getProperties() {\n return properties;\n }", "public void afterPropertiesSet() throws Exception {\n\t\tSessionFactory rawSf = buildSessionFactory();\n\t\tthis.sessionFactory = wrapSessionFactoryIfNecessary(rawSf);\n\t\tafterSessionFactoryCreation();\n\t}", "public org.LexGrid.commonTypes.Properties getProperties() {\n return properties;\n }", "private Properties getSystemPropertiesPost71() {\n Properties props = getSystemProperties();\n return props;\n }", "public String[] getProperties() \n {\n String[] props = {\"discussionSearch.subject\", \"discussionSearch.content\"}; \n return props;\n }" ]
[ "0.759216", "0.75288266", "0.7241452", "0.71401376", "0.6564034", "0.62362546", "0.62016326", "0.60977083", "0.6084662", "0.5969376", "0.59214044", "0.5908151", "0.5905034", "0.5863164", "0.5860836", "0.58397645", "0.583606", "0.5835345", "0.58246964", "0.58246964", "0.58241457", "0.57962006", "0.5788861", "0.5788861", "0.5780817", "0.5777923", "0.57714885", "0.57349735", "0.5733183", "0.57291174", "0.5720758", "0.5719807", "0.5711456", "0.5696433", "0.5689159", "0.5686702", "0.5682326", "0.56740975", "0.56672937", "0.56588125", "0.5647196", "0.5599699", "0.55883116", "0.5580458", "0.5565542", "0.55635715", "0.5559981", "0.5553935", "0.5550881", "0.5545606", "0.5525526", "0.55252576", "0.5513675", "0.551362", "0.5505273", "0.55004543", "0.54974866", "0.54974866", "0.54919076", "0.5484178", "0.5483558", "0.5478433", "0.5427894", "0.5426736", "0.5406197", "0.54037654", "0.5402258", "0.5399789", "0.5396111", "0.53960186", "0.53901553", "0.5388772", "0.53870094", "0.538543", "0.538315", "0.53828156", "0.53814", "0.5378556", "0.5371001", "0.5368755", "0.5356812", "0.5356613", "0.53485173", "0.5347834", "0.5345212", "0.53426987", "0.53348714", "0.53279346", "0.5326749", "0.5324143", "0.5321698", "0.5312773", "0.5312773", "0.53116685", "0.5309736", "0.5305772", "0.53035873", "0.5293364", "0.529086", "0.5290363" ]
0.5610703
41
This method will replace the currently set properties with the given properties. This is not a merge!. Existing properties will be wiped out.
public void setProperties(Properties properties);
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "Properties modifyProperties(Properties properties);", "private void overrideProperties() throws BuildException {\n // remove duplicate properties - last property wins\n // Needed for backward compatibility\n Set set = new HashSet();\n for (int i = properties.size() - 1; i >= 0; --i) {\n Property p = (Property) properties.get(i);\n if (p.getName() != null && !p.getName().equals(\"\")) {\n if (set.contains(p.getName())) {\n properties.remove(i);\n } else {\n set.add(p.getName());\n }\n }\n }\n Enumeration e = properties.elements();\n while (e.hasMoreElements()) {\n Property p = (Property) e.nextElement();\n p.setProject(newProject);\n p.execute();\n }\n getProject().copyInheritedProperties(newProject);\n }", "@Override\r\n\tpublic void setProperties(Properties properties) {\n\t\t\r\n\t}", "@Override\r\n\tpublic void setProperties(Properties properties) \r\n\t{\n\t}", "@Override\n\tpublic void setProperties(Properties p) {\n\t\t\n\t}", "public void resetProperties ()\n\t{\n\t\tproperties.clear();\n\t}", "protected void UpdateProperties(final Map<String, Object> props){\n //loop through the properties keys, check to see if it already exists,\n //if it does, update it, if it doesn't add it.\n props.keySet().forEach((k) -> {\n if(this.properties.get(k) == null){\n this.properties.put(k, props.get(k));\n }else{\n this.properties.replace(k, props.get(k));\n }\n }\n );\n }", "@Override\n public void updateProperties() {\n // unneeded\n }", "void addOrReplaceProperty(Property prop, Collection<Property> properties);", "public void setProperties(Properties properties) {\n this.properties=properties;\n }", "public void setProperties(Properties properties) {\n\t\tthis.properties = properties;\n\t}", "public final void setActualProperties(java.util.Properties properties) {\n this.actualProperties = properties;\n }", "protected void setProperties(P[] properties) {\n\t\tthis.properties = properties;\n\t}", "@Override\n protected void updateProperties() {\n }", "@Override\n\tpublic void setProperties(Properties properties) {\n\t\tsuper.setProperties(properties);\n\t}", "public void setProperties(Properties properties)\n {\n this.properties = properties;\n }", "public void setProperties(Map properties);", "public void setProperties(Map<String, Object> properties) {\n\t\tthis.properties = properties;\n\t}", "public void setProperty(Properties properties) {\r\n this.properties = properties;\r\n }", "public void setProperties(Map<String, List<String>> properties) {\n\t\tthis.properties = properties;\n\t}", "public\n void setProperties(YutilProperties argprops)\n {\n if (argprops == null)\n return;\n\n // Copy all key/val pairs\n for (Enumeration ep = argprops.propertyNames(); ep.hasMoreElements(); )\n {\n String key = (String)ep.nextElement();\n String val = key + \"=\" + argprops.getProperty(key);\n setProperties(val, false);\n }\n }", "public void setProperties(Map<String, String> properties) {\n\t\tthis.properties = properties;\n\t}", "public void setProperties(Map<String, Object> properties) {\n this.properties = properties;\n }", "@Override\r\n\tpublic void setProperties(Properties arg0) {\n\r\n\t}", "protected void afterPropertiesSetInternal() {\n\t\t// override this method\n\t}", "public void setProperties(Map<String, Object> properties) {\n mProperties = properties;\n }", "public void setProperties(Properties setList);", "public abstract void setProperties(Properties uprop);", "public\tvoid\tsetRemovedProperties(List<JsClass.Property> removedProperties) {\n\t\tthis.removedProperties = removedProperties;\n\t}", "public void setProperties(Map<String, String> properties) {\n this.properties = properties;\n }", "@Override\n public void modifyProperties(Map<String, String> properties) throws DdlException {\n List<String> cantChangeProperties = Arrays.asList(S3_ENDPOINT, S3_REGION, S3_ROOT_PATH, S3_BUCKET);\n Optional<String> any = cantChangeProperties.stream().filter(properties::containsKey).findAny();\n if (any.isPresent()) {\n throw new DdlException(\"current not support modify property : \" + any.get());\n }\n // modify properties\n replaceIfEffectiveValue(this.properties, S3_ACCESS_KEY, properties.get(S3_ACCESS_KEY));\n replaceIfEffectiveValue(this.properties, S3_SECRET_KEY, properties.get(S3_SECRET_KEY));\n replaceIfEffectiveValue(this.properties, S3_MAX_CONNECTIONS, properties.get(S3_MAX_CONNECTIONS));\n replaceIfEffectiveValue(this.properties, S3_REQUEST_TIMEOUT_MS, properties.get(S3_REQUEST_TIMEOUT_MS));\n replaceIfEffectiveValue(this.properties, S3_CONNECTION_TIMEOUT_MS, properties.get(S3_CONNECTION_TIMEOUT_MS));\n notifyUpdate();\n }", "public void update(\n final Properties properties\n ) {\n throw new UnsupportedOperationException(\"Not yet implemented\");\n }", "public static void copyProperties(List<Property> properties, StringMap result) {\n/* 192 */ if (properties != null)\n/* 193 */ for (int i = 0; i < properties.size(); i++) {\n/* 194 */ Property prop = properties.get(i);\n/* 195 */ result.putValue(prop.getName(), prop.getValue());\n/* */ } \n/* */ }", "public void setProperties(java.util.Map<String,String> properties) {\n this.properties = properties;\n }", "public void setProperties(org.LexGrid.commonTypes.Properties properties) {\n this.properties = properties;\n }", "public void reinitFromProperties(Properties indexingProperties)\n {\n this.fieldMap.clear();\n this.transMapMap.clear();\n this.customMethodMap.clear();\n this.customMixinMap.clear();\n\n this.fillMapFromProperties(indexingProperties);\n }", "public static void setProperties(final HashMap<String, String> properties) {\n for (String propertyName : properties.keySet()) {\n Conf.properties.setProperty(propertyName, properties.get(propertyName));\n }\n try {\n commit();\n } catch (IOException e) {\n Log.error(e);\n }\n }", "protected void convertProperties(Properties props) {\n\t\tEnumeration propertyNames = props.propertyNames();\n\t\twhile (propertyNames.hasMoreElements()) {\n\t\t\tString propertyName = (String) propertyNames.nextElement();\n\t\t\tString propertyValue = props.getProperty(propertyName);\n\t\t\tString convertedValue = convertPropertyValue(propertyValue);\n\t\t\tif (!ObjectUtils.nullSafeEquals(propertyValue, convertedValue)) {\n\t\t\t\tprops.setProperty(propertyName, convertedValue);\n\t\t\t}\n\t\t}\n\t}", "public void setProperties(String properties) throws ParseException {\n\t\tthis.m_corniInterpreter.clear();\n\t\tthis.m_corniInterpreter.parseProperties(properties);\n\t\t\n\t\tthis.m_attributes = m_corniInterpreter.getAttributes();\n\t\tthis.m_tagNames = m_corniInterpreter.getTagNames();\n\t}", "PropertiesTask setProperties( Properties properties );", "public void reset() {\r\n properties.clear();\r\n }", "public static void weaveDevProperties(Properties properties) {\n if (fgIsDev) {\n Properties devProperties = getDevProperties();\n if (devProperties != null) {\n Set<?> entries = devProperties.entrySet();\n Iterator<?> iterator = entries.iterator();\n while (iterator.hasNext()) {\n Entry<?, ?> entry = (Entry<?, ?>) iterator.next();\n properties.setProperty((String) entry.getKey(), (String) entry.getValue());\n }\n }\n }\n }", "PropertiesTask removeAllProperties();", "public synchronized void updateProperties(User user, Properties properties) {\r\n for (Property property : properties.getProperty()) {\r\n user.getProperties().getProperty().add(property);\r\n }\r\n this.putUser(user);\r\n }", "@JsonProperty(\"properties\")\n public void setProperties(PropertyBag properties) {\n this.properties = properties;\n }", "private void mergeOrReplaceCurrentProperty(Motif original, Motif updated, String property, String newValue) throws ExecutionError {\n if (property.equals(\"Short name\") || property.equals(\"Long name\") || property.equals(\"Classification\") || property.equals(\"Part\") || property.equals(\"Quality\") || property.equals(\"Consensus\")) { // these properties can not be merged\n replaceProperty(updated, property, newValue); // these properties can not be merged\n } else if (property.equals(\"Factors\")) {\n String mergedList=mergeStringsLists(original.getBindingFactors(),newValue);\n updated.setBindingFactors(mergedList);\n } else if (property.equals(\"Alternatives\")) {\n String[] names=newValue.split(\"\\\\s*,\\\\s*\");\n String[] originalNames=new String[original.getKnownDuplicatesNames().size()];\n originalNames=original.getKnownDuplicatesNames().toArray(originalNames);\n String[] merged=mergeStringLists(names, originalNames);\n updated.setKnownDuplicatesNames(merged);\n } else if (property.equals(\"Interactions\")) {\n String[] names=newValue.split(\"\\\\s*,\\\\s*\");\n String[] originalNames=new String[original.getInteractionPartnerNames().size()];\n originalNames=original.getInteractionPartnerNames().toArray(originalNames);\n String[] merged=mergeStringLists(names, originalNames);\n updated.setInteractionPartnerNames(merged);\n } else if (property.equals(\"Organisms\")) {\n String mergedList=mergeStringsLists(original.getOrganisms(),newValue);\n updated.setOrganisms(mergedList);\n } else if (property.equals(\"Expression\")) {\n String[] tissues=newValue.split(\"\\\\s*,\\\\s*\");\n String[] originalNames=new String[original.getTissueExpressionAsStringArray().size()];\n originalNames=original.getTissueExpressionAsStringArray().toArray(originalNames);\n String[] merged=mergeStringLists(tissues, originalNames);\n updated.setTissueExpression(merged);\n } else if (property.equals(\"Part\")) {\n if (!Motif.isValidPart(newValue)) throw new ExecutionError(\"'\"+newValue+\"' is not a valid value for the 'part' property\");\n updated.setPart(newValue);\n } else {\n if (!Motif.isValidUserDefinedPropertyKey(property)) throw new ExecutionError(\"'\"+property+\"' is not a valid name for a user-defined property\");\n if (newValue.contains(\";\")) throw new ExecutionError(\"Value can not contain the ';' character\");\n Class type=Motif.getClassForUserDefinedProperty(property, gui.getEngine());\n if (type!=null && (type.equals(ArrayList.class) || type.equals(String.class))) {\n String merged=mergeStringsLists( (String)original.getUserDefinedPropertyValueAsType(property,String.class), newValue); \n String[] mergedSplit=merged.split(\"\\\\s*,\\\\s*\");\n ArrayList<String> value=new ArrayList<String>(mergedSplit.length);\n value.addAll(Arrays.asList(merged));\n updated.setUserDefinedPropertyValue(property, value);\n } else replaceProperty(updated, property, newValue); // the property can not be merged (or can it?)\n }\n }", "public void updateProperties() {\n\t\t\tEnumeration iter = properties.keys();\r\n\t\t\twhile (iter.hasMoreElements()) {\r\n\t\t\t\tString key = (String) iter.nextElement();\r\n\t\t\t\tif (key.startsWith(ConfigParameters.RECENT_FILE_PREFIX)) {\r\n\t\t\t\t\tproperties.remove(key);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t// Save the list of recent file information\r\n\t\t\tfor (int i = 0; i < files.length; i++) {\r\n\t\t\t\tproperties.put(ConfigParameters.RECENT_FILE_PREFIX + (i + 1),\r\n\t\t\t\t\t\tfiles[i]);\r\n\t\t\t}\r\n\t\t\t// Save the number of recent files\r\n\t\t\tproperties.remove(ConfigParameters.RECENT_FILE_NUMBER);\r\n\t\t\tproperties.put(ConfigParameters.RECENT_FILE_NUMBER, files.length\r\n\t\t\t\t\t+ \"\");\r\n\t\t\t// Save to external file\r\n\t\t\tsim.core.AppEngine.getInstance().system.systemParameters\r\n\t\t\t\t\t.saveProperties(properties);\r\n\t\t\tdirty = false;\r\n\t\t}", "@NotNull @Contract(pure = true)\n\tT withProperties(Map<String, Object> newProperties);", "public void setProperties(java.util.Map<String, Double> properties) {\n this.properties = new HashMap<String, Double>(properties);\n }", "@Override\r\n\tpublic void setProperty(Properties prop) {\n\t}", "public void afterPropertiesSet() {\r\n\t}", "@ReactMethod\n public void peopleSet(ReadableMap properties) {\n mixpanel.getPeople().set(this.readableMapToJson(properties));\n }", "public final void mergeProperties(final Properties prop)\n {\n this.fProp.putAll(prop);\n }", "public static void forceReload() {\n properties = null;\n getProperties();\n }", "public void setProperties(ProviderPropertiesUnbundled properties) {\n synchronized (mBinder) {\n mProperties = properties.getProviderProperties();\n }\n\n ILocationProviderManager manager = mManager;\n if (manager != null) {\n try {\n manager.onSetProperties(mProperties);\n } catch (RemoteException | RuntimeException e) {\n Log.w(mTag, e);\n }\n }\n }", "void invalidateProperties() {\n super.invalidateProperties();\n token_ = null;\n }", "public void afterPropertiesSet() {\n\t}", "public void afterPropertiesSet() {\n\t}", "public void afterPropertiesSet() {\n\t}", "public void afterPropertiesSet() {\n\t}", "public void afterPropertiesSet() {\n\t}", "public void afterPropertiesSet() {\n\t}", "public void afterPropertiesSet() {\n\t}", "public void afterPropertiesSet() {\n\t}", "private void restoreProperties() {\n restoreModeAndItemValue();\n restoreStringValue(Variable.DEST_PATH);\n restoreBooleanValue(Variable.MAXTRACKS_ENABLED);\n restoreIntValue(Variable.MAXTRACKS);\n restoreBooleanValue(Variable.MAXSIZE_ENABLED);\n restoreIntValue(Variable.MAXSIZE);\n restoreBooleanValue(Variable.MAXLENGTH_ENABLED);\n restoreIntValue(Variable.MAXLENGTH);\n restoreBooleanValue(Variable.ONE_MEDIA_ENABLED);\n restoreStringValue(Variable.ONE_MEDIA);\n restoreBooleanValue(Variable.CONVERT_MEDIA);\n restoreStringValue(Variable.CONVERT_COMMAND);\n if (StringUtils.isBlank((String) data.get(Variable.CONVERT_COMMAND))) {\n data.put(Variable.CONVERT_COMMAND, \"pacpl\"); // use default value if none set\n // yet\n }\n restoreBooleanValue(Variable.NORMALIZE_FILENAME);\n restoreIntValue(Variable.RATING_LEVEL);\n }", "public synchronized void update() {\n // set lastCheck first to reduce risk of recursive calls\n this.lastCheck = System.currentTimeMillis();\n if (getChecksum() != this.lastChecksum) {\n // First collect properties into a temporary collection,\n // in a second step copy over new properties,\n // and in the final step delete properties which have gone.\n ResourceProperties temp = new ResourceProperties();\n temp.setIgnoreCase(this.ignoreCase);\n\n // first of all, properties are load from default properties\n if (this.defaultProperties != null) {\n this.defaultProperties.update();\n temp.putAll(this.defaultProperties);\n }\n\n // next we try to load properties from the application's\n // repositories, if we belong to any application\n if (this.resourceName != null) {\n Iterator iterator = this.app.getRepositories().iterator();\n while (iterator.hasNext()) {\n try {\n RepositoryInterface repository = (RepositoryInterface) iterator.next();\n ResourceInterface res = repository.getResource(this.resourceName);\n if (res != null && res.exists()) {\n\t\t\t\t\t\t\tInputStreamReader reader = new InputStreamReader(\n\t\t\t\t\t\t\t\t\tres.getInputStream());\n\t\t\t\t\t\t\ttemp.load(reader);\n\t\t\t\t\t\t\treader.close();\n }\n } catch (IOException iox) {\n iox.printStackTrace();\n }\n }\n }\n\n // if these are subproperties, reload them from the parent properties\n if (this.parentProperties != null && this.prefix != null) {\n this.parentProperties.update();\n Iterator it = this.parentProperties.entrySet().iterator();\n int prefixLength = this.prefix.length();\n while (it.hasNext()) {\n Map.Entry entry = (Map.Entry) it.next();\n String key = entry.getKey().toString();\n if (key.regionMatches(this.ignoreCase, 0, this.prefix, 0, prefixLength)) {\n temp.put(key.substring(prefixLength), entry.getValue());\n }\n }\n\n }\n\n // at last we try to load properties from the resource list\n if (this.resources != null) {\n Iterator iterator = this.resources.iterator();\n while (iterator.hasNext()) {\n try {\n ResourceInterface res = (ResourceInterface) iterator.next();\n if (res.exists()) {\n\t\t\t\t\t\t\tInputStreamReader reader = new InputStreamReader(\n\t\t\t\t\t\t\t\t\tres.getInputStream());\n\t\t\t\t\t\t\ttemp.load(reader);\n\t\t\t\t\t\t\treader.close();\n }\n } catch (IOException iox) {\n iox.printStackTrace();\n }\n }\n }\n\n // Copy over new properties ...\n putAll(temp);\n // ... and remove properties which have been removed.\n Iterator it = super.keySet().iterator();\n while (it.hasNext()) {\n if (!temp.containsKey(it.next())) {\n it.remove();\n }\n }\n // copy new up-to-date keyMap to ourself\n this.keyMap = temp.keyMap;\n\n this.lastChecksum = getChecksum();\n this.lastCheck = this.lastModified = System.currentTimeMillis();\n }\n }", "@Override\n public void updateProperties(final String id, final Map<Name, Property> properties ) {\n final File sidecarFile = sidecarFile(id);\n try {\n final EditableDocument document;\n if (!sidecarFile.exists()) {\n if (properties.isEmpty()) {\n return;\n }\n sidecarFile.createNewFile();\n document = Schematic.newDocument();\n } else {\n try (final FileInputStream sidecarStream = new FileInputStream(sidecarFile)) {\n final Document existing = Json.read(sidecarStream, false);\n document = Schematic.newDocument(existing);\n }\n }\n properties.forEach((key, property) -> {\n if (property == null) {\n translator.removeProperty(document, key, null, null);\n } else {\n translator.setProperty(document, property, null, null);\n }\n });\n try (final FileOutputStream outputStream = new FileOutputStream(sidecarFile)) {\n Json.write(document, outputStream);\n }\n } catch (final IOException e) {\n throw new RepositoryRuntimeException(id, e);\n }\n }", "@Override\n public void afterPropertiesSet() {\n }", "public static native void setDefaultProperties(CubeGrid cubeGridProperties) /*-{\r\n \tvar properties = $wnd.isc.addProperties({},[email protected]::getConfig()());\r\n \tdelete properties.ID;\r\n $wnd.isc.CubeGrid.addProperties(properties);\r\n }-*/;", "private void trimProperties(Properties properties) {\n // Have to do this iteration in a Java 5 compatible manner. no stringPropertyNames().\n for (Map.Entry<Object, Object> entry : properties.entrySet()) {\n String propName = (String) entry.getKey();\n properties.setProperty(propName, properties.getProperty(propName).trim());\n }\n }", "public boolean setProperties(Properties props) {\n String str;\n\n super.setProperties(props);\n str=props.getProperty(\"shun\");\n if(str != null) {\n shun=Boolean.valueOf(str).booleanValue();\n props.remove(\"shun\");\n }\n\n str=props.getProperty(\"merge_leader\");\n if(str != null) {\n merge_leader=Boolean.valueOf(str).booleanValue();\n props.remove(\"merge_leader\");\n }\n\n str=props.getProperty(\"print_local_addr\");\n if(str != null) {\n print_local_addr=Boolean.valueOf(str).booleanValue();\n props.remove(\"print_local_addr\");\n }\n\n str=props.getProperty(\"join_timeout\"); // time to wait for JOIN\n if(str != null) {\n join_timeout=Long.parseLong(str);\n props.remove(\"join_timeout\");\n }\n\n str=props.getProperty(\"join_retry_timeout\"); // time to wait between JOINs\n if(str != null) {\n join_retry_timeout=Long.parseLong(str);\n props.remove(\"join_retry_timeout\");\n }\n\n str=props.getProperty(\"leave_timeout\"); // time to wait until coord responds to LEAVE req.\n if(str != null) {\n leave_timeout=Long.parseLong(str);\n props.remove(\"leave_timeout\");\n }\n\n str=props.getProperty(\"merge_timeout\"); // time to wait for MERGE_RSPS from subgroup coordinators\n if(str != null) {\n merge_timeout=Long.parseLong(str);\n props.remove(\"merge_timeout\");\n }\n\n str=props.getProperty(\"digest_timeout\"); // time to wait for GET_DIGEST_OK from PBCAST\n if(str != null) {\n digest_timeout=Long.parseLong(str);\n props.remove(\"digest_timeout\");\n }\n\n str=props.getProperty(\"view_ack_collection_timeout\");\n if(str != null) {\n view_ack_collection_timeout=Long.parseLong(str);\n props.remove(\"view_ack_collection_timeout\");\n }\n\n str=props.getProperty(\"resume_task_timeout\");\n if(str != null) {\n resume_task_timeout=Long.parseLong(str);\n props.remove(\"resume_task_timeout\");\n }\n\n str=props.getProperty(\"disable_initial_coord\");\n if(str != null) {\n disable_initial_coord=Boolean.valueOf(str).booleanValue();\n props.remove(\"disable_initial_coord\");\n }\n\n str=props.getProperty(\"handle_concurrent_startup\");\n if(str != null) {\n handle_concurrent_startup=Boolean.valueOf(str).booleanValue();\n props.remove(\"handle_concurrent_startup\");\n }\n\n str=props.getProperty(\"num_prev_mbrs\");\n if(str != null) {\n num_prev_mbrs=Integer.parseInt(str);\n props.remove(\"num_prev_mbrs\");\n }\n\n if(props.size() > 0) {\n log.error(\"GMS.setProperties(): the following properties are not recognized: \" + props);\n\n return false;\n }\n return true;\n }", "protected void setMultiplePropertiesChanging(boolean multiplePropertiesChanging) {\n this.multiplePropertiesChanging = multiplePropertiesChanging;\n }", "protected void copyProperties(AbstractContext context) {\n\t\tcontext.description = this.description;\n\t\tcontext.batchSize = this.batchSize;\n\t\tcontext.injectBeans = this.injectBeans;\n\t\tcontext.commitImmediately = this.isCommitImmediately();\n\t\tcontext.script = this.script;\n\t}", "private static void populate(GlobalProperties properties, ResultSet rs) throws SQLException {\n while (rs.next()) {\n String name = rs.getString(\"name\");\n String value = rs.getString(\"value\");\n if (null != value) {\n properties.setProperty(name, value);\n } else {\n // null value in the database means remove this value if somehow it is in global file and needs removal at runtime\n // this is not expected to occur but may be used for very isolated cases\n properties.remove(name);\n LOGGER.warn(\"Removing global property since value is null: '{}'\", name);\n }\n }\n }", "public void setParameters(Properties props) {\n\n\t}", "private void processProperties(Map<String, String> properties,\n Configuration auConfig, CIProperties headers) {\n log.debug2(\"properties = {}\", properties);\n log.debug2(\"auConfig = {}\", auConfig);\n log.debug2(\"headers = {}\", headers);\n\n if (properties != null && properties.size() > 0) {\n for (String key : properties.keySet()) {\n\tlog.trace(\"key = {}\", key);\n\n\tString value = properties.get(key);\n\tlog.trace(\"value = {}\", value);\n\n\tif (auConfig != null && auConfigKeys.contains(key)) {\n\t auConfig.put(key, value);\n\t log.trace(\"property '{}={}' stored in auConfig\", key, value);\n\t} else {\n\t headers.put(key, value);\n\t log.trace(\"property '{}={}' stored in headers\", key, value);\n\t}\n }\n }\n }", "public void setProperties(String prefix, Properties setList);", "protected void toProperties(Properties properties, boolean dflt) {\r\n T val = dflt ? this.dflt : value;\r\n if (null != val) {\r\n properties.put(key, val);\r\n }\r\n }", "public void setProperties(String primitive, AnimationProperties properties){\r\n\t\tpropMap.put(primitive, properties);\r\n\t}", "private void addAlmostAll(Hashtable props) {\n Enumeration e = props.keys();\n while (e.hasMoreElements()) {\n String key = e.nextElement().toString();\n if (\"basedir\".equals(key) || \"ant.file\".equals(key)) {\n // basedir and ant.file get special treatment in execute()\n continue;\n }\n \n String value = props.get(key).toString();\n // don't re-set user properties, avoid the warning message\n if (newProject.getProperty(key) == null) {\n // no user property\n newProject.setNewProperty(key, value);\n }\n }\n }", "public void assignNestedProperties(Properties... newValueProperties) {\n List<Field> propertyFields = getAnyPropertyFields();\n for (Field propField : propertyFields) {\n Class<?> propType = propField.getType();\n if (Properties.class.isAssignableFrom(propType)) {\n boolean isNewAssignment = false;\n for (Properties newValue : newValueProperties) {\n if (propType.isAssignableFrom(newValue.getClass())) {\n try {\n propField.set(this, newValue);\n } catch (IllegalArgumentException | IllegalAccessException e) {\n throw new TalendRuntimeException(CommonErrorCodes.UNEXPECTED_EXCEPTION, e);\n }\n isNewAssignment = true;\n } // else not a compatible type so keep looking\n }\n if (!isNewAssignment) {// recurse\n Properties prop;\n try {\n prop = (Properties) propField.get(this);\n if (prop != null) {\n prop.assignNestedProperties(newValueProperties);\n } // else prop value is null so we can't recurse. this should never happend\n } catch (IllegalArgumentException | IllegalAccessException e) {\n throw new TalendRuntimeException(CommonErrorCodes.UNEXPECTED_EXCEPTION, e);\n } // cast is ok we check it was assignable before.\n }\n } // else not a nestedProperties so keep looking.\n }\n }", "private void resetProp(){\n proposition.clear();\n for (int i = 0; i<tailleCombinaison; i++) {\n proposition.add(\"-1\");\n }\n }", "void updateProperties(@NotNull List<NlComponent> components,\n @NotNull Map<String, NlProperty> properties,\n @NotNull PropMgr propertiesManager);", "private void mergeOrKeepCurrentProperty(Motif original, Motif updated, String property, String newValue) throws ExecutionError {\n if (property.equals(\"Short name\")) {\n String originalName=original.getShortName();\n if (originalName==null || originalName.isEmpty()) updated.setShortName(newValue); else updated.setShortName(originalName);\n } else if (property.equals(\"Long name\")) {\n String originalName=original.getLongName();\n if (originalName==null || originalName.isEmpty()) updated.setLongName(newValue); else updated.setLongName(originalName);\n } else if (property.equals(\"Consensus\")) {\n String originalConsensus=original.getConsensusMotif();\n if (originalConsensus==null || originalConsensus.isEmpty()) updated.setConsensusMotifAndUpdatePWM(newValue); else updated.setConsensusMotifAndUpdatePWM(originalConsensus);\n } else if (property.equals(\"Factors\")) {\n String mergedList=mergeStringsLists(original.getBindingFactors(),newValue);\n updated.setBindingFactors(mergedList);\n } else if (property.equals(\"Classification\")) {\n if (newValue.matches(\"[^0-9\\\\.]\")) throw new ExecutionError(\"Incorrect class label: \"+newValue);\n int level=MotifClassification.getClassLevel(newValue);\n while (level>4) {\n newValue=MotifClassification.getParentLevel(newValue);\n level=MotifClassification.getClassLevel(newValue);\n }\n if (!MotifClassification.isKnownClassString(newValue)) throw new ExecutionError(\"Unknown motif class:\"+newValue);\n if (original.getClassification()==null) updated.setClassification(newValue);\n } else if (property.equals(\"Quality\")) {\n try {\n int value=Integer.parseInt(newValue);\n if (value<1 || value>6) throw new ExecutionError(\"Quality should be a number between 1 and 6\");\n if (original.getQuality()==6) updated.setQuality(value);\n } catch (NumberFormatException nfe) {\n throw new ExecutionError(\"Unable to parse expected numeric value for quality: \"+newValue);\n }\n } else if (property.equals(\"Alternatives\")) {\n String[] names=newValue.split(\"\\\\s*,\\\\s*\");\n String[] originalNames=new String[original.getKnownDuplicatesNames().size()];\n originalNames=original.getKnownDuplicatesNames().toArray(originalNames);\n String[] merged=mergeStringLists(names, originalNames);\n updated.setKnownDuplicatesNames(merged);\n } else if (property.equals(\"Interactions\")) {\n String[] names=newValue.split(\"\\\\s*,\\\\s*\");\n String[] originalNames=new String[original.getInteractionPartnerNames().size()];\n originalNames=original.getInteractionPartnerNames().toArray(originalNames);\n String[] merged=mergeStringLists(names, originalNames);\n updated.setInteractionPartnerNames(merged);\n } else if (property.equals(\"Organisms\")) {\n String mergedList=mergeStringsLists(original.getOrganisms(),newValue);\n updated.setOrganisms(mergedList);\n } else if (property.equals(\"Expression\")) {\n String[] tissues=newValue.split(\"\\\\s*,\\\\s*\");\n String[] originalNames=new String[original.getTissueExpressionAsStringArray().size()];\n originalNames=original.getTissueExpressionAsStringArray().toArray(originalNames);\n String[] merged=mergeStringLists(tissues, originalNames);\n updated.setTissueExpression(merged);\n } else if (property.equals(\"Part\")) {\n if (!Motif.isValidPart(newValue)) throw new ExecutionError(\"'\"+newValue+\"' is not a valid value for the 'part' property\");\n updated.setPart(newValue);\n } else {\n if (!Motif.isValidUserDefinedPropertyKey(property)) throw new ExecutionError(\"'\"+property+\"' is not a valid name for a user-defined property\");\n if (newValue.contains(\";\")) throw new ExecutionError(\"Value can not contain the ';' character\");\n Class type=Motif.getClassForUserDefinedProperty(property, gui.getEngine());\n if (type!=null && (type.equals(ArrayList.class) || type.equals(String.class))) {\n String merged=mergeStringsLists( (String)original.getUserDefinedPropertyValueAsType(property,String.class), newValue); \n String[] mergedSplit=merged.split(\"\\\\s*,\\\\s*\");\n ArrayList<String> value=new ArrayList<String>(mergedSplit.length);\n value.addAll(Arrays.asList(merged));\n updated.setUserDefinedPropertyValue(property, value);\n } else updated.setUserDefinedPropertyValue(property, original.getUserDefinedPropertyValue(property)); // the property can not be merged (or can it?)\n }\n }", "private void resetAllProperties() {\n /*\n // Can't load method instructions: Load method exception: bogus opcode: 0073 in method: com.mediatek.internal.telephony.worldphone.WorldPhoneOp01.resetAllProperties():void, dex: \n */\n throw new UnsupportedOperationException(\"Method not decompiled: com.mediatek.internal.telephony.worldphone.WorldPhoneOp01.resetAllProperties():void\");\n }", "@Override\n public void afterPropertiesSet() {\n validateProperties();\n }", "void mergeFileProperties() {\n JMeterProperty fileName = getProperty(FILE_NAME);\n JMeterProperty paramName = getProperty(FILE_FIELD);\n JMeterProperty mimeType = getProperty(MIMETYPE);\n HTTPFileArg oldStyleFile = new HTTPFileArg(fileName, paramName, mimeType);\n \n HTTPFileArgs fileArgs = getHTTPFileArgs();\n \n HTTPFileArgs allFileArgs = new HTTPFileArgs();\n if (oldStyleFile.isNotEmpty()) { // OK, we have an old-style file definition\n allFileArgs.addHTTPFileArg(oldStyleFile); // save it\n // Now deal with any additional file arguments\n if (fileArgs != null) {\n HTTPFileArg[] infiles = fileArgs.asArray();\n for (HTTPFileArg infile : infiles) {\n allFileArgs.addHTTPFileArg(infile);\n }\n }\n } else {\n if (fileArgs != null) { // for new test plans that don't have FILE/PARAM/MIME properties\n allFileArgs = fileArgs;\n }\n }\n // Updated the property lists\n setHTTPFileArgs(allFileArgs);\n removeProperty(FILE_FIELD);\n removeProperty(FILE_NAME);\n removeProperty(MIMETYPE);\n }", "public void populate(java.util.Map properties) throws LexComponentException;", "public static void properties(final Swagger2Properties theProperties) {\n if (properties == null) {\n properties = theProperties;\n }\n else {\n throw new RuntimeException(\n \"The properties this class has already been configured. Subsequent configuration of this class is not allowed.\"\n );\n }\n }", "@SuppressWarnings(\"unchecked\")\n \tpublic void updated(Dictionary properties) throws ConfigurationException {\n \t\t\n \t}", "public\n void setPropertiesDefaults(YutilProperties argprops)\n {\n if (argprops == null)\n return;\n\n // Copy all key/val pairs\n for (Enumeration ep = argprops.propertyNames(); ep.hasMoreElements(); )\n {\n String key = (String)ep.nextElement();\n String val = key + \"=\" + argprops.getProperty(key);\n setPropertiesDefaults(val, false);\n }\n }", "private void replaceProperty(Motif updated, String property, String newValue) throws ExecutionError {\n if (property.equals(\"Short name\")) {\n updated.setShortName(newValue);\n } else if (property.equals(\"Long name\")) {\n updated.setLongName(newValue);\n } else if (property.equals(\"Consensus\")) {\n updated.setConsensusMotifAndUpdatePWM(newValue);\n } else if (property.equals(\"Factors\")) {\n updated.setBindingFactors(newValue);\n } else if (property.equals(\"Classification\")) {\n if (newValue.matches(\"[^0-9\\\\.]\")) throw new ExecutionError(\"Incorrect class label: \"+newValue);\n int level=MotifClassification.getClassLevel(newValue);\n while (level>4) {\n newValue=MotifClassification.getParentLevel(newValue);\n level=MotifClassification.getClassLevel(newValue);\n }\n if (!MotifClassification.isKnownClassString(newValue)) throw new ExecutionError(\"Unknown motif class:\"+newValue);\n updated.setClassification(newValue);\n } else if (property.equals(\"Quality\")) {\n try {\n int value=Integer.parseInt(newValue);\n if (value<1 || value>6) throw new ExecutionError(\"Quality should be a number between 1 and 6\");\n updated.setQuality(value);\n } catch (NumberFormatException nfe) {\n throw new ExecutionError(\"Unable to parse expected numeric value for quality: \"+newValue);\n }\n } else if (property.equals(\"Alternatives\")) {\n String[] names=newValue.split(\"\\\\s*,\\\\s*\");\n updated.setKnownDuplicatesNames(names);\n } else if (property.equals(\"Interactions\")) {\n String[] names=newValue.split(\"\\\\s*,\\\\s*\");\n updated.setInteractionPartnerNames(names);\n } else if (property.equals(\"Organisms\")) {\n updated.setOrganisms(newValue);\n } else if (property.equals(\"Expression\")) {\n String[] tissues=newValue.split(\"\\\\s*,\\\\s*\");\n updated.setTissueExpression(tissues);\n } else if (property.equals(\"Part\")) {\n if (!Motif.isValidPart(newValue)) throw new ExecutionError(\"'\"+newValue+\"' is not a valid value for the 'part' property\");\n updated.setPart(newValue);\n } else {// userdefined property\n if (!Motif.isValidUserDefinedPropertyKey(property)) throw new ExecutionError(\"'\"+property+\"' is not a valid name for a user-defined property\");\n if (newValue.contains(\";\")) throw new ExecutionError(\"Value can not contain the ';' character\");\n Object value=Motif.getObjectForPropertyValueString(newValue);\n updated.setUserDefinedPropertyValue(property, value);\n }\n }", "public void redoProjectProperties()\n\t{\n\t\tprojectProperties.revalidate();\n projectProperties.repaint();\n\t}", "public void noPropertyies() {\n\t\tproperties.clear();\r\n\t\tfor(int i = 0; i<groups.length; i++){\r\n\t\t\tgroups[i].clear();\r\n\t\t}\r\n\t}", "@Override\r\n\tpublic String[] updateJsonProperties() {\n\t\treturn null;\r\n\t}", "public void setProperties(final ConfigProperties properties) {\n this.properties = properties;\n }", "@Override\r\n\tpublic void setPropFile(Properties prop) {\n\t\t\r\n\t}", "public void mergeProperties(TLPropertyOwner target, List<TLProperty> propertiesToMerge,\n RollupReferenceHandler referenceHandler) {\n ModelElementCloner cloner = getCloner( target );\n Set<NamedEntity> existingSubstitutionGroups = new HashSet<>();\n Set<String> existingPropertyNames = new HashSet<>();\n\n if (target instanceof TLFacet) {\n findExistingProperties( (TLFacet) target, existingSubstitutionGroups, existingPropertyNames );\n }\n\n for (TLProperty sourceProperty : propertiesToMerge) {\n if (!existingPropertyNames.contains( sourceProperty.getName() )) {\n TLPropertyType propertyType = PropertyCodegenUtils.resolvePropertyType( sourceProperty.getType() );\n NamedEntity substitutionGroup = PropertyCodegenUtils.hasGlobalElement( propertyType )\n ? PropertyCodegenUtils.getInheritanceRoot( propertyType )\n : null;\n\n if (!existingSubstitutionGroups.contains( substitutionGroup )) {\n TLProperty clone = cloner.clone( sourceProperty );\n\n target.addElement( clone );\n referenceHandler.captureRollupReferences( clone );\n }\n }\n }\n }", "void editProperty(String requestedProperty, Object newValue) {\n properties.editProperty(requestedProperty, newValue); // <-- The replace() method automatically checks for null\n }", "public void setMessageProperties(Map<String,String> properties)\r\n\t{\r\n\t\tthis.properties = properties;\r\n\t}" ]
[ "0.7515123", "0.69731534", "0.68984514", "0.6871097", "0.6696641", "0.668482", "0.6666573", "0.6664539", "0.6627275", "0.6619443", "0.65928763", "0.65836877", "0.65728277", "0.65727353", "0.6572321", "0.6570074", "0.65288246", "0.6450727", "0.6400587", "0.63990575", "0.63835675", "0.6364338", "0.63533187", "0.629537", "0.62795734", "0.6276783", "0.6231218", "0.62263364", "0.6225898", "0.61995393", "0.6188574", "0.61482066", "0.61472076", "0.6091305", "0.60808146", "0.6078633", "0.6029034", "0.60238945", "0.59986997", "0.59537226", "0.5951858", "0.5931183", "0.59206754", "0.5871859", "0.5867949", "0.58627975", "0.584946", "0.58292586", "0.5826189", "0.5822749", "0.5800754", "0.5793238", "0.57930624", "0.5786085", "0.5782033", "0.57733357", "0.5764339", "0.5764339", "0.5764339", "0.5764339", "0.5764339", "0.5764339", "0.5764339", "0.5764339", "0.5750777", "0.57211417", "0.5719743", "0.5687027", "0.56681854", "0.564196", "0.5621118", "0.5617647", "0.56154114", "0.560812", "0.55946934", "0.55911607", "0.55762035", "0.5543131", "0.55172926", "0.54995143", "0.5493401", "0.54930246", "0.5492768", "0.5482117", "0.5480932", "0.54562587", "0.54501146", "0.5442221", "0.5434084", "0.54124933", "0.54056585", "0.54024726", "0.5393218", "0.5389081", "0.53876084", "0.5382146", "0.53776926", "0.5373059", "0.53722745", "0.53575504" ]
0.6702292
4
This method will set/replace the property given by its key with the given value.
public void addProperty(String key, String value);
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void setProperty(String key, Object value);", "void setProperty(String key, Object value);", "public void setProperty( String key, Object value );", "public void setProperty(Object key, Object value) {\r\n\t\tproperties.put(key, value);\r\n\t}", "public <T> void setValue (String key, T value)\n\t{\n\t\tproperties.get(key).value.setValue(value);\n\t}", "@Override\n\t\tpublic void setProperty(String key, Object value) {\n\n\t\t}", "public void setProperty(String key, String value) {\n\t\tthis.properties.put(key, value);\n\t}", "public void setProperty(String key, String value) {\n\t\tthis.properties.setProperty(key, value);\n\t}", "@VisibleForTesting\n public static void setProperty(String theKey, String theValue) {\n getProperties().setProperty(theKey, theValue);\n }", "public static void setProp(PropertiesAllowedKeys key, String value) {\n\t\tproperties.setProperty(key.toString(), value);\n\t\tpersistSettings();\n\t}", "public Object setProperty(String key, String value) {\n return this.props.setProperty(key, value);\n }", "public void setProp(String key, String value){\t\t\n \t\t//Check which of property to set & set it accordingly\n \t\tif(key.equals(\"UMPD.latestReport\")){\n \t\t\tthis.setLatestReport(value);\n<<<<<<< HEAD\n\t\t} \n=======\n \t\t\treturn;\n \t\t} \n \t\tif (key.equals(\"UMPD.latestVideo\")) {\n \t\t\tthis.setLastestVideo(value);\n \t\t\treturn;\n \t\t}\n>>>>>>> 45a14c6cf04ac0844f8d8b43422597ae953e0c42\n \t}\n //-----------------------------------------------------------------------------\n \t/**\n \t * @return - a list of <code>FieldAndval</code> objects representing the set \n \t * properties\n \t */\n \tpublic ArrayList<FieldAndVal> getSetPropsList(){\n \t\tcreateSetPropsList();\n \t\treturn setPropsList;\n \t}\n //-----------------------------------------------------------------------------\n \t/**\n \t * \n \t */\n \tprivate void createSetPropsList(){\n \t\tif((this.latestReport).length()>0){\n \t\t\tsetPropsList.add(new FieldAndVal(\"UMPD.latestReport\", this.latestReport));\n \t\t}\n \t}\n //-----------------------------------------------------------------------------\n \t/**\n \t * @return lastestVideo - \n \t */\n \tpublic String getLastestVideo() {\n \t\treturn lastestVideo;\n \t}", "final public void setProperty(String key, String value) {\n logger.info(\"Kylin Config was updated with \" + key + \" : \" + value);\n properties.setProperty(BCC.check(key), value);\n }", "@Override\r\n\tpublic Object setProperty(String key, String value) {\r\n\t\t\r\n\t\treturn Settings.setProperty(key, value);\r\n\t\t\r\n\t}", "void set(String key, Object value);", "public static void setUserProperty(String key, String value){\n\n UserProperties.setUserProperty(context, key, value);\n sendUserProperties(Constants.Z_USER_PROPS_UPLOAD_PERIOD_MILLIS);\n }", "public void setPropertyValue(String key, String value) {\n\t\tthis.configMap.put(key, value);\r\n\t}", "public final void setProperty(String key, Object value) {\n/* 57 */ Launch.blackboard.put(key, value);\n/* */ }", "public void putSubstitutionProperty(String key, String value)\n {\n String substKey = getSubstitutionPropertyKey(key);\n setProperty(substKey, value);\n }", "public final void setProperty(final String key, final String value)\n {\n\n if (!StringUtils.isBlank(key))\n {\n\n if ((StringUtils.isBlank(value)) || (StringUtils.isEmpty(value)))\n {\n this.fProp.setProperty(StringUtils.deleteWhitespace(key)\n .toLowerCase().trim(), \" \");\n } else\n {\n this.fProp.setProperty(StringUtils.deleteWhitespace(key)\n .toLowerCase().trim(), value.trim());\n } // end if..else\n } // end outer if.else\n\n }", "final void set(String key, String value) {\n set(key, value, false);\n }", "private static void setPropertyValue(Properties properties, String propertyName, String value) {\n \n properties.setProperty(propertyName, getPropertyValueOrDefault(value));\n }", "public void property(String key, String value) {\n\t\tpropsBinder().addBinding(key).toInstance(value);\n\t}", "PropertiesTask setProperty( String key, String value );", "public void set(String key, Object value) {\r\n\t\tthis.context.setValue(key, value);\r\n\t}", "public static void set(ServerProperty property, String value)\n\t{\n\t\tif (value == null)\n\t\t\tproperties.remove(property.getKey());\n\t\telse\n\t\t\tproperties.setProperty(property.getKey(), value);\n\t}", "private static void setProperty(String key, String value)\r\n/* 84: */ throws IOException\r\n/* 85: */ {\r\n/* 86: 83 */ log.finest(\"OSHandler.setProperty. Key=\" + key + \" Value=\" + value);\r\n/* 87: 84 */ File propsFile = getPropertiesFile();\r\n/* 88: 85 */ FileInputStream fis = new FileInputStream(propsFile);\r\n/* 89: 86 */ Properties props = new Properties();\r\n/* 90: 87 */ props.load(fis);\r\n/* 91: 88 */ props.setProperty(key, value);\r\n/* 92: 89 */ FileOutputStream fos = new FileOutputStream(propsFile);\r\n/* 93: 90 */ props.store(fos, \"\");\r\n/* 94: 91 */ fos.close();\r\n/* 95: */ }", "public void setProperty(String name,Object value);", "public void setProperty(String key, Object value) {\n commandData.put(key, value);\n }", "public void set(String key, Object value) {\n set(key, value, 0);\n }", "void putClientProperty(Object key, Object value);", "private static void setProperty(final GenericConfiguration config, final String key, final String value) {\n\t\t//Resolve system properties, so that they can be used in config values\n\t\tString val = CRUtil.resolveSystemProperties((String) value);\n\n\t\t//Set the property\n\t\tconfig.set(key, val);\n\t}", "void set(K key, V value);", "public void setValue(K key, V value);", "public void set(String propertyId, Object value)\n {\n properties.put(propertyId, value);\n }", "final <T> void set(String key, T value) {\n set(key, value, false);\n }", "public void set(String key, String value)\n {\n settings.setProperty(key, value);\n }", "public static void put(String key, Object value) {\n synchronized (props) {\n props.put(key, value);\n }\n }", "void editProperty(String requestedProperty, Object newValue) {\n properties.editProperty(requestedProperty, newValue); // <-- The replace() method automatically checks for null\n }", "public void setProperty(String property) {\n }", "public Object setProperty( Property propertyId,\n Object value ) {\n if (value == null) {\n // Removing this property ...\n return nodeProperties != null ? nodeProperties.remove(propertyId) : null;\n }\n // Otherwise, we're adding the property\n if (nodeProperties == null) nodeProperties = new TreeMap<Property, Object>();\n return nodeProperties.put(propertyId, value);\n }", "public final void set(final String key, final Object value) {\n try {\n synchronized (jo) {\n if (value == null) {\n jo.remove(key);\n } else {\n jo.put(key, value);\n }\n }\n } catch (JSONException e) {\n }\n }", "public static void setProperty(String property, String value) {\n\t\tproperties.setProperty(property, value);\n\t}", "protected void set(String key, String value)\r\n\t{ this.preferences.put(key, value); }", "public void set(String key, String value) {\n if (key.indexOf('=') != -1 || key.indexOf(';') != -1) {\n Log.e(TAG, \"Key \\\"\" + key + \"\\\" contains invalid character (= or ;)\");\n return;\n }\n if (value.indexOf('=') != -1 || value.indexOf(';') != -1) {\n Log.e(TAG, \"Value \\\"\" + value + \"\\\" contains invalid character (= or ;)\");\n return;\n }\n\n mMap.put(key, value);\n }", "T setSystemProperty(String key, String value);", "public void setProperty (String key, WorldStateValue value)\n\t{\n\t\tproperties.put(key, new WorldStateProperty(key, value));\n\t}", "public JbootVoModel set(String key, Object value) {\n super.put(key, value);\n return this;\n }", "public void put(String property, Object value)\n\t{\n\t\tglobal.put(property, global, value);\n\t}", "public void setSessionProperty(String key, Object value) {\n\t\t_sessionPropertyList.put(key, value);\n\t}", "public void addProperty(String key,\n Object value) {\n if (this.ignoreCase) {\n key = key.toUpperCase();\n }\n\n this.attributes.put(key, value.toString());\n }", "public Value set(Value key, Value value) {\n\t\tif (get(key) != null)\n\t\t\tput(key, value);\n\t\telse if (parent != null)\n\t\t\tparent.put(key, value);\n\t\telse\n\t\t\tput(key, value);\n\t\treturn value;\n\t}", "Form setProperty(String key, String value);", "void set(String key, String value) {\n if (notAnyEmpty(key, value))\n settings.put(key, value);\n }", "void set(String key, String value) {\n if (notAnyEmpty(key, value))\n settings.put(key, value);\n }", "protected abstract void loadProperty(String key, String value);", "DefinedProperty graphChangeProperty( int propertyKey, Object value );", "public void setObject(final String key, final Object value)\r\n {\r\n if (key == null)\r\n {\r\n throw new NullPointerException();\r\n }\r\n if (value == null)\r\n {\r\n helperObjects.remove(key);\r\n }\r\n else\r\n {\r\n helperObjects.put(key, value);\r\n }\r\n }", "public Property(String key, Object value)\r\n {\r\n m_key = key;\r\n m_value = value;\r\n }", "String setEnvironmentProperty(String key, String value);", "protected abstract Property createProperty(String key, Object value);", "@Override\n\tpublic void setProperty(String name, Object value)\n\t{\n\t\tsuper.setProperty(name, value);\n\n\t\tprocessProperty(name, value);\n\t}", "@Override\n\tpublic void setProperty(String name, Object value)\n\t{\n\t\tsuper.setProperty(name, value);\n\n\t\tprocessProperty(name, value);\n\t}", "public void setPropertyValue(String name, String value)\n {\n // Property name must not be empty.\n if (name.equals(EMPTY_STRING))\n {\n return;\n } \n \n // Store the property.\n this.properties.put(name, value);\n }", "public void setProperty(final String property, final String value) {\n\n\t\tthis.engine.setProperty(property, value);\n\t}", "@Override\n\tpublic void setProperty(String propertyName, Object value) {\n\t\t\n\t}", "public void setProperty(String key, String value) \n\t{\n\t\tif (key.equals(\"MINWIN\")) \n\t\t{\n\t\t\tsetMinWin(Float.parseFloat(value));\n\t\t} \n\t\telse if (key.equals(\"MAXLOSS\")) \n\t\t{\n\t\t\tsetMaxLoss(Float.parseFloat(value));\n\t\t}\n\t\telse if (key.equals(\"PERIOD\")) \n\t\t{\n\t\t\t_period = Integer.parseInt(value);\n\t\t}\n\t\telse if (key.equals(\"MAXWIN\")) \n\t\t{\n\t\t\tsetMaxWin(Float.parseFloat(value));\n\t\t}\n\t}", "public void setPropertyValue(Object propertyId, Object value) {\n\t\tproperties.put((String) propertyId, value);\n\t\t// tooltipInformation.get(propertyId).setPropertyValue(value);\n\t}", "@NonNull\n\t\tBuilder addProperty(@NonNull String key, Object value);", "@Override\n\t\t\tpublic void setPropertyValue(Object value) {\n\t\t\t\t\n\t\t\t}", "public void put(String key, Object value) {\r\n\t\tthis.settings.put(key, value);\r\n\t}", "public static void setProperty(String propertyName, String propertyValue){\r\n if (propertyValue == null)\r\n userProps.remove(propertyName);\r\n else\r\n userProps.put(propertyName, propertyValue);\r\n }", "public static void set(String key, String value) {\n stringRedisTemplate.opsForValue().set(key, value);\n }", "public void propertyPut(String k, int v) { m_exprCache.put(k,v); }", "static String replacePropertyWithValue(final String buffer, final String propertyName, final String propertyValue) {\n if (buffer == null) {\n throw new IllegalArgumentException(\"input buffer could not be null\");\n } else if (propertyName == null) {\n throw new IllegalArgumentException(\"input property name could not be null\");\n } else if (propertyValue == null) {\n throw new IllegalArgumentException(\"input property value could not be null\");\n } else {\n String propertyToken = String.format(PROPERTY_TOKEN_FORMAT, propertyName);\n return buffer.replace(propertyToken, propertyValue);\n }\n }", "public void testSetProperty() {\n rootBlog.setProperty(Blog.NAME_KEY, \"New name\");\n assertEquals(\"New name\", rootBlog.getProperty(Blog.NAME_KEY));\n assertEquals(\"New name\", rootBlog.getName());\n\n // and a new property\n rootBlog.setProperty(\"aNewPropertyKey\", \"A new property value\");\n assertEquals(\"A new property value\", rootBlog.getProperty(\"aNewPropertyKey\"));\n }", "public void setString(String key, String value) {\n\t\tif (value != null && !value.equals(getDefault(key)))\n\t\t\tinternal.setProperty(key, value);\n\t\telse\n\t\t\tinternal.remove(key);\n\t}", "public void setSetting(String key, String value) throws SQLException {\n\t\tdb.updateItem(\"settings\", \"value\", value, \"`key`='\"+key+\"'\");\n\t}", "public void setDataValue(String key, Object value) {\n\t\t if (value == null) {\n\t\t\t data.remove(key);\n\t\t }else {\n\t\t\t data.put(key, value);\n\t\t }\n\t }", "final public void setValue(Object value)\n {\n setProperty(VALUE_KEY, (value));\n }", "public void setProperty(String prop, Object value)\r\n {\r\n\tswitch(prop)\r\n\t{\r\n\t case \"name\":\r\n\t\tname = value.toString();\r\n\t\tbreak;\r\n\t case \"description\":\r\n\t\tdesc = value.toString();\r\n\t\tbreak;\r\n\t case \"type\":\r\n\t\tsetType(value.toString());\r\n\t\tbreak;\r\n\t case \"level\":\r\n\t\tlevel = (Integer) value;\r\n\t\tbreak;\r\n\t case \"rarity\":\r\n\t\trare = Rarity.valueOf(value.toString().toUpperCase());\r\n\t\tbreak;\r\n\t case \"vendor_value\":\r\n\t\tvendorValue = (Integer) value;\r\n\t\tbreak;\r\n\t case \"game_types\":\r\n\t\taddGameType(value.toString());\r\n\t\tbreak;\r\n\t case \"flags\":\r\n\t\taddFlag(value.toString());\r\n\t\tbreak;\r\n\t case \"restrictions\":\r\n\t\taddRestriction(value.toString());\r\n\t\tbreak;\r\n\t case \"id\":\r\n\t\tid = (Integer) value;\r\n\t\tbreak;\r\n\t case \"icon\":\r\n\t\ttry {\r\n\t\t icon = new URL(value.toString());\r\n\t\t}\r\n\t\tcatch(MalformedURLException e) {\r\n\t\t e.printStackTrace();\r\n\t\t}\r\n\t\tbreak;\r\n\t}\r\n }", "public void setData(@NotNull String key, @NotNull Object value) {\n data.put(key, value);\n }", "public void setPropertyValue(final JsiiObjectRef objRef, final String property, final JsonNode value) {\n ObjectNode req = makeRequest(\"set\", objRef);\n req.put(\"property\", property);\n req.set(\"value\", value);\n\n this.runtime.requestResponse(req);\n }", "@Override\n public void putValue(String key, Object value) {\n\n }", "public void setProperty(String name, Object value) {\n\t\tbeanMap.put(name, value);\n\t}", "DefinedProperty relChangeProperty( long relId, int propertyKey, Object value );", "Property changeValue(PropertyValue<?, ?> oldValue,\n\t\t\tPropertyValue<?, ?> newValue);", "public void setValue(String key, Object value)\n {\n if (value != null)\n {\n if (otherDetails == null)\n {\n otherDetails = new Hashtable();\n }\n\n otherDetails.put(key, value);\n }\n }", "public abstract void setProperty(String property, Object value)\n throws SOAPException;", "void addOrReplaceProperty(Property prop, Collection<Property> properties);", "public <T> void setProperty(String field, T value) {\n try {\n Field f = this.getClass().getDeclaredField(field); \n f.set(this, value);\n } catch (NoSuchFieldException ex) {\n System.out.println(\"Field no found...\");\n System.out.println(ex.getMessage());\n\n } catch (IllegalAccessException ex) {\n System.out.println(ex.getMessage());\n }\n }", "void put(String kind, String name, String property, String value);", "public void setProperty(String property) {\n \t\t_property = property;\n \t}", "boolean setValue(String type, String key, String value);", "public void put(String key, Object value)\n\t{\n\t\tverifyParseState();\n\t\tvalues.put(key, ValueUtil.createValue(value));\n\t}", "public String put(String key, String value)\n {\n String previousValue = getMap().put(key, value);\n if (value != previousValue && (value == null || !value.equals(previousValue))) {\n cacheable.setPropertyBoolean(PROPERTY_DIRTY, true);\n updater.deferUpdate();\n }\n return previousValue;\n }", "public void setProperty(String keyValuePair) throws PropertiesPlusException\n\t{\n\t\tkeyValuePair = keyValuePair.trim();\n\t\tint i = keyValuePair.indexOf('=');\n\t\tif (i < 1)\n\t\t\tthrow new PropertiesPlusException(String.format(\n\t\t\t\t\t\"%nError parsing %s%nExpecting a String containing one '=' sign%n\",\n\t\t\t\t\tkeyValuePair));\n\t\t\n\t\tString key = keyValuePair.substring(0, i).trim();\n\t\tString value = i == keyValuePair.length()-1 ? \"\" : keyValuePair.substring(i+1).trim();\n\t\tsetProperty(key, value);\n\t}", "public void setProperty(String arg0, Object arg1)\n throws UniquePropertyValueConflictException,\n\n EntityPersistenceException {\n\n }", "public void set(String key, Object value)\n {\n if (value == null) remove(key);\n else if (value instanceof Map)\n {\n DataSection section = createSection(key);\n Map map = (Map) value;\n for (Object k : map.keySet())\n {\n section.set(k.toString(), map.get(k));\n }\n }\n else\n {\n data.put(key, value);\n if (!keys.contains(key)) keys.add(key);\n }\n }", "public abstract void setValue(Context c, Object v) throws PropertyException;" ]
[ "0.79457885", "0.79236054", "0.7911866", "0.78736013", "0.77823246", "0.76876837", "0.75563693", "0.750217", "0.72972304", "0.72303236", "0.72017515", "0.71942335", "0.7192798", "0.7127846", "0.7115684", "0.7051058", "0.70298517", "0.6996772", "0.6950545", "0.69361824", "0.69209445", "0.69207394", "0.6894536", "0.6867773", "0.6840986", "0.6820931", "0.6795412", "0.6768574", "0.6767622", "0.6761828", "0.67606616", "0.67521936", "0.6723663", "0.67191863", "0.6710776", "0.6683791", "0.6623952", "0.658081", "0.6544784", "0.654334", "0.6539746", "0.65181136", "0.65030867", "0.6498681", "0.64959306", "0.6470146", "0.6466464", "0.64656174", "0.6441693", "0.6430939", "0.64140904", "0.64054245", "0.63566834", "0.633983", "0.633983", "0.63356566", "0.63231117", "0.6320962", "0.6290452", "0.6282819", "0.62754023", "0.6274127", "0.6274127", "0.6262062", "0.62587625", "0.6257973", "0.622567", "0.6211026", "0.6196892", "0.6194228", "0.61927587", "0.6188772", "0.61821556", "0.6175406", "0.6150767", "0.61405766", "0.6120251", "0.6118527", "0.61170876", "0.61152714", "0.6108078", "0.6102579", "0.60995495", "0.6094207", "0.60904723", "0.6077571", "0.60743743", "0.6072983", "0.6040615", "0.60269463", "0.6023019", "0.6022497", "0.60192233", "0.6014105", "0.6010629", "0.6008141", "0.60060394", "0.59760755", "0.5974784", "0.59740037" ]
0.6686995
35
This method is called from within the constructor to initialize the form. WARNING: Do NOT modify this code. The content of this method is always regenerated by the Form Editor.
@SuppressWarnings("unchecked") // <editor-fold defaultstate="collapsed" // desc="Generated Code">//GEN-BEGIN:initComponents private void initComponents() { modelo = new DefaultListModel<>(); jDialog1 = new javax.swing.JDialog(); jPanel1 = new javax.swing.JPanel(); botonLogin = new javax.swing.JButton(); BotonPerfil = new javax.swing.JButton(); jLabel1 = new javax.swing.JLabel(); jTextField1 = new javax.swing.JTextField(); jToggleButton1 = new javax.swing.JToggleButton(); jComboBox1 = new javax.swing.JComboBox<>(); jRadioButton1 = new javax.swing.JRadioButton(); jRadioButton2 = new javax.swing.JRadioButton(); jRadioButton3 = new javax.swing.JRadioButton(); jRadioButton4 = new javax.swing.JRadioButton(); jLabel2 = new javax.swing.JLabel(); jLabel3 = new javax.swing.JLabel(); jScrollPane2 = new javax.swing.JScrollPane(); listaProductos = new javax.swing.JList<>(); jScrollPane3 = new javax.swing.JScrollPane(); jList2 = new javax.swing.JList<>(); jLabel4 = new javax.swing.JLabel(); botonComprar = new javax.swing.JButton(); botonAnadirCesta = new javax.swing.JButton(); jButton5 = new javax.swing.JButton(); jScrollPane1 = new javax.swing.JScrollPane(); informacion = new javax.swing.JTextArea(); jLabel5 = new javax.swing.JLabel(); jScrollPane4 = new javax.swing.JScrollPane(); textoValoraciones = new javax.swing.JTextArea(); jLabel6 = new javax.swing.JLabel(); javax.swing.GroupLayout jDialog1Layout = new javax.swing.GroupLayout( jDialog1.getContentPane()); jDialog1.getContentPane().setLayout(jDialog1Layout); jDialog1Layout.setHorizontalGroup(jDialog1Layout.createParallelGroup( javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 400, Short.MAX_VALUE)); jDialog1Layout.setVerticalGroup(jDialog1Layout.createParallelGroup( javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 300, Short.MAX_VALUE)); setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE); botonLogin.setText("Login"); botonLogin.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { botonLoginActionPerformed(evt); } }); BotonPerfil.setText("Perfil"); BotonPerfil.addActionListener(new ActionListener() { @Override public void actionPerformed(ActionEvent e) { if(usuarioLogueado)infoUsuario.setVisible(true); else JOptionPane.showMessageDialog(null, "Debes loguearte para ver la informacion"); } }); jLabel1.setFont(new java.awt.Font("Trajan Pro", 3, 14)); // NOI18N jLabel1.setHorizontalAlignment(javax.swing.SwingConstants.CENTER); jLabel1.setText("EZ GAMES"); jTextField1.setCursor(new java.awt.Cursor(java.awt.Cursor.TEXT_CURSOR)); jTextField1.setName(""); // NOI18N jTextField1.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { jTextField1ActionPerformed(evt); } }); jToggleButton1.setName("Buscar"); jToggleButton1.setIcon(new ImageIcon("resources/guardar.jpg")); jToggleButton1.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { jToggleButton1ActionPerformed(evt); } }); jComboBox1.setModel(new javax.swing.DefaultComboBoxModel<>( new String[] { "PC", "PS4", "XONE", "Switch" })); jComboBox1.setToolTipText(""); jRadioButton1.setText("PC"); jRadioButton1.addActionListener(new ActionListener() { @Override public void actionPerformed(ActionEvent e) { jRadioButton2.setSelected(false); jRadioButton3.setSelected(false); jRadioButton4.setSelected(false); Controlador.getInstance().obtenerProductosPlataforma("PC"); } }); jRadioButton2.setText("PS4"); jRadioButton2.addActionListener(new ActionListener() { @Override public void actionPerformed(ActionEvent e) { jRadioButton1.setSelected(false); jRadioButton3.setSelected(false); jRadioButton4.setSelected(false); Controlador.getInstance().obtenerProductosPlataforma("PS4"); } }); jRadioButton3.setText("XONE"); jRadioButton3.addActionListener(new ActionListener() { @Override public void actionPerformed(ActionEvent e) { jRadioButton1.setSelected(false); jRadioButton2.setSelected(false); jRadioButton4.setSelected(false); Controlador.getInstance().obtenerProductosPlataforma("XBOXONE"); } }); jRadioButton4.setText("Switch"); jRadioButton4.addActionListener(new ActionListener() { @Override public void actionPerformed(ActionEvent e) { jRadioButton1.setSelected(false); jRadioButton2.setSelected(false); jRadioButton3.setSelected(false); Controlador.getInstance().obtenerProductosPlataforma("Switch"); } }); jLabel2.setText("Seleccione plataforma:"); jLabel3.setFont(new java.awt.Font("Tahoma", 1, 11)); // NOI18N jLabel3.setText("Resultados de la búsqueda"); jLabel3.setToolTipText(""); listaProductos.setModel(new javax.swing.AbstractListModel<String>() { String[] strings = {}; public int getSize() { return strings.length; } public String getElementAt(int i) { return strings[i]; } }); jScrollPane2.setViewportView(listaProductos); jList2.setModel(new javax.swing.AbstractListModel<String>() { String[] strings = {}; public int getSize() { return strings.length; } public String getElementAt(int i) { return strings[i]; } }); jScrollPane3.setViewportView(jList2); jLabel4.setFont(new java.awt.Font("Tahoma", 1, 11)); // NOI18N jLabel4.setText("Cesta"); botonComprar.setFont(new java.awt.Font("Tahoma", 0, 18)); // NOI18N botonComprar.setText("¡Confirmar compra!"); botonComprar.setToolTipText(""); botonComprar.addActionListener(new ActionListener() { @Override public void actionPerformed(ActionEvent e) { if(!usuarioLogueado) JOptionPane.showMessageDialog(null,"Debes iniciar sesion para comprar"); else { JOptionPane.showMessageDialog(null,"Compra realizada con exito"); } } }); botonAnadirCesta.setText("Añadir a cesta >>"); botonAnadirCesta.setName("anadirCesta"); // NOI18N botonAnadirCesta.addActionListener(new ActionListener() { @Override public void actionPerformed(ActionEvent e) { anadirCompra(listaProductos.getSelectedValue()); } }); jButton5.setText("<< Quitar de cesta"); jButton5.addActionListener(new ActionListener() { @Override public void actionPerformed(ActionEvent e) { eliminarCompra(jList2.getSelectedValue()); } }); informacion.setColumns(20); informacion.setRows(5); jScrollPane1.setViewportView(informacion); jLabel5.setText("Información"); textoValoraciones.setColumns(20); textoValoraciones.setRows(5); jScrollPane4.setViewportView(textoValoraciones); jLabel6.setText("Valoraciones"); javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout( jPanel1); jPanel1.setLayout(jPanel1Layout); jPanel1Layout .setHorizontalGroup(jPanel1Layout .createParallelGroup( javax.swing.GroupLayout.Alignment.LEADING) .addGroup( jPanel1Layout .createSequentialGroup() .addContainerGap() .addGroup( jPanel1Layout .createParallelGroup( javax.swing.GroupLayout.Alignment.LEADING) .addGroup( jPanel1Layout .createSequentialGroup() .addComponent( jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 216, javax.swing.GroupLayout.PREFERRED_SIZE) .addGroup( jPanel1Layout .createParallelGroup( javax.swing.GroupLayout.Alignment.LEADING) .addGroup( jPanel1Layout .createSequentialGroup() .addPreferredGap( javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup( jPanel1Layout .createParallelGroup( javax.swing.GroupLayout.Alignment.LEADING) .addGroup( javax.swing.GroupLayout.Alignment.TRAILING, jPanel1Layout .createSequentialGroup() .addGap(0, 0, Short.MAX_VALUE) .addGroup( jPanel1Layout .createParallelGroup( javax.swing.GroupLayout.Alignment.LEADING, false) .addComponent( botonAnadirCesta, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .addComponent( jButton5, javax.swing.GroupLayout.DEFAULT_SIZE, 157, Short.MAX_VALUE)) .addGap(61, 61, 61)) .addGroup( jPanel1Layout .createSequentialGroup() .addGroup( jPanel1Layout .createParallelGroup( javax.swing.GroupLayout.Alignment.LEADING) .addComponent( jScrollPane4, javax.swing.GroupLayout.PREFERRED_SIZE, 273, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent( jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 273, javax.swing.GroupLayout.PREFERRED_SIZE)) .addPreferredGap( javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)))) .addGroup( jPanel1Layout .createSequentialGroup() .addGroup( jPanel1Layout .createParallelGroup( javax.swing.GroupLayout.Alignment.LEADING) .addGroup( jPanel1Layout .createSequentialGroup() .addGap(112, 112, 112) .addComponent( jLabel5)) .addGroup( jPanel1Layout .createSequentialGroup() .addGap(121, 121, 121) .addComponent( jLabel6))) .addPreferredGap( javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))) .addGroup( jPanel1Layout .createParallelGroup( javax.swing.GroupLayout.Alignment.LEADING, false) .addComponent( jScrollPane3) .addComponent( botonComprar, javax.swing.GroupLayout.DEFAULT_SIZE, 221, Short.MAX_VALUE))) .addGroup( javax.swing.GroupLayout.Alignment.TRAILING, jPanel1Layout .createSequentialGroup() .addComponent( jLabel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .addGap(18, 18, 18) .addComponent( BotonPerfil) .addPreferredGap( javax.swing.LayoutStyle.ComponentPlacement.UNRELATED) .addGroup( jPanel1Layout .createParallelGroup( javax.swing.GroupLayout.Alignment.LEADING) .addComponent( jToggleButton1, javax.swing.GroupLayout.PREFERRED_SIZE, 38, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent( botonLogin, javax.swing.GroupLayout.PREFERRED_SIZE, 85, javax.swing.GroupLayout.PREFERRED_SIZE)) .addContainerGap()))) .addGroup( jPanel1Layout .createSequentialGroup() .addGap(73, 73, 73) .addGroup( jPanel1Layout .createParallelGroup( javax.swing.GroupLayout.Alignment.LEADING) .addGroup( jPanel1Layout .createSequentialGroup() .addGroup( jPanel1Layout .createParallelGroup( javax.swing.GroupLayout.Alignment.TRAILING) .addGroup( jPanel1Layout .createSequentialGroup() .addGap(51, 51, 51) .addComponent( jLabel3) .addPreferredGap( javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .addComponent( jLabel4)) .addGroup( jPanel1Layout .createSequentialGroup() .addComponent( jTextField1, javax.swing.GroupLayout.PREFERRED_SIZE, 486, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap( javax.swing.LayoutStyle.ComponentPlacement.RELATED, 26, Short.MAX_VALUE) .addComponent( jComboBox1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))) .addGap(91, 91, 91)) .addGroup( jPanel1Layout .createSequentialGroup() .addGap(11, 11, 11) .addComponent( jLabel2, javax.swing.GroupLayout.PREFERRED_SIZE, 160, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap( javax.swing.LayoutStyle.ComponentPlacement.UNRELATED) .addComponent( jRadioButton1) .addGap(18, 18, 18) .addComponent( jRadioButton2) .addGap(18, 18, 18) .addComponent( jRadioButton3) .addGap(18, 18, 18) .addComponent( jRadioButton4) .addGap(0, 0, Short.MAX_VALUE))))); jPanel1Layout .setVerticalGroup(jPanel1Layout .createParallelGroup( javax.swing.GroupLayout.Alignment.LEADING) .addGroup( jPanel1Layout .createSequentialGroup() .addContainerGap() .addGroup( jPanel1Layout .createParallelGroup( javax.swing.GroupLayout.Alignment.LEADING, false) .addComponent( jLabel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .addComponent( BotonPerfil, javax.swing.GroupLayout.DEFAULT_SIZE, 28, Short.MAX_VALUE) .addComponent( botonLogin, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)) .addGap(41, 41, 41) .addGroup( jPanel1Layout .createParallelGroup( javax.swing.GroupLayout.Alignment.LEADING) .addGroup( jPanel1Layout .createSequentialGroup() .addGroup( jPanel1Layout .createParallelGroup( javax.swing.GroupLayout.Alignment.BASELINE) .addComponent( jTextField1, javax.swing.GroupLayout.PREFERRED_SIZE, 37, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent( jComboBox1, javax.swing.GroupLayout.PREFERRED_SIZE, 37, javax.swing.GroupLayout.PREFERRED_SIZE)) .addGap(32, 32, 32) .addGroup( jPanel1Layout .createParallelGroup( javax.swing.GroupLayout.Alignment.BASELINE) .addComponent( jLabel2, javax.swing.GroupLayout.PREFERRED_SIZE, 23, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent( jRadioButton1) .addComponent( jRadioButton2) .addComponent( jRadioButton3) .addComponent( jRadioButton4)) .addGap(23, 23, 23) .addGroup( jPanel1Layout .createParallelGroup( javax.swing.GroupLayout.Alignment.BASELINE) .addComponent( jLabel3) .addComponent( jLabel4))) .addComponent( jToggleButton1, javax.swing.GroupLayout.PREFERRED_SIZE, 38, javax.swing.GroupLayout.PREFERRED_SIZE)) .addPreferredGap( javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup( jPanel1Layout .createParallelGroup( javax.swing.GroupLayout.Alignment.LEADING) .addComponent( jScrollPane2) .addGroup( jPanel1Layout .createSequentialGroup() .addComponent( jScrollPane3, javax.swing.GroupLayout.PREFERRED_SIZE, 407, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap( javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .addComponent( botonComprar, javax.swing.GroupLayout.PREFERRED_SIZE, 37, javax.swing.GroupLayout.PREFERRED_SIZE)) .addGroup( jPanel1Layout .createSequentialGroup() .addGap(14, 14, 14) .addComponent( botonAnadirCesta) .addGap(18, 18, 18) .addComponent( jButton5) .addGap(18, 18, 18) .addComponent( jLabel5) .addGap(2, 2, 2) .addComponent( jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 136, javax.swing.GroupLayout.PREFERRED_SIZE) .addGap(23, 23, 23) .addComponent( jLabel6) .addPreferredGap( javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent( jScrollPane4))) .addContainerGap())); javax.swing.GroupLayout layout = new javax.swing.GroupLayout( getContentPane()); getContentPane().setLayout(layout); layout.setHorizontalGroup(layout.createParallelGroup( javax.swing.GroupLayout.Alignment.LEADING).addGroup( javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup() .addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addContainerGap())); layout.setVerticalGroup(layout.createParallelGroup( javax.swing.GroupLayout.Alignment.LEADING).addGroup( layout.createSequentialGroup() .addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addGap(0, 0, Short.MAX_VALUE))); pack(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Form() {\n initComponents();\n }", "public MainForm() {\n initComponents();\n }", "public MainForm() {\n initComponents();\n }", "public MainForm() {\n initComponents();\n }", "public frmRectangulo() {\n initComponents();\n }", "public form() {\n initComponents();\n }", "public AdjointForm() {\n initComponents();\n setDefaultCloseOperation(HIDE_ON_CLOSE);\n }", "public FormListRemarking() {\n initComponents();\n }", "public MainForm() {\n initComponents();\n \n }", "public FormPemilihan() {\n initComponents();\n }", "public GUIForm() { \n initComponents();\n }", "public FrameForm() {\n initComponents();\n }", "public TorneoForm() {\n initComponents();\n }", "public FormCompra() {\n initComponents();\n }", "public muveletek() {\n initComponents();\n }", "public Interfax_D() {\n initComponents();\n }", "public quanlixe_form() {\n initComponents();\n }", "public SettingsForm() {\n initComponents();\n }", "public RegistrationForm() {\n initComponents();\n this.setLocationRelativeTo(null);\n }", "public Soru1() {\n initComponents();\n }", "public FMainForm() {\n initComponents();\n this.setResizable(false);\n setLocationRelativeTo(null);\n }", "public soal2GUI() {\n initComponents();\n }", "public EindopdrachtGUI() {\n initComponents();\n }", "public MechanicForm() {\n initComponents();\n }", "public AddDocumentLineForm(java.awt.Frame parent) {\n super(parent);\n initComponents();\n myInit();\n }", "public BloodDonationGUI() {\n initComponents();\n }", "public quotaGUI() {\n initComponents();\n }", "public Customer_Form() {\n initComponents();\n setSize(890,740);\n \n \n }", "public PatientUI() {\n initComponents();\n }", "public myForm() {\n\t\t\tinitComponents();\n\t\t}", "public Oddeven() {\n initComponents();\n }", "public intrebarea() {\n initComponents();\n }", "public Magasin() {\n initComponents();\n }", "public RadioUI()\n {\n initComponents();\n }", "public NewCustomerGUI() {\n initComponents();\n }", "public ZobrazUdalost() {\n initComponents();\n }", "public FormUtama() {\n initComponents();\n }", "public p0() {\n initComponents();\n }", "public INFORMACION() {\n initComponents();\n this.setLocationRelativeTo(null); \n }", "public ProgramForm() {\n setLookAndFeel();\n initComponents();\n }", "public AmountReleasedCommentsForm() {\r\n initComponents();\r\n }", "public form2() {\n initComponents();\n }", "public MainForm() {\n\t\tsuper(\"Hospital\", List.IMPLICIT);\n\n\t\tstartComponents();\n\t}", "public LixeiraForm() {\n initComponents();\n setLocationRelativeTo(null);\n }", "public kunde() {\n initComponents();\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n setName(\"Form\"); // NOI18N\n setRequestFocusEnabled(false);\n setVerifyInputWhenFocusTarget(false);\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);\n this.setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 465, Short.MAX_VALUE)\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 357, Short.MAX_VALUE)\n );\n }", "public MusteriEkle() {\n initComponents();\n }", "public frmMain() {\n initComponents();\n }", "public frmMain() {\n initComponents();\n }", "public DESHBORDPANAL() {\n initComponents();\n }", "public GUIForm() {\n initComponents();\n inputField.setText(NO_FILE_SELECTED);\n outputField.setText(NO_FILE_SELECTED);\n progressLabel.setBackground(INFO);\n progressLabel.setText(SELECT_FILE);\n }", "public frmVenda() {\n initComponents();\n }", "public Botonera() {\n initComponents();\n }", "public FrmMenu() {\n initComponents();\n }", "public OffertoryGUI() {\n initComponents();\n setTypes();\n }", "public JFFornecedores() {\n initComponents();\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents()\n {\n\n setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);\n setBackground(new java.awt.Color(255, 255, 255));\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());\n getContentPane().setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 983, Short.MAX_VALUE)\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 769, Short.MAX_VALUE)\n );\n\n pack();\n }", "public EnterDetailsGUI() {\n initComponents();\n }", "public vpemesanan1() {\n initComponents();\n }", "public Kost() {\n initComponents();\n }", "public FormHorarioSSE() {\n initComponents();\n }", "public UploadForm() {\n initComponents();\n }", "public frmacceso() {\n initComponents();\n }", "public HW3() {\n initComponents();\n }", "public Managing_Staff_Main_Form() {\n initComponents();\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents()\n {\n\n setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);\n getContentPane().setLayout(null);\n\n pack();\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n setName(\"Form\"); // NOI18N\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);\n this.setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 400, Short.MAX_VALUE)\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 300, Short.MAX_VALUE)\n );\n }", "public sinavlar2() {\n initComponents();\n }", "public P0405() {\n initComponents();\n }", "public IssueBookForm() {\n initComponents();\n }", "public MiFrame2() {\n initComponents();\n }", "public Choose1() {\n initComponents();\n }", "public MainForm() {\n initComponents();\n\n String oldAuthor = prefs.get(\"AUTHOR\", \"\");\n if(oldAuthor != null) {\n this.authorTextField.setText(oldAuthor);\n }\n String oldBook = prefs.get(\"BOOK\", \"\");\n if(oldBook != null) {\n this.bookTextField.setText(oldBook);\n }\n String oldDisc = prefs.get(\"DISC\", \"\");\n if(oldDisc != null) {\n try {\n int oldDiscNum = Integer.parseInt(oldDisc);\n oldDiscNum++;\n this.discNumberTextField.setText(Integer.toString(oldDiscNum));\n } catch (Exception ex) {\n this.discNumberTextField.setText(oldDisc);\n }\n this.bookTextField.setText(oldBook);\n }\n\n\n }", "public GUI_StudentInfo() {\n initComponents();\n }", "public Lihat_Dokter_Keseluruhan() {\n initComponents();\n }", "public JFrmPrincipal() {\n initComponents();\n }", "public bt526() {\n initComponents();\n }", "public Pemilihan_Dokter() {\n initComponents();\n }", "public Ablak() {\n initComponents();\n }", "@Override\n\tprotected void initUi() {\n\t\t\n\t}", "@SuppressWarnings(\"unchecked\")\n\t// <editor-fold defaultstate=\"collapsed\" desc=\"Generated\n\t// Code\">//GEN-BEGIN:initComponents\n\tprivate void initComponents() {\n\n\t\tlabel1 = new java.awt.Label();\n\t\tlabel2 = new java.awt.Label();\n\t\tlabel3 = new java.awt.Label();\n\t\tlabel4 = new java.awt.Label();\n\t\tlabel5 = new java.awt.Label();\n\t\tlabel6 = new java.awt.Label();\n\t\tlabel7 = new java.awt.Label();\n\t\tlabel8 = new java.awt.Label();\n\t\tlabel9 = new java.awt.Label();\n\t\tlabel10 = new java.awt.Label();\n\t\ttextField1 = new java.awt.TextField();\n\t\ttextField2 = new java.awt.TextField();\n\t\tlabel14 = new java.awt.Label();\n\t\tlabel15 = new java.awt.Label();\n\t\tlabel16 = new java.awt.Label();\n\t\ttextField3 = new java.awt.TextField();\n\t\ttextField4 = new java.awt.TextField();\n\t\ttextField5 = new java.awt.TextField();\n\t\tlabel17 = new java.awt.Label();\n\t\tlabel18 = new java.awt.Label();\n\t\tlabel19 = new java.awt.Label();\n\t\tlabel20 = new java.awt.Label();\n\t\tlabel21 = new java.awt.Label();\n\t\tlabel22 = new java.awt.Label();\n\t\ttextField6 = new java.awt.TextField();\n\t\ttextField7 = new java.awt.TextField();\n\t\ttextField8 = new java.awt.TextField();\n\t\tlabel23 = new java.awt.Label();\n\t\ttextField9 = new java.awt.TextField();\n\t\ttextField10 = new java.awt.TextField();\n\t\ttextField11 = new java.awt.TextField();\n\t\ttextField12 = new java.awt.TextField();\n\t\tlabel24 = new java.awt.Label();\n\t\tlabel25 = new java.awt.Label();\n\t\tlabel26 = new java.awt.Label();\n\t\tlabel27 = new java.awt.Label();\n\t\tlabel28 = new java.awt.Label();\n\t\tlabel30 = new java.awt.Label();\n\t\tlabel31 = new java.awt.Label();\n\t\tlabel32 = new java.awt.Label();\n\t\tjButton1 = new javax.swing.JButton();\n\n\t\tlabel1.setFont(new java.awt.Font(\"Segoe UI Semibold\", 0, 18)); // NOI18N\n\t\tlabel1.setText(\"It seems that some of the buttons on the ATM machine are not working!\");\n\n\t\tlabel2.setFont(new java.awt.Font(\"Segoe UI Semibold\", 0, 18)); // NOI18N\n\t\tlabel2.setText(\"Unfortunately these numbers are exactly what Professor has to use to type in his password.\");\n\n\t\tlabel3.setFont(new java.awt.Font(\"Segoe UI Semibold\", 0, 18)); // NOI18N\n\t\tlabel3.setText(\n\t\t\t\t\"If you want to eat tonight, you have to help him out and construct the numbers of the password with the working buttons and math operators.\");\n\n\t\tlabel4.setFont(new java.awt.Font(\"Segoe UI Semibold\", 0, 14)); // NOI18N\n\t\tlabel4.setText(\"Denver's Password: 2792\");\n\n\t\tlabel5.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel5.setText(\"import java.util.Scanner;\\n\");\n\n\t\tlabel6.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel6.setText(\"public class ATM{\");\n\n\t\tlabel7.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel7.setText(\"public static void main(String[] args){\");\n\n\t\tlabel8.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel8.setText(\"System.out.print(\");\n\n\t\tlabel9.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel9.setText(\" -\");\n\n\t\tlabel10.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel10.setText(\");\");\n\n\t\ttextField1.addActionListener(new java.awt.event.ActionListener() {\n\t\t\tpublic void actionPerformed(java.awt.event.ActionEvent evt) {\n\t\t\t\ttextField1ActionPerformed(evt);\n\t\t\t}\n\t\t});\n\n\t\tlabel14.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel14.setText(\"System.out.print( (\");\n\n\t\tlabel15.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel15.setText(\"System.out.print(\");\n\n\t\tlabel16.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel16.setText(\"System.out.print( ( (\");\n\n\t\tlabel17.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel17.setText(\")\");\n\n\t\tlabel18.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel18.setText(\" +\");\n\n\t\tlabel19.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel19.setText(\");\");\n\n\t\tlabel20.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel20.setText(\" /\");\n\n\t\tlabel21.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel21.setText(\" %\");\n\n\t\tlabel22.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel22.setText(\" +\");\n\n\t\tlabel23.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel23.setText(\");\");\n\n\t\tlabel24.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel24.setText(\" +\");\n\n\t\tlabel25.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel25.setText(\" /\");\n\n\t\tlabel26.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel26.setText(\" *\");\n\n\t\tlabel27.setCursor(new java.awt.Cursor(java.awt.Cursor.DEFAULT_CURSOR));\n\t\tlabel27.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel27.setText(\")\");\n\n\t\tlabel28.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel28.setText(\")\");\n\n\t\tlabel30.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel30.setText(\"}\");\n\n\t\tlabel31.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel31.setText(\"}\");\n\n\t\tlabel32.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel32.setText(\");\");\n\n\t\tjButton1.setFont(new java.awt.Font(\"Segoe UI Semibold\", 0, 14)); // NOI18N\n\t\tjButton1.setText(\"Check\");\n\t\tjButton1.addActionListener(new java.awt.event.ActionListener() {\n\t\t\tpublic void actionPerformed(java.awt.event.ActionEvent evt) {\n\t\t\t\tjButton1ActionPerformed(evt);\n\t\t\t}\n\t\t});\n\n\t\tjavax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);\n\t\tlayout.setHorizontalGroup(layout.createParallelGroup(Alignment.LEADING)\n\t\t\t\t.addGroup(layout.createSequentialGroup().addGap(28).addGroup(layout\n\t\t\t\t\t\t.createParallelGroup(Alignment.LEADING).addComponent(getDoneButton()).addComponent(jButton1)\n\t\t\t\t\t\t.addComponent(label7, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addComponent(label6, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addComponent(label5, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addComponent(label4, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addComponent(label3, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t.addComponent(label1, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t.addGap(1)\n\t\t\t\t\t\t\t\t.addComponent(label2, GroupLayout.PREFERRED_SIZE, 774, GroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t.addGap(92).addGroup(layout.createParallelGroup(Alignment.LEADING).addGroup(layout\n\t\t\t\t\t\t\t\t\t\t.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.LEADING, false)\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label15, GroupLayout.PREFERRED_SIZE, 145,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField8, GroupLayout.PREFERRED_SIZE, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(2)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label21, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField7, GroupLayout.PREFERRED_SIZE, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label8, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField1, GroupLayout.PREFERRED_SIZE, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label9, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED).addComponent(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\ttextField2, GroupLayout.PREFERRED_SIZE, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label31, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup().addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label14, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(37))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup().addGap(174)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField5, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t20, GroupLayout.PREFERRED_SIZE)))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label18, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(7)))\n\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.LEADING).addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.TRAILING, false).addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField4, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t20, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label17, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label22, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField9, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t20, GroupLayout.PREFERRED_SIZE)))\n\t\t\t\t\t\t\t\t\t\t\t\t.addGap(20)\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label23, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label20, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField3, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t20, GroupLayout.PREFERRED_SIZE)))\n\t\t\t\t\t\t\t\t\t\t\t\t.addGap(20).addComponent(label19, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup().addGap(23).addComponent(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tlabel10, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))))\n\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label16, GroupLayout.PREFERRED_SIZE, 177,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField12, GroupLayout.PREFERRED_SIZE, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label24, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField6, GroupLayout.PREFERRED_SIZE, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label27, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label25, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField11, GroupLayout.PREFERRED_SIZE, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label28, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addGap(1)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label26, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField10, GroupLayout.PREFERRED_SIZE, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED).addComponent(label32,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))))\n\t\t\t\t\t\t.addComponent(label30, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t.addContainerGap(GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)));\n\t\tlayout.setVerticalGroup(\n\t\t\t\tlayout.createParallelGroup(Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap()\n\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.TRAILING)\n\t\t\t\t\t\t\t\t.addComponent(label1, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t.addComponent(label2, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t.addGap(1)\n\t\t\t\t\t\t.addComponent(label3, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t.addComponent(label4, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t.addComponent(label5, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t.addComponent(label6, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t.addComponent(label7, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t.createParallelGroup(\n\t\t\t\t\t\t\t\t\t\tAlignment.TRAILING)\n\t\t\t\t\t\t\t\t.addGroup(\n\t\t\t\t\t\t\t\t\t\tlayout.createSequentialGroup().addGroup(layout.createParallelGroup(\n\t\t\t\t\t\t\t\t\t\t\t\tAlignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createSequentialGroup().addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.TRAILING).addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label9,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label8,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField1,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\ttextField2, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label10,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(3)))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(19)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField5,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label14,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup().addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label18,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label17,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField4,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(1))))\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label20, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label19, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField3, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)))\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup().addGap(78)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label27, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup().addGap(76)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField11, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup().addGap(75)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label32,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField10,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tShort.MAX_VALUE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.TRAILING, false)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tAlignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label15,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField8,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label21,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField7,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(27))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tAlignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField9,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tAlignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label22,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tlayout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(3)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tlabel23,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(29)))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label16,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField12,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tAlignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label24,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField6,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(1))))))\n\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t.addComponent(label25, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t.addComponent(label28, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t.addComponent(label26, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)))\n\t\t\t\t\t\t.addGap(30)\n\t\t\t\t\t\t.addComponent(label31, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addGap(25)\n\t\t\t\t\t\t.addComponent(label30, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addGap(26).addComponent(jButton1).addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t.addComponent(getDoneButton()).addContainerGap(23, Short.MAX_VALUE)));\n\t\tthis.setLayout(layout);\n\n\t\tlabel16.getAccessibleContext().setAccessibleName(\"System.out.print( ( (\");\n\t\tlabel17.getAccessibleContext().setAccessibleName(\"\");\n\t\tlabel18.getAccessibleContext().setAccessibleName(\" +\");\n\t}", "public Pregunta23() {\n initComponents();\n }", "public FormMenuUser() {\n super(\"Form Menu User\");\n initComponents();\n }", "public AvtekOkno() {\n initComponents();\n }", "public busdet() {\n initComponents();\n }", "public ViewPrescriptionForm() {\n initComponents();\n }", "public Ventaform() {\n initComponents();\n }", "public Kuis2() {\n initComponents();\n }", "public CreateAccount_GUI() {\n initComponents();\n }", "public POS1() {\n initComponents();\n }", "public Carrera() {\n initComponents();\n }", "public EqGUI() {\n initComponents();\n }", "public JFriau() {\n initComponents();\n this.setLocationRelativeTo(null);\n this.setTitle(\"BuNus - Budaya Nusantara\");\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n setBackground(new java.awt.Color(204, 204, 204));\n setMinimumSize(new java.awt.Dimension(1, 1));\n setPreferredSize(new java.awt.Dimension(760, 402));\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);\n this.setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 750, Short.MAX_VALUE)\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 400, Short.MAX_VALUE)\n );\n }", "public nokno() {\n initComponents();\n }", "public dokter() {\n initComponents();\n }", "public ConverterGUI() {\n initComponents();\n }", "public hitungan() {\n initComponents();\n }", "public Modify() {\n initComponents();\n }", "public frmAddIncidencias() {\n initComponents();\n }", "public FP_Calculator_GUI() {\n initComponents();\n \n setVisible(true);\n }" ]
[ "0.73191476", "0.72906625", "0.72906625", "0.72906625", "0.72860986", "0.7248112", "0.7213479", "0.72078276", "0.7195841", "0.71899796", "0.71840525", "0.7158498", "0.71477973", "0.7092748", "0.70800966", "0.70558053", "0.69871384", "0.69773406", "0.69548076", "0.69533914", "0.6944929", "0.6942576", "0.69355655", "0.6931378", "0.6927896", "0.69248974", "0.6924723", "0.69116884", "0.6910487", "0.6892381", "0.68921053", "0.6890637", "0.68896896", "0.68881863", "0.68826133", "0.68815064", "0.6881078", "0.68771756", "0.6875212", "0.68744373", "0.68711984", "0.6858978", "0.68558776", "0.6855172", "0.6854685", "0.685434", "0.68525875", "0.6851834", "0.6851834", "0.684266", "0.6836586", "0.6836431", "0.6828333", "0.68276715", "0.68262815", "0.6823921", "0.682295", "0.68167603", "0.68164384", "0.6809564", "0.68086857", "0.6807804", "0.6807734", "0.68067646", "0.6802192", "0.67943805", "0.67934304", "0.6791657", "0.6789546", "0.6789006", "0.67878324", "0.67877173", "0.6781847", "0.6765398", "0.6765197", "0.6764246", "0.6756036", "0.6755023", "0.6751404", "0.67508715", "0.6743043", "0.67387456", "0.6736752", "0.67356426", "0.6732893", "0.6726715", "0.6726464", "0.67196447", "0.67157453", "0.6714399", "0.67140275", "0.6708251", "0.6707117", "0.670393", "0.6700697", "0.66995865", "0.66989213", "0.6697588", "0.66939527", "0.66908985", "0.668935" ]
0.0
-1
TODO Autogenerated method stub
private void actualizarLista(ArrayList<Producto> p2) { String[] str = new String[p2.size()]; for (int i = 0; i < p2.size(); i++) { str[i] = p2.get(i).get_nombre(); } str.clone(); listaProductos.setModel(new javax.swing.AbstractListModel<String>() { String[] strings = str.clone(); public int getSize() { return strings.length; } public String getElementAt(int i) { return strings[i]; } }); /*informacion.setText("Precio:\t" + p2.get(0).get_nombre() + "\n" + "Plataforma:\t" + p2.get(0).get_genero() + "\nPrecio:\t" + Double.toString(p2.get(0).get_precio()));*/ listaProductos.addListSelectionListener(new ListSelectionListener() { @Override public void valueChanged(ListSelectionEvent e) { if (!e.getValueIsAdjusting()) { informacion.setText(obtenerInfo(listaProductos.getSelectedValue().toString())); textoValoraciones.setText(obtenerValoraciones(listaProductos.getSelectedValue().toString())); } } }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\n public void perish() {\n \n }", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "@Override\n\tpublic void anular() {\n\n\t}", "@Override\n\tprotected void getExras() {\n\n\t}", "@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}", "@Override\n\tpublic void entrenar() {\n\t\t\n\t}", "@Override\n\tpublic void nadar() {\n\t\t\n\t}", "@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}", "@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}", "@Override\n\tprotected void interr() {\n\t}", "@Override\n\tpublic void emprestimo() {\n\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\n\tpublic void grabar() {\n\t\t\n\t}", "@Override\n\tpublic void gravarBd() {\n\t\t\n\t}", "@Override\r\n\tpublic void rozmnozovat() {\n\t}", "@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}", "@Override\n protected void getExras() {\n }", "@Override\r\n\tpublic void publierEnchere() {\n\t\t\r\n\t}", "@Override\n\tpublic void nefesAl() {\n\n\t}", "@Override\n\tpublic void ligar() {\n\t\t\n\t}", "@Override\n public void func_104112_b() {\n \n }", "@Override\n\tprotected void initdata() {\n\n\t}", "@Override\n\tpublic void nghe() {\n\n\t}", "@Override\n public void function()\n {\n }", "@Override\n public void function()\n {\n }", "public final void mo51373a() {\n }", "@Override\r\n\tpublic void stehReagieren() {\r\n\t\t//\r\n\t}", "@Override\n public void inizializza() {\n\n super.inizializza();\n }", "@Override\n\tprotected void initData() {\n\t\t\n\t}", "@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}", "@Override\n\tpublic void sacrifier() {\n\t\t\n\t}", "@Override\r\n\tprotected void InitData() {\n\t\t\r\n\t}", "public void designBasement() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}", "public void gored() {\n\t\t\n\t}", "@Override\r\n\tprotected void initData() {\n\r\n\t}", "@Override\n\tpublic void einkaufen() {\n\t}", "@Override\n protected void initialize() {\n\n \n }", "public void mo38117a() {\n }", "@Override\n\tprotected void getData() {\n\t\t\n\t}", "Constructor() {\r\n\t\t \r\n\t }", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "@Override\n\tpublic void one() {\n\t\t\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "private stendhal() {\n\t}", "@Override\n\tprotected void update() {\n\t\t\n\t}", "@Override\n\t\t\tpublic void ic() {\n\t\t\t\t\n\t\t\t}", "@Override\n\tprotected void initData() {\n\n\t}", "@Override\n\tprotected void initData() {\n\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n public void init() {\n\n }", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\n\tpublic void debite() {\n\t\t\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "public contrustor(){\r\n\t}", "@Override\n\tprotected void initialize() {\n\n\t}", "@Override\r\n\tpublic void dispase() {\n\r\n\t}", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "@Override\n\tpublic void dtd() {\n\t\t\n\t}", "@Override\n\tprotected void logic() {\n\n\t}", "@Override\n\tprotected void lazyLoad() {\n\t\t\n\t}", "public void mo4359a() {\n }", "@Override\r\n\tprotected void initialize() {\n\r\n\t}", "@Override\n public void memoria() {\n \n }", "@Override\n\t\tpublic void method() {\n\t\t\t\n\t\t}", "private RepositorioAtendimentoPublicoHBM() {\r\t}", "@Override\n protected void initialize() \n {\n \n }", "@Override\r\n\tpublic void getProposition() {\n\r\n\t}", "@Override\n\tpublic void particular1() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n protected void prot() {\n }", "@Override\r\n\tpublic void init()\r\n\t{\n\t}", "@Override\n\tprotected void initValue()\n\t{\n\n\t}", "public void mo55254a() {\n }" ]
[ "0.6671074", "0.6567672", "0.6523024", "0.6481211", "0.6477082", "0.64591026", "0.64127725", "0.63762105", "0.6276059", "0.6254286", "0.623686", "0.6223679", "0.6201336", "0.61950207", "0.61950207", "0.61922914", "0.6186996", "0.6173591", "0.61327106", "0.61285484", "0.6080161", "0.6077022", "0.6041561", "0.6024072", "0.6020252", "0.59984857", "0.59672105", "0.59672105", "0.5965777", "0.59485507", "0.5940904", "0.59239364", "0.5910017", "0.5902906", "0.58946234", "0.5886006", "0.58839184", "0.58691067", "0.5857751", "0.58503544", "0.5847024", "0.58239377", "0.5810564", "0.5810089", "0.5806823", "0.5806823", "0.5800025", "0.5792378", "0.5792378", "0.5792378", "0.5792378", "0.5792378", "0.5792378", "0.5790187", "0.5789414", "0.5787092", "0.57844025", "0.57844025", "0.5774479", "0.5774479", "0.5774479", "0.5774479", "0.5774479", "0.5761362", "0.57596046", "0.57596046", "0.575025", "0.575025", "0.575025", "0.5747959", "0.57337177", "0.57337177", "0.57337177", "0.5721452", "0.5715831", "0.57142824", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.5711723", "0.57041645", "0.56991017", "0.5696783", "0.56881124", "0.56774884", "0.56734604", "0.56728", "0.56696945", "0.5661323", "0.5657007", "0.5655942", "0.5655942", "0.5655942", "0.56549734", "0.5654792", "0.5652974", "0.5650185" ]
0.0
-1
Constructor. Initialize a new board game with the given parameter.
public BoardGame(String name, int dimension, int totalPlayer) { this.name = name; this.dimension = dimension; this.totalPlayer = totalPlayer; board = new int[dimension][dimension]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Board() {\n initialize(3, null);\n }", "public Game() {\n initializeBoard();\n }", "public Board()\r\n\t{\r\n\t\tsuper(8, 8);\r\n\t}", "public Board() {\n\t\tintializeBoard(_RowCountDefault, _ColumnCountDefault, _CountToWinDefault);\n\t}", "private GameBoard() {}", "Board() {\n this(INITIAL_PIECES, BLACK);\n _countBlack = 12;\n _countWhite = 12;\n _moveHistory = new ArrayList<Move>();\n _movesMade = 0;\n }", "public GameBoard (int height, int width)\n {\n mHeight = height;\n mWidth = width;\n }", "@Override\r\n\tpublic void init() \r\n\t{\r\n\t\tthis.board = new GameBoard();\r\n\t}", "public Game() {\n board = new FourBoard();\n }", "public Board() {\n\t\tdimension = 9;\n\t\tpuzzle = new int[dimension][dimension];\n\t}", "Board() {\r\n init();\r\n }", "public PersonalBoard(){\n this(0);\n }", "public Board(String gameType) {\n propertyFactory = new TileFactory(gameType);\n createBoard();\n }", "public Board() {\n this.board = new byte[][] { new byte[3], new byte[3], new byte[3] };\n }", "Board() {\n\t\tswitch (Board.boardType) {\n\t\tcase Tiny:\n\t\t\tthis.dimensions = TinyBoard; break;\n\t\tcase Giant:\n\t\t\tthis.dimensions = GiantBoard; break;\n\t\tdefault:\n\t\t\tthis.dimensions = StandardBoard; break;\n\t\t}\n\t\tboard = new Square[dimensions.x][dimensions.y];\n\t\tinit();\n\t}", "public Board() {\n this.x = 0;\n this.o = 0;\n }", "public ChessBoard() {\n initComponents();\n createChessBoard();\n\n }", "Board() {\n this.cardFactory = new CardFactory(this);\n }", "public Board() {\n\t\tboard = new char[9][9];\n\t}", "public Board()\r\n\t{\r\n\t\treset();\r\n\t}", "public AIPlayer(Board board) {\n cells = board.squares;\n }", "public Board(int boardHeight, int boardWidth) {\n this.boardWidth = boardHeight+1;\n this.boardHeight = boardWidth+1;\n this.board = new char[this.boardHeight][this.boardWidth];\n this.numShips = 0;\n boardInit();\n }", "public Board() {\n\t\tboard = new int[8][8];\n\t\tbombs = 64 / 3;\n\t\tdifficulty = GlobalModel.BESTSCORE_EASY;\n\t\tfillBoard();\n\t\tsetDefaultScores();\n\t}", "public Board() {\n for (int row = 0; row < 9; row++) {\n for (int col = 0; col < 9; col++) {\n this.grid[row][col] = 0;\n }\n }\n }", "public GameBoard() {\r\n boards = new ArrayList<GameBoard>();\r\n }", "public Board()\r\n {\r\n board = new Piece[8][8];\r\n xLength = yLength = 8;\r\n }", "public TetrisBoard() {\n super();\n\n myBoard = new Board();\n myHeight = myBoard.getHeight() * BLOCK_SIZE;\n myWidth = myBoard.getWidth() * BLOCK_SIZE;\n myGameMode = CLASSIC_MODE;\n myBoardString = myBoard.toString();\n myGameOver = false;\n myWelcome = true;\n myTimer = new Timer(INITIAL_TIMER_DELAY, new TimerListener());\n\n setupBoard();\n }", "public Board()\n\t{\n\t\tcols = DEFAULT_WIDTH;\n\t\trows = DEFAULT_HEIGHT;\n\t\t\n\t\tpieces = new int[rows][cols];\n\t\tif (pieces.length > 0)\n\t\t{\n\t\t\tfor (int i = 0; i < pieces.length; i++)\n\t\t\t\tfor (int j = 0; j < pieces[0].length; j++)\n\t\t\t\t\tpieces[i][j] = -1;\n\t\t}\n\t}", "private void initializeBoard() {\n\t\t\n\t}", "public WarGame(int rounds, WarBoard board){\n super(rounds, board);\n }", "public Board(int i) {\n initBoard(i);\n }", "private MyGameState(int[][] board, int turn) {\n this.board = board;\n this.turn = turn;\n }", "public Board(char[][] board) {\n this.boardWidth = board.length;\n this.boardHeight = board[0].length;\n this.board = board;\n this.numShips = 0;\n boardInit();\n }", "public Game() {\n board = new TileState[BOARD_SIZE][BOARD_SIZE];\n for(int i=0; i<BOARD_SIZE; i++)\n for(int j=0; j<BOARD_SIZE; j++)\n board[i][j] = TileState.BLANK;\n movesPlayed = 0;\n playerOneTurn = true;\n gameOver = false;\n }", "public ComputerPlayer(Board board) \n {\n this.board = board;\n }", "public UIBoard()\r\n\t{\r\n\t\t//Creates a 10x10 \"Board\" object\r\n\t\tsuper(10,10);\r\n\t\tgrid = new int[getLength()][getWidth()];\r\n\t\t\r\n\t\t//Sets all coordinates to the value 0, which corresponds to \"not hit yet\"\r\n\t\tfor(int i=0; i<grid.length; i++)\r\n\t\t\tfor(int j=0; j<grid[i].length; j++)\r\n\t\t\t\tgrid[i][j] = 0;\t\t\r\n\t}", "public PersonalBoard(int width, int height){\n super(width, height);\n this.rand = new Random();\n }", "private Board() {\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// A private board constructor to ensure only one is created\n\t\tsuper();\n\t}", "public JumbleBoard()\n {\n }", "public Board(int row, int column, int countToWin) {\n\t\tintializeBoard(row, column, countToWin);\n\t}", "public Board(int dimensions){\n this.dimensions = dimensions;\n createBoard(dimensions);\n this.status = Status.CREATED;\n this.hitsLeft = 15;\n }", "public Board()\r\n\t{\r\n\t\tfor(int x = 0; x < 9; x++)\r\n\t\t\tfor(int y = 0 ; y < 9; y++)\r\n\t\t\t{\r\n\t\t\t\tboard[x][y] = new Cell();\r\n\t\t\t\tboard[x][y].setBoxID( 3*(x/3) + (y)/3+1);\r\n\t\t\t}\r\n\t}", "public GameBoard() {\n this.gameStarted = false;\n this.turn = 1; \n this.boardState = new char[3][3];\n this.winner = 0; \n this.isDraw = false; \n\n }", "public void run() {\n GameBoard board = new GameBoard(nrows, ncols);\n\n\n }", "public Game() {\n playerBlack = new Player(Player.BLACK);\n playerBlack.setIsTurn(true);\n playerWhite = new Player(Player.WHITE);\n playerWhite.setIsTurn(false);\n boardObject = new Board();\n\n // Set invalid parameters to start. This is used in move verification.\n potentialSuccessiveSlot = new Slot(Board.MAX_ROW, Board.MAX_COLUMN, 2);\n slotFrom = boardObject.getSlot(-1, -1);\n slotTo = boardObject.getSlot(-1, -1);\n\n // First click is always true in the starting game state.\n firstClick = true;\n\n successiveMove = false;\n turnColor = Slot.BLACK;\n\n rootValues = new ArrayList<>();\n plyCutoff = 0;\n minimaxMove = null;\n firstClickCompMove = true;\n alphaBetaEnable = false;\n }", "public Board() {\r\n\t\tthis.size = 4;\r\n\t\tthis.gameBoard = createBoard(4);\r\n\t\tthis.openTiles = 16;\r\n\t\tthis.moves = 0;\r\n\t\tthis.xValues = new boolean[4][4];\r\n\t\tthis.yValues = new boolean[4][4];\r\n\t\tthis.complete = false;\r\n\t}", "public Board() {\n playerNumber = 2;\n deadBlackCount = 0;\n deadWhiteCount = 0;\n deadRedCount = 0;\n deadBlueCount = 0;\n\n fields = new Field[DIMENSION][DIMENSION];\n // init fields\n for (int i = 0; i < DIMENSION; i++) {\n for (int j = 0; j < DIMENSION; j++) {\n fields[i][j] = new Field();\n fields[i][j].setX(i);\n fields[i][j].setY(j);\n }\n }\n }", "public Board()\r\n\t{\r\n\t\tthis.grid = new CellState[GRID_SIZE][GRID_SIZE];\r\n\t\tthis.whiteMarblesCount = MARBLES_COUNT;\r\n\t\tthis.blackMarblesCount = MARBLES_COUNT;\r\n\t\t\r\n\t\t/**\r\n\t\t * Initializes the board with empty value\r\n\t\t */\r\n\t\tfor (int indexcol = 0; indexcol < GRID_SIZE; indexcol++)\r\n\t\t{\r\n\t\t\tfor (int indexrow = 0; indexrow < GRID_SIZE; indexrow++)\r\n\t\t\t{\r\n\t\t\t\tthis.grid[indexrow][indexcol] = CellState.EMPTY;\t\t\t\t\r\n\t\t\t}\t\r\n\t\t}\r\n\t\t\r\n\t\t/**\r\n\t\t * Sets marbles on the board with default style\r\n\t\t */\r\n\t\tfor (int indexcol = 0; indexcol < 5; indexcol++)\r\n\t\t{\r\n\t\t\tthis.grid[0][indexcol] = CellState.WHITE_MARBLE;\r\n\t\t\tthis.grid[8][8 - indexcol] = CellState.BLACK_MARBLE;\r\n\t\t}\r\n\t\tfor (int indexcol = 0; indexcol < 6; indexcol++)\r\n\t\t{\r\n\t\t\tthis.grid[1][indexcol] = CellState.WHITE_MARBLE;\r\n\t\t\tthis.grid[7][8 - indexcol] = CellState.BLACK_MARBLE;\r\n\t\t}\r\n\t\tfor (int indexcol = 2; indexcol < 5; indexcol++)\r\n\t\t{\r\n\t\t\tthis.grid[2][indexcol] = CellState.WHITE_MARBLE;\r\n\t\t\tthis.grid[6][8 - indexcol] = CellState.BLACK_MARBLE;\r\n\t\t}\r\n\t\tthis.grid[3][8] = CellState.INVALID;\r\n\t\tthis.grid[2][7] = CellState.INVALID;\r\n\t\tthis.grid[1][6] = CellState.INVALID;\r\n\t\tthis.grid[0][5] = CellState.INVALID;\r\n\t\tthis.grid[5][0] = CellState.INVALID;\r\n\t\tthis.grid[6][1] = CellState.INVALID;\r\n\t\tthis.grid[7][2] = CellState.INVALID;\r\n\t\tthis.grid[8][3] = CellState.INVALID;\r\n\t}", "public Board() {\n this.board = new Piece[16];\n }", "public BoardGame()\n\t{\n\t\tplayerPieces = new LinkedHashMap<String, GamePiece>();\n\t\tplayerLocations = new LinkedHashMap<String, Location>();\n\t\t\n\t}", "public TicTacToeBoard() {board = new int[rows][columns];}", "public Board() {\n\t\tboardState = new Field[DIMENSION][DIMENSION];\n\t\tfor(int i = 0; i < DIMENSION; i++) {\n\t\t\tfor(int j = 0; j < DIMENSION; j++) {\n\t\t\t\tboardState[i][j] = new Field();\n\t\t\t}\n\t\t}\n\t}", "public Board() {\n\t\tthis.myBoard = new BlockFor2048[4][4];\n\t\tint randomInserted = 0;\n\t\tint colInd = 0;\n\t\tint rowInd = 0;\n\t\twhile (randomInserted != 2){\n\t\t\tcolInd = (int)(Math.random() * 4);\n\t\t\trowInd = (int)(Math.random() * 4);\n\t\t\tif (this.myBoard[colInd][rowInd] == null){\n\t\t\t\tthis.myBoard[colInd][rowInd] = new BlockFor2048(2);\n\t\t\t\trandomInserted++;\n\t\t\t}\n\t\t}\t\t\n\t\tthis.ScoreValue = 0;\n\t}", "private void initializeBoard() {\n\n squares = new Square[8][8];\n\n // Sets the initial turn to the White Player\n turn = white;\n\n final int maxSquares = 8;\n for(int i = 0; i < maxSquares; i ++) {\n for (int j = 0; j < maxSquares; j ++) {\n\n Square square = new Square(j, i);\n Piece piece;\n Player player;\n\n if (i < 2) {\n player = black;\n } else {\n player = white;\n }\n\n if (i == 0 || i == 7) {\n switch(j) {\n case 3:\n piece = new Queen(player, square);\n break;\n case 4:\n piece = new King(player, square);\n break;\n case 2:\n case 5:\n piece = new Bishop(player, square);\n break;\n case 1:\n case 6:\n piece = new Knight(player, square);\n break;\n default:\n piece = new Rook(player, square);\n }\n square.setPiece(piece);\n } else if (i == 1 || i == 6) {\n piece = new Pawn(player, square);\n square.setPiece(piece);\n }\n squares[j][i] = square;\n }\n }\n }", "public GameBoard(){\r\n\t\tboard = new Box[boardSize];\r\n\t\tfor(int i = 0; i < boardSize; i++){\r\n\t\t\tboard[i] = Box.EMPTY;\r\n\t\t}\r\n\t}", "public Board(Player p1, Player p2) {\r\n try {\r\n crownImage = ImageIO.read(new File(\"crown.jpg\"));\r\n } catch (IOException e) {\r\n e.printStackTrace();\r\n }\r\n checks = new int[8][8];\r\n currentPlayer = p2;\r\n nextPlayer = p1;\r\n whiteQueens = 0;\r\n whiteChecks = 12;\r\n blackQueens = 0;\r\n blackChecks = 12;\r\n winner = null;\r\n isGame = true;\r\n window(this);\r\n initializeBoard();\r\n swapPlayer();\r\n repaint();\r\n\r\n }", "public Board() {\n this.actionField = new ActionField();\n this.buyField = new BuyField();\n }", "public Board(String blocks) { this(blocks, Heuristic.INT, null); }", "public Board() {\n for (int y = 0; y < spaces.length; y++) {\n for (int x = 0; x < spaces[0].length; x++) {\n spaces[y][x] = new SubBoard();\n wonBoards[y][x] = ' ';\n }\n }\n }", "public Board(String gameName) {\n\n super(gameName);\n \n gameBoard = this;\n squares = new Square[Chess.CHESS][Chess.CHESS];\n moveListener = new MoveListener(this);\n this.setLayout(new GridLayout(Chess.CHESS, Chess.CHESS));\n \n JMenuBar menuBar = new JMenuBar();\n setJMenuBar(menuBar);\n \n // Define and add menu items.\n JMenu fileMenu = new JMenu(\"File\");\n menuBar.add(fileMenu);\n \n // Add the same and load actions.\n JMenuItem saveAction = new JMenuItem(\"Save Game\");\n JMenuItem loadAction = new JMenuItem(\"Load Game\");\n fileMenu.add(saveAction);\n fileMenu.add(loadAction);\n \n initBoard();\n \n initMenu(gameBoard);\n \n setup();\n \n p1 = new Player(Color.RED, true);\n p2 = new Player(Color.BLACK, false);\n \n this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n this.pack();\n this.centre();\n this.setVisible(true); \n }", "ComputerPlayer(Board board) {\n\t\tthis.board = board;\n\t\tthis.maxColumn = this.board.getBoardDataArray()[0].length;\n\t\tthis.maxRow = this.board.getBoardDataArray().length;\n\n\t\tSystem.out.println(\"Computer Player initialized ...\");\n\t}", "public Board(int lines, int columns, List<String> board) {\r\n\t\tif (lines == 0 || lines % 2 != 0 || lines < 2 || lines > 98) {\r\n\t\t\tthrow new IllegalArgumentException(\"Error! Line length is invalid.\");\r\n\t\t} else if (columns == 0 || columns % 2 != 0 || columns < 2 || columns > 26) {\r\n\t\t\tthrow new IllegalArgumentException(\r\n\t\t\t\t\t\"Error! Column length is invalid.\");\r\n\t\t} else if (board != null) {\r\n\r\n\t\t\tfor (String s : board) {\r\n\t\t\t\tif (!s.matches(\"[W,B,#,,-]+\")) {\r\n\t\t\t\t\tthrow new IllegalArgumentException(\r\n\t\t\t\t\t\t\t\"Error! Invalid board parameters.\");\r\n\t\t\t\t} else if (s.length() != columns) {\r\n\t\t\t\t\tthrow new IllegalArgumentException(\r\n\t\t\t\t\t\t\t\"Error! Board columns not equal to columns.\");\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tif (board.size() != lines) {\r\n\t\t\t\tthrow new IllegalArgumentException(\r\n\t\t\t\t\t\t\"Error! Board lines not equal to lines.\");\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tthis.playBoard = new char[lines][columns];\r\n\t\tthis.possibleMoves = new ArrayList<PossibleMove>();\r\n\r\n\t\tif (board == null) {\r\n\t\t\tthis.init();\r\n\t\t} else {\r\n\t\t\tfor (int i = 0; i < playBoard.length; i++) {\r\n\t\t\t\tfor (int j = 0; j < playBoard[0].length; j++) {\r\n\t\t\t\t\tplayBoard[i][j] = board.get(i).charAt(j);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}", "public BoardTest() {\n initComponents();\n \n createSudoku();\n //createBoggle();\n }", "public Board(Board a)\n {\n mainBoard=false;\n squares = new Square[Chess.ROWS][Chess.COLUMNS];\n setLayout(new GridLayout(Chess.ROWS,Chess.COLUMNS,0,0));\n if (a.firstSelected==null)\n firstSelected=null;\n else\n firstSelected = new Piece(a.firstSelected);\n for (int i = 0; i < Chess.ROWS; i++)\n for (int j = 0; j < Chess.COLUMNS; j++)\n squares[i][j] = new Square(a.squares[i][j]);\n }", "public Game(Scanner scan, Random gen)\n {\n\t_scan = scan;\n\t_gen = gen;\n\n\t_the_board = new Board(scan, gen);\n }", "public Game() {\n\t\tthis.board = new Board();\n\t\tthis.pieces = new HashMap<Chess.Color, List<Piece>>();\n\t\tthis.pieces.put(Chess.Color.WHITE, new ArrayList<Piece>());\n\t\tthis.pieces.put(Chess.Color.BLACK, new ArrayList<Piece>());\n\t\tthis.moveStack = new Stack<Move>();\n\t}", "public Board(){\n for(int holeIndex = 0; holeIndex<holes.length; holeIndex++)\n holes[holeIndex] = new Hole(holeIndex);\n for(int kazanIndex = 0; kazanIndex<kazans.length; kazanIndex++)\n kazans[kazanIndex] = new Kazan(kazanIndex);\n nextToPlay = Side.WHITE;\n }", "private Board()\r\n {\r\n this.grid = new Box[Config.GRID_SIZE][Config.GRID_SIZE];\r\n \r\n for(int i = 0; i < Config.NB_WALLS; i++)\r\n {\r\n this.initBoxes(Wall.ID);\r\n }\r\n \r\n for(int i = 0; i < Config.NB_CHAIR; i++)\r\n {\r\n this.initBoxes(Chair.ID);\r\n }\r\n \r\n for(int i = 0; i < Config.NB_PLAYER; i++)\r\n {\r\n this.initBoxes(Chair.ID);\r\n }\r\n }", "public Board() {\n\t\tthis.table = new int[Constants.SIZE][Constants.SIZE];\n\t\tthis.P1Movable = new boolean[Constants.SIZE][Constants.SIZE];\n\t\tthis.P2Movable = new boolean[Constants.SIZE][Constants.SIZE];\n\t\tP1turn = true;\n\t\tnumPieces = 0;\n\t\t\n\t\tfor(int i=0; i<table.length; i++) {\n\t\t\tfor(int j=0; j<table[i].length; j++) {\n\t\t\t\ttable[i][j] = Constants.EMPTY;\n\t\t\t\tP1Movable[i][j] = true;\n\t\t\t\tP2Movable[i][j] = true;\n\t\t\t}\n\t\t}\n\t\t\n\t}", "public Board(String boardName) {\n\n /*\n * Created according to the specs online.\n */\n if (boardName.equals(\"default\")) {\n Ball ball1 = new Ball(new Vect(0, 0), new Geometry.DoublePair(1.25,\n 1.25));\n Gadget circle = new CircleBumper(1, 10, new Gadget[] {});\n Gadget triangle = new TriangleBumper(12, 15, 180, new Gadget[] {});\n Gadget square1 = new SquareBumper(0, 17, new Gadget[] {});\n Gadget square2 = new SquareBumper(1, 17, new Gadget[] {});\n Gadget square3 = new SquareBumper(2, 17, new Gadget[] {});\n Gadget circle1 = new CircleBumper(7, 18, new Gadget[] {});\n Gadget circle2 = new CircleBumper(8, 18, new Gadget[] {});\n Gadget circle3 = new CircleBumper(9, 18, new Gadget[] {});\n this.balls = new Ball[] { ball1 };\n this.gadgets = new Gadget[] { circle, triangle, square1, square2,\n square3, circle1, circle2, circle3, top, bottom, left,\n right };\n\n } else if (boardName.equals(\"absorber\")) {\n Ball ball1 = new Ball(new Vect(0, 0), new Geometry.DoublePair(\n 10.25, 15.25));\n Ball ball2 = new Ball(new Vect(0, 0), new Geometry.DoublePair(\n 19.25, 3.25));\n Ball ball3 = new Ball(new Vect(0, 0), new Geometry.DoublePair(1.25,\n 5.25));\n Gadget absorber = new Absorber(0, 18, 20, 2, new Gadget[] {});\n Gadget triangle = new TriangleBumper(19, 0, 90, new Gadget[] {});\n Gadget circle1 = new CircleBumper(1, 10, new Gadget[] { absorber });\n Gadget circle2 = new CircleBumper(2, 10, new Gadget[] { absorber });\n Gadget circle3 = new CircleBumper(3, 10, new Gadget[] { absorber });\n Gadget circle4 = new CircleBumper(4, 10, new Gadget[] { absorber });\n Gadget circle5 = new CircleBumper(5, 10, new Gadget[] { absorber });\n this.balls = new Ball[] { ball1, ball2, ball3 };\n this.gadgets = new Gadget[] { absorber, triangle, circle1, circle2,\n circle3, circle4, circle5, top, left, right, bottom };\n }\n\n else if (boardName.equals(\"flippers\")) {\n Ball ball1 = new Ball(new Vect(0, 0), new Geometry.DoublePair(.25,\n 3.25));\n Ball ball2 = new Ball(new Vect(0, 0), new Geometry.DoublePair(5.25,\n 3.25));\n Ball ball3 = new Ball(new Vect(0, 0), new Geometry.DoublePair(\n 10.25, 3.25));\n Ball ball4 = new Ball(new Vect(0, 0), new Geometry.DoublePair(\n 15.25, 3.25));\n Ball ball5 = new Ball(new Vect(0, 0), new Geometry.DoublePair(\n 19.25, 3.25));\n Gadget left1 = new LeftFlipper(0, 8, 90, new Gadget[] {});\n Gadget left2 = new LeftFlipper(4, 10, 90, new Gadget[] {});\n Gadget left3 = new LeftFlipper(9, 8, 90, new Gadget[] {});\n Gadget left4 = new LeftFlipper(15, 8, 90, new Gadget[] {});\n Gadget circle1 = new CircleBumper(5, 18, new Gadget[] {});\n Gadget circle2 = new CircleBumper(7, 13, new Gadget[] {});\n Gadget circle3 = new CircleBumper(0, 5, new Gadget[] { left1 });\n Gadget circle4 = new CircleBumper(5, 5, new Gadget[] {});\n Gadget circle5 = new CircleBumper(10, 5, new Gadget[] { left3 });\n Gadget circle6 = new CircleBumper(15, 5, new Gadget[] { left4 });\n Gadget triangle1 = new TriangleBumper(19, 0, 90, new Gadget[] {});\n Gadget triangle2 = new TriangleBumper(10, 18, 180, new Gadget[] {});\n Gadget right1 = new RightFlipper(2, 15, 0, new Gadget[] {});\n Gadget right2 = new RightFlipper(17, 15, 0, new Gadget[] {});\n Gadget absorber = new Absorber(0, 19, 20, 1, new Gadget[] { right1,\n right2, new Absorber(0, 19, 20, 1, new Gadget[] {}) });\n this.balls = new Ball[] { ball1, ball2, ball3, ball4, ball5 };\n this.gadgets = new Gadget[] { left1, left2, left3, left4, circle1,\n circle2, circle3, circle4, circle5, circle6, triangle1,\n triangle2, right1, right2, absorber, top, bottom, left,\n right };\n } else {\n this.gadgets = new Gadget[] {};\n this.balls = new Ball[] {};\n }\n\n checkRep();\n }", "public void initializeBoard() {\n\n\t\t/*\n\t\t * How the array coordinates align with the actual chess board\n\t\t * (row,col) \n\t\t * (7,0) ... ... ... \n\t\t * (7,7) ... ... ... \n\t\t * ... ... ... \n\t\t * (2,0) ...\n\t\t * (1,0) ... \n\t\t * (0,0) ... ... ... (0,7)\n\t\t */\n\n\t\tboolean hasMoved = false;\n\t\tboolean white = true;\n\t\tboolean black = false;\n\n\t\t// Set white piece row\n\t\tboard[0][0] = new Piece('r', white, hasMoved, 0, 0, PieceArray.A_rookId);\n\t\tboard[0][1] = new Piece('n', white, hasMoved, 0, 1, PieceArray.B_knightId);\n\t\tboard[0][2] = new Piece('b', white, hasMoved, 0, 2, PieceArray.C_bishopId);\n\t\tboard[0][3] = new Piece('q', white, hasMoved, 0, 3, PieceArray.D_queenId);\n\t\tboard[0][4] = new Piece('k', white, hasMoved, 0, 4, PieceArray.E_kingId);\n\t\tboard[0][5] = new Piece('b', white, hasMoved, 0, 5, PieceArray.F_bishopId);\n\t\tboard[0][6] = new Piece('n', white, hasMoved, 0, 6, PieceArray.G_knightId);\n\t\tboard[0][7] = new Piece('r', white, hasMoved, 0, 7, PieceArray.H_rookId);\n\n\t\t// Set white pawns\n\t\tfor (int i = 0; i < 8; i++) {\n\t\t\tboard[1][i] = new Piece('p', white, hasMoved, 1, i, i + 8);\n\t\t}\n\n\t\t// Set empty rows\n\t\tfor (int row = 2; row < 6; row++)\n\t\t\tfor (int col = 0; col < 8; col++)\n\t\t\t\tboard[row][col] = null;\n\n\t\t// Set black pawns\n\t\tfor (int i = 0; i < 8; i++) {\n\t\t\tboard[6][i] = new Piece('p', black, hasMoved, 6, i, i+8);\n\t\t}\n\n\t\t// Set black piece row\n\t\tboard[7][0] = new Piece('r', black, hasMoved, 7, 0, PieceArray.A_rookId);\n\t\tboard[7][1] = new Piece('n', black, hasMoved, 7, 1, PieceArray.B_knightId);\n\t\tboard[7][2] = new Piece('b', black, hasMoved, 7, 2, PieceArray.C_bishopId);\n\t\tboard[7][3] = new Piece('q', black, hasMoved, 7, 3, PieceArray.D_queenId);\n\t\tboard[7][4] = new Piece('k', black, hasMoved, 7, 4, PieceArray.E_kingId);\n\t\tboard[7][5] = new Piece('b', black, hasMoved, 7, 5, PieceArray.F_bishopId);\n\t\tboard[7][6] = new Piece('n', black, hasMoved, 7, 6, PieceArray.G_knightId);\n\t\tboard[7][7] = new Piece('r', black, hasMoved, 7, 7, PieceArray.H_rookId);\n\t}", "public void initBoard() {\n board = new Board();\n\n // initilaisation des groupes\n Group violet = new Group();\n Group bleu = new Group();\n Group orange = new Group();\n Group vert = new Group();\n Group rouge = new Group();\n Group jaune = new Group();\n Group rose = new Group();\n Group marine = new Group();\n Group gare = new Group();\n Group compagnie = new Group();\n\n // ajout des cases\n board.addCaseBoard(new StartCase());\n board.addCaseBoard(new BuildingCaseImpl(\"Bvd Belleville\", 60, 2, 10,30, 90, 160,250, 30,violet, 50));\n board.addCaseBoard(new CaseBoardImpl(\"Caisse de caumunauté\"));\n board.addCaseBoard(new BuildingCaseImpl(\"Rue lecourbe\", 60, 4,20,60,180,320,450, 30,violet, 50));\n board.addCaseBoard(new CaseBoardImpl(\"Taxes\"));\n board.addCaseBoard(new BuyableCaseImpl(\"Gare Monparnasse\", 200, 2, 100,gare));\n board.addCaseBoard(new BuildingCaseImpl(\"Rue de Vaugirard\", 100, 6,30,90,270,400,550, 50, bleu, 50));\n board.addCaseBoard(new CaseBoardImpl(\"Chance\"));\n board.addCaseBoard(new BuildingCaseImpl(\"Rue de Courcelles\", 100, 6,30,90,270,400,550, 50, bleu, 50));\n board.addCaseBoard(new BuildingCaseImpl(\"Av de la Republique\", 120, 8,40,100,300,450,600, 60, bleu, 50));\n board.addCaseBoard(new CaseBoardImpl(\"Prison\"));\n board.addCaseBoard(new BuildingCaseImpl(\"Bvd de la villette\", 140, 10,50,150,450,625,750, 70, orange, 100));\n board.addCaseBoard(new BuyableCaseImpl(\"Compagnie de distribution d'electricité\",150, 0, 75, compagnie));\n board.addCaseBoard(new BuildingCaseImpl(\"Av de Neuilly\", 140, 10,50,150,450,625,750, 70, orange, 100));\n board.addCaseBoard(new BuildingCaseImpl(\"Rue de Paradis\", 160, 12,60,180,500,700,900, 80, orange, 100));\n board.addCaseBoard(new BuyableCaseImpl(\"Gare de Lyon\", 200, 2, 100,gare));\n board.addCaseBoard(new BuildingCaseImpl(\"Av de Mozart\", 180, 14,70,200,550,700,900, 90, vert, 100));\n board.addCaseBoard(new CaseBoardImpl(\"Caisse de Communauté\"));\n board.addCaseBoard(new BuildingCaseImpl(\"Bvd Saint Michel\", 180, 14,70,200,550,700,900, 90, vert, 100));\n board.addCaseBoard(new BuildingCaseImpl(\"Place Pigalle\", 200, 16,80,220,600,800,950, 100, vert, 100));\n board.addCaseBoard(new CaseBoardImpl(\"Park Gratuit\"));\n board.addCaseBoard(new BuildingCaseImpl(\"Av Matignon\", 220, 18,90,250,700,875,1050, 110, rouge, 150));\n board.addCaseBoard(new CaseBoardImpl(\"Chance\"));\n board.addCaseBoard(new BuildingCaseImpl(\"Bvd MalesHerbes\", 220, 18,90,250,700,875,1050, 110, rouge, 150));\n board.addCaseBoard(new BuildingCaseImpl(\"Av Henri-Martin\", 240, 20,100,300,750,925,1100, 120, rouge, 150));\n board.addCaseBoard(new BuyableCaseImpl(\"Gare du Nord\", 200, 2, 100,gare));\n board.addCaseBoard(new BuildingCaseImpl(\"Fb Saint Honoré\", 260, 22,110,330,800,975,1150, 130, jaune, 150));\n board.addCaseBoard(new BuildingCaseImpl(\"Place de la Bourse\", 260, 22,110,330,800,975,1150, 130, jaune, 150));\n board.addCaseBoard(new BuyableCaseImpl(\"Compagnie de distribution des eaux\",150, 0, 75, compagnie));\n board.addCaseBoard(new BuildingCaseImpl(\"Rue lafayette\", 280, 24,120,360,850,1025,1200, 140, jaune, 150));\n board.addCaseBoard(new CaseBoardImpl(\"Aller en Prison\"));\n board.addCaseBoard(new BuildingCaseImpl(\"Av de Breteuil\", 300, 26,130,390,900,1100,1275, 150, rose, 200));\n board.addCaseBoard(new BuildingCaseImpl(\"Av Foch\", 300, 26,130,390,900,1100,1275, 150, rose, 200));\n board.addCaseBoard(new CaseBoardImpl(\"Caisse de Communauté\"));\n board.addCaseBoard(new BuildingCaseImpl(\"Bvd des Capucines\", 320, 28,150,450,1000,1200,1400, 160, rose, 200));\n board.addCaseBoard(new BuyableCaseImpl(\"Gare Saint-Lazarre\", 200, 2, 100,gare));\n board.addCaseBoard(new CaseBoardImpl(\"Chance\"));\n board.addCaseBoard(new BuildingCaseImpl(\"Av des Champs Elysées\", 350, 35,175,500,1100,1300,1500, 175, marine, 200));\n board.addCaseBoard(new CaseBoardImpl(\"Caisse de Communauté\"));\n board.addCaseBoard(new BuildingCaseImpl(\"Rue de la Paix\", 400, 50,200,600,1400,1700,2000, 200, marine, 200));\n }", "Board() {\n this.ones = -1; // 1\n this.twos = -1; // 2\n this.threes = -1; // 3\n this.fours = -1; // 4\n this.fives = -1; // 5\n this.sixes = -1; // 6\n this.threeOfAKind = -1; // 7\n this.fourOfAKind = -1; // 8\n this.smallStraight = -1;// 9\n this.longStraight = -1; // 10\n this.fullHouse = -1; // 11\n this.yahtzee = -1; // 12\n }", "public static void makeBoardChess() {\r\n \r\n white = new AllPiece(\"White\");\r\n black = new AllPiece(\"Black\");\r\n \r\n }", "public Board(int x, int y){\n player1 = \"Player 1\";\n player2 = \"Player 2\";\n randomPlayer1 = \"CPU 1\";\n randomPlayer2 = \"CPU 2\";\n board = new Square[x][y];\n for (int i = 0; i < board.length;i++){\n row++;\n for(int j = 0; j < board.length; j++){\n if(column == y){\n column = 0;\n }\n column++;\n board[i][j] = new Square(row, column);\n }\n }\n row = x;\n column = y;\n }", "public ChessRunner(){\n\t\taddMouseListener(this);\n\t\tfor(int i=0;i<8;i++){\n\t\t\tfor (int j=1;j<7;j++)\n\t\t\t\tif(j==1)\n\t\t\t\t\tboard[i][j] = new BlackPawn();\n\t\t\t\telse if(j==6)\n\t\t\t\t\tboard[i][j] = new WhitePawn();\n\t\t\t\telse\n\t\t\t\t\tboard[i][j]= new BlankPiece();\n\t\t}\n\t\tboard[1][0] = new BlackKnight();\n\t\tboard[6][0] = new BlackKnight();\n\t\tboard[0][0] = new BlackRook();\n\t\tboard[7][0] = new BlackRook();\n\t\tboard[2][0] = new BlackBishop();\n\t\tboard[5][0] = new BlackBishop();\n\t\tboard[4][0] = new BlackKing();\n\t\tboard[3][0] = new BlackQueen();\n\t\t\n\t\tboard[1][7] = new WhiteKnight();\n\t\tboard[6][7] = new WhiteKnight();\n\t\tboard[0][7] = new WhiteRook();\n\t\tboard[7][7] = new WhiteRook();\n\t\tboard[2][7] = new WhiteBishop();\n\t\tboard[5][7] = new WhiteBishop();\n\t\tboard[4][7] = new WhiteKing();\n\t\tboard[3][7] = new WhiteQueen();\n\t\t\n\t}", "public Board() {\n\n\n\t\tfruits = new ArrayList<>();\n\n\t\tscore = fruitsEaten = 0;\n\t\tsnake = new Snake();\n\t\trand = new Random();\n\t\thead = snake.getHead();\n\t\tstate = GameState.Started;\n\n\n\t\t\n\t}", "public Gameboard() {\n\n\t\tturn = 0;\n\n\t\tboard = new Cell[4][4][4];\n\n\t\tfor (int i = 0; i < board.length; i++) {\n\t\t\tfor (int j = 0; j < board.length; j++) {\n\t\t\t\tfor (int k = 0; k < board.length; k++) {\n\n\t\t\t\t\tboard[i][j][k] = Cell.E;\n\n\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "public Board() {\n\n for(int row = 0; row < size; row++) {\n for(int col = 0; col < size; col++) {\n\n grid[row][col] = \"-\";\n\n }\n }\n\n }", "private Game(int boardSize) {\n this.boardSize = boardSize;\n this.board = new char[boardSize][boardSize];\n this.players = new APlayer[2];\n this.players[0] = new HumanPlayer(this, 'X');\n this.players[1] = new CpuPlayer(this, 'O');\n }", "public GameBoard() {\n\t\t\n\t\t// Initiate LoginScreen\n\t\tloginScreen();\n\t}", "public Player(GameBoard board) {\n\t\tthis.board = board;\n\t}", "public CheckersGame(CheckersData passedBoard) {\n boardData = passedBoard;\n }", "public GameBoard(){\r\n boardCells = new GameCell[NUMBER_OF_CELLS];\r\n for( int i= 0; i< NUMBER_OF_CELLS; i++ ){\r\n boardCells[i] = new GameCell(i);//\r\n }\r\n }", "public Board(int[][] grid, Tetrimino piece) {\n //initComponents();\n this.grid = grid;\n this.piece = piece;\n setLayout(new GridLayout(grid.length-4, grid[0].length));\n init();\n }", "public Sudoku(int[][] board){\n setBoard(board);\n }", "public TrollGame () {\n rand = new Random();\n initBoard(ROWS, COLS, rand);\n }", "public Game(int choose) {\n\t\tthis.board = new Grid();\n\t\tthis.sp = 200;\n\t\tthis.spawnZombie(choose);\n\t}", "void initializeGame() {\n // Initialize players\n // Put the pieces on the board\n }", "public static void boardInit() {\n ArrayList<Piece> white_piece_list = new ArrayList<>();\n ArrayList<Piece> black_piece_list = new ArrayList<>();\n ArrayList<Piece> piece_array = PieceFactory.createPieces();\n for(Piece p : piece_array)\n {\n if(p.getColor())\n {\n black_piece_list.add(p);\n }\n else\n {\n white_piece_list.add(p);\n }\n }\n white_player.setpieceList(white_piece_list);\n white_player.setKingXYCoords(PieceFactory.KING_INITIAL_X, PieceFactory.INITAL_Y_COORD_WHITE_PLAYER_OTHER);\n black_player.setpieceList(black_piece_list);\n black_player.setKingXYCoords(PieceFactory.KING_INITIAL_X, PieceFactory.INITAL_Y_COORD_WHITE_PLAYER_OTHER + PieceFactory.DIST_BETWEEN_PIECES);\n }", "public Board(int width, int height) {\n\t\tthis.width = width;\n\t\tthis.height = height;\n\t\tgrid = new boolean[width][height];\n\t\tcommitted = true;\n\t\t//Initialize the quick palying data attributes\n\t\twidths = new int[height];\n\t\theights = new int[width];\n\t\tmaxHeight = 0;\n\t\t//Initialize the undo data\n\t\tundoWidths = new int[height];\n\t\tundoHeights = new int[width];\n\t\tundoGrid = new boolean[width][height];\n\t\t\n\t\t// YOUR CODE HERE\n\t}", "private void getBoard() {\n gameBoard = BoardFactory.makeBoard();\n }", "public Board(int size) {\n initialize(size, null);\n }", "public TPanel(final Board theBoard) {\r\n super();\r\n myBoard = theBoard;\r\n myGameOver = false;\r\n myGamePaused = false;\r\n }", "public Board() {\n //Create all pieces\n board[0][0] = new Rook(\"black\", 0, 0);\n board[0][1] = new Knight(\"black\", 0, 1);\n board[0][2] = new Bishop(\"black\", 0, 2);\n board[0][3] = new Queen(\"black\", 0, 3);\n board[0][4] = new King(\"black\", 0, 4);\n board[0][5] = new Bishop(\"black\", 0, 5);\n board[0][6] = new Knight(\"black\", 0, 6);\n board[0][7] = new Rook(\"black\", 0, 7);\n\n board[7][0] = new Rook(\"white\", 7, 0);\n board[7][1] = new Knight(\"white\", 7, 1);\n board[7][2] = new Bishop(\"white\", 7, 2);\n board[7][3] = new Queen(\"white\", 7, 3);\n board[7][4] = new King(\"white\", 7, 4);\n board[7][5] = new Bishop(\"white\", 7, 5);\n board[7][6] = new Knight(\"white\", 7, 6);\n board[7][7] = new Rook(\"white\", 7, 7);\n\n for (int j = 0; j < 8; j++) {\n board[1][j] = new Pawn(\"black\", 1, j);\n board[6][j] = new Pawn(\"white\", 6, j);\n }\n\n //Printing everything\n for (Piece[] a : board) {\n for (Piece b : a) {\n System.out.printf(\"%-15s\", \"[\" + b + \"]\");\n }\n System.out.println(\"\");\n }\n }", "public OthelloBoard (int height, int width){\n super(height, width);\n m_Pieces = new OthelloPiece[WIDTH][HEIGHT];\n m_PieceCount+=4;\n \n }", "public Board(C4.Canvas gameContext, String player1Colour, String player2Colour) {\r\n game = gameContext;\r\n players = new Player[2];\r\n players[0] = new Player(player1Colour);\r\n players[1] = new Player(player2Colour);\r\n boardArray = new Piece[7][7];\r\n for (int nx = 0; nx < 7; nx++) {\r\n for (int ny = 0; ny < 7; ny++) {\r\n boardArray[nx][ny] = new Piece();\r\n }\r\n }\r\n }", "public TicTacToe()\n\t{\n\t\t// board array has an index of 10\n\t\tboard = new String[ 10 ];\n\t\t\n\t}", "@Override\r\n\tpublic Board createBoard(long width, long height)\r\n\t{\r\n\t\treturn new Board(width, height);\r\n\t}", "public BoardInterface(){\n\t\tsetupLayouts();\n\t\tsetPlayerChoice();\n\t}", "public TicTacToe(){ \r\n\t\tboard = new char[3][3];\r\n\t}" ]
[ "0.7792922", "0.77251273", "0.7643839", "0.75925857", "0.7575175", "0.75373137", "0.75269353", "0.7523065", "0.75038147", "0.75003546", "0.7481958", "0.7418533", "0.7409485", "0.73948795", "0.7361964", "0.7335899", "0.7335552", "0.73193413", "0.7291187", "0.7290027", "0.7288622", "0.72775996", "0.7269466", "0.7213819", "0.721211", "0.7204846", "0.71778125", "0.7164618", "0.71483463", "0.7145253", "0.71309495", "0.7118984", "0.7116575", "0.7111805", "0.7108941", "0.710336", "0.70957166", "0.7085847", "0.70722055", "0.7072163", "0.7061158", "0.70319897", "0.70298344", "0.70266277", "0.7019186", "0.7018743", "0.699861", "0.6990298", "0.6985349", "0.6949899", "0.69441587", "0.69182265", "0.68781334", "0.68669", "0.6859505", "0.6859501", "0.68558586", "0.6853921", "0.68190515", "0.68181795", "0.6814649", "0.6809603", "0.6807509", "0.6800049", "0.6776497", "0.6775165", "0.67660207", "0.6756536", "0.6754705", "0.67534685", "0.67523783", "0.675221", "0.67432165", "0.6735968", "0.673204", "0.67210066", "0.6719179", "0.6692778", "0.6692266", "0.66832006", "0.66802114", "0.66723436", "0.66616213", "0.6660743", "0.66545063", "0.66532385", "0.6634012", "0.6632972", "0.66288114", "0.6627616", "0.6624431", "0.6618858", "0.66139024", "0.6608356", "0.6606231", "0.65999067", "0.6592599", "0.6589935", "0.6588293", "0.6585923", "0.6580497" ]
0.0
-1
Checks if the coordinate exists on the square dimensional board.
public boolean isValid(int row, int col) { return isValid(row) && isValid(col); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public boolean isOpenSquare(int x, int y)\r\n {\r\n return isValidSqr(x, y) && board[x][y] == null;\r\n }", "public boolean hasPiece(int x, int y)\r\n {\r\n return isValidSqr(x, y) && board[x][y] != null;\r\n }", "public boolean coordOnBoard(int row, int col, ArrayList<ArrayList<GamePiece>> board) {\n return (0 <= row && row < board.size()) && (0 <= col && col < board.get(0).size());\n }", "boolean isPaintedSquare(int row, int col) {\n return grid[row][col];\n }", "private boolean isValidCoordinate(int x, int y) {\n return x >= 0 && x < gameState.mapSize\n && y >= 0 && y < gameState.mapSize;\n }", "public boolean valid(int x, int y) {\n return board[x][y] == 0;\n }", "@Override\r\n\tpublic boolean hasAsSquare(Square square) {\r\n\t\treturn squares.containsValue(square);\r\n\t}", "private boolean checkIfGoodSquare(MapLocation location) {\n return (location.x % 2 == location.y % 2) && !location.isAdjacentTo(Cache.myECLocation);\n }", "public boolean check(Square[][] square)\n {\n int count = 0;\n int row = -1;\n boolean ret = false;\n for(int i = 1; i <= 9; i++)\n {\n for(int r = 0; r < square.length; r++)\n {\n if(square[r][colNum].getValue() == i)\n count += 2;\n if(square[r][colNum].isPossible(i))\n {\n count++;\n row = r;\n }\n } \n if(count == 1)\n {\n \tret = true;\n square[row][colNum].setValue(i);\n }\n count = 0;\n }\n return ret;\n }", "public boolean checkValidCoordinate(int i, int j)\n\t{\n\t\tif(i>=0 && i<this.numberOfRows && j>=0 && j<this.numberOfColumns)\n\t\t{\n\t\t\treturn true;\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn false;\n\t\t}\n\t}", "static boolean isPositionAlreadyFilled(int i, int j, String[][] board) {\r\n\t\tboolean isOccupied = false;\r\n\t\tif (board[i][j] == \"*\" || board[i][j] == \"O\") {\r\n\t\t\tSystem.out.println(i + \" \" + j + \"board is \" + board[i][j]\r\n\t\t\t\t\t+ \"The current place is already filled Please choose the other place to fill\");\r\n\t\t\tisOccupied = true;\r\n\t\t}\r\n\t\treturn isOccupied;\r\n\t}", "public boolean pointExists(int row, int column) {\n return (row > 0 && row < rows && column > 0 && column < columns);\n }", "private boolean isLegalCoordinate(int row, int col) {\n return row > 0 && row <= getSize() && col > 0 && col <= getSize();\n }", "public boolean isNull(int x, int y){\r\n\t\tif (_squares[(int)x/20][(int)y/20] == null){\r\n\t\t\treturn true;\r\n\t\t}else{\r\n\t\t\treturn false;\r\n\t\t}\r\n\t}", "private boolean isInsideBoard(int x, int y){\n if(x < 0 || x > getWidth() - 1 || y < 0 || y > getHeight() - 1)\n return false;\n\n return true;\n }", "boolean hasCoordinates();", "boolean hasCoordinates();", "boolean hasCoordinates();", "public static boolean validity(int x, int y, int[][] grid) {\n\t String temp=\"\";\n\t for (int i=0;i<9;i++) {\n\t temp+=Integer.toString(grid[i][y]);//horizontal\n\t temp+=Integer.toString(grid[x][i]);//verical\n\t temp+=Integer.toString(grid[(x/3)*3+i/3][(y/3)*3+i%3]);//square\n\t }\n\t int count=0, idx=0;\n\t while ((idx=temp.indexOf(Integer.toString(grid[x][y]), idx))!=-1)\n\t {idx++; count++;}\n\t return count==3;\n\t }", "private boolean positionExists(int row, int column) {\n\t\treturn row >= 0 && row < rows && column >= 0 && column < columns;\n\t}", "private boolean checkSquare(int i, int j, int n){\n\t\tint xbox = j/3;\n\t\tint ybox = i/3;\n\t\tfor (int k = xbox * 3; k < xbox*3 +3; k++){\n\t\t\tfor(int l = ybox*3; l < ybox*3 + 3; l++){\n\t\t\t\tif(k == j && l == i){\n\t\t\t\t} else if(sudoku[l][k] == n){\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}", "public boolean hasPiece(int row, int col)\n\t{\n\t\t/* make sure our square is in bounds */\n\t\tif (row < 0 || row >= m_rows || col < 0 || col >= m_cols) {\n\t\t\treturn false;\n\t\t}\n\t\t\n\t\t/* empty squares have null in our pieces array */\n\t\treturn (m_pieces[row][col] != null);\n\t}", "public boolean isFull(int x, int y){\r\n\t\tif (_squares[x][y] == null){\r\n\t\t\treturn false;\r\n\t\t}else{\r\n\t\t\treturn true;\r\n\t\t}\r\n\t}", "private boolean hasValidNumber(String[] coord, int numShip) {\n int[] indices = getIndexFromCoord(coord);\n int x0 = indices[0];\n int y0 = indices[1];\n int x1 = indices[2];\n int y1 = indices[3];\n\n if (x0 == x1) {\n // horizontal ships\n if (Math.abs(y0 - y1) + 1 != numShip) {\n System.out.println(\"Error! Wrong length of the Submarine! Try again:\");\n return false;\n }\n return true;\n } else {\n // vertical ships\n if (Math.abs(x0 - x1) + 1 != numShip) {\n System.out.println(\"Error! Wrong length of the Submarine! Try again:\");\n return false;\n }\n return true;\n }\n }", "public boolean isOpen(int row, int col) {\n if (isInBounds(row-1, col-1)) {\n return grid[row-1][col-1];\n }\n else {\n throw new java.lang.IllegalArgumentException(\"Bad Coordinates\");\n }\n }", "private boolean isSafe(int row, int column, int value) throws Exception {\n for (int rowClash = 0; rowClash < DIMENSION; rowClash++) {\n if (this.board.get(row, rowClash) == value) {\n return false;\n }\n }\n\n for (int columnClash = 0; columnClash < DIMENSION; columnClash++) {\n if (this.board.get(columnClash, column) == value) {\n return false;\n }\n }\n\n int boxClash = (int)Math.sqrt(DIMENSION);\n int boxRowStart = row - row % boxClash;\n int boxColumnStart = column - column % boxClash;\n\n for (int rowBox = boxRowStart; rowBox < boxRowStart + boxClash; rowBox++) {\n for (int columnBox = boxColumnStart; columnBox < boxColumnStart + boxClash; columnBox++) {\n if (this.board.get(rowBox, columnBox) == value) {\n return false;\n }\n }\n }\n\n return true;\n }", "private boolean isInsideBoard(int i, int j) {\n return i >= 0 && i < BOARD_WIDTH && j >= 0 && j < BOARD_HEIGHT\n && mapCells[j][i] != 0;\n }", "public boolean isValid() {\n\t\treturn (x >= 0 && x < Board.SIZE && y >= 0 && y < Board.SIZE);\n\t}", "public boolean isSquare() {\n return (getRowDimension() == getColumnDimension());\n }", "boolean isLegalBox (int row, int col, int num) {\n\t\tint x = (row / 3) * 3 ;\n\t\tint y = (col / 3) * 3 ;\n\t\tfor( int r = 0; r < 3; r++ ) {\n\t\t\tfor( int c = 0; c < 3; c++ ) {\n\t\t\t\tif(r != row && c != col) {\n\t\t\t\t\tif( boardArray[y+c][x+r] == num ) {\n\t\t\t\t\t\treturn false;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}", "@Test\r\n public void testIsValidSquare()\r\n {\r\n for(int y = 0; y < 8; y++)\r\n for(int x = 0; x < 8; x++)\r\n assertTrue(board.isValidSqr(x, y));\r\n }", "public boolean isSquareVisited(int row, int col) {\n return playingBoard[row][col].isVisited();\n }", "private boolean check(int i, int j, int n){\n\t\treturn checkRow(i, j, n) && checkColumn(i, j ,n) && checkSquare(i, j, n);\n\t}", "protected boolean validCoord(int row, int col) {\n\t\treturn (row >= 0 && row < b.size() && col >= 0 && col < b.size());\n\t}", "boolean hasHasXCoordinate();", "public boolean containsCoord(Coordinate coordinateToCheck)\n {\n for(Coordinate coord : shipCoordinates)\n if(coord.equals(coordinateToCheck))\n return true;\n\n return false;\n }", "public boolean checkSquareExistsAndIsUnVisted(int testRow, int testCol) {\n if ((testRow >= 0 && testRow < BOARD_SIZE)\n && (testCol >= 0 && testCol < BOARD_SIZE)) {\n if (isSquareVisited(testRow, testCol) == false) {\n return true;\n } else {\n return false;\n }\n } else {\n return false;\n }\n }", "public final boolean checkIfInZone(int x, int y) { return (getSiege(x, y) != null); }", "public boolean isOpen(int row, int col) {\n\t\tif(row < 0 || row >= N || col < 0 || col >= N) \n\t\t\tthrow new IllegalArgumentException();\n\n\t\tint index = xyTo1D(row, col);\n\t\treturn grid[index];\n\t}", "public boolean safeBox(int num, int[][] board, int row, int col) //check if it is safe to place num in given grid\n {\n int boxR = row - row % 3; //1\n int boxC = col - col % 3; //1\n boolean flag = true; //1\n\n for (int r = boxR; r < boxR + 3; r++) //n\n {\n for (int c = boxC; c < boxC + 3; c++) //n\n {\n if (board[r][c] == num) //1\n {\n flag = false; //1\n }\n } \n }\n return flag; //1\n }", "private boolean onBoard(int x, int y){\n if((x<WIDTH&&y<HEIGHT)){\n if(0<=x&&0<=y){\n return true;\n }\n return false;\n }else{\n return false;\n }\n\t}", "private boolean spotTaken(int row, int col, int shipSize, char orientation) {\n boolean spotTaken = false;\n for(int i = 0; i < shipSize; i++) {\n if(this.board[row][col+i] != '*') {\n System.err.println(String.format(\"Error: There is already part of a ship at ship at %d, %d\", row, col+i));\n return true;\n }\n }\n \n return false;\n }", "public boolean hasPiece(Square sqr)\r\n {\r\n return (sqr != null) && hasPiece(sqr.x, sqr.y);\r\n }", "public boolean squareIsEmpty (int row, int col){\n return this.gameBoard[row][col] == 'g';\n }", "private static boolean isCellAlive(int[][] coordinates, int row, int column) {\n\t\tboolean cellAlive = coordinates[row][column] == 1;\r\n\t\tint numberOfNeighbours = 0;\r\n\t\t//check one to the right of col\r\n\t\tif (coordinates[row].length > column + 1) {\r\n\t\t\tif (coordinates[row][column + 1] == 1) {\r\n\t\t\t\tnumberOfNeighbours++;\r\n\t\t\t}\r\n\t\t}\r\n\t\t//check one to the left of col\r\n\t\tif (coordinates[row].length > column - 1 && column - 1 >= 0) {\r\n\t\t\tif (coordinates[row][column - 1] == 1) {\r\n\t\t\t\tnumberOfNeighbours++;\r\n\t\t\t}\r\n\t\t}\r\n\t\t//check one above col\r\n\t\tif (coordinates.length > row - 1 && row - 1 >= 0) {\r\n\t\t\tif (coordinates[row - 1][column] == 1) {\r\n\t\t\t\tnumberOfNeighbours++;\r\n\t\t\t}\r\n\t\t}\r\n\t\t//check one below col\r\n\t\tif (coordinates.length > row + 1) {\r\n\t\t\tif (coordinates[row + 1][column] == 1) {\r\n\t\t\t\tnumberOfNeighbours++;\r\n\t\t\t}\r\n\t\t}\r\n\t\t//check one top left diagonal to col\r\n\t\tif (coordinates.length > row - 1 && coordinates[row].length > column - 1 && row - 1 >= 0 && column - 1 >= 0) {\r\n\t\t\tif (coordinates[row - 1][column - 1] == 1) {\r\n\t\t\t\tnumberOfNeighbours++;\r\n\t\t\t}\r\n\t\t}\r\n\t\t//check one top right diagonal to col\r\n\t\tif (coordinates.length > row - 1 && coordinates[row].length > column + 1 && row - 1 >= 0) {\r\n\t\t\tif (coordinates[row - 1][column + 1] == 1) {\r\n\t\t\t\tnumberOfNeighbours++;\r\n\t\t\t}\r\n\t\t}\r\n\t\t//check one bottom left diagonal to col\r\n\t\tif (coordinates.length > row + 1 && coordinates[row].length > column - 1 && column - 1 >= 0) {\r\n\t\t\tif (coordinates[row + 1][column - 1] == 1) {\r\n\t\t\t\tnumberOfNeighbours++;\r\n\t\t\t}\r\n\t\t}\r\n\t\t//check one bottom right diagonal to col\r\n\t\tif (coordinates.length > row + 1 && coordinates[row].length > column + 1) {\r\n\t\t\tif (coordinates[row + 1][column + 1] == 1) {\r\n\t\t\t\tnumberOfNeighbours++;\r\n\t\t\t}\r\n\t\t}\r\n\t\t System.out.println(\"Number of neighbours for \" + row + \", \" + column\r\n\t\t + \" was \" + numberOfNeighbours);\r\n\t\t//if the number of neighbours was 2 or 3, the cell is alive\r\n\t\tif ((numberOfNeighbours == 2) && cellAlive) {\r\n\t\t\treturn true;\r\n\t\t} else if (numberOfNeighbours == 3) {\r\n\t\t\treturn true;\r\n\t\t}\r\n\t\treturn false;\r\n\t}", "private boolean isOccupied(int col, int row) {\n if (_board[col][row] != EMP) {\n return true;\n }\n return false;\n }", "public static boolean isTakenCell(int row, int col) {\n return (board[row - 1][col - 1] > 0);\n }", "@Override\n public boolean isLocationEmpty(int x, int y)\n {\n return isLocationEmpty(null, x, y);\n }", "public boolean tileOccupied(int x, int y, int pno){\n\t\tfor (int key : playerPosition.keySet()){\n\t\t\tif (key != pno){\n\t\t\t\tint a = playerPosition.get(key)[0];\n\t\t\t\tint b = playerPosition.get(key)[1];\n\t\t\t\tif (a == x && b == y){\n\t\t\t\t\treturn true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}", "private boolean isInSquare(int k, int row, int col) {\n int[][] square = getSquare(row,col);\n return isInSquare(k,square);\n }", "public boolean isSquare()\n {\n return width == height;\n }", "public static boolean occupiedExists(int i, int j) {\r\n\t\treturn (_playerOccupied.contains(new Point(i, j)));\r\n\t}", "public boolean isInside(Square cell) {\n\t\treturn (cell.getRow()>=0 && cell.getRow()<getRows() && cell.getColumn()>=0 && cell.getColumn()<getColumns());\n\t}", "public abstract boolean checkIfCellHasValue(int row, int col);", "public boolean containsSnake(int xcoord, int ycoord) {\n\t\treturn (SnakeArray[xcoord][ycoord] == 1);\n\t}", "static boolean isSafe(int x, int y, int sol[][]) {\n return (x >= 0 && x < N && y >= 0 &&\n y < N && sol[x][y] == -1);\n }", "private boolean isInBox( int row, int col ){\n\t\t\n\t\t/*Go through all the elements in the box including the prosepective\n\t\t * number and return true if any element except the prospective\n\t\t * number is equivalent*/\n\t\tfor( int x = col/3*3; x < (col/3+1)*3; x++)\n\t\t\tfor( int y = row/3*3; y < (row/3+1)*3; y++)\n\t\t\t\t{\n\t\t\t\t\tif( puzzle[row][col] == puzzle[y][x] &&\n\t\t\t\t\t\t(row!=y || col!=x)) \n\t\t\t\t\t{\n\t\t\t\t\t\treturn true;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t//If not found, return false\n\t\treturn false;\n\t}", "private boolean locateSafety(String[] coord) {\n\n int[] indices = getIndexFromCoord(coord);\n int x0 = indices[0];\n int y0 = indices[1];\n int x1 = indices[2];\n int y1 = indices[3];\n\n\n if (x0 == x1) {\n // horizontal\n int northIndex = x0 > 0 ? x0 - 1 : -1;\n int southIndex = x0 < Row.values().length - 1 ? x0 + 1 : -1;\n int leftIndex = y0 > 0 ? y0 - 1 : -1;\n int rightIndex = y1 < fields.length - 1 ? y1 + 1 : -1;\n // check north area\n if (northIndex != -1) {\n for (int i = y0; i <= y1; i++) {\n if (fields[northIndex][i].isShip()) {\n System.out.println(\"Error! You placed it too close to another one. Try again:\");\n return false;\n }\n }\n }\n // check south area\n if (southIndex != -1) {\n for (int i = y0; i <= y1; i++) {\n if (fields[southIndex][i].isShip()) {\n System.out.println(\"Error! You placed it too close to another one. Try again:\");\n return false;\n }\n }\n }\n // check left\n if (leftIndex != -1 && fields[x0][leftIndex].isShip()) {\n System.out.println(\"Error! You placed it too close to another one. Try again:\");\n return false;\n }\n // check right\n if (rightIndex != -1 && fields[x0][rightIndex].isShip()) {\n System.out.println(\"Error! You placed it too close to another one. Try again:\");\n return false;\n }\n\n } else {\n // vertical\n int leftCol = y0 > 0 ? y0 - 1 : -1;\n int rightCol = y0 < fields.length - 1 ? y0 + 1 : -1;\n int northIndex = x0 > 0 ? x0 - 1 : -1;\n int southIndex = x1 < Row.values().length -1 ? x1 + 1 : -1;\n\n // check north\n if (northIndex != -1 && fields[northIndex][y0].isShip()) {\n System.out.println(\"Error! You placed it too close to another one. Try again:\");\n return false;\n }\n // check south\n if (southIndex != -1 && fields[southIndex][y0].isShip()) {\n System.out.println(\"Error! You placed it too close to another one. Try again:\");\n return false;\n }\n // check left\n if (leftCol != -1) {\n for (int i = x0; i <= x1; i++) {\n if (fields[i][leftCol].isShip()) {\n System.out.println(\"Error! You placed it too close to another one. Try again:\");\n return false;\n }\n }\n }\n // check right\n if (rightCol != -1) {\n for (int i = x0; i <= x1; i++) {\n if (fields[i][rightCol].isShip()) {\n System.out.println(\"Error! You placed it too close to another one. Try again:\");\n return false;\n }\n }\n }\n }\n return true;\n }", "public boolean isValid(int row, int col) {\n\t\tif (row < 0 || row >= w || col < 0 || col >= l) return false;\n\t\tif (visited[row][col] != 0) return false;\n\t\treturn true;\n\t}", "private boolean checkTileExists(int x, int y, int zoom) {\n \t int minZoom = 12;\n \t int maxZoom = 16;\n\n \t if ((zoom < minZoom || zoom > maxZoom)) {\n \t return false;\n \t }\n\n \t return true;\n \t }", "public boolean cellExists(char col, int row){\n return searchSheet(col, row) != null ? true : false;\n }", "public boolean isValid(int x, int y)\n\t{\n\t\treturn (x < rowLen && y < columnLen && x >= 0 && y >= 0);\n\t}", "public boolean isOpen(int row, int col) {\n if(!inRange(row, col)) {\n throw new IllegalArgumentException();\n }\n return grid[row][col];\n }", "private static boolean isBoxValid(int[][] sudoku, int row, int col, int num) {\n int rowStart = row - row % 2;\n int colStart = col - col % 2;\n for (int i = rowStart; i < rowStart + 2; i++) {\n for (int j = colStart; j < colStart + 2; j++) {\n if (sudoku[i][j] == num) {\n return false;\n }\n }\n }\n return true;\n }", "public boolean areValidCoordinates(int x, int y) {\n return (x >= 0 && x < WIDTH && y >= 0 && y < HEIGHT);\n }", "public static boolean isWrongUserSquare()\n {\n boolean isWrong = false;\n int aux = 0;\n \n for (int i = 0; i < BOARD_WIDTH / 2; i++)\n {\n for (int j = 0; j < BOARD_HEIGHT / 2; j++)\n {\n aux = aux + playerBoardPos[i][j];\n }\n }\n \n if (!(aux == 10)) // Si el aux no tiene un 10 significa que hay un numero repetido.\n {\n isWrong = true;\n }\n \n return isWrong;\n }", "private void ensureLocationPointFound(Integer row, Integer column) {\n\n\t\tif (row == null || column == null || row <= 0 || column <= 0) {\n\n\t\t\tthrow new SomethingWentWrongException(\"Wrong Location Point\");\n\t\t}\n\t}", "private static boolean isSafe(int[][] board, int row, int column)\n\t{\n\t\tfor (int i = 0; i < column; i++)\n\t\t{\n\t\t\tif (board[row][i] == 1)\n\t\t\t\treturn false;\n\t\t}\n\n\t\t//check upper diagonal entries\n\t\tfor (int i = row, j = column; i >= 0 && j >= 0; i--, j--)\n\t\t{\n\t\t\tif (board[i][j] == 1)\n\t\t\t\treturn false;\n\t\t}\n\n\t\t//check lower diagonal entries\n\t\tfor (int i = row, j = column; i < numberOfQueens && j >= 0 ; i++, j--)\n\t\t{\n\t\t\tif (board[i][j] == 1)\n\t\t\t\treturn false;\n\t\t}\n\t\treturn true;\n\t}", "static boolean canPlace(int row, int col, char[][] piece) {\n for (int r = 0; r < piece.length; r++) {\n for (int c = 0; c < piece[r].length; c++) {\n if (piece[r][c] != '0') {\n if (row + r >= 0 && row + r < board.length && col + c >= 0 && col + c < board[row].length) {\n if (board[row + r][col + c] != '0') {\n return false;\n }\n } else {\n return false;\n }\n }\n }\n }\n\n return true;\n }", "private static boolean canBePlacedOrNot(int[][] sudoku, int row, int col, int num) {\n if (isRowValid(sudoku, row, num)) {\n return true;\n }\n\n if (isColVaild(sudoku, col, num)) {\n return true;\n }\n\n if (isBoxValid(sudoku, row, col, num)) {\n return true;\n }\n return false;\n }", "public boolean isPositionValid(int row, int col, int value){\n return !isInRow(row, value) && !isInCol(col, value) && !isInBox(row, col, value);\n }", "private static boolean isPossibleGrid(int[][] board, int row, int col, int value) {\r\n\t\tint srow = row - row % 3;\r\n\t\tint scol = col - col % 3;\r\n\t\tfor (int i = srow; i < srow + 3; i++) {\r\n\t\t\tfor (int j = scol; j < scol + 3; j++) {\r\n\t\t\t\tif (board[i][j] == value)\r\n\t\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn true;\r\n\t}", "boolean hasCoordInfo();", "@Override\n public boolean isLocationValid(int x, int y)\n {\n return master.isLocationValid(x, y);\n }", "public boolean hasShip(int row, int column) {\n\t\treturn this.grid[row][column].hasShip();\n\t}", "public boolean isMoveLegal(int x, int y) {\n\t\tif (rowSize <= x || colSize <= y || x < 0 || y < 0) {\r\n\t\t\t// System.out.print(\"Position (\" + (x + 1) + \", \" + (y + 1) + \") is\r\n\t\t\t// out of range!\\n\");\r\n\t\t\treturn false;\r\n\t\t} else if (!(matrix[x][y] == 0)) {\r\n\t\t\t// System.out.print(\"Position (\" + (x + 1) + \", \" + (y + 1) + \") has\r\n\t\t\t// been occupied!\\n\");\r\n\t\t\treturn false;\r\n\t\t} else\r\n\t\t\treturn true;\r\n\t}", "@Override\n\tpublic boolean check(piece[][] board) {\n\t\t\n\t\treturn false;\n\t\t\n\t}", "public boolean isOpen(int row, int col) {\n if (row - 1 >= grid.length || col - 1 >= grid.length || row - 1 < 0 || col - 1 < 0) {\n throw new IllegalArgumentException(\"index is out of boundary.\");\n }\n return grid[row - 1][col - 1];\n }", "private boolean isCorner(int x, int y)\n {\n return x-1 >= 0 && x+1 < LoadMap.MAPWIDTHINTILES && y-1 >= 0 && y+1 < LoadMap.MAPHEIGHTINTILES && (\n (connectedTiles[y][x+1] != null && (connectedTiles[y+1][x] != null || connectedTiles[y-1][x] != null))\n || (connectedTiles[y][x-1] != null && (connectedTiles[y+1][x] != null || connectedTiles[y-1][x] != null)));\n }", "boolean isSafe(int grid[][], int row, int col, int num)\n{\n /* Check if 'num' is not already placed in current row,\n current column and current 3x3 box */\n return !UsedInRow(grid, row, num) &&\n !UsedInCol(grid, col, num) &&\n !UsedInBox(grid, row - row%3 , col - col%3, num);\n}", "protected boolean hasSpace(int[][] gameboard, int col, int row){\r\n\t\tint count = 0;\r\n\t\tint i = col;\r\n\t\tboolean valid = false;\r\n\t\t\r\n\t\tif (col + size < 10) {\r\n\t\t\tfor(int j = 0; j < size; j++){\r\n\t\t\t\tif(gameboard[i][row] == -1){\r\n\t\t\t\t\ti++;\r\n\t\t\t\t\tcount++;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tif(count == size){\r\n\t\t\t\tvalid = true;\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\treturn valid;\r\n\t}", "private boolean valid (int row, int column) {\n\n boolean result = false;\n \n // check if cell is in the bounds of the matrix\n if (row >= 0 && row < grid.length &&\n column >= 0 && column < grid[0].length)\n\n // check if cell is not blocked and not previously tried\n if (grid[row][column] == 1)\n result = true;\n\n return result;\n\n }", "public boolean isOpen(int row, int col)\n {\n int oneDimensional = xyTo1D(row, col);\n return grid[oneDimensional];\n }", "protected boolean isOccupied(int row, int column){\n return (!ships[row][column].getShipType().equals(\"empty\"));\n }", "boolean isCellAlive(int x, int y);", "public boolean isOpen(int row, int col) {\n if (row < 0 || row > n - 1 || col < 0 || col > n - 1) throw new java.lang.IndexOutOfBoundsException(\"isOpen():row or col out of bounds\");\n return grid[row][col];\n }", "public boolean isFreeCoordinate(int x, int y)\n {\n boolean isFree = false;\n if(this.grille[x][y] == \"0\")\n {\n isFree = true;\n // System.out.println(\"case libre : [\" + x + \" \" + y + \"] \" +this.grille[x][y]);\n }\n else{\n // System.out.println(\"case occupee [\"+ x + \" \" + y + \" ] \" +this.grille[x][y]);\n\n }\n return isFree;\n }", "public boolean inGrid(int y, int x) {\n\n if (y > 0 && x > 0 && y < height - 1 && x < width - 1) {\n return true;\n }\n\n return false;\n }", "private boolean findChess(int x,int y){\r\n for(Point c:chessList){\r\n if(c!=null&&c.getX()==x&&c.getY()==y)\r\n return true;\r\n }\r\n return false;\r\n }", "public boolean isOpen(int row, int col)\r\n {\r\n if (row < 1 || row > dimension || col < 1 || col > dimension)\r\n throw new IllegalArgumentException(\"error range\");\r\n\r\n return grids[(row - 1) * dimension + col];\r\n }", "static boolean isValid(int row, int col)\n{\n\t// return true if row number and\n\t// column number is in range\n\treturn (row >= 0) && (row < ROW) &&\n\t\t(col >= 0) && (col < COL);\n}", "public boolean validateMove(int x, int y)\n {\n try {\n return (board[x][y] == EMPTY_FLAG);\n } catch (ArrayIndexOutOfBoundsException e) {\n return false;\n }\n }", "private boolean isInSquare(int k, int[][] square) {\n for (int r = 0; r < square.length; r++) {\n for (int c = 0; c < square[r].length; c++) {\n if (square[r][c] == k) return true;\n }\n }\n return false;\n }", "public boolean checkRep() {\n return location.x() >= 0 && location.x() < board.getWidth() && \n location.y() >= 0 && location.y() < board.getHeight(); \n }", "public boolean contains(int row, int col) {\n\t\treturn myGrid.contains(row, col);\n\t}", "public abstract boolean containsPoint(int x, int y);", "private static boolean isSafe(int[][] board, int row, int col) {\n\t\tfor(int i=0;i<=row;i++) {\n\t\t\tif(board[i][col]==1) {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\t// case for upper left diagonal\n\t\tfor(int i=row,j=col;i>=0 && j>=0;i--,j--) {\n\t\t\tif(board[i][j]==1)\n\t\t\t\treturn false;\n\t\t\t\n\t\t}\n\t\t// case for upper right diagonal\n\t\tfor(int i=row,j=col;i>=0 && j<N;i--,j++) {\n\t\t\tif(board[i][j]==1)\n\t\t\t\treturn false;\n\t\t}\n\t\treturn true;\n\t}", "private boolean isOccupied(Location loc)\n\t{\n\t\treturn grid[loc.getRow()][loc.getCol()] != null;\n\t}", "public boolean isOpen(int row, int col) {\n\t\tif (row < 1 || row > size || col < 1 || col > size) {\n\t\t\tthrow new IllegalArgumentException();\n\t\t}\n\t\treturn grid[row - 1][col - 1];\n\t}", "public int getSquareNumber(int x, int y){\n return board[x][y].getNumber();\n }", "private static boolean squaresIsInvalid(int i, int j, int[][] grid) {\n\t\tint iEnd = i + 3;\n\t\tint jEnd = j + 3;\n\t\t\n\t\tList<Integer> square = new ArrayList<>();\n\t\twhile(j < jEnd) {\n\t\t\twhile(i < iEnd) {\n\t\t\t\tsquare.add(grid[i][j]);\n\t\t\t\ti++;\n\t\t\t}\n\t\t\ti-=3;\n\t\t\tj++;\n\t\t}\n\t\tif(collectionHasRepeat(square)) return true;\n\t\treturn false;\n\t}" ]
[ "0.76687133", "0.7323406", "0.694424", "0.6895634", "0.6890149", "0.68246365", "0.68187803", "0.67938113", "0.6785059", "0.6699248", "0.66821796", "0.6667527", "0.6664338", "0.6643035", "0.6636387", "0.66271925", "0.66271925", "0.66271925", "0.6614372", "0.6602005", "0.6587062", "0.6558434", "0.65179247", "0.6492216", "0.6486179", "0.6485955", "0.6473202", "0.64696085", "0.6439899", "0.6406741", "0.6394855", "0.636738", "0.6358285", "0.63559496", "0.63548446", "0.6337718", "0.63361037", "0.6332036", "0.6330939", "0.6313039", "0.63063955", "0.62985533", "0.62891364", "0.6275432", "0.627083", "0.6266906", "0.62628293", "0.6261142", "0.6258706", "0.62360036", "0.6222183", "0.62183785", "0.62151694", "0.62138945", "0.62125516", "0.6205021", "0.61938256", "0.61897486", "0.6187821", "0.6168147", "0.6166885", "0.61649173", "0.6164037", "0.6157712", "0.61523384", "0.6150566", "0.6148801", "0.61478287", "0.6147787", "0.61460394", "0.61347234", "0.6129099", "0.61256266", "0.61168563", "0.6109055", "0.61065745", "0.6106449", "0.6104652", "0.61018455", "0.6084271", "0.6079052", "0.60716647", "0.6070278", "0.6061927", "0.604098", "0.6038765", "0.6035771", "0.6031098", "0.6030918", "0.60292894", "0.6028203", "0.60267603", "0.6017831", "0.60165185", "0.6010045", "0.60073847", "0.60063523", "0.6001642", "0.5999319", "0.5999295", "0.59964865" ]
0.0
-1
Checks if the index exists on the square dimensional board.
private boolean isValid(int index) { return index >= 0 && index < dimension; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public boolean check(Square[][] square)\n {\n int count = 0;\n int row = -1;\n boolean ret = false;\n for(int i = 1; i <= 9; i++)\n {\n for(int r = 0; r < square.length; r++)\n {\n if(square[r][colNum].getValue() == i)\n count += 2;\n if(square[r][colNum].isPossible(i))\n {\n count++;\n row = r;\n }\n } \n if(count == 1)\n {\n \tret = true;\n square[row][colNum].setValue(i);\n }\n count = 0;\n }\n return ret;\n }", "private boolean isValidIndex(final int theY, final int theX) {\n return 0 <= theY && theY < myGrid.length\n && 0 <= theX && theX < myGrid[theY].length;\n }", "public boolean isOpenSquare(int x, int y)\r\n {\r\n return isValidSqr(x, y) && board[x][y] == null;\r\n }", "private boolean isIndexExist(int index) {\n return index >= 0 && index < size();\n }", "public boolean valid(int x, int y) {\n return board[x][y] == 0;\n }", "private static boolean isFilled(int[][] sudoku) {\r\n for (int i = 0; i < 16; i++) {\r\n for (int j = 0; j < 16; j++) {\r\n if (sudoku[i][j] == -1) {\r\n return false;\r\n }\r\n }\r\n }\r\n return true;\r\n }", "private boolean checkSquare(int i, int j, int n){\n\t\tint xbox = j/3;\n\t\tint ybox = i/3;\n\t\tfor (int k = xbox * 3; k < xbox*3 +3; k++){\n\t\t\tfor(int l = ybox*3; l < ybox*3 + 3; l++){\n\t\t\t\tif(k == j && l == i){\n\t\t\t\t} else if(sudoku[l][k] == n){\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}", "private boolean positionExists(int row, int column) {\n\t\treturn row >= 0 && row < rows && column >= 0 && column < columns;\n\t}", "@Test\n\tpublic void testGettingIndexEmptySquare()\n\t{\n\t\t// arrange\n\t\tData d = new Data();\n\t\n\t\t// act\n\t\tint index = d.getIndex(1);\t // shouldn't be in the array, as it is an empty square\n\n\t\t// assert\n\t\tassertEquals(index, -1); //-1 means not found\n\t}", "boolean hasIndex();", "boolean hasIndex();", "boolean hasIndex();", "boolean hasIndex();", "boolean hasIndex();", "boolean hasIndex();", "public boolean isOpen(int row, int col) {\n if ((row > (size-1)) || (col > (size-1)) || (col < 0) || (row < 0)) {\r\n throw new java.lang.IndexOutOfBoundsException();\r\n }\r\n else if (grid[row][col] > 0) {\r\n return true;\r\n } else return false;\r\n }", "public boolean isOpen(int row, int col) {\n if (row - 1 >= grid.length || col - 1 >= grid.length || row - 1 < 0 || col - 1 < 0) {\n throw new IllegalArgumentException(\"index is out of boundary.\");\n }\n return grid[row - 1][col - 1];\n }", "boolean isPaintedSquare(int row, int col) {\n return grid[row][col];\n }", "private boolean isInSquare(int k, int row, int col) {\n int[][] square = getSquare(row,col);\n return isInSquare(k,square);\n }", "public boolean checkSudokuWin(){\n\t\tCharacter c;\n\t\tfor(int i=0;i<81;i++){\n\t\t\tc=sudokuDisplay[i/9][i%9];\n\t\t\tif(!checkBlockValidSudoku(i,c))\n\t\t\t\treturn false;\n\t\t}\n\t\treturn true;\n\t}", "private boolean isInsideBoard(int i, int j) {\n return i >= 0 && i < BOARD_WIDTH && j >= 0 && j < BOARD_HEIGHT\n && mapCells[j][i] != 0;\n }", "public static boolean validity(int x, int y, int[][] grid) {\n\t String temp=\"\";\n\t for (int i=0;i<9;i++) {\n\t temp+=Integer.toString(grid[i][y]);//horizontal\n\t temp+=Integer.toString(grid[x][i]);//verical\n\t temp+=Integer.toString(grid[(x/3)*3+i/3][(y/3)*3+i%3]);//square\n\t }\n\t int count=0, idx=0;\n\t while ((idx=temp.indexOf(Integer.toString(grid[x][y]), idx))!=-1)\n\t {idx++; count++;}\n\t return count==3;\n\t }", "public boolean isOpen(int row, int col) {\n\t\tif(row < 0 || row >= N || col < 0 || col >= N) \n\t\t\tthrow new IllegalArgumentException();\n\n\t\tint index = xyTo1D(row, col);\n\t\treturn grid[index];\n\t}", "private boolean isInSquare(int k, int[][] square) {\n for (int r = 0; r < square.length; r++) {\n for (int c = 0; c < square[r].length; c++) {\n if (square[r][c] == k) return true;\n }\n }\n return false;\n }", "public boolean isFull(int row, int col) {\n if (row - 1 >= grid.length || col - 1 >= grid.length || row - 1 < 0 || col - 1 < 0) {\n throw new IllegalArgumentException(\"index is out of boundary.\");\n }\n if (grid.length == 1) {\n return isOpen(row, col);\n }\n return uf.find(ufindex(row, col)) == uf.find(grid.length * grid.length) && isOpen(row, col);\n }", "public boolean IsSafe(int rowIndex, int columIndex) {\n for (int i = 0; i < this.SIZE_OF_CHESS_BOARD; i++) {\n //this.list_cells[rowIndex][i].setBackground(Color.red);\n if (maps[rowIndex][i] == true) {\n return false;\n }\n }\n\n //check in a colums\n for (int i = 0; i < this.SIZE_OF_CHESS_BOARD; i++) {\n //this.list_cells[i][columIndex].setBackground(Color.red);\n if (maps[i][columIndex] == true) {\n return false;\n }\n }\n\n //check in a diagonal line\n for (int x = -(this.SIZE_OF_CHESS_BOARD - 1); x < this.SIZE_OF_CHESS_BOARD; x++) {\n for (int y = -(this.SIZE_OF_CHESS_BOARD - 1); y < this.SIZE_OF_CHESS_BOARD; y++) {\n int newRowIndex = x + rowIndex;\n int newColumIndex = y + columIndex;\n if (newColumIndex >= 0 && newColumIndex < this.SIZE_OF_CHESS_BOARD && newRowIndex >= 0 && newRowIndex < this.SIZE_OF_CHESS_BOARD) {\n if (newColumIndex + newRowIndex == columIndex + rowIndex || columIndex - rowIndex == newColumIndex - newRowIndex) {\n // System.out.println(newRowIndex + \",\" + newColumIndex);\n if (maps[newRowIndex][newColumIndex] == true) {\n return false;\n }\n //this.list_cells[newRowIndex][newColumIndex].setBackground(Color.red);\n }\n }\n }\n }\n return true;\n }", "public boolean isFull(int row, int col) {\n if (!isValidSite(row, col)) {\n throw new IllegalArgumentException(\"Illegal indices [\" + row + \"][\" + col + \"]\");\n }\n return this.quf.find((this.n * this.n) + 1) == this.quf.find(this.getSite(row, col));\n }", "public static boolean validIndex(int row,int col,int i,int j){\n\t\tif(i<0 || j<0 || i>=row || j >= col){\n\t\t\treturn false;\n\t\t}\n\t\treturn true;\n\t\t\n\t}", "public boolean coordOnBoard(int row, int col, ArrayList<ArrayList<GamePiece>> board) {\n return (0 <= row && row < board.size()) && (0 <= col && col < board.get(0).size());\n }", "static boolean isSafe(int x, int y, int sol[][]) {\n return (x >= 0 && x < N && y >= 0 &&\n y < N && sol[x][y] == -1);\n }", "private boolean check(int i, int j, int n){\n\t\treturn checkRow(i, j, n) && checkColumn(i, j ,n) && checkSquare(i, j, n);\n\t}", "boolean UsedInCol(int grid[][], int col, int num)\n{\n for (int row = 0; row < N; row++)\n if (grid[row][col] == num)\n return true;\n return false;\n}", "public boolean isOpen(int row, int col) {\n if (row < 0 || row > n - 1 || col < 0 || col > n - 1) throw new java.lang.IndexOutOfBoundsException(\"isOpen():row or col out of bounds\");\n return grid[row][col];\n }", "private boolean subGridCheck() {\n\t\tint sqRt = (int)Math.sqrt(dimension);\n\t\tfor(int i = 0; i < sqRt; i++) {\n\t\t\tint increment = i * sqRt;\n\t\t\tfor(int val = 1; val <= dimension; val++) {\n\t\t\t\tint valCounter = 0;\n\t\t\t\tfor(int row = 0 + increment; row < sqRt + increment; row++) {\n\t\t\t\t\tfor(int col = 0 + increment; col < sqRt + increment; col++) {\n\t\t\t\t\t\tif(puzzle[row][col] == val)\n\t\t\t\t\t\t\tvalCounter++;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif(valCounter >= 2)\n\t\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}", "static boolean isPositionAlreadyFilled(int i, int j, String[][] board) {\r\n\t\tboolean isOccupied = false;\r\n\t\tif (board[i][j] == \"*\" || board[i][j] == \"O\") {\r\n\t\t\tSystem.out.println(i + \" \" + j + \"board is \" + board[i][j]\r\n\t\t\t\t\t+ \"The current place is already filled Please choose the other place to fill\");\r\n\t\t\tisOccupied = true;\r\n\t\t}\r\n\t\treturn isOccupied;\r\n\t}", "public boolean checkSquareExistsAndIsUnVisted(int testRow, int testCol) {\n if ((testRow >= 0 && testRow < BOARD_SIZE)\n && (testCol >= 0 && testCol < BOARD_SIZE)) {\n if (isSquareVisited(testRow, testCol) == false) {\n return true;\n } else {\n return false;\n }\n } else {\n return false;\n }\n }", "private boolean check(int i, int j, int arr[][]) {\n\t\tfor (int k = 0; k < BOARD_SIZE; k++) {\n\t\t\tif ((k != j && arr[i][k] == arr[i][j]) || (k != i && arr[k][j] == arr[i][j])) {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\tint i0 = i / LEVEL * LEVEL, j0 = j / LEVEL * LEVEL;\n\t\tfor (int k = 0; k < LEVEL; k++) {\n\t\t\tfor (int l = 0; l < LEVEL; l++) {\n\t\t\t\tif ((i0 + k != i || j0 + l != j) && arr[i0 + k][j0 + l] == arr[i][j]) {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}", "private static boolean isSafe(int[][] board, int row, int column)\n\t{\n\t\tfor (int i = 0; i < column; i++)\n\t\t{\n\t\t\tif (board[row][i] == 1)\n\t\t\t\treturn false;\n\t\t}\n\n\t\t//check upper diagonal entries\n\t\tfor (int i = row, j = column; i >= 0 && j >= 0; i--, j--)\n\t\t{\n\t\t\tif (board[i][j] == 1)\n\t\t\t\treturn false;\n\t\t}\n\n\t\t//check lower diagonal entries\n\t\tfor (int i = row, j = column; i < numberOfQueens && j >= 0 ; i++, j--)\n\t\t{\n\t\t\tif (board[i][j] == 1)\n\t\t\t\treturn false;\n\t\t}\n\t\treturn true;\n\t}", "public boolean isOpen(int i, int j) throws IndexOutOfBoundsException {\r\n\t\tif (i > N || i < 1)\r\n\t\t\tthrow new IndexOutOfBoundsException(\"row index i out of bounds\");\r\n\t\tif (j > N || j < 1)\r\n\t\t\tthrow new IndexOutOfBoundsException(\"column index j out of bounds\");\r\n\t\treturn grid[i - 1][j - 1];\r\n\t}", "public boolean isOpen(int row, int col) {\n if(!inRange(row, col)) {\n throw new IllegalArgumentException();\n }\n return grid[row][col];\n }", "private boolean isSafe(int row, int column, int value) throws Exception {\n for (int rowClash = 0; rowClash < DIMENSION; rowClash++) {\n if (this.board.get(row, rowClash) == value) {\n return false;\n }\n }\n\n for (int columnClash = 0; columnClash < DIMENSION; columnClash++) {\n if (this.board.get(columnClash, column) == value) {\n return false;\n }\n }\n\n int boxClash = (int)Math.sqrt(DIMENSION);\n int boxRowStart = row - row % boxClash;\n int boxColumnStart = column - column % boxClash;\n\n for (int rowBox = boxRowStart; rowBox < boxRowStart + boxClash; rowBox++) {\n for (int columnBox = boxColumnStart; columnBox < boxColumnStart + boxClash; columnBox++) {\n if (this.board.get(rowBox, columnBox) == value) {\n return false;\n }\n }\n }\n\n return true;\n }", "private boolean hasRoom(int index) {\r\n\t\t\tfor (int i = index; i < data.length; i++) {\r\n\t\t\t\tif (data[i] == null)\r\n\t\t\t\t\treturn true;\r\n\t\t\t}\r\n\t\t\treturn false;\r\n\t\t}", "public boolean isFull(int row, int col) {\n if ((row > (size-1)) || (col > (size-1)) || (col < 0) || (row < 0)) {\r\n throw new java.lang.IndexOutOfBoundsException();\r\n }\r\n else if (grid[row][col] == 2) {\r\n return true;\r\n } else return false;\r\n }", "boolean isSafe(int grid[][], int row, int col, int num)\n{\n /* Check if 'num' is not already placed in current row,\n current column and current 3x3 box */\n return !UsedInRow(grid, row, num) &&\n !UsedInCol(grid, col, num) &&\n !UsedInBox(grid, row - row%3 , col - col%3, num);\n}", "public boolean hasPiece(int x, int y)\r\n {\r\n return isValidSqr(x, y) && board[x][y] != null;\r\n }", "private static boolean squaresIsInvalid(int i, int j, int[][] grid) {\n\t\tint iEnd = i + 3;\n\t\tint jEnd = j + 3;\n\t\t\n\t\tList<Integer> square = new ArrayList<>();\n\t\twhile(j < jEnd) {\n\t\t\twhile(i < iEnd) {\n\t\t\t\tsquare.add(grid[i][j]);\n\t\t\t\ti++;\n\t\t\t}\n\t\t\ti-=3;\n\t\t\tj++;\n\t\t}\n\t\tif(collectionHasRepeat(square)) return true;\n\t\treturn false;\n\t}", "public boolean indexCheck(int index) {\n return (index >= 0 && index <= size) ? true : false;\n }", "private boolean checkRow(int i, int j, int n){\n\t\tfor(int k = 0; k < 9; k++){\n\t\t\tif(k == j){\n\t\t\t}else if(sudoku[i][k] == n){\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}", "public boolean isOpen(int row, int col)\r\n {\r\n if (row < 1 || row > dimension || col < 1 || col > dimension)\r\n throw new IllegalArgumentException(\"error range\");\r\n\r\n return grids[(row - 1) * dimension + col];\r\n }", "private boolean colCheck(int col, int n)\r\n {\r\n for(int r = 0; r < game.length; r++)\r\n if(game[r][col] == n)\r\n return false;\r\n return true;\r\n }", "private static boolean isSafe(int[][] board, int row, int col) {\n\t\tfor(int i=0;i<=row;i++) {\n\t\t\tif(board[i][col]==1) {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\t// case for upper left diagonal\n\t\tfor(int i=row,j=col;i>=0 && j>=0;i--,j--) {\n\t\t\tif(board[i][j]==1)\n\t\t\t\treturn false;\n\t\t\t\n\t\t}\n\t\t// case for upper right diagonal\n\t\tfor(int i=row,j=col;i>=0 && j<N;i--,j++) {\n\t\t\tif(board[i][j]==1)\n\t\t\t\treturn false;\n\t\t}\n\t\treturn true;\n\t}", "protected boolean hasSpace(int[][] gameboard, int col, int row){\r\n\t\tint count = 0;\r\n\t\tint i = col;\r\n\t\tboolean valid = false;\r\n\t\t\r\n\t\tif (col + size < 10) {\r\n\t\t\tfor(int j = 0; j < size; j++){\r\n\t\t\t\tif(gameboard[i][row] == -1){\r\n\t\t\t\t\ti++;\r\n\t\t\t\t\tcount++;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tif(count == size){\r\n\t\t\t\tvalid = true;\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\treturn valid;\r\n\t}", "private boolean checkRowColWin(char symbol) {\n boolean cols, rows;\n\n for (int col = 0; col < SIZE; col++) {\n cols = true;\n rows = true;\n\n for (int row = 0; row < SIZE; row++) {\n cols &= (gameField[col][row] == symbol);\n rows &= (gameField[row][col] == symbol);\n }\n if (cols || rows) {\n return true;\n }\n }\n return false;\n }", "public boolean isValid() {\n if (state.length != Board.dim*Board.dim) return false;\n if ((double)Board.dim != Math.sqrt((double)state.length)) return false;\n byte[] counts = new byte[state.length];\n try {\n for (int i = 0; i < counts.length; i++) counts[state[i]]++;\n } catch (ArrayIndexOutOfBoundsException e) { return false; }\n for (int i = 0; i < counts.length; i++) if (counts[i] != 1) return false;\n return true;\n }", "@Override\n\tpublic boolean isValidIndex(long index) {\n\t\ttry {\n\t\t\tif (isEmtpy || Long.compareUnsigned(index, maxOffset) > 0) {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t\treturn memory.contains(getAddress(index));\n\t\t}\n\t\tcatch (IOException | AddressOutOfBoundsException e) {\n\t\t\treturn false;\n\t\t}\n\t}", "public boolean isXsolution() {\n\t\tfor (int k=1; k<size*size; k++) {\n\t\t\tint count1 = 0;\n\t\t\tint count2 = 0;\n\t\t\tfor (int l=0; l<size*size; l++) {\n\t\t\t\tif (board[l][l]==k) count1++;\n\t\t\t\tif (board[l][size*size-l-1]==k) count2++;\n\t\t\t}\n\t\t\tif (count1!=1 || count2!=1) return false;\n\t\t}\n\t\treturn true;\n\t}", "public boolean isOpen(int row, int col)\n {\n int oneDimensional = xyTo1D(row, col);\n return grid[oneDimensional];\n }", "@Override\n public boolean isInBounds(int row, int col) {\n return row >= 0 && row < grid.length && col >= 0 && col < grid[0].length;\n }", "private boolean columnCheck() {\n\t\tfor(int col = 0; col < puzzle[0].length; col++) {\n\t\t\tfor(int i = 0; i < puzzle[0].length; i++) {\n\t\t\t\tif(puzzle[i][col] != 0) {\n\t\t\t\t\tfor(int j = i + 1; j < puzzle[0].length; j++) {\n\t\t\t\t\t\tif(puzzle[i][col] == puzzle[j][col])\n\t\t\t\t\t\t\treturn false;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}", "private boolean checkColumn(int i, int j, int n){\n\t\tfor(int k = 0; k < 9; k++){\n\t\t\tif(k == i){\n\t\t\t}else if(sudoku[k][j] == n){\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}", "private static boolean isPossibleGrid(int[][] board, int row, int col, int value) {\r\n\t\tint srow = row - row % 3;\r\n\t\tint scol = col - col % 3;\r\n\t\tfor (int i = srow; i < srow + 3; i++) {\r\n\t\t\tfor (int j = scol; j < scol + 3; j++) {\r\n\t\t\t\tif (board[i][j] == value)\r\n\t\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn true;\r\n\t}", "boolean UsedInRow(int grid[][], int row, int num)\n{\n for (int col = 0; col < N; col++)\n if (grid[row][col] == num)\n return true;\n return false;\n}", "private boolean checkSolveSudoku() {\n\n // Check Rows\n for (int i = 0; i < rows.size(); i++) {\n ArrayList<Cell> row = rows.get(i);\n int[] temp = new int[getSize()];\n\n for (int j = 0; j < row.size(); j++) {\n if (row.get(j).getNumber() == -1)\n return false;\n temp[row.get(j).getNumber() - 1]++;\n }\n\n for (int j : temp)\n if (j == 0)\n return false;\n }\n\n // Check Columns\n for (int i = 0; i < columns.size(); i++) {\n ArrayList<Cell> column = columns.get(i);\n int[] temp = new int[getSize()];\n\n for (int j = 0; j < column.size(); j++)\n temp[column.get(j).getNumber() - 1]++;\n\n for (int j : temp)\n if (j == 0)\n return false;\n }\n\n // Check Boxes\n for (int i = 0; i < boxes.size(); i++) {\n ArrayList<Cell> box = rows.get(i);\n int[] temp = new int[getSize()];\n\n for (int j = 0; j < box.size(); j++)\n temp[box.get(j).getNumber() - 1]++;\n\n for (int j : temp)\n if (j == 0)\n return false;\n }\n\n return true;\n }", "public boolean safeBox(int num, int[][] board, int row, int col) //check if it is safe to place num in given grid\n {\n int boxR = row - row % 3; //1\n int boxC = col - col % 3; //1\n boolean flag = true; //1\n\n for (int r = boxR; r < boxR + 3; r++) //n\n {\n for (int c = boxC; c < boxC + 3; c++) //n\n {\n if (board[r][c] == num) //1\n {\n flag = false; //1\n }\n } \n }\n return flag; //1\n }", "private static boolean isBoxValid(int[][] sudoku, int row, int col, int num) {\n int rowStart = row - row % 2;\n int colStart = col - col % 2;\n for (int i = rowStart; i < rowStart + 2; i++) {\n for (int j = colStart; j < colStart + 2; j++) {\n if (sudoku[i][j] == num) {\n return false;\n }\n }\n }\n return true;\n }", "public void checkNeighbours(int row, int column)\r\n {\r\n int counter = 0;\r\n //*************************************************\r\n //Following code was adapted from Harry Tang 2015-04-27\r\n for (int columnNeighbours = column - 1; columnNeighbours <= column + 1; columnNeighbours ++)\r\n {\r\n for (int rowNeighbours = row - 1; rowNeighbours <= row + 1; rowNeighbours ++)\r\n {\r\n try \r\n {\r\n if (cellGrid[columnNeighbours][rowNeighbours].isAlive()\r\n && cellGrid[columnNeighbours][rowNeighbours] != cellGrid[column][row])\r\n {\r\n counter ++;\r\n }\r\n }\r\n catch (IndexOutOfBoundsException e)\r\n {\r\n // do nothing\r\n }\r\n } // end of for (int y = indexY - 1; y == indexY; y++)\r\n } // end of for (int x = indexX - 1; x == indexX; x++)\r\n //*************************************************\r\n \r\n decisionOnCellState(counter, row, column);\r\n }", "public boolean isOpen(int i, int j){\n\t\t\n\t\tif (i <= 0 || i > N) throw new java.lang.IndexOutOfBoundsException(\"row index i out of bounds\");\n\t\tif (j <= 0 || j > N) throw new java.lang.IndexOutOfBoundsException(\"row index j out of bounds\");\n\t\t\t\t\n\t\treturn !idGrid[i-1][j-1];\n\t}", "private boolean tileIsInbounds(int row, int col){\n\t\treturn row >= 0 && col >= 0\n\t\t\t\t&& row < board.length && col < board[0].length;\n\t}", "public boolean isOpen(int i, int j){\n \tif(i<=0 || i>this.gridLength || j<=0 || j>this.gridLength){\n\t\t\tthrow new IndexOutOfBoundsException();\n\t\t}\n \treturn this.idGrid[(i-1)*this.gridLength + j] == true;\n }", "@Override\r\n\tpublic boolean hasAsSquare(Square square) {\r\n\t\treturn squares.containsValue(square);\r\n\t}", "boolean isLegalBox (int row, int col, int num) {\n\t\tint x = (row / 3) * 3 ;\n\t\tint y = (col / 3) * 3 ;\n\t\tfor( int r = 0; r < 3; r++ ) {\n\t\t\tfor( int c = 0; c < 3; c++ ) {\n\t\t\t\tif(r != row && c != col) {\n\t\t\t\t\tif( boardArray[y+c][x+r] == num ) {\n\t\t\t\t\t\treturn false;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}", "private static void mapCheck(){\n\t\tfor(int x = 0; x < Params.world_width; x = x + 1){\n\t\t\tfor(int y = 0; y < Params.world_height; y = y + 1){\n\t\t\t\tif(map[x][y] > 1){\n\t\t\t\t\t//System.out.println(\"Encounter Missing. Position: (\" + x + \",\" + y + \").\");\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "public boolean isOpen(int row, int col) {\n if (isInBounds(row-1, col-1)) {\n return grid[row-1][col-1];\n }\n else {\n throw new java.lang.IllegalArgumentException(\"Bad Coordinates\");\n }\n }", "@Override\n\tpublic boolean check(piece[][] board) {\n\t\t\n\t\treturn false;\n\t\t\n\t}", "private boolean check(Board board, char symbol)\n {\n for (int i = 0; i < size; i ++)\n if (checkRow(board, i, symbol))\n return true;\n for (int i = 0; i < size; i++)\n if (checkColumn(board, i , symbol))\n return true;\n if (checkLeftDiagonal(board, symbol))\n return true;\n if (checkRightDiagonal(board, symbol))\n return false;\n return false;\n }", "@Test\r\n public void testIsValidSquare()\r\n {\r\n for(int y = 0; y < 8; y++)\r\n for(int x = 0; x < 8; x++)\r\n assertTrue(board.isValidSqr(x, y));\r\n }", "public boolean isValid(int row, int col) {\n\t\tif (row < 0 || row >= w || col < 0 || col >= l) return false;\n\t\tif (visited[row][col] != 0) return false;\n\t\treturn true;\n\t}", "public boolean isValidSudoku(char[][] board) {\n\t\tif (board.length != 9 || board[0].length != 9) {\n\t\t\treturn false;\n\t\t}\n\t\tchar empty = '.';\n\n\t\t// Arraylists of Boolean arrays for row, column and block\n\t\tArrayList<boolean[]> rowCheck = new ArrayList<boolean[]>();\n\t\tArrayList<boolean[]> colCheck = new ArrayList<boolean[]>();\n\t\tArrayList<boolean[]> blockCheck = new ArrayList<boolean[]>();\n\n\t\t// 9 boolean arrays in each arraylist\n\t\tfor (int i = 0; i < 9; i++) {\n\t\t\trowCheck.add(new boolean[9]);\n\t\t\tcolCheck.add(new boolean[9]);\n\t\t\tblockCheck.add(new boolean[9]);\n\t\t}\n\n\t\t// loop through the matrix\n\t\tfor (int i = 0; i < 9; i++) {\n\t\t\tfor (int j = 0; j < 9; j++) {\n\n\t\t\t\t// Skip loop for empty positions\n\t\t\t\tif (board[i][j] == empty) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\t// Get number at current position. Its index position in array\n\t\t\t\t// would be 1 less than it value\n\t\t\t\tint curr = board[i][j] - '1'; // ' ' due to char data type\n\n\t\t\t\t// Check that row, column or block does not have the value yet\n\t\t\t\tif (rowCheck.get(i)[curr] == true\n\t\t\t\t\t\t|| colCheck.get(j)[curr] == true\n\t\t\t\t\t\t|| blockCheck.get(i / 3 * 3 + j / 3)[curr] == true) {\n\t\t\t\t\treturn false;\n\t\t\t\t} else { // If not found yet, set to true\n\t\t\t\t\trowCheck.get(i)[curr] = true;\n\t\t\t\t\tcolCheck.get(j)[curr] = true;\n\t\t\t\t\tblockCheck.get(i / 3 * 3 + j / 3)[curr] = true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn true; // Valid\n\t}", "public boolean isOpen(int row, int col) {\n if (row < 1 || row > gridSize || col < 1 || col > gridSize) {\n throw new IllegalArgumentException(\"array index out of bounds\");\n }\n\n // 1 --> open site\n return grid[row - 1][col - 1] == 1;\n }", "public boolean isOpen(int row, int col) {\n\t\tif (row < 1 || row > size || col < 1 || col > size) {\n\t\t\tthrow new IllegalArgumentException();\n\t\t}\n\t\treturn grid[row - 1][col - 1];\n\t}", "public static boolean isTakenCell(int row, int col) {\n return (board[row - 1][col - 1] > 0);\n }", "public boolean findPossibleElementInColumn(Board board) {\n for (int y = MIN_INDEX; y < MAX_INDEX; y++) {\n for (int x = MIN_INDEX; x < MAX_INDEX; x++) {\n List<SudokuElement> raw = board.getRaws().get(y).getSudokuElementList();\n final int valueForCurrentField = board.getRaws().get(x).getSudokuElementList().get(y).getValue();\n final SudokuElement valueForCurrent = board.getRaws().get(x).getSudokuElementList().get(y);\n final List<Integer> onlyPossibility = board.getRaws().get(x).getSudokuElementList().get(y).getPossibleElementsList();\n createListOfNumbersToEliminate(valueForCurrent);\n }\n }\n return true;\n }", "public boolean safeCol(int num, int[][] board, int col) //check if it is safe to place num in the given column\n {\n boolean flag = true; //1\n for (int r = 0; r < 9; r++) //n\n {\n if (board[r][col] == num) //1 \n {\n flag = false; //1\n }\n }\n return flag; //1\n }", "public boolean isSquareVisited(int row, int col) {\n return playingBoard[row][col].isVisited();\n }", "boolean UsedInBox(int grid[][], int boxStartRow, int boxStartCol, int num)\n{\n for (int row = 0; row < 3; row++)\n for (int col = 0; col < 3; col++)\n if (grid[row+boxStartRow][col+boxStartCol] == num)\n return true;\n return false;\n}", "public boolean isVaildSudoku(char[][] board) {\n for (int i = 0; i < 9; i++) {\n byte[] recordH = new byte[9];\n byte[] recordV = new byte[9];\n byte[] recordC = new byte[9];\n for (int j = 0; j < 9; j++) {\n //检查横向的\n char h = board[i][j];\n if ('.' != h) {\n h -= '1';\n if (recordH[h] != 0) {\n return false;\n }\n recordH[h] = 1;\n }\n\n //检查纵向的\n char v = board[j][i];\n if ('.' != v) {\n v -= '1';\n if (recordV[v] != 0) {\n return false;\n }\n recordV[v] = 1;\n }\n\n //检查宫格的\n System.out.println(\"i:\" + i + \"--j:\" + j);\n int x = (i / 3) * 3 + j / 3;\n int y = (i % 3) * 3 + j % 3;\n System.out.println(\"x:\" + x + \"--y:\" + y);\n char c = board[x][y];\n System.out.println(MessageFormat.format(\"x:{0} y:{1} current:{2}\", x, y, c));\n if ('.' != c) {\n c -= '1';\n if (recordC[c] != 0) {\n return false;\n }\n recordC[c] = 1;\n }\n }\n for (Map.Entry<Object, Object> entry : new HashMap<>().entrySet()) {\n\n }\n System.out.println(Arrays.toString(recordC));\n }\n\n return true;\n }", "public boolean isFull(int row, int col) {\n\t\tif(row < 0 || row >= N || col < 0 || col >= N) \n\t\t\tthrow new IllegalArgumentException();\n\t\tint index = xyTo1D(row, col);\n\t\treturn isOpen(row, col) && nonPercolate.connected(index, N * N);\n\t}", "private boolean columnOkay(int row, int column) throws Exception {\n ArrayList<Integer> clue = puzzle.getColumnClue(column);\n var filledGroups = searchBoard.getFilledGroups(column, TraversalType.COLUMN);\n if(filledGroups.size() > clue.size()) {\n return false;\n }\n int availableSquares = puzzle.getRows()-row-1;\n int tilesRequired;\n if(filledGroups.size() == 0) {\n tilesRequired = clue.size()-1;\n for(int s : clue) {\n tilesRequired += s;\n }\n } else {\n int index = filledGroups.size()-1;\n if(filledGroups.get(index) > clue.get(index)) {\n return false;\n }\n if(searchBoard.getState(row, column) == CellState.EMPTY && !filledGroups.get(index).equals(clue.get(index))) {\n return false;\n }\n tilesRequired = clue.get(index)-filledGroups.get(index);\n tilesRequired += clue.size()-filledGroups.size();\n if(searchBoard.getState(row, column) == CellState.EMPTY) {\n --tilesRequired;\n }\n for(int i = index+1; i < clue.size(); ++i) {\n tilesRequired += clue.get(i);\n }\n }\n return availableSquares >= tilesRequired;\n }", "public boolean isFull(int x, int y){\r\n\t\tif (_squares[x][y] == null){\r\n\t\t\treturn false;\r\n\t\t}else{\r\n\t\t\treturn true;\r\n\t\t}\r\n\t}", "public boolean checkCol(Square[][] square)\n {\n int sum = 0;\n for(int r = 0; r < square.length; r++)\n {\n sum += square[r][colNum].getValue();\n }\n return sum == 45;\n }", "public boolean checkBoardFull() {\n for (int i = 0; i < N; i++) {\n for (int j = 0; j < N; j++) {\n if (grid[i][j].getSymbol() == '-')\n return false;\n }\n }\n return true;\n }", "public boolean pointExists(int row, int column) {\n return (row > 0 && row < rows && column > 0 && column < columns);\n }", "private boolean checkRange(int rowIndex, int columnIndex) {\n return rowIndex >= 0 && rowIndex < matrix.length\n && columnIndex >= 0 && columnIndex < matrix[rowIndex].length;\n\n }", "public static boolean occupiedExists(int i, int j) {\r\n\t\treturn (_playerOccupied.contains(new Point(i, j)));\r\n\t}", "public boolean isValid() {\n\t\treturn (x >= 0 && x < Board.SIZE && y >= 0 && y < Board.SIZE);\n\t}", "private static boolean squaresAreInvalid(int[][] grid) {\n\t\tif(rowOfSquaresIsInvalid(Rows.TOP, grid))\treturn true;\n\t\tif(rowOfSquaresIsInvalid(Rows.MID, grid))\treturn true;\n\t\tif(rowOfSquaresIsInvalid(Rows.BOT, grid))\treturn true;\n\t\treturn false;\n\t}", "public boolean isFull(int row, int col) {\n validate(row, col);\n int k = mapping(row, col);\n return uf.find(count * count) == uf.find(k);\n }", "public boolean contains(int row, int col) {\n\t\treturn myGrid.contains(row, col);\n\t}", "private boolean isOccupied(int col, int row) {\n if (_board[col][row] != EMP) {\n return true;\n }\n return false;\n }", "public boolean squareIsEmpty (int row, int col){\n return this.gameBoard[row][col] == 'g';\n }" ]
[ "0.68602395", "0.6649582", "0.66344416", "0.66207266", "0.65856844", "0.65209997", "0.6512654", "0.6502135", "0.64692044", "0.6427703", "0.6427703", "0.6427703", "0.6427703", "0.6427703", "0.6427703", "0.64251614", "0.64139277", "0.6407056", "0.63636696", "0.6357108", "0.63412505", "0.633685", "0.6336446", "0.6322267", "0.63207394", "0.6295662", "0.6293419", "0.6285527", "0.62823457", "0.6266649", "0.6265649", "0.62608546", "0.6259575", "0.6257859", "0.62534714", "0.62389153", "0.6218028", "0.62172574", "0.61997306", "0.6185542", "0.617225", "0.61691505", "0.61666334", "0.6163274", "0.6156925", "0.6155711", "0.6134512", "0.6096563", "0.60813946", "0.6080649", "0.60782766", "0.60754585", "0.6069677", "0.6067829", "0.6065725", "0.6061252", "0.60547453", "0.60521555", "0.605036", "0.6036997", "0.6031722", "0.6031446", "0.6027442", "0.60234416", "0.60227275", "0.60160756", "0.6013489", "0.6001163", "0.5989055", "0.5987012", "0.5984506", "0.5984325", "0.59763986", "0.597389", "0.5967164", "0.59619665", "0.59569114", "0.59537363", "0.5951238", "0.5943691", "0.59433055", "0.594318", "0.5931523", "0.5931386", "0.5930165", "0.5926297", "0.59242827", "0.59225744", "0.591975", "0.59151435", "0.5914094", "0.5902502", "0.5885403", "0.5884056", "0.58826476", "0.58759826", "0.5869514", "0.586344", "0.5857541", "0.58570826" ]
0.6451264
9
Checks if the field is free, meaning no player currently marks it.
public boolean isFree(int row, int col) throws ArrayIndexOutOfBoundsException { return getState(row, col) == 0; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Boolean isFree()\n\t{\n\t\treturn free;\n\t}", "public Boolean getFree() {\n return free;\n }", "public boolean hasPakringFree() {\n return ((bitField0_ & 0x00000008) == 0x00000008);\n }", "public boolean hasPakringFree() {\n return ((bitField0_ & 0x00000004) == 0x00000004);\n }", "boolean isFree(Position position);", "public boolean hasPakringFree() {\n return ((bitField0_ & 0x00000008) == 0x00000008);\n }", "public boolean hasPakringFree() {\n return ((bitField0_ & 0x00000004) == 0x00000004);\n }", "protected boolean isValidAvailableField(int x, int y) {\n\t\tif (x < 0 || x >= 8) return false;\n\t\tif (y < 0 || y >= 8) return false;\n\t\t\n\t\t// Is field enabled?\n\t\tif (! _board.isFieldEnabled(x, y)) return false;\n\t\t\n\t\t// If we cannot travel over the same cell, return\n\t\tif (_board.getGame().hasGameOption(Game.GAMEOPTION_TRACEMOVES) && _board.hasTraveled(x, y)) {\n\t\t\treturn false;\n\t\t}\n\t\t\n\t\t// Cell free?\n\t\tPiece dst_piece = _board.getPieceFromXY(x, y);\n\t\tif (dst_piece == null) return true;\n\t\t\n\t\t// Same color in cell, \n\t\tif (dst_piece.getColor() == getColor()) return false;\n\t\t\n\t\t// We can overtake\n\t\tif (_board.getGame().hasGameOption(Game.GAMEOPTION_CANOVERTAKE)) return true;\n\t\t\n\t\treturn false;\n\t}", "public void setFree(Boolean free)\n\t{\n\t\tthis.free = free;\n\t}", "public boolean isUnused() {\n return this.binderySlotNumber == -9234;\n }", "public void deadcheck()\n\t{\n\t\tif (this.shield <= 0)\n\t\t{\n\t\t\tthis.drawMissile = false;\n\t\t}\n\t\telse \n\t\t\tthis.drawMissile = true;\n\t}", "public boolean getIsFree(int num)\n\t{\n\t\treturn isFree[num];\n\t}", "public boolean freeSpace(int neededSpace) {\n \t\treturn true;\n \t}", "public boolean hasFainted() {\n return hp <= 0;\n }", "public boolean isFreezed() {\n\t\treturn this.__freezed;\n\t}", "public boolean checkVisibility() {\n LocalDateTime now = LocalDateTime.now();\n return (this.viewer != 0 && !now.isAfter(this.destructTime));\n }", "private void setFree(final boolean free) {\n\t\tthis.free = free;\n\t}", "public boolean isHitFree()\n {\n // TODO: replace this line with your code\n }", "public boolean isOccupied() {\n return !(getLease() == null);\r\n }", "public boolean hasBeenAcquired(){\r\n\t\treturn !(acquiredBy == null);\r\n\t}", "public boolean isTollFree() \n\t{\n\t\treturn getNumber().charAt(1)=='8';\n\t}", "boolean hasPakringFree();", "boolean hasPakringFree();", "public boolean isFullySupplied()\n {\n boolean isFull = !model.needsFuel() || (model.maxFuel == fuel);\n isFull &= (model.maxAmmo == ammo);\n return isFull;\n }", "public boolean isFreeTorrent() {\r\n\t\treturn freeTorrent;\r\n\t}", "public Boolean invested() {\r\n\t\tif(allocated() >= getAmount()) {\r\n\t\t\treturn true;\r\n\t\t}else {\r\n\t\t\treturn false;\r\n\t\t}\r\n\t}", "public boolean isAvalible() {\n return available;\n }", "public void takeAvailable() {\n\t\tavailable = false;\n\t}", "public boolean isVacant() {\r\n\treturn !isOccupied() || !isAvailable();\r\n }", "public boolean canBeUsed(){\n\t\treturn !(this.isUsed);\n\t}", "public boolean isOccupied(){\n \t\treturn occupiedSeconds > 0;\n \t}", "public boolean isExpired(){\r\n float empty = 0.0f;\r\n return empty == getAmount();\r\n \r\n }", "public boolean isFull() {\n return numOfGoods == cargoSpace;\n }", "public boolean checkIfPlayerHoldsExplosive () { return noOfExplosives > 0; }", "public boolean isFull() {\n\t\t\n\t\tif (currentOccup < maxOccup)\n\t\t\treturn false;\n\t\telse\n\t\t\treturn true;\n\t}", "public void setFreePermits(Integer value) {\n setAttributeInternal(FREEPERMITS, value);\n }", "protected boolean isOccupied(){\n\t\treturn occupied;\n\t}", "private boolean checkRemainingRes() {\n for (int i = 0; i < playingField.getPlayingField().length; i++) {\n for (int j = 0; j < playingField.getPlayingField()[i].length; j++) {\n if (playingField.getPlayingField()[i][j].getResources() > 0) {\n return true;\n }\n }\n }\n return false;\n }", "public void setAvailable(boolean x){\n availabile = x;\n }", "public boolean isFull ()\n {\n for (int row = 0; row < 3; row++)\n for (int column = 0; column < 3; column++)\n if (getGridElement(row, column).getPlayer() == Player.NONE)\n return false;\n\n return true;\n }", "public boolean hasEmptySlots() {\n return (numMaxPlayers - activePlayers) != 0;\n }", "public boolean isBancrupt(){\r\n \treturn _budget <= 0;\r\n }", "public boolean isPlayerDefeated() {\n if (player.getHealth() <= 0) {\n return true;\n }\n return false;\n }", "@Override\r\n\tpublic boolean checkBudget() {\n\t\treturn false;\r\n\t}", "public boolean hasRejected() {\n return fieldSetFlags()[19];\n }", "public boolean isHolding();", "public boolean isFilled() \n\t{\n\t\treturn filled;\n\t}", "public boolean isFreeMoving() {\n\t\treturn _freeMoving;\n\t}", "public boolean checkBonus() {\r\n\t\tif (bonus) {\r\n\t\t\tbonus = false;\r\n\t\t\treturn true;\r\n\t\t} else {\r\n\t\t\treturn false;\r\n\t\t}\r\n\t}", "private void checkChargeTime() {\n\t\tif (elapsedTimeSeconds > chargeTimeP1) {\n\t\t\tplayerCharge.put(dolphinNodeOne, false);\n\t\t}\n\t}", "public boolean isAllocated()\n\t{\n\t\tif(getQtyAllocated().signum()!=0)\n\t\t\treturn true;\n\t\t\n\t\treturn false;\n\t}", "private void CheckFaintedPokemon() {\n \tif(user.getTeam(user.getCurrentPokemonIndex()).getStats().getStatus()==Status.FNT){\n \t\tuser.getTeam(user.getCurrentPokemonIndex()).getInfo().setUsedInBattle(false);\n \t\tbattleMessage.add(user.getTeam(user.getCurrentPokemonIndex()).getInfo().getNickname()+\" has lost the battle. \");\n \t\tbattleOver=true;\n \t}\n \tif(opponent.getTeam(opponent.getCurrentPokemonIndex()).getStats().getStatus()==Status.FNT){\n \t\topponent.getTeam(opponent.getCurrentPokemonIndex()).getInfo().setUsedInBattle(false);\n \t\tCalculateXP(user.getTeam(),opponent.getTeam(opponent.getCurrentPokemonIndex()));\n \t\tbattleMessage.add(opponent.getTeam(opponent.getCurrentPokemonIndex()).getInfo().getNickname()+\" has lost the battle. \");\n \t\tbattleOver=true;\n \t}\n \t\n }", "public boolean hasAmountF() {\n return amountF_ != null;\n }", "public boolean hasDefense() {\n return ((bitField0_ & 0x00000400) == 0x00000400);\n }", "private boolean checkField(int number){\n if(field.get(number).isActive()){\n return false;\n }\n return true;\n }", "public boolean hasDefense() {\n return ((bitField0_ & 0x00000400) == 0x00000400);\n }", "public lanyotech.cn.park.protoc.CommonProtoc.PARKINGFREE getPakringFree() {\n return pakringFree_;\n }", "public lanyotech.cn.park.protoc.CommonProtoc.PARKINGFREE getPakringFree() {\n return pakringFree_;\n }", "public boolean isSetGibbmt()\r\n {\r\n synchronized (monitor())\r\n {\r\n check_orphaned();\r\n return get_store().count_elements(GIBBMT$4) != 0;\r\n }\r\n }", "public BigDecimal getFreeMoney() {\r\n return freeMoney;\r\n }", "public boolean isFreeCoordinate(int x, int y)\n {\n boolean isFree = false;\n if(this.grille[x][y] == \"0\")\n {\n isFree = true;\n // System.out.println(\"case libre : [\" + x + \" \" + y + \"] \" +this.grille[x][y]);\n }\n else{\n // System.out.println(\"case occupee [\"+ x + \" \" + y + \" ] \" +this.grille[x][y]);\n\n }\n return isFree;\n }", "private boolean getFree() {\n \t\treturn this\n \t\t\t\t.sendData(closeBuffer(openBuffer(\"GET_SMS_CREDITS\", \"1.00\")));\n \t}", "public void checkRelease(){\n\n\t\t//Clear boolean to indicate that the GUIItem is no longer touched\n\t\twhileTouched = false;\n\t\tif (touchObject != null)\n\t\t\tonRelease = true;\n\t}", "public boolean isOccupied() {\r\n\treturn character != null;\r\n }", "public boolean isAvailable() {\r\n\treturn available;\r\n }", "@Override\n public boolean active() {\n return !Inventory.isFull();\n }", "public lanyotech.cn.park.protoc.CommonProtoc.PARKINGFREE getPakringFree() {\n return pakringFree_;\n }", "public lanyotech.cn.park.protoc.CommonProtoc.PARKINGFREE getPakringFree() {\n return pakringFree_;\n }", "public static boolean isPreservedFoodAvailable(Person person) {\n\t\tboolean result = false;\n\t\tUnit containerUnit = person.getTopContainerUnit();\n\t\tif (!(containerUnit instanceof MarsSurface)) {\n\t\t\tInventory inv = containerUnit.getInventory();\n\t\t\tif (inv != null && foodConsumptionRate > MIN)\n\t\t\t\tresult = inv.getAmountResourceStored(ResourceUtil.foodID, false) > MIN;\n//\t\t\t\tStorage.retrieveAnResource(foodConsumptionRate, ResourceUtil.foodID, inv, false);\n\t\t}\n\t\treturn result;\n\t}", "private boolean fieldsAreFilled(){\n return !textboxName.isEnabled() && !textboxInitialValue.isEnabled();\n }", "public boolean hasIllegalGoods() {\n return cargoHold.hasIllegalGoods();\n }", "@java.lang.Override\n public boolean hasFenced() {\n return ((bitField0_ & 0x00000002) != 0);\n }", "private boolean verifyObligedFields() {\n if(label.getText().toString().isEmpty() || label.getText().toString().equals(\"\"))\n {\n Toast.makeText(ExpenseCardViewDetails.this, R.string.label_must_be_filled, Toast.LENGTH_SHORT).show();\n return false;\n }\n if(category.getSelectedItem().toString().isEmpty())\n {\n Toast.makeText(ExpenseCardViewDetails.this, R.string.category_must_be_filled, Toast.LENGTH_SHORT).show();\n return false;\n }\n if(cost.getText().toString().isEmpty()){\n Toast.makeText(ExpenseCardViewDetails.this, R.string.cost_must_be_filled, Toast.LENGTH_SHORT).show();\n return false;\n }\n if(dateDue.getText().toString().isEmpty()){\n Toast.makeText(ExpenseCardViewDetails.this, R.string.date_due_must_be_filled, Toast.LENGTH_SHORT).show();\n return false;\n }\n return true;\n }", "public void waitingEnemy(){\t\t\n\t\tgetController().changeFree(false);\n\t\tdisplayAdvertisement(\"waiting enemy\");\n\t\tadvertisementPanel.cancelRequestSetVisible(true);\n\t\tvalidate();\n\t}", "@Override\n public boolean isValid() {\n return (27 - Inventory.getAll().length <= Inventory.find(\"Soft clay\").length)\n || (Inventory.find(\"Soft clay\").length < 1 || Inventory\n .find(\"Astral rune\").length < 1)\n && !Banking.isBankScreenOpen()\n && GlassBlower.antiban.canInteractObject();\n }", "public boolean isRequirementUnfulfilled() {\n return false;\n }", "public void verifyInPlanet() {\n if (!this.isInPlanet())\n return;\n if (this.getPosition().dst2(this.getPlanet().getPosition()) > maximumAllowedDistance) {\n this.removeFromPlanet();\n this.setState(new FloatState(this.state.getTime()));\n }\n }", "public void playerHasInvincibility() {\n\t\tthis.state = canBeKilled;\n\t}", "public boolean hasDefense() {\n return ((bitField0_ & 0x00000100) == 0x00000100);\n }", "public boolean isOccupied() {\n return piece != null;\n }", "public boolean isAvailable() {\n return this.isAcceptingRider && this.currentTrip == null;\n }", "public boolean isAvailable(){\r\n // return statement\r\n return (veh == null);\r\n }", "public synchronized boolean isFull() {\r\n\t\treturn (this.players.size() == 6);\r\n\t}", "private boolean boardIsFull() {\n int numberOfFieldsOnBoard = boardSize * boardSize;\n return (numberOfFieldsOnBoard == this.numberOfOccupiedFields);\n }", "private static void checkFreeSpace()\n {\n boolean isSpaceAvailable = false;\n int numOfFreeSpaces = 0;\n for(int index=1;index<board.length;index++)\n {\n if((board[index] == ' '))\n {\n isSpaceAvailable = true;\n numOfFreeSpaces++;\n }\n }\n if(isSpaceAvailable == false)\n {\n System.err.println(\"Board is full! You can't make another move\");\n System.exit(0);\n }\n else\n {\n System.out.println(\"Free space is available! you have \"+numOfFreeSpaces+ \" moves left\");\n }\n }", "public boolean isAvailable() {\n return available;\n }", "public boolean isSetRelease()\r\n {\r\n synchronized (monitor())\r\n {\r\n check_orphaned();\r\n return get_store().count_elements(RELEASE$4) != 0;\r\n }\r\n }", "public boolean isGranted(){\n\n// if (BallotBoxState.Granted.equals(getBallotBoxState()) || this.quorum.get() <= 0) {\n// setBallotBoxState(BallotBoxState.Granted);\n// return true;\n// }\n// return false;\n\n return this.quorum.get() <= 0;\n }", "public boolean hasOccupation() {\n return ((bitField0_ & 0x00000004) == 0x00000004);\n }", "public boolean hasOccupation() {\n return ((bitField0_ & 0x00000004) == 0x00000004);\n }", "public boolean isPositionFree(\n final Point position,\n final FieldObject object\n ) {\n int x = position.x;\n int y = position.y;\n int halfObjectSize = object.getSize() / 2;\n\n /* Checking field borders */\n if (x - halfObjectSize < 0\n || x + halfObjectSize >= FIELD_WIDTH\n || y - halfObjectSize < 0\n || y + halfObjectSize >= FIELD_HEIGHT) {\n return false;\n }\n\n /* Checking overlays with other field objects */\n for (FieldObject fieldObject : _fieldObjects) {\n int x1 = fieldObject.getPosition().x;\n int y1 = fieldObject.getPosition().y;\n\n double distanceBetweenCenters =\n Math.sqrt((x - x1) * (x - x1) + (y - y1) * (y - y1));\n\n final double minDistance =\n (object.getSize() + fieldObject.getSize()) / 2.0;\n if (distanceBetweenCenters <= minDistance) {\n return false;\n }\n }\n\n return true;\n }", "@java.lang.Override\n public boolean hasFenced() {\n return ((bitField0_ & 0x00000002) != 0);\n }", "public boolean isAcquired() {\r\n return false;\r\n }", "boolean isFullfilled() throws IllegalStateException;", "public boolean hasDefense() {\n return ((bitField0_ & 0x00000100) == 0x00000100);\n }", "public boolean isAvailable(){\r\n return blockingQueue.size() < maxWorkQueueSize;\r\n }", "public boolean isFull(){\n\t\tfor(int i = 0; i < INVENTORY_SLOTS; i++){\n\t\t\tif(inventoryItems[i] == null){\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}", "@Test\n\tpublic void freeCellInitiallyHoldTest() {\n\t\tFreeCell obj = new FreeCell();\n\t\t// Assert homeCell pile1 initially holds 0 cards\n\t\tassertEquals(0, obj.getHomeCellPile(1).getSize());\n\t\t// Assert homeCell pile2 initially holds 0 cards\n\t\tassertEquals(0, obj.getHomeCellPile(2).getSize());\n\t\t// Assert homeCell pile3 initially holds 0 cards\n\t\tassertEquals(0, obj.getHomeCellPile(3).getSize());\n\t\t\n\t}", "public void checkIfFreeTurn(int index, int eIndex) {\n\t\tint player;\n\t\tif (index > 7) {\n\t\t\tplayer = 2;\n\t\t} else {\n\t\t\tplayer = 1;\n\t\t}\n\t\tif (eIndex == 0 || eIndex == 7) {\n\t\t\tif (player == 1) {\n\t\t\t\tb.setTurn(false);\n\t\t\t\ta.setTurn(true);\n\n\t\t\t\ta.setFreeTurn(true);\n\t\t\t\t// a.resetUndoIncrement();\n\t\t\t} else {\n\t\t\t\ta.setTurn(false);\n\t\t\t\tb.setTurn(true);\n\n\t\t\t\tb.setFreeTurn(true);\n\t\t\t\t// b.resetUndoIncrement();\n\t\t\t}\n\n\t\t} else {\n\t\t\ta.setFreeTurn(false);\n\t\t\tb.setFreeTurn(false);\n\t\t}\n\t}", "public boolean isOccupied() {\n\t\treturn piece != null;\n\t}" ]
[ "0.7167961", "0.6806029", "0.6692597", "0.6689845", "0.66842455", "0.6658146", "0.66489756", "0.63499737", "0.6269951", "0.61913586", "0.6171223", "0.6045805", "0.6043488", "0.60370886", "0.60161203", "0.59891456", "0.59858274", "0.5982716", "0.59476906", "0.59252405", "0.5882803", "0.5882564", "0.5882564", "0.5841753", "0.58367664", "0.58350044", "0.5832752", "0.5784509", "0.57804775", "0.5766894", "0.57567203", "0.5732743", "0.5731683", "0.5711733", "0.5709498", "0.5702265", "0.56993085", "0.5696808", "0.5685416", "0.5684868", "0.5683556", "0.568296", "0.56819206", "0.56812626", "0.56622696", "0.56608427", "0.5656286", "0.5653663", "0.5651185", "0.5645303", "0.5631615", "0.56309175", "0.56306976", "0.5622327", "0.56040406", "0.5597029", "0.5594486", "0.5594486", "0.55895805", "0.55863786", "0.5580772", "0.5580141", "0.55765206", "0.55756336", "0.5573644", "0.55735517", "0.55639553", "0.55639553", "0.55617046", "0.55613476", "0.55595505", "0.5552344", "0.5542443", "0.55424297", "0.55347997", "0.5532073", "0.55289084", "0.55272454", "0.55260634", "0.5525088", "0.55244267", "0.55237055", "0.55195636", "0.5514851", "0.5513745", "0.5512396", "0.55103356", "0.5508693", "0.5505531", "0.5505426", "0.5502173", "0.55005234", "0.54974556", "0.54965687", "0.5494167", "0.54931515", "0.5491152", "0.5489824", "0.54879487", "0.5483967" ]
0.6050946
11
Set the next player. Going in upwards order and repeating. example: if 3 players are in the game the next player order is: 12312312... .
public void nextPlayer() { if (currentPlayer == totalPlayer) { currentPlayer = 1; } else { currentPlayer++; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void nextTurn(){\n players.add(currentPlayer);//Added to the back\n currentPlayer = players.pop();//Pull out the first player in line to go next\n }", "public void next_player() {\n\t\tthis.nb_turn++;\n\t\tthis.player_turn++;\n\t\tthis.same_dice_in_a_row = 0;\n\t\tif (player_turn == this.players.size()) {\n\t\t\tthis.player_turn = 0;\n\t\t}\n\n\t\tif (get_player_from_turn().get_surrend()) {\n\t\t\tthis.nb_turn--;\n\t\t\tif (get_player_in_game() > 0) {\n\t\t\t\tthis.next_player();\n\t\t\t}\n\t\t}\n\t}", "public void nextTurn(){\n\t\tplayers[currentPlayer].setNotCurrentPlayer();\n\t\t\n\t\t//increment current player to advance to next player\n\t\tcurrentPlayer = (currentPlayer + 1) % players.length;\n\t\t\n\t\t//update the new current player\n\t\tupdateCurrentPlayerView();\n\t}", "public void nextPlayer() {\n\t\tif (currentPlayer.equals(vServerThread.get(0))){\n\t\t\tcurrentPlayer=vServerThread.get(1);\n\t\t} else if (currentPlayer.equals(vServerThread.get(1))){\n\t\t\tcurrentPlayer=vServerThread.get(0);\n\t\t}\n\t}", "public void nextTurn() {\r\n activePlayer = nextPlayer;\r\n advanceNextPlayer();\r\n }", "public void rotateNextPlayer(){\n\t\t\n\t\tif(this.toRight)\n\t\t\tthis.nextElem = (this.nextElem + 1) % players.size();\n\t\telse\t\t\t\n\t\t\tthis.nextElem = (this.nextElem - 1 + players.size()) % players.size();\n\t}", "public static void ChooseNextPlayer () {\n do {\r\n\r\n // MOVE TO THE NEXT PLAYER\r\n next_player++;\r\n\r\n // IF WE MOVED TOO FAR, WRAP AROUND TO ZERO\r\n if (next_player >= player_count)\r\n next_player = 0;\r\n\r\n } while (player[next_player].lost);\r\n\r\n }", "private int getNextPlayer() {\n int nextPlayerID = ((currentTurn + turnOrder) % numPlayers);\n nextPlayerID = (((nextPlayerID + numPlayers) % numPlayers)); // handles negative numbers\n return nextPlayerID;\n }", "@Override\n public int getNextPlayer() {\n //TODO Implement this method\n if(isPlayerOne){\n return 0;\n }else {\n return 1;\n }\n }", "private void increaseCurrentPlayerIndex() {\n\t\tcurrentPlayer++;\n\t\tif(currentPlayer>3)\n\t\t\tcurrentPlayer=0;\n\t}", "private Player nextPlayer() {\n Player next = players.get(nextPlayerIdx++);\n nextPlayerIdx %= players.size(); \n \n return next;\n }", "public int nextPlayer() {\n\t\tplayer = (player + 1) % playerCount;\n\t\treturn player;\n\t}", "@Override\n public int getNextPlayer()\n {\n // Checks if the current player's ID is 0, as in player 1\n if (currentPlayer == 0)\n {\n //If the current player's ID is 0, change it to be 1, as in player 2\n currentPlayer = 1;\n }\n else\n {\n /*\n * The the current player's ID isn't 0, as in it's player 2, set the\n * ID to be 0, player 1\n */\n currentPlayer = 0;\n }\n\n // Return the current player's value after it's been changed\n return currentPlayer;\n }", "private void playNextPlayer() {\n \n PlayerId nextPlayer = state.nextPlayer();\n players.get(nextPlayer).setHelp(state, handsOfCards.get(nextPlayer), nextPlayer);\n Card c = players.get(nextPlayer).cardToPlay(state, handsOfCards.get(nextPlayer));\n state = state.withNewCardPlayed(c);\n \n handsOfCards.put(nextPlayer, handsOfCards.get(nextPlayer).remove(c));\n players.get(nextPlayer).updateHand(handsOfCards.get(nextPlayer));\n \n for (Map.Entry<PlayerId, Player> pId: players.entrySet()) {\n pId.getValue().updateTrick(state.trick());\n }\n players.get(nextPlayer).resetHelp();\n }", "public void updateNextPlayer(String nextPlayer) {\n\t\titem.setText(7, nextPlayer);\n\t}", "public static void NextTurn() {\n if (num_of_players == turn)\n turn=0;\n turn++;\n }", "public void nextPlayerInTurn() {\n currentPlayerTurn= playersTurns.poll();\n if (currentPlayerTurn != null) {\n eventListener.addEventObject(new PlayerEvent(currentPlayerTurn.getPlayerName(),EventNamesConstants.PlayerTurnArrived));\n currentPlayerName = currentPlayerTurn.getPlayerName();\n }\n else {\n currentPlayerName = \"None\";\n }\n }", "public void determineNextPlayer() {\r\n\t\t// Calculate next player\r\n\t\tSystem.out.println(\"[DEBUG LOG/Game.java] Current player number before getting next: \"+currentPlayer.getNumber());\r\n//\t\tif (currentPlayer.getNumber() == 0) {\r\n//\t\t\tif (p2 == null) {currentPlayer = p1;} else {currentPlayer = p2;}\r\n//\t\t} else if (currentPlayer.getNumber() == 1) {\r\n//\t\t\tif (p3 == null) {currentPlayer = p1;} else {currentPlayer = p3;}\r\n//\t\t} else if (currentPlayer.getNumber() == 2) {\r\n//\t\t\tif (p4 == null) {currentPlayer = p1;} else {currentPlayer = p4;}\r\n//\t\t} else {\r\n//\t\t\tcurrentPlayer = p1;\r\n//\t\t}\r\n\t\tcurrentPlayer = currentPlayer.getNextPlayer(); // Method already deals with quit\r\n\t\t\r\n\t\t// Player is alive and not free\r\n\t\tif (!currentPlayer.isFree() && !currentPlayer.isDead()) { \r\n\t\t\tSystem.out.println(\"[DEBUG LOG/Game.java] Next player is not dead and not free: \"+currentPlayer.getNumber());\r\n\t\t\tturnIsEnding = false;\r\n\t\t\tnewTurn();\r\n\t\t// Player is dead\r\n\t\t} else if (currentPlayer.isDead()) {\r\n\t\t\tif (!checkIfGameIsOver()) {\r\n\t\t\t\tSystem.out.println(\"[DEBUG LOG/Game.java] Player is dead, game is not over so skipping\");\r\n\t\t\t\tendTurn(); // DEATH CONDITION 1.5 & 2 & 2.5\r\n\t\t\t}\r\n\t\t// Player is free\r\n\t\t} else {\r\n\t\t\t// Check if game is over\r\n\t\t\tif (!checkIfGameIsOver()) {\r\n\t\t\t\t// End Game Dragon\r\n\t\t\t\tSystem.out.println(\"[DEBUG LOG/Game.java] Player is free, game is not over\");\r\n\t\t\t\t// Check if this is the first escaped player\r\n\t\t\t\tif (currentPlayer.getPlayerID().contentEquals(firstEscapee.getPlayerID())) {\r\n\t\t\t\t\t// Advance the room and draw next sprite\r\n\t\t\t\t\tcurrentPlayer.setCurrentRoom(currentPlayer.getCurrentRoom()+1);\r\n\t\t\t\t\tint room = currentPlayer.getCurrentRoom();\r\n\t\t\t\t\tcurrentPlayer.getPiece().setX(GlobalVars.playerCoordsPerRoom[room][0]+GlobalVars.playersOffset[currentPlayer.getNumber()][0]);\r\n\t\t\t\t\tcurrentPlayer.getPiece().setY(GlobalVars.playerCoordsPerRoom[room][1]+GlobalVars.playersOffset[currentPlayer.getNumber()][1]);\r\n\t\t\t\t\t// If last room, kill the rest of the players\r\n\t\t\t\t\tif (room == 43) {\r\n\t\t\t\t\t\tSystem.out.println(\"[DEBUG LOG/Game.java] First escapee has reached last room. Killing all other players\");\r\n\t\t\t\t\t\tfor (int i = 0; i < players.size(); i++) {\r\n\t\t\t\t\t\t\tif (!players.get(i).isDead() && !players.get(i).isFree()) {\r\n\t\t\t\t\t\t\t\tdeath(players.get(i)); // DEATH CONDITION 3.5\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t// Not run through death because turnIsEnding = true\r\n\t\t\t\t\t\tif (!status.contentEquals(\"over\")) {\r\n\t\t\t\t\t\t\tgameOver();\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\t// Not last stage so keep going\r\n\t\t\t\t\t\tSystem.out.println(\"[DEBUG LOG/Game.java] Advanced room in end sequence\");\r\n\t\t\t\t\t\tgameChannel.sendMessage(\":skull: Only **\"+(43-room)+\"** turn(s) left!\").queueAfter(2000,TimeUnit.MILLISECONDS);\r\n\t\t\t\t\t\t// Increased cube dragon attack\r\n\t\t\t\t\t\tdragonAttack(cubesPerLevel[attackLevel]+room-39);\r\n\t\t\t\t\t\t// Even if the last player died, should pass and then end game\r\n\t\t\t\t\t\tendTurn();\r\n\t\t\t\t\t}\r\n\t\t\t\t} else {\r\n\t\t\t\t\t// Not first escapee but also free\r\n\t\t\t\t\tendTurn();\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}", "public Player nextPlayer() {\r\n if (this.ordering==null || this.ordering.isEmpty()) {\r\n nextTurn();\r\n }\r\n Player p = this.ordering.poll();\r\n p.setEnergy(p.getBaseEnergy());\r\n p.disableShield();\r\n playerToPlay = p;\r\n p.setAsTurn(true);\r\n return p;\r\n }", "public void nextTurn() {\n\t\tusedPocket = false;\n\t\ttookFromPot = false;\n\t\tcurrentTurn++;\n\t\tcurrentTurn = currentTurn%2;\n\t\tif(currentTurn == 0) {\n\t\t\tcurrentPlayer = player1;\n\t\t\topponentPlayer = player2;\n\t\t} else {\n\t\t\tcurrentPlayer = player2;\n\t\t\topponentPlayer = player1;\n\t\t}\n\t}", "public static void nextTurn(){\n\t\tPlayerButton [][] ary = GameBoard.getPBAry();\n\t\t\n\t\tfor( int x=0; x< ary.length; x++ ){\n\t\t\tfor( int y=0; y<ary[x].length; y++ ){\n\t\t\t\tary[x][y].setMovable( false );\n\t\t\t}\n\t\t}\n\t\t\n\t\tcurr++;\n\t\tif(curr >= players.size())\n\t\t\tcurr=0;\n\n\t\tif(players.get(curr).hasBeenKicked()){\n\t\t\tnextTurn();\n\t\t}\n\t}", "public void setPlayersAtGo()\n {\n for(int i = 0; i < m_numPlayers; i++)\n {\n m_gameBoard.addPlayerToSpace(i + 1, 0);\n }\n }", "private void updateActivePlayer() {\n indexOfActivePlayer++;\n if (indexOfActivePlayer == players.size()) {\n String previousPlayer = players.get(indexOfActivePlayer - 1).getName();\n Collections.shuffle(players);\n while (players.get(0).getName() == previousPlayer) {\n Collections.shuffle(players);\n }\n indexOfActivePlayer = 0;\n }\n }", "public void setNextTurn() {\n\t\t// COMPLETE THIS METHOD\n\t\tif (turn == 1) {\n\t\t\t\n\t\t\tturn = 2;\n\t\t\tcurrentDisc = getPlayer2Disc();\n\t\t\t\t\n\t\t} else {\n\t\t\t\n\t\t\tturn = 1;\n\t\t\tcurrentDisc = getPlayer1Disc();\n\t\t\t\n\t\t}\n\t}", "public void setCurrentPlayer(int index){\n this.currentPlayer=index%4;\n }", "public void setNextActivePlayer() {\n this.activePlayer = getNextActivePlayer();\n // PLAYERLISTENER : Trigger playerEvent for player that is WAITING\n for (PlayerListener listener : playerListeners) {\n PlayerEvent event = new PlayerEvent(this, this.activePlayer, PlayerEvent.PLAYING);\n listener.playerStateChanged(event);\n }\n }", "public static void changePlayer() {\n\t\tvariableReset();\n\t\tif (curPlayer == 1)\n\t\t\tcurPlayer = player2;\n\t\telse\n\t\t\tcurPlayer = player1;\n\t}", "public void nextTurn(){\n\t\tthis.setCurrentElement(this.getCurrentElement().getNext());\n\t}", "public void nextTurn()\n\t{\n\t\tthis.actionListToExecute.clear();\n\t\tthis.board.discardLastPlayedCard();\n\t\tthis.getCurrentPlayer().getDataInput().printMessage(this.getCurrentPlayerGameStatus());\n\t\tthis.getCurrentPlayer().execEndOfTurn();\n\t\t\n\t\tint nbPlayerCardPickup = this.getAmountOfPlayerCardToFillYourHand() - this.getCurrentPlayer().getPlayerCardDeck().size();\n\t\tfor(int i = 0; i < nbPlayerCardPickup; i++)\n\t\t{\n\t\t\tthis.getCurrentPlayer().getPlayerCardDeck().addCard(this.getNextPlayerCard());\n\t\t}\n\t\t\n\t\tcurrentPlayerID = (currentPlayerID + 1) % this.getPlayerList().size();\n\t\tif(currentPlayerID == 0)\n\t\t{\n\t\t\tcurrentPlayerID = this.getPlayerList().size();\n\t\t}\n\t\tthis.getCurrentPlayer().execBeginOfTurn();\n\t\tinitBeginOfTurn();\n\t}", "public void generatePlayer()\n {\n board.getTile(8,0).insertPlayer(this.player);\n }", "public void playerFinishedGoNext() {\n\t\t// If game is over we don't want to switch turn.\n\t\tif (!isOver()) {\n\t\t\tswitchTurn();\n\t\t}\n\t}", "public void next() {\n addTracksToQueue();\n player.skipToNext();\n }", "public int nextPlayer() {\n// int count = 0;\n// for (int i = 0; i < playersArray.length; i++)\n// if (playersArray[i]<0)\n// count++;\n//\n// if (\n do {\n player = (player + 1) % numberPlayers;\n } while (playersArray[player] < 0);\n return player;\n }", "public Player nextPlayer() {\n\t\temptyPlayer = currentPlayer;\n\t\tcurrentPlayer = nextPlayer;\n\t\tnextPlayer = emptyPlayer;\n\t\treturn (currentPlayer);\n\t}", "private void swapPlayer(){\r\n resetTurn();\r\n tries = 0;\r\n Player temp = currentPlayer;\r\n currentPlayer = nextPlayer;\r\n nextPlayer = temp;\r\n if(!gameOver()){\r\n if(currentPlayer.getClass() == Ia.class) {\r\n int[] result = currentPlayer.estimateNextMove(this.getClone());\r\n if (result[0] == 0 && result[1] == 0 && result[2] == 0 && result[3] == 0) currentPlayer.setCanMove(false);\r\n else {\r\n currentPlayer.setCanMove(true);\r\n int row = result[0];\r\n int col = result[1];\r\n int nextRow = result[2];\r\n int nextCol = result[3];\r\n makeMove(row, col, nextRow, nextCol);\r\n }\r\n swapPlayer();\r\n }\r\n }\r\n else {\r\n getWinner();\r\n if(winner == null) System.out.println(\"DRAW!\");\r\n else {\r\n System.out.println(winner.getPlayerName() + \" WIN!\");\r\n if (winner.getClass() == Ia.class)\r\n System.out.println(\"Max time used to move: \" + winner.getMaxTime() + \" seconds\");\r\n }\r\n isOver = true;\r\n }\r\n\r\n }", "private void startNextPlayer() {\n if(flag.equals(\"player1\")){\n p2Handler.post(new Runnable() {\n @Override\n public void run() {\n try {\n Thread.sleep(3000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n Message msg = maHandler.obtainMessage(2);\n maHandler.sendMessage(msg);\n }\n });\n }\n if(flag.equals(\"player2\")){\n p1Handler.post(new Runnable() {\n @Override\n public void run() {\n try {\n Thread.sleep(3000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n Message msg = maHandler.obtainMessage(1);\n maHandler.sendMessage(msg);\n }\n });\n }\n }", "@Test\n void testForNextPlayerUserStartsFirst() {\n Dealer testDealer = new Dealer();\n testDealer.initDealer();\n Human testHuman = testDealer.getUser();\n testDealer.setNextPlayer(testDealer.getUser().getId());\n \n assertEquals(testDealer.getUser() , testDealer.getTrickPlayer());\n assertEquals(testDealer.getBotA().getId(), testDealer.getNextPlayer());\n }", "public void PlayerToPlayNext(UNOCard aCard) {\n\t\tif (gameDirection == \"right\") { // If Game is moving in one direction\n\t\t\tcurrentPlayerToPlayIndex++;\n\t\t\tif (currentPlayerToPlayIndex >= players.size()) {\n\t\t\t\tcurrentPlayerToPlayIndex = currentPlayerToPlayIndex - players.size();\n\t\t\t}\n\t\t}\n\t\t\n\t\tif (gameDirection == \"left\") { // If Game is moving in other direction\n\t\t\tcurrentPlayerToPlayIndex--;\n\t\t\tif (currentPlayerToPlayIndex <= 0) {\n\t\t\t\tcurrentPlayerToPlayIndex = currentPlayerToPlayIndex + players.size();\n\t\t\t}\n\t\t}\n\t\t\n\t\tcurrentPlayerToPlay = players.get(currentPlayerToPlayIndex); // Next Player to play a card\n\t}", "public void switchPlayer() {\r\n\t\tif (player == player1) {\r\n\t\t\tplayer = player2;\r\n\t\t} else {\r\n\t\t\tplayer = player1;\r\n\t\t}\r\n\t}", "public PlayerController getNextPlayer()\n {\n // This will return a player who is going to make a move\n int turn = this.turn;\n int NUMBER_OF_PLAYERS = GameConfiguration.NUMBER_OF_PLAYERS;\n if(turn%NUMBER_OF_PLAYERS == 0) \n {\n turn = 0;\n }\n else\n {\n turn = turn%NUMBER_OF_PLAYERS;\n }\n PlayerController player = findPlayerById(turn);\n return player;\n }", "public PlayerChoicePick getNextPlayerChoicePick();", "public void switchPlayer(){\n // Menukar giliran player dalam bermain\n Player temp = this.currentPlayer;\n this.currentPlayer = this.oppositePlayer;\n this.oppositePlayer = temp;\n }", "public void doNextMove(Player player) {\r\n int newX = xCoord;\r\n int newY = yCoord;\r\n switch (currentDirection) {\r\n case 1:\r\n newX = xCoord + 1;\r\n break;\r\n case 2:\r\n newY = yCoord + 1;\r\n break;\r\n case -1:\r\n newX = xCoord - 1;\r\n break;\r\n case -2:\r\n newY = yCoord - 1;\r\n break;\r\n }\r\n if (checkValidMove(newX, newY)) {\r\n // System.out.println(xCoord + \" \" + yCoord);\r\n // System.out.println(newX + \" \" + newY);\r\n moveTo(newX, newY);\r\n // System.out.println(xCoord + \" \" + yCoord);\r\n\r\n } else {\r\n turnAround();\r\n doNextMove(player);\r\n }\r\n }", "public void playNext() {\n if(mPosition < mMyTracks.size() - 1) {\n mPosition++;\n } else {\n mPosition = ++mPosition % mMyTracks.size();\n }\n prepareTrack();\n }", "private void next() {\n if (position < tracks.size()) {\n Player.getInstance().stop();\n\n // Set a new position:\n ++position;\n\n ibSkipPreviousTrack.setImageDrawable(getResources()\n .getDrawable(R.drawable.ic_skip_previous_track_on));\n\n try {\n Player.getInstance().play(tracks.get(position));\n } catch (IOException playerException) {\n playerException.printStackTrace();\n }\n\n setImageDrawable(ibPlayOrPauseTrack, R.drawable.ic_pause_track);\n setCover(Player.getInstance().getCover(tracks.get(position), this));\n\n tvTrack.setText(tracks.get(position).getName());\n tvTrackEndTime.setText(playerUtils.toMinutes(Player.getInstance().getTrackEndTime()));\n }\n\n if (position == tracks.size() - 1) {\n ibSkipNextTrack.setImageDrawable(getResources()\n .getDrawable(R.drawable.ic_skip_next_track_off));\n }\n }", "public void setNext(GameNode next) {\n this.next = next;\n }", "public void nextTurn() {\r\n ArrayList<Bomb> copy_bombs = new ArrayList<>(this.bombs);\r\n for (Bomb b : copy_bombs) {\r\n if(b.getDelay() == 1){\r\n this.explode = true;\r\n }\r\n b.tick();\r\n b.explode(this);\r\n }\r\n this.ordering = new LinkedList<>();\r\n this.fillPlayerQueue();\r\n if (this.random_order) {\r\n Collections.shuffle((List)this.ordering);\r\n }\r\n\r\n this.turn_number++;\r\n }", "private void alternatePlayer(Piece current) {\n if (currPlayer == X) {\n currPlayer = O;\n }\n else currPlayer = X;\n }", "public void advanceGame() {\n\t\tthis.status = Status.Active;\n\t\tthis.currentSuggestion = null;\n\t\tfor(User u : this.players) {\n\t\t\tu.availableActions.remove(ACTION.Wait);\n\t\t\tu.availableActions.remove(ACTION.Disprove);\n\t\t}\n\t\t\n\t\t// Next player can always move\n\t\tUser nextPlayer = null;\n\t\tdo {\n\t\t\tnextPlayer = getFollowingPlayer(this, this.getCurrentPlayer());\n\t\t\tif (nextPlayer.isActive) {\n\t\t\t\tnextPlayer.availableActions.add(ACTION.Move);\n\t\t\t\tif (this.board.getLocation(nextPlayer.character).isRoom) {\n\t\t\t\t\tnextPlayer.availableActions.add(ACTION.Accuse);\n\t\t\t\t}\n\t\t\t}\n\t\t\tcurrentMove++;\n\t\t} while (!nextPlayer.isActive);\n\t\t\n\t\tif (activeUserCount(this) == 1) {\n\t\t\t// Last player remaining is the winner (by default)\n\t\t\tthis.status = Status.Complete;\n\t\t\tmessages.add(String.format(\"[ %s ] has won the game (by default)!\", nextPlayer.name));\n\t\t}\n\t}", "void skipNextPlayer() {\n endTurn();\n }", "public void onPlayerNext() {\n\t\trunOnUiThread(new Runnable() {\n\t\t\tpublic void run() {\n\t\t\t\tsetCurrentTrack();\n\t\t\t}\n\t\t});\n\t}", "private void changeCurrentPlayer() {\n switch (currentPlayer) {\n case 0: currentPlayer = 1;\n return;\n default: currentPlayer = 0;\n return;\n }\n }", "private void nextTurnRoll() {\n Log.d(\"nextTurnRoll\", \"next player please roll\");\n m_currentTurn++;\n if(m_currentTurn >= m_numPlayers){\n m_currentTurn = 0;\n }\n convertTextToSpeech(players.get(m_currentTurn).getName() + \"please roll the dice\");\n }", "public void slidePlayer(char next){\n\t\t\n\t\t\n\t\tif (next==SLIDE_LEFT){\n\t\t\t//Left\n\t\t\tfor(int j=-1; j>=0-_xIndex; j--){\n\t\t\t\tint nextX=_xIndex+j;\n\t\t\t\tint nextY=_yIndex;\n\t\t\t\tchar nextStop= this._room._roomGrid[nextX][nextY];\n\t\t\t\tif (nextStop == FREE || nextStop == SLIDE_UP || nextStop == SLIDE_DOWN || nextStop == SLIDE_RIGHT || nextStop == SEAMLESS){\n\t\t\t\t\t_gbs.getPlayer().addDest(nextX,nextY);\n\t\t\t\t\tSysOut.print(\"DEST ADDED\");\n\t\t\t\t\t_gbs.getPlayer().setAvoidMethod(\"freeze\");\n\t\t\t\t\t_gbs.getPlayer().setIgnoring(true);\n\t\t\t\t\tthis._approachTimer.start();\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\telse if (next==SLIDE_DOWN){\n\t\t\t//Down\n\t\t\tfor(int j=1; j<=this._room._height-_yIndex-1; j++){\n\t\t\t\tint nextX=_xIndex;\n\t\t\t\tint nextY=_yIndex+j;\n\t\t\t\tchar nextStop= this._room._roomGrid[nextX][nextY];\n\t\t\t\tif (nextStop == FREE || nextStop == SLIDE_UP || nextStop == SLIDE_LEFT || nextStop == SLIDE_RIGHT || nextStop == SEAMLESS){\n\t\t\t\t\t_gbs.getPlayer().addDest(nextX,nextY);\n\t\t\t\t\tSysOut.print(\"DEST ADDED\");\n\t\t\t\t\t_gbs.getPlayer().setAvoidMethod(\"freeze\");\n\t\t\t\t\t_gbs.getPlayer().setIgnoring(true);\n\t\t\t\t\t_gbs.setSpinning(true);\n\t\t\t\t\tthis._approachTimer.start();\n\t\t\t\t\treturn;\n\t\t\t\t}\t\n\t\t\t}\n\t\t}\n\t\t\n\t\t\n\t\telse if (next==SLIDE_UP){\n\t\t\t//Up\n\t\t\tfor(int j=-1; j>=0-_yIndex; j--){\n\t\t\t\tint nextX=_xIndex;\n\t\t\t\tint nextY=_yIndex+j;\n\t\t\t\tchar nextStop= this._room._roomGrid[nextX][nextY];\n\t\t\t\tif (nextStop == FREE || nextStop == SLIDE_LEFT || nextStop == SLIDE_DOWN || nextStop == SLIDE_RIGHT || nextStop == SEAMLESS){\n\t\t\t\t\t_gbs.getPlayer().addDest(nextX,nextY);\n\t\t\t\t\tSysOut.print(\"DEST ADDED\");\n\t\t\t\t\t_gbs.getPlayer().setAvoidMethod(\"freeze\");\n\t\t\t\t\t_gbs.getPlayer().setIgnoring(true);\n\t\t\t\t\t_gbs.setSpinning(true);\n\t\t\t\t\tthis._approachTimer.start();\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\telse if (next==SLIDE_RIGHT){\n\t\t\t//Right\n\t\t\tfor(int j=1; j<=this._room._width-_xIndex-1; j++){\n\t\t\t\tint nextX=_xIndex+j;\n\t\t\t\tint nextY=_yIndex;\n\t\t\t\tchar nextStop= this._room._roomGrid[nextX][nextY];\n\t\t\t\tif (nextStop == FREE || nextStop == SLIDE_UP || nextStop == SLIDE_DOWN || nextStop == SLIDE_LEFT || nextStop == SEAMLESS){\n\t\t\t\t\t_gbs.getPlayer().addDest(nextX,nextY);\n\t\t\t\t\tSysOut.print(\"DEST ADDED\");\n\t\t\t\t\t_gbs.getPlayer().setAvoidMethod(\"freeze\");\n\t\t\t\t\t_gbs.getPlayer().setIgnoring(true);\n\t\t\t\t\t_gbs.setSpinning(true);\n\t\t\t\t\tthis._approachTimer.start();\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "public void setNext(Tile next){\n\t\tthis.next=next;\n\t}", "@Test\n\tpublic final void nextPositionUpTest() {\n\t\tplayer.setUp(true);\n\t\tplayer.getNextYPosition();\n\t\tassertTrue(player.isJumping());\n\t}", "public int incrementPlayerTurn() {\r\n\t\tthis.playerTurn++;\r\n\t\tif ( playerTurn >= 3 ) {\r\n\t\t\tthis.playerTurn = 0;\r\n\t\t}\r\n\t\t\r\n\t\treturn this.playerTurn;\r\n\t}", "@Override\n\tpublic void movePlayerUp() {\n\t\tpacman.changeNextDirection(Direction.up);\n //movePacman();\n\t}", "public void setFirstPlayer() {\n notifySetFirstPlayer(this.getCurrentTurn().getCurrentPlayer().getNickname(), onlinePlayers);\n }", "private PlayState getNext(){\n return values()[(this.ordinal() + 1) % PlayState.values().length];\n }", "public Player nextMove() {\n\t\treturn null;\n\t\t\n\t}", "void next() {\n\tcheckWinCondition();\n\tnew ClientServer(arr);\n\tif (!win) {\n\t\tchangePlayer();\n\t\tP2P.yourTurn = false;\n\t\tP2P.displayTextChanger(Display.txt1, \"Opponents turn!\", Color.lightGray);\n\t} else {\n\t\tgameEnder();\n\t\tEndScreen.showEndGameWindow();\n\tif (curPlayer == 1)\n\t\tEndScreen.infoWindow.setText(\"<html><center><b><font size=25 color=black> Red player won! </font></b></center></html>\");\n\telse\n\t\tEndScreen.infoWindow.setText(\"<html><center><b><font size=25 color=black> Black player won! </font></b></center></html>\");\n\t\tP2P.displayTextChanger(Display.txt1, \"Game has ended!\", Color.blue);\n\t\tP2P.yourTurn = false;\n\t}\n}", "public void autoMove() {\n selectAndMove(computerPlayer.selectToken(this));\n }", "private void nextPosition()\n\t{\n\t\tdouble playerX = Game.player.getX();\n\t\tdouble playerY = Game.player.getY();\n\t\tdouble diffX = playerX - x;\n\t\tdouble diffY = playerY - y;\n\t\tif(Math.abs(diffX) < 64 && Math.abs(diffY) < 64)\n\t\t{\n\t\t\tclose = true;\n\t\t} \n\t\telse\n\t\t{\n\t\t\tclose = false;\n\t\t}\n\t\tif(close)\n\t\t{\n\t\t\tattackPlayer();\n\t\t} \n\t\telse if(alarm.done())\n\t\t{\n\t\t\tdirection = Math.abs(random.nextInt() % 360) + 1;\n\t\t\talarm.setTime(50);\n\t\t}\n\t\thspd = MathMethods.lengthDirX(speed, direction);\n\t\tvspd = MathMethods.lengthDirY(speed, direction);\n\t\tif(hspd > 0 && !flippedRight)\n\t\t{\n\t\t\tflippedRight = true;\n\t\t\tsetEnemy();\n\t\t} \n\t\telse if(hspd < 0 && flippedRight)\n\t\t{\n\t\t\tflippedRight = false;\n\t\t\tsetEnemy();\n\t\t}\n\t\tmove();\n\t\talarm.tick();\n\t\tshootTimer.tick();\n\t}", "public void setCurrPlayer(int i) {\n if (currPlayer == -1) {\n currPlayer = i;\n }\n }", "public void playerNextMove(int row, int col){\r\n setSign(row,col,playerSign);\r\n }", "private void playNext(){\n musicSrv.playNext();\n updateTrackInfo();\n if(playbackPaused){ //if music is paused and user hits next button, next song is played\n playbackPaused = false;\n }\n }", "public void changeDirection(){\n\t\tthis.toRight ^= true;\n\t\t\n\t\tif(this.toRight)\n\t\t\tthis.nextElem = (this.currElem + 1) % players.size();\n\t\telse\n\t\t\tthis.nextElem = (this.currElem - 1 + players.size()) % players.size();\n\t}", "public Player switchPlayer(){\n Player player = getGame().getCurrentPlayer();\n\n List<Card> cards = new ArrayList<>();\n\n for(Card card: getGame().getCards()){\n if(card.rule.isValid(getGame().getDices())){\n cards.add(card);\n }\n }\n\n //get the best card\n if(!cards.isEmpty()){\n Card card = takeTheBestCard(cards);\n\n //add it to the player\n player.getCardsWon().add(card);\n getGame().getCards().remove(card);\n\n System.out.println(player.getName() + \" won \" + card.getExplaination());\n getGame().addAction(new Action(player.getName() + \" won \" + card.getExplaination()));\n }\n\n if(getGame().getCards().isEmpty()){\n game.setStatus(Game.GameStatus.COMPLETED);\n getGame().addAction(new Action(bestPlayer().getName() + \" WON THE GAME!!!\"));\n }\n //turn\n getGame().setCountOfTrialForPlayer(0);\n\n game.setIndexOfCurrentPlayer(game.getIndexOfCurrentPlayer()+1);\n\n if(game.getIndexOfCurrentPlayer() == getGame().getPlayers().size()){\n game.setIndexOfCurrentPlayer(0);\n }\n\n game.setCountOfTrialForPlayer(0);\n game.setDices(new ArrayList<>());\n\n return getGame().getCurrentPlayer();\n }", "private synchronized void sendAdvance(){\r\n\t\t\tfor(PrintWriter p : players){\r\n\t\t\t\tif(p != null){\r\n\t\t\t\t\tp.println(\"5\");\r\n\t\t\t\t\tp.println(Integer.toString(x));\r\n\t\t\t\t\tp.println(Integer.toString(y));\r\n\t\t\t\t\tp.flush();\r\n\t\t\t\t}else{\r\n\t\t\t\t\treturn;\r\n\t\t\t\t}\t\r\n\t\t\t}\t\r\n\t\t}", "public void setNext(Prompt next) {\n\t\t\tthis.next = next;\n\t\t}", "public PlayerId next() {\n return (this.ordinal() == (ALL.size() - 1)) ? ALL.get(0) : ALL.get(this.ordinal() + 1);\n }", "public void setPlayer(Player player) {\n this.currentPlayer = player;\n }", "public void startNewTurn(){\n currentPlayer = players.peek();\n players.add(players.remove());\n view.changeCurrentPlayer(currentPlayer.getName(), currentPlayer.getPlayerDiePath(), numDays);\n currentPlayer.setHasPlayed(false);\n }", "public void increaseTurnCount()\n\t{\n\t\tturnNumber++;\n\t\tthis.currentPlayerID++;\n\t\tthis.currentPlayerID = this.currentPlayerID % this.playerList.size();\n\t}", "public void pairPlayers() {\n List<UUID> lis = new ArrayList<UUID>(playerRegistry.keySet());\n \n Collections.shuffle(lis);\n UUID first = lis.get(0);\n\n for(int i = 0; i <= lis.size(); i++) {\n UUID temp = lis.get(i);\n if(i == lis.size()) {\n pairedPlayers.put(temp, first);\n break;\n }\n\n UUID tempNext = lis.get(i + 1);\n pairedPlayers.put(temp, tempNext);\n }\n\n SecretSanta._this().logDebug(\"[GiftManager] Pairing complete: \" + pairedPlayers.toString());\n }", "private void switchPlayer() {\n Player player;\n playerManager.switchPlayer();\n\n if(playerManager.getCurrentPlayer() == 1)\n player = playerManager.getPlayer(1);\n else if(playerManager.getCurrentPlayer() == 2)\n player = playerManager.getPlayer(2);\n else\n player = new Player(\"No Player exists\");\n\n updateLiveComment(\"Turn : \" + player.getName());\n }", "public void advanceToEndOfNextTrick() {\n\n if (isGameOver()) {\n return;\n }\n \n if (isFirstTurn) {\n startTurn();\n isFirstTurn=false;\n }\n else {\n state=state.withTrickCollected();\n for (Map.Entry<PlayerId, Player> pId: players.entrySet()) {\n pId.getValue().updateScore(state.score());\n }\n }\n\n if (isGameOver()) {\n for (Map.Entry<PlayerId, Player> pId: players.entrySet()) {\n pId.getValue().setWinningTeam(findWinningTeam());\n }\n return;\n }\n\n if (!isFirstTurn && state.isTerminal()) {\n startTurn();\n }\n\n for (Map.Entry<PlayerId, Player> pId: players.entrySet()) {\n pId.getValue().updateScore(state.score());\n pId.getValue().updateTrick(state.trick());\n }\n\n while (!(state.trick().isFull())) {\n playNextPlayer();\n }\n }", "public void nextTurn(){\r\n removeIceAndFire();\r\n currentTurn++;\r\n }", "private void nextMovement()\n\t{\n\t\tif(SEQUENCE.length <= 1)\n\t\t\tSEQUENCE = null;\n\t\telse\n\t\t{\n\t\t\tint[] temp = new int[SEQUENCE.length - 1];\n\t\t\tfor(int i = 1; i < SEQUENCE.length; i++)\n\t\t\t{\n\t\t\t\ttemp[i-1] = SEQUENCE[i];\n\t\t\t}\n\t\t\tSEQUENCE = temp;\n\t\t}\n\t}", "private void nextRound(){\n round++;\n if(round == 6){\n endGame();\n }else{\n out.println(\"###ROUND \" + round + \"###\");\n// ArrayList<Player> playerList = game.getPlayerList();\n for (Player e : playerList) {\n e.resetActions();\n }\n game.applyCards();\n }\n }", "public void setPlayer(int play)\n {\n this.player=play;\n }", "public int whoIsNext(int whoIsNow, int numberOfPlayers)\n\t{ //1,2,3,4\n\t\tint whoIsNextPlayer;\n\t\tif (whoIsNow==numberOfPlayers)\n\t\t\twhoIsNextPlayer=1;\n\t\telse\n\t\t\twhoIsNextPlayer=whoIsNow+1;\n\t\treturn whoIsNextPlayer;\t\t\n\t}", "private void switchPlayer(Player opponentPlayer, Match match) {\r\n if(opponentPlayer.getPlayerId().equals(match.getPlayer1().getPlayerId())){\r\n setCurrentPlayer(match, 1);\r\n } else if (opponentPlayer.getPlayerId().equals(match.getPlayer2().getPlayerId())){\r\n setCurrentPlayer(match, 2);\r\n } else {\r\n LOGGER.error(\"Player not found\");\r\n }\r\n }", "public void AddMovesToPlayer() {\n\t\t// 0 - turn left\n\t\t// 1 - turn right\n\t\t// 2 - go forward\n\t\tfor (int i = 0; i < (2 * minMoves); i++) {\n\t\t\tmoves.add(r.nextInt(3));\n\t\t}\n\t\tthis.face = 1;\n\t}", "private void sendMessagetoRespectivePlayer(int num) {\n Message msg1;\n if(flag == \"player1\"){\n prevP1 = num;\n int newPositionGroup = num / 10;\n if(winningHoleGroup == newPositionGroup){\n msg1 = p1Handler.obtainMessage(3);\n }\n else if((winningHoleGroup == newPositionGroup-1) || (winningHoleGroup == newPositionGroup+1)){\n msg1 = p1Handler.obtainMessage(4);\n }\n else{\n msg1 = p1Handler.obtainMessage(5);\n }\n p1Handler.sendMessage(msg1);\n }\n else{\n prevP2 = num;\n int newPositionGroup = num / 10;\n if(winningHoleGroup == newPositionGroup){\n msg1 = p2Handler.obtainMessage(3);\n }\n else if((winningHoleGroup == newPositionGroup-1) || (winningHoleGroup == newPositionGroup+1)){\n msg1 = p2Handler.obtainMessage(4);\n }\n else{\n msg1 = p2Handler.obtainMessage(5);\n }\n p2Handler.sendMessage(msg1);\n }\n }", "public void setWhoGoesFirst(Player playerToGoFirst) {\n if(playerToGoFirst.equals(humanPlayer)) {\n firstPlayer = humanPlayer;\n secondPlayer = aiPlayer;\n } else {\n firstPlayer = aiPlayer;\n secondPlayer = humanPlayer;\n }\n turn = firstPlayer;\n }", "private Player assignPlayerToFollow(Player notThisPlayer) {\n\t\tint min = 100; //big number so that every other number is smaller\n\t\tPlayer playerToFollow = null;\n\t\tfor(Player p : playerList) {\n\t\t\tif(notThisPlayer == null) {\n\t\t\t\tif(p.getType() == PlayerType.Agent) {\n\t\t\t\t\tif(p.getRobotsFollowing() < min) {\n\t\t\t\t\t\tplayerToFollow = p;\n\t\t\t\t\t\tmin = p.getRobotsFollowing();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\telse if(!p.getName().equals(notThisPlayer.getName())) {\n\t\t\t\tif(p.getType() == PlayerType.Agent) {\n\t\t\t\t\tif(p.getRobotsFollowing() < min) {\n\t\t\t\t\t\tplayerToFollow = p;\n\t\t\t\t\t\tmin = p.getRobotsFollowing();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif(playerToFollow != null)\n\t\t\tplayerToFollow.increaseRobotsFollowing();\n\t\treturn playerToFollow;\n\t}", "private void playerMoveUp()\n {\n this.getCurrentLevel().getInLevelLocation()[this.getCurrentX()][this.getCurrentY()].setHasPlayer(false);\n this.setCurrentY(this.getCurrentY() - 1);\n if (this.getCurrentY() > -1) {\n if (!nextIsWall()) {\n this.getCurrentLevel().getInLevelLocation()[this.getCurrentX()][this.getCurrentY()].setHasPlayer(true);\n } else {\n this.setCurrentY(this.getCurrentY() + 1);\n this.getCurrentLevel().getInLevelLocation()[this.getCurrentX()][this.getCurrentY()].setHasPlayer(true);\n }\n } else// hit edge redo setlocation\n {\n this.setCurrentY(this.getCurrentY() + 1);\n this.getCurrentLevel().getInLevelLocation()[this.getCurrentX()][this.getCurrentY()].setHasPlayer(true);\n } \n }", "public void makePlayerSkipNextRound() {\n\t\tcurrent.setSkipNextRound(true);\n\t}", "public void nextTurn() {\n do {\n colonySimulator.nextTurn(curTurn);\n curTurn++;\n try {\n Thread.sleep(200);\n } catch (InterruptedException ex) {\n Thread.currentThread().interrupt();\n }\n } while (!stepping && queenAlive);\n }", "private void next() {\n Timeline currentTimeline = simpleExoPlayerView.getPlayer().getCurrentTimeline();\n if (currentTimeline.isEmpty()) {\n return;\n }\n int currentWindowIndex = simpleExoPlayerView.getPlayer().getCurrentWindowIndex();\n if (currentWindowIndex < currentTimeline.getWindowCount() - 1) {\n player.seekTo(currentWindowIndex + 1, C.TIME_UNSET);\n } else if (currentTimeline.getWindow(currentWindowIndex, new Timeline.Window(), false).isDynamic) {\n player.seekTo(currentWindowIndex, C.TIME_UNSET);\n }\n }", "private void playOneTurnWithPlayer(Player player, RolledDice rolledDice) throws NotEnoughMoneyException {\n int position = player.increasePosition(rolledDice.getValue() - 1, fields.size());\n Field field = fields.get(position);\n field.playerStepped(player);\n //System.out.println(player);\n }", "public int nextId() throws IllegalIdRequestException {\r\n\t\tif (currentId < players.size()) {\r\n\t\t\treturn currentId++;\r\n\t\t} else {\r\n\t\t\tthrow new IllegalIdRequestException(\"all available IDs have been assigned to players.\");\r\n\t\t}\r\n\t}", "public void newPlayer() {\r\n\t\tthis.nbMonster ++;\r\n\t\tthis.nbPlayer ++;\r\n\t}", "@Test\n public void testNextPlayer() {\n\n assertEquals(Color.BLACK, game.getPlayerInTurn());\n game.nextTurn();\n assertEquals(Color.RED, game.getPlayerInTurn());\n game.nextTurn();\n assertEquals(Color.BLACK, game.getPlayerInTurn());\n }", "private void myTurn()\n\t{\n\t\t\n\t\tif (canPlay())\n\t\t{\n\t\t\tif (isTop())\n\t\t\t{\n\t\t\t\traise();\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tequal();\n\t\t\t}\n\t\t}\n\t\ttable.nextPlayer();\n\t\t\n\t}", "public void setCurrentPlayer(Player P){\n this.currentPlayer = P;\n }", "@Override\r\n\tpublic void makeRandonMove() {\r\n\t\tif (randPlayer.getPlayerNumber() == game.getState().getTurn() && !game.getState().isFinished()) game.execute(randPlayer.requestAction(game.getState()));\r\n\t}", "private void nextTurn(){\n\t\tint[] currentTurnInfo = mTurnIndicator.nextTurn(); \n\t\tif(currentTurnInfo[TurnView.TURN_POSITION] > -1){\n\t\t\t// highlight the current player\n\t\t\tCombatAdapter adapter = (CombatAdapter) getList().getAdapter();\n\t\t\tadapter.setCurrentTurn(currentTurnInfo[TurnView.TURN_POSITION]);\n\t\t\t// change the turn in the game table\n\t\t\tGameTable.setTurn(GameSQLDataSource.getDatabase(getActivity()), mEncounterRowID, currentTurnInfo[TurnView.TURN_POSITION]);\n\t\t\t// set the label\n\t\t\tmTurn.setText(currentTurnInfo[TurnView.TURN_INIT] + \"\");\n\t\t\t// increment the round if necessary\n\t\t\tif(currentTurnInfo[TurnView.TURN_POSITION] == 0){\n\t\t\t\tint round = GameTable.addRound(GameSQLDataSource.getDatabase(getActivity()), mEncounterRowID);\n\t\t\t\tmRound.setText(round + \"\");\n\t\t\t}\n\t\t}\n\t}" ]
[ "0.747705", "0.7418595", "0.73887587", "0.73818564", "0.7351361", "0.72943234", "0.7257342", "0.7183759", "0.71608627", "0.7091235", "0.7081687", "0.7071371", "0.70233965", "0.68501997", "0.68435544", "0.6763391", "0.676149", "0.67556554", "0.67226917", "0.6693016", "0.6670093", "0.6636617", "0.6599291", "0.6557615", "0.6545243", "0.6536292", "0.64471936", "0.6440232", "0.6437489", "0.64312935", "0.6428864", "0.6426512", "0.6400396", "0.63902146", "0.63900846", "0.63577986", "0.6356479", "0.6336012", "0.6296315", "0.62814504", "0.62410086", "0.62394005", "0.62315047", "0.6214488", "0.61993164", "0.61940646", "0.617026", "0.6165821", "0.61593914", "0.6149188", "0.6115406", "0.61041117", "0.6099719", "0.6078586", "0.60735846", "0.6053651", "0.60287535", "0.60254025", "0.5996804", "0.599148", "0.5975994", "0.5973872", "0.5972435", "0.5965185", "0.5959882", "0.5957317", "0.5939097", "0.59389913", "0.5934932", "0.59227186", "0.5920621", "0.5916143", "0.58929753", "0.58910215", "0.5875763", "0.58748066", "0.58743507", "0.587011", "0.58677447", "0.5863452", "0.58567345", "0.5855963", "0.583901", "0.58363825", "0.58356404", "0.5829773", "0.5826076", "0.5824178", "0.5821264", "0.58185136", "0.58167213", "0.5813032", "0.5807945", "0.5806361", "0.5805824", "0.5805784", "0.57966095", "0.57900804", "0.57882655", "0.57868165" ]
0.8094623
0
Check if the current Player has won with his last place.
public abstract boolean hasWon(int row, int col);
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public boolean checkForWin(){\n\t\t\n\t\tPlayer p = Game.getCurrPlayer();\n\t\t// if player made it to win area, player won\n\t\tif(p.won()){\n\t\t\tGame.gameWon = true;\n\t\t\tthis.network.sendWin();\n\t\t\treturn true;\n\t\t}\n\t\t// if player is the last player on the board, player won\n\t\tif(numPlayers == 1 && !p.hasBeenKicked()){\n\t\t\tGame.gameWon = true;\n\t\t\tthis.network.sendWin();\n\t\t\treturn true;\n\t\t}\n\n\t\treturn false;\n\t}", "@Override\n\tpublic boolean playerWon() {\n\t\treturn lastPlayerWin;\n\t}", "public boolean gameOver() {\n return winner() != null;\n }", "public boolean isGameOver() {\n if (!isFirstTurn) {\n if (state.score().totalPoints(TeamId.TEAM_1)>=Jass.WINNING_POINTS||state.score().totalPoints(TeamId.TEAM_2)>=Jass.WINNING_POINTS) {\n return true;\n }\n else {\n return false;\n }\n } \n else {return false;}\n }", "public boolean gameOver() {\r\n return didPlayerLose() || didPlayerWin();\r\n }", "private boolean isOver() {\n for (Player player : players) {\n if (player.getHand().length == 0) {\n System.out.println(\"Player '\" + player.getName() + \"' won!\");\n winner = player.getID();\n return true;\n }\n }\n\n return false;\n }", "private boolean isOver() {\r\n return players.size() == 1;\r\n }", "public boolean hasAnyoneLost()\n {\n gameOver = false;\n if(dw.isEmpty() || de.isEmpty())\n gameOver = true;\n \n return gameOver;\n }", "public boolean gameIsOver() {\r\n int cpt = 0;\r\n for (Player p : players) {\r\n if (p.getLife() > 0) {\r\n cpt++;\r\n }\r\n }\r\n return cpt==1;\r\n }", "private boolean checkGameOver() {\n\t\tboolean singlePlayerWon = otherPlayer.getLife() == 0;\n\t\tboolean otherPlayerWon = singlePlayer.getLife() == 0;\n\n\t\tif (singlePlayerWon || otherPlayerWon) {\n\t\t\tthis.singlePlayer.createEndButton(singlePlayerWon);\n\t\t\tthis.singlePlayer.onGameOver();\n\t\t\tthis.otherPlayer.onGameOver();\n\t\t\treturn true;\n\t\t}\n\n\t\treturn false;\n\t}", "public boolean hasTurn() {\n\t\treturn world.getCurrentPlayer() == this;\n\t}", "public boolean hasWon() {\n return isGoal(curBoard);\n }", "public boolean hasGameEnded() {\n return winner != 0;\n }", "public boolean playerWins(){\n return playerFoundTreasure(curPlayerRow, curPlayerCol);\n }", "public static boolean hasWonTheGame(Player player) {\r\n FloorTile pos = null;\r\n for (int i = 0; i < board.length; i++) {\r\n for (int j = 0; j < board[i].length; j++) {\r\n if (player.getPosition() == board[i][j]) {\r\n pos = board[i][j];\r\n }\r\n }\r\n }\r\n if (goalTile == pos) {\r\n for (int i = 0; i < numOfPlayers; i++) {\r\n players[i].getPlayerProfile().incGamesPlayed();\r\n if (player == players[i]) {\r\n players[i].getPlayerProfile().incWins();\r\n } else {\r\n players[i].getPlayerProfile().incLosses();\r\n }\r\n }\r\n\r\n return true;\r\n }\r\n return false;\r\n }", "public boolean playerLoses(){\n return (curPlayerRow == curTrollRow && curPlayerCol == curTrollCol);\n }", "public boolean isGameOver() {\n return (hasHeWon(computer) || hasHeWon(user) || getAvailableStates().isEmpty());\n }", "public boolean meWin(){\n return whitePieces.size() > blackPieces.size() && isWhitePlayer;\n }", "@Override\n\tpublic boolean checkWinner( int player) {\n\t\t\n\t\treturn didWin(player, -1, 0) ||\n\t\t\t\tdidWin(player, 0, -1) ||\n didWin(player, -1, -1) ||\n didWin(player, 1, -1);\n\t}", "public static boolean isGameLost() {\r\n\t\tboolean gameLost = false;\r\n\t\t\r\n\t\t//Game lost for three handed game.\r\n\t\tif (Main.isThreeHanded){\r\n\t\t\tif (Utils.stringToInt(Main.player1Score) <= Main.loseScoreNumb ||\r\n\t\t\t\t\tUtils.stringToInt(Main.player2Score) <= Main.loseScoreNumb ||\r\n\t\t\t\t\tUtils.stringToInt(Main.player3Score) <= Main.loseScoreNumb) {\r\n\t\t\t\tgameLost = true;\r\n\t\t\t}\r\n\t\t}\r\n\t\t//Game lost for four handed single player game.\r\n\t\tif (Main.isFourHandedSingle){\r\n\t\t\tif (Utils.stringToInt(Main.player1Score) <= Main.loseScoreNumb ||\r\n\t\t\t\t\tUtils.stringToInt(Main.player2Score) <= Main.loseScoreNumb ||\r\n\t\t\t\t\tUtils.stringToInt(Main.player3Score) <= Main.loseScoreNumb ||\r\n\t\t\t\t\tUtils.stringToInt(Main.player4Score) <= Main.loseScoreNumb) {\r\n\t\t\t\tgameLost = true;\r\n\t\t\t}\r\n\t\t}\r\n\t\t//Game lost for four handed team game.\r\n\t\tif (Main.isFourHandedTeams){\r\n\t\t\tif (Utils.stringToInt(Main.team1Score) <= Main.loseScoreNumb ||\r\n\t\t\t\t\tUtils.stringToInt(Main.team2Score) <= Main.loseScoreNumb) {\r\n\t\t\t\tgameLost = true;\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\t//Set Main variable.\r\n\t\tMain.isGameLost = gameLost;\r\n\r\n\t\treturn gameLost;\r\n\t}", "@Override\n public boolean gameOver() {\n //true if the board full or a winner has been found\n return getWinner() != EMPTY || isBoardFull();\n }", "public synchronized boolean HaveWon() {\n if (maxScore <= score) {\n return true;\n }\n return false;\n }", "public boolean didLastMoveWin(){\n\t\tboolean flag=false;\n\t\tif(horizontalWin()){\n\t\t\tSystem.out.println(\"You Won\");\n\t\t\tflag=true;\n\t\t}\n\t\tif(verticalWin()){\n\t\t\tSystem.out.println(\"You Won\");\n\t\t\tflag=true;\n\t\t}\n\t\tif(diagonalWin()){\n\t\t\tSystem.out.println(\"You Won\");\n\t\t\tflag=true;\n\t\t}\n\t\treturn flag;\n\t}", "public boolean topPlayerWon() {\n return winner == 2;\n }", "private void checkWin() {\n // Check if a dialog is already displayed\n if (!this.gameOverDisplayed) {\n // Check left paddle\n if (Objects.equals(this.scoreL.currentScore, this.winCount) && (this.scoreL.currentScore != 0)) {\n if (twoUser) {\n gameOver(GeneralFunctions.TWO_1_WIN);\n } else {\n gameOver(GeneralFunctions.ONE_LOSE);\n }\n // Right paddle\n } else if (Objects.equals(this.scoreR.currentScore, this.winCount) && (this.scoreR.currentScore != 0)) {\n if (twoUser) {\n gameOver(GeneralFunctions.TWO_2_WIN);\n } else {\n gameOver(GeneralFunctions.ONE_WIN);\n }\n }\n }\n }", "@Override\n public boolean gameOver() {\n return player1Wins() || player2Wins();\n }", "Boolean checkEndGame() {\n for (WarPlayer player : players) {\n if (player.getHand().size() == 0)\n return true;\n }\n return false;\n }", "private boolean isGameOver() {\n // either all black or all white pieces don't have any moves left, save\n // to internal field so that a delayed status is available\n gameOver = longestAvailableMoves(1, true).isEmpty() ||\n longestAvailableMoves(1, false).isEmpty();\n return gameOver;\n }", "public static void checkWinCondition() {\n\t\twin = false;\n\t\tif (curPlayer == 1 && arrContains(2, 4))\n\t\t\twin = true;\n\t\telse if (curPlayer == 2 && arrContains(1, 3))\n\t\t\twin = true;\n\t\tif (curPlayer == 2 && !gameLogic.Logic.arrContains(2, 4))\n\t\t\tP2P.gameLost = true;\n\t\telse if (gameLogic.Logic.curPlayer == 1 && !gameLogic.Logic.arrContains(1, 3))\n\t\t\tP2P.gameLost = true;\n\t\tif (P2P.gameLost == true) {\n\t\t\tif (gameLogic.Logic.curPlayer == 1)\n\t\t\t\tEndScreen.infoWindow.setText(\"<html><center><b><font size=25 color=black> Black player won! </font></b></center></html>\");\n\t\t\telse\n\t\t\t\tEndScreen.infoWindow.setText(\"<html><center><b><font size=25 color=black> Red player won! </font></b></center></html>\");\n\t\t}\n\t\telse\n\t\t\twin = false;\n\t}", "public final boolean checkForWin() {\r\n boolean result = false;\r\n String player = \"\";\r\n \r\n for (Rail rail : rails) {\r\n if (rail.isWinner()) {\r\n result = true;\r\n for(Tile tile : rail.getTiles()) {\r\n tile.setBackground(Color.GREEN);\r\n player = tile.getText();\r\n }\r\n if (player.equals(\"X\")) {\r\n winningPlayer = \"X\";\r\n this.xWins++;\r\n } else if (player.equals(\"0\")) {\r\n winningPlayer = \"0\";\r\n this.oWins++;\r\n }\r\n break;\r\n }\r\n }\r\n \r\n return result;\r\n }", "private void whichPlayerHasTurn() throws PlayerOutOfTurn {\n if (test.equals(lastPicked)) {\n throw (new PlayerOutOfTurn());\n }\n }", "public boolean gameOver(){\r\n if(isGame) return (currentPlayer.getChecks() == 0 || nextPlayer.getChecks() == 0 || currentPlayer.getQueens() == 4 || nextPlayer.getQueens() == 4 || (currentPlayer.cantMove() && nextPlayer.cantMove()));\r\n return getNumChecks(WHITE) == 0 || getNumChecks(BLACK) == 0 || getNumQueens(WHITE) == 4 || getNumQueens(BLACK) == 4;\r\n }", "boolean GameOver() {\n\t\treturn player.isDead();\n\t}", "public boolean userStillInGame() {\n return playersInGame.contains(humanPlayer);\n }", "public boolean isGameOver(){\n return checkKingReachedEnd() || checkNoDragonsLeft() || checkIfKingSurrounded();\n }", "public void gameOverCheck() {\n //users\n if (tankTroubleMap.getUsers().size() != 0) {\n tankTroubleMap.setWinnerGroup(tankTroubleMap.getUsers().get(0).getGroupNumber());\n for (int i = 1; i < tankTroubleMap.getUsers().size(); i++) {\n if (tankTroubleMap.getUsers().get(i).getGroupNumber() != tankTroubleMap.getWinnerGroup())\n return;\n }\n }\n //bots\n int firstBot = 0;\n if (tankTroubleMap.getBots().size() != 0) {\n if (tankTroubleMap.getWinnerGroup() == -1) {\n firstBot = 1;\n tankTroubleMap.setWinnerGroup(tankTroubleMap.getBots().get(0).getGroupNumber());\n }\n for (int i = firstBot; i < tankTroubleMap.getBots().size(); i++) {\n if (tankTroubleMap.getBots().get(i).getGroupNumber() != tankTroubleMap.getWinnerGroup())\n return;\n }\n }\n tankTroubleMap.setGameOver(true);\n }", "boolean gameOver() {\n return piecesContiguous(BP) || piecesContiguous(WP);\n }", "public boolean isGameOver() {\n\t\treturn (lives <= 0);\n\t}", "public static boolean isGameFinished() {\n return mafiaIsWinner() || citizenIsWinner();\n }", "public boolean isGameOver() {\n if (gameStatus == null || gameStatus.getPlayerOne() == null || gameStatus.getPlayerTwo() == null) return false;\n return gameStatus.isTie()\n || gameStatus.getPlayerOne().equals(gameStatus.getWinner())\n || gameStatus.getPlayerTwo().equals(gameStatus.getWinner())\n || gameStatus.getPlayerOnePoints() == 0\n || gameStatus.getPlayerTwoPoints() == 0\n || (getWhoseTurn() == 1 && isPlayerMoveImpossible(1))\n || (getWhoseTurn() == 2 && isPlayerMoveImpossible(2));\n }", "public boolean isGameOver() {\n\t\treturn (movesLeft() == 0) || someoneQuit\n\t\t\t\t|| (winningPlayer != Game.GAME_NOT_OVER);\n\t}", "public boolean checkWin()\n {\n boolean won = false;\n\n // Checks for the wining condition, if true end game. Else keep running.\n if((getPerson(PLAYER).getInventory().getItems().contains(winItem) && getPerson(PLAYER).getLocation().getName().equals(STARTROOM))||(moves > MOVELIMIT)){\n won = true;\n\n // Checks if the player won, then print a player winning statement.\n if (moves > MOVELIMIT){\n System.out.println(\"Princess Peach: \"+ getPerson(PLAYER).getName() + \", you have run out of time, Rover has ran away.\");\n }\n else{\n System.out.println(\"Princess Peach:\"+ getPerson(PLAYER).getName() + \", You've found the \" + winItem.getName() + \"!\");\n printEndingStory();\n }\n\n } \n return won;\n }", "public boolean isWinTurn() {\n for (int col = 0; col < mColsCount; col++) {\n if (isFourConnected(getCurrentPlayer(), 0, 1, 0, col, 0)\n || isFourConnected(getCurrentPlayer(), 1, 1, 0, col, 0)\n || isFourConnected(getCurrentPlayer(), -1, 1, 0, col, 0)) {\n hasWinner = true;\n return true;\n }\n }\n\n for (int row = 0; row < mRowsCount; row++) {\n if (isFourConnected(getCurrentPlayer(), 1, 0, row, 0, 0)\n || isFourConnected(getCurrentPlayer(), 1, 1, row, 0, 0)\n || isFourConnected(getCurrentPlayer(), -1, 1, row, mColsCount - 1, 0)) {\n hasWinner = true;\n return true;\n }\n }\n\n return false;\n }", "public boolean isGameOver() {\r\n for (String player : this.playerIds) {\r\n\r\n //If player has an empty card\r\n if(hasEmptyHand(player)) {\r\n return true;\r\n }\r\n }\r\n return false;\r\n }", "private boolean winGame() {\n if (model.isCompleted()) {\n win.message(\"Winner\");\n return true;\n }\n return false;\n }", "public boolean amIWinning(){\n if (playerScore > oppoScore) {\n return true;\n } else {\n return false;\n }\n }", "private boolean playerWin(Board board)\n {\n return check(board, PLAYER);\n }", "public boolean gameOver(){\n\t\treturn this.lives < 1;\n\t}", "public static boolean isGameWon() {\r\n\t\tboolean gameWon = false;\r\n\t\t\r\n\t\t//Game won for three handed game.\r\n\t\tif (Main.isThreeHanded){\r\n\t\t\tif (Utils.stringToInt(Main.player1Score) >= Main.winScoreNumb ||\r\n\t\t\t\t\tUtils.stringToInt(Main.player2Score) >= Main.winScoreNumb ||\r\n\t\t\t\t\tUtils.stringToInt(Main.player3Score) >= Main.winScoreNumb) {\r\n\t\t\t\tgameWon = true;\r\n\t\t\t}\r\n\t\t}\r\n\t\t//Game won for four handed single player game.\r\n\t\tif (Main.isFourHandedSingle){\r\n\t\t\tif (Utils.stringToInt(Main.player1Score) >= Main.winScoreNumb ||\r\n\t\t\t\t\tUtils.stringToInt(Main.player2Score) >= Main.winScoreNumb ||\r\n\t\t\t\t\tUtils.stringToInt(Main.player3Score) >= Main.winScoreNumb ||\r\n\t\t\t\t\tUtils.stringToInt(Main.player4Score) >= Main.winScoreNumb) {\r\n\t\t\t\tgameWon = true;\r\n\t\t\t}\r\n\t\t}\r\n\t\t//Game won for four handed team game.\r\n\t\tif (Main.isFourHandedTeams){\r\n\t\t\tif (Utils.stringToInt(Main.team1Score) >= Main.winScoreNumb ||\r\n\t\t\t\t\tUtils.stringToInt(Main.team2Score) >= Main.winScoreNumb) {\r\n\t\t\t\tgameWon = true;\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\t//Set Main variable.\r\n\t\tMain.isGameWon = gameWon;\r\n\t\t\r\n\t\treturn gameWon;\r\n\t}", "public boolean hasWon() {\n\t\tfor (int i = 0; i < wordToGuess.length(); i++) {\n\t\t\tchar letter = wordToGuess.charAt(i);\n\t\t\tif (!guessesMade.contains(letter)) {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}", "public boolean endOfGame() {\n\t\tfor (int i = 0; i < getNumOfPlayers(); i++) {\n\t\t\tif (this.getPlayerList().get(i).getCardsInHand().isEmpty()) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}", "public boolean won()\n {\n if (currentScore >= PigGame.GOAL)\n {\n return true;\n }\n \n else\n {\n return false;\n }\n }", "@Override\r\n\tpublic boolean isGameOver() {\n\t\treturn !( hasMoves( Seed.CROSS) || hasMoves( Seed.NOUGHT) );\r\n\t}", "public static void checkResult() {\n\t\tint sum = PlayerBean.PLAYERONE - PlayerBean.PLAYERTWO;\n\n\t\tif (sum == 1 || sum == -2) {\n\t\t\tScoreBean.addWin();\n\t\t\tresult = \"player one wins\";\n\t\t} else {\n\t\t\tScoreBean.addLoss();\n\t\t\tresult = \"player two wins\";\n\t\t}\n\t}", "public boolean isFinished() {\n\t\tif ((player1_moves | player2_moves) == COMPLETE) {\n\t\t\tfinished = true;\n\t\t\tcurrentPlayer = '\\0';\n\t\t}\n\t\tfor (int i : winning_cases) {\n\t\t\tif ((player1_moves & i) == i) {\n\t\t\t\twinner = 'X';\n\t\t\t\tfinished = true;\n\t\t\t} else if ((player2_moves & i) == i) {\n\t\t\t\twinner = 'O';\n\t\t\t\tfinished = true;\n\t\t\t}\n\t\t}\n\t\treturn finished;\n\t}", "public boolean hasHeWon(int player) {\n if ((board[0][0] == board[1][1] && board[0][0] == board[2][2] && board[0][0] == player) ||\n (board[0][2] == board[1][1] && board[0][2] == board[2][0] && board[0][2] == player)) {\n return true;\n }\n for (int i = 0; i < 3; i++) {\n // check for row i\n if (board[i][0] == board[i][1] && board[i][0] == board[i][2] && board[i][0] == player) {\n return true;\n } else\n // check for column i\n if (board[0][i] == board[1][i] && board[0][i] == board[2][i] && board[0][i] == player) {\n return true;\n }\n }\n return false;\n }", "@Override\n public void checkWonLost(Entity entity) {\n if (entity instanceof Player) {\n\n if (overallCoinsInGame <= 0) {\n world.won();\n }\n }\n }", "public boolean gameContinue() {\n for (Player player : players) {\n if (player.getPoints() > END_GAME_POINTS) {\n return false;\n }\n }\n return true;\n }", "public boolean isGameOver() {\n\t\treturn this.b.isGameOver();\n\t}", "public boolean gameEnd(){\r\n return !hasMovements(model.getCurrentPlayer().getColor());\r\n }", "boolean gameOver() {\n return piecesContiguous(BLACK) || piecesContiguous(WHITE);\n }", "private void checkIfAnotherPlayerLiesThere(int player, int place) {\n //get our board position\n int playerPos = userGridToLudoBoardGrid(player, place);\n\n //iterate all players\n for (int i = 0; i < nrOfPlayers(); i++) {\n //not our player\n if (players.get(i).getName() != players.get(player).getName()) {\n int counter = 0;\n //go through all pieces\n for (Piece piece : players.get(i).getPieces()) {\n //check if board position is the same\n if (userGridToLudoBoardGrid(i, piece.getPosition()) == playerPos) {\n counter++;\n }\n }\n //if there is only 1 piece there, reset it\n if (counter == 1) {\n int pieceIndex = 0;\n for (Piece piece : players.get(i).getPieces()) {\n if (userGridToLudoBoardGrid(i, piece.getPosition()) == playerPos) {\n\n // PIECELISTENER : Throw PieceEvent to PieceListeners\n for (PieceListener listener : pieceListeners) {\n PieceEvent pieceEvent = new PieceEvent(this, players.get(i).colour, pieceIndex++, piece.getPosition(), 0);\n listener.pieceMoved(pieceEvent);\n }\n\n // Reset piece\n piece.setPosition(0);\n }\n }\n }\n }\n }\n }", "@Override\n public boolean isWin() {\n for (Observer winner : winners) {\n if (winner.getName().equals(chosenHorse.getName())) {\n return true;\n }\n }\n return false;\n }", "public void checkGameEndState() {\n\t\tfor(MapCharacter c : friendlyMissionCriticals) {\n\t\t\tif(!friendlies.contains(c))\n\t\t\t\tthrow new PlayerLosesException();\n\t\t}\n\t\tif(getEnemies().size() == 0)\n\t\t\tthrow new PlayerWinsException();\n\t}", "@Override\r\n\tboolean isFinished() {\r\n\t\t// TODO Auto-generated method stub\r\n\t\tif(checkForWin() != -1)\r\n\t\t\treturn true;\r\n\t\telse if(!(hasValidMove(0) || hasValidMove(1)))\r\n\t\t\treturn true; //game draw both are stuck\r\n\t\telse return false;\r\n\t}", "public boolean isPlayerAlive() {\r\n\t\treturn !(this.getRobotsAlive().isEmpty());\r\n\t}", "public boolean GameIsOver() {\n\t\tif(deck.numCardsLeft()==8) {\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}", "public boolean hasWon(Player currentPlayer) {\n\t\treturn currentPlayer.hasVictim();\n\t}", "public boolean isPlayerWinner(int player)\n {\n return players[player] == 100;\n }", "public boolean checkForEndgame() {\n\t\tCalculatePossibleMoves(true);\n\t\tint blackMoves = getNumberOfPossibleMoves();\n\t\tCalculatePossibleMoves(false);\n\t\tint redMoves = getNumberOfPossibleMoves();\n\t\t\n\t\tif (blackMoves == 0 && redMoves == 0)\n\t\t\treturn true;\n\t\treturn false;\n\t}", "public boolean oWins() {\n\t\tif (checkWinner(LETTER_O) == 1)\n\t\t\treturn true;\n\t\telse\n\t\t\treturn false;\n\t}", "public boolean isGameOver()\n {\n if ( this.canMove(Direction.UP) || this.canMove(Direction.DOWN) ||\n this.canMove(Direction.LEFT) || this.canMove(Direction.RIGHT) ) { \n return false;\n }\n else {\n return true;\n } \n }", "protected boolean checkWin(int pno) {\n\t\tint[] pos = playerPosition.get(pno);\n\t\tif (collectedGold.get(pno) >= map.getWin() && \n\t\t\t\tmap.lookAtTile(pos[0], pos[1]) == 'E') {\n\t\t\tremovePlayer(pno);\n\t\t\tSystem.out.println(\"Client \" + pno + \" has escaped!\");\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}", "public boolean checkWin (int totalPieces){\n\t\treturn isFull();\n\t}", "public boolean playersFilled() throws SQLException {\n\t\ttry {\n\t\t\tif (getPlayers().last() == true) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t} catch (SQLException e) {\n\t\t\tSystem.out.println(e.getMessage());\n\t\t}\n\t\treturn false;\n\t}", "public boolean isGameOver() {\n return poolFront.next == null;\n }", "private boolean checkGameStatus() {\n int res = model.getWinner();\n if (res == Model.DRAW) {\n draw();\n return false;\n } else if (res == Model.WHITE) {\n whiteScore++;\n view.getPrompt().setText(whiteName + \" win!\");\n prepareRestart();\n return false;\n } else if (res == Model.BLACK) {\n blackScore++;\n view.getPrompt().setText(blackName + \" win!\");\n prepareRestart();\n return false;\n }\n return true;\n }", "private boolean isGameOver() {\n int numberOfRowsFilled = 0;\n for (GameRow row : rows) {\n if (row.isFilled()) {\n numberOfRowsFilled++;\n if (row.hasWinner()) {\n return true;\n }\n }\n }\n return numberOfRowsFilled == rows.size();\n }", "public boolean isWinner(ArrayList<Player> allPlayers,Player player){\n\t\tPlayer winner=player;\n\t\tfor (Player p : allPlayers) {\n\t\t\tif(p.getTimeStamp()>winner.getTimeStamp()){\n\t\t\t\twinner = p;\n\t\t\t}\n\t\t}\n\t\treturn winner.equals(player);\n\t}", "public boolean hasWon() {\n return this.isWinner;\n }", "public boolean isWinner(String username) {\n Player p = getPlayer(username);\n // Winner!\n return p != null && p.getScore() >= MyConstants.POINTS_TO_WIN;\n }", "public boolean checkGameOver() {\n return ((posIniPiece[piece.getKind()] == piece.getPos(0)) && iteration > 0);\n }", "public void checkWin(){\n boolean result = false;\n if(game.getTurn() > 3){\n Player currentPlayer = game.getPlayerTurn();\n int playernumber = currentPlayer.getPlayericon();\n result = game.winChecker(game.getBored(),playernumber);\n if(result == true) {\n setWinMsgBox(currentPlayer.getPlayerName() + \" Is victorious :)\",\"WIN\");\n }else if(game.getTurn() == 8 && result == false){\n setWinMsgBox(\"Too bad it is a draw, No one out smarted the other -_-\",\"DRAW\");\n }else{}\n }else{\n result = false;\n }\n }", "public boolean checkGameOver(){\n\t\tfor(int x = 0; x < this.tile[3].length; x++){\n\t\t if(this.isFilled(3, x)){\n\t\t \tSystem.out.println(\"game over\");\n\t\t return true;\n\t\t }\n\t\t}\n\t\treturn false;\n\t}", "public boolean gameOver()\n {\n return checkmate()||draw()!=NOT_DRAW;\n }", "public boolean isGameOver() {\r\n\t\treturn !getCurrentPlayingSpace().isBallsLeftOnTable();\r\n\t}", "public boolean isGameOver() {\n if (winner == null) {\n Piece[] diagOne = new Piece[this.size];\n Piece[] diagTwo = new Piece[this.size];\n for (int col = 0; col < _board.length; col += 1) {\n diagOne[col] = _board[col][col];\n diagTwo[col] = _board[col][this.size - 1 - col];\n if (isWinning(_board[col])) {\n alternatePlayer(currPlayer);\n winner = currPlayer;\n return true;\n }\n }\n this.transpose();\n for (int row = 0; row < _board[0].length; row += 1) {\n if (isWinning(this._board[row])) {\n this.transpose();\n alternatePlayer(currPlayer);\n winner = currPlayer;\n return true;\n }\n }\n\n this.transpose();\n\n if (isWinning(diagOne) || isWinning(diagTwo)) {\n alternatePlayer(currPlayer);\n winner = currPlayer;\n return true;\n }\n if (checkTie()) {\n return true;\n }\n }\n return false;\n }", "public boolean isGameOver() {\n\t\treturn false;\n\t}", "@Override\n public boolean currentPlayerHavePotentialMoves() {\n return !checkersBoard.getAllPotentialMoves(getCurrentPlayerIndex()).isEmpty();\n }", "public boolean gameOver() \n {\n \treturn status() != GAME_NOT_OVER;\n }", "public boolean isGameOver() {\n if(gameDescriptor.getTotalCycles() < roundNumber){\n eventListener.addEventObject(new RoundEvent(EventNamesConstants.GameFinished));\n return true;\n }\n return false;\n }", "@Override\n public boolean isLocalPlayersTurn() {\n return getTeam().equals(currentBoard.turn());\n }", "private boolean isGameOver() {\n return Snake().isTouching(Wall()) || Snake().isTouching(Snake());\n }", "@java.lang.Override\n public boolean hasOpponent() {\n return opponent_ != null;\n }", "public boolean isWinnerMe() {\n if (gameStatus == null || userId == null) return false;\n return userId.equals(gameStatus.getWinner())\n || (getMyPlayerNumber() == 1 && getPlayerTwoPoints() == 0)\n || (getMyPlayerNumber() == 2 && getPlayerOnePoints() == 0)\n || getMyPlayerNumber() == 1 && getPlayerOnePoints() > getPlayerTwoPoints()\n || getMyPlayerNumber() == 2 && getPlayerOnePoints() < getPlayerTwoPoints();\n }", "private void checkPlayerCondition()\n\t{\n\t\tif (playerExists() && PlayerAccess.getPlayer().isInExit())\n\t\t{\n\t\t\twon = true;\n\t\t}\n\t\tif (playerIsDead())\n\t\t{\n\t\t\tMapInstance.getInstance().levelRestart();\n\t\t}\n\t\tif (playerHasLost())\n\t\t{\n\t\t\tlost = true;\n\t\t}\n\t\tif (runOutOfTime())\n\t\t{\n\t\t\tPlayerAccess.getPlayer().die();\n\t\t}\n\t}", "public boolean endOfGame() {\n\t\tfor(CardGamePlayer player : playerList) {\n\t\t\tif(gameStarted && player.getNumOfCards() == 0) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}", "public boolean hasMoved(){\n\t\treturn getGame().getCurrentPlayer().hasMoved();\n\t}", "private boolean checkIfGameIsWon() {\n\t\t//loop through rows\n\t\tfor (int i = 0; i < NUMBER_OF_ROWS; i++) {\n\t\t\t//gameIsWon = this.quartoBoard.checkRow(i);\n\t\t\tif (this.quartoBoard.checkRow(i)) {\n\t\t\t\tSystem.out.println(\"Win via row: \" + (i) + \" (zero-indexed)\");\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\t\n\t\t//loop through columns\n\t\tfor (int i = 0; i < NUMBER_OF_COLUMNS; i++) {\n\t\t\t//gameIsWon = this.quartoBoard.checkColumn(i);\n\t\t\tif (this.quartoBoard.checkColumn(i)) {\n\t\t\t\tSystem.out.println(\"Win via column: \" + (i) + \" (zero-indexed)\");\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\t\n\t\t//check Diagonals\n\t\tif (this.quartoBoard.checkDiagonals()) {\n\t\t\tSystem.out.println(\"Win via diagonal\");\n\t\t\treturn true;\n\t\t}\n\t\t\n\t\treturn false;\n\t}", "public boolean GameOver() {\r\n if(Main.player1.SuaVida()==0 || Main.player2.SuaVida()==0)\r\n return true;\r\n return false;\r\n }", "public boolean isGameFinished() {\n if (listaJogadores.size() - listaJogadoresFalidos.size() == 1) {\n return true;\n } else {\n return false;\n }\n\n }" ]
[ "0.763378", "0.7609286", "0.72225606", "0.71539104", "0.7143171", "0.7070985", "0.70598733", "0.7025711", "0.7025172", "0.7022115", "0.697839", "0.697728", "0.6976904", "0.6965175", "0.6955494", "0.6920912", "0.688817", "0.68799555", "0.6866264", "0.68647844", "0.6843293", "0.6836185", "0.6818172", "0.681708", "0.68079793", "0.67784476", "0.6766934", "0.67652863", "0.6763269", "0.6760519", "0.6710968", "0.67086655", "0.66859204", "0.6675727", "0.6668095", "0.66679376", "0.6666254", "0.6659269", "0.66581655", "0.6657698", "0.6627681", "0.6621213", "0.6617574", "0.6613444", "0.65933037", "0.656123", "0.6543079", "0.65309036", "0.6517064", "0.6507664", "0.6505965", "0.64962286", "0.6495452", "0.64944416", "0.649418", "0.6486258", "0.64796937", "0.6475055", "0.6474126", "0.6473315", "0.64719516", "0.64653665", "0.64619386", "0.64568216", "0.6436212", "0.6431913", "0.6430724", "0.6421806", "0.6408781", "0.64083236", "0.6400306", "0.63939387", "0.63924277", "0.6382724", "0.63785833", "0.6376163", "0.6373339", "0.6373006", "0.63508284", "0.6350745", "0.63502985", "0.63491994", "0.6346852", "0.63452256", "0.63370633", "0.6328782", "0.6328765", "0.63247365", "0.6321161", "0.6316982", "0.63161063", "0.6313557", "0.63125896", "0.6307625", "0.63035536", "0.63025737", "0.63008946", "0.6298108", "0.6288063", "0.6287845", "0.62877065" ]
0.0
-1
Check if the board is full. Meaning there are no more free fields with the value of 0. In other words, all fields are taken by any players.
public boolean isFull() { return placeCounter == dimension * dimension; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private boolean boardIsFull() {\n int numberOfFieldsOnBoard = boardSize * boardSize;\n return (numberOfFieldsOnBoard == this.numberOfOccupiedFields);\n }", "public boolean isFull(){\r\n\t\tfor(int i = 0; i < boardSize; i++){\r\n\t\t\tif(board[i] == Box.EMPTY){\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\t\telse{\r\n\t\t\t\tcontinue;\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn true;\r\n\t}", "public static boolean isFull() {\n return (board[0][0] > 0 && board[0][1] > 0 && board[0][2] > 0\n && board[1][0] > 0 && board[1][1] > 0 && board[1][2] > 0\n && board[2][0] > 0 && board[2][1] > 0 && board[2][2] > 0\n && board[0][0] > 0 && board[1][0] > 0 && board[2][0] > 0\n && board[0][1] > 0 && board[1][1] > 0 && board[2][1] > 0\n && board[0][2] > 0 && board[1][2] > 0 && board[2][2] > 0\n && board[0][0] > 0 && board[1][1] > 0 && board[2][2] > 0\n && board[0][2] > 0 && board[1][1] > 0 && board[2][0] > 0);\n }", "public static boolean isBoardFull() {\n\t\treturn spacesLeft == 0;\n\t}", "public boolean isFull ()\n {\n for (int row = 0; row < 3; row++)\n for (int column = 0; column < 3; column++)\n if (getGridElement(row, column).getPlayer() == Player.NONE)\n return false;\n\n return true;\n }", "public boolean isBoardFull() {\n\t\t// REPLACE NEXT LINE WITH YOUR IMPLEMENTATION\n\t\tint boardSize = getBoardSize();\n\t\t\n\t\tfor (int i = 0; i < boardSize; i++) {\n\t\t\t\n\t\t\tfor (int j = 0; j < boardSize; j++) {\n\t\t\t\t\n\t\t\t\tif (isSpotBlank(i,j)) {\n\t\t\t\t\t\n\t\t\t\t\treturn false;\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t}\n\t\treturn true;\n\t\t\n\t}", "public boolean isBoardFull() {\r\n\r\n\t\t\r\n for (int i = 0; i < boardsize; i++) \r\n {\r\n for (int j = 0; j < boardsize; j++) \r\n {\r\n if (board[i][j] == -1) \r\n {\r\n return false;\r\n }\r\n }\r\n }\r\n\t\t\r\n return true;\r\n }", "private boolean full(Board board)\n {\n for (int i = 0; i < size; i++)\n for (int j = 0; j < size; j++)\n if (board.array[i][j] == EMPTY)\n return false;\n return true;\n }", "public boolean isFull() {\n for (int i = 0; i < rows; i++) {\n for (int j = 0; j < cols; j++) {\n if (getBoard()[i][j] == null)\n return false;\n }\n }\n return true;\n }", "public boolean isFullBoard() {\n for(int x= 0; x<4; x++) {\n for(int y= 0; y<4; y++) {\n if(board[x][y]==0) {\n return false;\n }\n }\n }\n return true;\n }", "public synchronized boolean isFull() {\r\n\t\treturn (this.players.size() == 6);\r\n\t}", "private boolean full()\n {\n // Check whether every column is full one by one\n for (int col = 0; col < COLUMNS; col++ )\n {\n // If a column is not full, the check failed\n if (chessBoard[0][col] == 0)\n {\n return false;\n }\n }\n // If all columns are full, the check passes\n return true;\n }", "@Override\n\tpublic boolean boardIsfull() {\n\t\treturn _columnFull.size() == _columnCount;\n\t}", "public boolean isFull() {\n for (int r = 0; r < 6; r++) {\n for (int c = 0; c < 7; c++) {\n if (!hasPiece(r, c)) {\n return false;\n }\n }\n }\n return true;\n }", "public boolean checkIfFull() {\n this.isFull = true;\n for(int i=0; i<this.size; i++) {\n for(int j=0; j<this.size; j++) if(this.state[i][j].isEmpty) this.isFull = false;\n }\n }", "protected static boolean isFull(final Board board)\r\n {\r\n for (int col = 0; col < board.getBoardKey()[0].length; col++)\r\n {\r\n for (int row = 0; row < board.getBoardKey().length; row++)\r\n {\r\n //if there is an empty space return false\r\n if (board.getKey(col, row) == Board.KEY_EMPTY)\r\n return false;\r\n }\r\n }\r\n \r\n //this board is full\r\n return true;\r\n }", "@Override\r\n\t\t\tpublic boolean isFull() {\r\n\t\t\t\tfor(int row = 0; row +1< 6; row++) {\r\n\t\t\t\t\tfor(int col = 0; col < 7; col++) {\r\n\t\t\t\t\t\tString brick = board[row][col].getText().trim();\r\n\t\t\t\t\t\tif(brick.isEmpty()){\r\n\t\t\t\t\t\t\treturn false;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\treturn true;\r\n\t\t\t}", "private boolean isBoardFull() {\n for (int i = 0; i < 3; i++) {\n for (int j = 0; j < 3; j++) {\n if (boardState[i][j] != 'X' && boardState[i][j] != 'O') {\n return false; \n }\n }\n }\n return true; \n }", "public boolean isFull(){\n for(int i=0;i<3;i++){\n for(int j=0;j<3;j++){\n if(!gameBoard[i][j].equals(\"O\") && !gameBoard[i][j].equals(\"X\")){\n return false;\n }\n }\n }\n return true;\n }", "private boolean isFull() {\n for (int i = 0; i < 6; i++)\n for (int j = 0; j < 7; j++)\n if (cell[i][j] == ' ')\n return false; // At least one cell is not filled\n\n // All cells are filled\n return true;\n }", "public boolean isFull() {\n return numMoves == MAX_MOVES;\n }", "public boolean checkBoardFull() {\n for (int i = 0; i < N; i++) {\n for (int j = 0; j < N; j++) {\n if (grid[i][j].getSymbol() == '-')\n return false;\n }\n }\n return true;\n }", "public boolean isFull() {\n\t\tboolean full = true;\n\t\tfor (int i = 0; i < 9; i++) {\n\t\t\tfor (int j = 0; j < 9; j++) {\n\t\t\t\tif (board[i][j] == '-') {\n\t\t\t\t\tfull = false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn full;\n\t}", "public boolean is_full(){\n return this.habitant.size() >= Constantes.HOUSE_FULL;\n }", "@Override\n public boolean isBoardFull() {\n //assume board is full\n boolean isFull = true;\n\n int i = 0;\n try {\n //if a column is not full => the board is not full and the loop ends\n while (isFull && i < NUM_COLS) {\n isFull = isColumnFull(i);\n i++;\n }\n } catch (IllegalColumnException e) {\n System.out.println(e + \" in MyGameState.java Method isBoardFull\");\n }\n\n return isFull;\n }", "public boolean isFull(){\n \treturn count==capacity;\n }", "public boolean isFull() { return false; }", "public boolean isFull() {\n\t\t\n\t\tif (currentOccup < maxOccup)\n\t\t\treturn false;\n\t\telse\n\t\t\treturn true;\n\t}", "public boolean isFull() {\n return count == capacity;\n }", "public boolean is_full()\n\t {\n\t if (num_elements == capacity)\n\t return true;\n\t return false;\n\t }", "public boolean isFull() {\n\t\tfor (int r = 0; r < 3; r++) {\n\t\t\tif (!isRowFull(r)) {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\tover = true;\n\t\treturn true;\n\t}", "public boolean isFull() {\n return (front == 0 && last == capacitySize) ? true : false;\n }", "public boolean isFull(){\n\t\tfor(int i = 0; i < INVENTORY_SLOTS; i++){\n\t\t\tif(inventoryItems[i] == null){\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}", "public boolean isFull() {\n return numOfGoods == cargoSpace;\n }", "public boolean isFull(){\n\t\treturn false;\n\t}", "public boolean isFull() {\r\n\t\treturn false;\r\n\t}", "private static Boolean isFilled() \n\t{\n\t\tfor(Cells[] cellList : board)\n\t\t{\n\t\t\tfor(Cells cell : cellList)\n\t\t\t{\n\t\t\t\tif(cell==Cells.VOID)\n\t\t\t\t{\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}", "public boolean isFull() {\n return false;\n }", "private boolean isBoardFilled() {\n for (char[] y : board) {\n for (char xy : y) {\n if (xy == 0) {\n return false;\n }\n }\n }\n return true;\n }", "public boolean isFull();", "public boolean isFull();", "public boolean isFull();", "public boolean isFull();", "public boolean isFull();", "public boolean isFull();", "public boolean isFull() {\n return (this.count == this.capacity);\n }", "private boolean isFull() {\n\t\treturn (size == bq.length);\n\t}", "public boolean isFull()\r\n\t{\r\n\t\treturn (count == capacity);\r\n\t}", "public boolean isFull() {\n return this.chromosomes.size() >= Defines.popSize;\n }", "public Boolean isFull() {\n\t\tif (this.mVehicles.size() == this.mCapacity)\n\t\t\treturn true;\n\t\telse\n\t\t\treturn false;\n\t}", "private boolean isFull(){\n return cellSize == Max;\n }", "public boolean isFull() {\n if(this.top==(size - 1)) {\n return true;\n }\n return false;\n }", "public boolean isFull() {\n\t\treturn false;\n\t}", "public static boolean fullBoard(){\r\n if(numTurns==42){\r\n return true; //determines if the outcome of the game is a draw\r\n }\r\n return false;\r\n }", "public boolean isFull(int[][] grid) {\n for (int row = 0; row < 9; row++){\n for (int col = 0; col < 9; col++) {\n if (grid[row][col] == 0) return false;\n }\n }\n return true;\n }", "public boolean isEmpty() {\n\t\treturn cards.size() <= 4;\n\t}", "public void testIsFull()\n {\n // An empty board isn't full\n assertFalse(b1.isFull());\n\n // A tied full board\n b1.fromString(\"RBRBRRBRB\");\n assertEquals(b1.checkForTriple(), Cell.EMPTY);\n assertTrue(b1.isFull());\n\n // A generic in progress board\n b1.fromString(\"RRRBEEBBE\");\n assertFalse(b1.isFull());\n\n }", "boolean isFull();", "boolean isFull();", "boolean isFull();", "boolean isFull();", "boolean isFull();", "boolean isFull();", "boolean isFull();", "boolean isFull();", "boolean isFull();", "@Override\n public boolean isFull() {\n return this.count() == 5;\n }", "public boolean isFull() {\n return size == cnt;\n }", "public boolean isFull(int row, int col) {\n return false;\n }", "private boolean isFull() {\n\t\treturn nbmsg==getSize();\n\t}", "public boolean isFull(){\n return this.top==this.maxLength-1;\n }", "public boolean checkWin (int totalPieces){\n\t\treturn isFull();\n\t}", "public boolean isFull() {\n\t\treturn(this.size == this.capacity);\n\t}", "@Override\r\n\tpublic boolean isfull() {\n\t\t\r\n\t\treturn count == size ;\r\n\t}", "public boolean isFull() {\r\n\t\treturn (rear+1)%maxSize==front;\r\n\t}", "public boolean isFull() {\n\t\treturn (rear+1)%total_size == front;\r\n\t}", "public boolean hasEmptySlots() {\n return (numMaxPlayers - activePlayers) != 0;\n }", "private static void checkFreeSpace()\n {\n boolean isSpaceAvailable = false;\n int numOfFreeSpaces = 0;\n for(int index=1;index<board.length;index++)\n {\n if((board[index] == ' '))\n {\n isSpaceAvailable = true;\n numOfFreeSpaces++;\n }\n }\n if(isSpaceAvailable == false)\n {\n System.err.println(\"Board is full! You can't make another move\");\n System.exit(0);\n }\n else\n {\n System.out.println(\"Free space is available! you have \"+numOfFreeSpaces+ \" moves left\");\n }\n }", "public boolean isFull()\r\n\t{\r\n\t\treturn numItems > MAXSIZE;\r\n\t}", "public boolean isFilled(){\n\t\tfor(int i=0;i<size;i++){\n\t\t\tfor(int j=0;j<size;j++){\n\t\t\t\tif(board[i][j] == '\\u0000')\n\t\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}", "public boolean isFull() {\n\t\treturn super.size() == CAPACITY;\n\t}", "public boolean isFull() {\n\t\treturn markCount == 9;\n\t}", "@Override\n public boolean isFull() {\n return false;\n }", "@Override\r\n\tpublic boolean isFull() {\r\n\t\treturn ((front == 0 && rear == MAX_LENGTH - 1) || rear == front - 1);\r\n\t}", "public static boolean inventoryIsFull() {\n\t\treturn Inventory.getCount() == 28;\n\t}", "public boolean isFull() {\n int size = 0;\n for (int i = 0; i < items.length; i++) {\n if (items[i] != null) {\n size++;\n }\n }\n return size == items.length;\n }", "public boolean isFull() {\n\t\treturn numElements==data.length;\n\t}", "@Override\r\n\tpublic boolean isFull() {\r\n\r\n\t\treturn data.size() >= maxQueue;\r\n\t}", "public boolean isFull()\r\n\t\t{\r\n\t\t\tint count = 0;\r\n\t\t\tData currentData = head;\r\n\t\t\twhile (currentData != null)\r\n\t\t\t{\r\n\t\t\t\tcount++;\r\n\t\t\t\tcurrentData = currentData.nextData();\r\n\t\t\t}\r\n\t\t\treturn (count > 2); //if the count is > 2 then it is full\r\n\t\t}", "public boolean checkAllCellsFull() {\n // going over all the matrix cells\n for (int i = 0; i < size; i++) {\n for (int j = 0; j < size; j++) {\n // if there is an empty cell than return false\n if (myMatrix[i][j] == 'E') {\n return false;\n }\n }\n }\n // if all cells are full than return true\n return true;\n }", "public boolean isFull() {\r\n\t\treturn cur_index == size;\r\n\t}", "public static boolean isFull(String[][] ticTacToeBoard) {\n\t\t\n\t\tfor(int i=0; i<3; i++) {\n\t\t\tif(ticTacToeBoard[i][0] != null) {\n\t\t\t\treturn false;\n\t\t\t} else if(ticTacToeBoard[i][1] != null) {\n\t\t\t\treturn false;\n\t\t\t} else if(ticTacToeBoard[i][2] != null) {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn true;\n\t\t\n\t}", "public boolean isRowFull(int r) {\n\t\tfor (int c = 0; c < 3; c++) {\n\t\t\tif (board[r][c] == 0) {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}", "public int isFull(){\n\t\tfor(i = 0; i < blocksPerSet; i++){\n\t\t\tif(blocks[i].getValid() == false)\n\t\t\t\treturn i;\n\t\t}\n\t\treturn -1;\n\t}", "@Override\n public boolean isFull(){\n return (count == size);\n \n }", "public boolean getFull(){\n if(current==max)\n return false;\n return true;\n }", "@Override\n\tpublic boolean isFull() {\n\t\tif(nodeCount == this.MAX_SIZE) return true; \n\t\telse return false;\n\t}", "private boolean isAllFieldsAreFull(){\n\t\tboolean lack = true;\n\t\tif (userNameField.getText().equals(\"\")) {\n\t\t\tlackUserNameLabel.setVisible(true);\t\t\t\t\n\t\t\tlack = false;\n\t\t}\n\t\tif (userLastNameField.getText().equals(\"\")) {\n\t\t\tlackUserLastNameLabel.setVisible(true);\n\t\t\tlack = false;\n\t\t}\n\t\tif (userLoginField.getText().equals(\"\")) {\n\t\t\tlackUserLoginLabel.setText(\"to pole nie może być puste\");\n\t\t\tlackUserLoginLabel.setVisible(true);\n\t\t\tlack = false;\n\t\t}\n\t\t\n\t\tif (userPermissionsBox.getSelectionModel().getSelectedIndex() <= -1) {\n\t\t\tlackUserPermissionsLabel.setVisible(true);\n\t\t\tlack = false;\n\t\t}\n\t\t\n\t\tif ((newUser) || (changePassword)){\n\t\t\tif (userPasswordField.getText().equals(\"\")) {\n\t\t\t\tlackUserPasswordLabel.setVisible(true);\n\t\t\t\tlack = false;\n\t\t\t}\n\t\t\tif (userConfirmPasswordField.getText().equals(\"\")) {\n\t\t\t\tlackUserConfirmPasswordLabel.setText(\"to pole nie może być puste\");\n\t\t\t\tlackUserConfirmPasswordLabel.setVisible(true);\n\t\t\t\tlack = false;\n\t\t\t}\n\t\t}\n\t\treturn lack;\n\t}", "private boolean checkFull() {\n\t\treturn this.array.length - 1 == this.lastNotNull();\n\t}", "public boolean isFull(){ \n return isFull;\n }" ]
[ "0.84006655", "0.7950994", "0.77920204", "0.7707066", "0.76974857", "0.76515895", "0.7638172", "0.760063", "0.75645995", "0.75525886", "0.75465035", "0.751824", "0.7440484", "0.7394994", "0.735912", "0.7331198", "0.73266107", "0.72811633", "0.7268931", "0.7254585", "0.72464514", "0.7182038", "0.7147037", "0.71434855", "0.7134874", "0.7000198", "0.69541866", "0.6936726", "0.6918485", "0.6916851", "0.69151974", "0.6901267", "0.68989134", "0.6891316", "0.688736", "0.6886545", "0.6876583", "0.68738264", "0.68731344", "0.6870875", "0.6870875", "0.6870875", "0.6870875", "0.6870875", "0.6870875", "0.6866928", "0.6858023", "0.6855588", "0.6854943", "0.68351716", "0.6808626", "0.6804757", "0.6791128", "0.6787231", "0.6773897", "0.6768177", "0.6748993", "0.67474604", "0.67474604", "0.67474604", "0.67474604", "0.67474604", "0.67474604", "0.67474604", "0.67474604", "0.67474604", "0.6745932", "0.673411", "0.67307913", "0.6723107", "0.6711709", "0.6706052", "0.6705103", "0.66843337", "0.66826034", "0.66757137", "0.66542715", "0.6648698", "0.6639091", "0.66313636", "0.6619703", "0.66143084", "0.66103125", "0.65847903", "0.65593", "0.6548531", "0.6531771", "0.6517027", "0.6514046", "0.6503552", "0.64998394", "0.6479779", "0.64766836", "0.64690095", "0.6468775", "0.64683634", "0.6456145", "0.6451221", "0.64431", "0.64402974" ]
0.6881456
36
Returns the current State of this field from the board.
public int getState(int row, int col) throws ArrayIndexOutOfBoundsException { return board[row][col]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public GameState getState(){\n\t\tGameState State=new GameState(this.points, this.currentBoard.getState());\n\t\t\n\t\treturn State;\n\t}", "public char[][] getBoardState(){\n\t\treturn board;\n\t}", "public byte getState() {\n return myState;\n }", "public State getState() { return model.getState(); }", "public State getState()\r\n\t{\r\n\t\treturn this.state;\r\n\t}", "public static String[][] getBoardState() {\n return boardState;\n }", "public S getState() {\r\n\t\treturn state;\r\n\t}", "public State getState() {\n return state.get();\n }", "public State getState();", "public State getState();", "public String getState() {\n return this.State;\n }", "public GameState GetState(){\n\t\treturn this.state;\n\t}", "public S getState() {\n return currentState;\n }", "public State getState() {\n\t\treturn state;\n\t}", "public State getState() {\n\t\treturn state;\n\t}", "public STATE getState() {\n\t\n\t\treturn state;\n\t}", "public char[][] getBoardState(){\n return board;\n }", "public GameState getState() {\n\t\treturn state;\n\t}", "public State getState() {\n return state;\n }", "public State getState() {\n return state;\n }", "public State getState() {\n return state;\n }", "public State getState() {\n return state;\n }", "public State getState() {\n return state;\n }", "public String state() {\n return this.state;\n }", "public String state() {\n return this.state;\n }", "@Override\n public String getState() {\n\n if(this.state == null){\n\n this.state = TestDatabase.getInstance().getClientField(token, id, \"state\");\n }\n\n return state;\n }", "public Player getState() {\n\t\treturn state;\n\t}", "public State GetState()\n {\n return this.state;\n }", "public S getCurrentState();", "public Status getStatus() {\n return board.getStatus();\n }", "State getState();", "State getState();", "State getState();", "State getState();", "public String getState() {\n return this.state;\n }", "public String getState() {\n return this.state;\n }", "public String getState() {\n return this.state;\n }", "public String getState() {\n return this.state;\n }", "public String getState()\n\t{\n\t\treturn State;\n\t\t\n\t}", "public Byte getState() {\n return state;\n }", "public Byte getState() {\n return state;\n }", "public State state() {\n return state;\n }", "public STATE getState() {\n return this.lastState;\n }", "public int getState() {\n return this.mState;\n }", "public String getCurrentState() {\n\t\treturn currentState;\n\t}", "public T getState() {\r\n\t\treturn state;\r\n\t}", "public int getState() {\n return state.getValue();\n }", "public int getCurrentState() {\n return myState;\n }", "public String getState() {\n return this.state;\n }", "public String getState() {\n return this.state;\n }", "public String getState()\r\n\t{\r\n\t\treturn state.getModelObjectAsString();\r\n\t}", "public String getState() {\n\t\treturn State;\n\t}", "public String getState() {\n\t\treturn state.toString();\n\t}", "public State getCurrentState() {\n \t\treturn currentState;\n \t}", "public String getState() \n\t{\n\t\treturn state;\n\t}", "@Override\n\tpublic String getState() {\n\t\treturn this.state;\n\t}", "public String getState()\r\n\t{\r\n\t\treturn state;\r\n\t}", "public String getState()\r\n\t{\r\n\t\treturn state;\r\n\t}", "public State state() {\n return _state;\n }", "public final char getState() {\n\t\treturn _state;\n\t}", "public String getState()\n {\n \treturn state;\n }", "public int getState() {\n return mState;\n }", "@Override\n public BattleState getBattleState() {\n return state;\n }", "public int getState()\r\n\t{\r\n\t\treturn currentstate;\r\n\t}", "public String getState() {\r\n\t\treturn state;\t\t\r\n\t}", "public String getState()\n\t{\n\t\treturn state;\n\t}", "public int getState()\n {\n return m_state.getState();\n }", "public State getState () {\n synchronized (this) {\n return state;\n }\n }", "public String getState() {\r\n\t\treturn state;\r\n\t}", "public String getState() {\r\n\t\treturn state;\r\n\t}", "public String getState() {\r\n\t\treturn state;\r\n\t}", "public AeBpelState getState();", "public E getCurrentState() {\n return present;\n }", "public ScanState getState() {\n return state;\n }", "public State getCurrentState() {\n\t\treturn currentState;\n\t}", "public State getCurrentState() {\n\t\treturn currentState;\n\t}", "public String getState() {\n\t\treturn state;\n\t}", "public TState getState() {\n return state;\n }", "public static States getState() {\r\n\t\treturn currentState;\r\n\t}", "public String getState() {\n return state;\n }", "public String getState() {\n return state;\n }", "public String getState() {\n return state;\n }", "public String getState() {\n return state;\n }", "public String getState() {\n return state;\n }", "public String getState() {\n return state;\n }", "public String getState() {\n return state;\n }", "public String getState() {\n return state;\n }", "public String getState() {\n return state;\n }", "public String getState() {\n return state;\n }", "public String getState() {\n return state;\n }", "public String getState() {\n return state;\n }", "public String getState() {\n return state;\n }", "public int getState() {\n return m_state;\n }", "public IState getState();", "@NotNull\r\n State getState();", "protected S state() {\n return state;\n }", "public Integer getaState() {\n return aState;\n }", "public String getState() {\n return state;\n }", "public java.lang.String getState() {\n return State;\n }", "public State getCurrentState() {\n return currentState;\n }", "public MashControlStateE GetState() {\n\n\t\tif (state == stateE.MASHING)\n\t\t{\n\t\t\treturn msc.GetState();\n\t\t}\n\n\t\tif (state == stateE.BOILING)\n\t\t{\n\t\t\treturn bc.GetState();\n\t\t}\n\t\telse\n\t\t\treturn MashControlStateE.DONE;\n\n\t}" ]
[ "0.7095482", "0.70368373", "0.70129454", "0.7012647", "0.69940215", "0.6978201", "0.6920819", "0.69118404", "0.69005924", "0.69005924", "0.68984574", "0.6898185", "0.6885196", "0.68583995", "0.68583995", "0.6845659", "0.6844116", "0.6810825", "0.6807035", "0.6807035", "0.6807035", "0.6807035", "0.6807035", "0.6791688", "0.6791688", "0.6783331", "0.67709345", "0.67659897", "0.67651415", "0.67590874", "0.6729583", "0.6729583", "0.6729583", "0.6729583", "0.67262733", "0.67262733", "0.67262733", "0.67262733", "0.6718061", "0.67068523", "0.67068523", "0.6705913", "0.67048067", "0.67014045", "0.67005914", "0.67001957", "0.66897464", "0.668959", "0.66860735", "0.66860735", "0.6679134", "0.6674447", "0.66632104", "0.666017", "0.6659271", "0.66549945", "0.66515195", "0.66515195", "0.66471744", "0.66396075", "0.6638256", "0.6633757", "0.6629914", "0.6627305", "0.6625107", "0.6622998", "0.6608413", "0.66072655", "0.65989196", "0.65989196", "0.65989196", "0.6593123", "0.65928733", "0.6587929", "0.6587172", "0.6587172", "0.6580232", "0.6579562", "0.6575829", "0.6572462", "0.6572462", "0.6572462", "0.6572462", "0.6572462", "0.6572462", "0.6572462", "0.6572462", "0.6572462", "0.6572462", "0.6572462", "0.6572462", "0.6572462", "0.65723896", "0.6570794", "0.6560168", "0.6559678", "0.6549344", "0.6547613", "0.65471697", "0.6541674", "0.6533743" ]
0.0
-1
Sets the state of this field from the board to the current player's index.
public void setState(int row, int col) throws ArrayIndexOutOfBoundsException { board[row][col] = currentPlayer; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void setCurrentPlayer(int index){\n this.currentPlayer=index%4;\n }", "public void setMoveIndex(int index) {\n\n boardIterator.goTo(index);\n\n queueEvent(new Runnable() {\n @Override\n public void run() {\n board.setBoard(boardIterator.board);\n }\n });\n\n autoFollow = index == game.getHistory().getNumBoardCommands() - 1;\n canPlay = true; // always true because animation will no longer be in progress.\n\n updateHighlights();\n\n if(listener != null)\n listener.onBoardStateChanged(this);\n }", "public void setIndexNextBoard(int index) throws IllegalArgumentException;", "public void setCurrPlayer(int i) {\n if (currPlayer == -1) {\n currPlayer = i;\n }\n }", "public void setIndex(int index) { this.index = index; }", "private void setIndex(int index){\n\t\tthis.index = index;\n\t}", "public void setIndex(int index) {\n _index = index;\n }", "public void setIndex(int index){\r\n \tthis.index = index;\r\n }", "private void setComponentsOfIndex() {\n\t\tint t = this.numbersIdex + 1;\n\t\tif (t == NUMBEROFEACHCARD) {\n\t\t\tthis.numbersIdex = 0;\n\t\t\tsetColorIndex();\n\t\t} else {\n\t\t\tthis.numbersIdex = t;\n\t\t}\n\t}", "public void setIndex(int index)\n/* */ {\n/* 39 */ this.index = index;\n/* */ }", "void changeSetting(int idx) {\n currentIdx = idx;\n }", "public void setHolder(int pIndex) {\n this.pIndex = pIndex;\n }", "public void setBoardLocation(int boardLocation) {this.boardLocation = boardLocation;}", "public void set(long index);", "void setIdx(int i);", "public void setIndex(int index){\n\t\tthis.index = index;\n\t}", "public void setPlayerPosition() throws IOException\r\n\t{\r\n\t\tboolean flag = false;\r\n\t\t\r\n\t\tint X = 0;\r\n\t\tint Y = 0;\r\n\t\t\r\n\t\twhile(flag == false)\r\n\t\t{\r\n\t\t\toStream.writeInt(X);\r\n\t\t\toStream.writeInt(Y);\r\n\t\t\tflag = iStream.readBoolean();\r\n\t\t\tX++;\r\n\t\t\tY++;\r\n\t\t}\r\n\t\tboard.makePlayer(X-1, Y-1);\r\n\t}", "public void setIndex(int i){\n\t\tthis.index = i;\r\n\t}", "public void setIndex(int ind){\n\t\tindex = ind;\n\t}", "private void increaseCurrentPlayerIndex() {\n\t\tcurrentPlayer++;\n\t\tif(currentPlayer>3)\n\t\t\tcurrentPlayer=0;\n\t}", "public abstract void setIndex(int i, boolean b);", "@Override\n\tpublic void setValueIndex(int index) {\n\t\t\n\t}", "public void setIndex(int index) {\r\n this.index = index;\r\n }", "public void setPos(int pos);", "public void setPos(int pos);", "public void changePlayer(int index) {\n currentPlayer.setText(\"Aktueller Spieler: \" + index);\n if(index == 1){\n pointsPlayer2.setOpaque(false);\n pointsPlayer1.setBackground(Color.green);\n pointsPlayer1.setOpaque(true);\n this.repaint();\n }\n else{\n pointsPlayer1.setOpaque(false);\n pointsPlayer2.setBackground(Color.green);\n pointsPlayer2.setOpaque(true);\n this.repaint();\n }\n }", "public void setCurrentPlayerIs(int currentPlayerInt){\n\t\tcurrentPlayerIs = currentPlayerInt;\n\t\trepaint();\n\t}", "public void setState(Player player) {\n\t\tstate = player;\n\t\tstateChanged();\n\t}", "public void set(int rowIndex, int columnIndex, int value) { target.set(index.get(rowIndex), columnIndex, value); }", "public void setPosition(int position);", "protected void setIndex(int index) {\n\t\tthis.index = index;\n\t}", "public void setCurrentCell(\n\t\t\tint index )\n\t{\n\t}", "public void setState(int i) {\n this.mState = i;\n }", "public void setIndex(Integer index) {\n this.index = index;\n }", "public void setIndex(Integer index) {\n this.index = index;\n }", "public void setIndex(int i) {\n\t\t\n\t}", "public void toggleChosenState(int index) {\n\n for (int i = 0; i < cells.size(); i++) {\n if (cells.get(i) == CellState.Chosen) {\n cells.set(i, CellState.Tower);\n }\n }\n cells.set(index, CellState.Chosen);\n }", "private void setFormedIndex() {\n\t\tint t = this.formeIndex + 1;\n\t\tif (t == NUMBEROFEACHCARD) {\n\t\t\tsetFillIndex();\n\t\t\tthis.formeIndex = 0;\n\t\t} else {\n\t\t\tthis.formeIndex = t;\n\t\t}\n\n\t}", "public void setIndex(int value) {\n\t\tthis.index = value;\r\n\t}", "public void setFieldIndex(final int fieldIndex) { _fldIndex = fieldIndex; }", "public void setCurrent(ServerPlayer p) {\n\t\tthis.current = p;\n\t}", "public int getCurrentPlayerIndex(){\r\n return currentPlayerIndex;\r\n }", "public void setPosition(){\r\n currentPosition = 0; \r\n }", "public void setIdx(Integer idx) {\r\n\t\tthis.idx = idx;\r\n\t}", "public final int getPlayerIndex() {\r\n return this.playerIndex;\r\n }", "public void setCurrentPlayer(Player P){\n this.currentPlayer = P;\n }", "public void setIndex(int value) {\n this.index = value;\n }", "public static int currentPlayerIndex() {\n return turn-1;\n }", "public void updateCurrentSongIndex(int index) {\n\t\tthis.currentSongIndex = index;\n\t}", "private void changeCurrentPlayer() {\n switch (currentPlayer) {\n case 0: currentPlayer = 1;\n return;\n default: currentPlayer = 0;\n return;\n }\n }", "public void setPlayerPosition(CellView playerPosition) {\n this.playerPosition = playerPosition;\n }", "public void setIndex(int value) {\n\t\tthis.index = value;\n\t}", "public void setBoard(Board board){this.board = board;}", "void setColumnIndex(int newIndex);", "public void set(int pos);", "public void setBoard() {\n bestPieceToMove = null;\n bestPieceFound = false;\n bestMoveDirectionX = 0;\n bestMoveDirectionY = 0;\n bestMoveFound = false;\n killAvailable = false;\n lightCounter = 12;\n darkCounter = 12;\n for (int y = 0; y < boardSize; y++) {\n for (int x = 0; x < boardSize; x++) {\n board[y][x] = new Field(x, y);\n if (y < 3 && board[y][x].getPlaceable()) {\n board[y][x].setPiece(new Piece(PieceColor.DARK, PieceType.MEN));\n } else if (y > 4 && board[y][x].getPlaceable()) {\n board[y][x].setPiece(new Piece(PieceColor.LIGHT, PieceType.MEN));\n }\n }\n }\n }", "@Override\n\tpublic void setTeam(int i) {\n\t\t\n\t}", "public void setState(GameState aState){\n\t\tpoints=aState.getScore();\n\t\tcurrentBoard.setState(aState.getBoardState());\n\t}", "public int setCurrentState(int[][] state) {\n\t\tfor (int i = 0; i < 9; i++) {\n\t\t\tfor (int j = 0; j < 9; j++) {\n\t\t\t\tthis.currentState[i][j] = state[i][j];\n\t\t\t}\n\t\t}\n\n\t\treturn 0;\n\t}", "public void move() {\n\t\tif ( board.getLevel() == 5 )\n\t\t\tmovementIndex = ( movementIndex + 1 ) % movement.length;\n\t}", "public void setPlayer(int row, int col, int value) {\n\t\tplayer[row][col] = value;\n\t}", "public void toggle() {\n if (currentPlayer.equals(\"red\")) {\n currentColor = BLUE_COLOUR;\n currentPlayer = \"blue\";\n } else {\n currentColor = RED_COLOUR;\n currentPlayer = \"red\";\n }\n //change color of grid\n changeColor();\n }", "public void setWormColorIndex( final int wormColorIndex ) throws RemoteException {\r\n playerState.wormColorIndex = wormColorIndex;\r\n }", "public int setIndex(int index) {\n\t\tthis.openIndex = index;\r\n\t\treturn index;\r\n\t}", "@Override\n\tpublic void setLED(int index, boolean state) throws emException, TException {\n\n\t}", "private void setCurrentPos() {\n\t\tcurrentPos=layout_Circle[l.y][l.x];\n\t\tcurrentPos.setFill(Paint.valueOf(\"Red\"));\n\n\t\tsetValidMoves();\n\t}", "public void setPos(int index, int value) {\r\n this.pos[index] = value;\r\n }", "public void setPosition(Integer position);", "public void setOnline(int pos){\n }", "private void changeCurIndex() {\n\t\tint TexID=-1;\r\n\t\tif(ApplicationInfo.Destination == Constants.TO_FRONT)\r\n\t\t{\r\n\t\t\tCurIndex=++CurIndex >= mApplications.size()? 0 : CurIndex;\r\n\t\t\tif((TexID=mApplications.get(getPreIndex()).getReady()) != -1)\r\n\t\t\t\tunSetTexID(TexID);\r\n \t\t\tmApplications.get(getPreIndex()).setReady(-1);\r\n\t\t}\r\n\t\telse if(ApplicationInfo.Destination == Constants.TO_BACK)\r\n\t\t{\r\n\t\t\tCurIndex=--CurIndex < 0? mApplications.size()-1 : CurIndex;\r\n\t\t\tif((TexID=mApplications.get(getNextIndex()).getReady()) != -1)\r\n\t\t\t\tunSetTexID(TexID);\r\n\t\t\tmApplications.get(getNextIndex()).setReady(-1);\r\n\t\t}\r\n\t\tLog.d(TAG, \"changeCurIndex :\"+CurIndex);\r\n\t}", "@Override\r\n\tpublic void setPlayerToTradeWith(int playerIndex) {\n\t\t\r\n\t}", "public void setStartingStudent(int playerIndex) {\n startingPlayer = playerIndex;\n }", "public void setStateOfMovement(int movementState){stateOfMovement = movementState; }", "public void set(int index, int o) {\n\t\tif(index == 0) return;\n\t\tr[index] = o;\n\t}", "public void setMove(int hash, Player player) {\n board[hash] = player;\n numMoves++;\n }", "void setColumnIndex(int index);", "public void setBoard(int[][] board) {\n this.board = board;\n }", "public void UpdatePushIndex() {\n\t\tsetorgetState(true,false);\n\t}", "public Builder setIndex(int value) {\n \n index_ = value;\n onChanged();\n return this;\n }", "public Builder setIndex(int value) {\n\n index_ = value;\n onChanged();\n return this;\n }", "public Builder setIndex(int value) {\n\n index_ = value;\n onChanged();\n return this;\n }", "public Builder setIndex(int value) {\n\n index_ = value;\n onChanged();\n return this;\n }", "public void setIndex(int rowOrCol) {\n index = rowOrCol;\n }", "@Override\n public void setLayer(int index, BoardLayerView layer) {\n this.layers.set(index, layer);\n }", "public void setCurrentPosition(int value) {\n this.currentPosition = value;\n }", "public void setCellState(int newState) {\n this.myState = newState;\n }", "public void setTurned(int index, boolean val){\n if (val == true) {\n if (selectedOption == 1) {\n if(cards.get(index).getNumber() == 1){\n cards.get(index).getPanel().setBorder(BorderFactory.createBevelBorder(1, Color.red, Color.blue));\n }\n cards.get(index).getPanel().setIcon(new ImageIcon(new ImageIcon(getClass().getResource(cards.get(index).getImgAnime())).getImage().getScaledInstance(cards.get(index).getPanel().getWidth(), cards.get(index).getPanel().getHeight(), Image.SCALE_SMOOTH)));\n } else {\n if (cards.get(index).getNumber() == 1) {\n cards.get(index).getPanel().setBorder(BorderFactory.createBevelBorder(1, Color.red, Color.blue));\n cards.get(index).getPanel().setIcon(new ImageIcon(new ImageIcon(getClass().getResource(cards.get(index).getImgAnime())).getImage().getScaledInstance(cards.get(index).getPanel().getWidth(), cards.get(index).getPanel().getHeight(), Image.SCALE_SMOOTH)));\n } else {\n cards.get(index).getPanel().setBackground(cards.get(index).getColor());\n cards.get(index).getPanel().setIcon(null);\n }\n }\n cards.get(index).setTurned(true);\n }\n if (val == false) {\n cards.get(index).getPanel().setIcon(new ImageIcon(new ImageIcon(getClass().getResource(\"img/Memory.png\")).getImage().getScaledInstance(cards.get(index).getPanel().getWidth(), cards.get(index).getPanel().getHeight(), Image.SCALE_SMOOTH)));\n cards.get(index).setTurned(false);\n cards.get(index).getPanel().setBorder(UIManager.getBorder(\"Button.border\"));\n }\n }", "void setBit(int index, int value);", "public abstract void updateIndex();", "public void reset() {\n\t\t//reset player to 0\n\t\tplayer = 0;\n\t\t\n\t\tfor(int row = size - 1; row >= 0; row --)\n\t\t\tfor(int col = 0; col < size; col ++)\n\t\t\t\tfor(int dep = 0; dep < size; dep ++)\n\t\t\t\t\t//goes through all board positions and sets to -1\n\t\t\t\t\tboard[row][col][dep] = -1;\n\t}", "public void setState(PlayerState state) {\n this.state = state;\n }", "@Override\r\n\tpublic void setBoard(Board board) {\n\t\t\r\n\t}", "public void setIndex(int index) {\r\n this.textIndex = index;\r\n }", "public void setSyncIndex(int index) {\n }", "public void setPlayersAtGo()\n {\n for(int i = 0; i < m_numPlayers; i++)\n {\n m_gameBoard.addPlayerToSpace(i + 1, 0);\n }\n }", "public void setIndex (int i){\n putValue(Action.NAME, i + \" \" + mDisplayName);\n putValue(Action.MNEMONIC_KEY, new Integer(Integer.toString(i).charAt(0)));\n }", "public void setPlayer(Player player) {\n this.currentPlayer = player;\n }", "void setIndexed(boolean indexed);", "public void setIndx(int indx){\n this.indx = indx;\n }", "public void setState(int i, int j, int val){\r\n this.state[i][j] = val;\r\n }" ]
[ "0.689618", "0.6423136", "0.6202302", "0.6190721", "0.61633897", "0.6069783", "0.60198486", "0.6012066", "0.600109", "0.5997539", "0.5936513", "0.59186083", "0.58927643", "0.58846444", "0.58840775", "0.5846299", "0.5844976", "0.5836734", "0.58167267", "0.5783228", "0.5760778", "0.57537574", "0.57421124", "0.57212484", "0.57212484", "0.5710265", "0.5707377", "0.5705178", "0.56723034", "0.5666434", "0.5658207", "0.5632316", "0.5622967", "0.5619155", "0.5619155", "0.5619153", "0.56063116", "0.56056935", "0.56013435", "0.55958325", "0.5594883", "0.5584555", "0.556781", "0.55671513", "0.5565017", "0.5547229", "0.5533549", "0.5517928", "0.5502972", "0.5486243", "0.5482054", "0.5470015", "0.546927", "0.54651856", "0.54631966", "0.54612976", "0.54537857", "0.5440951", "0.5426739", "0.54141194", "0.54093546", "0.54082555", "0.54059213", "0.53968686", "0.5395433", "0.53949755", "0.5392299", "0.53916186", "0.53875124", "0.53751457", "0.537469", "0.53503525", "0.5346495", "0.53459394", "0.53422403", "0.53304684", "0.53299886", "0.532222", "0.5316342", "0.5312677", "0.5312677", "0.5312677", "0.5309793", "0.5308422", "0.53053755", "0.52982897", "0.5287984", "0.5270772", "0.5268213", "0.52662134", "0.5263846", "0.52573514", "0.5247071", "0.52373534", "0.5236841", "0.5236231", "0.52349985", "0.52326006", "0.5220587", "0.5216701" ]
0.674406
1
Returns a string representation of a single state of a field on the board.
public String stateToString(int row, int col) { if (!isValid(row, col)) { return INDEX_ERROR_MESSAGE; } else if (!isFree(row, col)) { return "P" + getState(row, col); } return "**"; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public String toString() {\r\n\t\treturn (\"State: \" + this.key + \", Value: \" + this.val);\r\n\t}", "@Override\r\n\tpublic String toString()\r\n\t{\r\n\t\treturn state.toString();\r\n\t}", "public String toString(){\n \tif(state){\n\t\treturn (\"1\");\n\t }\n\t else{\n\t\t return(\"0\");\n\t }\n }", "public String dumpState() {\n StringBuilder out = new StringBuilder();\n out.append(currentPlayer);\n for (int i = 0; i < board.length; ++i)\n out.append(\" \" + board[i]);\n\n return out.toString();\n }", "@Override\n public String toString()\n {\n return state.toString();\n }", "java.lang.String getState();", "public String getStateString()\r\n\t{\r\n\t\treturn stateString;\r\n\t}", "public String getStateString()\n {\n return stateString;\n }", "public String getState() {\n\t\treturn state.toString();\n\t}", "public String toString() {\r\n\t\treturn gameState;\r\n\t}", "public String getState() {\r\n StringBuilder builder = new StringBuilder();\r\n builder.append(mLastLarge);\r\n builder.append(',');\r\n builder.append(mLastSmall);\r\n builder.append(',');\r\n for (int large = 0; large < 9; large++) {\r\n for (int small = 0; small < 9; small++) {\r\n builder.append(mSmallTiles[large][small].getOwner().name());\r\n builder.append(',');\r\n }\r\n }\r\n return builder.toString();\r\n }", "public java.lang.String getState() {\n java.lang.Object ref = state_;\n if (ref instanceof java.lang.String) {\n return (java.lang.String) ref;\n } else {\n com.google.protobuf.ByteString bs = \n (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n if (bs.isValidUtf8()) {\n state_ = s;\n }\n return s;\n }\n }", "public String state() {\n\treturn state(points, temperature, currentStateEnergy);\n }", "public java.lang.String getState() {\n java.lang.Object ref = state_;\n if (!(ref instanceof java.lang.String)) {\n java.lang.String s = ((com.google.protobuf.ByteString) ref)\n .toStringUtf8();\n state_ = s;\n return s;\n } else {\n return (java.lang.String) ref;\n }\n }", "public String toString() {\n\tStringBuffer buffer = new StringBuffer();\n\t//\tbuffer.append(\" 6 5 4 3 2 1 \\n\");\n\tbuffer.append(\"+---------------------------------------+\\n\");\n\t\n\tbuffer.append(\"| |\");\n\tfor (int i = 12; i >= 7; --i) {\n\t buffer.append(toString(state[i]));\n\t}\n\tbuffer.append(\" |\\n\");\n\t\n\tbuffer.append(\"|\");\n\tbuffer.append(toString(state[13]));\n\tbuffer.append(\"-----------------------------|\");\n\tbuffer.append(toString(state[6]));\n\tbuffer.append(\"\\n\");\n\t\n\tbuffer.append(\"| |\");\n\tfor (int i = 0; i <= 5; ++i) {\n\t buffer.append(toString(state[i]));\n\t}\n\tbuffer.append(\" |\\n\");\n\t\n\tbuffer.append(\"+---------------------------------------+\\n\");\n\tbuffer.append(\" 0 1 2 3 4 5 \\n\");\n\t\n\treturn buffer.toString();\n }", "String getState();", "String getState();", "String getState();", "public String toString()\n\t{\n\n\t\treturn String.format(City+\",\"+State);\n\n\t}", "public String getStateOfBoard()\n {\n // This function is used to print state of the board. such as number of coins present on the board\n String str=\"\";\n str += \"Black_Coins Count:\"+this.gameController.getCoinsCount(CoinType.BLACK) +\" Red_Coins Count:\"+this.gameController.getCoinsCount(CoinType.RED);\n return str;\n }", "public String toString()\n\t{\n\t\treturn fieldname;\n\t}", "public String toString()\n {\n return m_strFieldName;\n }", "public String getStateAsString() {\n return storeStateIntoString();\n }", "public String toString()\n\t{\n\t\treturn \"tag = \" + Integer.toHexString (myTag) + \" MesiState = \" + myMesiState;\n\n\t}", "@AutoEscape\n\tpublic String getState();", "@Override\n public String toString() {\n // | <M,C,B> |\n // | Depth = d |\n // -----------\n return \"\\n ----------- \\n\" + \"| <\" + this.state[0] + \",\" + this.state[1] + \",\" + this.state[2] + \"> |\\n\"\n + \"| Depth = \" + this.depth + \" |\\n\" + \" ----------- \\n\";\n }", "@Override\n public String toString() {\n String fieldStr = getTag() + \"=\" + getTagVal();\n return fieldStr;\n }", "public String getPlayerState() {\n String playerState = name + \" \" + actionArray[0] \n + \" \" + actionArray[1] + \" \" + actionArray[2] + \" \" + colorID + \" \";\n return playerState;\n }", "public String state() {\n return this.state;\n }", "public String state() {\n return this.state;\n }", "public java.lang.String getStateMessage() {\n java.lang.Object ref = stateMessage_;\n if (!(ref instanceof java.lang.String)) {\n com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n stateMessage_ = s;\n return s;\n } else {\n return (java.lang.String) ref;\n }\n }", "public String toString() {\n\t\t//TODO add your own field name here\t\t\n\t\t//return buffer.append(this.yourFieldName).toString();\n\t\treturn \"\";\n\t}", "public java.lang.String getState() {\r\n return state;\r\n }", "public java.lang.String getState() {\n return state;\n }", "public java.lang.String getState() {\n return state;\n }", "@Override\n public String toString() {\n StringBuilder sb = new StringBuilder();\n sb.append(\"{\");\n if (getState() != null)\n sb.append(\"State: \").append(getState()).append(\",\");\n if (getStateReason() != null)\n sb.append(\"StateReason: \").append(getStateReason()).append(\",\");\n if (getStateReasonCode() != null)\n sb.append(\"StateReasonCode: \").append(getStateReasonCode());\n sb.append(\"}\");\n return sb.toString();\n }", "String getField();", "@Output\n public String getState() {\n return state;\n }", "public String printState(){\n if (this.state.equals(\"unstarted\")) return \"unstarted 0\";\n\n else if (this.state.equals(\"terminated\")) return \"terminated 0\";\n else if (this.state.equals(\"blocked\")) {\n return String.format(\"blocked %d\", ioBurstTime);\n }\n else if (this.state.equals(\"ready\")) {\n if (remainingCPUBurstTime !=null){\n return String.format(\"ready %d\", remainingCPUBurstTime);\n }\n return \"ready 0\";\n }\n\n else if (this.state.equals(\"running\")){\n return String.format(\"running %d\", cpuBurstTime);\n }\n\n else return \"Something went wrong.\";\n }", "public String getState() { return state; }", "@Override\n\tpublic String toString(){\n\t\treturn \"com.jcdeck.adversary.State Turn: \"+this.getTurn()+\" Depth: \"+this.depth;\n\t}", "public String getState()\r\n\t{\r\n\t\treturn state.getModelObjectAsString();\r\n\t}", "public String toString() {\n\t\treturn \"PushObstacleState\";\n\t}", "public String getState() \n\t{\n\t\treturn state;\n\t}", "@Override\n public String toString() {\n StringBuilder result = new StringBuilder();\n for (int i = 0; i < 3; i++) {\n for (int j = 0; j < 3; j++) {\n int cell = field[i][j];\n result.append(cell == 0 ? \"_\" : (cell == 1 ? \"X\" : \"O\")).append(\" \");\n }\n result.append(\"\\n\");\n }\n return result.toString();\n }", "public String toString() {\r\n return \"Zip: \" + getZip() +\r\n \" City: \" + getCity() +\r\n \" State: \" + getState();\r\n }", "public String getState()\n {\n \treturn state;\n }", "@Override\n\tpublic String toString()\n\t{\n\t\tStringBuilder stringBuilder = new StringBuilder();\n\t\tfor (int i = 0; i < 2 * size + 1; i++)\n\t\t{\n\t\t\tstringBuilder.append(\"-\");\n\t\t}\n\t\tstringBuilder.append(\"\\n|\");\n\t\tfor (int i = 0; i < state.size(); i++)\n\t\t{\n\t\t\tstringBuilder.append(state.get(i)).append(\"|\");\n\t\t\tif (i % size == size - 1 && i < state.size() - 1)\n\t\t\t{\n\t\t\t\tstringBuilder.append(\"\\n|\");\n\t\t\t}\n\t\t}\n\t\tstringBuilder.append(\"\\n\");\n\t\tfor (int i = 0; i < 2 * size + 1; i++)\n\t\t{\n\t\t\tstringBuilder.append(\"-\");\n\t\t}\n\t\treturn stringBuilder.toString();\n\t}", "public String getState()\r\n\t{\r\n\t\treturn state;\r\n\t}", "public String getState()\r\n\t{\r\n\t\treturn state;\r\n\t}", "public String getState() {\n return state;\n }", "public FieldEnumString(List<PropertyModel> fields) {\n final StringBuilder sb = new StringBuilder(128);\n for (PropertyModel mappedField : fields) {\n if (sb.length() > 0) {\n sb.append(\", \");\n }\n sb.append(mappedField.getMappedName());\n }\n display = sb.toString();\n }", "public java.lang.String getState() {\n return State;\n }", "public String getState() {\n\t\treturn this.state_rep;\n\t}", "public String getState(){\n return state;\n }", "@java.lang.Override\n public java.lang.String getStateMessage() {\n java.lang.Object ref = stateMessage_;\n if (ref instanceof java.lang.String) {\n return (java.lang.String) ref;\n } else {\n com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n stateMessage_ = s;\n return s;\n }\n }", "public String getState()\n\t{\n\t\treturn state;\n\t}", "public String getState() {\n return this.state;\n }", "public String getState() {\n return this.state;\n }", "public String getState() {\n return this.state;\n }", "public String getState() {\n return this.state;\n }", "public String getState() {\n return state;\n }", "public String getState() {\n return state;\n }", "public String getState() {\n return state;\n }", "public String getState() {\n return state;\n }", "public String getState() {\n return state;\n }", "public String getState() {\n return state;\n }", "public String getState() {\n return state;\n }", "public String getState() {\n return state;\n }", "public String getState() {\n return state;\n }", "public String getState() {\n return state;\n }", "public String getState() {\n return state;\n }", "public String getState() {\n return state;\n }", "public String getState() {\n return state;\n }", "public java.lang.String getSqlState() {\n java.lang.Object ref = sqlState_;\n if (!(ref instanceof java.lang.String)) {\n com.google.protobuf.ByteString bs =\n (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n sqlState_ = s;\n return s;\n } else {\n return (java.lang.String) ref;\n }\n }", "public String getState() {\n return this.state;\n }", "public String getState() {\n return this.state;\n }", "public String getState() {\r\n\t\treturn state;\t\t\r\n\t}", "public String toString() {\n\treturn state.toString() + \" \" + context.toString();\n }", "public String getState() {\n return this.State;\n }", "@Override\n\tpublic String getState() {\n\t\treturn this.state;\n\t}", "public java.lang.String getState () {\n\t\treturn state;\n\t}", "public String getState() {\r\n\t\treturn state;\r\n\t}", "public String getState() {\r\n\t\treturn state;\r\n\t}", "public String getState() {\r\n\t\treturn state;\r\n\t}", "public String stateToCheckerboardString(int paraState) {\n\t\tint[][] tempCheckerboard = stateToCheckerboard(paraState);\n\t\tString resultString = \"\\r\\n\";\n\t\t//resultString += \"Checkerboard state: \\r\\n\";\n\t\tfor (int i = 0; i < tempCheckerboard.length; i++) {\n\t\t\tfor (int j = 0; j < tempCheckerboard[0].length; j++) {\n\t\t\t\tif (tempCheckerboard[i][j] == WHITE) {\n\t\t\t\t\tresultString += \"o \";\n\t\t\t\t} else if (tempCheckerboard[i][j] == BLACK) {\n\t\t\t\t\tresultString += \"x \";\n\t\t\t\t} else {\n\t\t\t\t\tresultString += \"- \";\n\t\t\t\t}//Of if\n\t\t\t}//Of for j\n\t\t\tresultString += \"\\r\\n\";\n\t\t}//Of for i\n\t\t\n\t\t//resultString += currentState;\n\t\treturn resultString;\n\t}", "public String getState() {\n\t\treturn state;\n\t}", "public String getState() {\n StringBuilder builder = new StringBuilder();\n //builder.append(muteMusic.getBackground().getLevel());\n //builder.append(',');\n builder.append(muteClicked);\n builder.append(',');\n builder.append(gameOver);\n builder.append(',');\n builder.append(wordsDetectedByUser.size());\n builder.append(',');\n for(int i =0;i<wordsDetectedByUser.size();i++)\n { builder.append(wordsDetectedByUser.get(i));\n builder.append(',');}\n builder.append(notValidWord);\n builder.append(',');\n // m1Handler.removeCallbacks(m1Runnable);\n mHandler.removeCallbacks(mRunnable);\n builder.append(phaseTwo);\n builder.append(',');\n builder.append(currentScore); //storing current score\n builder.append(',');\n builder.append(t); //storing timer state\n builder.append(',');\n Object a[] = DoneTiles.toArray();\n builder.append(a.length);\n builder.append(',');\n for(int i=0;i<a.length;i++) {\n builder.append(a[i].toString());\n builder.append(',');\n }\n builder.append(mLastLarge);\n builder.append(',');\n builder.append(mLastSmall);\n builder.append(',');\n for (int large = 0; large < 9; large++) {\n for (int small = 0; small < 9; small++) {\n builder.append(mSmallTiles[large][small].getOwner().name());\n builder.append(',');\n builder.append((((Button)mSmallTiles[large][small].getView()).getText()).toString());\n builder.append(',');\n //Log.d(DoneTiles);\n }\n }\n return builder.toString();\n }", "@Override\n public String toString ()\n {\n StringBuffer buffer = new StringBuffer();\n for (State value : stateMap.values()) {\n buffer.append(value.toString());\n buffer.append(\"\\n\");\n }\n return buffer.toString();\n }", "public String toString() {\n PrintfFormat str = new PrintfFormat();\n\n str.append (\"The current state of the MRG32k3a\");\n if (name != null && name.length() > 0)\n str.append (\" \" + name);\n str.append (\":\" + PrintfFormat.NEWLINE + \" Cg = { \");\n str.append ((long) Cg0 + \", \");\n str.append ((long) Cg1 + \", \");\n str.append ((long) Cg2 + \", \");\n str.append ((long) Cg3 + \", \");\n str.append ((long) Cg4 + \", \");\n str.append ((long) Cg5 + \" }\" + PrintfFormat.NEWLINE +\n PrintfFormat.NEWLINE);\n\n return str.toString();\n }", "public java.lang.String getSqlState() {\n java.lang.Object ref = sqlState_;\n if (ref instanceof java.lang.String) {\n return (java.lang.String) ref;\n } else {\n com.google.protobuf.ByteString bs = \n (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n sqlState_ = s;\n return s;\n }\n }", "public String warStateToString() {\n StringBuilder s = new StringBuilder();\n\n if (aggressor instanceof Nation) {\n s.append(((Nation) aggressor).getName());\n } else if (aggressor instanceof Town) {\n s.append(((Town) aggressor).getName());\n }\n\n s.append(\" \");\n\n if (defender instanceof Nation) {\n s.append(((Nation) defender).getName());\n } else if (defender instanceof Town) {\n s.append(((Town) defender).getName());\n }\n\n s.append(\" \");\n\n s.append(aggressorPoints).append(\" \");\n s.append(defenderPoints).append(\" \");\n\n for (Town town : towns.keySet()) {\n s.append(town.getName()).append(\" \");\n s.append(towns.get(town)).append(\" \");\n }\n\n if (rebelwar != null)\n s.append(\" \").append(rebelwar.getName());\n else\n s.append(\" \" + \"n u l l\");\n\n return s.toString();\n }", "public java.lang.String getField1334() {\n java.lang.Object ref = field1334_;\n if (!(ref instanceof java.lang.String)) {\n com.google.protobuf.ByteString bs =\n (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n field1334_ = s;\n return s;\n } else {\n return (java.lang.String) ref;\n }\n }", "public java.lang.String getField1334() {\n java.lang.Object ref = field1334_;\n if (ref instanceof java.lang.String) {\n return (java.lang.String) ref;\n } else {\n com.google.protobuf.ByteString bs = \n (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n field1334_ = s;\n return s;\n }\n }", "@Override\n\tpublic String getStateString() {\n\t\treturn null;\n\t}", "public String fieldIdToString() {\r\n\t\treturn new String(String.format(\"%02d\", getID()));\r\n\t}", "java.lang.String getField1764();", "public String getState()\n\t{\n\t\treturn State;\n\t\t\n\t}", "@Override\n public String getState() {\n\n if(this.state == null){\n\n this.state = TestDatabase.getInstance().getClientField(token, id, \"state\");\n }\n\n return state;\n }", "public String toString() {\n\t\tString resultString = \"\\r\\n\";\n\t\t//resultString += \"Checkerboard state: \\r\\n\";\n\t\tfor (int i = 0; i < checkerboard.length; i++) {\n\t\t\tfor (int j = 0; j < checkerboard.length; j++) {\n\t\t\t\tif (checkerboard[i][j] == WHITE) {\n\t\t\t\t\tresultString += \"o \";\n\t\t\t\t} else if (checkerboard[i][j] == BLACK) {\n\t\t\t\t\tresultString += \"x \";\n\t\t\t\t} else {\n\t\t\t\t\tresultString += \"- \";\n\t\t\t\t}//Of if\n\t\t\t}//Of for j\n\t\t\tresultString += \"\\r\\n\";\n\t\t}//Of for i\n\t\t\n\t\tresultString += currentState;\n\n\t\t//resultString += \"\\r\\nThe current situation is: \" + gameSituation;\n\t\treturn resultString;\n\t}" ]
[ "0.6700563", "0.66590697", "0.6589543", "0.6580903", "0.65000945", "0.63895786", "0.6330892", "0.63284177", "0.632788", "0.6321674", "0.62663335", "0.625622", "0.6220556", "0.6214642", "0.6211003", "0.61994267", "0.61994267", "0.61994267", "0.6196023", "0.6166093", "0.6151257", "0.61233217", "0.6117562", "0.61166286", "0.6051179", "0.6016266", "0.6003661", "0.59856963", "0.59685075", "0.59685075", "0.5967349", "0.59374565", "0.5934722", "0.5925989", "0.5925989", "0.59134823", "0.59104186", "0.5902475", "0.58991635", "0.5884915", "0.5880525", "0.58662075", "0.58467305", "0.5838289", "0.583382", "0.5830397", "0.5823451", "0.58133537", "0.58093095", "0.58093095", "0.580649", "0.57969093", "0.57919556", "0.5783496", "0.5780068", "0.57711923", "0.57646424", "0.57609403", "0.57609403", "0.57609403", "0.57609403", "0.575832", "0.575832", "0.575832", "0.575832", "0.575832", "0.575832", "0.575832", "0.575832", "0.575832", "0.575832", "0.575832", "0.575832", "0.575832", "0.57573736", "0.5756796", "0.5756796", "0.5754621", "0.57523346", "0.5733318", "0.57304585", "0.57277536", "0.5725086", "0.5725086", "0.5725086", "0.57121193", "0.57013935", "0.5693039", "0.56830716", "0.56804353", "0.5680025", "0.5675564", "0.56592596", "0.5634985", "0.56341845", "0.5629846", "0.56269735", "0.56269276", "0.56260645", "0.5623678" ]
0.630312
10
Returns a string representation of a single row of the board.
public String rowToString(int row) { if (!isValid(row)) { return INDEX_ERROR_MESSAGE; } StringBuilder sb = new StringBuilder(); for (int i = 0; i < dimension; i++) { sb.append(stateToString(row, i)).append(" "); } //remove the last unnecessary white space from the string. return sb.toString().substring(0, sb.length() - 1); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public String toString() {\n return String.format(\"%s%s\", column, row);\n }", "public String toString()\n {\n return row0 + \"\\n\" + row1 + \"\\n\" + row2 + \"\\n\" + row3;\n }", "public String toString()\n\t{\n\t\tchar rowLetter = (char)('A'+row);\n\t\treturn(\"\"+rowLetter+col);\n\t}", "public String toString() {\n String boardString = \"\";\n for (int j = 0; j < nRows; j++) {\n String row = \"\";\n for (int i = 0; i < nCols; i++) {\n if (board[j][i] == null) {\n row = row + \"Empty \";\n } else {\n row = row + board[j][i].getType() + \" \";\n }\n }\n boardString = boardString + row + \"\\n\";\n }\n return boardString;\n }", "public String boardCellToString() {\n String str;\n Integer convertX, convertY;\n //adjusting the co'ordinates because the board starts at 1 not 0\n convertX=this.xCor + 1;\n convertY= this.yCor + 1;\n str = \"(\" + convertX.toString() + \",\" + convertY.toString() + \")\";\n return str;\n }", "public String toString() {\n StringBuilder s = new StringBuilder(); // Initialize new string builder\n s.append(N + \"\\n\"); // Append board dimension to string\n\n for (int[] row : tiles) {\n for (int tile : row)\n s.append(String.format(\"%2d \", tile)); // Append formatted board tiles string\n s.append(\"\\n\"); // Append new line to string\n }\n return s.toString(); // Return string representation of board\n }", "public String toString() {\n String bs = \" \"; // bs stands for board string\n for (int col = 0; col <= (this.boardSize - 1); col++) {\n bs = bs + (col + 1) + \" \";\n if (col < this.boardSize - 1) {\n bs = bs + \" \";\n }\n }\n bs = bs + \"\\n\";\n char rowHead = 'A';\n for (int row = 0; row <= (this.boardSize - 1); row++) {\n bs = bs + \" \" + rowHead++ + \" \";\n for (int col = 0; col < this.boardSize; ++col) {\n bs = bs + \" \" + this.board[row][col];\n if (col < this.boardSize - 1) {\n bs = bs + \" |\";\n }\n }\n bs = bs + \"\\n\";\n if (row < this.boardSize - 1) {\n bs = bs + \" \";\n for (int col = 0; col < this.boardSize; col++) {\n bs = bs + \"---\";\n if (col < this.boardSize - 1) {\n bs = bs + \"|\";\n }\n }\n }\n bs = bs + \"\\n\";\n }\n return bs;\n }", "public String toString() {\n String returnString = \"\";\n returnString = returnString + \"\\r\\n\";\n for (int i = 0; i < rows + 1; i++) {\n for (int j = 0; j < cols + 1; j++) {\n if (i == 0 && j == 0) {\n returnString = returnString + \" \";\n continue;\n }\n if (i == 0) {\n if (j > 0) {\n returnString = returnString + (j + \" \");\n }\n if (j == 8) {\n returnString = returnString + \"\\r\\n\";\n }\n } else {\n if (j > 0) {\n if (!isEmpty(i - 1, j - 1)) {\n returnString = returnString + (getBoard()[i - 1][j - 1] + \" \");\n } else {\n returnString = returnString + \" \";\n }\n }\n }\n if (j == 0) {\n returnString = returnString + (i + \" \");\n }\n\n }\n returnString = returnString + \"\\r\\n\";\n }\n return returnString;\n }", "@Override\r\n public String toString() {\r\n StringBuilder sb = new StringBuilder();\r\n for (int i = 0; i < dimension; i++) {\r\n sb.append(rowToString(i)).append(\"\\n\");\r\n }\r\n //remove the last unnecessary carriage return from the string.\r\n return sb.toString().substring(0, sb.length() - 1);\r\n }", "public String toString() {\r\n return \"Row: \" + this.row + \"Column: \"+ this.col;\r\n }", "public String toString() {\n\tString str = \"\";\n\tfor (int i = 0; i < board.length; i++) {\n\t str = str + \"\\n\";\n\t for (int j = 0; j <= (board.length - 1); j++)\n\t\tstr = \" \" + str + board[i][j] + \" \";\n\t}\n\treturn str;\n }", "@Override\r\n public String toString() { return new String( \"(\" + row + \", \" + col + \")\" ); }", "public static String getLine (int row) {\n\t\t\n\t\t// Creates String to output\n\t\tString output;\n\t\t// Checks if row has >1 digit and compensates\n\t\tif ((row) / 10 >= 1) {\n\t\t\toutput = (row + \" |\");\n\t\t}\n\t\telse {\n\t\t\toutput = (row + \" |\");\n\t\t}\n\t\t// Adds the numbers in the table body\n\t\tfor (int i = 1; i <= 12; i++) {\n\t\t\t\n\t\t\t// Concatenates the numbers to output\n\t\t\toutput = output.concat(String.format(\" \" + \"%5d\", row * i) + \" \");\n\t\t\t\n\t\t}\n\t\t\n\t\t// Returns output\n\t\treturn output;\n\t\t\n\t}", "public String toString () {\n return \"(\" + col + \",\" + row + \")\";\n }", "@Override\n public String toString() {\n //create a string in the following format “<row>,<column>”\n String out = \"\";\n out += row + \", \" + column;\n return out;\n }", "@Override\n public String toString() {\n StringBuilder sb = new StringBuilder();\n\n //Print board\n int c = 0;\n for (Piece piece : board) {\n if (piece == null) {\n sb.append(\"\\t\");\n } else {\n sb.append(piece.pieceString()).append(\"\\t\");\n }\n if (++c % 4 == 0) {\n sb.append(\"\\n\");\n }\n }\n sb.append(\"\\n\");\n\n return sb.toString();\n }", "@Override\n public String toString() {\n StringBuilder sb = new StringBuilder();\n\n for (int i = 0; i < row; i++) {\n for (int j = 0; j < column; j++) {\n sb.append(game[i][j]);\n }\n sb.append(\"\\n\");\n }\n return sb.toString();\n }", "public String serialize() {\n return \"row=\\\"\" + row + \"\\\" column=\\\"\" + column + \"\\\"\";\n }", "public String toString()\n\t{\n\t\tString s = \"\";\n\t\tfor(int r = 0; r < board.length; r++)\n\t\t{\n\t\t\tfor(int c = 0; c < board[0].length; c++)\n\t\t\t{\n\t\t\t\ts += \"|\" + board[r][c];\n\t\t\t}\t\t\t\t\n\t\t\ts += \"|\" + \"\\n\" + \"-------------------\" + \"\\n\";\n\t\t}\n\t\treturn s;\n\t}", "public String toString() {\n \t// string representation of the board (in the output format specified below)\n \tStringBuilder sb = new StringBuilder(dimension() + \" \\n \");\n \t\n \tfor (int row = 0; row < dimension(); row++) {\n \t\tfor (int column = 0; column < dimension(); column++) {\n \t\t\tsb.append(blocks[row][column]);\n \t\t\tsb.append(\" \");\n \t\t}\n \t\t\n \t\tsb.append(\"\\n \");\n \t}\n \t\n \treturn sb.toString();\n }", "public String toString() {\n StringBuilder sb = new StringBuilder();\n\n for (int i = 0; i < SIZE; i++) {\n for (int j = 0; j < SIZE; j++) {\n sb.append(board[i][j]);\n sb.append(\" \");\n }\n sb.append(\"\\n\");\n }\n return sb.toString();\n }", "public String getBoard() {\r\n\t\tString r = \"\";\r\n\t\tfor (int y = 0; y < 3; y++) {\r\n\t\t\tfor (int x = 0; x < 3; x++) {\r\n\t\t\t\tr = r + board[y][x];\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn r;\r\n\t}", "@Override\n\tpublic String toString(){\n\t\t// return a string of the board representation following these rules:\n\t\t// - if printed, it shows the board in R rows and C cols\n\t\t// - every cell should be represented as a 5-character long right-aligned string\n\t\t// - there should be one space between columns\n\t\t// - use \"-\" for empty cells\n\t\t// - every row ends with a new line \"\\n\"\n\t\t\n\t\t\n\t\tStringBuilder sb = new StringBuilder(\"\");\n\t\tfor (int i=0; i<numRows; i++){\n\t\t\tfor (int j =0; j<numCols; j++){\n\t\t\t\tPosition pos = new Position(i,j);\n\t\t\t\t\n\t\t\t\t// use the hash table to get the symbol at Position(i,j)\n\t\t\t\tif (grid.contains(pos))\n\t\t\t\t\tsb.append(String.format(\"%5s \",this.get(pos)));\n\t\t\t\telse\n\t\t\t\t\tsb.append(String.format(\"%5s \",\"-\")); //empty cell\n\t\t\t}\n\t\t\tsb.append(\"\\n\");\n\t\t}\n\t\treturn sb.toString();\n\n\t}", "public String toString(){\n StringBuffer returnString = new StringBuffer();\n for(int i = 0; i < this.matrixSize; i++){\n if(rows[i].length() != 0){\n returnString.append((i+1) + \":\" + rows[i]+ \"\\n\");\n }\n }\n return returnString.toString();\n }", "public String toString() {\n return row + \",\" + col;\n }", "public String toString()\n\t{\n\t\tStringBuilder sb = new StringBuilder();\n\t\tsb.append(\" 1 2 3 4 5 6 7 8\\n\");\n\t\tfor(int i = 0; i < 8; i++)\n\t\t{\n\t\t\tsb.append((char) (i + FIRST_ROW) + \" \");\n\t\t\tfor(int i2 = 0; i2 < 8; i2++)\n\t\t\t{\n\t\t\t\tsb.append(\" \" + fields[i][i2]);\n\t\t\t\tif(i2 == 7)\n\t\t\t\t{\n\t\t\t\t\tsb.append(\"\\n\");\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn sb.toString();\n\t}", "public String toString() {\n\n\t\tString result = \"\";\n\n\t\tfor(Cell[][] dim : board) {\n\t\t\tfor(Cell[] row : dim) {\n\t\t\t\tfor(Cell col : row) {\n\t\t\t\t\tif(col== Cell.E)\n\t\t\t\t\t\tresult += \"-\";\n\t\t\t\t\telse\n\t\t\t\t\t\tresult += col;\t\n\t\t\t\t}\n\t\t\t\tresult += \"\\n\";\n\t\t\t}\n\t\t\tresult += \"\\n\";\n\t\t}\n\n//\t\tSystem.out.println(\"\\n***********\\n\");\n\t\treturn result;\n\n\t}", "@Override\n public String toString() {\n String returnBoard = \" \";\n for (int i = 1; i <= 3; i++) {\n returnBoard=returnBoard+\" \" +Integer.toString(i);\n }\n returnBoard+=\"\\n\";\n for (int i = 1; i <= 3; i++) {\n returnBoard+= Integer.toString(i);\n for (int j = 1; j <= 3; j++) {\n returnBoard = returnBoard + \" \" + board[i-1][j-1].toString();\n }\n returnBoard+=\"\\n\";\n }\n return returnBoard;\n }", "public String toString() {\n\t\tString temp = \"\";\n\t\tfor (int i = 0; i < 10; i++) {\n\t\t\ttemp += String.format(\"%d \", i);\n\t\t}\n\t\ttemp += \"\\n\";\n\t\tfor (int i = 0; i < 9; i++) {\n\t\t\ttemp += String.format(\"%d | \", i + 1);\n\t\t\tfor (int j = 0; j < 9; j++) {\n\t\t\t\ttemp += String.format(\"%c | \", board[i][j]);\n\t\t\t}\n\t\t\ttemp += \"\\n\";\n\t\t}\n\t\treturn temp;\n\t}", "@Override\n\tpublic String toString() {\n\t\tString result = \"-------------------\\n\";\n\t\tfor (Cell[] cellRow : board) {\n\t\t\tresult += \"|\";\n\t\t\tfor (Cell cell : cellRow) {\n\t\t\t\tresult += (cell.val == 0 ? \" \" : cell.val) + \"|\";\n\t\t\t}\n\t\t\tresult += \"\\n-------------------\\n\";\n\t\t}\n\t\treturn result += \"\\n\" + toTest();\n\t}", "public String toString() {\n\t\tString rowOne = Arrays.toString(finalGrid[0]);\n\t\tString rowTwo = Arrays.toString(finalGrid[1]);\n\t\tString rowThree = Arrays.toString(finalGrid[2]);\n\t\tString rowFour = Arrays.toString(finalGrid[3]);\n\t\tString rowFive = Arrays.toString(finalGrid[4]);\n\t\tString rowSix = Arrays.toString(finalGrid[5]);\n\t\tString rowSeven = Arrays.toString(finalGrid[6]);\n\t\tString rowEight = Arrays.toString(finalGrid[7]);\n\t\tString rowNine = Arrays.toString(finalGrid[8]);\n\t\tString allRows = \"The sudoku grid is as shown below: \\n\" + rowOne + \"\\n\" + rowTwo + \"\\n\" + rowThree + \"\\n\" + rowFour + \"\\n\" \n\t\t+ rowFive + \"\\n\" + rowSix + \"\\n\" + rowSeven + \"\\n\" + rowEight + \"\\n\" + rowNine;\n\t\treturn allRows;\n\t}", "public String toString() {\n String result = \"\";\n if (this.column > 0 && this.row > 0) {\n int column = this.column, exp = (int) (Math.log(column) / Math.log(26)), cur;\n for (int i = exp; i >= 0; i--) {\n cur = (int) (column / Math.pow(26, i));\n result += (char) (64 + cur);\n column -= cur * Math.pow(26, i);\n }\n result += this.row;\n }\n return result;\n }", "@Override\n public String toString() {\n\n \n String str = \"\";\n for(int rowIndex = 0; rowIndex < this.board.length; rowIndex++) {\n \n for(int columnIndex = 0; columnIndex < this.board[rowIndex].length; columnIndex++) {\n\n switch (this.board[rowIndex][columnIndex]) {\n case IBoardState.symbolOfInactiveCell:\n str += \"*|\";\n break;\n case IBoardState.symbolOfEmptyCell:\n str += \"0|\";\n break;\n case IBoardState.symbolOfFirstPlayer:\n str += \"1|\";\n break;\n case IBoardState.symbolOfSecondPlayer:\n str += \"2|\";\n break;\n }\n\n }\n str +=\"\\n\";\n }\n return str;\n }", "public String toString() {\n StringBuilder s = new StringBuilder();\n s.append(dim + \"\\n\");\n for (int i = 0; i < dim; i++) {\n for (int j = 0; j < dim; j++) {\n s.append(String.format(\"%2d \", board[i][j]));\n }\n s.append(\"\\n\");\n }\n return s.toString();\n }", "public String toString(){\n\t\tString board = \"\";\n\t\tfor(int i = 0; i < rows; i++){\n\t\t\tfor(int j = 0; j < columns; j++){\n\t\t\t\tif(theGrid[i][j]){ //iterate through, if cell is alive, mark with *\n\t\t\t\t\tboard += \"*\";\n\t\t\t\t}\n\t\t\t\telse{\n\t\t\t\t\tboard += \" \"; //else, [space]\n\t\t\t\t}\n\t\t\t}\n\t\t\tboard += \"\\n\";//create a new line, to create the board\n\t\t}\n\t\treturn board; //return the board\n\t}", "public String toString(){\r\n return \"{\"+ this.getRowIndex()+\",\"+ this.getColumnIndex()+\"}\";\r\n }", "private String toRowChar(int row)\n\t{\n\t\tString theRow;\n\t\t\n\t\tswitch (row)\n\t\t{\n\t\tcase 0: theRow = \"A\"; break;\n\t\tcase 1: theRow = \"B\"; break;\n\t\tcase 2: theRow = \"C\"; break;\n\t\tdefault: theRow = \" \";\n\t\t}\n\t\t\n\t\treturn theRow;\n\t}", "public String row(int i)\n throws Exception\n {\n if (i < 0 || i > height)\n throw new Exception(\"Invalid row \" + i);\n\n String result = tb.row(i);\n result = result.substring(0, width);\n return result;\n }", "public String toString() {\n\t\tStringBuilder string = new StringBuilder();\n\t\tstring.append(n + \"\\n\");\n\t\tfor (int i = 0; i < n; i++) {\n\t\t\tfor (int j = 0; j < n; j++) \n\t\t\t\tstring.append(String.format(\"%2d \", board[i][j]));\n\t\t\tstring.append(\"\\n\");\n\t\t}\n\t\treturn string.toString();\n\t}", "public String toString() {\n\t\tString str = \"\\n \";\n\t\tfor (int i = 1; i <= board.length; i++) {\n\t\t\tstr += i + \" \";\n\t\t}\n\t\tstr = str.stripTrailing() + \"\\n\";\n\t\tfor (int i = 0; i < board.length; i++) {\n\t\t\tstr += (i+1) + \" \";\n\t\t\tfor (int j = 0; j < board.length; j++) {\n\t\t\t\tif (board[i][j] == Disc.WHITE) {\n\t\t\t\t\tstr += \"W \";\n\t\t\t\t} else if (board[i][j] == Disc.BLACK) {\n\t\t\t\t\tstr += \"B \";\n\t\t\t\t} else {\n\t\t\t\t\tstr += \"- \";\n\t\t\t\t}\n\t\t\t}\n\t\t\tstr = str.stripTrailing() + \"\\n\";\n\t\t}\n\t\treturn str;\n\t}", "public String toString() {\n\t\tStringBuilder sb = new StringBuilder();\n\t\tfor (byte m = 0; m < 9; m++) {\n\t\t\tfor (byte n = 0; n < 9; n++) {\n\t\t\t\tsb.append(cells[m][n].getValue());\n\t\t\t}\n\t\t}\n\t\treturn sb.toString();\n\t}", "@Override\n public String toString() {\n StringBuilder result = new StringBuilder();\n for (int i = 0; i < 3; i++) {\n for (int j = 0; j < 3; j++) {\n int cell = field[i][j];\n result.append(cell == 0 ? \"_\" : (cell == 1 ? \"X\" : \"O\")).append(\" \");\n }\n result.append(\"\\n\");\n }\n return result.toString();\n }", "@Override\n public String toString() {\n String result = \"\";\n\n for (int position = 0; position < 64; position++) {\n if (position > 0) {\n if (position % 16 == 0) { // New level\n result += '|';\n } else if (position % 4 == 0) {\n result += ' '; // New row\n }\n }\n result += get(position);\n }\n return result;\n }", "public String toString ()\n\t{\n\t\tString s = \"Grid:\\n\";\n\t\tfor (int row=0; row<GRID_SIZE; row++)\n\t\t{\n\t\t\tfor (int col=0; col<GRID_SIZE; col++) {\n\t\t\t\ts = s + grid[col][row].value()+ \" \";\n\t\t\t}\n\t\t\ts += \"\\n\";\n\t\t}\n\t\treturn s;\n\t}", "public String toString()\n\t{\n\t\treturn _RowData.toString();\n\t}", "@Override\n public String toString() {\n String[] output = new String[getHeight()];\n for (int row=0; row < getHeight(); row++) {\n StringBuilder builder = new StringBuilder();\n for (int col=0; col < getWidth(); col++) {\n Square current = getSquare(row, col);\n builder.append(getCharForSquare(current));\n }\n output[row] = builder.toString();\n }\n return String.join(\"\\n\", output);\n }", "public String toString() {\n String result = \"\";\n result += \" \";\n // Column numbers\n for (int i = 0; i < numberOfColumns; i++) {\n result += (i % 10) + \" \";\n }\n result += \"\\n\";\n result += \" \";\n // Horizontal dividers\n for (int i = 0; i <= 2 * this.numberOfColumns - 2 ; i++) {\n result += HORI_DIVIDE;\n }\n result += \"\\n\";\n // Each horizontal line has the line number, a divider, and the safe data.\n for (int i = 0; i < numberOfRows; i++) {\n result += (i % 10);\n result += VERT_DIVIDE;\n for (int j = 0; j < numberOfColumns; j++) {\n result += grid[i][j];\n if (j != numberOfColumns - 1) {\n result += \" \";\n }\n }\n if (i != numberOfRows - 1) {\n result += \"\\n\";\n }\n }\n return result;\n }", "private String gameBoardToString(){\n StringBuilder config = new StringBuilder();\n\n //length attribute gets the number of rows in a 2D array. length attribute on a row gets the number of columns in a\n // 2D array. We iterate through all the rows and columns and join all the characters in the array into a single\n // String config\n\n for (int i = 0; i < this.boardRows; i++){\n for (int j =0; j < this.boardColumns; j++){\n config.append(this.gameBoard[i][j]);\n }\n }\n\n // Returns String object representation of StringBuilder object\n return config.toString();\n\n }", "public static void printBoard(String[][] board) {\n String row0 = board[0][0] +\"|\"+ board[0][1] +\"|\"+ board[0][2];\n String row1 = board[1][0] +\"|\"+ board[1][1] +\"|\"+ board[1][2];\n String row2 = board[2][0] +\"|\"+ board[2][1] +\"|\"+ board[2][2];\n\n System.out.println(row0);\n System.out.println(\"-----\");\n System.out.println(row1);\n System.out.println(\"-----\");\n System.out.println(row2);\n }", "@Override\n public String toString(){\n return row + \",\" + column + \",\";\n }", "public String toString() {\n StringBuilder output = new StringBuilder();\n output.append(\"{\\n\");\n for (int i=0; i<rows; i++) {\n output.append(Arrays.toString(matrix.get(i)) + \",\\n\");\n }\n output.append(\"}\\n\");\n return output.toString();\n }", "public String getGameStr() {\n StringBuilder outStr = new StringBuilder();\n for(int i=0;i<ROWS;i++) {\n for(int j=0;j<COLS;j++){ \n outStr.append(\"|\").append(gameBoard[i][j].show());\n }\n outStr.append(\"|\").append(System.getProperty(\"line.separator\"));\n }\n return outStr.toString();\n }", "@Override\n public String toString() {\n StringBuilder builder = new StringBuilder();\n\n for (int row = 0; row < this.getNumberOfRows(); row++) {\n for (int column = 0; column < this.getNumberOfCols(); column++) {\n\n if (row == this.getState()[0] && column == this.getState()[1])\n builder.append(\"* \");\n else\n builder.append(Integer.toString(this.getEnvironment()[row][column]) + ' ');\n\n }\n\n if (row != (this.getNumberOfRows() - 1))\n builder.append('\\n');\n }\n\n return builder.toString();\n }", "public String toString(){\n\n\t\tStringBuffer b = new StringBuffer();\n\t\tb.append('\\n');\n\n\t\tint i = 0, j, counter = 0;\n\t\twhile( i < numRows){\n\n\t\t\tj = 0;\n\t\t\twhile( j < numCols){\n\n\t\t\t\tb.append( \"\" + i + TAB + j + TAB);\n\t\t\t\tObject obj = this.get(i, j);\n\t\t\t\tif( obj != null ) {\n\t\t\t\t\tb.append( obj.toString() );\n\t\t\t\t\tcounter++;\n\t\t\t\t}\n\t\t\t\telse b.append( \"NULL\" );\n\t\t\t\tb.append('\\n');\n\n\t\t\t\tj++;\n\t\t\t}\n\t\t\ti++;\n\n\t\t}\n\t\tb.append( \"\\nNumber of Rows = \" + numRows + '\\n' );\n\t\tb.append( \"Number of Columns = \" + numCols + '\\n' );\n\t\tb.append( \"Size = \" + size + '\\n' );\n\t\tb.append( \"Number of non-null objects = \" + counter + '\\n' );\n\t\treturn b.toString();\n\t}", "public static void printGameBoard(Player[][] board) {\n\t\tStringBuilder rowBuffer = new StringBuilder(); \n\t\tfor (int row = 0; row < Score4Constants.rowMax; row++) {\n\t\t\tfor (int col = 0; col < Score4Constants.colMax; col++) {\n\t\t\t\trowBuffer.append(board[row][col].getName());\n\t\t\t\trowBuffer.append(\" \");\n\t\t\t}\n\t\t\tlogger.info(\"ROW: {}: {}\", row + 1, rowBuffer);\n\t\t\trowBuffer.delete(0, rowBuffer.length());\n\t\t}\n\t}", "public String toString() {\n\t\tString r = \"\";\n\t\tchar[][] a = toMatrix();\n\t\tfor (int i = 0; i < 3; i++) {\n\t\t\tfor (int j = 0; j < 3; j++) {\n\t\t\t\tif (a[i][j] == '\\0')\n\t\t\t\t\tr += \"-\";\n\t\t\t\telse\n\t\t\t\t\tr += a[i][j];\n\t\t\t}\n\t\t\tr += \"\\n\";\n\t\t}\n\t\treturn r.substring(0, r.length() - 1);\n\t}", "public String toString() {\n\t\t// This method is provided for debugging purposes\n\t\t// (use/modify as much as you'd like), it just prints\n\t\t// out the column for easy viewing.\n\t\tStringBuilder s = new StringBuilder(\"Column with \" + size() + \" items and a capacity of \" + capacity() + \":\");\n\t\tfor (int i = 0; i < size(); i++) {\n\t\t\ts.append(\"\\n [\" + i + \"]: \" + get(i));\n\t\t}\n\t\treturn s.toString();\n\n\t}", "public String toString() {\n\tString retStr = \"\";\n\tfor (int r = 0; r < this.size(); r++){\n\t for (int c = 0; c < this.size(); c++){\n\t\tretStr += matrix[r][c] + \"\\t\";\n\t }\n\t retStr += \"\\n\";\n\t}\n\treturn retStr;\n }", "public String toString() {\n\t\t// Variables\n\t\tString gameboard;\n\t\tchar[] firstLetter = { 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O' };\n\n\t\t// Top\n\t\tgameboard = \" ===============================================================\\n\";\n\n\t\t// Middle\n\t\tfor (int i = 0; i < 15; i++) {\n\t\t\t// Beginning of the line\n\t\t\tgameboard += \" \" + firstLetter[i] + \" ||\";\n\n\t\t\t// Letters\n\t\t\tfor (int j = 0; j < 15; j++) {\n\t\t\t\tif (this.grid[i][j].getTile().getLetter() == Character.MIN_VALUE) {\n\t\t\t\t\tif (this.grid[i][j].getScoreMult() > 1)\n\t\t\t\t\t\tgameboard += \" * \";\n\t\t\t\t\telse\n\t\t\t\t\t\tgameboard += \" . \";\n\t\t\t\t} else {\n\t\t\t\t\tgameboard += \" \" + this.grid[i][j].getTile().getLetter() + \" \";\n\t\t\t\t}\n\t\t\t\tif (j != 14)\n\t\t\t\t\tgameboard += '|';\n\t\t\t}\n\n\t\t\t// End of the line\n\t\t\tgameboard += \"||\\n\";\n\t\t\tif (i != 14)\n\t\t\t\tgameboard += \" ||---|---|---|---|---|---|---|---|---|---|---|---|---|---|---||\\n\";\n\t\t}\n\n\t\t// Bottom\n\t\tgameboard += \" ===============================================================\\n\";\n\t\tgameboard += \" 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15\";\n\n\t\treturn gameboard;\n\t}", "public String toString() {\n StringBuilder res = new StringBuilder();\n res.append(n + \"\\n\");\n for (int i = 0; i < n; i++) {\n for (int j = 0; j < n; j++)\n res.append(String.format(\" %2d \", tileAt(i, j)));\n res.append(\"\\n\");\n }\n return res.toString();\n }", "@Override\n public String toString() {\n\treturn \"\"+rowIndex+colIndex; \n }", "public String toString()\n {\n String boardString = \"\";\n int space = 1;\n for(int i = 0; i < NUM_SQUARES; i++)\n {\n boardString += \"| \" + board[i].toString() + \" | \";\n //Make a new line every 10 squares\n if(space == 10 || space == 20 || space == 30 || space == 40 || space == 50 || space == 60 || space == 70 || space == 80 || space == 90) boardString += \"\\n\";\n space++;\n }\n return boardString;\n }", "public String getHighlightrow()\n {\n return String.valueOf(highlightRow);\n }", "public String toString() {\n\t\t// Converts column\n\t\tString columnStr = \"\";\n\t\tfor (int tempColumn = cell.getAddress().getColumn();\n\t\t\t\ttempColumn >= 0; tempColumn = tempColumn\n\t\t\t\t\t/ (Address.HIGHEST_CHAR - Address.LOWEST_CHAR + 1) - 1)\n\t\t\tcolumnStr = ((char)((char)(tempColumn % (Address.HIGHEST_CHAR\n\t\t\t\t- Address.LOWEST_CHAR + 1)) + Address.LOWEST_CHAR)) + columnStr;\n\t\tif (columnAbsolute)\n\t\t\tcolumnStr = ABSOLUTE_OPERATOR + columnStr;\n\n\t\t// Converts row\n\t\tString rowStr = (rowAbsolute ? ABSOLUTE_OPERATOR : \"\")\n\t\t\t+ (cell.getAddress().getRow() + 1);\n\t\treturn columnStr + rowStr;\n\t}", "public String toString() {\n StringBuilder sb = new StringBuilder();\n sb.append(n + System.lineSeparator());\n for (int i = 0; i < n; i++) {\n for (int j = 0; j < n; j++) {\n sb.append(tiles[i][j] + \" \");\n }\n sb.append(System.lineSeparator());\n }\n return sb.toString();\n }", "public static String toString(String[][] board) {\n\n return board[0][0] + \" \" + board[0][1] + \" \" + board[0][2] + \" \"\n + board[1][0] + \" \" + board[1][1] + \" \" + board[1][2] + \" \"\n + board[2][0] + \" \" + board[2][1] + \" \" + board[2][2];\n }", "public static String toString(int[][] a) {\r\n\t\tint rowNum = a.length;\r\n\t\tint colNum = a[0].length;\r\n\t\tString ret = \"\";\r\n\t\tfor (int i = 0; i < rowNum; i++) {\r\n\t\t\tfor (int j = 0; j < colNum; j++) {\r\n\t\t\t\tif (colNum == 0) {\r\n\t\t\t\t\tret += \"\\n\";\r\n\t\t\t\t}\r\n\t\t\t\tret += \"\\t\" + a[i][j];\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn ret;\r\n\t}", "public String toString() {\n\t\tString returnString=\"\";\n\t\t\n\t\tfor (int i=0; i<squares.length; i++) {\n\t\t\tfor (int j=0; j<squares.length; j++) {\n\t\t\t\treturnString+=Character.toString(squares[i][j].getValue());\n\t\t\t}\n\t\t\treturnString+=\"// \";\n\t\t}\n\t\t\n\t\treturn returnString;\n\t}", "public String toString() {\n String s = \"\";\n for(int i = 1; i <= rows; i++){\n for(int j = 1; j <= cols; j++){ \n s = s + String.format(\"%2d\",m[i][j]) + \" \";\n }\n s += \"\\n\";\n }\n return s;\n }", "@Override\n\tpublic String toString() {\n\t\tString grid = \"\";\n\t\tfor (int i = 0; i < this.getNumRow(); i++) {\n\t\t\tgrid = grid + this.storage.get(i).toString() + \"\\n\";\n\t\t}\n\t\tSystem.out.println(grid);\n\t\treturn grid;\n\t}", "String getBoardString();", "public String toString() {\n StringBuilder s = new StringBuilder();\n s.append(N + \"\\n\");\n for (int i = 0; i < N; i++) {\n for (int j = 0; j < N; j++) {\n s.append(String.format(\"%2d \", tiles[i][j]));\n }\n s.append(\"\\n\");\n }\n return s.toString();\n }", "public String toString() {\n StringBuilder s = new StringBuilder();\n s.append(N + \"\\n\");\n for (int i = 0; i < N; i++) {\n for (int j = 0; j < N; j++) {\n s.append(String.format(\"%2d \", tiles[i][j]));\n }\n s.append(\"\\n\");\n }\n return s.toString();\n }", "public String toString(){\n //KEY --------\n // WHITE WALL = WW\n // WHITE ROAD = WR\n // WHITE CAPSTONE = WC\n // BLACK WALL = BW\n // BLACK ROAD = BR\n // BLACK CAPSTONE = BC\n // EMPTY = \"blank\"\n\n StringBuilder builder = new StringBuilder();\n\n /*TOP ROW*/ builder.append(\"\\t\"); for(int i = 0; i < SIZE; i++){ builder.append(i + \"\\t\");} builder.append(\"\\n\\n\");\n /*REST OF THE ROWS*/ \n for(int x = 0; x < SIZE; x++){\n builder.append(x + \"\\t\");\n for(int y = 0; y < SIZE; y++){\n TakStack current = stacks[y][x]; \n if(!current.isEmpty()){\n builder.append(getPieceString(current.top()));\n }\n builder.append(\"\\t\");\n }\n builder.append(\"\\n\\n\");\n }\n\n\n //BUILDER RETURN\n return builder.toString();\n }", "public String toString() {\r\n\t\tString s = (currentPlayer == getP1() ? \"Cross : \" : \"Nought : \");\r\n\t\tfor (int y = 0; y < 3; y++) {\r\n\t\t\tfor (int x = 0; x < 3; x++) {\r\n\t\t\t\ts = s + board[y][x];\r\n\t\t\t}\r\n\t\t\ts = s + \" \";\r\n\t\t}\r\n\t\treturn s;\r\n\t}", "@Override\r\n\t\tpublic String toString() {\r\n\t\t\tint rowNumTemp = rowNum;\r\n\t\t\tString result = \"\";\r\n\t\t\tint remainder;\r\n\t\t while (rowNumTemp > 0) {\r\n\t\t rowNumTemp--; // 1 => a, not 0 => a\r\n\t\t remainder = rowNumTemp % 26;\r\n\t\t char digit = (char) (remainder + (int) 'A'); //Lettering starts at A\r\n\t\t result = digit + result;\r\n\t\t rowNumTemp = rowNumTemp - remainder;\r\n\t\t rowNumTemp = rowNumTemp/26;\r\n\t\t }\r\n\r\n\t\t return result + Integer.toString(seatNum);\t\t \r\n\t\t\t\r\n\t\t}", "public String getString() {\t\t\t\n\t\tString result = \"\";\n\t\tfor (int row = 0; row < this.size; row ++) {\n\t\t\tString line = \"\";\n\t\t\tfor (int column = 0; column < this.size; column++) {\n\t\t\t\tline += printToken(this.getTokenAt(new Vector(column, row))) + \" \";\n\t\t\t}\n\t\t\t\n\t\t\tresult += line + System.lineSeparator();\n\t\t}\n\t\treturn result;\n\t}", "@Override\r\n public String toString() {\r\n StringBuilder res = new StringBuilder();\r\n for (int i=0 ; i<this.tiles.length ; i++) {\r\n if (i>0 && i%this.width == 0) {\r\n res.append(\"\\n\");\r\n }\r\n res.append(this.tiles[i]);\r\n }\r\n return res.toString();\r\n }", "public static void gridrow(String[][] arr) {\n String gridString = \" \";\n\n for (int i = 0; i < arr.length; i++) {\n gridString += i;\n }\n\n gridString += \" \";\n\n System.out.println(gridString);\n }", "@Override\n public String toString() {\n return columnToChar(c1) + \"\" + (8 - r1) + columnToChar(c2) + \"\" + (8 - r2);\n }", "public static String createTicTacRow(int row, char[][] ticTacArray) {\n String lineResult = \"\";\n\n // Note space at the end of string returned\n for (int i = 0; i < 3; i++) {\n char temp = ticTacArray[row][i];\n lineResult += temp + \" \";\n }\n\n return lineResult;\n }", "public String drawBoard() {\n fillBoard();\n return \"\\n\" +\n \" \" + boardArray[0][0] + \" | \" + boardArray[0][1] + \" | \" + boardArray[0][2] + \" \\n\" +\n \"------------\\n\" +\n \" \" + boardArray[1][0] + \" | \" + boardArray[1][1] + \" | \" + boardArray[1][2] + \" \\n\" +\n \"------------\\n\" +\n \" \" + boardArray[2][0] + \" | \" + boardArray[2][1] + \" | \" + boardArray[2][2] + \" \\n\";\n }", "public String toString() {\n StringBuilder s = new StringBuilder();\n s.append(this.dim + \"\\n\");\n int counter = 0;\n for (int i = 0; i < this.dim; i++) {\n for (int j = 0; j < this.dim; j++) {\n int n = tiles[counter++];\n s.append(String.format(\"%2d \", n));\n }\n s.append(\"\\n\");\n }\n return s.toString();\n }", "private StringBuilder generateRowStringValue(PuzzlePiece col1, PuzzlePiece col2, PuzzlePiece col3, PuzzlePiece col4) {\n StringBuilder builder = new StringBuilder();\n int[][] arrayPuzzle1 = col1 != null ? col1.getArrayPuzzle() : null;\n int[][] arrayPuzzle2 = col2 != null ? col2.getArrayPuzzle() : null;\n int[][] arrayPuzzle3 = col3 != null ? col3.getArrayPuzzle() : null;\n int[][] arrayPuzzle4 = col4 != null ? col4.getArrayPuzzle() : null;\n for (int i = 0; i < 5; i++) {\n for (int j = 0; j < 20; j++) {\n if (j < 5) {\n if (col1 != null) {\n builder.append(arrayPuzzle1[i][j] == 1 ? \"o\" : \" \");\n } else {\n builder.append(\" \");\n }\n } else if (j < 10) {\n int jj = j - 5;\n if (col2 != null) {\n builder.append(arrayPuzzle2[i][jj] == 1 ? \"o\" : \" \");\n } else {\n builder.append(\" \");\n }\n } else if (j < 15) {\n int jj = j - 10;\n if (col3 != null) {\n builder.append(arrayPuzzle3[i][jj] == 1 ? \"o\" : \" \");\n } else {\n builder.append(\" \");\n }\n } else {\n int jj = j - 15;\n if (col4 != null) {\n builder.append(arrayPuzzle4[i][jj] == 1 ? \"o\" : \" \");\n } else {\n builder.append(\" \");\n }\n }\n }\n builder.append(\"\\n\");\n }\n return builder;\n }", "public static String getCellStrContentRow(int c, Row row) {\n Cell cell = getCellOfSheetRow(c, row);\n if (cell == null) {\n return \"\";\n }\n String temp = getCellContentRow(c, row).toString().trim();\n if (temp.endsWith(\".0\")) {\n return temp.substring(0, temp.length() - 2);\n }\n return temp;\n }", "public static String printBoard(Game board) {\n return board.toString();\n }", "public String toString(){\n\t\tStringBuilder output = new StringBuilder();\n\t\tfor(int i = 0; i<this.size; i++){\n\t\t\tfor(int j=0; j<this.size; j++){\n\t\t\t\toutput.append(this.numbers[i][j] + \"\\t\");\n\t\t\t}\n\t\t\toutput.append(\"\\n\");\n\t\t}\n\t\treturn output.toString();\n\t}", "public String toString() {\n\t\tStringBuilder buff = new StringBuilder();\n\t\tfor (int y = height-1; y>=0; y--) {\n\t\t\tbuff.append('|');\n\t\t\tfor (int x=0; x<width; x++) {\n\t\t\t\tif (getGrid(x,y)) buff.append('+');\n\t\t\t\telse buff.append(' ');\n\t\t\t}\n\t\t\tbuff.append(\"|\\n\");\n\t\t}\n\t\tfor (int x=0; x<width+2; x++) buff.append('-');\n\t\treturn(buff.toString());\n\t}", "public String toString() {\n\t\tStringBuilder buff = new StringBuilder();\n\t\tfor (int y = height-1; y>=0; y--) {\n\t\t\tbuff.append('|');\n\t\t\tfor (int x=0; x<width; x++) {\n\t\t\t\tif (getGrid(x,y)) buff.append('+');\n\t\t\t\telse buff.append(' ');\n\t\t\t}\n\t\t\tbuff.append(\"|\\n\");\n\t\t}\n\t\tfor (int x=0; x<width+2; x++) buff.append('-');\n\t\treturn(buff.toString());\n\t}", "private String getString( Object[] row, String rrName ) {\n return (String) getEntry( row, rrName );\n }", "public String toString() {\n String s = \" 1 2 3 4 5 6 7 8\";\n\n\n s += \"\\n --------------------\\n1 |\";\n\n for(int i=0; i < this.TAILLEX; i++){\n for(int k=0; k < this.TAILLEY; k++){\n s += this.plateau[i][k] + \"|\";\n }\n if(i<7) s += \"\\n --------------------\\n\" + (i+2) + \" |\";\n else s += \"\\n --------------------\\n\";\n }\n\n return s;\n }", "public int getRow()\r\n {\r\n return row;\r\n }", "public String toString() {\r\n\t\tStringBuilder sb = new StringBuilder();\r\n\t\tint n = dimension();\r\n\t\tsb = sb.append(n + \"\\n\");\r\n\t\tfor (int i = 0; i < n; i++) {\r\n\t\t\tfor (int j = 0; j < n; j++) {\r\n\t\t\t\tsb = sb.append(\" \" + this.blocks[i][j]);\r\n\t\t\t}\r\n\t\t\tif (i != n) {\r\n\t\t\t\tsb = sb.append(\"\\n\");\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn sb.toString();\r\n\t}", "public static String rowToString(String prefix, RowView rowView) {\r\n\t\tif(rowView == null) return \"\";\r\n\t\tStringBuilder sb = new StringBuilder();\r\n\t\t\r\n\t\tsb.append(prefix);\r\n\t\tsb.append(\"(\\n\");\r\n\t\ttry {\r\n\t\t\tfor(int i = 0; i < rowView.getColumnCount(); i++) {\r\n\t\t\t\tsb.append('\\t');\r\n\t\r\n\t\t\t\t\tValueHolder valueHolder = new ValueHolder(rowView.getColumnTypes().get(i));\r\n\t\t\t\t\trowView.getValueAt(i, valueHolder);\r\n\t\t\t\t\t\r\n\t\t\t\t\tif(valueHolder.isNull())\r\n\t\t\t\t\t\tsb.append(\"(null)\");\r\n\t\t\t\t\telse if(valueHolder.getValueType() == SqlType.getType(\"bytea\"))\r\n\t\t\t\t\t\tsb.append(\"(bytea)\");\r\n\t\t\t\t\telse if(valueHolder.getValueType() == SqlType.getType(\"character varying\")) {\r\n\t\t\t\t\t\tString value = valueHolder.toString();\r\n\t\t\t\t\t\tif(value.length() > 70) value = value.substring(0, 67) + \"...\";\r\n\t\t\t\t\t\tsb.append(value);\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse\r\n\t\t\t\t\t\tvalueHolder.toString(sb);\r\n\t\t\t\tsb.append('\\n');\r\n\t\t\t}\r\n\t\t}\r\n\t\tcatch(RuntimeException e) {\r\n\t\t\tsb.append('\\t');\r\n\t\t\tsb.append(e.getMessage());\r\n\t\t\tsb.append('\\n');\r\n\t\t}\r\n\t\tsb.append(')');\r\n\t\treturn sb.toString();\r\n\t}", "@Override\n\tpublic String toString() {\n\t\tString countCell = \"\";\n\t\tfor ( int row = 0; row < gameGrid.length; row++){\n\t\t\tfor ( int column = 0; column < gameGrid[0].length; column++){\n\t\t\t\tif(gameGrid[row][column] == 1) //this represents a live cell or exist\n\t\t\t\t\tcountCell = countCell + \"0\"; \n\t\t\t\telse{\n\t\t\t\t\tcountCell = countCell + \".\";//this will create little dots if there is no live cell...\n\t\t\t\t}\n\n\t\t\t}\n\t\t\tcountCell = countCell + \"\\n\"; //creates a new line and moves down in the array\n\t\t}\n\n\t\treturn countCell;\n\t}", "private String printRow(Result res){\n Iterator<Pair<String ,byte[]>> iter =outList.iterator();\n String row = \"\";\n while(iter.hasNext()){\n Pair<String ,byte[]> col = iter.next();\n String val = appendFromCol(col.getFirst(), res);\n row += val + delim;\n }\n // strip out last delim\n return row.substring(0, row.length()-1);\n }", "@Override\n public String toString()\n {\n StringBuffer sb = new StringBuffer();\n\n for (int i = 0; i < dice.length; i++)\n {\n sb.append(dice[i][0]);\n }\n\n return sb.toString();\n }", "public int getRow()\n {\n return row;\n }", "@Override\r\n public String toString() { return \"{\" + rowIndex + \", \" + colIndex + '}'; }", "public int getRow()\n {\n return row;\n }" ]
[ "0.7294933", "0.7273718", "0.7146523", "0.7146119", "0.7142695", "0.70446455", "0.69389105", "0.6906867", "0.6859224", "0.6850875", "0.6849529", "0.6826694", "0.68255013", "0.6818487", "0.68159056", "0.6802113", "0.6789685", "0.67788434", "0.676629", "0.67526984", "0.6724801", "0.66900855", "0.668497", "0.6671683", "0.66260725", "0.6620349", "0.66138816", "0.65759474", "0.65731657", "0.6544539", "0.6524479", "0.6521428", "0.65178657", "0.6445836", "0.64414674", "0.6440834", "0.64236176", "0.63169605", "0.63062733", "0.6260454", "0.62586224", "0.6256484", "0.6255707", "0.62551135", "0.6249595", "0.6245939", "0.6242947", "0.623778", "0.62308013", "0.6229703", "0.62202114", "0.6206471", "0.6195457", "0.6189605", "0.61676973", "0.61553395", "0.61472577", "0.6139971", "0.61385685", "0.6132826", "0.61306465", "0.61265486", "0.6121643", "0.6114911", "0.6103052", "0.6099316", "0.6062881", "0.6037701", "0.60344905", "0.6031911", "0.60251874", "0.60189503", "0.60189503", "0.6018247", "0.6009017", "0.60049075", "0.59746253", "0.5956556", "0.59486973", "0.5931263", "0.592253", "0.59155273", "0.5905066", "0.58754605", "0.5867754", "0.5855252", "0.58422697", "0.5841888", "0.5841888", "0.5841487", "0.58394796", "0.5830257", "0.58235484", "0.5818783", "0.57985955", "0.57976395", "0.5796334", "0.5782252", "0.5779588", "0.57714677" ]
0.72366315
2
Returns a string (horizontal) representation of a single column of the board.
public String colToString(int col) { if (!isValid(col)) { return INDEX_ERROR_MESSAGE; } StringBuilder sb = new StringBuilder(); for (int i = 0; i < dimension; i++) { sb.append(stateToString(i, col)).append(" "); } //remove the last unnecessary white space from the string. return sb.toString().substring(0, sb.length() - 1); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public String boardCellToString() {\n String str;\n Integer convertX, convertY;\n //adjusting the co'ordinates because the board starts at 1 not 0\n convertX=this.xCor + 1;\n convertY= this.yCor + 1;\n str = \"(\" + convertX.toString() + \",\" + convertY.toString() + \")\";\n return str;\n }", "private char getColumnName(int column) {\r\n\t\tchar result = '0';\r\n\t\tif (column >= 0 && column <= playBoard[0].length) {\r\n\t\t\tresult = (char) (column + 65);\r\n\t\t}\r\n\t\treturn result;\r\n\t}", "String getColumn();", "public String toString() {\n String bs = \" \"; // bs stands for board string\n for (int col = 0; col <= (this.boardSize - 1); col++) {\n bs = bs + (col + 1) + \" \";\n if (col < this.boardSize - 1) {\n bs = bs + \" \";\n }\n }\n bs = bs + \"\\n\";\n char rowHead = 'A';\n for (int row = 0; row <= (this.boardSize - 1); row++) {\n bs = bs + \" \" + rowHead++ + \" \";\n for (int col = 0; col < this.boardSize; ++col) {\n bs = bs + \" \" + this.board[row][col];\n if (col < this.boardSize - 1) {\n bs = bs + \" |\";\n }\n }\n bs = bs + \"\\n\";\n if (row < this.boardSize - 1) {\n bs = bs + \" \";\n for (int col = 0; col < this.boardSize; col++) {\n bs = bs + \"---\";\n if (col < this.boardSize - 1) {\n bs = bs + \"|\";\n }\n }\n }\n bs = bs + \"\\n\";\n }\n return bs;\n }", "public String getBoard() {\r\n\t\tString r = \"\";\r\n\t\tfor (int y = 0; y < 3; y++) {\r\n\t\t\tfor (int x = 0; x < 3; x++) {\r\n\t\t\t\tr = r + board[y][x];\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn r;\r\n\t}", "public String toString() {\n return String.format(\"%s%s\", column, row);\n }", "private int toColChar(int column)\n\t{\n\t\tint theCol;\n\t\tswitch (column)\n\t\t{\n\t\tcase 0: theCol = 1; break;\n\t\tcase 1: theCol = 2; break;\n\t\tcase 2: theCol = 3; break;\n\t\tdefault: theCol = -1;\n\t\t}\n\t\t\n\t\treturn theCol;\n\t}", "public void displayBoard() {\n newLine();\n for (int row = _board[0].length - 1; row >= 0; row -= 1) {\n String pair = new String();\n for (int col = 0; col < _board.length; col += 1) {\n pair += \"|\";\n pair += _board[col][row].abbrev();\n }\n System.out.println(pair + \"|\");\n newLine();\n }\n }", "public String toString()\n\t{\n\t\tchar rowLetter = (char)('A'+row);\n\t\treturn(\"\"+rowLetter+col);\n\t}", "java.lang.String getColumn();", "public String toString() {\n\n\t\tString result = \"\";\n\n\t\tfor(Cell[][] dim : board) {\n\t\t\tfor(Cell[] row : dim) {\n\t\t\t\tfor(Cell col : row) {\n\t\t\t\t\tif(col== Cell.E)\n\t\t\t\t\t\tresult += \"-\";\n\t\t\t\t\telse\n\t\t\t\t\t\tresult += col;\t\n\t\t\t\t}\n\t\t\t\tresult += \"\\n\";\n\t\t\t}\n\t\t\tresult += \"\\n\";\n\t\t}\n\n//\t\tSystem.out.println(\"\\n***********\\n\");\n\t\treturn result;\n\n\t}", "public String toString() {\n\t\tString str = \"\\n \";\n\t\tfor (int i = 1; i <= board.length; i++) {\n\t\t\tstr += i + \" \";\n\t\t}\n\t\tstr = str.stripTrailing() + \"\\n\";\n\t\tfor (int i = 0; i < board.length; i++) {\n\t\t\tstr += (i+1) + \" \";\n\t\t\tfor (int j = 0; j < board.length; j++) {\n\t\t\t\tif (board[i][j] == Disc.WHITE) {\n\t\t\t\t\tstr += \"W \";\n\t\t\t\t} else if (board[i][j] == Disc.BLACK) {\n\t\t\t\t\tstr += \"B \";\n\t\t\t\t} else {\n\t\t\t\t\tstr += \"- \";\n\t\t\t\t}\n\t\t\t}\n\t\t\tstr = str.stripTrailing() + \"\\n\";\n\t\t}\n\t\treturn str;\n\t}", "public String toString() {\n\t\t// This method is provided for debugging purposes\n\t\t// (use/modify as much as you'd like), it just prints\n\t\t// out the column for easy viewing.\n\t\tStringBuilder s = new StringBuilder(\"Column with \" + size() + \" items and a capacity of \" + capacity() + \":\");\n\t\tfor (int i = 0; i < size(); i++) {\n\t\t\ts.append(\"\\n [\" + i + \"]: \" + get(i));\n\t\t}\n\t\treturn s.toString();\n\n\t}", "@Override\n\tpublic String toString(){\n\t\t// return a string of the board representation following these rules:\n\t\t// - if printed, it shows the board in R rows and C cols\n\t\t// - every cell should be represented as a 5-character long right-aligned string\n\t\t// - there should be one space between columns\n\t\t// - use \"-\" for empty cells\n\t\t// - every row ends with a new line \"\\n\"\n\t\t\n\t\t\n\t\tStringBuilder sb = new StringBuilder(\"\");\n\t\tfor (int i=0; i<numRows; i++){\n\t\t\tfor (int j =0; j<numCols; j++){\n\t\t\t\tPosition pos = new Position(i,j);\n\t\t\t\t\n\t\t\t\t// use the hash table to get the symbol at Position(i,j)\n\t\t\t\tif (grid.contains(pos))\n\t\t\t\t\tsb.append(String.format(\"%5s \",this.get(pos)));\n\t\t\t\telse\n\t\t\t\t\tsb.append(String.format(\"%5s \",\"-\")); //empty cell\n\t\t\t}\n\t\t\tsb.append(\"\\n\");\n\t\t}\n\t\treturn sb.toString();\n\n\t}", "public String toString() {\n \t// string representation of the board (in the output format specified below)\n \tStringBuilder sb = new StringBuilder(dimension() + \" \\n \");\n \t\n \tfor (int row = 0; row < dimension(); row++) {\n \t\tfor (int column = 0; column < dimension(); column++) {\n \t\t\tsb.append(blocks[row][column]);\n \t\t\tsb.append(\" \");\n \t\t}\n \t\t\n \t\tsb.append(\"\\n \");\n \t}\n \t\n \treturn sb.toString();\n }", "public String toString() {\n\tString str = \"\";\n\tfor (int i = 0; i < board.length; i++) {\n\t str = str + \"\\n\";\n\t for (int j = 0; j <= (board.length - 1); j++)\n\t\tstr = \" \" + str + board[i][j] + \" \";\n\t}\n\treturn str;\n }", "public String toString() {\n StringBuilder sb = new StringBuilder();\n\n for (int i = 0; i < SIZE; i++) {\n for (int j = 0; j < SIZE; j++) {\n sb.append(board[i][j]);\n sb.append(\" \");\n }\n sb.append(\"\\n\");\n }\n return sb.toString();\n }", "public String toString() {\n String result = \"\";\n if (this.column > 0 && this.row > 0) {\n int column = this.column, exp = (int) (Math.log(column) / Math.log(26)), cur;\n for (int i = exp; i >= 0; i--) {\n cur = (int) (column / Math.pow(26, i));\n result += (char) (64 + cur);\n column -= cur * Math.pow(26, i);\n }\n result += this.row;\n }\n return result;\n }", "public int getColumn();", "int getColumn();", "public String toString() {\n String returnString = \"\";\n returnString = returnString + \"\\r\\n\";\n for (int i = 0; i < rows + 1; i++) {\n for (int j = 0; j < cols + 1; j++) {\n if (i == 0 && j == 0) {\n returnString = returnString + \" \";\n continue;\n }\n if (i == 0) {\n if (j > 0) {\n returnString = returnString + (j + \" \");\n }\n if (j == 8) {\n returnString = returnString + \"\\r\\n\";\n }\n } else {\n if (j > 0) {\n if (!isEmpty(i - 1, j - 1)) {\n returnString = returnString + (getBoard()[i - 1][j - 1] + \" \");\n } else {\n returnString = returnString + \" \";\n }\n }\n }\n if (j == 0) {\n returnString = returnString + (i + \" \");\n }\n\n }\n returnString = returnString + \"\\r\\n\";\n }\n return returnString;\n }", "public String toString () {\n return \"(\" + col + \",\" + row + \")\";\n }", "public String toString() {\n String boardString = \"\";\n for (int j = 0; j < nRows; j++) {\n String row = \"\";\n for (int i = 0; i < nCols; i++) {\n if (board[j][i] == null) {\n row = row + \"Empty \";\n } else {\n row = row + board[j][i].getType() + \" \";\n }\n }\n boardString = boardString + row + \"\\n\";\n }\n return boardString;\n }", "public String toString(){\n\t\tString board = \"\";\n\t\tfor(int i = 0; i < rows; i++){\n\t\t\tfor(int j = 0; j < columns; j++){\n\t\t\t\tif(theGrid[i][j]){ //iterate through, if cell is alive, mark with *\n\t\t\t\t\tboard += \"*\";\n\t\t\t\t}\n\t\t\t\telse{\n\t\t\t\t\tboard += \" \"; //else, [space]\n\t\t\t\t}\n\t\t\t}\n\t\t\tboard += \"\\n\";//create a new line, to create the board\n\t\t}\n\t\treturn board; //return the board\n\t}", "public String toString() {\n StringBuilder s = new StringBuilder(); // Initialize new string builder\n s.append(N + \"\\n\"); // Append board dimension to string\n\n for (int[] row : tiles) {\n for (int tile : row)\n s.append(String.format(\"%2d \", tile)); // Append formatted board tiles string\n s.append(\"\\n\"); // Append new line to string\n }\n return s.toString(); // Return string representation of board\n }", "public String toString() {\n\t\tString temp = \"\";\n\t\tfor (int i = 0; i < 10; i++) {\n\t\t\ttemp += String.format(\"%d \", i);\n\t\t}\n\t\ttemp += \"\\n\";\n\t\tfor (int i = 0; i < 9; i++) {\n\t\t\ttemp += String.format(\"%d | \", i + 1);\n\t\t\tfor (int j = 0; j < 9; j++) {\n\t\t\t\ttemp += String.format(\"%c | \", board[i][j]);\n\t\t\t}\n\t\t\ttemp += \"\\n\";\n\t\t}\n\t\treturn temp;\n\t}", "public String toString() {\n StringBuilder s = new StringBuilder();\n s.append(dim + \"\\n\");\n for (int i = 0; i < dim; i++) {\n for (int j = 0; j < dim; j++) {\n s.append(String.format(\"%2d \", board[i][j]));\n }\n s.append(\"\\n\");\n }\n return s.toString();\n }", "public String toString()\n\t{\n\t\tString s = \"\";\n\t\tfor(int r = 0; r < board.length; r++)\n\t\t{\n\t\t\tfor(int c = 0; c < board[0].length; c++)\n\t\t\t{\n\t\t\t\ts += \"|\" + board[r][c];\n\t\t\t}\t\t\t\t\n\t\t\ts += \"|\" + \"\\n\" + \"-------------------\" + \"\\n\";\n\t\t}\n\t\treturn s;\n\t}", "public String getColumnone() {\n return columnone;\n }", "public void printBoard() {\r\n // Print column numbers.\r\n System.out.print(\" \");\r\n for (int i = 0; i < BOARD_SIZE; i++) {\r\n System.out.printf(\" %d \", i+1);\r\n }\r\n System.out.println(\"\\n\");\r\n\r\n\r\n for (int i = 0; i < BOARD_SIZE; i++) {\r\n System.out.printf(\"%c %c \", 'A' + i, board[i][0].mark);\r\n\r\n for (int j = 1; j < BOARD_SIZE; j++) {\r\n System.out.printf(\"| %c \", board[i][j].mark);\r\n }\r\n\r\n System.out.println(\"\");\r\n\r\n if (i < BOARD_SIZE - 1) {\r\n System.out.print(\" \");\r\n for (int k = 1; k < BOARD_SIZE * 3 + BOARD_SIZE; k++) {\r\n System.out.print(\"-\");\r\n }\r\n System.out.println(\"\");\r\n }\r\n }\r\n System.out.println(\"\");\r\n }", "public void displayBoard()\n {\n System.out.println(\"\");\n System.out.println(\" Game Board \");\n System.out.println(\" ---------------------------------\");\n for (int i = 0; i < ROW; i++)\n {\n System.out.print(i+1 + \" | \");\n for (int j = 0; j < COL; j++)\n {\n //board[i][j] = \"A\";\n System.out.print(board[i][j].getPieceName() + \" | \");\n }\n System.out.println();\n }\n System.out.println(\" ---------------------------------\");\n\n System.out.println(\" a b c d e f g h \");\n }", "public int col() {\r\n return col;\r\n }", "public int getColumn() {\n return col;\n }", "public int col() {\r\n\t\treturn col;\r\n\t}", "public String toString() {\r\n return \"Row: \" + this.row + \"Column: \"+ this.col;\r\n }", "int getCol();", "public String getColumn() {\n Object ref = column_;\n if (!(ref instanceof String)) {\n com.google.protobuf.ByteString bs =\n (com.google.protobuf.ByteString) ref;\n String s = bs.toStringUtf8();\n column_ = s;\n return s;\n } else {\n return (String) ref;\n }\n }", "public char getColumn() {\n\t\treturn column;\n\t}", "public int getColumn()\n\t{\n\t\treturn col;\n\t}", "private static char horizontalCoordinateForUser(int horizontalCoordinateForDeveloper){\n //column (1,2,3 instead of 0,1,2)\n return (char)((int) '1' + horizontalCoordinateForDeveloper);\n }", "int getColumn(int x, int y){\n return board[x][y].getColumn();\n }", "public int getColumn()\n {\n return col;\n }", "public String toString() {\n return row + \",\" + col;\n }", "@Override\n public String toString() {\n return columnToChar(c1) + \"\" + (8 - r1) + columnToChar(c2) + \"\" + (8 - r2);\n }", "String getColumn(int index);", "String getColumn(int index);", "public int getCol(){\r\n\t\treturn this.column;\r\n\t}", "public String getColumnName(int columnIndex)\r\n {\r\n return \" \";\r\n }", "public int getColumn()\t \t\t{ return column; \t}", "@Override\r\n public String toString() { return new String( \"(\" + row + \", \" + col + \")\" ); }", "public static void printBoard() {\n int separatorLen = 67;\n StringBuilder boardString = new StringBuilder();\n boardString.append(new String(new char [separatorLen]).replace(\"\\0\",\"*\"));\n boardString.append(\"\\n\");\n for(int y = Y_UPPER_BOUND - 1; y >= 0; y--)\n {\n boardString.append(y + 1).append(\" \");\n boardString.append(\"*\");\n for (int x = 0; x < X_UPPER_BOUND; x++)\n {\n Piece p = Board.board[x + y * X_UPPER_BOUND];\n if(p != null)\n {\n boardString.append(\" \").append(p).append(p.getColor()? \"-B\":\"-W\").append(\" \").append((p.toString().length() == 1? \" \":\"\"));\n }\n else\n {\n boardString.append(\" \");\n }\n boardString.append(\"*\");\n }\n boardString.append(\"\\n\").append((new String(new char [separatorLen]).replace(\"\\0\",\"*\"))).append(\"\\n\");\n }\n boardString.append(\" \");\n for(char c = 'A'; c <= 'H';c++ )\n {\n boardString.append(\"* \").append(c).append(\" \");\n }\n boardString.append(\"*\\n\");\n System.out.println(boardString);\n }", "@Override\n public String toString() {\n String returnBoard = \" \";\n for (int i = 1; i <= 3; i++) {\n returnBoard=returnBoard+\" \" +Integer.toString(i);\n }\n returnBoard+=\"\\n\";\n for (int i = 1; i <= 3; i++) {\n returnBoard+= Integer.toString(i);\n for (int j = 1; j <= 3; j++) {\n returnBoard = returnBoard + \" \" + board[i-1][j-1].toString();\n }\n returnBoard+=\"\\n\";\n }\n return returnBoard;\n }", "public int getCol() {\n\t\treturn column; \n\t}", "String getBoardString();", "public CellCoord nextColumn() {\n return new CellCoord(column + 1, row);\n }", "public static void displayboard(String board[][]){\n\t\tint rowindicator[]=new int[boardwidth+1];\n\t\tint rowcount=1;\n\t\tfor(int i=1;i<=boardwidth;i++){\n\t\t\trowindicator[i]=rowcount;\n\t\t\trowcount++;\n\t\t}\n\t\tint columnindicator[]=new int[boardlength+1];\n\t\tint columncount=1;\n\t\tfor(int i=1;i<=boardlength;i++){\n\t\t\tcolumnindicator[i]=columncount;\n\t\t\tcolumncount++;\n\t\t}\n\t\tSystem.out.print(\"\\n \");\n\t\tfor(int i=1;i<=boardlength;i++){\n\t\t\t//displays column indicator\n\t\t\tSystem.out.print(\" \"+columnindicator[i]);\n\t\t}\n\t\t//displays board\n\t\tSystem.out.println(\"\");\n\t\tfor(int x=1;x<=boardwidth;x++){\n\t\t\t//displays row indicator\n\t\t\tSystem.out.print(\" \"+rowindicator[x]);\n\t\t\tfor(int i=1;i<=boardlength;i++){\n\t\t\t\tSystem.out.print(\" \"+board[x][i]);\n\t\t\t}\n\t\t\tSystem.out.println();\n\t\t}\n\t}", "@Override\n public String getColumn() {\n Object ref = column_;\n if (ref instanceof String) {\n return (String) ref;\n } else {\n com.google.protobuf.ByteString bs =\n (com.google.protobuf.ByteString) ref;\n String s = bs.toStringUtf8();\n column_ = s;\n return s;\n }\n }", "public String drawBoard() {\n fillBoard();\n return \"\\n\" +\n \" \" + boardArray[0][0] + \" | \" + boardArray[0][1] + \" | \" + boardArray[0][2] + \" \\n\" +\n \"------------\\n\" +\n \" \" + boardArray[1][0] + \" | \" + boardArray[1][1] + \" | \" + boardArray[1][2] + \" \\n\" +\n \"------------\\n\" +\n \" \" + boardArray[2][0] + \" | \" + boardArray[2][1] + \" | \" + boardArray[2][2] + \" \\n\";\n }", "public int getColumn() {\r\n\t\treturn this.col;\r\n\t}", "public static void printBoard(){\n \n System.out.println(board[0][0] + \" | \" + board[0][1] + \" | \" + board[0][2]);\n System.out.println(board[1][0] + \" | \" + board[1][1] + \" | \" + board[1][2]);\n System.out.println(board[2][0] + \" | \" + board[2][1] + \" | \" + board[2][2]);\n \n }", "public int getCol() { return _col; }", "private static void printMatrix(char[][] board) {\n\t\tint row = board.length;\n\t\tint col = board[0].length;\n\t\tfor(int i=0; i<row; i++){\n\t\t\t\n\t\t\tfor(int j=0; j<col; j++){\n\t\t\t\t\n\t\t\t\tSystem.out.print(\" \" + board[i][j]+\"\");\n\t\t\t}\n\t\t\tSystem.out.println();\n\t\t}\n\t\t\n\t\tSystem.out.println();\n\t}", "public String toString() {\n String result = \"\";\n result += \" \";\n // Column numbers\n for (int i = 0; i < numberOfColumns; i++) {\n result += (i % 10) + \" \";\n }\n result += \"\\n\";\n result += \" \";\n // Horizontal dividers\n for (int i = 0; i <= 2 * this.numberOfColumns - 2 ; i++) {\n result += HORI_DIVIDE;\n }\n result += \"\\n\";\n // Each horizontal line has the line number, a divider, and the safe data.\n for (int i = 0; i < numberOfRows; i++) {\n result += (i % 10);\n result += VERT_DIVIDE;\n for (int j = 0; j < numberOfColumns; j++) {\n result += grid[i][j];\n if (j != numberOfColumns - 1) {\n result += \" \";\n }\n }\n if (i != numberOfRows - 1) {\n result += \"\\n\";\n }\n }\n return result;\n }", "public int getColumn() {\n return mCol;\n }", "private char convertSeatColToString(int col) {\n return ((char) (col + CONVERT_NUM_TO_CHAR));\n }", "public int getColumn()\n {\n return column;\n }", "public String toString() {\n\t\t// Variables\n\t\tString gameboard;\n\t\tchar[] firstLetter = { 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O' };\n\n\t\t// Top\n\t\tgameboard = \" ===============================================================\\n\";\n\n\t\t// Middle\n\t\tfor (int i = 0; i < 15; i++) {\n\t\t\t// Beginning of the line\n\t\t\tgameboard += \" \" + firstLetter[i] + \" ||\";\n\n\t\t\t// Letters\n\t\t\tfor (int j = 0; j < 15; j++) {\n\t\t\t\tif (this.grid[i][j].getTile().getLetter() == Character.MIN_VALUE) {\n\t\t\t\t\tif (this.grid[i][j].getScoreMult() > 1)\n\t\t\t\t\t\tgameboard += \" * \";\n\t\t\t\t\telse\n\t\t\t\t\t\tgameboard += \" . \";\n\t\t\t\t} else {\n\t\t\t\t\tgameboard += \" \" + this.grid[i][j].getTile().getLetter() + \" \";\n\t\t\t\t}\n\t\t\t\tif (j != 14)\n\t\t\t\t\tgameboard += '|';\n\t\t\t}\n\n\t\t\t// End of the line\n\t\t\tgameboard += \"||\\n\";\n\t\t\tif (i != 14)\n\t\t\t\tgameboard += \" ||---|---|---|---|---|---|---|---|---|---|---|---|---|---|---||\\n\";\n\t\t}\n\n\t\t// Bottom\n\t\tgameboard += \" ===============================================================\\n\";\n\t\tgameboard += \" 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15\";\n\n\t\treturn gameboard;\n\t}", "public String getBoardOverview() {\n String boardOverview = \"\";\n\n for (int y = 0; y < this.boardSize; y++) {\n for (int x = 0; x < this.boardSize; x++) {\n char StoneColor = ' ';\n\n if (!this.fields[x][y].isEmpty()) {\n switch (this.fields[x][y].getStone().getColor()) {\n case BLACK:\n StoneColor = 'B';\n break;\n case WHITE:\n StoneColor = 'W';\n break;\n }\n } else if (this.fields[x][y].isPossibleMove()) {\n StoneColor = 'x';\n }\n\n boardOverview = boardOverview + StoneColor;\n\n }\n // next line\n boardOverview = boardOverview + String.format(\"%n\");\n }\n\n return boardOverview;\n }", "@Override\r\n public int getCol() {\r\n return this.col;\r\n }", "Column getCol();", "public int getCol() {\n return col;\n }", "private String encodedBoard() {\r\n char[] result = new char[Square.SQUARE_LIST.size() + 1];\r\n result[0] = turn().toString().charAt(0);\r\n for (Square sq : SQUARE_LIST) {\r\n result[sq.index() + 1] = get(sq).toString().charAt(0);\r\n }\r\n return new String(result);\r\n }", "public int getColumn() {\r\n return column;\r\n }", "public int getColumn() {\r\n return column;\r\n }", "public int getCol() {\r\n return this.col;\r\n }", "private int getColumn() {\n return binaryPartition(column);\n }", "private void displayColumn(BoardMap map){\n System.out.print(\" \");\n for (int i = 0 ; i < map.getWidth() ; i++){\n if(i < 10){\n System.out.print(i + \" \");\n\n } else {\n System.out.print(i + \" \");\n }\n }\n System.out.println();\n }", "public int getColumn() {\r\n\t\treturn column;\r\n\t}", "public int getColumn() {\n return column;\n }", "public int getColumn() {\n return column;\n }", "public int getColumn() {\n return column;\n }", "protected int getCol() {\r\n\t\treturn this.col;\r\n\t}", "public String getSlackRepresentationOfBoard() {\n String boardBorders[] = {\"```| \",\n \" | \",\n \" | \",\n \" |\\n|---+---+---|\\n| \",\n \" | \",\n \" | \",\n \" |\\n|---+---+---|\\n| \",\n \" | \",\n \" | \",\n \" |```\"};\n int boardBordersIndex = 0;\n StringBuilder boardString = new StringBuilder();\n for(int row = 0; row < BOARD_SIZE; row ++ ){\n for(int col = 0; col <BOARD_SIZE; col ++ ){\n boardString.append( boardBorders[boardBordersIndex] );\n boardString.append( getTokenAsCharFromBoardPosition(row, col, boardBordersIndex+1));\n boardBordersIndex++;\n }\n }\n boardString.append( boardBorders[boardBordersIndex] );\n return boardString.toString();\n }", "public int getColumn() {\n\t\treturn column;\n\t}", "public int getColumn()\n\t\t{\n\t\t\treturn m_col;\n\t\t}", "@Override\n public int getCol() {\n return getLayout().getCol();\n }", "@Override\n public String toString() {\n StringBuilder sb = new StringBuilder();\n\n //Print board\n int c = 0;\n for (Piece piece : board) {\n if (piece == null) {\n sb.append(\"\\t\");\n } else {\n sb.append(piece.pieceString()).append(\"\\t\");\n }\n if (++c % 4 == 0) {\n sb.append(\"\\n\");\n }\n }\n sb.append(\"\\n\");\n\n return sb.toString();\n }", "public String toString() {\n\t\t// Converts column\n\t\tString columnStr = \"\";\n\t\tfor (int tempColumn = cell.getAddress().getColumn();\n\t\t\t\ttempColumn >= 0; tempColumn = tempColumn\n\t\t\t\t\t/ (Address.HIGHEST_CHAR - Address.LOWEST_CHAR + 1) - 1)\n\t\t\tcolumnStr = ((char)((char)(tempColumn % (Address.HIGHEST_CHAR\n\t\t\t\t- Address.LOWEST_CHAR + 1)) + Address.LOWEST_CHAR)) + columnStr;\n\t\tif (columnAbsolute)\n\t\t\tcolumnStr = ABSOLUTE_OPERATOR + columnStr;\n\n\t\t// Converts row\n\t\tString rowStr = (rowAbsolute ? ABSOLUTE_OPERATOR : \"\")\n\t\t\t+ (cell.getAddress().getRow() + 1);\n\t\treturn columnStr + rowStr;\n\t}", "private String gameBoardToString(){\n StringBuilder config = new StringBuilder();\n\n //length attribute gets the number of rows in a 2D array. length attribute on a row gets the number of columns in a\n // 2D array. We iterate through all the rows and columns and join all the characters in the array into a single\n // String config\n\n for (int i = 0; i < this.boardRows; i++){\n for (int j =0; j < this.boardColumns; j++){\n config.append(this.gameBoard[i][j]);\n }\n }\n\n // Returns String object representation of StringBuilder object\n return config.toString();\n\n }", "@Override\n public String toString() {\n\treturn \"\"+rowIndex+colIndex; \n }", "public final int getColumn() {\n return column;\n }", "public int getColumn() { return cc; }", "public String toString() {\n String s = \"\";\n for(int i = 1; i <= rows; i++){\n for(int j = 1; j <= cols; j++){ \n s = s + String.format(\"%2d\",m[i][j]) + \" \";\n }\n s += \"\\n\";\n }\n return s;\n }", "public int getColumn() {\n\t\t\treturn column;\n\t\t}", "public int getColumn()\r\n\t{\r\n\t\treturn this.column;\r\n\t}", "public static String printSelectCol1() {\n return \"Choose card 1 and write the corresponding col (Only choose Ints between 1 - 5 or 0 to quit) : \";\n }", "public void printBoard()\n {\n // Print column numbers;\n System.out.print(\" \");\n for (int index = 0; index < columns; index++)\n System.out.print(\" \" + index);\n\n System.out.println();\n\n // Print the row numbers and the board contents.\n for (int index = 0; index < rows; index++)\n {\n System.out.print(index);\n\n for (int index2 = 0; index2 < columns; index2++)\n System.out.print(\" \" + board[index][index2]);\n\n System.out.println();\n }\n\n }", "public int getCurrentPawnColumn(){\r\n GamePosition curPos = currentGame.getCurrentPosition();\n\t\tPlayer white = currentGame.getWhitePlayer();\n\t\tif(curPos.getPlayerToMove().equals(white)) {\n\t\t\treturn curPos.getWhitePosition().getTile().getColumn();\n\t\t\n\t\t} else {\n\t\t\treturn curPos.getBlackPosition().getTile().getColumn();\n\t\t}\r\n }", "public static void displayBoard(char[][] a){\r\n int rowNumber = a.length;\r\n int colNumber = a[0].length;\r\n for (int i = 0; i<rowNumber;i++){\r\n rowLine(colNumber);\r\n for (int j = 0; j<colNumber;j++){\r\n System.out.print('|');\r\n System.out.print(a[i][j]);\r\n }\r\n System.out.println('|');\r\n }\r\n rowLine(colNumber);\r\n }", "public int getCol()\n\t{\n\t\treturn col;\n\t}" ]
[ "0.6943318", "0.69309753", "0.6882265", "0.67920846", "0.66699064", "0.6641938", "0.66356874", "0.6616836", "0.6608309", "0.65922916", "0.6553194", "0.65320086", "0.6479835", "0.64783245", "0.6445527", "0.64170694", "0.64150494", "0.64034355", "0.640313", "0.6379349", "0.63785475", "0.63735056", "0.6371365", "0.63627774", "0.63483846", "0.63228714", "0.6321257", "0.6309482", "0.6296464", "0.62963974", "0.6293564", "0.6289323", "0.62735397", "0.62734604", "0.6268223", "0.62471986", "0.6243793", "0.62371355", "0.62342405", "0.62319463", "0.6217615", "0.621507", "0.6209982", "0.6206177", "0.6201322", "0.6201322", "0.6196936", "0.61904496", "0.618245", "0.61817044", "0.6178857", "0.61669064", "0.615631", "0.61561376", "0.6146942", "0.613466", "0.61263883", "0.6117463", "0.6117031", "0.610045", "0.6098266", "0.60966223", "0.6088104", "0.60853326", "0.6081585", "0.6079827", "0.6079533", "0.6079492", "0.6077028", "0.607575", "0.60700727", "0.60691994", "0.60684186", "0.60684186", "0.6066612", "0.606021", "0.6059176", "0.60514", "0.60463274", "0.60463274", "0.60463274", "0.6031643", "0.6025769", "0.60205823", "0.6018387", "0.6018213", "0.60082173", "0.6003561", "0.59905815", "0.5982833", "0.59824604", "0.59761184", "0.59666795", "0.59570825", "0.5956973", "0.59514904", "0.59500104", "0.5947657", "0.5946949", "0.59422123" ]
0.6275662
32
Returns a string representation from the board.
@Override public String toString() { StringBuilder sb = new StringBuilder(); for (int i = 0; i < dimension; i++) { sb.append(rowToString(i)).append("\n"); } //remove the last unnecessary carriage return from the string. return sb.toString().substring(0, sb.length() - 1); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "String getBoardString();", "public String toString()\n\t{\n\t\tString s = \"\";\n\t\tfor(int r = 0; r < board.length; r++)\n\t\t{\n\t\t\tfor(int c = 0; c < board[0].length; c++)\n\t\t\t{\n\t\t\t\ts += \"|\" + board[r][c];\n\t\t\t}\t\t\t\t\n\t\t\ts += \"|\" + \"\\n\" + \"-------------------\" + \"\\n\";\n\t\t}\n\t\treturn s;\n\t}", "public String getBoard() {\r\n\t\tString r = \"\";\r\n\t\tfor (int y = 0; y < 3; y++) {\r\n\t\t\tfor (int x = 0; x < 3; x++) {\r\n\t\t\t\tr = r + board[y][x];\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn r;\r\n\t}", "public String boardCellToString() {\n String str;\n Integer convertX, convertY;\n //adjusting the co'ordinates because the board starts at 1 not 0\n convertX=this.xCor + 1;\n convertY= this.yCor + 1;\n str = \"(\" + convertX.toString() + \",\" + convertY.toString() + \")\";\n return str;\n }", "public String toString() {\n String boardString = \"\";\n for (int j = 0; j < nRows; j++) {\n String row = \"\";\n for (int i = 0; i < nCols; i++) {\n if (board[j][i] == null) {\n row = row + \"Empty \";\n } else {\n row = row + board[j][i].getType() + \" \";\n }\n }\n boardString = boardString + row + \"\\n\";\n }\n return boardString;\n }", "@Override\n public String toString() {\n StringBuilder sb = new StringBuilder();\n\n //Print board\n int c = 0;\n for (Piece piece : board) {\n if (piece == null) {\n sb.append(\"\\t\");\n } else {\n sb.append(piece.pieceString()).append(\"\\t\");\n }\n if (++c % 4 == 0) {\n sb.append(\"\\n\");\n }\n }\n sb.append(\"\\n\");\n\n return sb.toString();\n }", "public String toString() {\n StringBuilder s = new StringBuilder(); // Initialize new string builder\n s.append(N + \"\\n\"); // Append board dimension to string\n\n for (int[] row : tiles) {\n for (int tile : row)\n s.append(String.format(\"%2d \", tile)); // Append formatted board tiles string\n s.append(\"\\n\"); // Append new line to string\n }\n return s.toString(); // Return string representation of board\n }", "public String toString() {\n\tString str = \"\";\n\tfor (int i = 0; i < board.length; i++) {\n\t str = str + \"\\n\";\n\t for (int j = 0; j <= (board.length - 1); j++)\n\t\tstr = \" \" + str + board[i][j] + \" \";\n\t}\n\treturn str;\n }", "public static String printBoard(Game board) {\n return board.toString();\n }", "public String toString() {\n\t\tString str = \"\\n \";\n\t\tfor (int i = 1; i <= board.length; i++) {\n\t\t\tstr += i + \" \";\n\t\t}\n\t\tstr = str.stripTrailing() + \"\\n\";\n\t\tfor (int i = 0; i < board.length; i++) {\n\t\t\tstr += (i+1) + \" \";\n\t\t\tfor (int j = 0; j < board.length; j++) {\n\t\t\t\tif (board[i][j] == Disc.WHITE) {\n\t\t\t\t\tstr += \"W \";\n\t\t\t\t} else if (board[i][j] == Disc.BLACK) {\n\t\t\t\t\tstr += \"B \";\n\t\t\t\t} else {\n\t\t\t\t\tstr += \"- \";\n\t\t\t\t}\n\t\t\t}\n\t\t\tstr = str.stripTrailing() + \"\\n\";\n\t\t}\n\t\treturn str;\n\t}", "public String toString() {\n String bs = \" \"; // bs stands for board string\n for (int col = 0; col <= (this.boardSize - 1); col++) {\n bs = bs + (col + 1) + \" \";\n if (col < this.boardSize - 1) {\n bs = bs + \" \";\n }\n }\n bs = bs + \"\\n\";\n char rowHead = 'A';\n for (int row = 0; row <= (this.boardSize - 1); row++) {\n bs = bs + \" \" + rowHead++ + \" \";\n for (int col = 0; col < this.boardSize; ++col) {\n bs = bs + \" \" + this.board[row][col];\n if (col < this.boardSize - 1) {\n bs = bs + \" |\";\n }\n }\n bs = bs + \"\\n\";\n if (row < this.boardSize - 1) {\n bs = bs + \" \";\n for (int col = 0; col < this.boardSize; col++) {\n bs = bs + \"---\";\n if (col < this.boardSize - 1) {\n bs = bs + \"|\";\n }\n }\n }\n bs = bs + \"\\n\";\n }\n return bs;\n }", "@Override\n\tpublic String toString(){\n\t\t// return a string of the board representation following these rules:\n\t\t// - if printed, it shows the board in R rows and C cols\n\t\t// - every cell should be represented as a 5-character long right-aligned string\n\t\t// - there should be one space between columns\n\t\t// - use \"-\" for empty cells\n\t\t// - every row ends with a new line \"\\n\"\n\t\t\n\t\t\n\t\tStringBuilder sb = new StringBuilder(\"\");\n\t\tfor (int i=0; i<numRows; i++){\n\t\t\tfor (int j =0; j<numCols; j++){\n\t\t\t\tPosition pos = new Position(i,j);\n\t\t\t\t\n\t\t\t\t// use the hash table to get the symbol at Position(i,j)\n\t\t\t\tif (grid.contains(pos))\n\t\t\t\t\tsb.append(String.format(\"%5s \",this.get(pos)));\n\t\t\t\telse\n\t\t\t\t\tsb.append(String.format(\"%5s \",\"-\")); //empty cell\n\t\t\t}\n\t\t\tsb.append(\"\\n\");\n\t\t}\n\t\treturn sb.toString();\n\n\t}", "private String gameBoardToString(){\n StringBuilder config = new StringBuilder();\n\n //length attribute gets the number of rows in a 2D array. length attribute on a row gets the number of columns in a\n // 2D array. We iterate through all the rows and columns and join all the characters in the array into a single\n // String config\n\n for (int i = 0; i < this.boardRows; i++){\n for (int j =0; j < this.boardColumns; j++){\n config.append(this.gameBoard[i][j]);\n }\n }\n\n // Returns String object representation of StringBuilder object\n return config.toString();\n\n }", "public String toString() {\n \t// string representation of the board (in the output format specified below)\n \tStringBuilder sb = new StringBuilder(dimension() + \" \\n \");\n \t\n \tfor (int row = 0; row < dimension(); row++) {\n \t\tfor (int column = 0; column < dimension(); column++) {\n \t\t\tsb.append(blocks[row][column]);\n \t\t\tsb.append(\" \");\n \t\t}\n \t\t\n \t\tsb.append(\"\\n \");\n \t}\n \t\n \treturn sb.toString();\n }", "public String toString() {\n\n\t\tString result = \"\";\n\n\t\tfor(Cell[][] dim : board) {\n\t\t\tfor(Cell[] row : dim) {\n\t\t\t\tfor(Cell col : row) {\n\t\t\t\t\tif(col== Cell.E)\n\t\t\t\t\t\tresult += \"-\";\n\t\t\t\t\telse\n\t\t\t\t\t\tresult += col;\t\n\t\t\t\t}\n\t\t\t\tresult += \"\\n\";\n\t\t\t}\n\t\t\tresult += \"\\n\";\n\t\t}\n\n//\t\tSystem.out.println(\"\\n***********\\n\");\n\t\treturn result;\n\n\t}", "public String toString() {\n StringBuilder sb = new StringBuilder();\n\n for (int i = 0; i < SIZE; i++) {\n for (int j = 0; j < SIZE; j++) {\n sb.append(board[i][j]);\n sb.append(\" \");\n }\n sb.append(\"\\n\");\n }\n return sb.toString();\n }", "private String encodedBoard() {\r\n char[] result = new char[Square.SQUARE_LIST.size() + 1];\r\n result[0] = turn().toString().charAt(0);\r\n for (Square sq : SQUARE_LIST) {\r\n result[sq.index() + 1] = get(sq).toString().charAt(0);\r\n }\r\n return new String(result);\r\n }", "public String getSlackRepresentationOfBoard() {\n String boardBorders[] = {\"```| \",\n \" | \",\n \" | \",\n \" |\\n|---+---+---|\\n| \",\n \" | \",\n \" | \",\n \" |\\n|---+---+---|\\n| \",\n \" | \",\n \" | \",\n \" |```\"};\n int boardBordersIndex = 0;\n StringBuilder boardString = new StringBuilder();\n for(int row = 0; row < BOARD_SIZE; row ++ ){\n for(int col = 0; col <BOARD_SIZE; col ++ ){\n boardString.append( boardBorders[boardBordersIndex] );\n boardString.append( getTokenAsCharFromBoardPosition(row, col, boardBordersIndex+1));\n boardBordersIndex++;\n }\n }\n boardString.append( boardBorders[boardBordersIndex] );\n return boardString.toString();\n }", "public String toString() {\n String returnString = \"\";\n returnString = returnString + \"\\r\\n\";\n for (int i = 0; i < rows + 1; i++) {\n for (int j = 0; j < cols + 1; j++) {\n if (i == 0 && j == 0) {\n returnString = returnString + \" \";\n continue;\n }\n if (i == 0) {\n if (j > 0) {\n returnString = returnString + (j + \" \");\n }\n if (j == 8) {\n returnString = returnString + \"\\r\\n\";\n }\n } else {\n if (j > 0) {\n if (!isEmpty(i - 1, j - 1)) {\n returnString = returnString + (getBoard()[i - 1][j - 1] + \" \");\n } else {\n returnString = returnString + \" \";\n }\n }\n }\n if (j == 0) {\n returnString = returnString + (i + \" \");\n }\n\n }\n returnString = returnString + \"\\r\\n\";\n }\n return returnString;\n }", "public String toString(){\n\t\tchar[][] boardRep = new char[yDim + 2][xDim + 2];\n\t\t\n\t\tfor(int i = 0; i < boardRep.length; i++){\n\t\t\tfor(int j = 0; j < boardRep[i].length; j++){\n\t\t\t\tboardRep[i][j] = ' ';\n\t\t\t}\n\t\t}\n\t\t\n\t\tfor(int i = 0; i < yDim + 2; i++){\n\t\t\tboardRep[i][0] = '.';\n\t\t\tboardRep[i][xDim + 1] = '.';\n\t\t}\n\t\t\n\t\tfor(int i = 0; i < xDim + 2; i++){\n\t\t\tboardRep[0][i] = '.';\n\t\t\tboardRep[yDim + 1][i] = '.';\n\t\t}\n\t\t\n\t\tfor (Gadget g : gadgets){\n\t\t\tif(g instanceof SquareBumper){\n\t\t\t\tboardRep[g.getY() + 1][g.getX() + 1]= '#';\n\t\t\t}else if(g instanceof TriangularBumper){\n\t\t\t\tif(((TriangularBumper) g).getOrientation() % 2 == 0)\t\n\t\t\t\t\tboardRep[g.getY() + 1][g.getX() + 1]= '/';\n\t\t\t\tif(((TriangularBumper) g).getOrientation() % 2 == 1)\t\n\t\t\t\t\tboardRep[g.getY() + 1][g.getX() + 1]= '\\\\';\n\t\t\t}else if(g instanceof CircularBumper){\n\t\t\t\tboardRep[g.getY() + 1][g.getX() + 1]= 'O';\n\t\t\t}else if(g instanceof Absorber){\n\t\t\t\tfor(int i=g.getX(); i < g.getX() + g.getWidth(); i++){\n\t\t\t\t\tfor(int j=g.getY(); j < g.getY() + g.getHeight(); j++){\n\t\t\t\t\t\tboardRep[j + 1][i + 1] = '=';\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}else if(g instanceof Flipper){\n\t\t\t\tFlipper f = (Flipper) g;\n\t\t\t\tif (f.isLeft && f.orientation == 0){\n\t\t\t\t\tboardRep[f.getY()+1][f.getX()+1] = '|';\n\t\t\t\t\tboardRep[f.getY()+2][f.getX()+1] = '|';\n\t\t\t\t} else if(f.orientation == 0){\n\t\t\t\t\tboardRep[f.getY()+1][f.getX()+2] = '|';\n\t\t\t\t\tboardRep[f.getY()+2][f.getX()+2] = '|';\n\t\t\t\t} else{\n\t\t\t\t\tboardRep[f.getY()+1][f.getX()+1] = '-';\n\t\t\t\t\tboardRep[f.getY()+1][f.getX()+2] = '-';\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\tfor(Ball b : balls){\n\t\t\tboardRep[(int) (b.getY() + 1)][(int) (b.getX() + 1)]= '*';\n\t\t}\n\t\t\n\t\tStringBuffer boardString = new StringBuffer();\n\t\tfor(char[] row : boardRep){\n\t\t\tfor(char c : row){\n\t\t\t\tboardString.append(c);\n\t\t\t}\n\t\t\tboardString.append('\\n');\n\t\t}\n\t\t\n\t\treturn boardString.toString();\n\t}", "public String toString() {\n StringBuilder s = new StringBuilder();\n s.append(dim + \"\\n\");\n for (int i = 0; i < dim; i++) {\n for (int j = 0; j < dim; j++) {\n s.append(String.format(\"%2d \", board[i][j]));\n }\n s.append(\"\\n\");\n }\n return s.toString();\n }", "@Override\n public String toString() {\n String returnBoard = \" \";\n for (int i = 1; i <= 3; i++) {\n returnBoard=returnBoard+\" \" +Integer.toString(i);\n }\n returnBoard+=\"\\n\";\n for (int i = 1; i <= 3; i++) {\n returnBoard+= Integer.toString(i);\n for (int j = 1; j <= 3; j++) {\n returnBoard = returnBoard + \" \" + board[i-1][j-1].toString();\n }\n returnBoard+=\"\\n\";\n }\n return returnBoard;\n }", "public String toString() {\n\t\tString temp = \"\";\n\t\tfor (int i = 0; i < 10; i++) {\n\t\t\ttemp += String.format(\"%d \", i);\n\t\t}\n\t\ttemp += \"\\n\";\n\t\tfor (int i = 0; i < 9; i++) {\n\t\t\ttemp += String.format(\"%d | \", i + 1);\n\t\t\tfor (int j = 0; j < 9; j++) {\n\t\t\t\ttemp += String.format(\"%c | \", board[i][j]);\n\t\t\t}\n\t\t\ttemp += \"\\n\";\n\t\t}\n\t\treturn temp;\n\t}", "@Override\n public String toString() {\n\n \n String str = \"\";\n for(int rowIndex = 0; rowIndex < this.board.length; rowIndex++) {\n \n for(int columnIndex = 0; columnIndex < this.board[rowIndex].length; columnIndex++) {\n\n switch (this.board[rowIndex][columnIndex]) {\n case IBoardState.symbolOfInactiveCell:\n str += \"*|\";\n break;\n case IBoardState.symbolOfEmptyCell:\n str += \"0|\";\n break;\n case IBoardState.symbolOfFirstPlayer:\n str += \"1|\";\n break;\n case IBoardState.symbolOfSecondPlayer:\n str += \"2|\";\n break;\n }\n\n }\n str +=\"\\n\";\n }\n return str;\n }", "public static String toString(String[][] board) {\n\n return board[0][0] + \" \" + board[0][1] + \" \" + board[0][2] + \" \"\n + board[1][0] + \" \" + board[1][1] + \" \" + board[1][2] + \" \"\n + board[2][0] + \" \" + board[2][1] + \" \" + board[2][2];\n }", "public static String serializeBoard(final Board gameBoard) {\n StringJoiner joiner = new StringJoiner(\" \");\n \n joiner\n .add(generatePiecePlacement(gameBoard.getMatrix()))\n .add(determineActiveColor(gameBoard))\n .add(generateCastlingAvailability(gameBoard));\n \n return joiner.toString();\n }", "private String boardToString(char[] board) {\n String boardString = \"\";\n for (char aBoard : board) boardString += aBoard;\n return boardString.replaceAll(\" \", \"_\");\n }", "public String toString(){\n\t\tString board = \"\";\n\t\tfor(int i = 0; i < rows; i++){\n\t\t\tfor(int j = 0; j < columns; j++){\n\t\t\t\tif(theGrid[i][j]){ //iterate through, if cell is alive, mark with *\n\t\t\t\t\tboard += \"*\";\n\t\t\t\t}\n\t\t\t\telse{\n\t\t\t\t\tboard += \" \"; //else, [space]\n\t\t\t\t}\n\t\t\t}\n\t\t\tboard += \"\\n\";//create a new line, to create the board\n\t\t}\n\t\treturn board; //return the board\n\t}", "String getBoard();", "public String toString() {\n\t\tString resultString = \"\\r\\n\";\n\t\t//resultString += \"Checkerboard state: \\r\\n\";\n\t\tfor (int i = 0; i < checkerboard.length; i++) {\n\t\t\tfor (int j = 0; j < checkerboard.length; j++) {\n\t\t\t\tif (checkerboard[i][j] == WHITE) {\n\t\t\t\t\tresultString += \"o \";\n\t\t\t\t} else if (checkerboard[i][j] == BLACK) {\n\t\t\t\t\tresultString += \"x \";\n\t\t\t\t} else {\n\t\t\t\t\tresultString += \"- \";\n\t\t\t\t}//Of if\n\t\t\t}//Of for j\n\t\t\tresultString += \"\\r\\n\";\n\t\t}//Of for i\n\t\t\n\t\tresultString += currentState;\n\n\t\t//resultString += \"\\r\\nThe current situation is: \" + gameSituation;\n\t\treturn resultString;\n\t}", "public String getBoardOverview() {\n String boardOverview = \"\";\n\n for (int y = 0; y < this.boardSize; y++) {\n for (int x = 0; x < this.boardSize; x++) {\n char StoneColor = ' ';\n\n if (!this.fields[x][y].isEmpty()) {\n switch (this.fields[x][y].getStone().getColor()) {\n case BLACK:\n StoneColor = 'B';\n break;\n case WHITE:\n StoneColor = 'W';\n break;\n }\n } else if (this.fields[x][y].isPossibleMove()) {\n StoneColor = 'x';\n }\n\n boardOverview = boardOverview + StoneColor;\n\n }\n // next line\n boardOverview = boardOverview + String.format(\"%n\");\n }\n\n return boardOverview;\n }", "public String convertBoardToString(){\n String tmp= \"\";\n\n for (int i=0; i<30; i++){\n for (int j=0; j<80; j++){\n if (board.getCharacter(j,i)==0){\n tmp += '-';\n } else {\n tmp += board.getCharacter(j,i);\n }\n }\n }\n return tmp;\n }", "public String toString() {\n\t\t// Variables\n\t\tString gameboard;\n\t\tchar[] firstLetter = { 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O' };\n\n\t\t// Top\n\t\tgameboard = \" ===============================================================\\n\";\n\n\t\t// Middle\n\t\tfor (int i = 0; i < 15; i++) {\n\t\t\t// Beginning of the line\n\t\t\tgameboard += \" \" + firstLetter[i] + \" ||\";\n\n\t\t\t// Letters\n\t\t\tfor (int j = 0; j < 15; j++) {\n\t\t\t\tif (this.grid[i][j].getTile().getLetter() == Character.MIN_VALUE) {\n\t\t\t\t\tif (this.grid[i][j].getScoreMult() > 1)\n\t\t\t\t\t\tgameboard += \" * \";\n\t\t\t\t\telse\n\t\t\t\t\t\tgameboard += \" . \";\n\t\t\t\t} else {\n\t\t\t\t\tgameboard += \" \" + this.grid[i][j].getTile().getLetter() + \" \";\n\t\t\t\t}\n\t\t\t\tif (j != 14)\n\t\t\t\t\tgameboard += '|';\n\t\t\t}\n\n\t\t\t// End of the line\n\t\t\tgameboard += \"||\\n\";\n\t\t\tif (i != 14)\n\t\t\t\tgameboard += \" ||---|---|---|---|---|---|---|---|---|---|---|---|---|---|---||\\n\";\n\t\t}\n\n\t\t// Bottom\n\t\tgameboard += \" ===============================================================\\n\";\n\t\tgameboard += \" 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15\";\n\n\t\treturn gameboard;\n\t}", "public String toString() {\n\t\tStringBuilder string = new StringBuilder();\n\t\tstring.append(n + \"\\n\");\n\t\tfor (int i = 0; i < n; i++) {\n\t\t\tfor (int j = 0; j < n; j++) \n\t\t\t\tstring.append(String.format(\"%2d \", board[i][j]));\n\t\t\tstring.append(\"\\n\");\n\t\t}\n\t\treturn string.toString();\n\t}", "public String toString(){\n //KEY --------\n // WHITE WALL = WW\n // WHITE ROAD = WR\n // WHITE CAPSTONE = WC\n // BLACK WALL = BW\n // BLACK ROAD = BR\n // BLACK CAPSTONE = BC\n // EMPTY = \"blank\"\n\n StringBuilder builder = new StringBuilder();\n\n /*TOP ROW*/ builder.append(\"\\t\"); for(int i = 0; i < SIZE; i++){ builder.append(i + \"\\t\");} builder.append(\"\\n\\n\");\n /*REST OF THE ROWS*/ \n for(int x = 0; x < SIZE; x++){\n builder.append(x + \"\\t\");\n for(int y = 0; y < SIZE; y++){\n TakStack current = stacks[y][x]; \n if(!current.isEmpty()){\n builder.append(getPieceString(current.top()));\n }\n builder.append(\"\\t\");\n }\n builder.append(\"\\n\\n\");\n }\n\n\n //BUILDER RETURN\n return builder.toString();\n }", "public void displayBoard(){\r\n System.out.println(board.toString());\r\n }", "@Override\n\tpublic String toString() {\n\t\tString result = \"-------------------\\n\";\n\t\tfor (Cell[] cellRow : board) {\n\t\t\tresult += \"|\";\n\t\t\tfor (Cell cell : cellRow) {\n\t\t\t\tresult += (cell.val == 0 ? \" \" : cell.val) + \"|\";\n\t\t\t}\n\t\t\tresult += \"\\n-------------------\\n\";\n\t\t}\n\t\treturn result += \"\\n\" + toTest();\n\t}", "public String getGameStr() {\n StringBuilder outStr = new StringBuilder();\n for(int i=0;i<ROWS;i++) {\n for(int j=0;j<COLS;j++){ \n outStr.append(\"|\").append(gameBoard[i][j].show());\n }\n outStr.append(\"|\").append(System.getProperty(\"line.separator\"));\n }\n return outStr.toString();\n }", "@Override\n public String toString() {\n StringBuilder sb = new StringBuilder();\n\n for (int i = 0; i < row; i++) {\n for (int j = 0; j < column; j++) {\n sb.append(game[i][j]);\n }\n sb.append(\"\\n\");\n }\n return sb.toString();\n }", "public String toString()\n {\n String boardString = \"\";\n int space = 1;\n for(int i = 0; i < NUM_SQUARES; i++)\n {\n boardString += \"| \" + board[i].toString() + \" | \";\n //Make a new line every 10 squares\n if(space == 10 || space == 20 || space == 30 || space == 40 || space == 50 || space == 60 || space == 70 || space == 80 || space == 90) boardString += \"\\n\";\n space++;\n }\n return boardString;\n }", "public String toString() {\n // show marbles on board with indexes\n String s = \"\";\n for (int i = 0; i < DIMENSION; i++) {\n if ((i > 4) && (i != 10)) {\n s += \" \".repeat(i - 2);\n // char index bottom board\n s += \"\\u001b[32m\" + String.valueOf((char) ((char) i + 'A' - 1)) + \"\\u001b[0m \";\n } else {\n s += \" \".repeat(i);\n }\n for (int j = 0; j < DIMENSION; j++) {\n if (i + j == 4) {\n if (i == 0) {\n s += \" \";\n } else {\n // char index top board\n s += \"\\u001b[32m\" + String.valueOf((char) ((char) i + 'A' - 1)) + \"\\u001b[0m\";\n }\n } else if ((i + j < 4) || i + j > 15) {\n s += \"\\u001b[32m\";\n if ((i == 7 && j == 9)) {\n s += \"9\";\n } else if ((i == 8 && j == 8)) {\n s += \"8\";\n } else if ((i == 9 && j == 7)) {\n s += \"7\";\n } else if ((i == 10 && j == 6)) {\n s += \"6\";\n } else {\n s += \" \";\n }\n s += \"\\u001b[0m\";\n } else if (isOutOfBoard(fields[i][j])) {\n \n s += fields[i][j].getMarbleColor().toString().charAt(0);\n } else {\n // show marbles with color\n switch (fields[i][j].getMarbleColor()) {\n case BLACK:\n s += \"\\u001b[30mo\";\n break;\n case WHITE:\n s += \"\\u001b[37mo\";\n break;\n case RED:\n s += \"\\u001b[31mo\";\n break;\n case BLUE:\n s += \"\\u001b[34mo\";\n break;\n case NONE:\n s += \" \";\n break;\n }\n }\n s += \"\\u001b[0m \";\n }\n \n s += \"\\n\";\n }\n \n s += \" \".repeat(13) + \"\\u001b[32m1 2 3 4 5\\u001b[0m\";\n return s;\n\n\n }", "public String showBoard() {\n return name + \"\\r\\n\" + myBoard.displayMyBoard() + \"\\r\\n\" + opponentsBoard.displayShotsTaken();\n }", "private String digestGameBoard() {\n StringBuilder config = new StringBuilder();\n for(char[] gameBoardRow : gameBoard) {\n for(char slot : gameBoardRow) {\n config.append(slot);\n }\n }\n return config.toString();\n }", "public static void printBoard() {\n int separatorLen = 67;\n StringBuilder boardString = new StringBuilder();\n boardString.append(new String(new char [separatorLen]).replace(\"\\0\",\"*\"));\n boardString.append(\"\\n\");\n for(int y = Y_UPPER_BOUND - 1; y >= 0; y--)\n {\n boardString.append(y + 1).append(\" \");\n boardString.append(\"*\");\n for (int x = 0; x < X_UPPER_BOUND; x++)\n {\n Piece p = Board.board[x + y * X_UPPER_BOUND];\n if(p != null)\n {\n boardString.append(\" \").append(p).append(p.getColor()? \"-B\":\"-W\").append(\" \").append((p.toString().length() == 1? \" \":\"\"));\n }\n else\n {\n boardString.append(\" \");\n }\n boardString.append(\"*\");\n }\n boardString.append(\"\\n\").append((new String(new char [separatorLen]).replace(\"\\0\",\"*\"))).append(\"\\n\");\n }\n boardString.append(\" \");\n for(char c = 'A'; c <= 'H';c++ )\n {\n boardString.append(\"* \").append(c).append(\" \");\n }\n boardString.append(\"*\\n\");\n System.out.println(boardString);\n }", "public String toString() {\n\t\tString returnString=\"\";\n\t\t\n\t\tfor (int i=0; i<squares.length; i++) {\n\t\t\tfor (int j=0; j<squares.length; j++) {\n\t\t\t\treturnString+=Character.toString(squares[i][j].getValue());\n\t\t\t}\n\t\t\treturnString+=\"// \";\n\t\t}\n\t\t\n\t\treturn returnString;\n\t}", "public String toString() {\r\n\t\tString s = (currentPlayer == getP1() ? \"Cross : \" : \"Nought : \");\r\n\t\tfor (int y = 0; y < 3; y++) {\r\n\t\t\tfor (int x = 0; x < 3; x++) {\r\n\t\t\t\ts = s + board[y][x];\r\n\t\t\t}\r\n\t\t\ts = s + \" \";\r\n\t\t}\r\n\t\treturn s;\r\n\t}", "public String dumpState() {\n StringBuilder out = new StringBuilder();\n out.append(currentPlayer);\n for (int i = 0; i < board.length; ++i)\n out.append(\" \" + board[i]);\n\n return out.toString();\n }", "public String getStateOfBoard()\n {\n // This function is used to print state of the board. such as number of coins present on the board\n String str=\"\";\n str += \"Black_Coins Count:\"+this.gameController.getCoinsCount(CoinType.BLACK) +\" Red_Coins Count:\"+this.gameController.getCoinsCount(CoinType.RED);\n return str;\n }", "public String toString ()\n\t{\n\t\tString s = \"Grid:\\n\";\n\t\tfor (int row=0; row<GRID_SIZE; row++)\n\t\t{\n\t\t\tfor (int col=0; col<GRID_SIZE; col++) {\n\t\t\t\ts = s + grid[col][row].value()+ \" \";\n\t\t\t}\n\t\t\ts += \"\\n\";\n\t\t}\n\t\treturn s;\n\t}", "public String drawBoard() {\n fillBoard();\n return \"\\n\" +\n \" \" + boardArray[0][0] + \" | \" + boardArray[0][1] + \" | \" + boardArray[0][2] + \" \\n\" +\n \"------------\\n\" +\n \" \" + boardArray[1][0] + \" | \" + boardArray[1][1] + \" | \" + boardArray[1][2] + \" \\n\" +\n \"------------\\n\" +\n \" \" + boardArray[2][0] + \" | \" + boardArray[2][1] + \" | \" + boardArray[2][2] + \" \\n\";\n }", "public String toString() {\n\t\tStringBuilder sb = new StringBuilder();\n\t\tfor (byte m = 0; m < 9; m++) {\n\t\t\tfor (byte n = 0; n < 9; n++) {\n\t\t\t\tsb.append(cells[m][n].getValue());\n\t\t\t}\n\t\t}\n\t\treturn sb.toString();\n\t}", "public static String printOpenBoard(Game board) {\n return board.openBoardToString();\n }", "public String toString() {\n return String.format(\"Final board:\\n%s\" +\n \"Number of conflicts:%d\\n\" +\n \"Time elapsed: %f seconds\\n\",\n board,\n BoardState.countConflicts(board.getBoard()),\n time * 0.000000001);\n }", "public String toString() {\n StringBuilder s = new StringBuilder();\n s.append(this.dim + \"\\n\");\n int counter = 0;\n for (int i = 0; i < this.dim; i++) {\n for (int j = 0; j < this.dim; j++) {\n int n = tiles[counter++];\n s.append(String.format(\"%2d \", n));\n }\n s.append(\"\\n\");\n }\n return s.toString();\n }", "@Override\n public String toString() {\n String[] output = new String[getHeight()];\n for (int row=0; row < getHeight(); row++) {\n StringBuilder builder = new StringBuilder();\n for (int col=0; col < getWidth(); col++) {\n Square current = getSquare(row, col);\n builder.append(getCharForSquare(current));\n }\n output[row] = builder.toString();\n }\n return String.join(\"\\n\", output);\n }", "public String toString() {\n StringBuilder res = new StringBuilder();\n res.append(n + \"\\n\");\n for (int i = 0; i < n; i++) {\n for (int j = 0; j < n; j++)\n res.append(String.format(\" %2d \", tileAt(i, j)));\n res.append(\"\\n\");\n }\n return res.toString();\n }", "public String toString() {\n\t\tString r = \"\";\n\t\tchar[][] a = toMatrix();\n\t\tfor (int i = 0; i < 3; i++) {\n\t\t\tfor (int j = 0; j < 3; j++) {\n\t\t\t\tif (a[i][j] == '\\0')\n\t\t\t\t\tr += \"-\";\n\t\t\t\telse\n\t\t\t\t\tr += a[i][j];\n\t\t\t}\n\t\t\tr += \"\\n\";\n\t\t}\n\t\treturn r.substring(0, r.length() - 1);\n\t}", "public String stateToCheckerboardString(int paraState) {\n\t\tint[][] tempCheckerboard = stateToCheckerboard(paraState);\n\t\tString resultString = \"\\r\\n\";\n\t\t//resultString += \"Checkerboard state: \\r\\n\";\n\t\tfor (int i = 0; i < tempCheckerboard.length; i++) {\n\t\t\tfor (int j = 0; j < tempCheckerboard[0].length; j++) {\n\t\t\t\tif (tempCheckerboard[i][j] == WHITE) {\n\t\t\t\t\tresultString += \"o \";\n\t\t\t\t} else if (tempCheckerboard[i][j] == BLACK) {\n\t\t\t\t\tresultString += \"x \";\n\t\t\t\t} else {\n\t\t\t\t\tresultString += \"- \";\n\t\t\t\t}//Of if\n\t\t\t}//Of for j\n\t\t\tresultString += \"\\r\\n\";\n\t\t}//Of for i\n\t\t\n\t\t//resultString += currentState;\n\t\treturn resultString;\n\t}", "public String toString() {\n return String.format(\"%s%s\", column, row);\n }", "public void displayBoard() {\n newLine();\n for (int row = _board[0].length - 1; row >= 0; row -= 1) {\n String pair = new String();\n for (int col = 0; col < _board.length; col += 1) {\n pair += \"|\";\n pair += _board[col][row].abbrev();\n }\n System.out.println(pair + \"|\");\n newLine();\n }\n }", "@Override\n public final String toString()\n {\n String str = formatInt(turn)+formatInt(fiftyMove);\n //int counter = 0;\n for (Square[] s1: getSquares())\n {\n for (Square s: s1)\n {\n if (!s.isEmpty())\n {\n str+=\"\"+s;\n //counter++;\n /*if (counter%4==0)\n str+=\"\\n\";*/\n }\n }\n }\n return str;\n }", "String displayMyBoard();", "public String toString()\n\t{\n\t\tchar rowLetter = (char)('A'+row);\n\t\treturn(\"\"+rowLetter+col);\n\t}", "public String toString() {\n\t\tStringBuilder buff = new StringBuilder();\n\t\tfor (int y = height-1; y>=0; y--) {\n\t\t\tbuff.append('|');\n\t\t\tfor (int x=0; x<width; x++) {\n\t\t\t\tif (getGrid(x,y)) buff.append('+');\n\t\t\t\telse buff.append(' ');\n\t\t\t}\n\t\t\tbuff.append(\"|\\n\");\n\t\t}\n\t\tfor (int x=0; x<width+2; x++) buff.append('-');\n\t\treturn(buff.toString());\n\t}", "public String toString() {\n\t\tStringBuilder buff = new StringBuilder();\n\t\tfor (int y = height-1; y>=0; y--) {\n\t\t\tbuff.append('|');\n\t\t\tfor (int x=0; x<width; x++) {\n\t\t\t\tif (getGrid(x,y)) buff.append('+');\n\t\t\t\telse buff.append(' ');\n\t\t\t}\n\t\t\tbuff.append(\"|\\n\");\n\t\t}\n\t\tfor (int x=0; x<width+2; x++) buff.append('-');\n\t\treturn(buff.toString());\n\t}", "public String toString() {\n StringBuilder s = new StringBuilder();\n s.append(N + \"\\n\");\n for (int i = 0; i < N; i++) {\n for (int j = 0; j < N; j++) {\n s.append(String.format(\"%2d \", tiles[i][j]));\n }\n s.append(\"\\n\");\n }\n return s.toString();\n }", "public String toString() {\n StringBuilder s = new StringBuilder();\n s.append(N + \"\\n\");\n for (int i = 0; i < N; i++) {\n for (int j = 0; j < N; j++) {\n s.append(String.format(\"%2d \", tiles[i][j]));\n }\n s.append(\"\\n\");\n }\n return s.toString();\n }", "public void printBoard() {\n \tfor(int i = 7; i >= 0; i--) {\n \t\tfor(int j = 0; j < 8; j++) {\n \t\t\tSystem.out.print(\"\"+getPiece(j, i).getColor().toString().charAt(0)+getPiece(j, i).getName().charAt(0)+\"\\t\");\n \t\t}\n \t\tSystem.out.println();\n \t}\n }", "public String toString() {\n String s = \"\";\n for(int i = 1; i <= rows; i++){\n for(int j = 1; j <= cols; j++){ \n s = s + String.format(\"%2d\",m[i][j]) + \" \";\n }\n s += \"\\n\";\n }\n return s;\n }", "public static void printGameBoard(Player[][] board) {\n\t\tStringBuilder rowBuffer = new StringBuilder(); \n\t\tfor (int row = 0; row < Score4Constants.rowMax; row++) {\n\t\t\tfor (int col = 0; col < Score4Constants.colMax; col++) {\n\t\t\t\trowBuffer.append(board[row][col].getName());\n\t\t\t\trowBuffer.append(\" \");\n\t\t\t}\n\t\t\tlogger.info(\"ROW: {}: {}\", row + 1, rowBuffer);\n\t\t\trowBuffer.delete(0, rowBuffer.length());\n\t\t}\n\t}", "@Override\r\n\tpublic String toString()\r\n\t{\r\n\t\tString s = new String(\"\");\r\n\t\tfor (int i = 0; i < maze.length; i++) {\r\n\t\t\ts+= \"\\n\";\r\n\t\t\ts+= \"Floor #\";\r\n\t\t\ts+= (i+1);\r\n\t\t\ts+= \":\";\r\n\t\t\ts+= \"\\n\";\r\n\t\t\tfor (int j = 0; j < maze[0].length; j++) {\r\n\t\t\t\ts+= \"\\n\";\r\n\t\t\t\tfor (int j2 = 0; j2 < maze[0][0].length; j2++) {\r\n\t\t\t\t\ts += this.maze[i][j][j2];\r\n\t\t\t\t\ts += \" \";\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\ts+= \"\\n\";\r\n\t\t}\r\n\t\treturn s;\r\n\t}", "public String toString()\n\t{\n\t\tStringBuilder sb = new StringBuilder();\n\t\tsb.append(\" 1 2 3 4 5 6 7 8\\n\");\n\t\tfor(int i = 0; i < 8; i++)\n\t\t{\n\t\t\tsb.append((char) (i + FIRST_ROW) + \" \");\n\t\t\tfor(int i2 = 0; i2 < 8; i2++)\n\t\t\t{\n\t\t\t\tsb.append(\" \" + fields[i][i2]);\n\t\t\t\tif(i2 == 7)\n\t\t\t\t{\n\t\t\t\t\tsb.append(\"\\n\");\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn sb.toString();\n\t}", "private void renderBoard() {\n Cell[][] cells = gameBoard.getCells();\n StringBuilder battleField = new StringBuilder(\"\\tA B C D E F G H I J \\n\");\n\n for (int i = 0; i < cells.length; i++) {\n battleField.append(i+1).append(\"\\t\");\n for (int j = 0; j < cells[i].length; j++) {\n if (cells[i][j].getContent().equals(Content.deck)) {\n battleField.append(\"O \");\n } else {\n battleField.append(\"~ \");\n }\n }\n battleField.append(\"\\n\");\n }\n\n System.out.println(battleField.toString());\n }", "@Override\n public String toString() {\n StringBuilder result = new StringBuilder();\n for (int i = 0; i < 3; i++) {\n for (int j = 0; j < 3; j++) {\n int cell = field[i][j];\n result.append(cell == 0 ? \"_\" : (cell == 1 ? \"X\" : \"O\")).append(\" \");\n }\n result.append(\"\\n\");\n }\n return result.toString();\n }", "public static void printBoard(String[][] board) {\n String row0 = board[0][0] +\"|\"+ board[0][1] +\"|\"+ board[0][2];\n String row1 = board[1][0] +\"|\"+ board[1][1] +\"|\"+ board[1][2];\n String row2 = board[2][0] +\"|\"+ board[2][1] +\"|\"+ board[2][2];\n\n System.out.println(row0);\n System.out.println(\"-----\");\n System.out.println(row1);\n System.out.println(\"-----\");\n System.out.println(row2);\n }", "public String toString () {\n return \"(\" + col + \",\" + row + \")\";\n }", "public String toString() {\n\tStringBuffer buffer = new StringBuffer();\n\t//\tbuffer.append(\" 6 5 4 3 2 1 \\n\");\n\tbuffer.append(\"+---------------------------------------+\\n\");\n\t\n\tbuffer.append(\"| |\");\n\tfor (int i = 12; i >= 7; --i) {\n\t buffer.append(toString(state[i]));\n\t}\n\tbuffer.append(\" |\\n\");\n\t\n\tbuffer.append(\"|\");\n\tbuffer.append(toString(state[13]));\n\tbuffer.append(\"-----------------------------|\");\n\tbuffer.append(toString(state[6]));\n\tbuffer.append(\"\\n\");\n\t\n\tbuffer.append(\"| |\");\n\tfor (int i = 0; i <= 5; ++i) {\n\t buffer.append(toString(state[i]));\n\t}\n\tbuffer.append(\" |\\n\");\n\t\n\tbuffer.append(\"+---------------------------------------+\\n\");\n\tbuffer.append(\" 0 1 2 3 4 5 \\n\");\n\t\n\treturn buffer.toString();\n }", "public String toString() {\n String type = \"TYPE: Edge Piece\\n\";\n String[] strColors = colorsAsString(colors);\n String color = \"Color: [\" + strColors[0] + \",\" + strColors[1] + \"]\\n\";;\n String slot;\n switch (loc) {\n case 1 :\n slot = \"Front top\";\n break;\n case 2 :\n slot = \"Front bottom\";\n break;\n case 3 :\n slot = \"Front right\";\n break;\n case 4 :\n slot = \"Front left\";\n break;\n case 5 :\n slot = \"Back top\";\n break;\n case 6 :\n slot = \"Back bottom\";\n break;\n case 7 :\n slot = \"Back left on green side\";\n break;\n case 8 :\n slot = \"Back right on green side\";\n break;\n case 9 :\n slot = \"Top right\";\n break;\n case 10 :\n slot = \"Top left\";\n break;\n case 11 :\n slot = \"Bottom right\";\n break;\n default :\n slot = \"Bottom left\";\n }\n String location = \"Location: \" + slot + \"\\n\";\n String oriented = \"Yes\";\n if (orient == -1) {\n oriented = \"No\";\n }\n String orientation = \"Oriented? \" + oriented + \"\\n\";\n String solved = \"Solved? \" + solved() + \"\\n \";\n return type + color + location + orientation + solved;\n }", "public void printShipBoard() {\n\t\tSystem.out.println(Arrays.deepToString(this.shipBoard));\n\t}", "@Override\n public String toString() {\n return String.valueOf(playerPiece);\n }", "public String toString() {\n StringBuilder sb = new StringBuilder();\n sb.append(n + System.lineSeparator());\n for (int i = 0; i < n; i++) {\n for (int j = 0; j < n; j++) {\n sb.append(tiles[i][j] + \" \");\n }\n sb.append(System.lineSeparator());\n }\n return sb.toString();\n }", "@Override\r\n public String toString() {\r\n StringBuilder res = new StringBuilder();\r\n for (int i=0 ; i<this.tiles.length ; i++) {\r\n if (i>0 && i%this.width == 0) {\r\n res.append(\"\\n\");\r\n }\r\n res.append(this.tiles[i]);\r\n }\r\n return res.toString();\r\n }", "public String toString() {\n String result = \"\";\n result += \" \";\n // Column numbers\n for (int i = 0; i < numberOfColumns; i++) {\n result += (i % 10) + \" \";\n }\n result += \"\\n\";\n result += \" \";\n // Horizontal dividers\n for (int i = 0; i <= 2 * this.numberOfColumns - 2 ; i++) {\n result += HORI_DIVIDE;\n }\n result += \"\\n\";\n // Each horizontal line has the line number, a divider, and the safe data.\n for (int i = 0; i < numberOfRows; i++) {\n result += (i % 10);\n result += VERT_DIVIDE;\n for (int j = 0; j < numberOfColumns; j++) {\n result += grid[i][j];\n if (j != numberOfColumns - 1) {\n result += \" \";\n }\n }\n if (i != numberOfRows - 1) {\n result += \"\\n\";\n }\n }\n return result;\n }", "public String configString() {\n \n String boardConfig = \"\";\n // adds each element in the array to the string with a space in between\n // condition is numPiles - 1 so last element does not print with a space afterwards\n \n for (int i = 0; i < numPiles - 1; i++){\n boardConfig += piles[i] + \" \";\n }\n boardConfig += piles[numPiles - 1] + \" \";\n \n //check if valid board still\n assert isValidSolitaireBoard();\n \n //return the current board configuration string\n return boardConfig;\n }", "public String toString() {\n String result = \"\";\n if (this.column > 0 && this.row > 0) {\n int column = this.column, exp = (int) (Math.log(column) / Math.log(26)), cur;\n for (int i = exp; i >= 0; i--) {\n cur = (int) (column / Math.pow(26, i));\n result += (char) (64 + cur);\n column -= cur * Math.pow(26, i);\n }\n result += this.row;\n }\n return result;\n }", "@Override\r\n\tpublic String toString() {\r\n\t\tString str = new String();\r\n\t\tfor(Cell2048[] a : game) {\r\n\t\t\tfor(Cell2048 b : a)\r\n\t\t\t\tstr += b.getValue();\r\n\t\t}\r\n\t\treturn Integer.toString(rows_size) + \",\" + Integer.toString(columns_size) +\",\" +str;\r\n\t}", "@Override\n\tpublic String toString(){\n\t\tString game;\n\t\t\n\t\tgame=this.currentBoard.toString();\n\t\tgame=game+\"best value: \"+this.currentRules.getWinValue(currentBoard)+\" Score: \"+this.points+\"\\n\";\n\t\t\n\t\tif(currentRules.win(currentBoard)){\n\t\t\tgame=game+\"Well done!\\n\";\n\t\t\tfinish=true;\n\t\t}\n\t\telse if(currentRules.lose(currentBoard)){\n\t\t\tgame=game+\"Game over.\\n\";\n\t\t\tfinish=true;\n\t\t}\n\t\t\n\t\treturn game;\n\t}", "public String toString() {\r\n\t\tStringBuilder sb = new StringBuilder();\r\n\t\tint n = dimension();\r\n\t\tsb = sb.append(n + \"\\n\");\r\n\t\tfor (int i = 0; i < n; i++) {\r\n\t\t\tfor (int j = 0; j < n; j++) {\r\n\t\t\t\tsb = sb.append(\" \" + this.blocks[i][j]);\r\n\t\t\t}\r\n\t\t\tif (i != n) {\r\n\t\t\t\tsb = sb.append(\"\\n\");\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn sb.toString();\r\n\t}", "public static char[][] getBoard() {\n\t\treturn board;\n\t}", "public String toString() {\n\t\treturn (new StringBuilder().append(\"Turn: \")\n\t\t\t.append(turnNumber)\n\t\t\t.append(\"\\n\")\n\t\t\t.append(towerSet.toString())\n\t\t\t.append('\\n')).toString();\n\t}", "@Override\n public String toString() {\n StringBuilder s = new StringBuilder();\n int N = size();\n s.append(N + \"\\n\");\n for (int i = 0; i < N; i++) {\n for (int j = 0; j < N; j++) {\n s.append(String.format(\"%2d \", tileAt(i,j)));\n }\n s.append(\"\\n\");\n }\n /*\n s.append(manhattan());\n s.append(\"\\n\");\n for (int i = 0; i < N; i++) {\n for (int j = 0; j < N; j++) {\n s.append(String.format(\"%2d \", _goal[i][j]));\n }\n s.append(\"\\n\");\n }*/\n s.append(\"\\n\");\n return s.toString();\n }", "public void printBoard() {\n String value = \"\";\n renderBoard();\n System.out.println(\"\");\n // loop to print out values in rows and columns\n for (int i = 0; i < game.getRows(); i++) {\n for (int j = 0; j < game.getCols(); j++) {\n if (grid[i][j] == 0)\n value = \".\";\n else\n value = \"\" + grid[i][j];\n System.out.print(\"\\t\" + value);\n }\n System.out.print(\"\\n\");\n }\n }", "@Override\n public String toString() {\n if(piece instanceof King) return player + 'K';\n if(piece instanceof Queen) return player + 'Q';\n if(piece instanceof Rook) return player + 'R';\n if(piece instanceof Knight) return player + 'N';\n if(piece instanceof Bishop) return player + 'B';\n if(piece instanceof Pawn) return player + 'p';\n else return \" \";\n }", "public String toString() {\r\n StringBuilder result= new StringBuilder();\r\n for(int x=0;x<8;x++){\r\n for(int y=0;y<8;y++){\r\n result.append(checks[x][y]).append(\",\");\r\n }\r\n result.append(\"\\n\");\r\n }\r\n return result.toString();\r\n }", "public void printBoard() {\n printStream.println(\n \" \" + positions.get(0) + \"| \" + positions.get(1) + \" |\" + positions.get(2) + \"\\n\" +\n \"---------\\n\" +\n \" \" + positions.get(3) + \"| \" + positions.get(4) + \" |\" + positions.get(5) + \"\\n\" +\n \"---------\\n\" +\n \" \" + positions.get(6) + \"| \" + positions.get(7) + \" |\" + positions.get(8) + \"\\n\");\n }", "@Override\n public String toString() {\n String result = \"\";\n\n for (int position = 0; position < 64; position++) {\n if (position > 0) {\n if (position % 16 == 0) { // New level\n result += '|';\n } else if (position % 4 == 0) {\n result += ' '; // New row\n }\n }\n result += get(position);\n }\n return result;\n }", "private static void printBoard(char [][] board){\n for (int i = 0; i < 6; i++){\n for(int j = 0; j < 7; j++){\n System.out.print(\"|\"+board[i][j]);\n }\n System.out.println(\"|\");\n }\n System.out.println();\n }", "public char[][] getBoard() {\n return board;\n\t}", "private static void printBoard(char[][] board) {\n\n\t\t// header\n\t\tfor (int i = 0; i < board.length; i++) {\n\t\t\tSystem.out.print(\"- \");\n\t\t}\n\n\t\tSystem.out.println();\n\n\t\tfor (int i = 0; i < board.length; i++) {\n\t\t\tfor (int j = 0; j < board[0].length; j++) {\n\t\t\t\tSystem.out.print(board[i][j] + \" \");\n\t\t\t}\n\n\t\t\tSystem.out.println();\n\t\t}\n\n\t\t// footer\n\t\tfor (int j = 0; j < board.length; j++) {\n\t\t\tSystem.out.print(\"- \");\n\t\t}\n\n\t\tSystem.out.println();\n\t}", "public void printBoard(LightModel board){\n String separatorSx = \"| \";\n String centralSep = \" | \";\n String separatorDx = \" |\";\n\n for(LightPlayer lp : board.getPlayers()){\n playersInfo.append(lp.getColor().toString()).append(\" = \").append(lp.getName()).append(\" \");\n }\n System.out.println(playersInfo);\n playersInfo.setLength(0);\n for(int j=0; j<=4;j++) {\n floorInfo.append(\"| \");\n pawnInfo.append(separatorSx);\n for (int i = 0; i < 4; i++) {\n if (board.getLightGrid()[j][i].isRoof()) {\n floorInfo.append(\"* \").append(board.getLightGrid()[j][i].getFloor()).append(\" | \");\n } else floorInfo.append(\" \").append(board.getLightGrid()[j][i].getFloor()).append(\" | \");\n if (board.getLightGrid()[j][i].getOccupied() == null) {\n pawnInfo.append(\" \").append(centralSep);\n } else\n pawnInfo.append(board.getLightGrid()[j][i].getOccupied().toString())\n .append(board.getLightGrid()[j][i].getOccupied().getNumber())\n .append(centralSep);\n }\n if (board.getLightGrid()[j][4].isRoof()) {\n floorInfo.append(\"* \").append(board.getLightGrid()[j][4].getFloor()).append(separatorDx);\n } else floorInfo.append(\" \").append(board.getLightGrid()[j][4].getFloor()).append(separatorDx);\n if (board.getLightGrid()[j][4].getOccupied() == null) {\n pawnInfo.append(\" \").append(separatorDx);\n } else\n pawnInfo.append(board.getLightGrid()[j][4].getOccupied().toString())\n .append(board.getLightGrid()[j][4].getOccupied().getNumber())\n .append(separatorDx);\n System.out.println(\"+ - - + - - + - - + - - + - - +\");\n System.out.println(floorInfo.toString());\n System.out.println(pawnInfo.toString());\n pawnInfo.setLength(0);\n floorInfo.setLength(0);\n\n }\n System.out.println(\"+ - - + - - + - - + - - + - - +\");\n }", "public void printBoard() {\n\t\tSystem.out.print(\"\\r\\n\");\n\t\tSystem.out.println(\" A | B | C | D | E | F | G | H\");\n\t\tfor(int i = BOARD_SIZE ; i > 0 ; i--) {\n\t\t\tSystem.out.println(\" ___ ___ ___ ___ ___ ___ ___ ___\");\n\t\t\tfor(int j = 0; j < BOARD_SIZE ; j++) {\n\t\t\t\tif(j == 0) {\n\t\t\t\t\tSystem.out.print(i + \" |\");\n\t\t\t\t} \n\t\t\t\tif(this.tiles.get(i).get(j).getPiece() != null) {\n\t\t\t\t\tif(this.tiles.get(i).get(j).getPiece().getColor() == PrimaryColor.BLACK) {\n\t\t\t\t\t\tif(this.tiles.get(i).get(j).getPiece() instanceof Soldier)\n\t\t\t\t\t\t\tSystem.out.print(\" B |\");\n\t\t\t\t\t\telse\n\t\t\t\t\t\t\tSystem.out.print(\"B Q|\");\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\tif(this.tiles.get(i).get(j).getPiece() instanceof Soldier)\n\t\t\t\t\t\t\tSystem.out.print(\" W |\");\n\t\t\t\t\t\telse\n\t\t\t\t\t\t\tSystem.out.print(\"W Q|\");\n\t\t\t\t\t}\n\t\t\t\t}else {\n\t\t\t\t\tSystem.out.print(\" |\");\n\t\t\t\t}\n\n\t\t\t\tif(j==BOARD_SIZE-1) {\n\t\t\t\t\tSystem.out.print(\" \" + i); \n\t\t\t\t}\n\t\t\t}\n\t\t\tSystem.out.println();\n\t\t}\n\n\t\tSystem.out.println(\" ___ ___ ___ ___ ___ ___ ___ ___\");\n\t\tSystem.out.println(\" A | B | C | D | E | F | G | H\\r\\n\");\n\n\t}" ]
[ "0.81808215", "0.81183374", "0.8063188", "0.7995336", "0.7983921", "0.7981973", "0.79410124", "0.7876103", "0.7871404", "0.7871019", "0.78280765", "0.7807706", "0.7798642", "0.77812535", "0.7707736", "0.77033085", "0.76303023", "0.7625184", "0.75833493", "0.75414187", "0.75335073", "0.7516351", "0.7501374", "0.7492061", "0.74553865", "0.7435368", "0.7415178", "0.7405152", "0.7364244", "0.7323312", "0.7303845", "0.7297647", "0.72876656", "0.7254306", "0.7222952", "0.72202235", "0.7206224", "0.7187034", "0.7110916", "0.7081176", "0.7041033", "0.70160145", "0.69401675", "0.6923897", "0.6897703", "0.68576145", "0.67838997", "0.67619485", "0.6760796", "0.6754037", "0.6731678", "0.67306674", "0.6692778", "0.6639092", "0.661792", "0.6581793", "0.65806454", "0.6555113", "0.65272564", "0.65213186", "0.6493675", "0.6491234", "0.64774245", "0.64746636", "0.64746636", "0.64621806", "0.64621806", "0.64420897", "0.64379567", "0.64324623", "0.64156604", "0.6395055", "0.63851553", "0.63674754", "0.63650304", "0.6362627", "0.6342694", "0.6329916", "0.63255495", "0.63129836", "0.63088495", "0.62979794", "0.6296235", "0.6286736", "0.62857485", "0.62851524", "0.6271168", "0.6267816", "0.6252523", "0.6238016", "0.62340146", "0.6227403", "0.6217778", "0.6216498", "0.62100554", "0.61888933", "0.6188086", "0.6177159", "0.6167148", "0.6166709", "0.61657506" ]
0.0
-1
Sends an email to the manager of the application to inform about a technical event, e.g. if an error occurred.
private void sendTechnicalNotification(final String subject, final String text) { MimeMessagePreparator prep = new MimeMessagePreparator() { @Override public void prepare(MimeMessage mimeMessage) throws javax.mail.MessagingException { mimeMessage.setRecipient(Message.RecipientType.TO, new InternetAddress(emailManager)); mimeMessage.setSubject(properties.getProperty(subject)); mimeMessage.setText(text); } }; try { this.mailSender.send(prep); } catch (MailException ex) { LOG.error("Sending email to " + emailManager + " failed", ex); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void sendEmailToSubscriberForHealthTips() {\n\n\n\n }", "public void sendDiscrepancyEmail() throws Exception;", "private void sendFeedback() {\n final String technicalInfo = commonsLogSender.getExtraInfo();\n\n final Intent feedbackIntent = new Intent(Intent.ACTION_SENDTO);\n feedbackIntent.setType(\"message/rfc822\");\n feedbackIntent.setData(Uri.parse(\"mailto:\"));\n feedbackIntent.putExtra(Intent.EXTRA_EMAIL,\n new String[]{CommonsApplication.FEEDBACK_EMAIL});\n feedbackIntent.putExtra(Intent.EXTRA_SUBJECT,\n CommonsApplication.FEEDBACK_EMAIL_SUBJECT);\n feedbackIntent.putExtra(Intent.EXTRA_TEXT, String.format(\n \"\\n\\n%s\\n%s\", CommonsApplication.FEEDBACK_EMAIL_TEMPLATE_HEADER, technicalInfo));\n try {\n startActivity(feedbackIntent);\n } catch (final ActivityNotFoundException e) {\n Toast.makeText(getActivity(), R.string.no_email_client, Toast.LENGTH_SHORT).show();\n }\n }", "public void sendMailReport() {\n mailService.sendMail(\"[email protected]\", \"ToDo report\",\n String.format(\"There are '%s' todo entries!\", todoListService.getAllEntries().size()));\n }", "@Override\n\tpublic void alert() {\n\t\ttry {\n\t\t\tSystem.out.println(\"ala\");\n\t\t\tfM.sendMail(text, topic, toWho);\n\t\t} finally {\n\t\t\tif (al != null)\n\t\t\t\tal.alert();\n\t\t}\n\t}", "@Override\n public void sendEmail() {\n return;\n }", "@Override\r\n\tpublic void sendEmails() {\n\t\tSystem.out.println(\"All e-mails sent from e-mail service!\");\r\n\t}", "SendEmail() {\t\n\t}", "private void sendNotificationError(Exception e) {\n logger.error(e.getMessage());\n \n }", "private void sendEmail() {\n\n // Set up an intent object to send email and fill it out\n Intent emailIntent = new Intent(Intent.ACTION_SEND);\n emailIntent.setData(Uri.parse(\"mailto:\"));\n emailIntent.setType(\"text/plain\");\n\n // An array of string addresses\n String[] toAddress = new String[]{getString(R.string.email_company_contact)};\n emailIntent.putExtra(Intent.EXTRA_EMAIL, toAddress);\n emailIntent.putExtra(Intent.EXTRA_SUBJECT, getString(R.string.email_subject));\n emailIntent.putExtra(Intent.EXTRA_TEXT, getString(R.string.email_default_text));\n\n // Error handler, try to execute code\n try {\n // Starts a new screen to send email\n startActivity(Intent.createChooser(emailIntent, getString(R.string.email_prompt)));\n finish();\n } catch (android.content.ActivityNotFoundException ex) {\n // An error occurred trying to use the activity\n Toast.makeText(this,\n getString(R.string.error_send_email), Toast.LENGTH_SHORT).show();\n // Missing a finally that closes the activity?\n }\n }", "public static void main(String[] args) throws UnknownHostException, AddressException, MessagingException {\n\t\tSystem.out.println(InetAddress.getLocalHost().getHostAddress());\n\t\tMonitoringMail mail = new MonitoringMail();\n\t\tString messageBody=\"https://\"+InetAddress.getLocalHost().getHostAddress()+ \":8080/C:/work/Selenium/LiveProjects/PageObjectModelBasics/target/surefire-reports/html/extent.html\";\n\t\tSystem.out.println(messageBody);\n\t\tmail.sendMail(TestConfig.server, TestConfig.from, TestConfig.to, TestConfig.subject, messageBody,TestConfig.attachmentPath, TestConfig.attachmentName);\n\t}", "public static void sendAlarmEmail(EmailParameters emailParameters) {\r\n\t\tsendEmail(emailParameters, \"Alarm detected movement at your house!\", \"Alarm detected movement at your house!\");\r\n\t}", "@Override\n\tvoid email() {\n\t\tSystem.out.println(\"email id [email protected]\");\n\t\t\n\t}", "void sendEmail(Task task, String taskTypeName, String plantName);", "public void sendMail(View view) {\n\n contentManager = new ContentManager(this);\n contentManager.sendEmail(helpBinding.mail.getText().toString(), new EmailListener() {\n @Override\n public void onSuccess(EmailResponse emailResponse) {\n showToast(emailResponse.getMessage());\n }\n\n @Override\n public void onFailed(String message, int responseCode) {\n showToast(message);\n }\n\n @Override\n public void startLoading(String requestId) {\n showToast(getString(R.string.sendEmail));\n }\n\n @Override\n public void endLoading(String requestId) {\n\n }\n });\n }", "private void notificationMailGD(String email) {\r\n\t\tlogger.log(IAppLogger.INFO, \"Enter: notificationMailGD()\");\r\n\t\ttry {\r\n\t\t\tProperties prop = new Properties();\r\n\t\t\tprop.setProperty(IEmailConstants.SMTP_HOST, propertyLookup.get(IEmailConstants.SMTP_HOST));\r\n\t\t\tprop.setProperty(IEmailConstants.SMTP_PORT, propertyLookup.get(IEmailConstants.SMTP_PORT));\r\n\t\t\tprop.setProperty(\"senderMail\", propertyLookup.get(\"senderMail\"));\r\n\t\t\tprop.setProperty(\"supportEmail\", propertyLookup.get(\"supportEmail\"));\r\n\t\t\tString subject = propertyLookup.get(\"mail.gd.subject\");\r\n\t\t\tString mailBody = propertyLookup.get(\"mail.gd.body\");\r\n\t\t\tlogger.log(IAppLogger.INFO, \"Email triggered...\");\r\n\t\t\temailSender.sendMail(prop, email, null, null, subject, mailBody);\r\n\t\t\tlogger.log(IAppLogger.INFO, \"Email sent to : \" + email);\r\n\t\t} catch (Exception e) {\r\n\t\t\tlogger.log(IAppLogger.ERROR, \"Unable to send Email: \" + e.getMessage());\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t\tlogger.log(IAppLogger.INFO, \"Exit: notificationMailGD()\");\r\n\t}", "@Override\n\tvoid email() {\n\t\tSystem.out.println(\"[email protected]\");\n\t\t\n\t}", "@Override\n public void onFailure(@NonNull Exception e) {\n Toast.makeText(LogInActivity.this, \"Unable to send the email\"+e.getMessage(), Toast.LENGTH_SHORT).show();\n }", "void sendEmail(Job job, String email);", "public static void sendEmail(EmailSendable e, String message){\n\t\tSystem.out.println(\"Email-a bidali da: \"+message);\r\n\t}", "public void sendEmail(\n ActionRequest actionRequest, ActionResponse actionResponse)\n throws IOException, PortletException {\n }", "public void sendErrorNotificationMail(Download download) {\n sendNotificationMail(download, ERROR_SUBJECT, \"error.ftl\");\n }", "public void onFinish(ISuite arg0) {\n\t\tMonitoringMail mail=new MonitoringMail();\r\n\t\t\r\n\t\ttry {\r\n\t\t\tmessageBody = \"http://\"+InetAddress.getLocalHost().getHostAddress()+\":8080/job/git-DataDriven-Framework/Extent_20reports//\";\r\n\t\t} catch (UnknownHostException e) {\r\n\t\t\t// TODO Auto-generated catch block\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n //System.out.println(hostname);\r\n \r\n try {\r\n\t\tmail.sendMail(TestConfig.server, TestConfig.from, TestConfig.to, TestConfig.subject, messageBody);\r\n\t} catch (AddressException e) {\r\n\t\t// TODO Auto-generated catch block\r\n\t\te.printStackTrace();\r\n\t} catch (MessagingException e) {\r\n\t\t// TODO Auto-generated catch block\r\n\t\te.printStackTrace();\r\n\t}\r\n\t\t\r\n\t}", "@Override\n\tpublic boolean sendEmail() {\n\t\treturn true;\n\t}", "public void sendMail() {\n String sub;\n String message;\n\n sub = \"Welcome\";\n message = \"Thank you for choosing us as your healthcare partners. Here we strive hard to ensure that\\n\"\n + \"you remain in good health. Not only we boast of an exellent team of doctors but also world class operational \\n\"\n + \"infrastructure in place. For any other information or details contact our reg desk. You can access\\n\"\n + \"your account with the Username:\" + txtUserName.getText()+ \"and your password:\" + txtPassword.getPassword().toString()+ \".\\n\\t\\t\\t -Team MVP\";\n\n SendEmail SE = new SendEmail(txtEmail.getText(), sub, message);\n }", "@Override\r\n\tpublic void sendGeneralNotification() {\n\t\t\r\n\t}", "@Override\n\tpublic void sendHtmlEmail(MimeMessage mm) {\n\t\t\n\t}", "public static void main(String[] args) throws AddressException, MessagingException, IOException {\n MonitoringMail mail = new MonitoringMail();\n mail.sendMail(TestConfig.server, TestConfig.from, TestConfig.to, TestConfig.subject, TestConfig.messageBody, TestConfig.attachmentPath, TestConfig.attachmentName);\n\t}", "public static void main(String[] args) {\n MailAdapter mailAdapter = MailAdapter.getInstance();\n mailAdapter.sendEmail(\"[email protected]\", \"[email protected]\", \"We are doing Java\", true);\n mailAdapter.receiveEmail();\n\n }", "@Click public void aboutEmailButton() {\n\n Intent emailIntent = new Intent(\n Intent.ACTION_SENDTO, Uri.parse(\"mailto:\" + Uri.encode(EMAIL))\n );\n //emailIntent.putExtra(Intent.EXTRA_SUBJECT, subject);\n //emailIntent.putExtra(Intent.EXTRA_TEXT, body);\n\n //startActivity(emailIntent);\n //startActivity(Intent.createChooser(emailIntent, \"Send an email\"));\n\n try {\n startActivity(emailIntent);\n } catch (ActivityNotFoundException e) {\n app.toasty(R.string.error_no_email_client);\n e.printStackTrace();\n }\n }", "public void sendEmail(SendEmailRequestDocument parameters) {\r\n\t\t// Add the business logic here\r\n\t\treturn;\r\n\t}", "private void sendEmailWithoutChooser() {\r\n String email = AppConstants.ADMIN_EMAIL;\r\n String feedback_msg = \"\";\r\n Intent emailIntent = new Intent(Intent.ACTION_SENDTO);\r\n String aEmailList[] = {email};\r\n emailIntent.setData(Uri.parse(\"mailto:\")); // only email apps should handle this\r\n emailIntent.putExtra(android.content.Intent.EXTRA_EMAIL, aEmailList);\r\n emailIntent.putExtra(Intent.EXTRA_TEXT, Html.fromHtml(\"<i><font color='your color'>\" + feedback_msg + \"</font></i>\"));\r\n emailIntent.putExtra(Intent.EXTRA_SUBJECT, \"Request help from Customer Support\");\r\n\r\n PackageManager packageManager = getApplicationContext().getPackageManager();\r\n boolean isIntentSafe = emailIntent.resolveActivity(packageManager) != null;\r\n if (isIntentSafe) {\r\n startActivity(emailIntent);\r\n } else {\r\n Toast.makeText(getApplicationContext(), \"Email app is not found\", Toast.LENGTH_SHORT).show();\r\n }\r\n }", "public void sendNotificaitoin(User user) throws MailException, InterruptedException {\n\n\n System.out.println(\"Sending email...\");\n\n SimpleMailMessage mail = new SimpleMailMessage();\n mail.setTo(\"[email protected]\");\n mail.setFrom(\"[email protected]\");\n mail.setSubject(\"notification\");\n mail.setText(\"time is running out\");\n javaMailSender.send(mail);\n\n System.out.println(\"Email Sent!\");\n }", "private void sendEmail() {\n String to = \"[email protected]\";\n\n // Sender's email ID needs to be mentioned\n String from = \"[email protected]\";\n\n // Assuming you are sending email from localhost\n String host = \"localhost\";\n\n // Get system properties\n Properties properties = System.getProperties();\n\n // Setup mail server\n properties.setProperty(\"mail.smtp.host\", host);\n\n // Get the default Session object.\n Session session = Session.getDefaultInstance(properties);\n\n try {\n // Create a default MimeMessage object.\n MimeMessage message = new MimeMessage(session);\n\n // Set From: header field of the header.\n message.setFrom(new InternetAddress(from));\n\n // Set To: header field of the header.\n message.addRecipient(Message.RecipientType.TO, new InternetAddress(to));\n\n // Set Subject: header field\n message.setSubject(\"This is the Subject Line!\");\n\n // Now set the actual message\n message.setText(\"This is actual message\");\n\n // Send message\n Transport.send(message);\n System.out.println(\"Sent message successfully....\");\n } catch (MessagingException mex) {\n mex.printStackTrace();\n }\n }", "public void SendEmail() throws Exception {\r\n\r\n\t\t\t\r\n\t\t// Create the attachment\r\n\t\t EmailAttachment attachment = new EmailAttachment();\r\n\t\t attachment.setURL(new URL(\"file:///C:/Users/sachinsehgal2/eclipse-workspace/TeachAway/Test_Report.html\"));\r\n\t\t attachment.setDisposition(EmailAttachment.ATTACHMENT);\r\n\t\t attachment.setDescription(\"Selenium Report\");\r\n\t\t attachment.setName(\"TeachAway_Menu Navigation Automation Report.html\");\r\n\r\n\t\t // Create the email message\r\n\t\t MultiPartEmail email = new MultiPartEmail();\r\n\t\t\temail.setHostName(\"smtp.gmail.com\");\r\n\t\t\temail.setSmtpPort(465);\r\n\t\t\temail.setAuthentication(\"[email protected]\", \"password\");\r\n\t\t\temail.setSSLOnConnect(true);\r\n\t\t \temail.addCc(\"[email protected]\", \"StakeHolder\");\r\n\t\t\temail.setFrom(\"[email protected]\", \"admin\");\r\n\t\t\temail.setSubject(\"Automation Status -TeachAway Navigation Menu\");\r\n\t\t\temail.setMsg(\"PFA the results for automation of Navigation menu for Teach Away.\");\r\n\t\t \r\n\t\t // add the attachment\r\n\t\t email.attach(attachment);\r\n\t\t // send the email\r\n\t\t email.send();\r\n\t\tSystem.out.println(\"The email Sent\");\r\n\t}", "private void sendErrorMail(Context mContext, String filePath) {\n\t\tIntent sendIntent = new Intent(Intent.ACTION_SEND);\n\t\tString subject = \"Error Description\"; // here subject\n\t\tString body = \"Sorry for your inconvenience .\\nWe assure you that we will solve this problem as soon possible.\"\n\t\t\t\t+ \"\\n\\nThanks for using app.\"; // here email body\n\n\t\tsendIntent.setType(\"plain/text\");\n\t\tsendIntent.putExtra(Intent.EXTRA_EMAIL,\n\t\t\t\tnew String[] { \"[email protected]\" }); // your developer email id\n\t\tsendIntent.putExtra(Intent.EXTRA_TEXT, filePath);\n\t\tsendIntent.putExtra(Intent.EXTRA_SUBJECT, subject);\n//\t\tsendIntent.putExtra(Intent.EXTRA_STREAM,\n//\t\t\t\tUri.fromFile(new File(filePath)));\n\t\t//sendIntent.setType(\"message/rfc822\");\n\t\tmContext.startActivity(Intent.createChooser(sendIntent, \"Complete action using\"));\n\t}", "public void launchEmail(){\n\t\tIntent sendIntent = new Intent(Intent.ACTION_MAIN); \n \tsendIntent.addCategory(Intent.CATEGORY_APP_EMAIL);\n\n if (sendIntent.resolveActivity(pacman) != null) {\n \tstartActivity(sendIntent);\n \treturn;\n } else {\n \tToast.makeText(context, \"No Email App Availible\", Toast.LENGTH_SHORT).show();\n \treturn;\n }\n\t}", "private void sendNotification() {\n }", "private void sendNotificationMail(Download download, String subject, String bodyTemplate) {\n List<Address> emails = getNotificationAddresses(download);\n if (emails.isEmpty() && bccAddresses.isEmpty()) {\n LOG.warn(\"No valid notification addresses given for download {}\", download.getKey());\n return;\n }\n try {\n // Send E-Mail\n MimeMessage msg = new MimeMessage(session);\n msg.setFrom();\n msg.setRecipients(Message.RecipientType.TO, emails.toArray(new Address[emails.size()]));\n msg.setRecipients(Message.RecipientType.BCC, bccAddresses.toArray(new Address[bccAddresses.size()]));\n msg.setSubject(subject);\n msg.setSentDate(new Date());\n msg.setText(buildBody(download, bodyTemplate));\n Transport.send(msg);\n\n } catch (TemplateException | IOException e) {\n LOG.error(NOTIFY_ADMIN, \"Rendering of notification Mail for download [{}] failed\", download.getKey(), e);\n } catch (MessagingException e) {\n LOG.error(NOTIFY_ADMIN, \"Sending of notification Mail for download [{}] failed\", download.getKey(), e);\n }\n }", "public void sendEmail(){\r\n EmailService emailSvc = new EmailService(email, username, password, firstName, lastName);\r\n Thread th = new Thread(emailSvc);\r\n LOG.info(\"Starting a new thread to send the email..\");\r\n th.start();\r\n LOG.info(\"The email was sent successfully\");\r\n }", "@Override\n public void sendEmail(String emailBody) {\n }", "private void sendEmail(String emailAddress, String subject, String body) {\n\t\t\n\t}", "private void sendApplicationApprovedMail(Application application, Applicant applicant, String message) throws MessagingException {\r\n\t\tMailSender ms = new MailSender(\"smtp.gmail.com\", 465, \"[email protected]\", \"fairsailtest\");\r\n\t\t\r\n\t\tms.sendMessage(\"[email protected]\", \"Application was approved\", \"Your application \" + application.getApplicationId() + \" has been successfully approved \\n\\n\" + message, applicant.getEmailAddress());\r\n\t}", "public static void sendToUserErrorMail(FormStackInfo info) throws JSONException{\n\t\tSendGrid sendGrid = new SendGrid(\"user\", \"password\");\n\t\tEmail email = new Email();\n\t\temail.addTo(info.getEmail());\n\t\temail.setFrom(\"[email protected]\");\n\t\temail.setReplyTo(\"[email protected]\");\n\t\temail.setSubject(\"Error\");\n\t\temail.setHtml(\"Your Error Message to User\");\n\t\ttry{\n\t\t\tsendGrid.send(email);\n\t\t}catch(Exception e){\n\t\t\te.printStackTrace();\n\t\t}\n\t}", "private void sendEmail() {\n\n\n Log.i(TAG, \" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\");\n\n\n Log.i(TAG, \"sendEmail: \"+currentEmail);\n\n Log.i(TAG, \" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\");\n\n\n String email = currentEmail.trim();\n String subject = \"Garbage Report Handeled\";\n\n String message = textViewStreet.getText().toString() + \" \" + \"request has been handeled\" +\" \"+textViewDescription.getText().toString();\n\n// String message = textViewStreet.getText().toString() + \" \" + \"request has been handeled\" + \" \" +time+\" \"+textViewDescription.getText().toString();\n //Creating SendMail object\n SendMail sm = new SendMail(this, email, subject, message);\n\n //Executing sendmail to send email\n sm.execute();\n }", "public void sendEmail(final Context context, final String title) {\n\t\tsendEmail(context, title, \"\");\n\t}", "public void sendEmail(Author authorObject);", "private void email() throws IOException {\n\t\t/*\n\t\tString emailText = \"This email includes the following Play Types: \" + playSort.getSelectedItem().toString() + \n\t\t\t\t\"\\nFrom the gameplan: \" + gamePlans.getSelectedItem().toString();\n\t\tString subject = playSort.getSelectedItem().toString() + \" from \" + gamePlans.getSelectedItem().toString();\n\t\t\t\t\n\t\t// TODO: save image to file system, and add the file paht to atachment\n\t\tArrayList<String> attachments = DigPlayDB.getInstance(getBaseContext()).getAllPlayNames();\n\t\tArrayList<String> attachmentPath = new ArrayList<String>();\n\t\tfor (int att = 0; att < attachments.size(); att++) \n\t\t{\n\t\t\tFile myFile = new File(\"/sdcard/DCIM/Play/temp.jpeg\");\n\t\t\tmyFile.setWritable(true);\n\t FileOutputStream myOutWriter =new FileOutputStream(myFile);\n\t myOutWriter.write(DigPlayDB.getInstance(getBaseContext()).getImage(attachments.get(att)));\n\t myOutWriter.flush();\n\t myOutWriter.close();\n\t myFile.setReadable(true);\n\t attachmentPath.add(myFile.getAbsolutePath());\n\t\t}\n\n\t\tEmailPlaybook.EmailAttachment(this, \"[email protected]\", subject, emailText, attachmentPath);\n\t\t*/\n\t}", "private void sendApplicationRejectedMail(Application application, Applicant applicant, String message) throws MessagingException {\r\n\t\tMailSender ms = new MailSender(\"smtp.gmail.com\", 465, \"[email protected]\", \"fairsailtest\");\r\n\t\t\r\n\t\tms.sendMessage(\"[email protected]\", \"Application was rejected\", \"Your application \" + application.getApplicationId() + \" has been rejected\\n\\n\" + message, applicant.getEmailAddress());\r\n\t}", "public void sendHtmlEmail() throws EmailException, MalformedURLException,\n\t\t\tUnsupportedEncodingException, ParseException {\n\t\tITrustContributionServer trustContributionServer = new TrustContributionServer();\n\t\tHtmlEmail email = new HtmlEmail();\n\t\temail.setHostName(\"smtp.exmail.qq.com\");\n\n\t\t// TODO 收件人:资产管理中心全体员工;[email protected];\n\t\tString itemCode = \"v00003\";\n\t\tList<String> emailList = new ArrayList<>();\n\t\temailList = trustContributionServer.getEmailList(itemCode);\n\t\tif (emailList != null && emailList.size() != 0) {\n\t\t\tString[] toBeStored = emailList\n\t\t\t\t\t.toArray(new String[emailList.size()]);\n\t\t\temail.addTo(toBeStored);\n\t\t}\n\n\t\t// email.addTo(new String[]{\"[email protected]\",\"[email protected]\"});\n\n\t\temail.setSmtpPort(465);\n\t\temail.setAuthenticator(new DefaultAuthenticator(\"[email protected]\",\n\t\t\t\t\"Wzm910712\"));\n\t\temail.setSSLOnConnect(true);\n\t\temail.setFrom(\"[email protected]\");\n\t\tDateFormat format = new SimpleDateFormat(\"yyyy-MM-dd\");\n\t\tDate yestoday = getYestoday();\n\t\temail.setSubject(\"投融资部-每日中航百度报酬日报--\" + format.format(yestoday));\n\t\t/*\tString caption = new String((\"中航百度报酬日报--\").getBytes(\"GBK\"),\n\t\t\t\t\"ISO-8859-1\") + format.format(yestoday);\n\t\tString td1 = new String((\"昨日信托报酬\").getBytes(\"GBK\"), \"ISO-8859-1\");\n\t\tString td2 = new String((\"累计信托报酬\").getBytes(\"GBK\"), \"ISO-8859-1\");\n\t\tString td3 = new String((\"昨日保管费\").getBytes(\"GBK\"), \"ISO-8859-1\");\n\t\tString td4 = new String((\"累计保管费\").getBytes(\"GBK\"), \"ISO-8859-1\");\n\t\tString td5 = new String((\"昨日优先收益\").getBytes(\"GBK\"), \"ISO-8859-1\");\n\t\tString td6 = new String((\"累计优先收益\").getBytes(\"GBK\"), \"ISO-8859-1\");\n\t\tString td7 = new String((\"上月优先级本金\").getBytes(\"GBK\"), \"ISO-8859-1\");\n\t\tString td8 = new String((\"上月劣后级本金\").getBytes(\"GBK\"), \"ISO-8859-1\");\n\n\t\tString td31 = new String((\"上月差额补足金额\").getBytes(\"GBK\"), \"ISO-8859-1\");\n\t\tString td32 = new String((\"上月保证金1\").getBytes(\"GBK\"), \"ISO-8859-1\");\n\t\tString td33 = new String((\"上月客户退货款\").getBytes(\"GBK\"), \"ISO-8859-1\");\n\t\tString td34 = new String((\"上月客户主动还款\").getBytes(\"GBK\"), \"ISO-8859-1\");\n\t\tString td35 = new String((\"M3+率\").getBytes(\"GBK\"), \"ISO-8859-1\");\n\t\tString td36 = new String((\"B3\").getBytes(\"GBK\"), \"ISO-8859-1\");\n\t\tString td37 = new String((\"M2+率\").getBytes(\"GBK\"), \"ISO-8859-1\");\n\t\tString td38 = new String((\"B2\").getBytes(\"GBK\"), \"ISO-8859-1\");\n\n\t\t// TODO 查询出各个数据\n\t\tdouble custodianFee = 0;\n\t\tdouble priorityEarnings = 0;\n\t\tdouble trustremuneration = 0;\n\t\tMap<String, Object> map = new HashMap<>();\n\t\tmap = trustContributionServer.getDetailFromBenefitCheckDaily(partner);\n\t\tif (map != null) {\n\t\t\tcustodianFee = Double.parseDouble(map.get(\"CUSTODIANFEE\")\n\t\t\t\t\t.toString());\n\t\t\tpriorityEarnings = Double.parseDouble(map.get(\"PRIORITYEARNINGS\")\n\t\t\t\t\t.toString());\n\t\t\ttrustremuneration = Double.parseDouble(map.get(\"TRUSTREMUNERATION\")\n\t\t\t\t\t.toString());\n\t\t}\n\n\t\t// 累计信托报酬\n\t\tMap<String, Object> trustRemunerationMap = new HashMap<>();\n\t\tdouble sumOftrustRemuneration = 0;\n\t\ttrustRemunerationMap = trustContributionServer\n\t\t\t\t.getSumOfBenefitCheckDaily(partner);\n\t\tif (trustRemunerationMap != null) {\n\t\t\tsumOftrustRemuneration = Double.parseDouble(trustRemunerationMap\n\t\t\t\t\t.get(\"TRUSTREMUNERATION\").toString());\n\t\t}\n\n\t\t// 累计优先收益\n\t\tMap<String, Object> priorityEaringsMap = new HashMap<>();\n\t\tdouble sumOfpriorityEarings = 0;\n\t\tpriorityEaringsMap = trustContributionServer\n\t\t\t\t.getSumOfPriorityEarings(partner);\n\t\tif (priorityEaringsMap != null) {\n\t\t\tsumOfpriorityEarings = Double.parseDouble(priorityEaringsMap.get(\n\t\t\t\t\t\"PRIORITYEARINGS\").toString());\n\t\t}\n\n\t\t// 累计保管费\n\t\tMap<String, Object> custodianFeeMap = new HashMap<>();\n\t\tdouble sumOfcustodianFee = 0;\n\t\tcustodianFeeMap = trustContributionServer.getSumOfcustodianFee(partner);\n\t\tif (custodianFeeMap != null) {\n\t\t\tsumOfcustodianFee = Double.parseDouble(custodianFeeMap.get(\n\t\t\t\t\t\"CUSTODIANFEE\").toString());\n\t\t}\n\n\t\tMap<String, Object> benefitCheckMonthSummaryMap = new HashMap<>();\n\n\t\tdouble priorityPrincipal = 0;\n\t\t// 上月劣后级本金\n\t\tdouble inferiorPrincipal = 0;\n\t\t// 上月差额补足金额\n\t\tdouble differenceUpBalance = 0;\n\t\t// 上月保证金\n\t\tdouble serviceFee = 0;\n\t\t// 上月客户退货款\n\t\tdouble merchantsRetmoneyActual = 0;\n\t\t// 上月客户主动还款\n\t\tdouble customeDrivingRepayment = 0;\n\n\t\tbenefitCheckMonthSummaryMap = trustContributionServer\n\t\t\t\t.getdetailFromMonthSummary(partner);\n\t\tif (benefitCheckMonthSummaryMap != null) {\n\n\t\t\tpriorityPrincipal = Double.parseDouble(benefitCheckMonthSummaryMap\n\t\t\t\t\t.get(\"PRIORITYPRINCIPAL\").toString());\n\n\t\t\tinferiorPrincipal = Double.parseDouble(benefitCheckMonthSummaryMap\n\t\t\t\t\t.get(\"INFERIORPRINCIPAL\").toString());\n\n\t\t\tdifferenceUpBalance = Double\n\t\t\t\t\t.parseDouble(benefitCheckMonthSummaryMap.get(\n\t\t\t\t\t\t\t\"DIFFERENCEUPBALANCE\").toString());\n\n\t\t\tserviceFee = Double.parseDouble(benefitCheckMonthSummaryMap.get(\n\t\t\t\t\t\"SERVICEFEE\").toString());\n\n\t\t\tmerchantsRetmoneyActual = Double\n\t\t\t\t\t.parseDouble(benefitCheckMonthSummaryMap.get(\n\t\t\t\t\t\t\t\"MERCHANTSRETMONEYACTUAL\").toString());\n\n\t\t\tcustomeDrivingRepayment = Double\n\t\t\t\t\t.parseDouble(benefitCheckMonthSummaryMap.get(\n\t\t\t\t\t\t\t\"CUSTOMEDRIVINGREPAYMENT\").toString());\n\t\t}\n\n\t\t// B3=B2\n\t\tString partnerCode = \"\";\n\t\tif (partner.equalsIgnoreCase(\"众安\")) {\n\t\t\tpartnerCode = \"ZAYX\";\n\t\t}// 改为map为添加条件,做一下为null 时候的判断\n\t\t//partnerCode = \"HBYH\";// TODO delete when upload,and sql update\n\t\tMap<String, Object> resultB3Map = new HashMap<>();\n\n\t\tMap<String, Object> resultB2Map = new HashMap<>();\n\n\t\tdouble B3Part1 = 0;\n\t\tdouble B3Part2 = 0;\n\t\tresultB3Map = trustContributionServer\n\t\t\t\t.getB3Part1FromPayDaily(partnerCode);\n\n\t\tif (resultB3Map != null) {\n\t\t\tB3Part1 = Double.parseDouble((resultB3Map.get(\"PAYPRINCIPALAMT\")\n\t\t\t\t\t.toString()));\n\t\t}\n\t\tresultB2Map = trustContributionServer\n\t\t\t\t.getB3Part2FromPayDaily(partnerCode);\n\t\tif (resultB2Map != null) {\n\t\t\tB3Part2 = Double.parseDouble((resultB2Map.get(\"PAYPRINCIPALAMT\")\n\t\t\t\t\t.toString()));\n\t\t}\n\t\t\n\t\t * double B3Part1=\n\t\t * trustContributionServer.getB3Part1FromPayDaily(partnerCode);\n\t\t * \n\t\t * double B3Part2 =\n\t\t * trustContributionServer.getB3Part2FromPayDaily(partnerCode);\n\t\t \n\n\t\tBigDecimal d1 = new BigDecimal(String.valueOf(B3Part1));\n\n\t\tBigDecimal d2 = new BigDecimal(String.valueOf(B3Part2));\n\n\t\tdouble B3 = d1.add(d2).doubleValue();\n\n\t\t// A3\n\t\tint days = 90;\n\t\tMap<String, Object> A3Map = new HashMap<>();\n\t\tA3Map.put(\"partnerCode\", partnerCode);\n\t\tA3Map.put(\"days\", days);\n\n\t\tdouble fPayCapital = 0;\n\t\tdouble fUndueCapital = 0;\n\t\t// 获取大于 90 天的应付本金\n\t\tMap<String, Object> over90DaysCapitalMap1 = new HashMap<>();\n\t\tover90DaysCapitalMap1 = trustContributionServer\n\t\t\t\t.getOverDueDaysCapital1(A3Map);\n\t\tif (over90DaysCapitalMap1 != null) {\n\t\t\tfPayCapital = Double.parseDouble(over90DaysCapitalMap1.get(\n\t\t\t\t\t\"PAYPRINCIPALAMT\").toString());\n\t\t}\n\n\t\tMap<String, Object> over90DaysCapitalMap2 = new HashMap<>();\n\t\tover90DaysCapitalMap2 = trustContributionServer\n\t\t\t\t.getOverDueDaysCapital2(A3Map);\n\t\tif (over90DaysCapitalMap2 != null) {\n\t\t\tfUndueCapital = Double.parseDouble(over90DaysCapitalMap2.get(\n\t\t\t\t\t\"PAYPRINCIPALAMT\").toString());\n\t\t}\n\n\t\tBigDecimal d1Capital = new BigDecimal(String.valueOf(fPayCapital));\n\t\tBigDecimal d2Capital = new BigDecimal(String.valueOf(fUndueCapital));\n\t\tdouble allCapital = d1Capital.add(d2Capital).doubleValue();\n\n\t\tdouble A3 = 0;\n\t\t// 获取实付本金\n\t\tMap<String, Object> resultMap = new HashMap<>();\n\t\tresultMap = trustContributionServer.getA3Capital(A3Map);\n\t\tif (resultMap != null) {\n\t\t\tA3 = allCapital\n\t\t\t\t\t- Double.parseDouble((resultMap.get(\"PAYPRINCIPALAMT\")\n\t\t\t\t\t\t\t.toString()));\n\t\t}\n\n\t\tMap<String, Object> A2Map = new HashMap<>();\n\t\tdouble A2 = 0;\n\t\tA2Map.put(\"partnerCode\", partnerCode);\n\t\tint days2 = 60;\n\t\tA2Map.put(\"days\", days2);\n\n\t\t// 获取逾期60天以上的应付本金\n\t\tdouble fPayCapita1 = 0;\n\t\tdouble fUndueCapita1 = 0;\n\t\tMap<String, Object> over60DaysCapitalMap1 = new HashMap<>();\n\t\tover60DaysCapitalMap1 = trustContributionServer\n\t\t\t\t.getOverDueDaysCapital1(A2Map);\n\t\tif (over60DaysCapitalMap1 != null) {\n\t\t\tfPayCapita1 = Double.parseDouble(over60DaysCapitalMap1.get(\n\t\t\t\t\t\"PAYPRINCIPALAMT\").toString());\n\t\t}\n\n\t\tMap<String, Object> over60DaysCapitalMap2 = new HashMap<>();\n\t\tover60DaysCapitalMap2 = trustContributionServer\n\t\t\t\t.getOverDueDaysCapital2(A2Map);\n\t\tif (over60DaysCapitalMap2 != null) {\n\t\t\tfUndueCapita1 = Double.parseDouble(over60DaysCapitalMap2.get(\n\t\t\t\t\t\"PAYPRINCIPALAMT\").toString());\n\t\t}\n\n\t\tBigDecimal d1Capital1 = new BigDecimal(String.valueOf(fPayCapita1));\n\t\tBigDecimal d2Capital1 = new BigDecimal(String.valueOf(fUndueCapita1));\n\t\tdouble allCapital1 = d1Capital1.add(d2Capital1).doubleValue();\n\n\t\tMap<String, Object> resultMap2 = new HashMap<>();\n\t\tresultMap2 = trustContributionServer.getA3Capital(A2Map);\n\t\tif (resultMap2 != null) {\n\t\t\t// TODO\n\t\t\tA2 = allCapital1\n\t\t\t\t\t- Double.parseDouble((resultMap2.get(\"PAYPRINCIPALAMT\")\n\t\t\t\t\t\t\t.toString()));\n\t\t}\n\n\t\t// 获取格式化对象\n\t\tNumberFormat nt = NumberFormat.getPercentInstance();\n\t\t// 设置百分数精确度2即保留两位小数\n\t\tnt.setMinimumFractionDigits(2);\n\t\t// 最后格式化并输出\n\n\t\t// TODO\n\t\t\n\t\t * String M3= nt.format(A3/B3); String M2 = nt.format(A2/B3);\n\t\t \n\t\tString M3 = \"0.00%\";\n\t\tString M2 = \"0.00%\";\n\t\tif (B3 != 0) {\n\t\t\tM3 = nt.format(A3 / B3);\n\t\t\tM2 = nt.format(A2 / B3);\n\t\t}\n\t\t\n\n\t\tURL url = new URL(\"http://www.apache.org/images/asf_logo_wide.gif\");\n\t\t// String cid = email.embed(url, \"Apache logo\");\n\t\t\n\t\tString firstTable = \"<div>\"\n\t\t\t\t+ \"<table width=\\\"1150\\\" border=\\\"1\\\" cellspacing=\\\"0\\\">\"\n\t\t\t\t+ \"<caption>\"\n\t\t\t\t+ caption\n\t\t\t\t+ \"</caption>\"\n\t\t\t\t+ \"<tr style=\\\"background-color:#f47920\\\">\"\n\t\t\t\t+ \"<td align=\\\"center\\\">\"\n\t\t\t\t+ td1\n\t\t\t\t+ \"</td>\"\n\t\t\t\t+ \"<td align=\\\"center\\\">\"\n\t\t\t\t+ td2\n\t\t\t\t+ \"</td>\"\n\t\t\t\t+ \"<td align=\\\"center\\\">\"\n\t\t\t\t+ td3\n\t\t\t\t+ \"</td>\"\n\t\t\t\t+ \"<td align=\\\"center\\\">\"\n\t\t\t\t+ td4\n\t\t\t\t+ \"</td>\"\n\t\t\t\t+ \"<td align=\\\"center\\\">\"\n\t\t\t\t+ td5\n\t\t\t\t+ \"</td>\"\n\t\t\t\t+ \"<td align=\\\"center\\\">\"\n\t\t\t\t+ td6\n\t\t\t\t+ \"</td>\"\n\t\t\t\t+ \"<td align=\\\"center\\\">\"\n\t\t\t\t+ td7\n\t\t\t\t+ \"</td>\"\n\t\t\t\t+ \"<td align=\\\"center\\\">\"\n\t\t\t\t+ td8\n\t\t\t\t+ \"</td>\"\n\t\t\t\t+ \"</tr>\"\n\t\t\t\t+ \"<tr>\"\n\t\t\t\t+ \"<td align=\\\"center\\\">\"\n\t\t\t\t+ trustremuneration\n\t\t\t\t+ \"</td>\"\n\t\t\t\t+ \"<td align=\\\"center\\\">\"\n\t\t\t\t+ sumOftrustRemuneration\n\t\t\t\t+ \"</td>\"\n\t\t\t\t+ \"<td align=\\\"center\\\">\"\n\t\t\t\t+ custodianFee\n\t\t\t\t+ \"</td>\"\n\t\t\t\t+ \"<td align=\\\"center\\\">\"\n\t\t\t\t+ sumOfcustodianFee\n\t\t\t\t+ \"</td>\"\n\t\t\t\t+ \"<td align=\\\"center\\\">\"\n\t\t\t\t+ priorityEarnings\n\t\t\t\t+ \"</td>\"\n\t\t\t\t+ \"<td align=\\\"center\\\">\";*/\n\t\tStringBuilder a1RateBuilder = new StringBuilder();\n\t\ta1RateBuilder = this.getA1RateBuilder();\n\t\t\n\t\tStringBuilder a2RateBuilder = new StringBuilder();\n\t\ta2RateBuilder = this.getA2RateBuilder();\n\t\tString commonHead = \"<html>\" + \"<head>\" + \" </head>\" + \"<body>\";\n\t\tString htmlMsg = commonHead\n\t\t\t\t+ a1RateBuilder.toString()\n\t\t\t\t+\"</body>\" + \"</html>\";\n\t\temail.setHtmlMsg(htmlMsg);\n\t\temail.send();\n\t}", "private void sendEmail(){\n String teachersEmail = tvTeachersEmail.getText().toString();\n String[] receiver = new String[1];\n receiver[0] = teachersEmail;\n Intent intent = new Intent(Intent.ACTION_SEND);\n intent.putExtra(Intent.EXTRA_EMAIL, receiver);\n\n // opening only email clients - force sending with email\n intent.setType(\"message/rfc822\");\n startActivity(Intent.createChooser(intent, getString(R.string.open_email_clients)));\n }", "public Email(Application application, Manager manager){\n setRecipient(manager.getEmail());\n setContent(application.getTitle(),manager.getFirstname() + \" \" +manager.getLastname(),\n application.getId(), ASSIGNED);\n setSubject(\"Application Notification\");\n type = ASSIGNED;\n }", "void send(Email email);", "SendEmailResponse sendEmail(String templateId, String emailAddress, Map<String, String> personalisation, String reference) throws NotificationClientException;", "void send(String emailName);", "public void mailErrorToAdmin(String descripcion, Exception e)\r\n\t\t\tthrows MailerException;", "public final void testSendMail() throws EMagineException {\r\n\t\tCollection<Attachment> attachments = new ArrayList<Attachment>();\r\n\t\tAttachment attachment = new Attachment();\r\n\t\tattachment.setName(this.getClass().getSimpleName()+\".java\");\r\n\t\tattachment.setPath(\"TestSource/\"+this.getClass().getPackage().getName().replaceAll(\"\\\\.\", \"/\")+\"/\"+this.getClass().getSimpleName()+\".java\");\r\n\t\tattachments.add(attachment);\r\n\t\tMailManager.sendMail(\"[email protected]\", \"MailManagerTest\", \"Just a funny test\", attachments);\r\n\t}", "public void sendEmail(String receiver, Integer indexID){\r\n\t \r\n\t Properties props = new Properties();\r\n\t props.put(\"mail.smtp.host\", EMAIL_SERVER);\r\n\t props.put(\"mail.smtp.port\", SERVER_PORT);\r\n\t props.put(\"mail.smtp.starttls.enable\", \"true\");\r\n\t props.put(\"mail.smtp.auth\", \"true\");\r\n\t props.put(\"mail.smtp.socketFactory.port\", SERVER_PORT);\r\n\t props.put(\"mail.smtp.socketFactory.class\", \"javax.net.ssl.SSLSocketFactory\");\r\n\t props.put(\"mail.smtp.socketFactory.fallback\", \"false\");\r\n\t \r\n\t Session sess = Session.getInstance(props,\r\n\t\t\t new javax.mail.Authenticator() {\r\n\t\t \t\tprotected PasswordAuthentication getPasswordAuthentication() {\r\n\t\t \t\t\treturn new PasswordAuthentication(EMAIL_SENDER, PW_SENDER);\r\n\t\t \t\t}\r\n\t \t});\r\n\t \r\n\t try{ \r\n\t Message msg = new MimeMessage(sess);\r\n\t msg.setFrom(new InternetAddress(EMAIL_SENDER));\r\n\t msg.setRecipients(Message.RecipientType.TO,InternetAddress.parse(receiver));\r\n\t msg.setSubject(\"Notification regarding waitlist\");\r\n\t \r\n\t Transport.send(msg);\r\n\t System.out.println(\"Email has been send successfully!\"); \r\n\t }\r\n\t \r\n\t catch (MessagingException e){\r\n\t\t throw new RuntimeException(e);\r\n\t }\r\n\t \r\n\t \r\n\t }", "@Override\n\tprotected String doIt() throws Exception {\n\t\tString returnMsg = Msg.getMsg(getCtx(), \"EGGO_SENDMAIL_EVENT\");\n\t\tMOrder mo = new MOrder(getCtx(), Order_ID, get_Trx());\n\t\tif(EventType.equals(\"05\") && (mo.get_ValueAsTimestamp(\"DatePose\") == null || mo.get_ValueAsTimestamp(\"Z_DATELIVRCLI\")==null))\n\t\t{\n\t\t\treturn Msg.getMsg(getCtx(), \"EGGO_SENDMAIL_ERR\");\n\t\t}\n\t\t//SI\n\t\t//XX_no_solde_inv_gest\n\t\t\n\t\t\n\t\tif(EventType.equals(\"05\")) {\n\t\t\tString role = \"\"+getCtx().getAD_Role_ID();\n\t\t\tString XX_Gest_roles = Msg.getMsg(getCtx(), \"XX_Gest_roles\");\n\t\t\tString XX_Gest_rolesXX = Msg.getMsg(getCtx(), \"XX_Gest_roles++\");\n\t\t\tString XX_no_solde_inv_gest = Msg.getMsg(getCtx(), \"XX_no_solde_inv_gest\");\n\t\t\tString XX_no_solde_inv_gestXX = Msg.getMsg(getCtx(), \"XX_no_solde_inv_gest++\");\n\t\t\tString XX_no_ech_05_gest = Msg.getMsg(getCtx(), \"XX_no_ech_05_gest\");\n\t\t\tString XX_no_ech_05_gestXX = Msg.getMsg(getCtx(), \"XX_no_ech_05_gest++\");\n\t\t\tif(XX_Gest_roles.contains(role))\n\t\t\t{\n\t\t\t\t//No 05 ?\n\t\t\t\tint nbECH05 = QueryUtil.getSQLValue(get_Trx(), \"Select count(1) from z_orderpaymschedule where C_order_ID = ? and exists (select 1 from z_typeecheance \"\n\t\t\t\t\t+ \"where z_typeecheance.z_typeecheance_ID = z_orderpaymschedule.z_typeecheance_ID and value = '05')\", Order_ID);\n\t\t\t\tif(nbECH05 <= 0)\n\t\t\t\t\treturnMsg = XX_no_ech_05_gest;\n\t\t\t\telse {\n\t\t\t\t\tint inv_id = QueryUtil.getSQLValue(get_Trx(), \"Select max(C_Invoice_ID) from z_orderpaymschedule where C_order_ID = ? and exists (select 1 from z_typeecheance \"\n\t\t\t\t\t\t+ \"where z_typeecheance.z_typeecheance_ID = z_orderpaymschedule.z_typeecheance_ID and value = '05')\", Order_ID);\n\t\t\t\t\tif(inv_id<=0)\n\t\t\t\t\t{\n\t\t\t\t\t\tthrow new CompiereException(XX_no_solde_inv_gest);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\n\t\t\tif(XX_Gest_rolesXX.contains(role))\n\t\t\t{\n\t\t\t\tint nbECH05 = QueryUtil.getSQLValue(get_Trx(), \"Select count(1) from z_orderpaymschedule where C_order_ID = ? and exists (select 1 from z_typeecheance \"\n\t\t\t\t\t\t+ \"where z_typeecheance.z_typeecheance_ID = z_orderpaymschedule.z_typeecheance_ID and value = '05')\", Order_ID);\n\t\t\t\t\tif(nbECH05 <= 0)\n\t\t\t\t\t\treturnMsg = XX_no_ech_05_gestXX;\n\t\t\t\t\telse {\n\t\t\t\t\t\tint inv_id = QueryUtil.getSQLValue(get_Trx(), \"Select max(C_Invoice_ID) from z_orderpaymschedule where C_order_ID = ? and exists (select 1 from z_typeecheance \"\n\t\t\t\t\t\t\t+ \"where z_typeecheance.z_typeecheance_ID = z_orderpaymschedule.z_typeecheance_ID and value = '05')\", Order_ID);\n\t\t\t\t\t\tif(inv_id<=0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\treturnMsg = XX_no_solde_inv_gestXX;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tString ret = WSUtil.SendEmailEvent(getCtx(), mo, EventType,getAD_PInstance_ID(), get_Trx());\n\t\tif(ret == null)\n\t\t{\n\t\t\treturn \"Event Type not supported\";\n\t\t}\n\t\treturn returnMsg;\n\t}", "public Boolean sendEmail(String sender, String receiver, String subject, String body) throws Exception;", "public static void main(String[] args) throws EmailException {\n\n\t\tString text= \"<table><tr><td>EmpId</td><td>Emp name</td><td>age</td></tr><tr><td>value</td><td>value</td><td>value</td></tr></table>\";\n\t\tEmail email=new SimpleEmail();\n\t\t//MailMessage mail = new MailMessage();\n\t\t\n\t\temail.setHostName(\"smtp.googlemail.com\");\n\t\temail.setSmtpPort(465);\n\t\temail.setAuthenticator(new DefaultAuthenticator(\"[email protected]\", \"\"));\n\t\temail.setSSL(true);\n\t\temail.setFrom(\"[email protected]\");\n\t\temail.setSubject(\"TestMail\");\n\t\temail.setMsg(text);\n\t\t\n\t\temail.addTo(\"[email protected]\");\n\t\temail.send();\n\t\t\n\t\tSystem.out.println(\"Email Sent Sucessfully\");\n\t\t\n}", "private void sendEmail(String result){\n \t\n \tIntent emailIntent = new Intent(android.content.Intent.ACTION_SEND);\n \temailIntent.setType(\"plain/text\");\n \t\n \t//emailIntent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);\n\n \t/* Fill it with Data */\n \temailIntent.setType(\"plain/text\");\n \t//emailIntent.putExtra(android.content.Intent.EXTRA_EMAIL, new String[]{\"[email protected]\"});\n \temailIntent.putExtra(android.content.Intent.EXTRA_SUBJECT, \"Here's the code from FlipSHA\");\n \temailIntent.putExtra(android.content.Intent.EXTRA_TEXT, \"After the coin is flipped and\" +\n \t\t\t\" you don't believe in your friend, check this hash \"+ result);\n\n \t/* Send it off to the Activity-Chooser */\n \tstartActivity(emailIntent); \n }", "private void mailLogs(Configuration config) {\r\n\t\tString smtp = config.getProps().getProperty(\"smtp.host\");\r\n\t\tString recipients = config.getProps().getProperty(\"recipients\");\r\n\r\n\t\tif (smtp == null || recipients == null) {\r\n\t\t\tlog.warn(\"Mail can't be configured. Not sending report.\");\r\n\t\t\treturn;\r\n\t\t}\r\n\t\tMail mail = new Mail(smtp, recipients);\r\n\t\ttry {\r\n\t\t\tmail.send(config.getTestName() + \" : \" + config.getTestCase(),\r\n\t\t\t\t\tconfig.toString());\r\n\t\t} catch (MessagingException e) {\r\n\t\t\t// e.printStackTrace();\r\n\t\t}\r\n\t}", "public static void sendEmail(SuspectionReport report,String covidLocation) throws Exception {\n\t\tlogger.info(\"--------------- sendEmailToCustomer --------------\");\n\t\ttry {\n\t\t\tProperties mailProps = new Properties();\n\t\t\tfinal String username = \"[email protected]\";\n\t final String password = \"bvhibkzgkicfdsqh\";\n\n\t Properties props = new Properties();\n\t props.put(\"mail.smtp.starttls.enable\",\"true\");\n\t props.put(\"mail.smtp.host\", \"smtp.gmail.com\"); \n\t props.put(\"mail.smtp.auth\", \"true\"); \n\t props.put(\"mail.smtp.port\", \"587\"); ; //TLS\n\t \n\t Session session = Session.getDefaultInstance(props, \n\t new javax.mail.Authenticator() { \n\t protected PasswordAuthentication getPasswordAuthentication() { \n\t return new PasswordAuthentication(username,password); \n\t } \n\t }); \n\t\t\t//mailProps.put(\"mail.smtp.host\", apiUtil.getProperty(\"spring.mail.host\"));\n\t\t\t//Session mailSession = Session.getDefaultInstance(mailProps, null);\n\t\t\tInternetAddress toAddrs = new InternetAddress(apiUtil.getProperty(\"email.to.address\"));\n\t\t\t\n\t\t\tInternetAddress fromAddr = new InternetAddress(apiUtil.getProperty(\"email.from.address\").toString().trim());\n\t\t\t// Create and initialize message\n\t\t\tjavax.mail.Message message = new MimeMessage(session);\n\t\t\tmessage.setFrom(fromAddr);\n\t\t\tmessage.setRecipient(javax.mail.Message.RecipientType.TO, toAddrs);\n\t\t\t// message.setRecipients(Message.RecipientType.CC, ccAddrs);\n\t\t\tmessage.setSubject(\"Covid Contact Suspection\" );\n\t\t\tInternetAddress[] replyTo = new InternetAddress[1];\n\t\t\treplyTo[0]=new InternetAddress(apiUtil.getProperty(\"email.from.address\").toString().trim());\n\t\t\tmessage.setReplyTo(replyTo);\n\t\t\tmessage.setContent(velocityUtil.getEmailTemplate(report,covidLocation),\"text/html\");\n\t\t\t// Send message \t\t\t\n\t\t\tTransport.send(message);\n\t\t\tlogger.info(\"--------------- Email has been sent --------------\");\n\t\t} catch (MessagingException e) {\n\t\t\tlogger.error(\"--------------- Exception --------------\" + e.getMessage());\n\t\t}\n\t}", "@RequestMapping(\"/mail\")\n\tpublic String mail() throws MessagingException {\n\t\tmailsender.send(\"[email protected]\", \"A test mail\", \"body of the test mail\");\n\t\t\n\t\treturn \"mail sent by Nawaki to the localhost...........\";//result\n\t}", "protected void firePaperJamEvent()\n {\n // construct parameters and signatures\n Object[] parameter = new Object[ 1 ];\n parameter[ 0 ] = new Notification( \n \"PrinterEvent.PAPER_JAM\", this, 0L );\n String[] signature = new String[ 1 ];\n signature[ 0 ] = \"javax.management.Notification\";\n \n // invoke notification\n try {\n mBeanServer.invoke( eventBroadcasterName,\n \"sendNotification\", parameter, signature ); \n } \n\n // handle exception when invoking method\n catch( ReflectionException exception ) {\n exception.printStackTrace();\n }\n\n // handle exception communicating with MBean\n catch( MBeanException exception ) {\n exception.printStackTrace();\n } \n\n // handle exception if MBean not found\n catch( InstanceNotFoundException exception ) {\n exception.printStackTrace();\n } \n\n }", "public void tradeEmail(Trade model, Activity view) {\n String subject = \"SSCTE Trade Completed\" ;\n String body = model.getOwner().getName() + \" has accepted a trade with \" + model.getBorrower().getName() + \".\\n\" +\n \"+=================================+\\n\" +\n \" \" + model.getOwner().getName() + \"'s cards traded:\\n\";\n for (Card card : model.getOwnerList()) {\n body = body + \" [\" + card.getQuantity() + \"] \" + card.getName() + \"\\n\";\n }\n body = body +\n \"+=====================+\\n\" +\n \" \" + model.getBorrower().getName() + \"'s cards traded:\\n\";\n for (Card card : model.getBorrowList()) {\n body = body + \" [\" + card.getQuantity() + \"] \" + card.getName() + \"\\n\";\n }\n body = body +\n \"+=================================+\\n\\n\" +\n \" [Add some comments for continuing trade here]\";\n\n\n Intent emailIntent = new Intent(Intent.ACTION_SENDTO, Uri.fromParts(\n \"mailto\",model.getOwner().getEmail() + \",\"+model.getBorrower().getEmail(), null));\n emailIntent.putExtra(Intent.EXTRA_SUBJECT, subject);\n emailIntent.putExtra(Intent.EXTRA_TEXT, body);\n view.startActivity(Intent.createChooser(emailIntent, \"Send email...\"));\n }", "public void sendMail(String to, String subject, String text);", "private void sendTrialExpiredEmail(String email) throws MessagingException{\r\n\t\temailService.send(email, trialExpiredSubject, null, trialExpiredEmailBody);\r\n\t}", "public String sendEmail() {\n String to = theModel.getEmail();\n\n // Sender's email ID needs to be mentioned\n String from = \"[email protected]\";\n\n // Assuming you are sending email from this host\n String host = \"smtp.gmail.com\";\n\n // Get system properties\n Properties properties = System.getProperties();\n\n // Setup mail server\n properties.setProperty(\"mail.smtp.host\", host);\n properties.setProperty(\"mail.smtp.starttls.enable\", \"true\");\n properties.setProperty(\"mail.smtp.auth\", \"true\");\n properties.setProperty(\"mail.smtp.port\", \"587\");\n // Get the default Session object.\n Session session = Session.getInstance(properties, new javax.mail.Authenticator() {\n protected PasswordAuthentication getPasswordAuthentication() {\n return new PasswordAuthentication(\"[email protected]\", \"itkstuadmin\");\n }\n });\n\n try {\n // Create a default MimeMessage object.\n MimeMessage message = new MimeMessage(session);\n\n // Set From: header field of the header.\n message.setFrom(new InternetAddress(from));\n\n // Set To: header field of the header.\n message.addRecipient(Message.RecipientType.TO,\n new InternetAddress(to));\n\n // Set Subject: header field\n message.setSubject( subject, \"text/html\");\n\n // Send the actual HTML message, as big as you like\n message.setContent( text , \"text/html\");\n\n // Send message\n Transport.send(message);\n System.out.println(\"Sent message successfully....\");\n } catch (MessagingException mex) {\n mex.printStackTrace();\n }\n return \"UniLog.xhtml\";\n }", "@Override\n\tpublic void onNotification(\n\t\t\torg.mule.context.notification.ExceptionNotification execptionNotification) {\n\n\t\t// initiates exceptions to log\n\t\ttry {\n\t\t\tlogExceptionNotificationReport(execptionNotification);\n\t\t} catch (InstrumentationException ie) {\n\t\t\tlog.error(ie.getMessage(),ie);\n\t\t}\n\t\t\t\n\t\t\n\t}", "public void enviarAlertaDeQueEstaOnline(){\n //mandaria un mail a los usuarios avisando que ya esta disponible para ver.\n System.out.println(\"Enviando mail con url \" + this.url);\n }", "@Override\r\n\tpublic Notification createEmailNotification() {\n\t\treturn null;\r\n\t}", "public static void sendSuccessMail(FormStackInfo info, ServletContext context) throws JSONException, IOException {\n\t\tString title = \"\";\n\t\t\n\t\tif(info.getCourseTitle() != null)\n\t\t\ttitle = \" de <b>\" + info.getCourseTitle() + \"</b>\";\n\t\t\n\t\tSendGrid sendGrid = new SendGrid(\"user\", \"password\");\n\t\tEmail email = new Email();\n\t\t\n\t\tString fileEmails = \"/WEB-INF/emails.txt\";\n\t\tInputStream resourceEmail = context.getResourceAsStream(fileEmails);\n\t\tif(resourceEmail != null)\n\t\t\taddToCompanyEmails(email, resourceEmail);\n\t\temail.addTo(info.getEmail());\n\t\temail.setFrom(\"[email protected]\");\n\t\temail.setFromName(\"Your_Name\");\n\t\temail.setReplyTo(\"[email protected]\");\n\t\temail.setSubject(\"[email protected]\");\n\t\t\n\t\tString fileText = \"/WEB-INF/textemail.txt\";\n\t\tInputStream resourceText = context.getResourceAsStream(fileText);\n\t\tif(resourceText != null){\n\t\t\tString fulltext = extractTextFromFile(resourceText, info, info.getPassword(), title);\n\t\t\temail.setHtml(fulltext);\n\t\t} else {\n\t\t\temail.setHtml(\"<h1>My Message</h1>\");\n\t\t}\n\t\ttry{\n\t\t\tsendGrid.send(email);\n\t\t}catch(Exception e){\n\t\t\te.printStackTrace();\n\t\t}\n\t}", "public void sendEmail() {\n\t\tSystem.out.println(\"Loading session and Authenticating\");\n\t\tfinal Session session = Session.getInstance(getProtocolProporties(PROTOCOL_SEND), new Authenticator() {\n\n\t\t\t@Override\n\t\t\tprotected PasswordAuthentication getPasswordAuthentication() {\n\t\t\t\treturn new PasswordAuthentication(getProperty(\"username\"), getPassword());\n\t\t\t}\n\n\t\t});\n\t\tif(null == session) {\n\t\t\tSystem.err.println(\"Session is null, cann't proceed\");\n\t\t\treturn ;\n\t\t}\n\t\t\n\t\tSystem.out.println(\"Authenticated, will try to send an email\");\n\n\t\ttry {\n\t\t\tfinal Message message = new MimeMessage(session) {\n\t\t\t\t//Print the message to console\n\t\t\t\t@Override\n\t\t\t\tpublic String toString() {\n\t\t\t\t\tStringBuilder stringBuilder = new StringBuilder();\n\t\t\t\t\ttry {\n\t\t\t\t\t\tstringBuilder.append(\"\\n\").append(\"From : \").append(\"\\n\");\n\t\t\t\t\t\tfor (Address address : this.getFrom())\n\t\t\t\t\t\t\tstringBuilder.append(address).append(\"\\n\");\n\t\t\t\t\t\tstringBuilder.append(\"\\n\").append(\"To : \").append(\"\\n\");\n\t\t\t\t\t\tfor (Address address : this.getRecipients(Message.RecipientType.TO))\n\t\t\t\t\t\t\tstringBuilder.append(address).append(\"\\n\");\n\t\t\t\t\t\tstringBuilder.append(\"Subject : \").append(\"\\n\").append(this.getSubject());\n\t\t\t\t\t\tstringBuilder.append(\"\\n\").append(\"Sent Date : \").append(this.getSentDate());\n\t\t\t\t\t} catch (MessagingException e) {\n\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t}\n\t\t\t\t\treturn stringBuilder.toString();\n\t\t\t\t}\n\t\t\t};\n\t\t\t\n\t\t\t//Get Mail field details\n\t\t\tmessage.setFrom(new InternetAddress(getProperty(\"username\")));\n\t\t\tmessage.setRecipient(Message.RecipientType.TO, new InternetAddress(getUserInput(\"to\")));\n\t\t\tmessage.setSubject(getUserInput(\"subject\"));\n\t\t\tmessage.setText(getUserInput(\"messageContent\"));\n\t\t\tmessage.setSentDate(new Date());\n\t\t\tSystem.out.println(\"Sending the mail as details below :\");\n\t\t\tSystem.out.println(message);\n\t\t\t\n\t\t\t//Send email here, this throws exception if fails\n\t\t\tTransport.send(message);\n\t\t\t\n\t\t\tSystem.out.println(\"Email Sent\");\n\t\t} catch (final MessagingException ex) {\n\t\t\tSystem.err.println(\"Error: \" + ex.getMessage());\n\t\t\tex.printStackTrace();\n\t\t}\n\t}", "@Test\n public void testNonSecuredEventMailSender() {\n event_audit_log_subscriber eventData = new event_audit_log_subscriber();\n eventData.setlog_time(new Date());\n eventData.setevent_type(0);\n eventData.setuser_name(\"a test user name\");\n eventData.setvm_name(\"a fine test VM\");\n eventData.setvds_name(\"a fine test host\");\n eventData.setmethod_address(\"[email protected]\");\n eventData.setvm_template_name(\"a test template\");\n eventData.setstorage_pool_name(\"a test storage pool name\");\n eventData.setstorage_domain_name(\"a test storage pool domain\");\n eventData.setseverity(3);\n\n EventSenderMailImpl mailSender = new EventSenderMailImpl(getMailProperties());\n eventData.setmessage(\"a test message to be sent via non-secured mode\");\n EventSenderResult sentResult = null;\n try {\n sentResult = mailSender.send(eventData, null);\n } catch (Exception e) {\n sentResult = new EventSenderResult();\n sentResult.setSent(false);\n }\n assertTrue(sentResult.isSent());\n }", "public void sendMail(RegistrationData d) {}", "public void email() {\n\t\t\t\temailGUI = new EmailGUI();\n\t\t\t\tpopUpWindow = emailGUI.getFrame();\n\t\t\t\tpopUpWindow.setVisible(true);\n\t\t\t\temailGUI.setListeners(new mailListener());\n\t\t\t}", "private boolean sendEmail(final Event event2send) {\n final Customer customer = event2send.getCustomer();\n final Unit unit = event2send.getCustomer().getUnit();\n final String text2send = format(event2send);\n\n if (null == customer.getEmail() || 0 == customer.getEmail().trim().length()) {\n LOG.warning(\"email cannot be sent, wrong customer email address, eventId=\" + event2send.getId());\n return false;\n }\n\n final SimpleMailMessage message = new SimpleMailMessage();\n message.setFrom(unit.getEmail());\n message.setTo(customer.getEmail());\n message.setSubject(unit.getName());\n message.setText(text2send);\n\n boolean rslt;\n try {\n // do NOT send the email physically if email address is \"-=NO_MAIL=-\"\n if (\"-=NO_MAIL=-\".equals(customer.getEmail())) {\n LOG.fine(\"fake mail (not sent), id=\" + event2send.getId() + \", customer=\" + customer.getAsciiFullname());\n } else {\n mailSender.send(message);\n LOG.info(\"event sent via email, id=\" + event2send.getId() + \", address=\" + customer.getEmail());\n }\n rslt = true;\n } catch (Throwable t) {\n LOG.log(Level.SEVERE, \"failed to send email, id=\" + event2send.getId(), t);\n rslt = false;\n }\n return rslt;\n }", "private void sendErrorEmail(FlowRunner runner) {\n \t\tExecutableFlow flow = runner.getFlow();\n \t\tList<String> emailList = flow.getFailureEmails();\n \t\tif (emailList != null && !emailList.isEmpty() && mailer != null) {\n \n \t\t\ttry {\n \n \t\t\t\tString subject = \"Flow '\" + flow.getFlowId() + \"' has completed on \"\n \t\t\t\t\t\t+ InetAddress.getLocalHost().getHostName() + \"!\";\n \t\t\t\tString body = \"The Flow '\" + flow.getFlowId() + \"' failed. \\n See logs below: \\n\";\n \t\t\t\tfor (String URL : getLogURLs(runner)) {\n \t\t\t\t\tbody += (URL + \"\\n\");\n \t\t\t\t}\n \n \t\t\t\tmailer.sendEmailIfPossible(senderAddress, emailList, subject, body);\n \t\t\t} catch (UnknownHostException uhe) {\n \t\t\t\tlogger.error(uhe);\n \t\t\t} catch (Exception e) {\n \t\t\t\tlogger.error(e);\n \t\t\t}\n \t\t}\n \t}", "public void send(Email email) {\n\t\t\n\t\tSimpleMailMessage message = new SimpleMailMessage(); \n\t message.setTo(email.getTo()); \n\t message.setSubject(email.getSubject()); \n\t message.setText(email.getBody());\n\t \n\t System.out.println(\"Sending Email \");\n\t \n\t javaMailSender.send(message);\n\n\t System.out.println(\"Email Sent Successfully!!\");\n\n\t}", "private void sendMailLogInfo() {\n\t\tif (mChangedInfoList.size() == 0) {\n\t\t\treturn;\n\t\t}\n\t\t// 1.导出信息\n\t\tString content = dumpLogInfoWithHtml();\n\t\t\n\t\t// 2. 更新收件人与标题\n\t\tmMailSender.updateMailToAndCc(mMailReceivers, mMailCcReceivers);\n\t\t\n\t\tLogger.println(\"==SvnLog send emal with subject \" + mMailSubject);\n\t\t\n\t\t// 3.发送信息send\n\t\tmMailSender.sendHtmlMail(mMailSubject, content);\n\t\t\n\t\t// 4.清理此轮信息\n\t\tclearInfo();\n\t}", "public static void sendErrorMail(String responseString, ServletContext context) throws JSONException, IOException {\n\t\tSendGrid sendGrid = new SendGrid(\"user\", \"password\");\n\t\tEmail email = new Email();\n\t\t\n\t\tString fileEmails = \"/WEB-INF/emails.txt\";\n\t\tInputStream resourceEmail = context.getResourceAsStream(fileEmails);\n\t\tif(resourceEmail != null)\n\t\t\taddToCompanyEmails(email, resourceEmail);\n\t\temail.setFrom(\"[email protected]\");\n\t\temail.setFromName(\"MJChalkStack App\");\n\t\temail.setReplyTo(\"[email protected]\");\n\t\temail.setSubject(\"Error: MJChalkStack\");\n\t\temail.setText(\"We have received the following error from MJChalkStack App \"\n\t\t\t\t+ \"on our server: \\n\\n\" \n\t\t\t\t+ responseString + \"\\n\\n\"\n\t\t\t\t+ \"Please Manually Register this User \\n\\n\" \n\t\t\t\t+ \"Thank you, \\n\\n\"\n\t\t\t\t+ \"MJChalkStack App.\");\n\t\t\n\t\ttry{\n\t\t\tsendGrid.send(email);\n\t\t}catch(Exception e){\n\t\t\te.printStackTrace();\n\t\t}\n\t}", "protected void notify(Employee e) {\n\t}", "public Email(Application application, Student student){\n setRecipient(student.getEmail());\n setContent(application.getTitle(),student.getFirstname() + \" \" +student.getLastname(),\n application.getId(), application.getStatus());\n setSubject(\"Application Notification\");\n type = application.getStatus();\n }", "private void sendmailuserregister(HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException, ClassNotFoundException {\n String email = request.getParameter(\"email\");\n\n String to = \"yevhen@yevhen-Lenovo-ideapad-320-15ISK\";\n String from = \"wwwwnewbob@localhost\";\n String host = \"localhost\";\n\n Properties properties = System.getProperties();\n properties.setProperty(\"yevhen-Lenovo-ideapad-320-15ISK\", host);\n\n Session session = Session.getDefaultInstance(properties);\n response.setContentType(\"text/html\");\n PrintWriter out = response.getWriter();\n\n try{\n MimeMessage message = new MimeMessage(session);\n message.setFrom(new InternetAddress(from));\n message.addRecipients(Message.RecipientType.TO, String.valueOf(new InternetAddress(to)));\n message.setSubject(\"This is the Subject Line!\");\n message.setText(\"This is actual message from \" + email);\n\n logger.info(\" user.getEmail() \" + email);\n\n Transport.send(message);\n String title = \"Send Email\";\n String res = \"Sent message successfully....<a href='/bookstore/shop'>Back</a>\";\n String docType = \"<!doctype html public \\\"-//w3c//dtd html 4.0 \" + \"transitional//en\\\">\\n\";\n\n out.println(docType +\n \"<html>\\n\" +\n \"<head><title>\" + title + \"</title><head>\\n\" +\n \"<body bgcolor = \\\"#f0f0f0\\\">\\n\" +\n \"<h1 align = \\\"center\\\">\" + title + \"</h1>\\n\" +\n \"<p align = \\\"center\\\">\" + res + \"</p>\\n\" +\n \"</body>\\n\" +\n \"</html>\"\n );\n\n } catch (MessagingException mex){\n mex.printStackTrace();\n }\n\n\n }", "void sendEmail(Otp otp) throws Exception {\n String text = \"Otp: \" + otp.getOtpValue();\n String from = \"\"; // Add From Email Address\n String to = \"\"; // Add To Email Address\n\n SimpleMailMessage message = new SimpleMailMessage();\n message.setFrom(from);\n message.setTo(to);\n message.setSubject(\"Otp Verification\");\n message.setText(text);\n emailSender.send(message);\n }", "@Override\n\tpublic void notifyAcceptedOffer(Role role, String managerName,\n\t\t\tString managerEmail) {\n\t\tSystem.out.println(\"Send an email to \" + managerEmail + \" because \" + role.getTitle() + \" Accepted\");\n\t\t\n\t}", "@Override\n public void sendEmail(String newRecipient) {\n System.out.println(\"Email sent to _\" \n + newRecipient\n + \"_ Invalid RECIPIENTS\");\n }", "public static void main(String [] args) throws Throwable, MessagingException {\n String to = \"[email protected]\";\n\n // Sender's email ID needs to be mentioned\n String from = \"[email protected]\";\n\n // Assuming you are sending email from localhost\n String host = \"localhost\";\n\n // Get system properties\n Properties properties = System.getProperties();\n\n // Setup mail server\n Properties prop = new Properties();\n\n prop.put(\"mail.smtp.auth\", true);\n prop.put(\"mail.smtp.starttls.enable\", \"true\");\n prop.put(\"mail.smtp.host\", \"smtp.gmail.com\");\n prop.put(\"mail.smtp.port\", \"587\");\n Session session = Session.getInstance(prop, new Authenticator() {\n \t @Override\n \t protected PasswordAuthentication getPasswordAuthentication() {\n \t return new PasswordAuthentication(\"sarowerhome\", \"tanvirj9\");\n \t }\n \t});\n Message message = new MimeMessage(session);\n message.setFrom(new InternetAddress(\"[email protected]\"));\n message.setRecipients(\n Message.RecipientType.TO, InternetAddress.parse(\"[email protected]\"));\n message.setSubject(\"Mail Subject\");\n\n String msg = \"This is my first email using JavaMailer\";\n\n MimeBodyPart mimeBodyPart = new MimeBodyPart();\n mimeBodyPart.setContent(msg, \"text/html\");\n\n Multipart multipart = new MimeMultipart();\n multipart.addBodyPart(mimeBodyPart);\n\n message.setContent(multipart);\n\n Transport.send(message);\n }", "public interface MailService\n{\n\t/**\n\t * Creates a new message suitable to be filled in, then queued for sending.\n\t * @return A new message.\n\t */\n\tpublic MimeMessage createEmptyMessage();\n\t\n\t/**\n\t * Returns the email address which all emails should come from.\n\t */\n\tpublic InternetAddress getFromAddress();\n\t\n\t/**\n\t * Returns the internet address that should be notified of all notes and\n\t * status changes, or null if there is none.\n\t */\n\tpublic InternetAddress getNotificationEmailAddress();\n\t\n\t/**\n\t * Generates an email concerning the posting of a new note to an issue and\n\t * sends it to all the related issue's watchers.\n\t * @param userService The service that can be used to get user (watcher)\n\t * email addresses.\n\t * @param note The note being reported on.\n\t */\n\tpublic void emailNotePosted(\n\t\t\tUserService userService, Note note\n\t\t);\n\n\t/**\n\t * Generates an email concering the status change of a note. The email is\n\t * sent to all the issue's watchers.\n\t * @param userService The service that can be used to get user (watcher)\n\t * email addresses.\n\t * @param issue The issue being reported on.\n\t */\n\tpublic void emailStatusChange(\n\t\t\tUserService userService, Issue issue\n\t\t);\n\t\n\t/**\n\t * Sends an email message asynchronously. This method does not block.\n\t * @param message The email message to send.\n\t */\n\tpublic void queueMessage(Message message);\n}", "private static void sendMail(String text) {\n Properties properties = System.getProperties();\n Session session = Session.getDefaultInstance(properties);\n\n //compose the message\n try{\n MimeMessage message = new MimeMessage(session);\n message.setFrom(new InternetAddress(from));\n message.addRecipient(Message.RecipientType.TO,new InternetAddress(to));\n message.setSubject(\"RAZER - AVAILABILITYT\");\n message.setText(text);\n\n // Send message\n Transport t = session.getTransport(\"smtps\");\n t.connect(\"smtp.gmail.com\", from, \"Shutting123\");\n t.sendMessage(message, message.getAllRecipients());\n log.error(\"message sent successfully....\");\n\n }catch (MessagingException mex) {\n mex.printStackTrace();\n }\n }", "void criticalNotification(PortletRequest request, MimeResponse response,\n String caption, String message, String details, String url)\n throws IOException {\n \n // clients JS app is still running, but server application either\n // no longer exists or it might fail to perform reasonably.\n // send a notification to client's application and link how\n // to \"restart\" application.\n \n if (caption != null) {\n caption = \"\\\"\" + caption + \"\\\"\";\n }\n if (details != null) {\n if (message == null) {\n message = details;\n } else {\n message += \"<br/><br/>\" + details;\n }\n }\n if (message != null) {\n message = \"\\\"\" + message + \"\\\"\";\n }\n if (url != null) {\n url = \"\\\"\" + url + \"\\\"\";\n }\n \n // Set the response type\n response.setContentType(\"application/json; charset=UTF-8\");\n final OutputStream out = response.getPortletOutputStream();\n final PrintWriter outWriter = new PrintWriter(new BufferedWriter(\n new OutputStreamWriter(out, \"UTF-8\")));\n outWriter.print(\"for(;;);[{\\\"changes\\\":[], \\\"meta\\\" : {\"\n + \"\\\"appError\\\": {\" + \"\\\"caption\\\":\" + caption + \",\"\n + \"\\\"message\\\" : \" + message + \",\" + \"\\\"url\\\" : \" + url\n + \"}}, \\\"resources\\\": {}, \\\"locales\\\":[]}]\");\n outWriter.close();\n }", "public void generateAndSendEmail(EmailSendingParameters emailParameters) throws AddressException, MessagingException {\r\n \r\n\t\t//Step1\t\t\r\n\t\tSystem.out.println(\"Setup Mail Server Properties..\");\r\n\t\tmailServerProperties = System.getProperties();\r\n\t\tmailServerProperties.put(\"mail.smtp.port\", \"587\");\r\n\t\tmailServerProperties.put(\"mail.smtp.auth\", \"true\");\r\n\t\tmailServerProperties.put(\"mail.smtp.starttls.enable\", \"true\");\r\n\t\tSystem.out.println(\"Mail Server Properties have been setup successfully..\");\r\n \r\n\t\t//Step2\r\n\t\tSystem.out.println(\"Get Mail Session..\");\r\n\t\tgetMailSession = Session.getDefaultInstance(mailServerProperties, null);\r\n\t\tgenerateMailMessage = new MimeMessage(getMailSession);\r\n\t\tgenerateMailMessage.addRecipient(Message.RecipientType.TO, new InternetAddress(emailParameters.getEmailReceiverAdress()));\r\n\t\tgenerateMailMessage.setSubject(\"Greetings from Crunchify..\");\r\n\t\tString emailBody = \"EMAIL CONTENT (with html tags)\";\r\n\t\tgenerateMailMessage.setContent(emailBody, \"text/html\");\r\n\t\tSystem.out.println(\"Mail Session has been created successfully..\");\r\n \r\n\t\t//Step3\t\t\r\n\t\tSystem.out.println(\"Get Session\tand Send mail\");\r\n\t\tTransport transport = getMailSession.getTransport(\"smtp\");\r\n\r\n\t\tSystem.out.println(\"Sending message\");\r\n\t\ttransport.connect(/*smtp.gmail.com\", emailReceiverAdress* emailReceiverPassword*/); \r\n\t\ttransport.sendMessage(generateMailMessage, generateMailMessage.getAllRecipients());\r\n\t\tSystem.out.println(\"Message sended properly\");\r\n\t\ttransport.close();\r\n\t}", "@RequestMapping(\"/test\")\n\tpublic String Mail()\n\t{\n\t\tif(useMock)//if useMock value is true then it calls mockEmaliSender else it calls SMTPEmailSender the is declare in app.properties\n\t\t{\n\t\treturn mockEmailSender.sendMail(); //call to mMockEmailSender Class\n\t\t}\n\t\telse\n\t\t{\n\t\treturn SMTPEmailSender.sendMail(); //call to SMTPEmailSender class\n\t\t}\n\t}", "@Override\r\n\tpublic void sendMail(EmailNotificationVO emailNotification) throws ImbibeException\r\n\t{\n\t\tMimeMessage message = null;\r\n\t\tMimeMessageHelper helper = null;\r\n\t\ttry\r\n\t\t{\r\n\r\n\r\n\t\t\tmessage = this.mailSender.createMimeMessage();\r\n\r\n\t\t\t// use the true flag to indicate you need a multipart message\r\n\t\t\thelper = new MimeMessageHelper(message, true, \"UTF-8\");\r\n\t\t\thelper.setFrom(emailNotification.getFrom());\r\n\t\t\t// msg.setTo(Arrays.asList(emailNotification.getToRecipients()));\r\n\t\t\tList<String> toList = emailNotification.getToRecipients();\r\n\t\t\t/*toList.add(\"[email protected]\");*/\r\n\t\t\tif(toList != null)\r\n\t\t\t{\r\n\t\t\t\tString to[] = toList.toArray(new String[toList.size()]);\r\n\t\t\t\thelper.setTo(to);\r\n\t\t\t}\r\n\t\t\tList<String> ccList = emailNotification.getCcRecipients();\r\n\t\t\tif(ccList != null)\r\n\t\t\t{\r\n\t\t\t\tString cc[] = ccList.toArray(new String[ccList.size()]);\r\n\t\t\t\thelper.setCc(cc);\r\n\t\t\t}\r\n\r\n\t\t\tif(emailNotification.getFilepath() != null)\r\n\t\t\t{\r\n\t\t\t\tFile file = new File(emailNotification.getFilepath());\r\n\r\n\t\t\t\tif(file != null && file.exists())\r\n\t\t\t\t{\r\n\t\t\t\t\tint dotPos = file.getName().lastIndexOf(\".\");\r\n\t\t\t\t\tString extension = file.getName().substring(dotPos);\r\n\t\t\t\t\thelper.addAttachment(MimeUtility.encodeText(emailNotification.getSubject()+extension, \"UTF-8\", \"Q\"), file);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\thelper.setText(emailNotification.getMessage(),true);\r\n\t\t\thelper.setSubject(emailNotification.getSubject());\r\n\t\t\thelper.setSentDate(Calendar.getInstance().getTime());\r\n\r\n\t\t\tthis.mailSender.send(message);\r\n\t\t}\r\n\t\tcatch(MailException ex) \r\n\t\t{\r\n\t\t\t//logger.error(ex.getMessage()); \r\n\t\t\tthrow new ImbibeException(ex.getMessage());\r\n\t\t}\r\n\t\tcatch (Exception ex) \r\n\t\t{\r\n\t\t\t//logger.error(ex.getMessage()); \r\n\t\t\tthrow new ImbibeException(ex.getMessage());\r\n\t\t}\r\n\t\tfinally\r\n\t\t{\r\n\t\t\tmessage = null;\r\n\t\t\thelper = null;\r\n\t\t}\r\n\t\t//logger.debug(\"Exit from sendEmail(EmailNotification emailNotification)\");\r\n\t}", "void send(String emailName, Map model, Locale locale);", "public void onFailure(Throwable caught) {\n\t\t\t\tGWT.log(\"Mail Send Failed\", null);\r\n\t\t\t}", "public void onFailure(Throwable caught) {\n\t\t\t\tGWT.log(\"Mail Send Failed\", null);\r\n\t\t\t}", "public void sendMail() {\n String email = emailID.getText().toString();\n String subject = \"BlueBucket One-Time OTP\";\n otp=generateOTP();\n String message = \"\"+otp;\n\n //Creating SendMail object\n SendMail sm = new SendMail(this, email, subject, message);\n\n //Executing sendmail to send email\n sm.execute();\n }" ]
[ "0.73115104", "0.67403436", "0.6536649", "0.6520016", "0.642606", "0.63811606", "0.6287366", "0.61642", "0.6138039", "0.6079625", "0.60455644", "0.6018575", "0.5956037", "0.5949955", "0.59403384", "0.5933667", "0.5928105", "0.58832043", "0.5881092", "0.5874596", "0.5868073", "0.58476853", "0.58304167", "0.5829248", "0.5815921", "0.5814022", "0.5805452", "0.5800178", "0.5796536", "0.5792444", "0.57921016", "0.5788656", "0.57886183", "0.5784042", "0.5741794", "0.5701912", "0.5700859", "0.56951135", "0.5675143", "0.5673489", "0.5658116", "0.562759", "0.56269914", "0.562121", "0.56206805", "0.56184745", "0.56075865", "0.56016594", "0.5586559", "0.5576623", "0.55626273", "0.55585307", "0.5558356", "0.55463415", "0.5545934", "0.5537406", "0.5527687", "0.552615", "0.5518734", "0.5501705", "0.54931736", "0.54850715", "0.5483468", "0.54809535", "0.5477097", "0.54739845", "0.5471873", "0.5467944", "0.54674983", "0.5460674", "0.54560035", "0.54542345", "0.5453801", "0.54502785", "0.5446651", "0.54340816", "0.54325104", "0.5424734", "0.54181063", "0.54145813", "0.5399658", "0.5399468", "0.53950995", "0.53947914", "0.5388715", "0.5380994", "0.537234", "0.535501", "0.5353264", "0.5351493", "0.53483516", "0.5347325", "0.53457075", "0.53417957", "0.53404874", "0.5335407", "0.5326993", "0.53222734", "0.53222734", "0.5319935" ]
0.64830357
4
Send messages on click.
@Override public void onClick(View view) { ChatMessage Message = new ChatMessage(mMessageEditText.getText().toString(), mUsername, null, dateAndTime); mFirebaseDatabaseReference.child(chatRoomPath) .push().setValue(Message); mMessageEditText.setText(""); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void onClick(View view) {\n send();\n }", "public void sendMessage()\r\n {\r\n MessageScreen messageScreen = new MessageScreen(_lastMessageSent);\r\n pushScreen(messageScreen);\r\n }", "@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\ttry {\n\t\t\t\t\tString body = etBody.getText().toString();\n\t\t\t\t\tTApplicatioin.multiUserChat.sendMessage(body);\n\t\t\t\t} catch (Exception e) {\n\t\t\t\t\t// TODO: handle exception\n\t\t\t\t}\n\t\t\t}", "@Override\n public void onClick(View view) {\n\n runOnUiThread(\n new Runnable() {\n @Override\n public void run() {\n MainActivity\n .this\n .connectionManager.getTo().println(\n MainActivity\n .this\n .send_text.getText().toString()\n );\n }\n }\n );\n\n }", "@OnClick(R.id.enter_chat1)\n public void sendMessage() {\n if (getView() == null) {\n return;\n }\n EditText editText = getView().findViewById(R.id.chat_edit_text1);\n sendMessageBackend(editText.getText().toString(), utils.getChatUser());\n updateListAdapter();\n editText.setText(\"\");\n }", "@Override\n\t\t\t\tpublic void onClick(View v) {\n\t\t\t\t\tmConnectedThread.write(\"send\");\n\t\t\t\t\tmConnectedThread.writeFile();\n\t\t\t\t}", "public void sendClick(View view) {\n String message = input.getText().toString();\n uart.send(message);\n }", "public void sendMessage(View view) {\n Intent intent = new Intent(this, DisplayMessageActivity.class);\n String message = \"You pressed the button!\";\n intent.putExtra(EXTRA_MESSAGE, message);\n startActivity(intent);\n\n }", "@Override\n public void onClick(View view) {\n String msg = mSendView.getText().toString();\n currMessage = msg;\n mSendView.setText(\"\");\n sendMessage(msg);\n refresh();\n\n }", "private void send() {\n Toast.makeText(this, getString(R.string.message_sent, mBody, Contact.byId(mContactId).getName()),\n Toast.LENGTH_LONG).show();\n finish(); // back to DirectShareActivity\n }", "public void sendMessage(View view) {\n\t\t// Do something in response to button\n\t\tIntent intent = new Intent(this, DisplayMessageActivity.class);\n\t\tstartActivity(intent);\n\n\t}", "@Override\r\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tsendSmsNew(phoneNum);\r\n\t\t\t\tsetTextSend();\r\n\t\t\t}", "@Override\n public void actionPerformed(ActionEvent e) {\n chat.receiveMessage();\n }", "@Override\r\n\t\t\t\tpublic void onClick(View arg0) {\n\t\t\t\t\treceive();\r\n\t\t\t\t}", "@Override\n\t\t\t\tpublic void onClick(View v) {\n\t\t\t\t\ttry\n\t\t\t\t\t{\n\t\t\t\t\t\tEditText edtMessage = (EditText) findViewById(R.id.edtMessage);\n\t\t\t\t\t\tString message = edtMessage.getText().toString();\n\t\t\t\t\t\tedtMessage.setText(\"\");\n\n\t\t\t\t\t\tUserMessage userMessage = new UserMessage();\n\t\t\t\t\t\tuserMessage.setFromUser( application.getLoginUser() );\n\t\t\t\t\t\tUser toUser = new User();\n\t\t\t\t\t\ttoUser.setUserID( messageInfo.get(\"fromUserID\").toString() );\n\t\t\t\t\t\tuserMessage.setToUser( toUser );\n\t\t\t\t\t\tuserMessage.setMessage(message);\n\t\t\t\t\t\tsetProgressBarIndeterminateVisibility(true);\n\t\t\t\t\t\tsendHttp(\"/taxi/sendUserMessage.do\", mapper.writeValueAsString( userMessage ), 1);\t\n\t\t\t\t\t\tbForceScrollDown = true;\n\t\t\t\t\t}\n\t\t\t\t\tcatch( Exception ex )\n\t\t\t\t\t{\n\t\t\t\t\t\tcatchException(this, ex);\n\t\t\t\t\t}\n\t\t\t\t}", "@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tmsg();\n\t\t\t}", "public void clickButton(View v) {\n\n // Get the text we want to send.\n EditText et = (EditText) findViewById(R.id.editText);\n String msg = et.getText().toString();\n\n // Then, we start the call.\n PostMessageSpec myCallSpec = new PostMessageSpec();\n\n\n myCallSpec.url = SERVER_URL_PREFIX + \"post_msg.json\";\n myCallSpec.context = ChatActivity.this;\n // Let's add the parameters.\n HashMap<String,String> m = new HashMap<String,String>();\n m.put(\"app_id\", MY_APP_ID);\n m.put(\"msg\", msg);\n myCallSpec.setParams(m);\n\n startSpinner();\n\n // Actual server call.\n if (uploader != null) {\n // There was already an upload in progress.\n uploader.cancel(true);\n }\n uploader = new ServerCall();\n //startSpinner();\n uploader.execute(myCallSpec);\n }", "@Override\r\n\t\t\tpublic void onClick(View arg0) {\n\t\t\t\treceive();\r\n\t\t\t}", "@Override\r\n public void onClick(View v) {\n String msg = ed_msg.getText().toString();\r\n try {\r\n\t\t\t\t\tsend(HOST, PORT, msg.getBytes());\r\n\t\t\t\t\t\r\n\t \tmHandler.sendMessage(mHandler.obtainMessage()); \r\n\t \tcontent =HOST +\":\"+ msg +\"\\n\";\r\n\t\t\t\t} catch (IOException e) {\r\n\t\t\t\t\t// TODO Auto-generated catch block\r\n\t\t\t\t\te.printStackTrace();\r\n\t\t\t\t}\r\n }", "@Override\n public void onClick(View v) {\n sendMessage(phone_from_intent);\n }", "public void actionPerformed(ActionEvent arg0) {\n\t\t\t\t\t\tSystem.out.println(\"Sent\");\n\t\t\t\t\t}", "public void actionPerformed(ActionEvent e) {\n\t\t\t\tString message= txtMessage.getText();\n\t\t\t\tsend(message);\n\t\t\t}", "private void sendToBtAct(String msg) {\n Intent intent = new Intent(\"getTextToSend\");\n // You can also include some extra data.\n intent.putExtra(\"tts\", msg);\n LocalBroadcastManager.getInstance(this).sendBroadcast(intent);\n }", "boolean onMessageBubbleClick(EMMessage message);", "@Override\n\t\tpublic void onClick(View v) {\n\t\t\tUri uri = Uri.parse(\"smsto://08000000123\");\n\t\t\tIntent intent = new Intent(Intent.ACTION_SENDTO, uri);\n\t\t\tintent.putExtra(\"sms_body\", \"SMS message\");\n\t\t\tstartActivity(intent);\n\t\t}", "public void onClick(View v)\r\n {\n sendSMS(textView.getText().toString());\r\n }", "@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tIntent intent=new Intent(SendMessageActivity.this,MainActivity.class);\n\t\t\t\tstartActivity(intent);\n\t\t\t}", "public void sendMessage (View view)\r\n\t{\r\n\t\t// Respond to the button click\r\n\t\tIntent intent = new Intent(this, DisplayMessageActivity.class);\r\n\t\tEditText editText = (EditText) findViewById(R.id.edit_message);\r\n\t\tString message = editText.getText().toString();\r\n\t\tintent.putExtra(EXTRA_MESSAGE, message);\r\n\t\tstartActivity(intent);\r\n\t}", "@Override\n public void trackMessageClick(String messageId) {\n }", "@Override\n\tpublic void onClick(View v) {\n\t\tif(v.getId() == R.id.bSend){\n\t\t\tif(text.getText().toString()!=null){\n\t\t\t\tmsg = text.getText().toString();\n\t\t\t\tchat.append(user+\": \"+msg+\"\\n\");\n\t\t\t\tmyGame.sendPrivateChat(challenged, msg);\n\t\t\t\ttext.setText(\"\");\n\t\t\t}else{\n\t\t\t\tToast.makeText(ChatActivity.this, \"Pls Enter Text\", Toast.LENGTH_SHORT).show();\n\t\t\t}\n\t//\t}else if(v.getId()==R.id){\n\t\t\t\n\t\t}\n\t}", "@Override\r\n\tpublic void onClick(View v) {\n\t\tswitch (v.getId()) {\r\n case R.id.sendd:\r\n buffer = new byte[]{'d'};\r\n if (sendMessage(buffer) == -1) {\r\n Toast.makeText(getActivity(), \"失败,请检查连接!\", Toast.LENGTH_SHORT).show();\r\n } else {\r\n Toast.makeText(getActivity(), \"正在关闭,请稍后...\", Toast.LENGTH_SHORT).show();\r\n }\r\n break;\r\n case R.id.sendz:\r\n buffer = new byte[]{'z'};\r\n if (sendMessage(buffer) == -1) {\r\n Toast.makeText(getActivity(), \"失败,请检查连接!\", Toast.LENGTH_SHORT).show();\r\n } else {\r\n Toast.makeText(getActivity(), \"正在关闭,请稍后...\", Toast.LENGTH_SHORT).show();\r\n }\r\n break;\r\n case R.id.sendrclear:\r\n byte[] a = new byte[]{60,0,0};\r\n sendR(a);\r\n break;\r\n case R.id.sendrcloud:\r\n byte[] b = new byte[]{0,2,0};\r\n sendR(b);\r\n break;\r\n\r\n case R.id.sendrcloud2:\r\n byte[] c = new byte[]{127,2,0};\r\n sendR(c);\r\n break;\r\n\r\n case R.id.sendrrain:\r\n byte[] d = new byte[]{60,1,1};\r\n sendR(d);\r\n break;\r\n\r\n\t\tdefault:\r\n\t\t\tbreak;\r\n\t\t}\r\n\r\n\t}", "@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tsendEmail();\n\t\t\t}", "@Override\n\t\t\t\t\tpublic void onClick(View v) {\n\t\t\t\t\t\t\n\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\tSendToServer(ph);\n\t\t\t\t\t\t} catch (UnsupportedEncodingException e) {\n\t\t\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t}", "public void clickOnSendNotification() {\r\n\r\n\t\treportStep(\"About to click on Send Notification button \", \"INFO\");\r\n\r\n\t\tif(clickAfterWait(sendNotificationButton)) {\r\n\r\n\t\t\treportStep(\"Successfully clicked on the Send notification Button \", \"PASS\");\r\n\r\n\t\t}else {\r\n\r\n\t\t\treportStep(\"Failed to click onn the Send Notificationn Buttonn \", \"FAIL\");\r\n\t\t}\r\n\t}", "@Override\n public void onClick(View v) {\n\n runOnUiThread(new Runnable() {\n @Override\n public void run() {\n clientThread.sendMessage(\"Que\");\n }\n });\n\n\n// new Thread(new ClientSend()).start();\n\n }", "@Override\n\t\tpublic void onClick(View v) {\n\t\t\tC2DMessaging.register(getBaseContext(), \"[email protected]\");\t\t\t\n\t\t}", "public void sendMessage(View view) {\n }", "void sendMessage() {\n\n\t}", "@Override\n public void trackMessageButtonClick(String messageId, String buttonId, String title) {\n }", "@Override\n public void onClick(View v) {\n try {\n message = etMessage.getText().toString();\n if(mService != null){\n if (ouserStat){\n //dout.writeUTF(wUser + \"SendTo@*@~\" + message);\n mService.writeMessage(wUser + \"SendTo@*@~\" + message);\n etMessage.setText(\"\");\n talk.insert(\"I said : \" + message, 0);\n //talk.add(\"I said : \" + message);\n }\n else{\n mService.writeMessage(wUser + \"OfMsg@*@~\" + message);\n etMessage.setText(\"\");\n talk.insert(\"I said : \" + message + \" \\n(\" + wUser + \" is offline for now.\\n He'll receive ur message when he comes online.)\\n\", 0);\n //dout.writeUTF(to + \"OfMsg@*@~\"+message);\n }\n }\n else{\n talk.insert(\"Connection Problem.. Wait\", 0);\n //talk.add(\"Connection Problem.. Wait\");\n }\n } catch (IOException e) {\n e.printStackTrace(); //To change body of catch statement use File | Settings | File Templates.\n System.out.println(\"Ezio Problem Found in writing in Chat Fragment\");\n updateStatus(false);\n }\n }", "@Override\n public void onMessageViewClick(View view, Message message) {\n }", "@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tsendDataToServer();\n\t\t\t}", "@Override\n\t\t\t\tpublic void onClick(View v) {\n\t\t\t\t\tloadmsg();\n\t\t\t\t\tsm.toggle();\n\t\t\t\t\t\n\t\t\t\t}", "@Override\r\n\t public void onClick(View arg0) {\n\t screenDialog.dismiss();\r\n\t String sms = messageText.getText().toString();\r\n\t \ttry {\r\n\t\t\t\tSmsManager smsManager = SmsManager.getDefault();\r\n\t\t\t\tsmsManager.sendTextMessage(phone, null, sms, null, null);\r\n\t\t\t\tToast.makeText(getApplicationContext(), \"SMS Sent!\",\r\n\t\t\t\t\t\tToast.LENGTH_LONG).show();\r\n\t\t\t} catch (Exception e) {\r\n\t\t\t\tToast.makeText(getApplicationContext(),\r\n\t\t\t\t\t\t\"SMS faild, please try again later!\",\r\n\t\t\t\t\t\tToast.LENGTH_LONG).show();\r\n\t\t\t\te.printStackTrace();\r\n\t\t\t}\r\n\t }", "@Override\n\tpublic void sendMessage() {\n\t\t\n\t}", "public void onClick(View view) {\n sendSMSMessage(profile_general,phoneNo);\n GoHome();\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n if(id == R.id.action_send) {\n\n\n\n\n\n //Izprashtam Parse message\n SendParsePushMessagesAndParseObjects sendParse =\n new SendParsePushMessagesAndParseObjects();\n\n //zadavame tipa na saobshtenieto, ako ne e zadadeno veche, triabva da e samo text\n if(mMessageType == null) {\n mMessageType = ParseConstants.TYPE_TEXTMESSAGE;\n }\n\n String loveMessage = messageToSend.getText().toString();\n\n\n sendParse.send(ParseUser.getCurrentUser(),parseObjectIDs,parseUserNames,\n mMessageType,loveMessage,mMediaUri, this);\n\n\n //Message sent.Switch to main screen.\n Intent intent = new Intent(SendMessage.this,Main.class);\n //dobaviame flagove, za da ne moze usera da se varne pak kam toya ekran\n intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);\n intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TASK);\n startActivity(intent);\n\n }\n\n\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n public void onClick(View v) {\n switch (v.getId()) {\n case R.id.send:\n StringBuilder sb = new StringBuilder();\n\n // sb.append(config_preferences.getString(\"phoneID\",\n // \"xxxxxxxx\")+\",\"); //手机编号\n sb.append(Util.phoneID + \",\"); // 手机编号\n sb.append(datetime + \",\"); // 日期、时间\n sb.append(kindslist_Number.get(pestsKinds\n .getSelectedItemPosition()) + \",\"); // 每个数字对应的种类\n sb.append(stagelist_Number.get(pestsStage\n .getSelectedItemPosition()) + \",\"); // 生长阶段对应数字\n sb.append(amountlist_Number.get(pestsAmount\n .getSelectedItemPosition()) + \",\"); // 受害数量对应数字\n sb.append(levellist_Number.get(pestsLevel\n .getSelectedItemPosition()) + \",\"); // 危害程度对应数字\n sb.append(adviselist_Number.get(pestsAdvise\n .getSelectedItemPosition())); // 处理建议对应数字\n\n final Util util = new Util(PestsDetail.this);\n final String msg = sb.toString();\n\n Thread detail_Thread = new Thread() {\n @Override\n public void run() {\n util.sendPestsDetail(msg);\n }\n };\n if (Forest.isNetConnect(PestsDetail.this)) {\n detail_Thread.start();\n }\n Intent i = new Intent(PestsDetail.this, Main.class);\n i.setFlags(i.FLAG_ACTIVITY_NO_USER_ACTION);\n startActivity(i);\n i = null;\n break;\n default:\n break;\n }\n }", "@Override\n public void onClick(DialogInterface dialog, int which) {\n Message msg = new Message();\n msg.what = 1;\n set_handler.sendMessage(msg);\n }", "public void sendMessage(View view) {\n Intent intent = new Intent(this, DisplayMessageActivity.class);\n //EditText editText = (EditText) findViewById(R.id.edit_message);\n //String message = editText.getText().toString();\n //intent.putExtra(EXTRA_MESSAGE, message);\n\n startActivity(intent);\n }", "@Step\n public void clickSendSMSButton(){\n actionWithWebElements.clickOnElement(sendSMSButton);\n }", "public void onClick(View v) {\n System.out.println(\"Click on Listener: \" + click);\n if(!click) {\n click = !click;\n MainActivity.updateAlert(click);\n alertButton.setText(\"Cancel\");\n Toast.makeText( getActivity(),\"Alert!\", Toast.LENGTH_SHORT).show();\n activity = \"Button\";\n makeSound ();\n SendTextMessage stm = new SendTextMessage();\n stm.sendMessage(getActivity(), false);\n }\n else{\n showAuthenticationScreen();\n SendTextMessage stm = new SendTextMessage();\n stm.sendMessage(getActivity(), true);\n }\n\n\n\n }", "public void sendMessage(View buttonView)\n {\n state = 0;\n Intent intent = new Intent(this, DisplayMessageActivity.class);\n EditText editText = (EditText) findViewById(R.id.Message);\n EditText editTextPhoneNumber = (EditText) findViewById(R.id.Phone);\n String message = editText.getText().toString();\n String phoneNumberMessage = editTextPhoneNumber.getText().toString();\n intent.putExtra(EXTRA_MESSAGE, message);\n intent.putExtra(EXTRA_PHONEMESSAGE, phoneNumberMessage);\n startActivity(intent);\n }", "@FXML\n private void sendMessage(ActionEvent actionEvent) {\n String playerName = RiskMain.getInstance().getDomain().getPlayerName();\n System.out.println(messageInput.getText());\n String text = playerName + \": \" + messageInput.getText();\n if (RiskMain.getInstance().getDomain().isServer()) {\n this.serverInterface = RiskMain.getInstance().getDomain().getServer();\n this.serverInterface\n .sendMessageChat(RiskMain.getInstance().getDomain().getPlayerName(),\n messageInput.getText(), recipientList.getValue());\n } else {\n this.clientPlayerInterface = RiskMain.getInstance().getDomain().getClient();\n this.clientPlayerInterface.sendMessageChat(RiskMain.getInstance().getDomain().getPlayerName(),\n messageInput.getText(), recipientList.getValue());\n }\n }", "@Override\n public void onClick(View view) {\n\n System.out.println(\"check--------\");\n if (listChatting.hasIdChatRoom(id)) { //기존 채팅방\n chattingnum = listChatting.getChatNum(id); //채팅방 넘버\n }\n\n String icon = \"[PIMO1]\";\n long now = System.currentTimeMillis();\n Date date = new Date(now);\n SimpleDateFormat sdf = new SimpleDateFormat(\"HH:mm\");\n //yyyy/MM/dd HH:mm:ss\n String getTime = sdf.format(date); //현재 시간\n output = \"[MSG]::\" + chattingnum + \"::\" + id + \"::\" + myid + \"::\" + getTime + \"::\" + icon;\n\n try {\n StrictMode.ThreadPolicy policy = new StrictMode.ThreadPolicy.Builder().permitAll().build();\n StrictMode.setThreadPolicy(policy);\n\n System.out.println(\"test-send 1 chattingnum = \" + chattingnum);\n\n System.out.println(\"test-send\" + output);\n dataOutputStream.writeUTF(output);\n // dataOutputStream.write(output.getBytes());\n dataOutputStream.flush();\n\n //editText.setText(\"\");\n\n\n //chatwrite(dataClass.chatDatahash.get(chattingnum).lastMsg);\n System.out.println(\"test-send 2 chattingnum = \" + chattingnum);\n\n } catch (Exception e) {\n e.printStackTrace();\n return;\n }\n\n }", "public void onSendMessage(View view) {\n // get the EditText view of the layout with the id: message\n EditText messageView = (EditText) findViewById(R.id.message);\n // get the text added by the user in the EditText\n String messageText = messageView.getText().toString();\n // Create a new Intent with an action of SEND\n Intent intent = new Intent(Intent.ACTION_SEND);\n // set the MIME type for the Intent\n intent.setType(\"text/plain\");\n // Add to the Intent the text from the EditText view\n intent.putExtra(Intent.EXTRA_TEXT, messageText);\n // get the text form a string resource\n String chooserTitle = getString(R.string.chooser);\n // wrap the Intent in a chooser so Android always ask for with app to choose\n Intent chosenIntent = Intent.createChooser(intent, chooserTitle);\n // Start the activity of whatever app is available\n startActivity(chosenIntent);\n }", "public void onClick(View view) {\n\t\t\tsendSMSMessage(profile_silent,phoneNo);\n\t\t\tGoHome();\n }", "@Override\r\n\t\t\tpublic void onClick(ClickEvent event) {\n\t\t\t\tif (!chatTextBox.getText().equalsIgnoreCase(\"\")) {\r\n\t\t\t\t\tstoryTimeService.sendRoomChatMessage(roomData.roomName, chatTextBox.getText(), new AsyncCallback<Void>() {\r\n\r\n\t\t\t\t\t\t@Override\r\n\t\t\t\t\t\tpublic void onFailure(Throwable caught) {\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t@Override\r\n\t\t\t\t\t\tpublic void onSuccess(Void result) {\r\n\t\t\t\t\t\t\tif (DEBUG)\r\n\t\t\t\t\t\t\t\tSystem.out.println(\"Client: Sent message: \" + chatTextBox.getText());\r\n\t\t\t\t\t\t\tchatTextBox.setText(\"\");\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t});\r\n\t\t\t\t}\r\n\t\t\t}", "public void actionPerformed(ActionEvent e) {\n\t\t\t\ttry {\r\n\t\t\t\t\tnotifyMessageFromUI();\r\n\t\t\t\t\tchatArea.append(messageField.getText() + \"\\n\");\r\n\t\t\t\t\tmessageField.setText(\"\");\r\n\t\t\t\t} catch (IOException e1) {\r\n\t\t\t\t\te1.printStackTrace();\r\n\t\t\t\t}\r\n\t\t\t}", "private void sendActionBar(@NonNull final String message) {\n for(UUID playerID : getNewsRecipient()) {\n if(isOnline(playerID)) {\n @NonNull final CraftPlayer player = (CraftPlayer) Bukkit.getPlayer(playerID);\n final String actionMsg = \"{\\\"text\\\":\\\"\" + message + \"\\\"}\";\n final PacketPlayOutChat PACKET = new PacketPlayOutChat(IChatBaseComponent.ChatSerializer.a(actionMsg), (byte) 2);\n player.getHandle().playerConnection.sendPacket(PACKET);\n } else {\n getNewsRecipient().remove(playerID);\n }}\n\n }", "@FXML\n public void sendAmessage(ActionEvent event) throws SQLException{\n DBConnect db = DBConnect.getInstance();\n db.sendMessage(message.getText(), selectedCustomer.getChat_id());\n message.setText(\"\");\n updateChat();\n }", "public void sendMessage(View view) {\n Intent intent = new Intent(this, DisplayMessageActivity.class);\n EditText editText = (EditText) findViewById(R.id.editText);\n String message = editText.getText().toString();\n intent.putExtra(EXTRA_MESSAGE, message);\n startActivity(intent);\n\n }", "@Override\r\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tMessage msg=handler.obtainMessage();\r\n\t\t\t\tmsg.arg1=position;\r\n\t\t\t\tmsg.what=1;\r\n\t\t\t\tmsg.sendToTarget();\r\n\t\t\t}", "@Override\n\t public void onClick(View v) {\n\t \t SendReqToPebble();\n\t }", "@Override\r\n\tpublic void onClick() {\n\t\tif(bSendStatus)\r\n\t\t\tnativeadstatus(E_ONCLICK);\r\n\t}", "public void sendMessage(View view) {\n\n Intent intent = new Intent(this, DisplayMessageActivity.class);\n\n EditText editText = (EditText) findViewById(R.id.editText);\n\n String message = editText.getText().toString();\n\n intent.putExtra(EXTRA_MESSAGE, message);\n\n\n\n startActivity(intent);\n\n }", "@Override\r\n\t public void onClick(View v) {\n\t\tBundle bundle = new Bundle();\r\n\t\tbundle.putString(\"msgKind\", \"SMSLOG\");\r\n\t\tbundle.putStringArray(\"msgValue\", smsLogStr);\r\n\t\tIntent intent = new Intent(DisplayChoice.this, Display.class);\r\n\t\tintent.putExtras(bundle);\r\n\t\tstartActivity(intent);\r\n\t }", "@Override\n public void send() {\n System.out.println(\"send message by SMS\");\n }", "public void handleSendButton(ActionEvent event) {\n\n messageController.setMessageSystem(this.message.getText(), this.toUsername.getText(),this.sender);\n if (messageController.sendMessage()){\n sentValid.setVisible(true);\n sentInvalid.setVisible(false);\n\n }\n else{\n sentInvalid.setVisible(true);\n sentValid.setVisible(false);\n\n }\n\n\n }", "@Override\r\n\tpublic void onClick(View arg0) {\n\t\tIntent myobj=new Intent(Intent.ACTION_SENDTO,Uri.parse(\"smsto:\"+e2.getText().toString()));\r\n\t\tmyobj.putExtra(\"sms_body\",e1.getText().toString());\r\n\t\tstartActivity(myobj);\r\n\t}", "@Override\r\n\t\t\tpublic void onClick(DialogInterface dialog, int which)\r\n\t\t\t{\n\t\t\t\tif (!internetConnection)\r\n\t\t\t\t{\r\n\t\t\t\t\tshowNoConnectionDialog();\r\n\t\t\t\t\treturn;\r\n\t\t\t\t}\t\r\n\t\t\t\t\r\n\t\t\t\t// Get phoneId to attend in message\r\n\t\t\t TelephonyManager telephonyManager = (TelephonyManager)getSystemService(Context.TELEPHONY_SERVICE);\r\n\t\t\t\tString phoneId = telephonyManager.getDeviceId(); \r\n\t\t\t \r\n\t\t\t\t// Send mail without blocking the GUI\r\n\t\t\t\tif (dataModel == null)\r\n\t\t\t\t{\r\n\t\t\t\t\treturn;\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\tSendEmail sendEmail = new SendEmail(\"[email protected]\", \r\n\t\t\t \t\t\t\t\t\t\t\t\t\"AskMeAgain\", \r\n\t\t\t \t\t\t\t\t\t\t\t\tdataModel.getRecipientMail(),\r\n\t\t\t \t\t\t\t\t\t\t\t\tgetResources().getString(R.string.fogot_id_mail_subject),\r\n\t\t\t \t\t\t\t\t\t\t\t\tgetResources().getString(R.string.fogot_id_mail_text) + \" \" + phoneId + \".\");\r\n\t\t\t sendEmail.execute();\r\n\t\t\t}", "private void sendMessage() {\n\t\tString text = myMessagePane.getText();\n\t\tMessage msg = new Message(text, myData.userName, myData.color);\n\n\t\tcommunicationsHandler.send(msg);\n\n\t\t// De-escape xml-specific characters\n\t\tXmlParser xmlParser = new XmlParser(myData);\n\t\tString outText = xmlParser.deEscapeXMLChars(msg.text);\n\t\tmsg.text = outText;\n\n\t\tmyMessagePane.setText(\"\");\n\t\tupdateMessageArea(msg);\n\n\t}", "@Override\n\t\t\tpublic void onClick(View arg0) {\n\t\t\t\tif(messageCheck.isChecked())\n\t\t\t\tprefs.edit().putString(\"MessageText\",message.getText()+\" \").commit();\n\t\t\t\t\t\n\n\t\t\t}", "@Override\n public void onClick(View v) {\n\n\n Toast.makeText(MainSOSActivity.this, \"Stay Safe and Confirm the Message! Your emergnecy conctacts will be notified!\", Toast.LENGTH_SHORT).show();\n\n }", "@Override\n\tpublic void onMessagePlayCompleted() {\n\t\tbtnSend.setEnabled(true);\n\t}", "@Override\n public void onClick(View view) {\n intent.putExtra(SEND_KEY,sendText.getText().toString());\n\n //Start next Activity/No data is passed back to this activity\n startActivity(intent);\n\n }", "@Override\n public void onClick(View v) {\n Intent intent=new Intent(context, MessageActivity.class);\n intent.putExtra(\"id\",id);\n context.startActivity(intent);\n }", "public void doSendMsg() {\n FacesContext fctx = FacesContext.getCurrentInstance();\n HttpSession sess = (HttpSession) fctx.getExternalContext().getSession(false);\n SEHRMessagingListener chatHdl = (SEHRMessagingListener) sess.getAttribute(\"ChatHandler\");\n if (chatHdl.isSession()) {\n //TODO implement chat via sehr.xnet.DOMAIN.chat to all...\n if (room.equalsIgnoreCase(\"public\")) {\n //send public inside zone\n chatHdl.sendMsg(this.text, SEHRMessagingListener.PUBLIC, moduleCtrl.getLocalZoneID(), -1, -1);\n } else {\n chatHdl.sendMsg(this.text, SEHRMessagingListener.PRIVATE_USER, moduleCtrl.getLocalZoneID(), -1, curUserToChat.getUsrid());\n }\n this.text = \"\";\n }\n //return \"pm:vwChatRoom\";\n }", "@Override\n public void onClick(View view) {\n Intent replyMailIntent = new Intent(\n EmailViewerActivity.this, MailEditorActivity.class);\n // Put message ID that this activity receive from InboxActivity\n replyMailIntent.putExtra(MailEditorActivity.KEY_REPLY,\n getIntent().getExtras().getInt(KEY_EXTRA));\n // Start the reply activity when this button is clicked\n startActivity(replyMailIntent);\n }", "public void sendMessage ( String... messages ) {\n\t\texecute ( handle -> handle.sendMessage ( messages ) );\n\t}", "@Then(\"^Click On Send Button$\")\r\n\tpublic void click_On_Send_Button() {\n\t\tnop.click(\"//*[@id=\\\"submitMessage\\\"]/span\"); \r\n\t \r\n\t}", "@Override\r\n\t\t\t\t\tpublic void onClick(View v) {\n\t\t\t\t\t\tIntent i = new Intent(Intent.ACTION_SEND);\r\n\r\n\t\t\t\t\t\ti.setType(\"message/rfc822\");\r\n\t\t\t\t\t\t/*\r\n\t\t\t\t\t\t * i.setClassName(\"com.google.android.gm\",\r\n\t\t\t\t\t\t * \"com.google.android.gm.ComposeActivityGmail\");\r\n\t\t\t\t\t\t */\r\n\t\t\t\t\t\ti.putExtra(Intent.EXTRA_EMAIL,\r\n\t\t\t\t\t\t\t\tnew String[] { \"[email protected]\" });\r\n\r\n\t\t\t\t\t\tstartActivity(i);\r\n\r\n\t\t\t\t\t}", "@Override\r\n\t\t\t\t\tpublic void onClick(View v) {\n\t\t\t\t\t\tIntent i = new Intent(Intent.ACTION_SEND);\r\n\r\n\t\t\t\t\t\ti.setType(\"message/rfc822\");\r\n\t\t\t\t\t\t/*\r\n\t\t\t\t\t\t * i.setClassName(\"com.google.android.gm\",\r\n\t\t\t\t\t\t * \"com.google.android.gm.ComposeActivityGmail\");\r\n\t\t\t\t\t\t */\r\n\t\t\t\t\t\ti.putExtra(Intent.EXTRA_EMAIL,\r\n\t\t\t\t\t\t\t\tnew String[] { \"[email protected]\" });\r\n\r\n\t\t\t\t\t\tstartActivity(i);\r\n\r\n\t\t\t\t\t}", "@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tString text = getCurUser() + \" : \" + textField.getText();\n\t\t\t\ttextField.setText(\"\");\n\t\t\t\tfinal ChatMessage msg = new ChatMessage();\n\t\t\t\tmsg.setMessage(text);\n\t\t\t\tmainFrame.sendMessage(msg);\n\t\t\t\t\n\t\t\t}", "protected void onSendMessage(View view){\n et = (EditText)findViewById(R.id.message);\n String message = et.getText().toString();\n Intent intent = new Intent(this, ReceiveMessageActivity.class);\n intent.putExtra(\"message\",message);\n startActivity(intent);\n }", "void messageSent();", "private void sendMessage(String text)\n {\n Message msg = mHandler.obtainMessage();\n Bundle bundle = new Bundle();\n bundle.putString(\"text\",text);\n msg.setData(bundle);\n msg.what = 1;\n mHandler.sendMessage(msg);\n }", "public void sendMessage(String[] messages) {}", "@Override\n public void onClick(View v) {\n String message = etMessage.getText().toString();\n // buat objek chat\n Chat chat = new Chat(\"yogi\", message);\n // kirim chat ke database\n chatReference.push().setValue(chat);\n // kosongkan inputan\n etMessage.getText().clear();\n }", "private void sendMessage() {\n\n // Get the right Prefix\n String prefix = null;\n\n if ( !messageGroup.getPrefix().equalsIgnoreCase(\"\") ) {\n prefix = messageGroup.getPrefix();\n } else {\n prefix = Announcer.getInstance().getConfig().getString(\"Settings.Prefix\");\n }\n\n Announcer.getInstance().getCaller().sendAnnouncment( messageGroup, prefix, counter);\n\n counter();\n\n }", "public void onClick(View v) {\n View view = getView();\n if (null != view) {\n TextView textView = (TextView) view.findViewById(R.id.edit_text_out);\n String message = textView.getText().toString();\n Bundle bundle=new Bundle();\n bundle.putString(BluetoothChatFragment.EXTRAS_ADVERTISE_DATA, message);\n mCallback.onSendMessage(bundle);\n //對話框上顯示\n mConversationArrayAdapter.add(\"Me: \" + message);\n //設為不可發送 並清除訊息文字編輯區\n Send_btn=false;\n mSendButton.setEnabled(Send_btn);\n mOutStringBuffer.setLength(0);\n mOutEditText.setText(mOutStringBuffer);\n\n }\n }", "private void sendMessage() {\n if (mRecipientAddress == null) {\n if (mDevices.getSelectedItem() == null) {\n mStatusText.append(\"Please select a device to message.\\n\");\n return;\n }\n if (mMessage.getText() == null || mMessage.getText().toString().equals(\"\")) {\n mStatusText.append(\"Please enter a message to send.\\n\");\n return;\n }\n }\n WifiDirectClientAsyncTask t = new WifiDirectClientAsyncTask(this, mMessage.getText().toString());\n if (Build.VERSION.SDK_INT>=Build.VERSION_CODES.HONEYCOMB)\n t.executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR);\n else\n t.execute();\n }", "@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tswitch (data.MessageType) {\n\t\t\t\tcase 1:\n\t\t\t\t\ttc.startActivity(new Intent(tc, AllotActivity.class));\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase 2:\n\t\t\t\t\ttc.startActivity(new Intent(tc, Will_Activity.class));\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase 3:\n\t\t\t\t\ttc.startActivity(new Intent(tc, OvertimeActivity.class));\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase 4:\n\t\t\t\t\ttc.startActivity(new Intent(tc, DefeatActivity.class));\n\t\t\t\t\tbreak;\n\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}", "private void b_sendActionPerformed(java.awt.event.ActionEvent evt) { \r\n\t\tString nothing = \"\";\r\n\t\tif ((b_sendText.getText()).equals(nothing)) {\r\n\t\t\tb_sendText.setText(\"\");\r\n\t\t\tb_sendText.requestFocus();\r\n\t\t}\r\n\t\telse {\r\n\t\t\ttry {\r\n\t\t\t\ttellEveryone(\"Server\" + \":\" + b_sendText.getText() + \":\" + \"Chat\");\r\n\t\t\t\tPrint_Writer.flush(); // flushes the buffer\r\n\t\t\t} catch (Exception ex) {\r\n\t\t\t}\r\n\t\t\tb_sendText.setText(\"\");\r\n\t\t\tb_sendText.requestFocus();\r\n\t\t}\r\n\r\n\t\tb_sendText.setText(\"\");\r\n\t\tb_sendText.requestFocus();\r\n\r\n\t}", "public void clickSendButtonInMessagesTab(String message) throws UIAutomationException{\t\r\n\t\telementController.requireElementSmart(fileName,\"Send Button In Messages Tab\",GlobalVariables.configuration.getAttrSearchList(), \"Send Button In Messages Tab\");\r\n\t\tUIActions.click(fileName,\"Send Button In Messages Tab\",GlobalVariables.configuration.getAttrSearchList(), \"Send Button In Messages Tab\");\r\n\t\ttry\r\n\t\t{\r\n\t\t\tThread.sleep(4000);\r\n\t\t}\r\n\t\tcatch(Exception e){}\r\n\t\t\r\n\t\t//If the message is blank , check whether \"Message not sent\" notification appears\r\n\t\tif(message.equals(\" \"))\r\n\t\t{\r\n\t\t// Check by clicking on 'Send' notification appears\r\n\t\telementController.requireElementSmart(fileName,\"Message Not Sent Notification\",GlobalVariables.configuration.getAttrSearchList(), \"Message Not Sent Notification\");\r\n\t\tString linkTextInPage=UIActions.getText(fileName,\"Message Not Sent Notification\",GlobalVariables.configuration.getAttrSearchList(), \"Message Not Sent Notification\");\r\n\t\tString linkTextInXML=dataController.getPageDataElements(fileName,\"Message Not Sent Notification Name\" , \"Name\");\r\n\t\tif(!linkTextInPage.contains(linkTextInXML)){\r\n\t\tthrow new UIAutomationException( \"'\"+linkTextInXML +\"' not found\");\r\n\t\t}\t\t\t\r\n\t\t\t\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t// Check by clicking on 'Send' notification appears\r\n\t\telementController.requireElementSmart(fileName,\"Message Sent Notification\",GlobalVariables.configuration.getAttrSearchList(), \"Message Sent Notification\");\r\n\t\tString linkTextInPage=UIActions.getText(fileName,\"Message Sent Notification\",GlobalVariables.configuration.getAttrSearchList(), \"Message Sent Notification\");\r\n\t\tString linkTextInXML=dataController.getPageDataElements(fileName,\"Message Sent Notification Name\" , \"Name\");\r\n\t\tif(!linkTextInPage.contains(linkTextInXML)){\r\n\t\tthrow new UIAutomationException( \"'\"+linkTextInXML +\"' not found\");\r\n\t\t\t}\r\n\t\t}\t\r\n\t\t}", "@Override\n public void onClick(View view) {\n sendRequest();\n }", "public void sendLog() {\n\t\tcommon.waitFor(5000);\n\t\tcommon.isElementDiplayed(sendButton);\n\t\tsendButton.click();\n\t\tcommon.isElementDiplayed(sucessMessage);\n\t\tsendButton.click();\n\n\t}", "@Override\r\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tMessage msg = Message.obtain();\r\n\t\t\t\tnextStep = OTHERBEACH;\r\n\t\t\t\tmsg.what = nextStep;\r\n\t\t\t\tmHandler.sendMessage(msg);\r\n\t\t\t\tisPause =true;\r\n\t\t\t}", "@Override\n public void sendMessage() {\n Intent intent = new Intent(this, GoToMessage.class);\n intent.putExtras(getIntent().getExtras());\n Bundle args = new Bundle();\n args.putString(\"nickname\", mNickname);\n //args.putSerializable(\"convoitem\", item);\n args.putString(\"topic\", mContact.getTopic());\n args.putInt(\"chatid\", mContact.getChatID());\n intent.putExtras(args);\n startActivity(intent);\n }", "public void sendMessage(View view) {\n EditText editText = findViewById(R.id.user_message);\n String message = editText.getText().toString();\n\n Intent intent = new Intent(this, MessageActivity.class);\n\n intent.putExtra(\"EXTRA_MESSAGE\", message);\n\n startActivity(intent);\n }", "@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tIntent i = new Intent(getApplicationContext(), ChainInbox.class);\n\t\t\t\tstartActivity(i);\n\t\t\t}" ]
[ "0.7461509", "0.7345714", "0.72578794", "0.71984386", "0.71679026", "0.7129024", "0.69707674", "0.6941254", "0.6937578", "0.69345194", "0.68870664", "0.6865474", "0.6844149", "0.68215895", "0.6803217", "0.6799085", "0.6794124", "0.67724663", "0.6764417", "0.6752641", "0.6741718", "0.6714612", "0.67124856", "0.6705659", "0.66655964", "0.66600114", "0.66561747", "0.665129", "0.6627497", "0.66220546", "0.6619054", "0.66160643", "0.660652", "0.65764225", "0.65382314", "0.65261567", "0.65245146", "0.6517775", "0.6490093", "0.6486354", "0.6482769", "0.64687556", "0.64675766", "0.644065", "0.64268833", "0.6410419", "0.64050007", "0.6384759", "0.63846064", "0.6379665", "0.6376075", "0.6375918", "0.63705415", "0.63581306", "0.6345211", "0.6344025", "0.6337041", "0.6324022", "0.63219404", "0.6305701", "0.62993157", "0.629738", "0.6294825", "0.62929595", "0.6285925", "0.6280793", "0.62716687", "0.6267197", "0.62477976", "0.6234718", "0.62290657", "0.6222093", "0.6220898", "0.6215034", "0.62133735", "0.62080956", "0.6204039", "0.62019914", "0.6195934", "0.6194917", "0.619046", "0.618492", "0.618492", "0.6181853", "0.6179492", "0.61746407", "0.61650926", "0.6161959", "0.61601055", "0.61502594", "0.61501074", "0.61474895", "0.61473024", "0.6142969", "0.61413056", "0.6133989", "0.6129031", "0.6114117", "0.6110339", "0.6109227", "0.6096128" ]
0.0
-1
code to send chatid to Notes class
@Override public void onClick(View v) { Intent i = new Intent(getApplicationContext(), Prescription.class); Bundle bundle = new Bundle(); bundle.putString("Chatroomcode", chatCode); i.putExtras(bundle); startActivity(i); CustomIntent.customType(Chat.this, "fadein-to-fadeout"); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "int getSendid();", "public int getChatID()\n {\n return chatID;\n }", "String getMessageChatId(String msgId);", "public Integer getChatid() {\n return chatid;\n }", "public long getChatId(){\n return this.chatId;\n }", "public void setChatid(Integer chatid) {\n this.chatid = chatid;\n }", "int getMsgid();", "public String getIdentifier()\n {\n return chatRoomName;\n }", "long getMsgId();", "protected void goToChat(String recID)\n {\n Intent intent = new Intent(this, MessageActivity.class);\n intent.putExtra(\"EXTRA_SESSION_ID\", recID);\n this.startActivity(intent);\n this.finish();\n }", "public void makeAndSendAgentID(){\n sendID(id, x, y);\n }", "public void writeIdChatAtSpecificUserInDatabase(@NonNull ChatMessage chat) {\n mDatabaseReference.child(\"users\").child(chat.getSender()).child(\"chats\").\n child(chat.getIdChat()).setValue(chat.getReceiver());\n mDatabaseReference.child(\"users\").child(chat.getReceiver()).child(\"chats\").\n child(chat.getIdChat()).setValue(chat.getSender());\n }", "long getMessageID();", "long getMessageID();", "private void sendMessage(String body, String toJid) {\n Log.d(TAG, \"Sending message to :\" + toJid);\n\n EntityBareJid jid = null;\n\n toJid = toJid + \"@\" + mApplicationContext.getString(R.string.txt_domain_name) + \"/\" + mApplicationContext.getString(R.string.txt_resource);\n ChatManager chatManager = ChatManager.getInstanceFor(mConnection);\n\n try {\n jid = JidCreate.entityBareFrom(toJid);\n Log.e(TAG, \"sendMessage: jid : \" + jid);\n } catch (XmppStringprepException e) {\n e.printStackTrace();\n }\n Chat chat = chatManager.chatWith(jid);\n try {\n Message message = new Message(jid, Message.Type.chat);\n message.setBody(body);\n chat.send(message);\n\n } catch (SmackException.NotConnectedException e) {\n e.printStackTrace();\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }", "int getReceiverid();", "private void sendMessage(String content, String room) {\n }", "java.lang.String getMessageInfoID();", "void sendTo(String from, String to, String m_id);", "public void writeMassege() {\n m = ChatClient.message;\n jtaChatHistory.setText(\"You : \" + m);\n //writeMassageServer();\n }", "public void notificar()\n\t{\n\n\t\tSocket socket;\n\t\tDataOutputStream out;\n\n\t\ttry\n\t\t{\n\t\t\tsocket = new Socket(host, port);\n\n\t\t\tout = new DataOutputStream(socket.getOutputStream());\n\n\t\t\tout.writeUTF(id);\n\n\t\t\tsocket.close();\n\n\t\t} catch (IOException e)\n\t\t{\n\t\t\te.printStackTrace();\n\t\t}\n\t}", "public void sendMessageById(int senderId, int recipientId, String messageId){\n \t\t\n String url = \"http://nkucloud.dyndns.org:8080/mediacloud/sendMessageById.jsp\";\n \t\t\n \t\tList<NameValuePair> data = new ArrayList<NameValuePair>();\n \t\t\n \t\tdata.add(new BasicNameValuePair(\"userId\", senderId + \"\"));\n \t\tdata.add(new BasicNameValuePair(\"recipient\", recipientId + \"\"));\n \t\tdata.add(new BasicNameValuePair(\"uniqueId\", messageId));\n \t\t\n \n \t\ttry {\n \n \t\t\t// Make POST request\n \t\t\tRequestHelper.makeHttpPostRequest(url, data);\n \t\t} catch (Exception e) {\n \t\t\t// TODO Auto-generated catch block\n \t\t\te.printStackTrace();\n \t\t}\n \t}", "String getNotificationID();", "public String GiveEventID(){\n \tRandom x = new Random();\n \tString pool = \"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789\";\n \tString newid = \"\";\n \tfor(int i = 0;i<26;i++){\n \t\tnewid+=pool.charAt(x.nextInt(36));\n \t}\n \tJSONArray ja = fetchAllNotes(TimeT.getName(),new String[] {TimeT.getFields()[0]},new String[] {newid});\n \tif(ja.length()!=0)\n \t\tnewid = GiveEventID();\n \treturn newid;\n \t\n }", "public int createmessage(String sendername, int senderid, int getterid, String txt) {\n int id = nextId;\n try{\n this.gateWay.writeNewMsg(id, sendername, senderid, getterid, txt);\n }catch (IOException ignored){}\n\n createHelper(id, sendername, senderid, getterid, txt);\n nextId += 1;\n return id;\n }", "@Override\r\n\t\t\t\t\tpublic void sendNoteOn(NoteOn noteOn) {\n\t\t\t\t\t\t\r\n\t\t\t\t\t}", "void sendChat(SendChatParam param);", "public void sendMessage(final int note) {\n final ShortMessage myMsg = new ShortMessage();\n final long timeStamp = -1;\n\n // hard-coded a moderate velocity of 93 because there is no way of tracking speed of finger movement\n try {\n myMsg.setMessage(ShortMessage.NOTE_ON, 0, note, 93);\n } catch (final InvalidMidiDataException e) {\n System.err.println(\"Could not send midi message! \");\n System.err.println(e.getMessage());\n }\n this.midiReceiver.send(myMsg, timeStamp);\n\n// turn the note off after one second of playing\n final ExecutorService service = Executors.newFixedThreadPool(1);\n service.submit(() -> {\n try {\n Thread.sleep(1000);\n //stop old note from playing\n myMsg.setMessage(ShortMessage.NOTE_OFF, 0, note, 0);\n this.midiReceiver.send(myMsg, timeStamp);\n } catch (final InterruptedException | InvalidMidiDataException e) {\n e.printStackTrace();\n }\n });\n }", "public String getID()\n {\n return \"topic=\" + id;\n }", "public void updateLastSentMessageId(Chat chat) {\n spannerTemplate.update(chat, \"ChatID\", \"LastSentMessageID\");\n }", "public void sendNotification(String type, int fromId, int commentId, int articleId) {\n Map<String, String> content = new HashMap<String, String>();\n content.put(\"reply\", \"{from} replied your comment for {article}, check it out!\");\n //more to add to assist with upcoming services\n\n CommentAdder comment = CommentAdder.dao.findById(commentId);\n int toId = comment.get(\"user_id\"); //user_id of whom is getting this notification\n\n UserAdder fromUserSheet = UserAdder.dao.findById(fromId);\n String fromUser = fromUserSheet.get(\"username\");\n\n ContentAdder article = ContentAdder.dao.findById(articleId);\n String articleTitle = article.get(\"title\");\n String articleUrl = article.get(\"en_title\");\n\n String notificationText = Integer.toString(commentId).length() +\n \":\" + commentId + content.get(type).replace(\"{from}\",fromUser)\n .replace(\"{article}\",articleTitle);\n Date now = new Date();\n DateFormat simpleFormat = new SimpleDateFormat(\"yyyy-MM-dd HH:mm:ss\");\n\n new NotificationAdder().set(\"title\", type).set(\"text\", notificationText).set(\"url\",articleUrl).set(\"type\", type)\n .set(\"from_user_id\",fromId).set(\"to_user_id\",toId).set(\"create_time\", simpleFormat.format(now)).save();\n\n }", "void setMessageID(long messageID);", "public void postMsg(String print, String rid) {\n\t\tSystem.out.println(\"Printing in.........\" + rid);\n\n\t\tRoom r = api.context().byId(rid);\n\t\tapi.perform(r.post(new PrimaryChatlet().setQuestionHtml(print)));\n\t}", "public void createMessage(int tid, int uid, int rank, String detail);", "@Override\npublic int sendToID(NodeIDType id, byte[] msg) throws IOException {\n\treturn 0;\n}", "public void echoID() throws IOException {\r\n\t\t//TODO implement using JSON\r\n\t}", "void sendMessage(String pid,String cmd,MintReply mr,int flags)\n{\n sendMessage(pid,cmd,null,mr,flags);\n}", "public void addChat(String to, String from, String from_fullname, String msg, String date, String status,\r\n String uniqueid, String type, String file_type) {\r\n\r\n String myPhone = getUserDetails().get(\"phone\");\r\n String contactPhone = \"\";\r\n if(myPhone.equals(to)) contactPhone = from;\r\n if(myPhone.equals(from)) contactPhone = to;\r\n\r\n SQLiteDatabase db = this.getWritableDatabase();\r\n\r\n ContentValues values = new ContentValues();\r\n values.put(UserChat.USERCHAT_TO, to); // TO\r\n values.put(UserChat.USERCHAT_FROM, from); // FROM\r\n values.put(UserChat.USERCHAT_FROM_FULLNAME, from_fullname); // FROM FULL NAME\r\n values.put(UserChat.USERCHAT_MSG, msg); // CHAT MESSAGE\r\n values.put(UserChat.USERCHAT_DATE, date); // DATE\r\n values.put(\"status\", status); // status: pending, sent, delivered, seen\r\n values.put(\"uniqueid\", uniqueid);\r\n values.put(\"type\", type);\r\n values.put(\"file_type\", file_type);\r\n values.put(\"contact_phone\", contactPhone); // Contact\r\n\r\n // Inserting Row\r\n db.insert(UserChat.TABLE_USERCHAT, null, values);\r\n db.close(); // Closing database connection\r\n }", "long getMessageId();", "long getMessageId();", "private void createHelper(int id, String sendername, int senderid, int getterid, String txt) {\n Message b = new Message(sendername, id, senderid, getterid, txt);\n allmessage.add(b);\n }", "private void sendReply(Integer toID) {\n restTemplate.postForObject(\n config.getConfigNodeInfos().get(toID).getNodeURL() + \"/message/reply\",\n new ReplyMessage(updateAndGetLTS(null), nodeID),\n String.class);\n }", "ChildMessage(String t, int ids[], String nums[],Context ctx){\t\t\t\t\n\t\t\ttext = t;\t\t\t\t\t\t\t\t\t\t\t// Set text for child\n\t\t\tnumbers = new HashMap<String,Integer>();\t\t\t// init numbers hashmap\n\t\t\taddNumbers(ids,nums,ctx);\t\t\t\t\t\t\t\t\n\t\t}", "public void doSendMsg() {\n FacesContext fctx = FacesContext.getCurrentInstance();\n HttpSession sess = (HttpSession) fctx.getExternalContext().getSession(false);\n SEHRMessagingListener chatHdl = (SEHRMessagingListener) sess.getAttribute(\"ChatHandler\");\n if (chatHdl.isSession()) {\n //TODO implement chat via sehr.xnet.DOMAIN.chat to all...\n if (room.equalsIgnoreCase(\"public\")) {\n //send public inside zone\n chatHdl.sendMsg(this.text, SEHRMessagingListener.PUBLIC, moduleCtrl.getLocalZoneID(), -1, -1);\n } else {\n chatHdl.sendMsg(this.text, SEHRMessagingListener.PRIVATE_USER, moduleCtrl.getLocalZoneID(), -1, curUserToChat.getUsrid());\n }\n this.text = \"\";\n }\n //return \"pm:vwChatRoom\";\n }", "netty.framework.messages.MsgId.MsgID getMsgID();", "netty.framework.messages.MsgId.MsgID getMsgID();", "@Override\n\tpublic int writeRecord(int meetingID, Object o, String username) {\n\t\treturn 0;\n\t}", "java.lang.String getID();", "int getMessageId();", "@Override\n public void handleMessage(Message msg) {\n super.handleMessage(msg);\n if(msg.what==1)\n {\n savePhone();\n }\n }", "public void setID(String username){\n this.clientID = username+\": \"+clientID;\n \n }", "public void messageSent(int messageId) {\n\r\n\t}", "Object getMessageId();", "public void messageResp(int respId) {\n\r\n\t}", "@Import(\"note\")\n\tint getLinkedNoteId();", "void getMeMyID()throws IOException{\n out.println(\"ID_ASSIGN\");\r\n fromServer = in.readLine();\r\n String[] input = fromServer.split(\" \");\r\n ID = Integer.parseInt(input[0]);\r\n if(input[1].equals(\"true\")){\r\n setBallHolder(true);\r\n }\r\n }", "@Override\n public void sendMessage() {\n Intent intent = new Intent(this, GoToMessage.class);\n intent.putExtras(getIntent().getExtras());\n Bundle args = new Bundle();\n args.putString(\"nickname\", mNickname);\n //args.putSerializable(\"convoitem\", item);\n args.putString(\"topic\", mContact.getTopic());\n args.putInt(\"chatid\", mContact.getChatID());\n intent.putExtras(args);\n startActivity(intent);\n }", "protocol.ChatData.ChatItem getChatData();", "@Override\n\tpublic void onPrivateChatReceived(final String sender, final String msg) {\n\t\tChatActivity.this.runOnUiThread(new Runnable() {\n\t\t\t public void run() {\n\t\t\t\t sa = ((SharingAtts)getApplication());\n\t\t\t\t chat.append(sender+\": \"+msg+\"\\n\");\t\n\t\t\t\t ItemTest it = new ItemTest();\n\t\t\t\t String colNames = it.printData(\"chat\")[1];\n\t\t\t\t DBManager dbm = new DBManager(ChatActivity.this, colNames,\"chat\",it.printData(\"chat\")[0]);\n\t\t\t\t dbm.openToWrite();\n\t\t\t\t dbm.cretTable();\n\t\t\t\t String msg2 = msg.replace(\" \", \"?*\");\n\t\t\t\t dbm.insertQuery(sender+\" \"+msg2+\" \"+sa.name, colNames.split(\" \")[1]+\" \"+colNames.split(\" \")[2]+\" \"+colNames.split(\" \")[3]);\n\t\t\t\t dbm.close();\n\t\t\t }\n\t\t});\n\t\t\n\t\t\n\t\t\n\t}", "@Override\n\tpublic String sendViewID(final String viewId) {\n\t\tthis.sendId = this.cleanViewId(viewId);\n\t\treturn viewId;\n\t}", "public void setChanId(int arg0) {\n\n }", "int insert(WechatDemo record);", "public void clientToServerChatMessage(String message){\n String chatMessage = message;\n System.out.println(\"chatmessage\" + chatID + \" \" + chatMessage);\n toServer.println(\"chatmessage\" + chatID + \" \" + chatMessage);\n toServer.flush();\n }", "@Override\r\n\tpublic String getPID() {\n\t\treturn \"NYXQYZ\"+getID();\r\n\t}", "public ModelChatlist(String id) {\n this.id = id;\n }", "Boolean sendMsg(String token, Long chatSessionId, String Content);", "void setSenderId(int id) {\n this.senderId = id;\n }", "@Override\n public WriterResult write(int clientId) throws RemoteException {\n log.info(\"writing news client id {}\", clientId);\n try {\n WriterResult result = new WriterResult();\n serverState.getNumOfWriters().incrementAndGet();\n result.setrSeq(numOfClients.incrementAndGet());\n Thread.sleep(new Random().nextInt(10_000));\n serverState.getSharedNews().lockWrite();\n serverState.getSharedNews().setNewsValue(clientId);\n int writeSSeq = serverState.getSequenceNumber().incrementAndGet();\n result.setsSeq(writeSSeq); //sSeq\n writerLog(clientId, writeSSeq);\n serverState.getSharedNews().unlockWrite();\n serverState.getNumOfWriters().decrementAndGet();\n return result;\n } catch (final Exception e) {\n throw new RemoteException(\"Error happend\");\n }\n }", "void messageSent(IMSession session, String messageId);", "private void saveNote()\n\t{\n\t\tString text = ((EditText) findViewById(R.id.note_edittext)).getText().toString();\n\t\tNoteDbWorker worker = new NoteDbWorker(this);\n\t\tworker.updateNote(user.userName, text);\n\t\tworker.close();\n\t\tToast.makeText(this, getString(R.string.note_saved), Toast.LENGTH_LONG).show();\n\t}", "public void make_chat_room() {\n client_PW.println(\"------------make new chat-------------\");\n client_PW.println(\"Enter chat name : \");\n client_PW.flush();\n String line = null;\n String ad=null;\n PrintWriter pw=null;\n HashMap new_chat = new HashMap();\n try {\n line = client_BR.readLine();\n try{\n File file = new File(System.getProperty(\"user.home\"),line + \".txt\");\n pw = new PrintWriter(file);\n \n }catch(Exception e){System.out.println(e);}\n \n synchronized(chat_room) {\n chat_room.put(line, new_chat);\n }\n synchronized(cur_chat_room) {\n cur_chat_room.remove(client_ID);\n }\n String msg = client_ID + \"님이 퇴장하셨습니다\";\n broadcast(msg, null);\n synchronized(new_chat) {\n new_chat.put(client_ID,client_PW);\n }\n synchronized(new_chat) {\n \n new_chat.put(ad,pw);\n }\n cur_chat_room = new_chat;\n } catch (Exception e) { System.out.println(e); }\n \n\n }", "public void setMsgId(Integer msgId) {\n this.msgId = msgId;\n }", "public void write(String id);", "private void recordMessageID( byte[] messageID ){\n \tsynchronized( this.messageIDs ){\n \t Log.d(TAG, \"New Message, ID: \" + messageID.toString());\n \t messageIDs.add(messageID);\n \t // Remove oldest message ID if too many are stored\n \t if (messageIDs.size() > Constants.MSG_HISTORY_LEN) {\n \t Log.d(TAG, \"Removing Message from History\");\n \t messageIDs.remove(0);\n \t }\n \t}\n }", "java.lang.String getLegacyDiscussionId();", "public String getUniqueID ( ) { return _uniqueID; }", "java.lang.String getMessageId();", "public void sendmsg(String to, String msg){\n\n HashMap cur_hash = null;\n PrintWriter to_PW = null;\n\n try{\n synchronized (chat_room) {\n Iterator chat_hash = chat_room.values().iterator();\n while(chat_hash.hasNext()) {\n cur_hash = (HashMap)chat_hash.next();\n if(cur_hash.containsKey(to)) {\n to_PW = (PrintWriter)cur_hash.get(to);\n break;\n }\n }\n }\n \n if(to_PW != null){\n to_PW.println(msg);\n to_PW.flush();\n }\n } catch (Exception e) {\n System.out.println(e);\n } \n }", "public String getUniqueID();", "private void sendMyMessage(JSONObject jsonMsg) {\n String link = \"http://\"+ip+\":8065/api/v1/channels/\"+channel_id+\"/create\";\n String response;\n try{\n ConnectAPIs messageAPI = new ConnectAPIs(link,token);\n messageAPI.sendComment(jsonMsg,this,this);\n }catch(Exception e){\n System.out.println(\"Sending error: \" + e.toString());\n }\n }", "@Override\r\n\t\t\tpublic void onChat(String message) {\n\r\n\t\t\t}", "@Override\n public void onClick(View view) {\n\n System.out.println(\"check--------\");\n if (listChatting.hasIdChatRoom(id)) { //기존 채팅방\n chattingnum = listChatting.getChatNum(id); //채팅방 넘버\n }\n\n String icon = \"[PIMO1]\";\n long now = System.currentTimeMillis();\n Date date = new Date(now);\n SimpleDateFormat sdf = new SimpleDateFormat(\"HH:mm\");\n //yyyy/MM/dd HH:mm:ss\n String getTime = sdf.format(date); //현재 시간\n output = \"[MSG]::\" + chattingnum + \"::\" + id + \"::\" + myid + \"::\" + getTime + \"::\" + icon;\n\n try {\n StrictMode.ThreadPolicy policy = new StrictMode.ThreadPolicy.Builder().permitAll().build();\n StrictMode.setThreadPolicy(policy);\n\n System.out.println(\"test-send 1 chattingnum = \" + chattingnum);\n\n System.out.println(\"test-send\" + output);\n dataOutputStream.writeUTF(output);\n // dataOutputStream.write(output.getBytes());\n dataOutputStream.flush();\n\n //editText.setText(\"\");\n\n\n //chatwrite(dataClass.chatDatahash.get(chattingnum).lastMsg);\n System.out.println(\"test-send 2 chattingnum = \" + chattingnum);\n\n } catch (Exception e) {\n e.printStackTrace();\n return;\n }\n\n }", "public void sendMsg(String address, String title, String content);", "public void sendMessageToClient(Object message, String username) {\n\n }", "boolean saveMyNoteText(String myNote);", "public void obtenerID();", "public int getSendid() {\n return sendid_;\n }", "public void insertReply() {\n\r\n\t}", "void xsetMessageID(org.apache.xmlbeans.XmlLong messageID);", "@Override\r\n\tpublic void OnRandChatInvite(long tempid, long roomid, String uniqueid) {\n\t\tNotitfyRandChat(String.valueOf(tempid),uniqueid,String.valueOf(roomid));\r\n\t}", "private static void writeToPreference(String type, String tag, String s) {\n /*SharedPreferences.Editor editor = eventHistory.edit(); //save log entries\n editor.putString(\n HISTORY_KEY, //key\n type + \" \" + s + \" \" + tag); //content\n editor.apply();*/\n recipient.replyTo( 1, (type + \" \" + s + \" \" + tag));\n }", "void sendMidi (byte[] msg, int offset, int count);", "int getClientMsgNo();", "public void insertChatMessage(String chatMessageID, String chatID, String replierStaffNo, String replierStudentID, String messageContent, String dateTimePosted)\n {\n if(replierStaffNo.equals(\"\"))\n dbConnection.alterDataBase(\"INSERT INTO ChatMessage VALUES ('\"+chatMessageID+\"', '\"+chatID+\"', null, '\"+replierStudentID+\"', '\"+messageContent+\"', '\"+dateTimePosted+\"');\");\n if(replierStudentID.equals(\"\"))\n dbConnection.alterDataBase(\"INSERT INTO ChatMessage VALUES ('\"+chatMessageID+\"', '\"+chatID+\"', '\"+replierStaffNo+\"', null, '\"+messageContent+\"', '\"+dateTimePosted+\"');\");\n }", "private void individualSend(UserLogic t) {\n if(t != UserLogic.this && t != null && ((String)UI.getContacts().getSelectedValue()).equals(t.username)){\r\n if(((String)t.UI.getContacts().getSelectedValue()).equals(username)) { //If both users are directly communicating\r\n t.UI.getProperList().addElement(username + \"> \" + UI.getMessage().getText()); //Send message\r\n t.UI.getContacts().setCellRenderer(clearNotification); //Remove notification\r\n }\r\n else{ //If the user are not directly communicating\r\n t.UI.getContacts().setCellRenderer(setNotification); //Set notification\r\n }\r\n if(t.chats.containsKey(username)){ //Store chats in other users database (When database exists)\r\n ArrayList<String> arrayList = t.chats.get(username); //Get data\r\n arrayList.add(username + \"> \" + UI.getMessage().getText()); //Add new message to the database\r\n t.chats.put(username, arrayList); //Store data\r\n }\r\n else { //When database doesn't exist\r\n ArrayList<String> arrayList = new ArrayList<>(); //create new database\r\n arrayList.add(username + \"> \" + UI.getMessage().getText()); //Add new message to the database\r\n t.chats.put(username, arrayList); //Store data\r\n }\r\n }\r\n //This writes on my screen\r\n if(t == UserLogic.this && t!=null){ //On the current user side\r\n UI.getProperList().addElement(\"Me> \" + UI.getMessage().getText()); //Write message to screen\r\n String currentChat = (String) UI.getContacts().getSelectedValue(); //Get selected user\r\n if(chats.containsKey(currentChat)){ //check if database exists\r\n ArrayList<String> arrayList = chats.get(currentChat);\r\n arrayList.add(\"Me> \" + UI.getMessage().getText());\r\n chats.put(currentChat, arrayList);\r\n }\r\n else { //When database doesn't exist\r\n ArrayList<String> arrayList = new ArrayList<>();\r\n arrayList.add(\"Me> \" + UI.getMessage().getText());\r\n chats.put(currentChat, arrayList);\r\n }\r\n }\r\n }", "void update(int id, int teacherid, int noteid );", "public interface Chat {\n String getPhoneNumberNational();\n\n String getName();\n\n int getChannelID();\n\n int getPersonID();\n\n String getState();\n\n Date getLastMessageSentAt();\n\n String getIsGroupChat();\n}", "public void processMessage(Chat chat, Message message)\n {\n }", "public Integer getMsgId() {\n return msgId;\n }", "private void sendAddFBAndChatInfoToServer(String fbid) {\n \tSBHttpRequest chatServiceAddUserRequest = new ChatServiceCreateUser(fbid);\r\n \tSBHttpClient.getInstance().executeRequest(chatServiceAddUserRequest);\r\n\t\tSBHttpRequest sendFBInfoRequest = new SaveFBInfoRequest(ThisUserConfig.getInstance().getString(ThisUserConfig.USERID), fbid, ThisUserConfig.getInstance().getString(ThisUserConfig.FBACCESSTOKEN));\r\n\t\tSBHttpClient.getInstance().executeRequest(sendFBInfoRequest);\t\t\t\r\n\t}", "public void getChatMessage(String text) {\n\t\tint idplayer = gamecontroller.getPlayerController().getPlayerID();\n\t\tChatM.writeChatToDatabase(idplayer, text);\n\t}" ]
[ "0.6328527", "0.6322908", "0.62849885", "0.6250209", "0.6181419", "0.6162109", "0.61433095", "0.60068786", "0.5949524", "0.58989275", "0.5847809", "0.584407", "0.57984674", "0.57984674", "0.57924855", "0.57245594", "0.57110566", "0.56866115", "0.56754327", "0.56496865", "0.5639618", "0.56368446", "0.5622222", "0.5608247", "0.55691516", "0.55625284", "0.5554575", "0.55423665", "0.5540295", "0.55387807", "0.5522493", "0.54899657", "0.5489241", "0.5484785", "0.54755884", "0.54596025", "0.5447077", "0.54400563", "0.54385865", "0.54385865", "0.54349214", "0.54322606", "0.5421696", "0.5405982", "0.5368603", "0.5368603", "0.5358096", "0.5346956", "0.5341386", "0.53408885", "0.53389597", "0.5338637", "0.5333176", "0.5329246", "0.5305991", "0.5303569", "0.52891284", "0.5281052", "0.5278426", "0.5270909", "0.5268948", "0.5261286", "0.52547485", "0.5252974", "0.5252738", "0.52518946", "0.52476317", "0.52441627", "0.5242301", "0.5237575", "0.52318496", "0.5231089", "0.5226684", "0.522193", "0.52116954", "0.5196896", "0.5194637", "0.51916003", "0.5191527", "0.51875097", "0.5183518", "0.5182867", "0.5180967", "0.51797426", "0.5178014", "0.5172615", "0.5168439", "0.5167088", "0.5165147", "0.51644844", "0.51589715", "0.515645", "0.5152882", "0.515162", "0.51515377", "0.5151318", "0.5150612", "0.5149061", "0.5148479", "0.5147382", "0.51461846" ]
0.0
-1
opens page to Select image for image message.
@Override public void onClick(View view) { Intent intent = new Intent(); intent.setType("image/*"); intent.setAction(Intent.ACTION_GET_CONTENT); startActivityForResult(Intent.createChooser(intent, "Select Picture"), REQUEST_IMAGE); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void selectImage() {\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(\n Intent.createChooser(\n intent,\n \"Select Image from here...\"),\n PICK_IMAGE_REQUEST);\n }", "public static void menu_viewimageinbrowser(ActionContext actionContext){\n Thing currentThing = actionContext.getObject(\"currentThing\");\n \n String url = XWorkerUtils.getWebUrl() + \"do?sc=xworker.ide.worldexplorer.swt.http.SwtImage\";\n url = url + \"&control=\" + currentThing.getMetadata().getPath();\n \n XWorkerUtils.ideOpenUrl(url); \n }", "public void openDialog() {\r\n\t\tString filename = this.getFileName();\r\n\t\tif (filename.equals(null) || filename.equals(\"\") ) {\r\n\t\t\ttext.append(\"\\nPlease select valid image\");\r\n\t\t\topenDialog();\r\n\t\t}\r\n\t\tdisplay_img = this.loadImage(filename);\r\n\r\n\t}", "PreViewPopUpPage clickImageLink();", "private void selectImage() {\n final CharSequence[] items = {\"Take Photo\", \"Choose from Library\",\n \"Cancel\"};\n\n AlertDialog.Builder builder = new AlertDialog.Builder(Timetable.this);\n builder.setTitle(\"Add Photo!\");\n builder.setItems(items, new DialogInterface.OnClickListener() {\n @Override\n public void onClick(DialogInterface dialog, int item) {\n if (items[item].equals(\"Take Photo\")) {\n Intent intent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE);\n startActivityForResult(intent, REQUEST_CAMERA);\n } else if (items[item].equals(\"Choose from Library\")) {\n Intent intent = new Intent(\n Intent.ACTION_PICK,\n android.provider.MediaStore.Images.Media.EXTERNAL_CONTENT_URI);\n intent.setType(\"image/*\");\n startActivityForResult(\n Intent.createChooser(intent, \"Select File\"),\n SELECT_FILE);\n } else if (items[item].equals(\"Cancel\")) {\n dialog.dismiss();\n }\n }\n });\n builder.show();\n }", "private void openFileChoose() {\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(intent, PEGA_IMAGEM);\n }", "public void showImageChooser() {\n Intent intent2 = new Intent();\n intent2.setType(\"image/*\");\n intent2.setAction(\"android.intent.action.GET_CONTENT\");\n startActivityForResult(Intent.createChooser(intent2, \"Select Picture\"), PICK_IMAGE_REQUEST);\n }", "public void selectedImageButtonPushed(ActionEvent event) throws IOException {\n // get the Stage to open a new window\n Stage stage = (Stage)((Node)event.getSource()).getScene().getWindow();\n FileChooser fileChooser = new FileChooser();\n fileChooser.setTitle(\"open Image\");\n //filter for .jpg and .png\n FileChooser.ExtensionFilter imageFilter = new FileChooser.ExtensionFilter(\"Image Files\",\"*.jpg\",\"*.png\");\n fileChooser.getExtensionFilters().add(imageFilter);\n // set the start directory\n String userDirectoryString = System.getProperty(\"user.home\")+\"\\\\Pictures\";\n File userDirectory = new File(userDirectoryString);\n // confirm that system can reach the directory\n if (!userDirectory.canRead())\n userDirectory = new File(System.getProperty(\"user.home\"));\n //set the file chooser to select initial directory\n fileChooser.setInitialDirectory(userDirectory);\n File imageFile = fileChooser.showOpenDialog(stage);\n if (imageFile != null && imageFile.isFile())\n {\n selectImage.setImage(new Image(imageFile.toURI().toString()));\n }\n }", "public void actionPerformed(ActionEvent e) {\n\t\t int returnVal = fc.showOpenDialog(GenerateWindow.this);\n\n\t\t if (returnVal == JFileChooser.APPROVE_OPTION) {\n\t\t File imagefile = fc.getSelectedFile();\n\t\t imageSelect.setText(\"images/\"+imagefile.getName());\n\t\t }}", "private void choseImage() {\n Intent intent = new Intent(Intent.ACTION_GET_CONTENT);\n intent.setType(\"image/*\");\n\n if (intent.resolveActivity(getPackageManager()) != null) {\n startActivityForResult(intent, GALLERY_REQ_CODE);\n } else {\n Toast.makeText(this, R.string.no_image_picker, Toast.LENGTH_SHORT).show();\n }\n }", "private void showImageChooser() {\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(Intent.createChooser(intent, \"Select Profile Image\"), CHOOSE_IMAGE);\n }", "void selectImage(String path);", "@FXML\n void goToChooseImagePage(ActionEvent event) {\n try {\n // Create a FXML loader for loading the choose image FXML file.\n FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource(\"Avatar.fxml\"));\n\n BorderPane chooseImagePage = (BorderPane) fxmlLoader.load();\n Scene chooseImagePageScene = new Scene(chooseImagePage, Main.LARGE_WINDOW_WIDTH, Main.LARGE_WINDOW_HEIGHT);\n Stage chooseImagePageStage = new Stage();\n\n chooseImagePageStage.setScene(chooseImagePageScene);\n chooseImagePageStage.setTitle(Main.CHOOSE_IMAGE_PAGE_WINDOW_TITLE);\n chooseImagePageStage.initModality(Modality.APPLICATION_MODAL);\n // Show the choose image scene and wait for it to be closed\n chooseImagePageStage.showAndWait();\n } catch (IOException e) {\n e.printStackTrace();\n // Quit the program (with an error code)\n System.exit(-1);\n }\n }", "public void openImage() {\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(intent, IMAGE_REQUEST);\n }", "public void selectImage(View view){\n Intent intent = new Intent(Intent.ACTION_PICK, MediaStore.Images.Media.INTERNAL_CONTENT_URI);\n startActivityForResult(intent,PICK_IMAGE);\n }", "private void selectImageFromGallery() {\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(Intent.createChooser(intent, getString(R.string.select_picture)),\n REQUEST_IMAGE_OPEN);\n }", "@Override\n public void onClick(View v) {\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n // image k selection k liey requesting code jo hai upar vo 1234 hai ye dena hota hai\n startActivityForResult(Intent.createChooser(intent, \"Select Image\"), REQUEST_CODE);\n }", "private void openImageFile(ImageActions action) {\n\t\tsetImageHolder(action, RGPTUIUtil.getImageFile(this));\r\n\t}", "@Override\n public void onClick(View v) {\n\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(Intent.createChooser(intent,\n \"Select Picture\"), IMG_RESULT);\n\n }", "public void imageclick(View view)\n {\n //for logo image upload\n\n\n Intent i =new Intent();\n i.setType(\"image/*\");\n i.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(Intent.createChooser(i,\"select an image\"),imagerequestcode);\n\n }", "private void selectImage(){\n final CharSequence[] options = { \"Choose from Gallery\",\"Cancel\" };\n AlertDialog.Builder builder = new AlertDialog.Builder(activity);\n builder.setItems(options, new DialogInterface.OnClickListener() {\n @Override\n public void onClick(DialogInterface dialog, int item) {\n if (options[item].equals(\"Choose from Gallery\"))\n {\n Intent intent = new Intent(Intent.ACTION_PICK, android.provider.MediaStore.Images.Media.EXTERNAL_CONTENT_URI);\n intent.addFlags(Intent.FLAG_GRANT_READ_URI_PERMISSION);\n startActivityForResult(intent, 2);\n }\n else if (options[item].equals(\"Cancel\")) {\n dialog.dismiss();\n }\n }\n });\n builder.show();\n }", "void imageChooser() {\n\n\n Intent i = new Intent();\n i.setType(\"image/*\");\n i.setAction(Intent.ACTION_GET_CONTENT);\n\n\n startActivityForResult(Intent.createChooser(i, \"Select Picture\"), SELECT_PICTURE);\n }", "void imageChooser() {\n\n // create an instance of the\n // intent of the type image\n Intent i = new Intent();\n i.setType(\"image/*\");\n i.setAction(Intent.ACTION_GET_CONTENT);\n\n\n // pass the constant to compare it\n // with the returned requestCode\n startActivityForResult(Intent.createChooser(i, \"Select Picture\"), SELECT_PICTURE);\n }", "private void selectImage() {\n final CharSequence[] options = { \"Take Photo\", \"Choose from Gallery\",\"Cancel\" };\n AlertDialog.Builder builder = new AlertDialog.Builder(EventsActivity.this);\n\n builder.setTitle(\"Search Events By Photo\");\n\n builder.setItems(options, new DialogInterface.OnClickListener() {\n @Override\n public void onClick(DialogInterface dialog, int item) {\n if(options[item].equals(\"Take Photo\")){\n Intent intent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE);\n if (intent.resolveActivity(getPackageManager()) != null) {\n File photoFile = null;\n try {\n photoFile = createImageFile();\n } catch (IOException ex) {\n\n }\n if (photoFile != null) {\n Uri photoURI = FileProvider.getUriForFile(context,\n \"com.example.android.fileprovider\",\n photoFile);\n intent.putExtra(MediaStore.EXTRA_OUTPUT, photoURI);\n startActivityForResult(intent, 1);\n }\n }\n }\n else if(options[item].equals(\"Choose from Gallery\")) {\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(Intent.createChooser(intent, \"Select File\"),2);\n }\n else if(options[item].equals(\"Cancel\")) {\n dialog.dismiss();\n }\n }\n });\n builder.show();\n }", "private void onSendImageClick() {\n Intent intent = new Intent();\n intent.putExtra(Constants.SELECTED_IMAGE, mediaPath);\n intent.putExtra(Constants.CHAT_TYPE, messageType);\n setResult(Activity.RESULT_OK, intent);\n finish();\n }", "@Override\n public void onClick(View v) {\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(Intent.createChooser(intent,\n \"Select Picture\"), SELECT_PICTURE);\n }", "public void onClick(View arg0) {\n Intent intent = new Intent();\r\n intent.setType(\"image/*\");\r\n intent.setAction(Intent.ACTION_GET_CONTENT);\r\n startActivityForResult(Intent.createChooser(intent,\r\n \"Select Picture\"), SELECT_PICTURE);\r\n }", "private void showFileChooser() {\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(Intent.createChooser(intent, \"Select Picture\"), PICK_IMAGE_REQUEST);\n }", "private void showFileChooser() {\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(Intent.createChooser(intent, \"Select Picture\"), PICK_IMAGE_REQUEST);\n }", "protected void mCertificateImageSelection() {\n final CharSequence[] options = {\"Camera\", \"Gallery\", \"Cancel\"};\n\n AlertDialog.Builder builder = new AlertDialog.Builder(new ContextThemeWrapper\n (ApplicationActivity.this, R.style.AlertDialogCustom));\n\n builder.setIcon(R.mipmap.birth_icon);\n builder.setTitle(\"Birth Certificate\");\n builder.setItems(options, new DialogInterface.OnClickListener() {\n @Override\n public void onClick(DialogInterface dialog, int item) {\n\n //Camera Option\n if (options[item].equals(\"Camera\")) {\n Intent intent = new Intent(android.provider.MediaStore.ACTION_IMAGE_CAPTURE);\n startActivityForResult(intent, CAMERA_REQUEST_1);\n }\n\n //Gallery Option\n else if (options[item].equals(\"Gallery\")) {\n Intent intent = new Intent(Intent.ACTION_PICK,\n android.provider.MediaStore.Images.Media.EXTERNAL_CONTENT_URI);\n intent.setType(\"image/*\");\n startActivityForResult(intent, GALLERY_REQUEST_1);\n }\n\n //Cancel Option\n else if (options[item].equals(\"Cancel\")) {\n dialog.dismiss();\n }\n }\n });\n\n builder.show();\n }", "private void showFileChooser() {\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(Intent.createChooser(intent, \"Select Picture\"), PICK_IMAGE_REQUEST);\n }", "@FXML\r\n public void imageButtonClicked() {\r\n File file = fileChooser.showOpenDialog(viewHandler.getPrimaryStage());\r\n if (file != null) {\r\n try {\r\n viewModel.setImageurl(ImageConverter.ImageToByte(file));\r\n Image img = new Image(new ByteArrayInputStream(viewModel.getImageurl()));\r\n dogPicture.setFill(new ImagePattern(img));\r\n } catch (FileNotFoundException e) {\r\n e.printStackTrace();\r\n }\r\n }\r\n }", "private void showFileChooser() {\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(Intent.createChooser(intent, \"Select Picture\"), 234);\n }", "private static void openImageMenu(OrganizedImage image, int index)\n {\n\t// True if the 'Back to 'Browse organized images' menu...' option has been selected.\n\tboolean backToBrowseOrganized = false;\n\n\twhile(!backToBrowseOrganized)\n\t {\n\t\tSystem.out.println(\"\");\n\t\tSystem.out.println(\">>Main>Browse organized images>Open image:\");\n\t\tSystem.out.println(\"\");\n\t\tSystem.out.println(\"1: View image.\");\n\t\tSystem.out.println(\"2: Image options...\");\n\t\tSystem.out.println(\"3: Back to 'Browse organized images' menu...\");\n\t\tSystem.out.println(\"\");\n\t\tSystem.out.print(\"\\t>> \");\n\t\t\n\t\tswitch(getUserOption())\n\t\t {\n\t\t case(1):\n\t\t\timage.view();\n\t\t\tbreak;\n\t\t case(2):\n\t\t\timageOptionsMenu(image, index);\n\t\t\tbreak;\n\t\t case(3):\n\t\t\tbackToBrowseOrganized = true;\n\t\t\tbreak;\n\t\t default:\n\t\t\tSystem.out.println(\"That was not a valid option, please try again:\");\n\t\t }\n\t }\n }", "private void imagePic(){\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(Intent.createChooser(intent, \"Select Picture\"),1);\n\n }", "public void loadInputImage()\n{\n selectInput(\"Select a file to process:\", \"imageLoader\"); // select image window -> imageLoader()\n}", "private void showGalleryChooser() {\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(Intent.createChooser(intent, \"Select Picture\"), PICK_IMAGE_REQUEST);\n }", "private void showChoosePictureDialog() {\n String[] permissions = PermissionConstants.checkIfPermissionsAreGranted(this,\n PermissionConstants.READ_STORAGE, PermissionConstants.WRITE_STORGAE,\n PermissionConstants.CAMERA);\n if(permissions.length > 0) {\n PermissionConstants.askForPermissions(this, PERMISSIONS_REQUEST, permissions);\n } else {\n EasyImage.openChooserWithGallery(this, \"\", 0);\n }\n }", "public void choosePicture() {\n\n Intent intent = new Intent();\n intent.setType(\"image/*\"); //inserting all images inside this Image folder\n intent.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(intent, 1);\n\n }", "public void getImage(View view)\n {\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(Intent.createChooser(intent, \"Select Picture\"), PICK_IMAGE);\n\n }", "private void chooseImageAndUpload() {\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(Intent.createChooser(intent, \"Select Picture\"), Common.PICK_IMAGE_REQUEST);\n\n }", "@Override\n public void onClick(View v) {\n\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n Intent pickIntent = new Intent(Intent.ACTION_PICK, MediaStore.Images.Media.EXTERNAL_CONTENT_URI);\n pickIntent.setType(\"image/*\");\n Intent chooserIntent = Intent.createChooser(intent, \"Select Image\");\n chooserIntent.putExtra(Intent.EXTRA_INITIAL_INTENTS, new Intent[] {pickIntent});\n startActivityForResult(chooserIntent,PICK_IMAGE_REQUEST);\n }", "public void selectMarkerImage() {\r\n\t\tsafeClick(selectAddMarkerImage, MEDIUMWAIT);\r\n\t}", "@Override\n public void onClick(View view) {\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n\n startActivityForResult(Intent.createChooser(intent,\"Choose an app to select a image\"), 1);\n }", "@Override\n public void onClick(View view) {\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(Intent.createChooser(intent, getString(R.string.photo_selector)), RESULT_PHOTO_OK);\n }", "@Override\n public void onClick(View view) {\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(Intent.createChooser(intent, getString(R.string.photo_selector)), RESULT_PHOTO_OK);\n }", "public void openFileChooser(ValueCallback<Uri> uploadMsg) {\n openFileChooser(uploadMsg, \"image/*\");\n }", "@Override\n public void actionPerformed(ActionEvent e) {\n JFileChooser fc = new JFileChooser(); \n int returnVal = fc.showOpenDialog(null);\n if (returnVal == JFileChooser.APPROVE_OPTION) {\n File file = fc.getSelectedFile();\n System.out.println(file.getAbsolutePath()); \n image = loadImage( file);\n }\n }", "@Override\n public void onClick(View v) {\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n ((MainActivity) getActivity()).startActivityForResult(\n Intent.createChooser(intent, \"Select Picture\"),\n MainActivity.GALLERY_CODE);\n\n }", "@Override\n public void imageFromGallery() {\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(Intent.createChooser(intent, \"Select picture\"), PICK_IMAGE);\n }", "protected void mProfileImageSelection() {\n\n final CharSequence[] options = {\"Camera\", \"Gallery\", \"Cancel\"};\n\n AlertDialog.Builder builder = new AlertDialog.Builder(new ContextThemeWrapper\n (ApplicationActivity.this, R.style.AlertDialogCustom));\n\n builder.setIcon(R.mipmap.profile_icon);\n builder.setTitle(\"Profile Picture\");\n builder.setItems(options, new DialogInterface.OnClickListener() {\n @Override\n public void onClick(DialogInterface dialog, int item) {\n\n //Camera Option\n if (options[item].equals(\"Camera\")) {\n Intent intent = new Intent(android.provider.MediaStore.ACTION_IMAGE_CAPTURE);\n startActivityForResult(intent, CAMERA_REQUEST);\n }\n\n //Gallery Option\n else if (options[item].equals(\"Gallery\")) {\n Intent intent = new Intent(Intent.ACTION_PICK,\n android.provider.MediaStore.Images.Media.EXTERNAL_CONTENT_URI);\n intent.setType(\"image/*\");\n startActivityForResult(intent, GALLERY_REQUEST);\n }\n\n //Cancel Option\n else if (options[item].equals(\"Cancel\")) {\n dialog.dismiss();\n }\n }\n });\n\n builder.show();\n }", "private void select_image() {\n\n final CharSequence[] items = {\"Camera\", \"Gallery\", \"Cancel\"};\n\n AlertDialog.Builder builder = new AlertDialog.Builder(step4.this);\n builder.setTitle(\"Add Image\");\n builder.setItems(items, new DialogInterface.OnClickListener() {\n @Override\n public void onClick(DialogInterface DialogInterface, int i) {\n if (items[i].equals(\"Camera\")) {\n\n Intent camera = new Intent(android.provider.MediaStore.ACTION_IMAGE_CAPTURE);\n if (ActivityCompat.checkSelfPermission(step4.this, Manifest.permission.CAMERA) != PackageManager.PERMISSION_GRANTED) {\n Toast.makeText(getApplicationContext(), \"Please grant permission to access Camera\", Toast.LENGTH_LONG).show();\n ActivityCompat.requestPermissions(step4.this, new String[]{Manifest.permission.CAMERA}, 1);\n startActivityForResult(camera,REQUEST_CAMERA);\n\n } else {\n startActivityForResult(camera,REQUEST_CAMERA);\n\n }\n\n\n\n } else if (items[i].equals(\"Gallery\")) {\n\n Intent gallery = new Intent(Intent.ACTION_PICK, MediaStore.Images.Media.EXTERNAL_CONTENT_URI);\n gallery.setType(\"image/*\");\n startActivityForResult(gallery, select_file);\n\n\n } else if (items[i].equals(\"Cancel\")) {\n\n DialogInterface.dismiss();\n\n\n }\n }\n\n\n });\n builder.show();\n }", "private void selectOptionOfPicture() {\n final CharSequence[] options = { \"Take Photo\", \"Choose from Gallery\",\"Cancel\" };\n AlertDialog.Builder builder = new AlertDialog.Builder(view.getContext());\n builder.setTitle(\"Add Photo!\");\n builder.setItems(options, new DialogInterface.OnClickListener() {\n @Override\n public void onClick(DialogInterface dialog, int item) {\n if (options[item].equals(\"Take Photo\"))\n {\n Intent intent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE);\n startActivityForResult(intent, 1);\n }\n else if (options[item].equals(\"Choose from Gallery\"))\n {\n Intent intent = new Intent(Intent.ACTION_PICK, MediaStore.Images.Media.INTERNAL_CONTENT_URI);\n startActivityForResult(intent, 2);\n }\n else if (options[item].equals(\"Cancel\")) {\n dialog.dismiss();\n }\n }\n });\n builder.show();\n }", "@Override\n public void onClick(View v) {\n chooseImage();\n }", "private void showImageDetail() {\n }", "@Override\n public void onClick(View v) {\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(Intent.createChooser(intent, \"SELECT IMAGE\"), GALLERY_PICK);\n }", "public void openImage(String name) throws ViewerException {\n\n\t}", "public void openCustomPictureCreator() {\n\n\t\tFXMLLoader fxmlL = new FXMLLoader(getClass().getResource(\"AvatarDrawingTool.fxml\"));\n\t\ttry {\n\t\t\tBorderPane login = (BorderPane) fxmlL.load();\n\n\t\t\tScene scene = new Scene(login, 600, 400);\n\n\t\t\tStage stage = new Stage();\n\t\t\tstage.setScene(scene);\n\t\t\tstage.initModality(Modality.APPLICATION_MODAL);\n\n\t\t\tstage.showAndWait();\n\t\t\t\n\t\t\tif(custom) {\n\t\t\t\tsetImg();\n\t\t\t}\n\t\t} catch (IOException e) {\n\t\t\t\n\t\t\te.printStackTrace();\n\t\t}\n\t}", "private void openFileChooser() {\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(intent, PICK_IMAGE_REQUEST);\n\n }", "private void showImagePickDialog() {\n String[] options = {\"Camera\", \"Gallery\"};\n //dialog\n AlertDialog.Builder builder = new AlertDialog.Builder(this);\n builder.setTitle(\"Pick Image\")\n .setItems(options, new DialogInterface.OnClickListener() {\n @Override\n public void onClick(DialogInterface dialog, int which) {\n if (which == 0) {\n //Camera Clicked\n if (checkCameraPermission()) {\n // cameraPermission allowed\n pickFromCamera();\n } else {\n // cameraPermission not allowed, request\n requestCameraPermission();\n }\n } else {\n //Gallery Clicked\n if (checkStoragePermission()) {\n // Storage Permission allowed\n pickFromGallery();\n } else {\n // Storage Permission not allowed, request\n requestStoragePermission();\n\n }\n\n }\n }\n }).show();\n }", "@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tIntent intent = new Intent(Intent.ACTION_PICK, null);\n\n\t\t\t\tintent.setDataAndType(MediaStore.Images.Media.EXTERNAL_CONTENT_URI, \"image/*\");\n\t\t\t\tstartActivityForResult(intent, 1);\n\t\t\t\tmenu_mine.setVisibility(View.GONE);\n\t\t\t}", "public void onLaunchSelect() {\n Intent intent = new Intent(Intent.ACTION_PICK,\n MediaStore.Images.Media.EXTERNAL_CONTENT_URI);\n\n\n // If you call startActivityForResult() using an intent that no app can handle, your app will crash.\n // So as long as the result is not null, it's safe to use the intent.\n if (intent.resolveActivity(getPackageManager()) != null) {\n // Bring up gallery to select a photo\n startActivityForResult(intent, SELECT_IMAGE_REQUEST_CODE);\n }\n }", "public void onClick(View v) {\n Intent intent = new Intent(Intent.ACTION_OPEN_DOCUMENT);\n\n // Filter to only show results that can be \"opened\", such as a\n // file (as opposed to a list of contacts or timezones)\n intent.addCategory(Intent.CATEGORY_OPENABLE);\n\n // Filter to show only images, using the image MIME data type.\n // it would be \"*/*\".\n intent.setType(\"*/*\");\n\n startActivityForResult(intent, RESULT_PICK_IMAGEFILE);\n }", "@Override\n public void onClick(View v) {\n\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.putExtra(Intent.EXTRA_ALLOW_MULTIPLE, true);\n intent.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(Intent.createChooser(intent, \"Select Picture\"), 1);\n\n }", "private void helperDisplayInputImage()\r\n\t{\r\n\t\ttry\r\n\t\t{\r\n\t\t\t//---- Get currently selected file index in the combo box\r\n\t\t\tint index = mainFormLink.getComponentPanelLeft().getComponentComboboxFileName().getSelectedIndex();\r\n\r\n\t\t\t//---- Check the index if the action is invoked by image deletion then causes error\r\n\t\t\tint imageCount = DataController.getTable().getTableSize();\r\n\r\n\t\t\tif (index >= 0 && index < imageCount)\r\n\t\t\t{\r\n\t\t\t\t//---- Get file path of the table\r\n\r\n\t\t\t\tString filePath = DataController.getTable().getElement(index).getDataFile().getFilePath();\r\n\r\n\t\t\t\tmainFormLink.getComponentPanelCenter().getComponentPanelImageView().displayPolygonStop();\r\n\t\t\t\tmainFormLink.getComponentPanelCenter().getComponentPanelImageView().loadImage(filePath);\r\n\t\t\t}\r\n\t\t}\r\n\t\tcatch (ExceptionMessage e)\r\n\t\t{\r\n\t\t\tExceptionHandler.processException(e);\r\n\t\t}\r\n\t}", "@Override\n public void onClick(View v) {\n Intent photoPickerIntent = new Intent(Intent.ACTION_PICK);\n photoPickerIntent.setType(\"image/*\");\n startActivityForResult(photoPickerIntent, SELECT_PHOTO);\n }", "private void galleryIntent() {\n Intent intent = new Intent(Intent.ACTION_PICK, android.provider.MediaStore.Images.Media.EXTERNAL_CONTENT_URI);\n intent.setType(\"image/*\");\n ((MessageActivity) context).startActivityForResult(Intent.createChooser(intent,\n \"Select Picture\"), SELECT_PICTURE);\n\n }", "public void clickPickImage(View view) {\n Intent photoPickerIntent = new Intent(Intent.ACTION_PICK);\n photoPickerIntent.setType(\"image/*\");\n startActivityForResult(photoPickerIntent, 10);\n }", "public void OpenActionPerformed(ActionEvent evt) { \r\n\r\n //open file from file browser and display the image in the drawing panel\r\n if (jfcOpen.showOpenDialog(this) == JFileChooser.APPROVE_OPTION){\r\n //get selected image file\r\n File fileOpen = jfcOpen.getSelectedFile();\r\n \r\n //get image file path\r\n String fileName = fileOpen.toString();\r\n \r\n //set image path and display image\r\n drawingPanel.setPath(fileName); \r\n }\r\n }", "private void getImage() {\n\n Intent intent = new Intent(\n Intent.ACTION_PICK,\n android.provider.MediaStore.Images.Media.EXTERNAL_CONTENT_URI);\n\n //intent.setType(\"text/xls\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n\n try {\n startActivityForResult(\n Intent.createChooser(intent, \"Complete action using\"),\n MY_INTENT_CLICK);\n }catch (Exception e) {\n e.getMessage();\n }\n }", "public void onImageClick(View view) {\n Intent photo_picker = new Intent(Intent.ACTION_PICK,\n android.provider.MediaStore.Images.Media.EXTERNAL_CONTENT_URI);\n photo_picker.setType(\"image/jpeg\");\n startActivityForResult(photo_picker,PHOTO_PICK);\n }", "private void openFileChooser() {\n Intent imageIntent = new Intent(Intent.ACTION_PICK, MediaStore.Images.Media.EXTERNAL_CONTENT_URI);\n imageIntent.setType(\"image/*\");\n startActivityForResult(imageIntent, GALLERY_REQUEST);\n }", "@FXML\n public void onBrowseButtonClick() {\n\t\tFileChooser fileChooser = new FileChooser();\n\t\tfileChooser.setTitle(\"Open\");\n\t\tfileChooser.getExtensionFilters().addAll(\n\t\t\t\tnew FileChooser.ExtensionFilter(\"Images\", \"*.jpg\", \"*.png\", \"*.jpeg\")\n\t\t);\n\n\t\t// Opens the file chooser and grabs the image the user selected\n\t\tFile file = fileChooser.showOpenDialog(root.getScene().getWindow());\n\t\tif (file == null)\n\t\t\treturn;\n\n\t\t// Saves the image in the program\n\t\tImage originalImage = new Image(file.toURI().toString());\n\t\tMain.setOriginalImage(originalImage);\n\n\t\t// Shows the path text and saves the original image in the program\n\t\toriginalImageView.setImage(originalImage);\n\n\t\t// Centers the image in the tiny space it has\n\t\tdouble imageViewOffset = originalImageView.getBoundsInParent().getWidth() / 2;\n\t\toriginalImageView.setLayoutX(128 - imageViewOffset);\n\n\t\tcreateRectifiedImage();\n\t\tshowRectifiedImage();\n\t}", "@Override\n public void onClick(View view) {\n Intent intent=new Intent(Intent.ACTION_PICK);\n // Sets the type as image/*. This ensures only components of type image are selected\n intent.setType(\"image/*\");\n //We pass an extra array with the accepted mime types. This will ensure only components with these MIME types as targeted.\n String[] mimeTypes = {\"image/jpeg\", \"image/png\"};\n intent.putExtra(Intent.EXTRA_MIME_TYPES,mimeTypes);\n // Launching the Intent\n startActivityForResult(intent,1);\n }", "String avatarImageSelected();", "@Override\r\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tJFileChooser jfc=new JFileChooser(); \r\n\t\t jfc.setFileSelectionMode(JFileChooser.FILES_AND_DIRECTORIES ); \r\n\t\t jfc.showDialog(new JLabel(), \"选择\"); \r\n\t\t File file=jfc.getSelectedFile();\r\n\t\t if(null==file){\r\n\t\t \treturn;\r\n\t\t }\r\n\t\t if(file.isDirectory()){\r\n\t\t System.out.println(\"文件夹:\"+file.getAbsolutePath()); \r\n\t\t }else if(file.isFile()){\r\n\t\t System.out.println(\"文件:\"+file.getAbsolutePath()); \r\n\t\t }\r\n\t\t if(Util.isImage(file)){\r\n\t\t \tImageIcon img = new ImageIcon(file.getAbsolutePath());\r\n\t\t\t\t\tlbImage.setIcon(img);\r\n\t\t\t\t\tMain.img = img.getImage();\r\n\t\t }else{\r\n\t\t \tJOptionPane.showMessageDialog(Main.this, \"请选择图片\");\r\n\t\t }\r\n\t\t\t}", "public void loadImage1(View view) {\n Intent intent = new Intent(this, SelectImageActivity.class);\n startActivityForResult(intent, REQUEST_SELECT_IMAGE_1);\n }", "@Override\n\t\tpublic void onClick(View v) { Intent galleryIntent = new Intent(Intent.ACTION_PICK,\n\t\t\t\t\tandroid.provider.MediaStore.Images.Media.EXTERNAL_CONTENT_URI);\n\n\t\t\t// Start the Intent\n\t\t\tstartActivityForResult(\n\t\t\t\t\tIntent.createChooser(galleryIntent, \"Select Picture\"), REQUEST_CODE);\n\t\t}", "private void sendImage(Uri selectedImageUri) {\n\t\t\n\t}", "private void OpenGallery() {\n Intent pickImage = new Intent(Intent.ACTION_PICK, MediaStore.Images.Media.EXTERNAL_CONTENT_URI);\n startActivityForResult(pickImage, RequestCode);\n }", "private void openGallery() {\n Intent gallery = new Intent(Intent.ACTION_PICK, MediaStore.Images.Media.INTERNAL_CONTENT_URI);\n startActivityForResult(gallery, REQUEST_IMAGE_SELECT);\n }", "BufferedImage getSelectedImage();", "@Override\n public void onClick(View v) {\n Intent i = new Intent(\n Intent.ACTION_PICK,\n android.provider.MediaStore.Images.Media.EXTERNAL_CONTENT_URI);\n startActivityForResult(i, SELECTED_PICTURE);\n }", "public void startImageSwitch() {\n Intent intent = new Intent(this, AlbumCompatActivity.class);\r\n intent.putExtra(AlbumCompatActivity.CHOOSE_MODE, AlbumCompatActivity.CHOOSE_MODE_SECTION); // ImageUtil.getPathForUpload(mImageKey).getAbsolutePath()\r\n intent.putExtra(AlbumCompatActivity.K_ALBUM_RST_COUNT, 5);\r\n startActivityForResult(intent, SELECT_IMAGE_COMPLETE);\r\n }", "public void openFile()\n { \n JFileChooser chooser = new JFileChooser();\n chooser.setCurrentDirectory(new File(\".\"));\n \n chooser.setFileFilter(new\n javax.swing.filechooser.FileFilter()\n { \n public boolean accept(File f)\n { \n String name = f.getName().toLowerCase();\n return name.endsWith(\".gif\") || name.endsWith(\".jpg\") || name.endsWith(\".jpeg\")\n || f.isDirectory();\n }\n public String getDescription() { return \"Image files\"; }\n });\n\n int r = chooser.showOpenDialog(this);\n if(r != JFileChooser.APPROVE_OPTION) return;\n\n try\n {\n image = ImageIO.read(chooser.getSelectedFile());\n }\n catch (IOException e)\n {\n JOptionPane.showMessageDialog(this, e);\n }\n repaint();\n }", "@Override\n public void onClick(View v) {\n\n Intent intent = new Intent( Intent.ACTION_PICK, android.provider.MediaStore.Images.Media.EXTERNAL_CONTENT_URI);\n intent.setType(\"image/*\");\n startActivityForResult(Intent.createChooser(intent, \"Select File\"), 1);\n }", "public void pickImage(View view) {\n if (checkClickTime()) return;\n Intent chooseImageIntent = ImagePicker.getPickImageIntent(this);\n startActivityForResult(chooseImageIntent, PICK_IMAGE_REQUEST_CODE);\n }", "@When(\"^user clicks on image tab$\")\n\tpublic void user_clicks_on_image_tab() throws Throwable {\n\t\thomepage.waitForPageToLoad(\"Google Images\");\n\t\thomepage.waitForElementToBeClickable(homepage.imagesButton);\n\t\thomepage.clickOnElementUsingJs(homepage.imagesButton);\n\t}", "@Override\n public void onClick(View v) {\n Intent intent = new Intent(Intent.ACTION_PICK);\n intent.setType(\"image/*\");\n // the one is the number attached to the intent\n //it capture the number and goes with the result\n startActivityForResult(intent,1);\n }", "@OnClick(R.id.hinhanh_dangtin)\n void ChooseImage(View v) {\n onPickPhoto(v);\n }", "public void call1()\n\t{\n\t\tIntent intent = new Intent();\n\t\tintent.setType(\"image/*\");\n\t\tintent.setAction(Intent.ACTION_GET_CONTENT);\n\t\tstartActivityForResult(Intent.createChooser(intent,\n\t\t\t\t\"Select Picture\"), SELECT_PICTURE);\n\n\n\t}", "@Override\n\tpublic void actionPerformed(ActionEvent e) {\n\t\tif (e.getSource() == first) {\n\t\t\tshowPictureFromTheInternet(\"http://www.pictorem.com/collection/900_2331348HighRes.jpg\");\n\t\t} else if (e.getSource() == secound) {\n\t\t\tshowPictureFromTheInternet(\"https://ih1.redbubble.net/image.410068489.3517/ap,550x550,12x12,1,transparent,t.png\");\n\t\t}\n\n\t}", "@FXML\n\tvoid goToPicture(ActionEvent event) throws IOException {\n\t\tAnchorPane loader = (AnchorPane)FXMLLoader.load(getClass().getResource(\"/application/view/visual.fxml\"));\n\t\tStage stage = (Stage) switchPic.getScene().getWindow();\n\t\tScene scene = new Scene(loader,600,400);\n\t\tstage.setScene(scene);\n\t}", "public void changePic(View v){\n //Intent gallery = new Intent(Intent.ACTION_PICK, MediaStore.Images.Media.INTERNAL_CONTENT_URI);\n //startActivityForResult(gallery,PICK_IMAGE);\n new AlertDialog.Builder(ProfileModify.this)\n .setIcon(android.R.drawable.ic_dialog_alert)\n .setTitle(\"Choose\")\n .setItems(Choose, new DialogInterface.OnClickListener() {\n @Override\n public void onClick(DialogInterface dialog, int which) {\n if(which == 0) {\n Intent iGallery = new Intent(Intent.ACTION_PICK,MediaStore.Images.Media.EXTERNAL_CONTENT_URI);\n startActivityForResult(iGallery,PICK_GALLERY);\n }\n else {\n Intent iCamera = new Intent(MediaStore.ACTION_IMAGE_CAPTURE);\n if(iCamera.resolveActivity(getPackageManager()) != null){\n startActivityForResult(iCamera,REQUEST_IMAGE_CAPTURE);\n }\n }\n }\n }).create().show();\n }", "public void selectImages()\n {\n Log.d(TAG, \"selectImages\");\n BSImagePicker multiPicker = null;\n\n multiPicker = new BSImagePicker.Builder(FILE_PROVIDER)\n .isMultiSelect()\n .setMultiSelectBarBgColor(android.R.color.background_dark)\n .setMultiSelectTextColor(R.color.primary_text)\n .setMultiSelectDoneTextColor(android.R.color.white)\n .setSpanCount(NUMBER_OF_COLUMNS)\n .build();\n\n multiPicker.show(this.fragmentActivity.getSupportFragmentManager(), \"Image picker\");\n }", "private void chooseDialog() {\n CharSequence menu[] = new CharSequence[]{\"Take From Galery\", \"Open Camera\"};\n AlertDialog.Builder builder = new AlertDialog.Builder(this);\n builder.setTitle(\"Pick a Picture\");\n builder.setItems(menu, new DialogInterface.OnClickListener() {\n @Override\n public void onClick(DialogInterface dialogInterface, int i) {\n if (i == 0) {\n gallery();\n } else {\n takePicture();\n }\n }\n });\n builder.show();\n\n }", "@Subscribe\n public void handlePhotoGalleryPageSelected(OnPhotoGalleryPhotoSelect event) {\n displayPhoto(event.getPhotoDisplayInfo());\n }", "private void profilePicImageChooser() {\n Intent pickIntent = new Intent();\n pickIntent.setType(\"image/*\");\n pickIntent.setAction(Intent.ACTION_GET_CONTENT);\n\n Intent takePhotoIntent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE);\n\n String pickTitle = \"Select or take a new Picture\";\n Intent chooserIntent = Intent.createChooser(pickIntent, pickTitle);\n chooserIntent.putExtra(Intent.EXTRA_INITIAL_INTENTS, new Intent[]{takePhotoIntent});\n startActivityForResult(chooserIntent, HPIApp.Prefs.CODE_IMAGE_SELECT);\n }", "@Override\n\t\t\t\tpublic void onClick(View v) {\n\t\t\t\t\tLog.e(\"open gallery\", \"opencamera\");\n\n\t\t\t\t\topenImagechooseAlertDialog();\n\t\t\t\t}", "@Override\n\t\t\t\tpublic void onClick(View v) {\n\t\t\t\t\tLog.e(\"open gallery\", \"opencamera\");\n\n\t\t\t\t\topenImagechooseAlertDialog();\n\t\t\t\t}" ]
[ "0.74408454", "0.7193606", "0.71055746", "0.69587463", "0.69334054", "0.6847602", "0.683667", "0.68223894", "0.6808904", "0.6795413", "0.67827255", "0.6727278", "0.67186046", "0.67082167", "0.6679211", "0.66729724", "0.66632086", "0.6622124", "0.66147125", "0.659803", "0.6594573", "0.6563624", "0.6556868", "0.6532325", "0.6508118", "0.65046793", "0.6495447", "0.6485604", "0.6485604", "0.64703363", "0.64218795", "0.6383113", "0.6379487", "0.6368577", "0.6364237", "0.63629454", "0.6348977", "0.63269913", "0.6321009", "0.6320471", "0.63016003", "0.6298336", "0.6293661", "0.62920266", "0.62634873", "0.62634873", "0.62547755", "0.6248373", "0.6245701", "0.62412524", "0.6237145", "0.6234931", "0.6232344", "0.6230463", "0.6226784", "0.62108696", "0.6191588", "0.6186381", "0.61810106", "0.61754644", "0.61750245", "0.6163808", "0.6160201", "0.6157782", "0.61402357", "0.6105127", "0.6100224", "0.6093228", "0.60874784", "0.60638565", "0.60546505", "0.6050681", "0.60470146", "0.60415834", "0.60404545", "0.6040364", "0.59917665", "0.59913707", "0.5983183", "0.5976103", "0.5971194", "0.59649444", "0.59642905", "0.59525317", "0.5952434", "0.5951439", "0.5943219", "0.59350556", "0.59140915", "0.5912521", "0.59113264", "0.589994", "0.58976406", "0.5882138", "0.58812857", "0.58782494", "0.5874348", "0.5874128", "0.5873521", "0.5873521" ]
0.66554576
17
uploads the image into the database under the file named images
private void putImageInStorage() { final StorageReference ref = storageReference.child("images/" + java.util.UUID.randomUUID().toString()); ref.putFile(filePath) .addOnSuccessListener(new OnSuccessListener<UploadTask.TaskSnapshot>() { @Override public void onSuccess(UploadTask.TaskSnapshot taskSnapshot) { if (taskSnapshot.getMetadata() != null) { if (taskSnapshot.getMetadata().getReference() != null) { Task<Uri> result = taskSnapshot.getStorage().getDownloadUrl(); result.addOnSuccessListener(new OnSuccessListener<Uri>() { @Override public void onSuccess(Uri uri) { imageUrl = uri.toString(); ChatMessage Message = new ChatMessage(null, mUsername, imageUrl, dateAndTime); mFirebaseDatabaseReference.child(CHATS_PATH + chatCode) .push().setValue(Message); } }); } } } }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void store_image(Images image) {\n\t\tir.save(image);\n\t}", "void savePicturePath(String userName, String picturePath) throws DatabaseException;", "public void setImageName(String name) {\n imageToInsert = name;\n}", "protected void processRequest(HttpServletRequest request, HttpServletResponse response)\n\nthrows ServletException, IOException {\n\nresponse.setContentType(\"text/html;charset=UTF-8\");\n\ntry (PrintWriter out = response.getWriter()) {\n\n// this tyr is created by me for the connection of database\n\ntry {\n\n// this is the path provide by me to save the image\n\nString savePath = \"C:\\\\Users\\\\Ratnesh Pandey\\\\eclipse-workspace\\\\kw\\\\WebContent\\\\images\" + File.separator + SAVE_DIR;\n\n/*in place of C: you can place a path where you need to save the image*/\n\n// this comment will pickup the image file and have convert it into file type\n\nFile fileSaveDir = new File(savePath);\n\nif (!fileSaveDir.exists()) {\n\nfileSaveDir.mkdir();\n\n}\n\n// this two comment will take the name and image form web page\n\nString userid= request.getParameter(\"userid\");\nString Heading= request.getParameter(\"Heading\");\nString content = request.getParameter(\"content\");\nPart part = request.getPart(\"file\");\n\n// this comment will extract the file name of image\n\nString fileName = extractFileName(part);\n\n// this will print the image name and user provide name\n\n/*out.println(fileName);\n\nout.println(\"\\n\" + userid);*/\n\n/*if you may have more than one files with same name then you can calculate\n\nsome random characters and append that characters in fileName so that it will\n\nmake your each image name identical.*/\n\npart.write(savePath + File.separator + fileName);\n\n/*\n\nYou need this loop if you submitted more than one file\n\nfor (Part part : request.getParts()) {\n\nString fileName = extractFileName(part);\n\npart.write(savePath + File.separator + fileName);\n\n}*/\n\n// connection to database\n\nClass.forName(\"com.mysql.jdbc.Driver\");\n\nConnection con = DriverManager.getConnection(\"jdbc:mysql://localhost:3306/users\", \"root\", \"speedoflightis3x108\");\n\n// query to insert name and image name\n\nString query = \"INSERT INTO users.contribution(userid,Heading,content,photourl) values (?, ?, ?, ?)\";\n\nPreparedStatement pst;\n\npst = con.prepareStatement(query);\n\npst.setString(1, userid);\npst.setString(2, Heading);\npst.setString(3, content);\n\nString filePath = savePath + File.separator + fileName;\n\npst.setString(4, filePath);\n\npst.executeUpdate();\nresponse.sendRedirect(\"Home(ak).jsp\");\n\n} catch (Exception ex) {\n\nout.println(\"error\" + ex);\n\n}\n\n}\n\n}", "@Override\n protected void doPost(HttpServletRequest request, HttpServletResponse response)\n throws ServletException, IOException {\n\n String savePath = request.getServletContext().getRealPath(\"/\") + \"images\";\n File fileSaveDir=new File(savePath);\n if(!fileSaveDir.exists()){\n fileSaveDir.mkdir();\n }\n\n \n Part imagePart = request.getPart(\"photo\");\n String fileName = extractFileName(imagePart);\n String fileLocalPath = File.separator + fileName;\n imagePart.write(savePath + fileLocalPath);\n String description = request.getParameter(\"description\");\n \n Conexion c=new Conexion();\n Connection con=c.getConexion();\n CallableStatement cs = null;\n \n try{\n String query = \"call sp_pv_insertPost(?,?,1)\";\n cs = con.prepareCall(query);\n cs.setString(1, fileLocalPath);\n cs.setString(2, description);\n cs.execute(); \n }catch(SQLException e){\n e.printStackTrace();\n }finally{\n BDUtil.cerrarStatement(cs);\n c.cerrarConexion();\n }\n \n response.setContentType(\"text/plain\"); \n response.setCharacterEncoding(\"UTF-8\");\n response.getWriter().write(\"success\"); \n \n }", "void save(Images image);", "public void uploadFile() {\n \n InputStream input = null;\n try {\n input = file.getInputStream();\n System.out.println(\"chay qua inpustream\");\n String itemName = file.getSubmittedFileName();\n String filename = itemName.substring(\n itemName.lastIndexOf(\"\\\\\") + 1);\n String dirPath = FacesContext.getCurrentInstance().getExternalContext().getRealPath(\"/upload/images\");\n fileNamed = \"/upload/images/\"+filename;\n File f = new File(dirPath + \"\\\\\" + filename);\n if (!f.exists()) {\n f.createNewFile();\n }\n FileOutputStream output = new FileOutputStream(f);\n byte[] buffer = new byte[1024];\n int length;\n while ((length = input.read(buffer)) > 0) {\n output.write(buffer, 0, length);\n }\n // resize(dirPath + \"\\\\\" + filename, dirPath + \"\\\\\" + filename, 200, 200);\n input.close();\n output.close();\n } catch (IOException ex) {\n System.out.println(\"loi io\");\n Logger.getLogger(ArtistsManagedBean.class.getName()).log(Level.SEVERE, null, ex);\n }\n \n }", "protected void processRequest(HttpServletRequest request, HttpServletResponse response)\n throws ServletException, IOException {\n PrintWriter out = response.getWriter();\n response.setContentType(\"text/html;charset=UTF-8\");\n try{\n \n \n out.println(\"fsa\");\n \n Part filePart = request.getPart(\"file\");\n InputStream in=filePart.getInputStream();\n OutputStream ot=new FileOutputStream(new File(\"D:/database.png\"));\n int read = 0;\n final byte[] bytes = new byte[1024];\n\n while ((read = in.read(bytes)) != -1) {\n ot.write(bytes, 0, read);\n }\n\nin.close();\n\not.close();\n \n \n \n String url = \"jdbc:mysql://localhost:3306/organizer\";\n String user = \"root\";\n String password = \"hatim\";\n \n \n Class.forName(\"com.mysql.jdbc.Driver\");\n File f=new File(\"D:/database.png\");\n in=new FileInputStream(f);\n\n\n Connection conn = DriverManager.getConnection(url, user, password);\n PreparedStatement statement=null; \n \n statement = conn.prepareStatement(\"insert into organizer_detail values(?,?,?,?,?,?,?,?,?,?)\");\n statement.setString(1,request.getParameter(\"OrgName\"));\n statement.setString(2,request.getParameter(\"UserId\"));\n statement.setString(3,request.getParameter(\"Password\"));\n statement.setString(4,request.getParameter(\"Email_Id\"));\n statement.setString(5,request.getParameter(\"Address\"));\n statement.setBinaryStream(6,in,(int)f.length());\n statement.setInt(7,Integer.parseInt(request.getParameter(\"Phone_No\")));\n\n statement.setString(8,request.getParameter(\"City\"));\n statement.setString(9,request.getParameter(\"Country\"));\nstatement.setInt(10,23424);\n\nstatement.executeUpdate();\n\n response.sendRedirect(\"success.jsp\");\n }catch(Exception e)\n {\n \n response.sendRedirect(\"success.jsp\");\n }\n \n }", "public void addPicture() {\n FileChooser chooser = new FileChooser();\n chooser.setTitle(\"Upload your pic for this post\");\n file = chooser.showOpenDialog(null);\n if (file != null) {\n\n Image profilePicImage = new Image(file.toURI().toString());\n try {\n this.postPic = new FileInputStream(file).readAllBytes();\n } catch (IOException ioException) {\n ioException.printStackTrace();\n }\n postImage.setImage(profilePicImage);\n }\n }", "@PostMapping(\"/tasks/{id}/images\")\n public RedirectView addImages(@PathVariable UUID id, @RequestParam(value=\"file\")MultipartFile file){\n Task selectedTask = taskRepository.findById(id).get();\n List<String> pic = this.s3Client.uploadFile(file);\n //saving images and thumbImg\n selectedTask.setImages(pic.get(0));\n selectedTask.setThumbImg(pic.get(1));\n\n taskRepository.save(selectedTask);\n return new RedirectView(\"http://taskmaster1.s3-website-us-west-2.amazonaws.com/\");\n }", "public void writeImage(File file, String id) {\n try {\n FileInputStream in = new FileInputStream(file);\n PreparedStatement pstmt = conn.prepareStatement(\n \"UPDATE vehicles vehicles SET photo=? WHERE veh_reg_no = ?\");\n pstmt.setBinaryStream(1, (InputStream)in, (int)file.length());\n pstmt.setString(2, id);\n System.out.println(pstmt); // for debugging\n int returnCode = pstmt.executeUpdate();\n System.out.println(returnCode + \" record updated\");\n } catch (Exception ex) {\n ex.printStackTrace();\n }\n }", "public void saveImage(MultipartFile imageFile) throws IOException {\n\t\tlogger.info(\"ComicDetail ID is \"+imageFile.getOriginalFilename());\r\n\t\tString folder=\"/images/comiccover\";\r\n\t\tbyte[] bytes = imageFile.getBytes();\r\n\t\tlogger.info(\"ComicDetail ID is \"+imageFile.getOriginalFilename());\r\n\t\t//Path path = Paths.get(folder+imageFile.getOriginalFilename());\r\n\t\r\n\t\t//Files.write(path, bytes);\r\n\t}", "private static void writeBLOBData() {\n\t\tConnection conn = null;\n\t\tPreparedStatement stmt = null;\n\t\ttry {\n\t\t\tconn = JDBCUtils.getMySQLConnection();\n\t\t\tString sql = \"INSERT INTO testblob(name, img) values(?,?)\";\n\t\t\tstmt = conn.prepareStatement(sql);\n\t\t\tstmt.setString(1, \"ke\");\n\t\t\tFile file = new File(\"D:\" + File.separator + \"test.jpg\");\n\t\t\tInputStream in = new FileInputStream(file);\n\t\t\tstmt.setBinaryStream(2, in, (int)file.length());\n\t\t\tstmt.executeUpdate();\n\t\t}\n\t\tcatch(Exception e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\tfinally {\n\t\t\tJDBCUtils.release(stmt, conn);\n\t\t}\n\t}", "@Override\n protected void doPost(HttpServletRequest request, HttpServletResponse response)\n throws ServletException, IOException {\n Part fpart = request.getPart(\"pic\");\n InputStream ips = null;\n if(fpart!=null){\n System.out.println(fpart.getName());\n System.out.println(fpart.getSize());\n System.out.println(fpart.getContentType());\n ips = fpart.getInputStream();}\n\n int catid = Integer.parseInt(request.getParameter(\"catid\"));\n String itemname = request.getParameter(\"itemname\");\n\n \n DbConnection con = new DbConnection();\n try {\n Connection conn = con.connect();\n PreparedStatement pstmnt = conn.prepareStatement(\"INSERT INTO menuitem(img,catId,itemName) VALUES(?,?,?)\");\n pstmnt.setBlob(1, ips);\n pstmnt.setInt(2,catid );\n pstmnt.setString(3, itemname);\n \n int rcode = pstmnt.executeUpdate();\n if(rcode==0){\n System.out.println(\"fail\");\n request.setAttribute(\"msg\", \"Error!!!!!!!!!!\");\n //getServletContext().getRequestDispatcher(\"/login.jsp\").forward(request, response);\n \n RequestDispatcher rd = request.getRequestDispatcher(\"imgdisplay.jsp\");\n rd.forward(request, response);\n }\n else{\n System.out.println(\"success\");\n request.setAttribute(\"msg\", \"Success!!!!!!!!!!\");\n //getServletContext().getRequestDispatcher(\"/homepage.jsp\").forward(request, response);\n request.setAttribute(\"itemname\", itemname);\n RequestDispatcher rd = request.getRequestDispatcher(\"imgdisplay.jsp\");\n rd.forward(request, response);\n } \n }\n catch (SQLException ex) {\n Logger.getLogger(savepic.class.getName()).log(Level.SEVERE, null, ex);\n } catch (ClassNotFoundException ex) {\n Logger.getLogger(savepic.class.getName()).log(Level.SEVERE, null, ex);\n }\n catch(Exception e){System.out.println(e.getMessage());} \n \n \n \n\n }", "void setImageFromFile(File imageFile);", "@Override\n\tpublic void saveImage(Image image) {\n\t\tnew ImageDaoImpl().saveImage(image);\n\t}", "Person addImage(String name, String imagePath);", "public static int storePictureToDB(String imagePath, String userName) {\n System.out.println(\" DB METHOD CALLED image path: \" + imagePath +\" userName : \"+userName);\n try {\n Class.forName(\"org.apache.derby.jdbc.ClientDriver\");\n } catch (ClassNotFoundException e) {\n System.err.println(e.getMessage());\n System.exit(0);\n }\n int rowCount = 0;\n //create connection to database and create query string\n try {\n String myDB = \"jdbc:derby://localhost:1527/LinkedUDB\";\n Connection DBConn = DriverManager.getConnection(myDB, \"itkstu\", \"student\");\n\n String insertString = \"UPDATE itkstu.userlogin SET PROFILEPICTURE = '\" + imagePath + \"' WHERE LOWER(USERNAME) = '\" + userName + \"'\";\n Statement stmt = DBConn.createStatement();\n \n // if insert is successful, rowCount will be set to 1 (1 row inserted successfully). Else, insert failed.\n rowCount = stmt.executeUpdate(insertString);\n\n } catch (SQLException e) {\n System.err.println(e.getMessage());\n }\n return rowCount;\n\n }", "@Override\r\n\tpublic FileImage save(FileImage fileImage) {\n\t\treturn fileImageDao.save(fileImage);\r\n\t}", "private void doUpload(Part img1, String image) throws IOException{\n OutputStream out = null;\n InputStream filecontent = null;\n try {\n out = new FileOutputStream(new File(path \n + image));\n System.out.println(path \n + image);\n filecontent = img1.getInputStream();\n\n int read = 0;\n final byte[] bytes = new byte[1024];\n\n while ((read = filecontent.read(bytes)) != -1) {\n out.write(bytes, 0, read);\n }\n \n } catch (Exception fne) {\n System.out.println(\"You either did not specify a file to upload or are \"\n + \"trying to upload a file to a protected or nonexistent \"\n + \"location.\");\n fne.printStackTrace();\n\n } finally {\n if (out != null) {\n out.close();\n }\n if (filecontent != null) {\n filecontent.close();\n }\n }\n }", "@Override\n protected void doPost(HttpServletRequest request, HttpServletResponse response)\n throws ServletException, IOException {\n int geekid = Integer.parseInt(request.getParameter(\"geekid\"));\n if (ServletFileUpload.isMultipartContent(request)) {\n try {\n\n List<FileItem> multiparts = new ServletFileUpload(new DiskFileItemFactory()).parseRequest(request);\n\n for (FileItem item : multiparts) {\n\n if (!item.isFormField()) {\n item.write(new File(UPLOAD_DIRECTORY + File.separator + \"image\" + geekid + \".jpg\"));\n\n }\n \n String fileName = UPLOAD_DIRECTORY + File.separator + \"image\" + geekid + \".jpg\";\n\n }\n\n //File uploaded successfully\n request.setAttribute(\"message\", \"File Uploaded Successfully\");\n\n } catch (Exception ex) {\n\n request.setAttribute(\"message\", \"File Upload Failed due to \" + ex);\n\n }\n\n } else {\n\n request.setAttribute(\"message\",\n \"Sorry this Servlet only handles file upload request\");\n\n }\n\n request.getRequestDispatcher(\"/result.jsp\").forward(request, response);\n\n }", "private void uploadImage() {\n FileChooser fileChooser = new FileChooser();\n\n //Extension de l'image\n FileChooser.ExtensionFilter extFilter = new FileChooser.ExtensionFilter(\"Fichier image\", \"*.*\");\n fileChooser.getExtensionFilters().addAll(extFilter);\n\n File file = fileChooser.showOpenDialog(null);\n\n try {\n BufferedImage bufferedImage = ImageIO.read(file);\n Image image = SwingFXUtils.toFXImage(bufferedImage, null);\n imageViewAvatar.setImage(image);\n getUser().setAvatar(image);\n\n } catch (IOException e) {\n e.printStackTrace();\n }\n }", "@RequestMapping(value = \"/upload\", method = RequestMethod.POST)\n // defining the upload\n public String uploadFile(@RequestParam(\"title\") String title,\n @RequestParam(\"description\") String description,\n @RequestParam(\"file\") MultipartFile file,\n @RequestParam(\"tags\") String tags,\n HttpSession session) throws IOException {\n\n User currUser = (User) session.getAttribute(\"currUser\");\n\n if(currUser == null ){\n return \"redirect:/\";\n }\n\n else {\n List<Tag> imageTags = findOrCreateTags(tags);\n // creating an id of the image\n Long imageId = createId();\n // uploading the image and converting it to a base64 encoded version of the image\n String uploadedImageData = convertUploadedFileToBase64(file);\n Image newImage = new Image(imageId, title, description, uploadedImageData, currUser, imageTags);\n // storing the new image\n imageService.save(newImage);\n // after upload is successful, redirect the user to the home page\n return \"redirect:/home\";\n }\n }", "public TestImageBLOB() {\n // Setup database connection\n try {\n conn = DriverManager.getConnection(\n \"jdbc:mysql://localhost:8888/rental_db\", \"myuser\", \"xxxx\");\n } catch(SQLException ex) {\n ex.printStackTrace();\n }\n \n // Setup GUI\n this.setLayout(new BorderLayout());\n pnlRead = new JPanel();\n this.add(pnlRead, BorderLayout.NORTH); // Top panel for read image\n pnlWrite = new JPanel();\n this.add(pnlWrite, BorderLayout.SOUTH); // Bottom panel for write image\n \n pnlRead.add(new JLabel(\"Read Image for Vehicle No:\"));\n tfIDRead = new JTextField(\"SBA1111A\", 10);\n pnlRead.add(tfIDRead);\n btnRead = new JButton(\"Read Image\");\n pnlRead.add(btnRead);\n btnRead.addActionListener(new ActionListener() {\n public void actionPerformed(ActionEvent e) {\n // Read image from database for the selected ID\n img = readImage(tfIDRead.getText());\n repaint();\n }\n });\n \n pnlWrite.add(new JLabel(\"Write Image for Vehicle No:\"));\n tfIDWrite = new JTextField(\"GA5555E\", 10);\n pnlWrite.add(tfIDWrite);\n \n btnWrite = new JButton(\"Select Image\");\n btnWrite.addActionListener(new ActionListener() {\n public void actionPerformed(ActionEvent e) {\n JFileChooser chooser = new JFileChooser();\n int returnCode = chooser.showOpenDialog(null);\n File file = null;\n if (returnCode == JFileChooser.APPROVE_OPTION) {\n file = chooser.getSelectedFile(); // Path to image\n // Insert image into database for the selected ID\n writeImage(file, tfIDWrite.getText());\n // Show confirmation message (need to check result)\n JOptionPane.showMessageDialog(TestImageBLOB.this,\n \"Image inserted.\", \"ImageDemo\",\n JOptionPane.PLAIN_MESSAGE);\n }\n }\n });\n pnlWrite.add(btnWrite);\n }", "public void createRecipeImage(FileUploadEvent event) {\r\n Image newImage = new Image();\r\n String destination = FacesContext.getCurrentInstance().getExternalContext().getRealPath(\"/\");\r\n String getParam = qm.get(\"recipeId\");\r\n Integer recipeID = Integer.parseInt(getParam);\r\n this.recipe = recipesEJB.findRecipe(recipeID);\r\n File file = new File(destination+\"uploads\"+File.separator+\"recipe\"+File.separator+recipeID);\r\n String abspath = file.getAbsolutePath()+ File.separator;\r\n if(!file.exists()){\r\n if(file.mkdirs());\r\n }\r\n //new name of the image\r\n List <Image> recipeImages = this.recipe.getImageGallery();\r\n Integer count = recipeImages.size();\r\n\r\n if(this.recipe.getImageGallery().get(0).getImagePath().equalsIgnoreCase(\"/resources/images/recipe_placeholder.png\") && count == 1){\r\n imageEJB.removeImage(this.recipe.getImageGallery().get(0));\r\n this.recipe.getImageGallery().remove(0);\r\n }else {\r\n count++;\r\n }\r\n String newImageName;\r\n if (event.getFile().getContentType().equalsIgnoreCase(\"image/jpeg\")) {\r\n newImageName = count + \".jpeg\";\r\n } else if (event.getFile().getContentType().equalsIgnoreCase(\"image/gif\")) {\r\n newImageName = count + \".gif\";\r\n } else {\r\n newImageName = count + \".png\";\r\n }\r\n // Do what you want with the file \r\n String newImagePath = \"/uploads/recipe/\"+recipeID+\"/\"+newImageName;\r\n try {\r\n copyFile(abspath,newImageName, event.getFile().getInputstream()); \r\n newImage = this.imageEJB.createImage(newImage);\r\n newImage.setCaption(\"This is the \"+this.recipe.getRecipeName()+\"'s recipe picture.\");\r\n newImage.setDescription(newImageName);\r\n newImage.setRecipe(this.recipe);\r\n newImage.setImagePath(newImagePath);\r\n newImage.setImageName(newImageName);\r\n newImage = this.imageEJB.editImage(newImage);\r\n this.recipe.getImageGallery().add(newImage);\r\n this.recipe = recipesEJB.editRecipe(recipe);\r\n FacesContext.getCurrentInstance().addMessage(null, new FacesMessage(\"Success!\", \"Your image was uploaded successfully.\"));\r\n } catch (IOException e) {\r\n e.printStackTrace();\r\n }\r\n }", "public com.agbar.service.model.ImgImportadas create(long imageId);", "public void upload(FileUploadEvent event) {\r\n\t\tUploadedFile uploadFile = event.getFile();\r\n\t\t// Recuperer le contenu de l'image en byte array (pixels)\r\n\t\tbyte[] contents = uploadFile.getContents();\r\n\t\tSystem.out.println(\"---------------- \" + contents);\r\n\t\tproduit.setPhoto(contents);\r\n\t\t// Transforme byte array en string (format basé64)\r\n\t\timage = \"data:image/png;base64,\" + Base64.encodeBase64String(produit.getPhoto());\r\n\t\t\r\n\t}", "public void uploadPictureToParkById(int id, MultipartFile multipartFile, boolean enablePublicReadAccess) {\n Optional<DogPark> dogPark = dogParkRepository.findById(id);\n\n if (dogPark.isPresent()) {\n\n //Create a new image to store the URL of the file that is being created\n Image image = new Image();\n\n //Creating the file\n String fileName = multipartFile.getOriginalFilename();\n\n try {\n //creating the file in the server (temporarily)\n File file = new File(fileName);\n FileOutputStream fos = new FileOutputStream(file);\n fos.write(multipartFile.getBytes());\n fos.close();\n\n for (int i = -1; i < dogPark.get().getImages().size(); i++) {\n\n if (i == dogPark.get().getImages().size() - 1) {\n fileName = dogPark.get().getName() + \"/\" + dogPark.get().getName() + (i + 1) + \".\" + FilenameUtils.getExtension(fileName);\n }\n }\n\n //Set the URL to the new image and connect with the correct dog park and save it to the repository\n image.setUrl(\"https://dogparks.s3.amazonaws.com/\" + fileName);\n image.setDogpark(dogPark.get());\n imageRepository.save(image);\n\n //Add the image to the dog park\n dogPark.get().getImages().add(image);\n\n PutObjectRequest putObjectReqeust = new PutObjectRequest(this.awsS3AudioBucket, fileName, file);\n\n if (enablePublicReadAccess) {\n putObjectReqeust.withCannedAcl(CannedAccessControlList.PublicRead);\n }\n\n this.amazonS3.putObject(putObjectReqeust);\n\n } catch (IOException | AmazonServiceException ex) {\n logger.error(\"error [\" + ex.getMessage() + \"] occurred while uploading [\" + fileName + \"] \");\n }\n }\n else {\n throw new DogParkNotFoundException();\n }\n }", "private void saveImageInstantly() {\n\n if (movie != null) {\n\n // Get movie's title and set an initial file name\n String movieTitle = movie.getMovieTitle();\n\n // Replace any invalid characters\n movieTitle = movieTitle.replaceAll(\"[\\\"/?\\\"*><|]\", \"\").replace(\":\", \"-\");\n\n // If preferences file is empty\n if (userDirectoryString.equals(\"empty\")) {\n\n userDirectoryString = System.getProperty(\"user.home\");\n }\n\n File userDirectory = new File(userDirectoryString + \"/\" + movieTitle + \".jpg\");\n\n // If it can't access User Home, default to C drive\n if (!userDirectory.getParentFile().canRead()) {\n userDirectory = new File(\"D:\\\\\" + movieTitle + \".jpg\");\n }\n\n // Check file isn't null, so it the image view\n if (imgPoster.getImage() != null) {\n\n try {\n\n ImageIO.write(SwingFXUtils.fromFXImage(imgPoster.getImage(), null), \"jpg\", userDirectory);\n setLblStatus(\"Poster saved successfully.\");\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n }\n }", "@Override\n\tpublic void run(String... args) throws Exception {\n\t\timageDAO.save(new Image(\"imag1\",\"www.ex.com/image1\"));\n\t\timageDAO.save(new Image(\"imag2\",\"www.ex.com/image2\"));\n\t\timageDAO.save(new Image(\"imag3\",\"www.ex.com/image3\"));\n\t\timageDAO.save(new Image(\"imag4\",\"www.ex.com/image4\"));\n\t}", "public void crearRutaImgPublicacion(){\n \n servletContext=(ServletContext) contexto.getExternalContext().getContext();\n String ruta=\"\";\n //Ruta real hasta la carpeta uploads\n ruta=servletContext.getRealPath(\"/upload/\");\n //Obtener el codigo del usuario de la sesion actual\n //este es utilizado para ubicar la carpeta que le eprtenece\n String codUsuario=String.valueOf(new SessionLogica().obtenerUsuarioSession().getCodUsuario());\n //Concatenamiento de directorios internos\n ruta+=File.separatorChar+\"img\"+File.separatorChar+\"post\"+File.separatorChar+codUsuario+File.separatorChar+\"all\"+File.separatorChar;\n //Asignacion de la ruta creada\n this.rutaImgPublicacion=ruta;\n }", "IbeisImage uploadImage(File image) throws UnsupportedImageFileTypeException, IOException, MalformedHttpRequestException,\n UnsuccessfulHttpRequestException;", "public ImageFile saveImageFile(ImageFile imagedata){\n //int imageID;\n Session session = sessionFactory.openSession();\n // try to save data\n try{\n session.beginTransaction();\n \n session.save(imagedata);\n \n session.getTransaction().commit();\n session.flush();\n }\n catch (HibernateException e) {\n e.printStackTrace();\n return null;\n } \n finally { session.close(); }\n \n // Return imageID if image is saved\n return imagedata;\n }", "public Image addPostImage(Vendor vendor,Post post, MultipartFile file) {\n //1. check if image is not empty\n isFileEmpty(file);\n //2. if file is an image\n isImage(file);\n //3. grab metadata if any\n Map<String, String> metadata = extractMetadata(file);\n //4. create new Image entity\n Image image= new Image(vendor,post,null);\n imageRepository.save(image);\n\n //5. store image in s3 & update database (userProfileImageLink) with s3 image link\n String path = String.format(\"%s/postImages/%s/%s\", BucketName.PROFILE_IMAGE.getBucketName(),\n post.getPostId(),\n image.getImageId());\n String filename = String.format(\"%s-%s\", file.getOriginalFilename(), UUID.randomUUID());\n try {\n profileImageFileStore.save(path, filename, Optional.of(metadata), file.getInputStream());\n image.setPostImageLink(filename);\n imageRepository.save(image);\n return image;\n } catch ( IOException e){\n imageRepository.delete(image);\n throw new IllegalStateException(e);\n }\n\n }", "public void uploadImage() {\n if (imgPath != null && !imgPath.isEmpty()) {\n //prgDialog.setMessage(\"Converting Image to Binary Data\");\n //prgDialog.show();\n // Convert image to String using Base64\n new EncodeImageToStringTask().execute();\n // When Image is not selected from Gallery\n } else {\n //Toast.makeText(\n // getApplicationContext(),\n // \"You must select image from gallery before you try to upload\",\n // Toast.LENGTH_LONG).show();\n }\n }", "public void upload() {\r\n if (file != null) {\r\n try {\r\n String filepath = super.getUploadFolder() + \"/\" + file.getFileName();\r\n filepath = FileUtil.alternativeFilepathIfExists(filepath);\r\n FileUtil.createFile(filepath);\r\n\r\n file.write(filepath);\r\n super.info(\"Succesful\", file.getFileName() + \" is uploaded.\");\r\n\r\n Upload upload = new Upload();\r\n upload.setDescription(description);\r\n upload.setFilepath(filepath);\r\n upload.setTag(Md5Util.getMd5Sum(filepath));\r\n this.description = null;\r\n uploads.add(upload);\r\n // update ui and ready for save in db\r\n } catch (Exception e) {\r\n System.out.println(e);\r\n }\r\n }\r\n }", "public void upload(FileUploadEvent event){\n UploadedFile file = event.getFile();\n if(file != null){\n try {\n imagePic = new OracleSerialBlob(file.getContents());\n Long size = imagePic.length();\n putProfPic(imagePic);\n //setPhoto_profile(new ByteArrayContent(imagePic.getBytes(1, size.intValue())));\n } catch (SQLException ex) {\n LOG.error(ex);\n GBMessage.putErrorMessage(\"Error al subir el archivo\");\n } catch (IOException ex) {\n Logger.getLogger(StaffBean.class.getName()).log(Level.SEVERE, null, ex);\n }\n GBMessage.putInfoMessage(\"Carga correcta\");\n }\n }", "@RequestMapping(value = \"view/{menuId}\", method = RequestMethod.POST)\n public String imageupload(Model model, @PathVariable int menuId, @RequestParam(\"uploadFile\") MultipartFile uploadFile,\n RedirectAttributes redirectAttributes) {\n\n\n\n Menu menu = menuDao.findOne(menuId);\n model.addAttribute(\"title\", menu.getName());\n model.addAttribute(\"cheeses\", menu.getCheeses());\n model.addAttribute(\"menuId\", menu.getId());\n //add photo upload coding here.\n\n //need to get the file into the input stream.\n //String filename = uploadFile.toString();\n //uploadFile.getOriginalFilename();\n //File filename = new FileInputStream(uploadFile1);\n //String uploadFilename = uploadFile.getOriginalFilename();\n //Session session = sessionFactory.getSessionFactory().getCurrentSession();\n //File uploadfile = new File(uploadfile);\n //Blob fileblob = Hibernate.getLobCreator(session).createBlob(filename.getBytes()); //new FileInputStream(uploadfile), file1.length()\n\n //model.addAttribute(\"imagefile\",uploadFile.getOriginalFilename());\n //System.out.println(\"File is:\" + uploadfile.getOriginalFilename());\n\n return \"\";\n }", "List<IbeisImage> uploadImages(List<File> images) throws UnsupportedImageFileTypeException, IOException,\n MalformedHttpRequestException, UnsuccessfulHttpRequestException;", "void saveImage(List<Elements> elements, int numOfArticles) throws IOException {\r\n //For simplicity, exceptions are not caught...\r\n URL url = null;\r\n HttpURLConnection conn = null;\r\n InputStream reader = null;\r\n FileOutputStream writer = null;\r\n byte[] buffer = null;\r\n\r\n for (int i = 0; i < numOfArticles; i++) {\r\n String urlName = elements.get(0).get(i).attr(\"src\");\r\n url = new URL(urlName);\r\n conn = (HttpURLConnection) url.openConnection();\r\n conn.setRequestProperty(\"User-Agent\", \"\");\r\n\r\n String imageName = url.getFile();\r\n imageName = imageName.substring(imageName.lastIndexOf(\"/\") + 1);\r\n\r\n reader = conn.getInputStream();\r\n writer = new FileOutputStream(new File(imageName));\r\n buffer = new byte[BUFFER_SIZE];\r\n int bytesRead = 0;\r\n while ((bytesRead = reader.read(buffer)) != -1) {\r\n writer.write(buffer, 0, bytesRead);\r\n }\r\n }\r\n if (writer != null) {\r\n writer.close();\r\n }\r\n if (reader != null) {\r\n reader.close();\r\n }\r\n }", "public void upload(UploadedFile file) {\n FacesContext faces = FacesContext.getCurrentInstance();\n\n getSelected().setUrlImage(file.getFileName());\n String fileExtension = file.getFileName().split(\"\\\\.\")[file.getFileName().split(\"\\\\.\").length - 1];\n\n //String generatedFileName = \"file\" + System.currentTimeMillis();\n File directory = new File(faces.getExternalContext().getRealPath(UPLOAD_DIRECTORY_IMAGE_RELATIVE));\n\n if (!directory.exists()) {\n directory.mkdir();\n }\n\n File newFile = new File(faces.getExternalContext().getRealPath(UPLOAD_DIRECTORY_IMAGE_RELATIVE) + File.separator + file.getFileName());\n try {\n if (!newFile.createNewFile()) {\n String nameGenerated = \"file_generated\" + System.currentTimeMillis();\n newFile = new File(faces.getExternalContext().getRealPath(UPLOAD_DIRECTORY_IMAGE_RELATIVE) + File.separator + nameGenerated + \".\" + fileExtension);\n getSelected().setUrlImage(nameGenerated);\n }\n\n FileOutputStream output = new FileOutputStream(newFile);\n\n byte[] buffer = new byte[BUFFER];\n\n int bulk;\n\n InputStream input = file.getInputstream();\n\n while (true) {\n bulk = input.read(buffer);\n\n if (bulk < 0) {\n break;\n }\n\n output.write(buffer, 0, bulk);\n output.flush();\n }\n\n output.close();\n input.close();\n\n } catch (Exception ex) {\n ex.printStackTrace();\n FacesContext.getCurrentInstance().addMessage(\"\", new FacesMessage(bundle.getString(\"Error_file_created\")));\n }\n\n }", "public interface ImageService {\n\n void saveImageFile(Long recipeId, MultipartFile imageFile);\n}", "public void uploadImage() {\n\t\tif (fileChooser.showOpenDialog(btnUploadImage) == JFileChooser.APPROVE_OPTION)\n\t\t\t;\n\n\t\tfileChooser.addChoosableFileFilter(new FileNameExtensionFilter(\"Images\", \"jpg\", \"png\", \"gif\", \"bmp\"));\n\t\tif (fileChooser.getSelectedFile() != null) {\n\t\t\timage = new ImageIcon(fileChooser.getSelectedFile().getAbsolutePath());\n\t\t\t// Resize image to 100x100\n\t\t\timg = image.getImage();\n\t\t\tImage newimg = img.getScaledInstance(100, 100, java.awt.Image.SCALE_SMOOTH);\n\t\t\timage = new ImageIcon(newimg);\n\t\t}\n\t}", "public void onClick(View v) {\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_OPEN_DOCUMENT);\n startActivityForResult(Intent.createChooser(intent, \"Select Picture\"), PICK_IMAGE);\n\n\n\n\n /*String stringFilePath = Environment.getExternalStorageDirectory().getPath()+\"/Download/\"+editText.getText().toString()+\".jpeg\";\n Bitmap bitmap = BitmapFactory.decodeFile(stringFilePath);\n ByteArrayOutputStream byteArrayOutputStream = new ByteArrayOutputStream();\n bitmap.compress(Bitmap.CompressFormat.PNG, 0, byteArrayOutputStream);\n byte[] bytesImage = byteArrayOutputStream.toByteArray();\n db.addTicket(stringFilePath, bytesImage);*/\n\n }", "@RequestMapping(value = {\"/register\"}, method = RequestMethod.POST)\r\n public String registerUser(@Valid FileBucket fileBucket, BindingResult result,\r\n ModelMap model, HttpServletRequest req) {\r\n\r\n MultipartFile[] files = fileBucket.getFiles();\r\n String originalImgPath = \"\";\r\n String resizedImgPath = \"\";\r\n //String serverFileName = \"\";\r\n String photoName = \"\";\r\n String itemViewName = \"\";\r\n String imgLocation = \"\";\r\n int width = 580;\r\n int height = 450;\r\n boolean saved = false;\r\n String serverFileName = \"\";\r\n\r\n FileBucket fb = new FileBucket();\r\n User user = new User();\r\n if (result.hasErrors()) {\r\n return \"registration\";\r\n }\r\n if (files != null && files.length > 0) {\r\n for (int i = 0; i < files.length; i++) {\r\n try {\r\n\r\n byte[] bytes = null;\r\n // Creating the directory to store file\r\n String rootPath = System.getProperty(\"catalina.home\");\r\n File dir = new File(rootPath + File.separator + \"tmpFiles\");\r\n if (!dir.exists()) {\r\n dir.mkdirs();\r\n }\r\n\r\n FilenameUtils fileUTIL = new FilenameUtils();\r\n\r\n String path = req.getServletContext().getRealPath(\"/image\");\r\n //String ext = fileUTIL.getExtension(file.getOriginalFilename());\r\n //String baseName = fileUTIL.getBaseName(file.getOriginalFilename());\r\n\r\n imgLocation = dir + File.separator;\r\n // get files name in the array\r\n if (i == 0) {\r\n photoName = files[i].getOriginalFilename();\r\n bytes = files[i].getBytes();\r\n serverFileName = imgLocation + photoName;\r\n System.out.println(\"photoName:: \" + photoName);\r\n } else if (i == 1) {\r\n itemViewName = files[i].getOriginalFilename();\r\n bytes = files[i].getBytes();\r\n serverFileName = imgLocation + itemViewName;\r\n System.out.println(\"itemViewName:: \" + itemViewName);\r\n }\r\n\r\n System.out.println(\"serverFileName :: \" + serverFileName);\r\n\r\n // resize image\r\n //utility.resize(originalImgPath, resizedImgPath, width, height);\r\n //create the file on server\r\n File serverFile = new File(serverFileName);\r\n BufferedOutputStream stream = new BufferedOutputStream(\r\n new FileOutputStream(serverFile));\r\n stream.write(bytes);\r\n stream.close();\r\n\r\n } catch (Exception e) {\r\n e.printStackTrace();\r\n }\r\n }\r\n\r\n //System.out.println(\"bytes ::\" + bytes);\r\n user.setFirstName(fileBucket.getFirstName());\r\n user.setLastName(fileBucket.getLastName());\r\n user.setPhoneNumber(fileBucket.getPhoneNumber());\r\n user.setItemView(fileBucket.getItemView());\r\n user.setAddress(fileBucket.getAddress());\r\n user.setPassportPhotograph(photoName);\r\n user.setImgLocation(imgLocation);\r\n user.setImgName(photoName);\r\n user.setImgItemName(itemViewName);\r\n\r\n saved = userService.saveUser(user);\r\n\r\n } else {\r\n System.out.println(\"File is empty / No image uploaded\");\r\n }\r\n\r\n //model.addAttribute(\"user\", user);\r\n model.addAttribute(\"user\", fb);\r\n //model.addAttribute(\"success\", \"User \" + user.getFirstName() + \" \" + user.getLastName() + \" saved successfully\");\r\n //model.addAttribute(\"saved\", saved);\r\n\r\n //return \"adduser\";\r\n //return \"redirect:/adduser\";\r\n return \"redirect:/register\";\r\n }", "public void saveImage(){\n fixMediaDir(); // fixes bug in Android 4.4\n\n // name file eSketch + timestamp\n final String filename = \"eSketch\" + System.currentTimeMillis() + \".jpg\";\n\n // insert image on the device\n String location = MediaStore.Images.Media.insertImage(\n getContext().getContentResolver(), mBitmap, filename, \"eSketch Drawing\"\n );\n\n if( location != null ){\n // notify user image was saved successfully\n Toast msg = Toast.makeText( getContext(), R.string.message_saved, Toast.LENGTH_SHORT);\n msg.setGravity(Gravity.CENTER, msg.getXOffset()/2, msg.getYOffset()/2);\n msg.show();\n } else {\n // notify user image was NOT saved successfully\n Toast msg = Toast.makeText( getContext(), R.string.message_error_saving, Toast.LENGTH_SHORT);\n msg.setGravity(Gravity.CENTER, msg.getXOffset()/2, msg.getYOffset()/2);\n msg.show();\n }\n }", "@Override\n public void addUserImage(String userName, String path) {\n User user = getUserByName(userName);\n Image image = new Image();\n image.setImagePath(path);\n image.setOwner(user);\n image.setLikeNum(0);\n imageRepository.save(image);\n }", "public static void Bildeinfuegen()\r\n\t{\n\t\tPath path = FileSystems.getDefault().getPath(\"bilder\", \"bild2.jpg\");\r\n\t\tFile file=path.toFile();\r\n\t\t//File file = new File(getCacheDirectory() + \"\\\\results.txt\");\r\n\t\t\r\n\t\tString INSERT_DATA_SQL=\"INSERT INTO bilder VALUES (?, ?)\";\r\n\t\ttry {\r\n\r\n\t\t\tFileInputStream fis= new FileInputStream(file);\r\n\t\t\tconn = DriverManager.getConnection(DB_URL,USER,PASS);\r\n\t\t\tpstmt = conn.prepareStatement(INSERT_DATA_SQL);\r\n\t\t\tfis = new FileInputStream(file);\r\n\t\t\t//pstmt = conn.prepareStatement(\"INSERT INTO bilder VALUES (?, ?)\");\r\n\t\t\tpstmt.setString(1, file.getName());\r\n\t\t\tpstmt.setBinaryStream(2, fis, (int)file.length());\r\n\t\t\tpstmt.executeUpdate();\r\n\r\n\t\t\tpstmt.close();\r\n\t\t\tfis.close();\r\n\t\t} catch (FileNotFoundException e) {\r\n\t\t\t// TODO Auto-generated catch block\r\n\t\t\te.printStackTrace();\r\n\t\t}catch (SQLException e) {\r\n\t\t\te.printStackTrace();\r\n\t\t}catch (IOException e) {\r\n\t\t\t// TODO Auto-generated catch block\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\r\n\t\tSystem.out.println(\"Daten in Datenbank gepeichert.\");\r\n\t}", "public void setImage(String image){\n this.image = image;\n }", "@Override\n public void saveImageFile(Long recipeId, MultipartFile file) {\n log.debug(\"Received a file\");\n\n try {\n Recipe recipe = recipeRepository.findById(recipeId).get();\n\n Byte[] byteObjects = new Byte[file.getBytes().length];\n\n int i = 0;\n\n //transfer MultipartFile to Byte[]\n for (byte b : file.getBytes()){\n byteObjects[i++] = b;\n }\n\n recipe.setImage(byteObjects);\n\n recipeRepository.save(recipe);\n } catch (IOException e) {\n //todo handle better\n log.error(\"Error occurred\", e);\n\n e.printStackTrace();\n }\n }", "public void photoUpload() throws Exception {\n\r\n\t\tString Window=commonUtil.getWindowHandle(driver);\r\n\t\tcommonUtil.switchToWindow(Window, driver);\r\n\r\n\t\t// display picture window \r\n\t\tcommonUtil.clickOnButton(driver, ChangePicture,\"ChangePicture\");\r\n\r\n\r\n\t\t//load picture using robot class\r\n\t\r\n\t\tcommonUtil.LoadFile(driver, prop.getProperty(\"photopath\"));\r\n\t\t//System.out.println(\"photo is loading...\"); \r\n\r\n\t\t\r\n\t\t\r\n\t\t//switch to crop window\r\n\r\n\t\tWindow=commonUtil.getWindowHandle(driver);\r\n\t\tcommonUtil.switchToWindow(Window, driver);\r\n\r\n\r\n\t\t//crop image window \r\n\t\tcommonUtil.clickOnButton(driver, Cropimage,\"CropImage\");\r\n\t\t\r\n\t\t//enter Display name and discription\r\n\t\t\r\n\t\tcommonUtil.enterText(driver, Displaytext, prop.getProperty(\"displayname\"),\"Displayname\");\r\n\t\tcommonUtil.enterText(driver, Discriptiontext, prop.getProperty(\"Address\"),\"Discription\");\r\n\t\t\r\n\t\t//click on save button\r\n\t\t\r\n\t\tcommonUtil.clickOnButton(driver, Save,\"SaveButton\");\r\n\r\n\t\t\r\n\t}", "public void insertIntoDB () throws SQLException\r\n {\r\n Connection conn = null; \r\n PreparedStatement ps = null;\r\n try {\r\n // i have made changes to the databse string and made is online. am uploading again it to github as talked to you. all other code is same.\r\n conn = (Connection) DriverManager.getConnection(\"jdbc:mysql://50.62.177.180:3306/contacts\",\"harman474\", \"Galaxys3neo\");\r\n String sql = \"INSERT into contacts(firstName, lastName, phoneNumber,address, birthday,imageFile)\"\r\n + \"Values (?,?,?,?,?,?)\";\r\n ps = conn.prepareStatement(sql);\r\n \r\n //4. Convert the birthday into a SQL date\r\n Date dob = Date.valueOf(birthday);\r\n // bind the parameters\r\n ps.setString(1, firstName);\r\n ps.setString(2, lastName);\r\n ps.setString(3, phoneNumber);\r\n ps.setString(4,address);\r\n ps.setDate(5, dob);\r\n ps.setString(6, imageFile.getName());\r\n \r\n ps.execute();\r\n }\r\n catch (Exception e)\r\n {\r\n System.err.println(e.getMessage());\r\n }\r\n finally\r\n {\r\n if \r\n (conn != null)\r\n conn.close();\r\n if \r\n (ps != null)\r\n ps.close();\r\n }\r\n \r\n }", "@PostMapping(\"/photos/add\")\r\n\tpublic String addPhoto(@RequestParam(\"title\") String title, @RequestParam(\"image\") MultipartFile image, @RequestParam(\"update\") Optional<String> update, Model model) throws IOException{\n\t\tif(update.isPresent()){\r\n\t\t\tlog.info(String.format(\"Updating photo with title %s\", title));\r\n\t\t\tPhoto toUpdate = photoService.getPhotoByTitle(title);\r\n\t\t\ttoUpdate.setImage(new Binary(BsonBinarySubType.BINARY, image.getBytes()));\r\n\t\t\tphotoService.updatePhoto(toUpdate);\r\n\t\t}else{\r\n\t\t\tlog.info(String.format(\"Uploading new photo with title %s\", title));\r\n\t\t\tphotoService.addPhoto(title, image);\r\n\t\t}\r\n\t\treturn \"redirect:/media/photos/all\";\r\n\t\t/*return \"redirect:/media/photos/\"+id;*/\r\n\t}", "public static void upload_Image(String filePath) {\n\t\tboolean bstatus;\n\n\t\tbstatus = uploadFile1(btn_LiteratureImage, filePath);\n\t\tReporter.log(bstatus, \"Image Slected\", \"Image Not Slected\");\n\n\t}", "public void creaRutaImgPerfil(){\n servletContext=(ServletContext) contexto.getExternalContext().getContext();\n String ruta=\"\";\n //Ruta real hasta la carpeta de uploads\n ruta=servletContext.getRealPath(\"/upload/\");\n \n //Concatenamiento de directorios internos\n ruta+=File.separatorChar+\"img\"+File.separatorChar+\"users\"+File.separatorChar;\n \n //Asignacion de la ruta creada\n this.rutaImgPerfil=ruta;\n }", "void setImage(String image);", "private void postImage(String fid, final String fileName) {\n\t\tJSONObject jsObject = new JSONObject();\n\t\tSharedPreferences myPrefs = getActivity().getSharedPreferences(\"myPrefs\",getActivity().MODE_PRIVATE);\n\t\ttry {\n\n\t\t\tjsObject.put(\"field_image\", new JSONObject().put(\"und\", new JSONArray().put(0, new JSONObject().put(\"fid\", fid))));\n\t\t} catch (JSONException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t\tcd = new ConnectionDetector(getActivity());\n\n\t\t// Check if Internet present\n\t\tif (!cd.isConnectingToInternet()) {\n\t\t\t// Internet Connection is not present\n\t\t\talert.showAlertDialog(getActivity(),\n\t\t\t\t\t\"Internet Connection Error\",\n\t\t\t\t\t\"Please connect to working Internet connection\", false);\n\t\t\t// stop executing code by return\n\t\t\treturn;\n\t\t}else{\n\t\t\tnew UpdateLike(jsObject,myPrefs){\n\t\t\t\tprotected void onPreExecute() {\n\t\t\t\t\tAppUtil.initializeProgressDialog(getActivity(), \"Finalizing post...\", progressDialog);\n\t\t\t\t};\n\t\t\t\tprotected void onPostExecute(String result) {\n\t\t\t\t\tAppUtil.cancelProgressDialog();\n\t\t\t\t\tinfalteImageOnCoverPhoto(fileName);\n\t\t\t\t};\n\t\t\t}.execute(\"http://www1.kitchengardens.in/svc/node/\"+garden_node_id);\n\t\t}\n\t}", "private void uploadPhoto() {\n // Get the data from an ImageView as bytes\n ImageView imageView = (ImageView)findViewById(R.id.imgView);\n imageView.setDrawingCacheEnabled(true);\n imageView.buildDrawingCache();\n Bitmap bitmap = imageView.getDrawingCache();\n ByteArrayOutputStream baos = new ByteArrayOutputStream();\n bitmap.compress(Bitmap.CompressFormat.JPEG, 100, baos);\n byte[] data = baos.toByteArray();\n\n FirebaseStorage storage = FirebaseStorage.getInstance();\n\n // Create a storage reference from our app\n StorageReference storageRef = storage.getReferenceFromUrl(Config.FIREBASE_STORAGE_URL);\n\n // Create a reference to 'images/profile/userNodeId.jpg'\n StorageReference mountainImagesRef = storageRef.child(\"images/profile/\"+currentUser.getFireUserNodeId()+\".jpg\"); // set image name as userid.jpg which is unique\n\n UploadTask uploadTask = mountainImagesRef.putBytes(data);\n uploadTask.addOnFailureListener(new OnFailureListener() {\n @Override\n public void onFailure(Exception exception) {\n // Handle unsuccessful uploads\n Toast.makeText(getApplicationContext(),\"Photo upload failed!\",Toast.LENGTH_SHORT).show();\n }\n }).addOnSuccessListener(new OnSuccessListener<UploadTask.TaskSnapshot>() {\n @Override\n public void onSuccess(UploadTask.TaskSnapshot taskSnapshot) {\n // taskSnapshot.getMetadata() contains file metadata such as size, content-type, and download URL.\n Toast.makeText(getApplicationContext(),\"Photo uploaded successfully!\",Toast.LENGTH_SHORT).show();\n }\n });\n }", "@RequestMapping(value = {\"/edit-user-{id}\"}, method = RequestMethod.POST)\r\n public String updateUser(@Valid FileBucket fileBucket, BindingResult result,\r\n ModelMap model, @PathVariable String id, HttpServletRequest req) {\r\n\r\n MultipartFile[] files = fileBucket.getFiles();\r\n String originalImgPath = \"\";\r\n String resizedImgPath = \"\";\r\n //String serverFileName = \"\";\r\n String photoName = \"\";\r\n String itemViewName = \"\";\r\n String imgLocation = \"\";\r\n int width = 580;\r\n int height = 450;\r\n boolean saved = false;\r\n String serverFileName = \"\";\r\n\r\n FileBucket fb = new FileBucket();\r\n User user = new User();\r\n if (result.hasErrors()) {\r\n return \"registration\";\r\n }\r\n if (files != null && files.length > 0) {\r\n for (int i = 0; i < files.length; i++) {\r\n try {\r\n\r\n byte[] bytes = null;\r\n // Creating the directory to store file\r\n String rootPath = System.getProperty(\"catalina.home\");\r\n File dir = new File(rootPath + File.separator + \"tmpFiles\");\r\n if (!dir.exists()) {\r\n dir.mkdirs();\r\n }\r\n\r\n FilenameUtils fileUTIL = new FilenameUtils();\r\n\r\n String path = req.getServletContext().getRealPath(\"/image\");\r\n //String ext = fileUTIL.getExtension(file.getOriginalFilename());\r\n //String baseName = fileUTIL.getBaseName(file.getOriginalFilename());\r\n\r\n imgLocation = dir + File.separator;\r\n // get files name in the array\r\n if (i == 0) {\r\n photoName = files[i].getOriginalFilename();\r\n bytes = files[i].getBytes();\r\n serverFileName = imgLocation + photoName;\r\n System.out.println(\"photoName:: \" + photoName);\r\n } else if (i == 1) {\r\n itemViewName = files[i].getOriginalFilename();\r\n bytes = files[i].getBytes();\r\n serverFileName = imgLocation + itemViewName;\r\n System.out.println(\"itemViewName:: \" + itemViewName);\r\n }\r\n\r\n System.out.println(\"serverFileName :: \" + serverFileName);\r\n\r\n // resize image\r\n //utility.resize(originalImgPath, resizedImgPath, width, height);\r\n //create the file on server\r\n File serverFile = new File(serverFileName);\r\n BufferedOutputStream stream = new BufferedOutputStream(\r\n new FileOutputStream(serverFile));\r\n stream.write(bytes);\r\n stream.close();\r\n\r\n } catch (Exception e) {\r\n e.printStackTrace();\r\n }\r\n }\r\n\r\n System.out.println(\"fileBucket.getPhoneNumber() ::\" + fileBucket.getPhoneNumber());\r\n user.setId(fileBucket.getId());\r\n user.setFirstName(fileBucket.getFirstName());\r\n user.setLastName(fileBucket.getLastName());\r\n user.setPhoneNumber(fileBucket.getPhoneNumber());\r\n user.setItemView(fileBucket.getItemView());\r\n user.setAddress(fileBucket.getAddress());\r\n user.setPassportPhotograph(photoName);\r\n user.setImgLocation(imgLocation);\r\n user.setImgName(photoName);\r\n user.setImgItemName(itemViewName);\r\n\r\n saved = userService.updateUser(user);\r\n\r\n } else {\r\n System.out.println(\"File is empty / No image uploaded\");\r\n }\r\n\r\n //model.addAttribute(\"user\", user);\r\n model.addAttribute(\"user\", fb);\r\n // model.addAttribute(\"success\", \"User \" + user.getFirstName() + \" \" + user.getLastName() + \" saved successfully\");\r\n // model.addAttribute(\"saved\", saved);\r\n\r\n //return \"adduser\";\r\n \r\n return \"redirect:/register\";\r\n }", "private void chooseImageAndUpload() {\n Intent intent = new Intent();\n intent.setType(\"image/*\");\n intent.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(Intent.createChooser(intent, \"Select Picture\"), Common.PICK_IMAGE_REQUEST);\n\n }", "private void saveImageToGallery() {\n ContentValues image = new ContentValues();\n image.put(MediaStore.Images.Media.TITLE, mPictureFile);\n image.put(MediaStore.Images.Media.DISPLAY_NAME, mPictureFile);\n image.put(MediaStore.Images.Media.DESCRIPTION, \"Processed by the MFace App\");\n image.put(MediaStore.Images.Media.DATE_TAKEN, System.nanoTime()); //\n image.put(MediaStore.Images.Media.MIME_TYPE, \"image/jpeg\");//png!!!\n image.put(MediaStore.Images.Media.ORIENTATION, 0);\n image.put(MediaStore.Images.Media.DATA, mPictureFile);\n getContext().getContentResolver().insert(MediaStore.Images.Media.EXTERNAL_CONTENT_URI, image);\n }", "public synchronized void addNewImage(BufferedImage img, File file) {\r\n\t\tint image_pk = db.insertImage(file.getName(), file.getAbsolutePath(), DEFAULT_TAG_PK);\r\n\t\tSaveImageOnDisk saveImage = new SaveImageOnDisk(img, file, db.getCacheName(image_pk)); \r\n\t\tsaveImage.start();\r\n\t}", "public String guardarImgPost(){\n \n File archivo=null;//Objeto para el manejo de os archivos\n InputStream in =null;//Objeto para el manejo del stream de datos del archivo\n //Se obtiene el codigo de usuario de la sesion actual\n String codUsuario=codUsuario=String.valueOf(new SessionLogica().obtenerUsuarioSession().getCodUsuario());\n //Se obtiene un codigo producto de la combinacion del codigo del usuario y de un numero aleatorio\n String codGenerado=new Utiles().generar(codUsuario);\n String extension=\"\";\n int i=0;\n //Extension del archivo ha subir\n extension=\".\"+FilenameUtils.getExtension(this.getObjImagen().getImagen().getFileName());\n \n \n try {\n //Pasa el buffer de datos en un array de bytes , finalmente lee cada uno de los bytes\n in=this.getObjImagen().getImagen().getInputstream();\n byte[] data=new byte[in.available()];\n in.read(data);\n \n //Crea un archivo en la ruta de publicacion\n archivo=new File(this.rutaImgPublicacion+codGenerado+extension);\n FileOutputStream out=new FileOutputStream(archivo);\n //Escribe los datos en el nuevo archivo creado\n out.write(data);\n \n System.out.println(\"Ruta de Path Absolute\");\n System.out.println(archivo.getAbsolutePath());\n \n //Cierra todas las conexiones\n in.close();\n out.flush();\n out.close();\n } catch (IOException ex) {\n System.out.println(ex.getMessage());\n return \"none.jpg\";\n }\n //Retorna el nombre de la iamgen almacenada\n return codGenerado+extension;\n }", "public void uploadPic() {\n try {\n if (bitmap == null) {\n Toast.makeText(AddPage.this, \"Please Select Image\", Toast.LENGTH_SHORT).show();\n\n } else {\n if (bitmap != null) {\n\n final DatabaseReference newref = FirebaseDatabase.getInstance().getReference(\"Page\").push();\n FirebaseStorage storage = FirebaseStorage.getInstance();\n\n StorageReference storageRef = storage.getReferenceFromUrl(\"gs://questo-1f35e.appspot.com\");\n // Create a reference to 'images/mountains.jpg'\n StorageReference mountainImagesRef = storageRef.child(\"PageImages\").child(newref.getKey() + \"\");\n ByteArrayOutputStream baos = new ByteArrayOutputStream();\n bitmap.compress(Bitmap.CompressFormat.JPEG, 100, baos);\n byte[] data = baos.toByteArray();\n UploadTask uploadTask = mountainImagesRef.putBytes(data);\n uploadTask.addOnFailureListener(new OnFailureListener() {\n @Override\n public void onFailure(@NonNull Exception e) {\n\n }\n\n }).addOnSuccessListener(new OnSuccessListener<UploadTask.TaskSnapshot>() {\n @Override\n public void onSuccess(UploadTask.TaskSnapshot taskSnapshot) {\n // taskSnapshot.getMetadata() contains file metadata such as size, content-type, and download URL.\n Uri downloadUrl = taskSnapshot.getDownloadUrl();\n\n if (downloadUrl != null) {\n // article = new Article(newref.getKey(), date.getTime(), title.getText().toString(), input.getText().toString(), MyData.getMyUser().id, MyData.getMyUser().name, downloadUrl.toString());\n if (dialog != null && dialog.isShowing())\n dialog.dismiss();\n\n upload(downloadUrl.toString());\n\n\n\n\n final String s = name;\n if (s.trim().length() != 0) {\n\n if(MainActivity.rootLayout!=null)\n Snackbar.make(MainActivity.rootLayout, \"Successfully created page \" + s, Snackbar.LENGTH_LONG)\n .setAction(\"Show\", new View.OnClickListener() {\n @Override\n public void onClick(View v) {\n\n\n Intent intent = new Intent(AddPage.this, PageOpenActivity.class);\n intent.putExtra(\"id\", s);\n startActivity(intent);\n\n }\n }).show();\n\n\n\n if(PageActivity.rootlayout!=null)\n Snackbar.make(PageActivity.rootlayout, \"Successfully created page \" + s, Snackbar.LENGTH_LONG)\n .setAction(\"Show\", new View.OnClickListener() {\n @Override\n public void onClick(View v) {\n\n\n Intent intent = new Intent(AddPage.this, PageOpenActivity.class);\n intent.putExtra(\"id\", s);\n startActivity(intent);\n\n }\n }).show();\n\n\n\n\n\n }\n\n // FirebaseAuth.getInstance().signOut();\n// finish()\n\n finish();\n }\n }\n });\n }\n }\n } catch (Exception e) {\n FirebaseDatabase.getInstance().getReference(\"Exceptions\").child(Profile.getCurrentProfile().getId()).push().setValue(e.toString());\n\n }\n\n }", "private void salvaFoto(){\n\n try {\n\n File f = new File(Environment.getExternalStorageDirectory() +getResources().getString(R.string.folder_package)+ \"/\" +id_Familiar+ \".jpg\");\n\n if(f.exists()){ boolean deleted = f.delete();}\n\n ByteArrayOutputStream bytes = new ByteArrayOutputStream();\n bitmap.compress(Bitmap.CompressFormat.JPEG, qualidade_image_profile, bytes);\n\n try {\n f.createNewFile();\n FileOutputStream fo = new FileOutputStream(f);\n fo.write(bytes.toByteArray());\n } catch (IOException e) {\n e.printStackTrace();\n }\n\n }\n catch (Exception E){\n Log.e(\"error\",\"Erro ao carregar imagem\");\n }\n }", "private void saveAndUpload(String name, String email, Uri photoUri){\n\n // TODO implement save to local DB\n // TODO implement safe upload to Server\n }", "private void getNewImage() {\n try {\n URL imageUrl = new URL(path);\n URLConnection uc = imageUrl.openConnection();\n\n InputStream is = uc.getInputStream();\n BufferedInputStream bis = new BufferedInputStream(is);\n\n ByteArrayOutputStream buffer = new ByteArrayOutputStream();\n int current;\n while ((current = bis.read()) != -1) {\n buffer.write((byte) current);\n }\n final byte[] data = buffer.toByteArray();\n // enqueue UI update as a priority\n Handler handler = new Handler(Looper.getMainLooper());\n handler.post(new Runnable() {\n public void run() {\n view.setImageBitmap(BitmapFactory.decodeByteArray(\n data, 0, data.length));\n }\n });\n // update database while that is queueing\n ContentValues values = new ContentValues();\n values.put(MovieEntry.COLUMN_POSTER, data);\n context.getContentResolver().update(MovieEntry.buildMovieUriWithId(movieId),\n values, null, null);\n } catch (Exception E) {\n Log.i(TAG, E.toString());\n E.printStackTrace();\n }\n }", "public void uploadImg(View view){\n Intent intent = new Intent(Intent.ACTION_OPEN_DOCUMENT);\n intent.addCategory(Intent.CATEGORY_OPENABLE);\n intent.setType(\"image/*\");\n intent.addFlags(Intent.FLAG_GRANT_READ_URI_PERMISSION);\n intent.addFlags(Intent.FLAG_GRANT_WRITE_URI_PERMISSION);\n intent.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(Intent.createChooser(intent, \"Select Picture\"), SELECT_PICTURE);\n }", "public void uploadMultipart() {\n //getting the actual path of the image\n String path = getPath(filePath);\n\n //Uploading code\n try {\n String uploadId = UUID.randomUUID().toString();\n\n //Creating a multi part request\n new MultipartUploadRequest(this, uploadId, \"todo\")\n .addFileToUpload(path, \"image\") //Adding file\n .setNotificationConfig(new UploadNotificationConfig())\n .setMaxRetries(2)\n .startUpload(); //Starting the upload\n\n } catch (Exception exc) {\n Toast.makeText(this, exc.getMessage(), Toast.LENGTH_SHORT).show();\n }\n }", "@PostMapping\n public ResponseEntity<BlobImage> saveImage(@RequestBody BlobStoreRequest request) {\n logger.info(\"Got a request to save an image: {}\", request.getMd5());\n BlobImage blob = BlobImage.builder()\n .build();\n blob = repository.save(blob);\n\n String storageLocation = properties.getStorageLocation();\n String uploadDir = storageLocation + \"/\" + blob.getId();\n\n blob.setImageUri(ServletUriComponentsBuilder.fromCurrentContextPath().path(\"/api/v1/blob/{id}\")\n .buildAndExpand(blob.getId()).toUriString());\n\n blob.setFileNameWithAbsolutePath(uploadDir);\n\n repository.save(blob);\n return ResponseEntity.ok(blob);\n }", "private void getImagesFromDatabase() {\n try {\n mCursor = mDbAccess.getPuzzleImages();\n\n if (mCursor.moveToNext()) {\n for (int i = 0; i < mCursor.getCount(); i++) {\n String imagetitle = mCursor.getString(mCursor.getColumnIndex(\"imagetitle\"));\n String imageurl = mCursor.getString(mCursor.getColumnIndex(\"imageurl\"));\n mImageModel.add(new CustomImageModel(imagetitle, imageurl));\n mCursor.moveToNext();\n }\n } else {\n Toast.makeText(getActivity(), \"databse not created...\", Toast.LENGTH_LONG).show();\n }\n } catch (Exception e) {\n e.printStackTrace();\n\n }\n\n }", "public void saveImagesFolder(final Path path_of_resource) throws IOException {\n final Path path = path_of_resource;\n Set<String> listImages = new HashSet<>();\n listImages = listFiles(path);\n List<String> found = new ArrayList<>();\n Iterator<Image> image_it = imageRepository.findAll().iterator();\n // Filter images that have the same name in the db and the images in the\n // resource folder.\n while (image_it.hasNext()) {\n Image next_i = image_it.next();\n Iterator<String> list_it = listImages.iterator();\n while (list_it.hasNext()) {\n String next_s = list_it.next();\n if (next_i.getName().equals(Paths.get(next_s).getFileName().toString()))\n found.add(next_s);\n }\n }\n listImages.removeAll(found);\n System.out.println(listImages);\n listImages.forEach(i -> {\n try {\n final byte[] fileContent = Files.readAllBytes(Paths.get(i));\n Image image = new Image(Paths.get(i).getFileName().toString(), fileContent,\n Utils.typeOfFile(Paths.get(i)), Utils.sizeOfImage(Paths.get(i)));\n image.setIsNew(false);\n imageRepository.save(image);\n\n } catch (final IOException e) {\n e.printStackTrace();\n }\n });\n }", "public void setImage(int imageId) {\n this.imageId=imageId;\n\t}", "Path fileToUpload();", "public void saveContact(View view) {\n EditText nameField = (EditText) findViewById(R.id.name);\n EditText emailField = (EditText) findViewById(R.id.email);\n EditText phoneField = (EditText) findViewById(R.id.phone);\n String name = nameField.getText().toString();\n String email = emailField.getText().toString();\n String phone = phoneField.getText().toString();\n String image = name.replace(' ', '_') + \".jpg\";\n\n //create and save image to internal storage, and save image name in DB\n Bitmap bitmap = null;\n ContextWrapper cw = new ContextWrapper(getApplicationContext());\n File directory = cw.getDir(\"imageDir\", Context.MODE_PRIVATE);\n\n File mypath = new File(directory, image);\n\n FileOutputStream fos = null;\n\n //create bitmap Image\n try{\n bitmap = MediaStore.Images.Media.getBitmap(this.getContentResolver(), selectedImageUri);\n fos = new FileOutputStream(mypath);\n bitmap.compress(Bitmap.CompressFormat.PNG, 100, fos);\n\n } catch (FileNotFoundException e) {\n e.printStackTrace();\n } catch (IOException e) {\n e.printStackTrace();\n }\n\n //Save directory to use for specifying path of image\n setDir(directory.getAbsolutePath());\n\n int end = 0;\n\n //update contacts info and image\n for(int i=0; i < contacts.size(); i++){\n name = nameField.getText().toString();\n email = emailField.getText().toString();\n phone = phoneField.getText().toString();\n if(contacts.get(i).name.equals(name)){\n contacts.get(i).setEmail(email);\n contacts.get(i).setMobile(phone);\n contacts.get(i).setImage(image);\n contactRepository.update(contacts.get(i));\n }else{\n end += 1;\n }\n }\n\n if(end == contacts.size()){\n contactRepository.insert(new Contact(image, name, email, phone));\n }\n\n Toast.makeText(this, \"Contact saved\",\n Toast.LENGTH_SHORT).show();\n }", "private void createUpdateImage(Item item) throws Exception {\r\n //cria a imagem\r\n new Image().saveImage(item.getImagem(), item.getNome());\r\n \t}", "boolean uploadImage() {\r\n\t\tJFileChooser inImg = new JFileChooser();\r\n\t\tint approved = inImg.showOpenDialog(mainFrame);\r\n\t\tif (approved == JFileChooser.APPROVE_OPTION) {\r\n\t\t\tFile imf = inImg.getSelectedFile();\r\n\t\t\ttry {\r\n\t\t\t\talbum.put(album.size(), new Image(imf.getPath()));\r\n\t\t\t} catch (Exception e) {\r\n\t\t\t\tJOptionPane.showMessageDialog(new JFrame(), \"Invalid File Path\");\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\t\tmodel.addElement(album.get(album.size() - 1));\r\n\t\t\talbumList.setModel(model);\r\n\t\t}\r\n\t\treturn true;\r\n\t}", "public Result uploadImage() {\n MultipartFormData<File> body = request().body().asMultipartFormData();\n MultipartFormData.FilePart<File> fileInput = body.getFile(\"inputFile\");\n if (fileInput != null) {\n File file = (File) fileInput.getFile();\n String imageUrl = S3Action.putImg(s3, file, UUID.randomUUID().toString());\n return ok(afterPutImg.render(imageUrl));\n } else {\n return badRequest(\"error\");\n }\n }", "private void uploadFile() {\n //checking if file is available\n if (filePath != null) {\n //displaying progress dialog while image is uploading\n final ProgressDialog progressDialog = new ProgressDialog(this);\n progressDialog.setTitle(\"Uploading\");\n progressDialog.show();\n\n //getting the storage reference\n StorageReference sRef = storageReference.child(\"admins/\" + System.currentTimeMillis() + \".\" + getFileExtension(filePath));\n\n //adding the file to reference\n sRef.putFile(filePath).addOnSuccessListener(new OnSuccessListener<UploadTask.TaskSnapshot>() {\n @Override\n public void onSuccess(UploadTask.TaskSnapshot taskSnapshot) {\n //dismissing the progress dialog\n progressDialog.dismiss();\n\n //displaying success toast\n // Toast.makeText(getApplicationContext(), \"File Uploaded \", Toast.LENGTH_LONG).show();\n\n // ba5odha fe string as url\n imageurl = taskSnapshot.getDownloadUrl().toString();\n\n DatabaseReference mDatabase;\n\n mDatabase = FirebaseDatabase.getInstance().getReference();\n\n String s = mDatabase.push().getKey();\n\n Admin a = new Admin(s, name.getText().toString(), email.getText().toString(), phone.getText().toString(), address.getText().toString(), imageurl);\n\n // b3ml save fel firebase lel object of admin\n mDatabase.child(\"admins\").child(s).setValue(a);\n\n Toast.makeText(RegisterAsAdmin.this, \"Registration successful\", Toast.LENGTH_LONG).show();\n FirebaseAuth.getInstance().signOut();\n Intent i = new Intent(RegisterAsAdmin.this, LoginAsAdmin.class);\n startActivity(i);\n finish();\n }\n }).addOnFailureListener(new OnFailureListener() {\n @Override\n public void onFailure(@NonNull Exception exception) {\n progressDialog.dismiss();\n Toast.makeText(getApplicationContext(), exception.getMessage(), Toast.LENGTH_LONG).show();\n }\n }).addOnProgressListener(new OnProgressListener<UploadTask.TaskSnapshot>() {\n @Override\n public void onProgress(UploadTask.TaskSnapshot taskSnapshot) {\n //displaying the upload progress\n double progress = (100.0 * taskSnapshot.getBytesTransferred()) / taskSnapshot.getTotalByteCount();\n progressDialog.setMessage(\"Uploaded \" + ((int) progress) + \"%...\");\n }\n });\n } else {\n Toast.makeText(RegisterAsAdmin.this, \"File Error\", Toast.LENGTH_SHORT).show();\n }\n }", "public void addPic(PictureStatus pictures) {\n \t\t\t\tpictureRepo.save(pictures);\r\n \t\t\t}", "public void pullFromHibernate(){\n List<ImageData> deleteList = new ArrayList<>();\n\n USER.getImages()\n .stream()\n .filter(imageData -> {\n File newFile = new File(imageData.getPath());\n if(addFile(newFile)){\n IMAGE_DATA.inverse().forcePut(imageData, newFile);\n return false;\n }else return true;\n }).forEach(deleteList::add);\n\n deleteList.forEach(imageData -> {\n LOGGER.info(\"File: \" + imageData.getPath() + \" not found locally.\\n\" +\n \"Deleting reference from remote SQL.\");\n USER.deleteImage(imageData);\n });\n refreshTagsTree();\n }", "@Override\n\tpublic int saveImage(Movie movie) {\n\t\tString str = uuid.toString();\n String id = str.substring(0, 8) + str.substring(9, 13) + str.substring(14, 18) + str.substring(19, 23) + str.substring(24);\n \n\t\tmovie.setId(id);\n\t\tmovie.setCreateData(new Date());\n\t\tint number = this.insert(\"Movie.insert\", movie);\n\t\treturn number;\n\t}", "private void uploadFile() {\n //if there is a file to upload\n if (filePath != null) {\n\n\n final StorageReference storageReference2nd = storageReference.child(System.currentTimeMillis() + \".\" + GetFileExtension(filePath));\n storageReference2nd.putFile(filePath)\n .addOnSuccessListener(new OnSuccessListener<UploadTask.TaskSnapshot>() {\n @Override\n public void onSuccess(UploadTask.TaskSnapshot taskSnapshot) {\n\n /* storageReference2nd.getDownloadUrl().addOnSuccessListener(new OnSuccessListener<Uri>() {\n @Override\n public void onSuccess(Uri uri) {\n final String ImageUrl = uri.toString();\n\n }\n });*/\n\n // Getting Description, Price, Address, Mobile from EditText and store into string variable.\n String TempDescription = Description.getText().toString().trim();\n String TempPrice = Price.getText().toString().trim();\n String TempAddress = Address.getText().toString().trim();\n String TempPhone = Phone.getText().toString().trim();\n String TempImageUrl = ImageUrl;\n\n\n\n\n\n //if the upload is successfull\n\n //and displaying a success toast\n Toast.makeText(postadv.this, \"File Uploaded \", Toast.LENGTH_LONG).show();\n\n\n @SuppressWarnings(\"VisibleForTests\")\n ImageUploadInfo imageUploadInfo = new ImageUploadInfo(TempDescription, TempPrice, TempAddress, TempPhone, storageReference2nd.getDownloadUrl().toString());\n\n // Getting image upload ID.\n String ImageUploadId = databaseReference.push().getKey();\n\n // Adding image upload id s child element into databaseReference.\n databaseReference.child(ImageUploadId).setValue(imageUploadInfo);\n }\n })\n .addOnFailureListener(new OnFailureListener() {\n @Override\n public void onFailure(@NonNull Exception exception) {\n //if the upload is not successfull\n //hiding the progress dialog\n\n //and displaying error message\n Toast.makeText(getApplicationContext(), exception.getMessage(), Toast.LENGTH_LONG).show();\n }\n });\n }\n //if there is not any file\n else {\n Toast.makeText(postadv.this, \"Failed\", Toast.LENGTH_SHORT).show();\n }\n }", "public void upload() {\n try {\n BufferedImage bufferedProfile = ImageIO.read(profilePicture.getInputStream());\n FaceImage face = new FaceImage(bufferedProfile);\n\n if (face.foundFace()) {\n\n face.setNoCropMultiplier(1);\n face.setAdditionPadding(20);\n face.setDimension(128, 128);\n BufferedImage profilePicture = face.getScaledProfileFace();\n\n File outfile = new File(Settings.NEW_PROFILE_IMAGE_PATH.replace(\"~~username~~\", student.getUserName()));\n ImageIO.write(profilePicture, \"png\", outfile);\n\n success = true;\n\n student.setProfilePicturePath(\"profile/\" + student.getUserName() + \".png\");\n save();\n\n } else {\n FacesContext.getCurrentInstance().addMessage(\"imageContainer:file\", new FacesMessage(\"Kein Gesicht gefunden!\"));\n\n }\n\n } catch (IOException e) {\n System.err.println(\"something went wrong \" + e.getMessage());\n }\n\n }", "private void uploadImage() {\n if(checkPermissions()){ // if permission is granted we move on with the code\n Intent gallery = new Intent();\n gallery.setType(\"image/\");\n gallery.setAction(Intent.ACTION_GET_CONTENT);\n startActivityForResult(Intent.createChooser(gallery,\"Select Image With: \"),CHOOSE_IMAGE_FROM_GALLERY);\n }else{\n requestPermissionFromUser(); // if permission is not granted we go and request a permission from the user\n }\n }", "@Override\n\tvoid postarFoto() {\n\n\t}", "@Override\n protected void doPost(HttpServletRequest request, HttpServletResponse response)\n throws ServletException, IOException {\n String appPath = request.getServletContext().getRealPath(\"\");\n //construct path of the directory to save uploaded file\n String savePath = appPath + File.separator + SAVE_DIR;\n\n //create the saves directory if it does not exists\n File fileSaveDir = new File(savePath);\n if (!fileSaveDir.exists()) {\n fileSaveDir.mkdir();\n }\n \n Part file = request.getPart(\"image\");\n String fileName = extractFilename(file);\n file.write(savePath + File.separator + fileName);\n String filePath = savePath + File.separator + fileName;\n \n Slider slid = new Slider();\n slid.setImage(fileName);\n \n sliders.createSlider(slid);\n \n RequestDispatcher res = request.getRequestDispatcher(\"/admin/sliders/list.jsp\");\n request.setAttribute(\"sliders\", sliders.getSliders());\n res.forward(request, response);\n }", "public int insertImageIntoDatabase(BufferedImage image) {\r\n\t\tint idImage = -1;\r\n\t\ttry {\r\n\t\t\tjava.io.ByteArrayOutputStream baos = new java.io.ByteArrayOutputStream();\r\n\t\t\tImageIO.write(image, \"png\", baos);\r\n\r\n\t\t\tPreparedStatement pStat = dbConnection.prepareStatement(\"insert into images (img) VALUES (?)\", Statement.RETURN_GENERATED_KEYS);\r\n\t\t\tpStat.setBlob(1, new java.io.ByteArrayInputStream(baos.toByteArray()));\r\n\t\t\tpStat.execute();\r\n\r\n\t\t\tResultSet rs = pStat.getGeneratedKeys();\r\n\t\t\tif (rs.next()) {\r\n\t\t\t\tidImage = rs.getInt(1);\r\n\t\t\t}\r\n\t\t\tpStat.close();\r\n\t\t} catch (SQLException | IOException e) {\r\n\t\t\te.printStackTrace();\r\n\t\t} \r\n\t\t\r\n\t\treturn idImage;\r\n\t}", "@PreAuthorize(\"hasAnyRole('ROLE_ADMIN','ROLE_CONTRIBUTOR')\")\r\n\t@CrossOrigin(origins=\"http://localhost:4200\")\r\n\t@RequestMapping(value=\"/image/upload/{idMangas:[0-9]+}\", method=RequestMethod.POST, produces=MediaType.APPLICATION_JSON_VALUE)\r\n\t@ResponseBody\r\n\tpublic Manga upload(@RequestParam(\"file\") MultipartFile file, @PathVariable(\"idMangas\") int idMangas){\n\t\tlog.info(\"File name: \" + file.getOriginalFilename());\r\n\t\tlog.info(\"File name: \" + file.getContentType());\r\n\t\t\r\n\t\ttry {\r\n\t\t\tImage img = new Image(0, file.getOriginalFilename(), file.getSize(), file.getContentType(), \"\", \"\");\r\n\t\t\timageDao.saveImageFile(img, file.getInputStream());\r\n\t\t\t// on save ensuite en bdd l image\r\n\t\t\timageDao.save(img);\r\n\t\t\t// puis on lie limage a mongas recup ds lurl\r\n\t\t\tManga m = mangasDao.findOne(idMangas);\r\n\t\t\tm.setImg(img);\r\n\t\t\treturn mangasDao.save(m);\r\n\t\t\t// return m;\r\n\t\t\t\r\n\t\t} catch (IOException e) {\r\n\t\t\t// TODO Auto-generated catch block\r\n\t\t\tthrow new HttpClientErrorException(HttpStatus.INTERNAL_SERVER_ERROR, \"erreur lors de la sauvegarde\");\r\n\t\t}\r\n\t}", "@EventListener(ApplicationReadyEvent.class)\n private void createImageDirectory()\n {\n new File(productImageUpload).mkdir();\n }", "private void UploadPic(String name){\n if(filepath!=null)\n {\n progressDialog.setTitle(\"Uploading...\");\n progressDialog.show();\n //\"UserProfile/user.jpg\"\n StorageReference imageRef = storageReference.child(firebaseAuth.getCurrentUser().getEmail() + \"/\" + name + \".jpg\" );\n imageRef.putFile(filepath)\n .addOnSuccessListener(new OnSuccessListener<UploadTask.TaskSnapshot>() {\n @Override\n public void onSuccess(UploadTask.TaskSnapshot taskSnapshot) {\n //Get URL to uploaded Content\n progressDialog.hide();\n Toast.makeText(UserInfoForm.this, \"Upload Successful\", Toast.LENGTH_SHORT).show();\n }\n })\n .addOnFailureListener(new OnFailureListener() {\n @Override\n public void onFailure(@NonNull Exception exception) {\n progressDialog.hide();\n Toast.makeText(UserInfoForm.this, \"Upload Failed\", Toast.LENGTH_SHORT).show();\n }\n })\n .addOnProgressListener(new OnProgressListener<UploadTask.TaskSnapshot>() {\n @Override\n public void onProgress(UploadTask.TaskSnapshot taskSnapshot) {\n double progress = (100.0 * taskSnapshot.getBytesTransferred()/taskSnapshot.getTotalByteCount());\n progressDialog.setMessage( (int)progress + \"% Uploaded\");\n }\n });\n }\n else{\n Toast.makeText(this, \"Upload Failed\", Toast.LENGTH_SHORT).show();\n }\n }", "@PreAuthorize(\"hasRole('ROLE_USER') or hasRole('ROLE_USER_PREMIUM') or hasRole('ROLE_ROOT')\")\n @RequestMapping(value = \"/images/{user_id}\", method = RequestMethod.POST)\n public ResponseEntity<?> addImage(@PathVariable(\"user_id\") final Integer user_id,\n @RequestParam(\"file\") final MultipartFile file, final RedirectAttributes redirectAttributes) {\n Image image;\n if (!AcceptedMediaTypes.contains(file.getContentType()))\n return new ResponseEntity<>(HttpStatus.UNSUPPORTED_MEDIA_TYPE);\n try {\n image = new Image(file.getOriginalFilename(), file.getBytes(), Utils.typeOfFile(file),\n Utils.sizeOfImage(file));\n\n User user = userRepository.findById(user_id).orElse(null);\n if (!JwtUtils.checkUserAuthentification(user))\n return new ResponseEntity<>(HttpStatus.FORBIDDEN);\n image.setUser(user);\n\n imageRepository.save(image);\n } catch (final IOException e) {\n e.printStackTrace();\n return new ResponseEntity<>(HttpStatus.BAD_REQUEST);\n }\n\n try {\n System.out.println(\"New id for image saved: \" + image.getId());\n return ResponseEntity.created(new URI(\"/\")).header(\"id\", String.valueOf(image.getId()))\n .body(\"Image successfully saved\");\n } catch (final URISyntaxException e) {\n e.printStackTrace();\n return new ResponseEntity<>(HttpStatus.NO_CONTENT);\n }\n }", "public void addPhoto(ActionEvent event) throws IOException {\n\t\t//System.out.println(\"ITEM ADDED______________________________________________\");\n\t\tFileChooser fileChooser = new FileChooser();\n\t\tfileChooser.setTitle(\"Open Photo\"); \n\t\tAccessibleUsersList.masterUserList.userLoggedIn.fileList = fileChooser.showOpenMultipleDialog(this.myNewStage);\n\t\t\n\t\tboolean checkIfImages = true;\n\t\t\n\t\tif(AccessibleUsersList.masterUserList.userLoggedIn.fileList != null){\n\t\t\t\n\t\t\tfor(File file : AccessibleUsersList.masterUserList.userLoggedIn.fileList){\n\t\t\t\t\n\t\t\t\tMimetypesFileTypeMap mimetype= new MimetypesFileTypeMap();\n\t\t\t\tmimetype.addMimeTypes(\"image png jpg jpeg JPG PNG\");\t\n\t\t\t\t\n\t\t\t\tString mimetype1 = mimetype.getContentType(file);\n\t\t\t\tString type = mimetype1.split(\"/\")[0];\n\t\t\t\t\n\t\t\t\tif(type.contains(\"image\")){\n\t\t\t //System.out.println(\"It's an image\");\n\t\t\t\t} else { \n\t\t\t \t //System.out.println(\"It's NOT an image\");\n\t\t\t \t Alert majorBagAlert = new Alert(AlertType.ERROR);\n\t\t\t\t majorBagAlert.setTitle(\"Error\");\n\t\t\t\t majorBagAlert.setHeaderText(\"One or more images is not an image file type.\");\n\t\t\t\t majorBagAlert.setContentText(\"Please enter photo(s) again\");\n\t\t\t\t majorBagAlert.showAndWait();\n\t\t\t \t \n\t\t\t\t //adding comment\n\t\t\t checkIfImages = false; \n\t\t\t }\n\t\t\t}\n }\n\t\t\n\n\t\t//iterate through the logged in user's albums \n\t\t//this is the album we have to add our photos to \n\t\tthis.selectedAlbum = AccessibleUsersList.masterUserList.userLoggedIn.selectedAlbum.getName(); \n\t\tAlbum foundAlbum = null; \n\t\tlong lastModifiedDate = 0; \n\t\tString path; \n\t\t\n\t\t//if we are certain we only collected files of type jpg, png or jpeg \n\t\tif(checkIfImages){\n\t\t\t\n\t\t\tif(AccessibleUsersList.masterUserList.userLoggedIn.fileList != null) {\n\t\t\t\t\n\t\t\t\tfor(File file : AccessibleUsersList.masterUserList.userLoggedIn.fileList){\n\t\t\t\t\t\n\t\t\t\t\tpath = file.getAbsolutePath();\n\t\t\t\t\tFileInputStream inputstream = new FileInputStream(path); \n\t\t\t\t\tImage image1 = new Image(inputstream); \n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t//iterate through the logged in user's albums \n\t\t\t\t\tint x=0; \n\t\t\t\t\tfor(Album album: AccessibleUsersList.masterUserList.userLoggedIn.albums_list){\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t//looking for the current album to add our photos into \n\t\t\t\t\t\tif(album.getName().equals(this.selectedAlbum)){\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tfoundAlbum = AccessibleUsersList.masterUserList.userLoggedIn.albums_list.get(x);\n\t\t\t\t\t\t\tlastModifiedDate = file.lastModified();\n\t\t\t\n\t\t\t\t\t\t\tPhoto albumPhoto = new Photo(path, lastModifiedDate); \n\t\t\t\t\t\t\tfoundAlbum.getAlbum().add(albumPhoto);\t \n\t\t\t\t\t\t\t//System.out.println(foundAlbum.getAlbum());\n\t\t\t\t\t\t\t//foundAlbum.photos.add(new model.Photo(image1, lastModifiedDate));\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tImageView pic = new ImageView();\n\t\t\t\t\t\t\tpic.setFitWidth(340);\n\t\t\t\t\t\t\tpic.setFitHeight(180);\n\t\t\t\t\t\t\tpic.setImage(image1);\n\t\t\t\t\t\t\tlistOfPhotos.add(pic);\n\t\t\t\t\t\t\talbumPhoto.setImage(pic);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t//System.out.println(\"photo added\");\n\t\t\t\t\t\t\t//System.out.println(albumPhoto.getPathToPhoto());\n\t\t\t\t\t\t\t//System.out.println(AccessibleUsersList.masterUserList.userLoggedIn);\n\t\t\t\t\t\t\t//System.out.println(AccessibleUsersList.masterUserList.userLoggedIn.selectedAlbum);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t//AccessibleUsersList.masterUserList.userLoggedIn.selectedAlbum.addPhoto(albumPhoto); <-----cause of bug, added photo TWICE, X\n\t\t\t\t\t\t\tbreak; \n\t\t\t\t\t\t} \n\t\t\t\t\t\tx++; \n\t\t\t\t\t}\n \t\t\t\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\ttry {\n\t\t\tserializeUsers(AccessibleUsersList.masterUserList);\n\t\t} catch (IOException e) {\n\t\t\tSystem.out.println(e.getMessage());\n\t\t}\t\n\t}", "public ImageMetadata addImage(MultipartFile file, String username) {\n String filename = StringUtils.cleanPath(file.getOriginalFilename());\n\n //Log message\n log.info(\"storing file {}...\", filename);\n\n //pass in file and username\n ImageMetadata metadata = fileStorageService.store(file, username);\n\n return imageMetadataRepository.save(metadata);\n }", "void UploadToFirebase() {\n // This gives the path name for the storage\n StorageReference photoRef = mStorageRef.child(\"images\").child(selectedImageUri.getLastPathSegment());\n\n // This uploads it into firebase storage\n // Toast makes the little comment appear at the bottom of the screen\n photoRef.putFile(selectedImageUri).addOnSuccessListener(new OnSuccessListener<UploadTask.TaskSnapshot>() {\n @SuppressLint(\"ShowToast\")\n @Override\n public void onSuccess(UploadTask.TaskSnapshot taskSnapshot) {\n Toast toast = Toast.makeText(getApplicationContext(), \"Uploaded\", Toast.LENGTH_SHORT);\n toast.show();\n }\n })\n .addOnFailureListener(new OnFailureListener() {\n @SuppressLint(\"ShowToast\")\n @Override\n public void onFailure(@NonNull Exception e) {\n Toast toast = Toast.makeText(getApplicationContext(), \"Upload failed\", Toast.LENGTH_SHORT);\n toast.show();\n }\n });\n }", "public void postPhoto() throws InterruptedException, IOException, AWTException{\n\t\tString filepath= getTargetFilePath(\"PhotoToUpload\", \"Image\", \"jpeg\");\n\t\tSystem.out.println(\"File path is:\"+ filepath);\n\t\t\n\t\tclick(profileIcon);\n\t\tThread.sleep(1000);\n\t\tclick(PhotoTab);\n\t\tThread.sleep(1000);\n\t\tdriver.findElement(PhotoUpload).sendKeys(filepath);\n\t\tclick(PostBttn);\n\t}", "private void uploadToServer(String filePath, String title) {\n APIClient apiClient = new APIClient();\n Retrofit retrofit = apiClient.getApiClient();\n ApiInterface apiInterface = retrofit.create(ApiInterface.class);\n File file = new File(filePath);\n\n MultipartBody.Part filePart =\n MultipartBody.Part.createFormData(\"file\", title+\".jpg\", //file.getName(),\n RequestBody.create(MediaType.parse(\"image/*\"), file));\n\n\n Call call = apiInterface.uploadImage(filePart);\n call.enqueue(new Callback() {\n @Override\n public void onResponse(Call call, Response response) {\n Toast.makeText(AddPost.this, \"Worked\",Toast.LENGTH_SHORT).show();\n }\n @Override\n public void onFailure(Call call, Throwable t) {\n t.printStackTrace();\n Toast.makeText(AddPost.this, \"Didn't work\",Toast.LENGTH_SHORT).show();\n }\n });\n }", "public void loadMedia() {\n MediaDBMapper mapper = new MediaDBMapper(ctx);\n\n String[] fileNames = {\n \"medved.jpg\",\n \"medved 2.jpg\",\n \"medved hnedy.jpg\",\n \"grizzly.jpg\",\n \"buk.jpg\",\n \"jedle.jpg\",\n \"jedle 2.jpg\"\n };\n\n File file = null;\n\n try {\n boolean autoCommit = getConnection().getAutoCommit();\n getConnection().setAutoCommit(false);\n\n try {\n\n for (String fileName : fileNames) {\n try {\n file = new File(\"resources\\\\\" + fileName);\n\n System.out.println(\"Opening: \" + file.getPath() + \".\");\n\n MediaEntity e = mapper.create();\n e.setName(file.getName().substring(0, file.getName().lastIndexOf('.')));\n\n mapper.loadImageFromFile(e, file.getPath());\n\n mapper.save(e);\n } catch (NullPointerException ex) {\n ex.printStackTrace();\n }\n\n// getConnection().commit();\n }\n\n } finally {\n getConnection().setAutoCommit(autoCommit);\n }\n } catch (SQLException ex) {\n ex.printStackTrace();\n// throw new RuntimeException(ex);\n }\n }", "public static String saveFile( MultipartFile filedata, HttpServletRequest request) {\n String pathval = \"C://KCGLIMG//\";\n String newFileName = String.valueOf( System.currentTimeMillis());\n String saveFilePath = \"images//equipment//\";\n\n File fileDir = new File(pathval + saveFilePath);\n if (!fileDir.exists()) {\n fileDir.mkdirs();\n }\n\n String filename=filedata.getOriginalFilename();\n\n String extensionName = filename.substring(filename.lastIndexOf(\".\") + 1);\n try {\n String imgPath = saveFilePath + newFileName + \".\" +extensionName;\n System.out.println(pathval + imgPath);\n FileOutputStream out = new FileOutputStream(pathval + imgPath);\n \n out.write(filedata.getBytes());\n out.flush();\n out.close();\n\n String path=pathval+imgPath;\n return path;\n } catch (Exception e) {\n e.printStackTrace();\n }\n return null;\n }", "public void setImage(String image) {\n this.image = image;\n }" ]
[ "0.7046421", "0.65712374", "0.64192855", "0.6417885", "0.62518495", "0.6213179", "0.6177981", "0.6137774", "0.6100679", "0.60947907", "0.6092865", "0.60674244", "0.6040768", "0.6020018", "0.60066", "0.6005063", "0.6001989", "0.59932834", "0.5951225", "0.5914678", "0.5913442", "0.5911909", "0.59026915", "0.58902615", "0.586922", "0.5868665", "0.5837303", "0.58356327", "0.58187944", "0.58103716", "0.57448494", "0.5739421", "0.57145137", "0.5712845", "0.5708664", "0.57074404", "0.56995934", "0.5688437", "0.5686562", "0.56689394", "0.5662231", "0.56393737", "0.56374747", "0.5634753", "0.56250554", "0.56221354", "0.56212205", "0.56194204", "0.56129295", "0.5612908", "0.5611012", "0.5608867", "0.55914354", "0.55897295", "0.5585411", "0.5565426", "0.556382", "0.5560699", "0.55603874", "0.5556469", "0.5542273", "0.55421615", "0.5539805", "0.5529278", "0.55259275", "0.5523444", "0.55211747", "0.55198187", "0.55155313", "0.5511671", "0.5509401", "0.5501082", "0.5494107", "0.5488137", "0.5486115", "0.54812247", "0.5480404", "0.54788196", "0.546938", "0.545991", "0.5454309", "0.543379", "0.5417821", "0.5416681", "0.5415238", "0.5414741", "0.5410488", "0.54085517", "0.54061985", "0.54023504", "0.53985566", "0.5398201", "0.5394395", "0.53940356", "0.539256", "0.5392508", "0.5389818", "0.53866184", "0.5384244", "0.5381204" ]
0.61382157
7
TODO Autogenerated method stub
public static void main(String[] args) { System.out.println(test(7, 4, 8)); System.out.println(test(7, 8, 4)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\n public void perish() {\n \n }", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "@Override\n\tpublic void anular() {\n\n\t}", "@Override\n\tprotected void getExras() {\n\n\t}", "@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}", "@Override\n\tpublic void entrenar() {\n\t\t\n\t}", "@Override\n\tpublic void nadar() {\n\t\t\n\t}", "@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}", "@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}", "@Override\n\tprotected void interr() {\n\t}", "@Override\n\tpublic void emprestimo() {\n\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\n\tpublic void grabar() {\n\t\t\n\t}", "@Override\n\tpublic void gravarBd() {\n\t\t\n\t}", "@Override\r\n\tpublic void rozmnozovat() {\n\t}", "@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}", "@Override\n protected void getExras() {\n }", "@Override\r\n\tpublic void publierEnchere() {\n\t\t\r\n\t}", "@Override\n\tpublic void nefesAl() {\n\n\t}", "@Override\n\tpublic void ligar() {\n\t\t\n\t}", "@Override\n public void func_104112_b() {\n \n }", "@Override\n\tprotected void initdata() {\n\n\t}", "@Override\n\tpublic void nghe() {\n\n\t}", "@Override\n public void function()\n {\n }", "@Override\n public void function()\n {\n }", "public final void mo51373a() {\n }", "@Override\r\n\tpublic void stehReagieren() {\r\n\t\t//\r\n\t}", "@Override\n public void inizializza() {\n\n super.inizializza();\n }", "@Override\n\tprotected void initData() {\n\t\t\n\t}", "@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}", "@Override\n\tpublic void sacrifier() {\n\t\t\n\t}", "@Override\r\n\tprotected void InitData() {\n\t\t\r\n\t}", "public void designBasement() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}", "public void gored() {\n\t\t\n\t}", "@Override\r\n\tprotected void initData() {\n\r\n\t}", "@Override\n\tpublic void einkaufen() {\n\t}", "@Override\n protected void initialize() {\n\n \n }", "public void mo38117a() {\n }", "@Override\n\tprotected void getData() {\n\t\t\n\t}", "Constructor() {\r\n\t\t \r\n\t }", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "@Override\n\tpublic void one() {\n\t\t\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "private stendhal() {\n\t}", "@Override\n\tprotected void update() {\n\t\t\n\t}", "@Override\n\t\t\tpublic void ic() {\n\t\t\t\t\n\t\t\t}", "@Override\n\tprotected void initData() {\n\n\t}", "@Override\n\tprotected void initData() {\n\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n public void init() {\n\n }", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\n\tpublic void debite() {\n\t\t\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "public contrustor(){\r\n\t}", "@Override\n\tprotected void initialize() {\n\n\t}", "@Override\r\n\tpublic void dispase() {\n\r\n\t}", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "@Override\n\tpublic void dtd() {\n\t\t\n\t}", "@Override\n\tprotected void logic() {\n\n\t}", "@Override\n\tprotected void lazyLoad() {\n\t\t\n\t}", "public void mo4359a() {\n }", "@Override\r\n\tprotected void initialize() {\n\r\n\t}", "@Override\n public void memoria() {\n \n }", "@Override\n\t\tpublic void method() {\n\t\t\t\n\t\t}", "private RepositorioAtendimentoPublicoHBM() {\r\t}", "@Override\n protected void initialize() \n {\n \n }", "@Override\r\n\tpublic void getProposition() {\n\r\n\t}", "@Override\n\tpublic void particular1() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n protected void prot() {\n }", "@Override\r\n\tpublic void init()\r\n\t{\n\t}", "@Override\n\tprotected void initValue()\n\t{\n\n\t}", "public void mo55254a() {\n }" ]
[ "0.6671074", "0.6567672", "0.6523024", "0.6481211", "0.6477082", "0.64591026", "0.64127725", "0.63762105", "0.6276059", "0.6254286", "0.623686", "0.6223679", "0.6201336", "0.61950207", "0.61950207", "0.61922914", "0.6186996", "0.6173591", "0.61327106", "0.61285484", "0.6080161", "0.6077022", "0.6041561", "0.6024072", "0.6020252", "0.59984857", "0.59672105", "0.59672105", "0.5965777", "0.59485507", "0.5940904", "0.59239364", "0.5910017", "0.5902906", "0.58946234", "0.5886006", "0.58839184", "0.58691067", "0.5857751", "0.58503544", "0.5847024", "0.58239377", "0.5810564", "0.5810089", "0.5806823", "0.5806823", "0.5800025", "0.5792378", "0.5792378", "0.5792378", "0.5792378", "0.5792378", "0.5792378", "0.5790187", "0.5789414", "0.5787092", "0.57844025", "0.57844025", "0.5774479", "0.5774479", "0.5774479", "0.5774479", "0.5774479", "0.5761362", "0.57596046", "0.57596046", "0.575025", "0.575025", "0.575025", "0.5747959", "0.57337177", "0.57337177", "0.57337177", "0.5721452", "0.5715831", "0.57142824", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.5711723", "0.57041645", "0.56991017", "0.5696783", "0.56881124", "0.56774884", "0.56734604", "0.56728", "0.56696945", "0.5661323", "0.5657007", "0.5655942", "0.5655942", "0.5655942", "0.56549734", "0.5654792", "0.5652974", "0.5650185" ]
0.0
-1
/ Metodo que devuelve el arraylist de tickets
public static ArrayList<Ticket> getTickets() { return ticketsBar; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public List<Ticket> getTickets() {return tickets;}", "public List<Ticket> getTicketList() {\r\n\t\treturn ticketList;\r\n\t}", "@Test\r\n\tpublic void testListTickets() {\n\t\tint i = 1;\r\n\t\tString[] types = {\"singleton\", \"head\", \"tail\"};\r\n\t\tJsonObject[] tickets = new JsonObject[0];\r\n\t\tfor (RandomOrgClient roc : rocs) {\r\n\t\t\tfor (String t : types) {\r\n\t\t\t\ttry {\r\n\t\t\t\t\ttickets = roc.listTickets(t);\r\n\t\t\t\t\tif (tickets != null && tickets.length > 0) {\r\n\t\t\t\t\t\tJsonObject ticket = tickets[0];\r\n\t\t\t\t\t\tif (t.equals(\"singleton\")) {\r\n\t\t\t\t\t\t\tcollector.checkThat(ticket.get(\"nextTicketId\").isJsonNull(), equalTo(true));\r\n\t\t\t\t\t\t\tcollector.checkThat(ticket.get(\"previousTicketId\").isJsonNull(), equalTo(true));\r\n\t\t\t\t\t\t} else if (t.equals(\"head\")) {\r\n\t\t\t\t\t\t\tcollector.checkThat(ticket.get(\"nextTicketId\").isJsonNull(), equalTo(false));\r\n\t\t\t\t\t\t\tcollector.checkThat(ticket.get(\"previousTicketId\").isJsonNull(), equalTo(true));\r\n\t\t\t\t\t\t} else if (t.equals(\"tail\")) {\r\n\t\t\t\t\t\t\tcollector.checkThat(ticket.get(\"nextTicketId\").isJsonNull(), equalTo(true));\r\n\t\t\t\t\t\t\tcollector.checkThat(ticket.get(\"previousTicketId\").isJsonNull(), equalTo(false));\r\n\t\t\t\t\t\t} else { \r\n\t\t\t\t\t\t\tcollector.addError(new Error(\"Invalid ticket type. \"));\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t} catch (Exception e) {\r\n\t\t\t\t\tcollector.addError(new Error(errorMessage(i, e, true)));\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\ti++;\r\n\t\t}\r\n\t}", "private void loadTickets() {\n\t\topenTickets.clear();\n\t\tclosedTickets.clear();\n\t\tArrayList<Ticket> tickets = jdbc.getTickets();\n\t\t\n\t\tfor (Ticket t : tickets) {\n\t\t\tUser u = jdbc.get_user(t.submittedBy);\n\t\t\tString submittedBy = \"Submitted By: \"+u.get_lastname()+\", \"+u.get_firstname();\n\t\t\tString id = \"Ticket ID: \"+t.ticketID;\n\t\t\tString title = \"Title: \"+t.title;\n\t\t\tif (t.isDone) {\n\t\t\t\tString status = \"Status: Closed\";\n\t\t\t\tString s = String.format(\"%-40s%-40s%-40s%-40s\", id, title, submittedBy, status);\n\t\t\t\tclosedTickets.addElement(s);\n\t\t\t} else {\n\t\t\t\tString status = \"Status: Open\";\n\t\t\t\tString s = String.format(\"%-30s%-30s%-30s%-30s\", id, title, submittedBy, status);\n\t\t\t\topenTickets.addElement(s);\n\t\t\t}\n\t\t}\n\t}", "private TicketList() {\n initTicketList();\n }", "public List<Ticket> getAllTickets(){\n List<Ticket> tickets=ticketRepository.findAll();\n return tickets;\n }", "public Set<Ticket> getTickets() { return Set.copyOf(tickets); }", "public ArrayList<Ticket> readTickets(String command) {\r\n try{\r\n ResultSet results = Connect.readSp(command);\r\n \r\n while (results.next()) {\r\n Ticket tkt = new Ticket();\r\n tkt.setTktNo(results.getInt(\"tktNo\"));\r\n tkt.setPersonellNo(results.getInt(\"staffNo\"));\r\n tkt.setProcessLeadNo(results.getInt(\"processLeadNo\"));\r\n tkt.setTktName(results.getString(\"name\"));\r\n tkt.setStatus(results.getString(\"status\"));\r\n tkt.setCategory(results.getString(\"category\"));\r\n System.out.println(\"this effin ticket \" + tkt.getTktNo());\r\n tkt.readComments();\r\n tkt.readTasks();\r\n tickets.add(tkt);\r\n }\r\n results.close();\r\n }\r\n catch (SQLException e) {\r\n System.out.println(\"Failure\"+e.getMessage( ));\r\n }\r\n return tickets;\r\n }", "public static ArrayList verTicket (String DNICliente) throws SQLException{\n PreparedStatement query=null;\n ResultSet resultado=null;\n ArrayList <Ticket> listaTickets=new ArrayList();\n try{\n query=Herramientas.getConexion().prepareStatement(\"SELECT * FROM ticket WHERE DNI_cliente=?\");\n query.setString(1, DNICliente);\n resultado=query.executeQuery();\n while(resultado.next()){\n DateTimeFormatter formatoFecha = DateTimeFormatter.ofPattern(\"dd/MM/yyyy\");\n DateTimeFormatter formatoHora = DateTimeFormatter.ofPattern(\"HH:mm\");\n LocalDate fecha=LocalDate.parse(resultado.getString(4),formatoFecha);\n LocalTime hora=LocalTime.parse(resultado.getString(5),formatoHora);\n ArrayList <LineaCompra> lineasT1=new ArrayList();\n Ticket t1=new Ticket(resultado.getInt(1),resultado.getInt(3),fecha,hora,resultado.getDouble(6),lineasT1);\n t1.verLineaTicket();\n listaTickets.add(t1);\n }\n } catch(SQLException ex){\n Herramientas.aviso(\"Ha habido un error al recuperar sus tickets\");\n Excepciones.pasarExcepcionLog(\"Ha habido un error al recuperar sus tickets\", ex);\n } finally{\n resultado.close();\n query.close();\n }\n return listaTickets;\n }", "public List<Ticket> getTicketsForPurchase() {\n if (ticket == null) {\n ticket = new ArrayList<Ticket>();\n }\n return this.ticket;\n }", "public Integer[] getTicketNumber() {\n return ticketNumber;\n }", "List<Ticket> getTickets(String status, String priority);", "public Set getLoggedInUserTickets();", "@Override\n\tpublic List<LotteryTicket> getAllLotteryTickets() {\n\t\tList<LotteryTicket> ticket = null;\n\t\ttry {\n\t\t\tticket = lotteryTicketRepository.findAllByIsCancelled(false);\n\t\t} catch (Exception exception) {\n\t\t\tLOGGER.error(\"Something went wrong in getAllLotteryTickets\" + exception);\n\t\t\tthrow new InternalServerError(\"Something went wrong in getting all lottery tickets\");\n\t\t}\n\n\t\t// Check if ticket list is empty\n\t\tif (ticket == null || ticket.size() == 0) {\n\t\t\tthrow new InternalServerError(\"No tickets found\");\n\t\t}\n\n\t\t// Return tickets list response\n\t\treturn ticket;\n\t}", "boolean createTicketAssignments(List<Ticket> tickets);", "public Set getTickets(String username);", "private void displayList(Ticket[] tickets){\n clrscr();\n System.out.println(\"Welcome to Zendesk Tickets Viewer!\\n\");\n System.out.println(\"Displaying PAGE \" + pageNumber + \"\\n\");\n System.out.printf(\"%-6s%-60s%-14s\\n\", \"ID\", \"Subject\", \"Date Created\");\n SimpleDateFormat sdf = new SimpleDateFormat(\"dd/MM/yyyy\");\n\n // Handles if API is unavailable\n if(tickets != null){\n for (Ticket t: tickets) {\n String s = t.getSubject();\n if(s.length() > 60){\n s = s.substring(0,58);\n s += \"..\";\n }\n System.out.printf(\"%-6s%-60s%-14s\\n\", t.getId(), s, sdf.format(t.getCreated_at()));\n }\n } else {\n System.out.println(\"Sorry! Failed to retrieve tickets. The API might be unavailable or Username / Token is incorrect\");\n }\n\n if(pageNumber > 1){\n System.out.print(\"<-- Previous Page (P) | \");\n }\n if(hasMore){\n System.out.println(\"Next Page (N) -->\");\n }\n System.out.println(\"\");\n System.out.println(\"View Ticket Details (-Enter ID Number-) | Quit (Q)\");\n System.out.println(\"\");\n if (hasMore && pageNumber > 1) {\n System.out.println(\"What would you like to do? ( P / N / Q / #ID )\");\n } else if (pageNumber > 1 && !hasMore){\n System.out.println(\"What would you like to do? ( P / Q / #ID )\");\n } else if (pageNumber == 1 && hasMore){\n System.out.println(\"What would you like to do? ( N / Q / #ID )\");\n } else {\n System.out.println(\"What would you like to do? ( Q / #ID )\");\n }\n }", "public List<Articulo> obtenerTodosLosArticulosDeTicket(Ticket ticket) {\n return this.articuloFacade.obtenerTodosLosArticulosDeUnTicket(ticket);\n }", "@GET(\"dev/gig/list_tickets/\")\n Call<List<TicketResp>> getTicketList(@Header(\"authorization\") String auth);", "@Override\n\tpublic List<IAdhocTicket> getCurrentTickets() {\n\t\tList<IAdhocTicket> currentTickets = new ArrayList<IAdhocTicket>();\n\t\tfor (int i = 0; i < currentTicketNo; i++) {\n\t\t\tif (currentTickets.get(i).isCurrent() == true) {\n\t\t\t\tcurrentTickets.add(currentTickets.get(i));\n\t\t\t}\n\t\t}\n\t\treturn currentTickets;\n\t}", "@Test\r\n\tpublic void testCreateTickets() {\n\t\tint i = 1;\r\n\t\tfor (RandomOrgClient roc : rocs) {\r\n\t\t\ttry {\r\n\t\t\t\tJsonObject[] result = roc.createTickets(1, true);\t\t\t\t\r\n\t\t\t\tcollector.checkThat(result[0], notNullValue());\r\n\t\t\t\t\r\n\t\t\t\tresult = roc.createTickets(1, false);\t\t\t\t\r\n\t\t\t\tcollector.checkThat(result[0], notNullValue());\r\n\t\t\t\t\r\n\t\t\t} catch (Exception e) {\r\n\t\t\t\tcollector.addError(new Error(errorMessage(i, e, true)));\r\n\t\t\t}\r\n\t\t\ti++;\r\n\t\t}\r\n\t}", "public List<ActividadEnSitio> obtenerTodasLasActividadesEnSitioDeUnTicket(Ticket ticket) {\n return this.actividadEnSitioFacade.obtenerTodasLasActividadesDeUnTicket(ticket);\n }", "@Test\n public void whenGetTickets_thenArrayOfTickets()\n throws Exception {\n \n \tCollection<Ticket> ticket = new ArrayList<Ticket>();\n \tticket.add(new Ticket((long) 2, 4, 360, Constants.STATUS_WAITING, null, null));\n \tticket.add(new Ticket((long) 1, 2, 180, Constants.STATUS_WAITING, null, null));\n \tgiven(ticketService.findAllTickets()).willReturn(ticket);\n\n mvc.perform(MockMvcRequestBuilders.get(\"/api/tickets\")\n .contentType(MediaType.APPLICATION_JSON))\n .andExpect(MockMvcResultMatchers.status().isOk())\n .andExpect(MockMvcResultMatchers.content().json(\"[\\r\\n\" + \n \" {\\r\\n\" + \n \" \\\"id\\\": 2,\\r\\n\" + \n \" \\\"totalodd\\\": 4.0,\\r\\n\" + \n \" \\\"possiblegain\\\": 360.0,\\r\\n\" + \n \" \\\"status\\\": 0\\r\\n\" + \n \" },\\r\\n\" + \n \" {\\r\\n\" + \n \" \\\"id\\\": 1,\\r\\n\" + \n \" \\\"totalodd\\\": 2.0,\\r\\n\" + \n \" \\\"possiblegain\\\": 180.0,\\r\\n\" + \n \" \\\"status\\\": 0\\r\\n\" + \n \" }\\r\\n\" + \n \"]\"));\n }", "@GetMapping(value=\"/ticket/alltickets\")\n\tpublic List<Ticket> getAllTickets(){\n\t\treturn ticketBookingService.getAllTickets();\n\t}", "public List<Ticket> getTicketAssignedToUser(String username) {\n\t\ttry {\n\t\t\tTypedQuery<Ticket> query = em.createNamedQuery(\"Ticket.findByAssignee\", Ticket.class);\n\t\t\tquery.setParameter(\"inUsername\", username);\n\t\t\tList<Ticket> tickets = query.getResultList();\n\t\t\tif (tickets != null) {\n\t\t\t\treturn tickets;\n\t\t\t} else {\n\t\t\t\treturn null;\n\t\t\t}\n\t\t} catch (Exception e) {\n\t\t\tlogger.log(Level.WARNING, \"Unpossible to fetch tickets\", e.getMessage());\n\t\t\treturn null;\n\t\t}\n\t}", "@Override\n\tpublic List<TicketModel> getTickets(RepositoryModel repository, TicketFilter filter) {\n\t\tJedis jedis = pool.getResource();\n\t\tList<TicketModel> list = new ArrayList<TicketModel>();\n\t\tif (jedis == null) {\n\t\t\treturn list;\n\t\t}\n\t\ttry {\n\t\t\t// Deserialize each journal, build the ticket, and optionally filter\n\t\t\tSet<String> keys = jedis.keys(key(repository, KeyType.journal, \"*\"));\n\t\t\tfor (String key : keys) {\n\t\t\t\t// {repo}:journal:{id}\n\t\t\t\tString id = key.split(\":\")[2];\n\t\t\t\tlong ticketId = Long.parseLong(id);\n\t\t\t\tList<Change> changes = getJournal(jedis, repository, ticketId);\n\t\t\t\tif (ArrayUtils.isEmpty(changes)) {\n\t\t\t\t\tlog.warn(\"Empty journal for {}:{}\", repository, ticketId);\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\tTicketModel ticket = TicketModel.buildTicket(changes);\n\t\t\t\tticket.project = repository.projectPath;\n\t\t\t\tticket.repository = repository.name;\n\t\t\t\tticket.number = ticketId;\n\n\t\t\t\t// add the ticket, conditionally, to the list\n\t\t\t\tif (filter == null) {\n\t\t\t\t\tlist.add(ticket);\n\t\t\t\t} else {\n\t\t\t\t\tif (filter.accept(ticket)) {\n\t\t\t\t\t\tlist.add(ticket);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// sort the tickets by creation\n\t\t\tCollections.sort(list);\n\t\t} catch (JedisException e) {\n\t\t\tlog.error(\"failed to retrieve tickets from Redis @ \" + getUrl(), e);\n\t\t\tpool.returnBrokenResource(jedis);\n\t\t\tjedis = null;\n\t\t} finally {\n\t\t\tif (jedis != null) {\n\t\t\t\tpool.returnResource(jedis);\n\t\t\t}\n\t\t}\n\t\treturn list;\n\t}", "private void populateTicketDBData(Map<String, ExtTicketVO> tickets) {\n\t\tif (tickets == null || tickets.isEmpty()) return;\n\t\tString sql = StringUtil.join(\"select distinct t.ticket_id, t.ticket_no\",\n\t\t\t\tDBUtil.FROM_CLAUSE, schema, \"wsla_ticket t\",\n\t\t\t\tDBUtil.WHERE_CLAUSE, \"t.ticket_no in (\", DBUtil.preparedStatmentQuestion(tickets.size()), \")\");\n\t\tlog.debug(sql);\n\n\t\tint x = 0;\n\t\ttry (PreparedStatement ps = dbConn.prepareStatement(sql)) {\n\t\t\tfor (String ticketId : tickets.keySet())\n\t\t\t\tps.setString(++x, ticketId);\n\n\t\t\tResultSet rs = ps.executeQuery();\n\t\t\twhile (rs.next()) {\n\t\t\t\tExtTicketVO tkt = tickets.get(rs.getString(2));\n\t\t\t\tif (tkt == null) {\n\t\t\t\t\tlog.error(\"could not find ticket for \" + rs.getString(2));\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\ttkt.setTicketId(rs.getString(1)); //these should be the same as ticketNo, but just in case\n\t\t\t\ttkt.setTicketIdText(rs.getString(2));\n\t\t\t}\n\n\t\t} catch (SQLException sqle) {\n\t\t\tlog.error(\"could not populate tickets from DB\", sqle);\n\t\t}\n\t}", "public @Nullable List<Ticket> getAllTicketsForDate(String dateString){\n return null;\n }", "List<Ticket> ticketDTOToTicket(List<TicketDTO> all);", "public static void main(String[] args) {\n TravelAgency Altayyar = new TravelAgency(20);\n \n //creating and storing object for processing using array\n Ticket[] ticketsToAdd = new Ticket[4];\n \n ticketsToAdd[0] = new BusTicket(\"Nora Ali\",\"Riyadh\",\"Jeddah\",\"28/02/2018\",\"Standard\",600);\n ticketsToAdd[1] = new AirlineTicket(\"Sara Saad\",\"Riyadh\",\"Khobar\",\"03/03/2018\",\"Business\",\"Flynas\");\n ticketsToAdd[2] = new AirlineTicket(\"Ahmad Ali\",\"Riyadh\",\"Dammam\",\"13/03/2018\",\"Economy\",\"Saudia\");\n ticketsToAdd[3] = new AirlineTicket(\"Maha Hamad\",\"Riyadh\",\"Jeddah\",\"20/04/2018\",\"Business\",\"Saudia\");\n \n //adding objects\n for (int i = 0; i < ticketsToAdd.length; i++) {\n \n boolean isAdded = Altayyar.addReservation(ticketsToAdd[i]);\n System.out.println((isAdded)?\"The Ticket was added successfully\":\"The Ticket was not added !\");\n }\n \n \n //display all the issued tickets \n Altayyar.display();\n \n\n //cancel a ticket\n boolean isCancelled = Altayyar.cancelReservation(0);\n System.out.println((isCancelled)?\"The ticket was found and cancelled successfully !\":\"Ticket was not found !\");\n \n \n \n \n \n //get and display all tickets belonging to Saudia \n Ticket[] saudiaTickets = Altayyar.allTickets(\"Saudia\");\n \n for (int i = 0; i < saudiaTickets.length; i++) {\n \n System.out.println(saudiaTickets[i].toString());\n }\n \n \n \n //display all the issued tickets after the update \n Altayyar.display();\n \n \n }", "public @Nullable List<Ticket> getPurchasedTicketsForEvent(@Nullable Event event) {\n\n return null;\n}", "public TicketsPanel(ArrayList<Ticket> ticket,JPanel rightPanel,UserList list) {\n initComponents();\n this.ticket=ticket;\n this.rightPanel=rightPanel;\n this.list=list;\n populate();\n }", "public static void sendTicket(Ticket t) throws SQLException {\r\n\t\ttools.Search.deleteTicket(t.getMesa());\r\n\t\tif(t.getProductosComanda().size() == 0) {\r\n\t\t\tm.getTicketsFrame().setTicketOnTable(t);\r\n\t\t\tm.getTablesFrame().setTicketOnTable(t.getMesa());\r\n\t\t\tbbddManager.TicketDBManager.deleteComanda(t.getMesa());\r\n\t\t\treturn;\r\n\t\t}\r\n\t\tticketsBar.add(t);\r\n\t\t\r\n\r\n\t\tm.getTicketsFrame().setTicketOnTable(t);\r\n\t\tm.getTablesFrame().setTicketOnTable(t.getMesa());\r\n\t\tbbddManager.TicketDBManager.insertComanda(t);\r\n\t}", "Ticket(int id)//Instanciacion del constructor de la clase con sus respectivos parametros.\r\n {\r\n ticketID=id;//inicializacion de atributo de la clase con los parametros recibidos en el constructor.\r\n }", "@Override\n\tpublic int getCount() {\n\t\treturn mTickets.size();\n\t}", "public List<ServicioTicket> obtenerTodosLosServiciosDeTicket() {\n return this.servicioTicketFacade.findAll();\n }", "@Test\n public void whenGetTickets_thenTickets()\n throws Exception {\n\n \tCollection<Ticket> ticket = new ArrayList<Ticket>();\n \tticket.add(new Ticket((long) 1, 4, 360, Constants.STATUS_WAITING, null, null));\n\n \tgiven(ticketService.findAllTickets()).willReturn(ticket);\n\n mvc.perform(MockMvcRequestBuilders.get(\"/api/tickets\")\n .contentType(MediaType.APPLICATION_JSON))\n .andExpect(MockMvcResultMatchers.status().isOk())\n .andExpect(MockMvcResultMatchers.content().json(\"[\\r\\n\" + \n \" {\\r\\n\" + \n \" \\\"id\\\": 1,\\r\\n\" + \n \" \\\"totalodd\\\": 4.0,\\r\\n\" + \n \" \\\"possiblegain\\\": 360.0,\\r\\n\" + \n \" \\\"status\\\": 0\\r\\n\" + \n \" }\\r\\n\" + \n \"]\"));\n }", "public void addTicket(LotteryTicket ticket)\r\n\t{\r\n\t\tlotteryTickets.add(ticket);\r\n\t}", "List<ticket_type> getTicketTypes(Connection conn) {\r\n\t\tList<ticket_type> types = new ArrayList<ticket_type>();\r\n\t\ttry {\r\n\t\t\tStatement stmt = conn.createStatement(ResultSet.TYPE_SCROLL_SENSITIVE, ResultSet.CONCUR_UPDATABLE);\r\n\t\t\tString query = \"select vtype, fine from ticket_type\";\r\n\t\t\tResultSet rs = stmt.executeQuery(query);\r\n\r\n\t\t\twhile(rs.next()) {\r\n\t\t\t\tticket_type vt = new ticket_type(rs.getString(\"vtype\"), rs.getFloat(\"fine\"));\r\n\t\t\t\ttypes.add(vt);\r\n\t\t\t}\r\n\t\t} catch (SQLException ex) {\r\n\t\t\tthrow new RuntimeException(ex);\r\n\t\t}\r\n\t\treturn types;\r\n\t}", "List<TicketDTO> ticketToTicketDTO(List<Ticket> all);", "public List<Ticket> getTransactionLog() {\r\n\t\treturn tickets;\r\n\t}", "@Test\r\n public void getEventTicketInstanceList() {\r\n System.out.println(\"getEventTicketInstanceList begin.\");\r\n\r\n // Model ID of event ticket instances you want to get.\r\n String modelId = \"eventTicketModelTest\";\r\n\r\n // Get a list of the event ticket instances.\r\n String urlSegment = \"eventticket/instance\";\r\n List<HwWalletObject> responseInstances = walletBuildService.getInstances(urlSegment, modelId, 5);\r\n System.out.println(\"Event ticket instances list: \" + CommonUtil.toJson(responseInstances));\r\n }", "private Ticket[] parseList(String HttpResponse){\n if(HttpResponse == null){\n return null;\n }\n //Parse JSON to Object\n Gson g = new GsonBuilder()\n .setDateFormat(\"yyyy-MM-dd'T'HH:mm:ssZ\")\n .create();\n JsonParser parser = new JsonParser();\n try{ // Try to parse the response\n JsonElement root = parser.parse(HttpResponse);\n if(root.isJsonObject()){\n JsonObject ob = root.getAsJsonObject();\n JsonArray ticketsArray = ob.get(\"tickets\").getAsJsonArray();\n Ticket[] tickets = g.fromJson(ticketsArray, Ticket[].class);\n prevPageURL = ob.getAsJsonObject(\"links\").get(\"prev\").getAsString();\n nextPageURL = ob.getAsJsonObject(\"links\").get(\"next\").getAsString();\n hasMore = ob.getAsJsonObject(\"meta\").get(\"has_more\").getAsBoolean();\n return tickets;\n }\n }\n catch(JsonSyntaxException jse){\n System.out.println(\"Not a valid Json String:\"+jse.getMessage());\n }\n return null;\n }", "public void receiveResultget_Ticket_List(\n com.xteam.tourismpay.PFTMXStub.Get_Ticket_ListResponse result) {\n }", "public List<Ticket> getTicketsReportedByUser(String username) {\n\t\ttry {\n\t\t\tTypedQuery<Ticket> query = em.createNamedQuery(\"Ticket.findByReported\", Ticket.class);\n\t\t\tquery.setParameter(\"inUsername\", username);\n\t\t\tList<Ticket> tickets = query.getResultList();\n\t\t\tif (tickets != null) {\n\t\t\t\treturn tickets;\n\t\t\t} else {\n\t\t\t\treturn null;\n\t\t\t}\n\t\t} catch (Exception e) {\n\t\t\tlogger.log(Level.WARNING, \"Unpossible to fetch tickets\", e.getMessage());\n\t\t\treturn null;\n\t\t}\n\n\t}", "public Ticket getTicket() {\n return ticket;\n }", "public CustomListAdapter(Activity activity, List<Ticket> TicketItems) {\n this.activity = activity;\n this.TicketItems = TicketItems;\n }", "List<Ticket> getListTicketByDriverIDAndStatus(String driverID, String status);", "private List<Change> getJournal(Jedis jedis, RepositoryModel repository, long ticketId) throws JedisException {\n\t\tif (ticketId <= 0L) {\n\t\t\treturn new ArrayList<Change>();\n\t\t}\n\t\tList<String> entries = jedis.lrange(key(repository, KeyType.journal, ticketId), 0, -1);\n\t\tif (entries.size() > 0) {\n\t\t\t// build a json array from the individual entries\n\t\t\tStringBuilder sb = new StringBuilder();\n\t\t\tsb.append(\"[\");\n\t\t\tfor (String entry : entries) {\n\t\t\t\tsb.append(entry).append(',');\n\t\t\t}\n\t\t\tsb.setLength(sb.length() - 1);\n\t\t\tsb.append(']');\n\t\t\tString journal = sb.toString();\n\n\t\t\treturn TicketSerializer.deserializeJournal(journal);\n\t\t}\n\t\treturn new ArrayList<Change>();\n\t}", "void setTicket(Ticket ticket) {\n this.ticket = ticket;\n }", "public static List<ViajeEntidad> getListaViajesEntidad(){\n List<ViajeEntidad> viajes = new ArrayList<>();\n Date date = new Date();\n ViajeEntidadPK viajePK = new ViajeEntidadPK();\n TaxiEntidad taxiByPkPlacaTaxi = new TaxiEntidad();\n ClienteEntidad clienteByPkCorreoCliente = new ClienteEntidad();\n clienteByPkCorreoCliente.setPkCorreoUsuario(\"[email protected]\");\n TaxistaEntidad taxistaByCorreoTaxi = new TaxistaEntidad();\n taxistaByCorreoTaxi.setPkCorreoUsuario(\"[email protected]\");\n OperadorEntidad agendaOperador = new OperadorEntidad();\n agendaOperador.setPkCorreoUsuario(\"[email protected]\");\n\n viajePK.setPkPlacaTaxi(\"CCC11\");\n viajePK.setPkFechaInicio(\"2019-01-01 01:01:01\");\n viajes.add(new ViajeEntidad(viajePK, \"2019-01-01 02:01:01\",\"5000\", 2, \"origen\",\"destino\", \"agenda\", \"agenda2\", taxiByPkPlacaTaxi, clienteByPkCorreoCliente, taxistaByCorreoTaxi, agendaOperador));\n viajePK.setPkPlacaTaxi(\"DDD11\");\n viajes.add(new ViajeEntidad(viajePK, \"2019-01-01 02:01:01\",\"5000\", 2, \"origen\",\"destino\", \"agenda\", \"agenda2\", taxiByPkPlacaTaxi, clienteByPkCorreoCliente, taxistaByCorreoTaxi, agendaOperador));\n viajePK.setPkPlacaTaxi(\"EEE11\");\n viajes.add(new ViajeEntidad(viajePK, \"2019-01-01 02:01:01\",\"5000\", 2, \"origen\",\"destino\", \"agenda\", \"agenda2\", taxiByPkPlacaTaxi, clienteByPkCorreoCliente, taxistaByCorreoTaxi, agendaOperador));\n\n return viajes;\n }", "public Ticket getCurrentTicket(){return this.currentTicket;}", "@Override\n\n public void run() {\n\n fetchTickets();\n\n }", "public void emptyTickets() {\r\n tickets.clear();\r\n }", "private void addEntry( List<TicketEntry> entries, JSONObject entry){\n //parsing the entry fields and building it\n String barcode = (String) entry.get(\"barcode\");\n String desc = (String) entry.get(\"description\");\n int amount = Integer.parseInt((String) entry.get(\"amount\"));\n double PPU = Double.parseDouble((String) entry.get(\"PPU\"));\n double discountRate = Double.parseDouble((String) entry.get(\"discountRate\"));\n entries.add(new TicketEntryImpl(barcode,desc,amount,PPU,discountRate));\n }", "public int getticketId() {\n \treturn ticketId;\n }", "public TiraList() {\n this.list = new Object[8];\n this.nextindex = 0;\n this.startIndex = 0;\n }", "List<TicketEntity> toEntityList(List<TicketDto> ticketDtoList);", "@Override\n public int getItemCount() {\n if (getTickets() == null)\n return 0;\n return getTickets().size();\n }", "public void listarTicketsEnFechas(int dia, int mes, int año, int dia2, int mes2, int año2){\r\n\t\tIterator<Ticket> itr = tickets.iterator();\r\n\t\tMesa mesaAuxiliar = new Mesa();\r\n\t\tTicket ticketAuxiliarMenor = new Ticket(mesaAuxiliar, 0, dia, mes, año);\r\n\t\tTicket ticketAuxiliarMayor = new Ticket(mesaAuxiliar, 0, dia2, mes2, año2);\r\n\t\tTicket aux;\r\n\t\twhile(itr.hasNext()){\r\n\t\t\taux = itr.next();\r\n\t\t\tif((aux.compareTo(ticketAuxiliarMenor) >= 0) && (aux.compareTo(ticketAuxiliarMayor) <= 0)){\r\n\t\t\t\taux.imprimirPorPantalla();\r\n\t\t\t}\r\n\t\t}\r\n\t}", "public void verLineaTicket() throws SQLException{\n try (PreparedStatement query = Herramientas.getConexion().prepareStatement(\"SELECT * FROM linea_ticket WHERE codigo_ticket=?\")) {\n query.setInt(1, this.getCodigo());\n try (ResultSet resultado = query.executeQuery()) {\n while(resultado.next()){\n LineaCompra lineaT1=new LineaCompra(resultado.getInt(2),resultado.getInt(3),resultado.getDouble(4));\n this.getLineasTicket().add(lineaT1);\n }\n }\n }\n }", "public Ticket getTicketById(int id) {\r\n\t\tfor (Iterator<Ticket> iter = ticketList.iterator(); iter.hasNext(); ) {\r\n\t\t\tTicket ticket = iter.next();\r\n\t\t\tif (ticket.getTicketId() == id) {\r\n\t\t\t\treturn ticket;\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn null;\r\n\t\t\r\n\t}", "java.util.List<WorldUps.UInitTruck> \n getTrucksList();", "@Override\n\tpublic byte[] getItem(int position) {\n\t\treturn mTickets.get(position);\n\t}", "public static void main(String[] args) throws Exception{\n TicketManager manager = new TicketManager();\n\n BufferedWriter fileOpen = new BufferedWriter(new FileWriter(\"open_tickets.txt\", true));\n Scanner inputFile = new Scanner(new File(\"open_tickets.txt\"));\n\n String dateFormat = \"EEE MMM dd hh:mm:ss z yyyy\";\n SimpleDateFormat format = new SimpleDateFormat(dateFormat);\n\n while (inputFile.hasNext())\n {\n Ticket open = new Ticket(inputFile.nextLine(), Integer.parseInt(inputFile.nextLine()),\n inputFile.nextLine(), format.parse(inputFile.nextLine()), null, null);\n\n ticketQueue.add(open);\n }\n fileOpen.close();\n\n //TODO problem 8 load open tickets from a file\n\n //TODO Problem 9 how will you know what ticket ID to start with?\n\n manager.mainMenu();\n }", "public void setNoOfTicket(String noOfTickets) {\n \r\n }", "List<TicketDto> toDtoList(List<TicketEntity> ticketEntityList);", "public List<TempWTask> getTaskList(){return taskList;}", "public void setTicketId(Integer ticketId) {\r\n this.ticketId = ticketId;\r\n }", "java.util.List<com.lvl6.proto.QuestProto.FullQuestProto> \n getNewlyAvailableQuestsList();", "@Override\r\n\tpublic Ticket buyTicket(String passenger, int route, int departure, int arrival) {\n\t\tint k = route;\r\n\t // Add sentinels to start and end\r\n\t\tMyLinkedList list = new MyLinkedList();\r\n\t\tNode head = list.init();\r\n\t\t//list.add(k);\r\n\t\tlist.print(head);\r\n\t\tSystem.out.println(\"链表长度为: \"+ list.get_length(head));\r\n\t\t//创建前驱结点(起点)和当前节点和目标节点(终点)\r\n\t Node predpred = new Node(departure-1);\r\n\t\tNode pred = new Node(departure);\r\n\t\tNode curr = pred.next;\r\n\t\tNode succ = new Node(arrival);\r\n\t\t//predpred.key = departure -1;\r\n\t\t//pred.key = departure;\r\n\t\t//succ.key = arrival;\r\n\r\n\t\t\r\n\t\tfor (int i = 1; i <= 8*100; i++){\r\n\t\t\thead.lock();\r\n\t\t try {\r\n\t\t pred = head;\r\n\t\t curr = pred.next;\r\n\t\t curr.lock();\r\n\t\t try {\r\n\t\t while (curr.key < succ.key) {\r\n\t\t \t //System.out.println(predpred.key);\r\n\t\t //System.out.println(curr.key + \" \" + succ.key);\r\n\t\t pred.unlock();\r\n\t\t pred = curr;\r\n\t\t curr = curr.next;\r\n\t\t curr.lock();\r\n\t\t }\r\n\t\t if (curr.key == succ.key) {\r\n\t\t \tpredpred.next = curr.next;\r\n\t\t\t\t\tticket.tid = k*1000 + i/100+100 + i%100;\r\n\t\t\t\t\tticket.passenger = passenger;\r\n\t\t\t\t\tticket.route = route;\r\n\t\t\t\t\tticket.coach = i/100+1;\r\n\t\t\t\t\tticket.seat = i%100;\r\n\t\t\t\t\tticket.departure = departure;\r\n\t\t\t\t\tticket.arrival = arrival;\r\n\t\t\t\t\t//System.out.println(\"lock\"+ ticket);\r\n\t\t\t\t\treturn ticket;\r\n\t\t }\r\n\t\t } finally {curr.unlock();}\r\n\t\t } finally {pred.unlock();}\r\n\t\t i++;\r\n\t\t\tlist.print(head);\r\n\t\t\tSystem.out.println(\"新链表长度为: \"+ list.get_length(head));\r\n\t\t}\r\n\r\n\t\t\r\n\t\t//检索每一张座位的区间。看看我的座位的区间在不在别人的区间内。\r\n\t\treturn null;\r\n\t}", "protected Ticket completeTicket()\n\t{\n\t\tif (tickets.size() != 0)\n\t\t{\n\t\t\treturn tickets.pop();\n\t\t}\n\t\telse \n\t\t{\n\t\t\treturn null;\n\t\t}\n\t}", "protected static LinkedList<Ticket> searchByName(LinkedList<Ticket> tickets)\n {\n LinkedList<Ticket> matchingTickets = new LinkedList<>();\n Scanner scan = new Scanner(System.in);\n String searchTerm = scan.nextLine();\n\n\n for (Ticket t : tickets)\n {\n if (t.getReporter().contains(searchTerm))\n {\n matchingTickets.add(t);\n }\n }\n\n return matchingTickets;\n }", "@Override\n\tpublic GetJiraTicketsDTO getJiraTickets(String status, Integer page, Integer pageSize) {\n\t\treturn null;\n\t}", "private List<LotteryTicketLine> createTicketLines(int lines, LotteryTicket ticket) {\n\t\tList<LotteryTicketLine> linesList = new ArrayList<>();\n\n\t\t// Iterate the lines\n\t\tfor (int linesItr = 1; linesItr <= lines; linesItr++) {\n\t\t\t// Generate appropriate parameters and add in list object\n\t\t\tint first = generateRandomNumber();\n\t\t\tint second = generateRandomNumber();\n\t\t\tint third = generateRandomNumber();\n\t\t\tLotteryTicketLine line = new LotteryTicketLine(first, second, third, getOutcome(first, second, third),\n\t\t\t\t\tticket);\n\t\t\tlinesList.add(line);\n\t\t}\n\t\treturn linesList;\n\t}", "public @Nullable List<Ticket> bookTickets(@Nonnull Event event, @Nullable User user, @Nullable List<Long> seats) {\n\n return null;\n }", "private ArrayList getCommitteList() {\r\n /**\r\n * This sends the functionType as 'G' to the servlet indicating to\r\n * get the details of all existing committees with the required\r\n * information\r\n */\r\n \r\n Vector vecBeans = new Vector();\r\n String connectTo = CoeusGuiConstants.CONNECTION_URL + \"/comMntServlet\";\r\n RequesterBean request = new RequesterBean();\r\n request.setDataObject(\"\"+CoeusConstants.IACUC_COMMITTEE_TYPE_CODE);\r\n request.setFunctionType(COMMITTEE_LIST_FOR_MODULE);\r\n AppletServletCommunicator comm = new AppletServletCommunicator(\r\n connectTo, request);\r\n /**\r\n * Updated for REF ID :0003 Feb'21 2003.\r\n * Hour Glass implementation while DB Trsactions Wait\r\n * by Subramanya Feb' 21 2003\r\n */\r\n setCursor( new Cursor( Cursor.WAIT_CURSOR ) );\r\n comm.send();\r\n ResponderBean response = comm.getResponse();\r\n setCursor( new Cursor( Cursor.DEFAULT_CURSOR ) );\r\n \r\n if (response.isSuccessfulResponse()) {\r\n vecBeans = response.getDataObjects();\r\n }\r\n return new ArrayList(vecBeans);\r\n }", "@Override\n\tpublic String toString() {\n\t\treturn this.ticketid+\"\\t\"+this.eatid+\"\\t\"+this.eatnum;\n\t}", "public abstract NSMutableArray<I_WorkFlowItem> tachesObligatoires();", "@Test\n\tpublic void testCreateTicketOk() {\n\t\tArrayList<Object> p = new ArrayList<Object>();\n\t\tp.add(new TGame(\"FORTNITE\", 6, 20.0, 1, 2, \"descripcion\", \"Shooter\"));\n\t\tTTicket tt = new TTicket(1, p);\n\t\tassertEquals();\n\t}", "public Map<String,Ticket> retriveTickets(IssueType issueType) throws IOException {\n\t\tMap<String,Ticket> tickets = new HashMap<>();\n\t\t\n\t\tInteger j = 0;\n\t\tInteger i = 0;\n\t\tInteger total = 1;\n\t //Get JSON API for closed bugs w/ AV in the project\n\t\tdo {\n\t\t\t//https://issues.apache.org/jira/rest/api/2/search?jql=project%20%3D%20OPENJPA%20AND%20issueType%20%3D%20Bug%20AND(%20status%20=%20closed%20OR%20status%20=%20resolved%20)AND%20resolution%20=%20fixed%20&fields=key,resolutiondate,versions,created&startAt=0&maxResults=1000\n\t\t\t//Only gets a max of 1000 at a time, so must do this multiple times if bugs >1000\n\t\t\tj = i + 1000;\n\t String url = basicUrl + \"search?jql=project%20%3D%20\"\n\t + this.projectName + \"%20AND%20issueType%20\" + issueType.getType() + \"%20AND(%20status%20=%20closed%20OR\"\n\t + \"%20status%20=%20resolved%20)AND%20resolution%20=%20fixed%20&fields=key,resolutiondate,versions,created&startAt=\"\n\t + i.toString() + \"&maxResults=\" + j.toString();\n\t JSONObject json = JSONTools.readJsonFromUrl(url);\n\t JSONArray issues = json.getJSONArray(\"issues\");\n\t total = json.getInt(\"total\");\n\t for (; i < total && i < j; i++) {\n\t //Iterate through each bug\n\t \t \n\t \tJSONObject issue = issues.getJSONObject(i%1000);\n\t \ttickets.put(issue.get(\"key\").toString(), new Ticket(this.projectName, issue.get(\"key\").toString(), issueType));\n\t \t\n\t } \n\t \n\t\t} while (i < total);\n\t\t\n\t\treturn tickets;\n\t \n\t}", "public int getTicketId() {\r\n return ticketId;\r\n }", "public static ArrayList<TicketType> getAllTicketTypesData() {\n\t\tList list = null;\n\t\tString filename = \".\\\\data\\\\ticketType.dat\";\n\t\tlist = (ArrayList)SerializeDB.readSerializedObject(filename); //Read data\n\t\t\n\t\treturn (ArrayList<TicketType>) list;\n\t}", "public static List<FlightInfo> AssignMultipleFlightData() {\n\n FlightInfo flight1 = new FlightInfo();\n flight1.setDeparts(new Date(2017 - 1900, 04, 21));\n\n Person person1 = new Person();\n person1.setFirstName(\"Tim\");\n //person1.setLastName(\"John\");\n\n Ticket ticket1 = new Ticket();\n ticket1.setPrice(200);\n\n ticket1.setPassenger(person1);\n\n flight1.setTickets(ticket1);\n\n FlightInfo flight2 = new FlightInfo();\n flight2.setDeparts(new Date(2017 - 1900, 04, 21));\n\n Person person2 = new Person();\n person2.setFirstName(\"Will\");\n person2.setLastName(\"Smith\");\n\n Ticket ticket2 = new Ticket();\n ticket2.setPrice(400);\n ticket2.setPassenger(person2);\n flight2.setTickets(ticket2);\n\n return Arrays.asList(flight1, flight2);\n }", "public Ticket(int ticketNumber) {\n\t\tthis.ticketNumber = Math.abs(ticketNumber);\n\t\tif (ticketList.contains(ticketNumber)) {\n\t\t\tthrow new IllegalArgumentException(\"Ticket Number already exists!\");\n\t\t} else {\n\t\t\tticketList.add(ticketNumber);\n\t\t}\n\n\t}", "public static void initializeData() {\n\t\tList list;\n\t\tint i;\n\t\tList data = new ArrayList<>();\n\t\tString filename = \".\\\\data\\\\ticketType.dat\";\n\t\t\n\t\tMovieType movieType;\n\t\tCinemaClass cinemaClass;\n\t\tMovieGoerGroup[] movieGoerGroupL;\n\t\tString[] dayOfWeekL;\n\t\tString[] isPublicHolidayL;\n\t\tdouble price;\n\t\tTicketType ticketType, temp;\n\t\t\n\t\t//Type 1\n\t\tmovieType = MovieType.REG;\n\t\tcinemaClass = CinemaClass.REG;\n\t\tmovieGoerGroupL = new MovieGoerGroup[] {MovieGoerGroup.SENIOR};\n\t\tdayOfWeekL = new String[] {\"Mon\", \"Tue\", \"Wed\", \"Thu\", \"Fri\"};\n\t\tisPublicHolidayL = new String[] {\"false\"};\n\t\tprice = 5;\n\t\tticketType = new TicketType(movieType,cinemaClass,movieGoerGroupL,dayOfWeekL,isPublicHolidayL,price);\n\t\tdata.add(ticketType);\n\t\t\n\t\t//Type 2\n\t\tmovieType = MovieType.REG;\n\t\tcinemaClass = CinemaClass.REG;\n\t\tmovieGoerGroupL = new MovieGoerGroup[] {MovieGoerGroup.STUDENT};\n\t\tdayOfWeekL = new String[] {\"Mon\", \"Tue\", \"Wed\", \"Thu\", \"Fri\"};\n\t\tisPublicHolidayL = new String[] {\"false\"};\n\t\tprice = 7;\n\t\tticketType = new TicketType(movieType,cinemaClass,movieGoerGroupL,dayOfWeekL,isPublicHolidayL,price);\n\t\tdata.add(ticketType);\n\t\t\n\t\t//Type 3\n\t\tmovieType = MovieType.REG;\n\t\tcinemaClass = CinemaClass.REG;\n\t\tmovieGoerGroupL = new MovieGoerGroup[] {MovieGoerGroup.ADULT};\n\t\tdayOfWeekL = new String[] {\"Mon\", \"Tue\", \"Wed\", \"Thu\", \"Fri\"};\n\t\tisPublicHolidayL = new String[] {\"false\"};\n\t\tprice = 9;\n\t\tticketType = new TicketType(movieType,cinemaClass,movieGoerGroupL,dayOfWeekL,isPublicHolidayL,price);\n\t\tdata.add(ticketType);\n\t\t\n\t\t//Type 4: Sat, Sun \n\t\tmovieType = MovieType.REG;\n\t\tcinemaClass = CinemaClass.REG;\n\t\tmovieGoerGroupL = new MovieGoerGroup[] {MovieGoerGroup.STUDENT, MovieGoerGroup.ADULT, MovieGoerGroup.SENIOR};\n\t\tdayOfWeekL = new String[] {\"Sat\", \"Sun\"};\n\t\tisPublicHolidayL = new String[] {\"false\"};\n\t\tprice = 13;\n\t\tticketType = new TicketType(movieType,cinemaClass,movieGoerGroupL,dayOfWeekL,isPublicHolidayL,price);\n\t\tdata.add(ticketType);\n\t\t\n\t\t//Type 5: public holiday \n\t\tmovieType = MovieType.REG;\n\t\tcinemaClass = CinemaClass.REG;\n\t\tmovieGoerGroupL = new MovieGoerGroup[] {MovieGoerGroup.STUDENT, MovieGoerGroup.ADULT, MovieGoerGroup.SENIOR};\n\t\tdayOfWeekL = new String[] {\"Mon\", \"Tue\", \"Wed\", \"Thu\", \"Fri\", \"Sat\", \"Sun\"};\n\t\tisPublicHolidayL = new String[] {\"true\"}; //public holiday\n\t\tprice = 13;\n\t\tticketType = new TicketType(movieType,cinemaClass,movieGoerGroupL,dayOfWeekL,isPublicHolidayL,price);\n\t\tdata.add(ticketType);\n\t\t\n\t\t//Type 6: Atmos cinemaType\n\t\tmovieType = MovieType.REG;\n\t\tcinemaClass = CinemaClass.ATMOS;\n\t\tmovieGoerGroupL = new MovieGoerGroup[] {MovieGoerGroup.STUDENT, MovieGoerGroup.ADULT, MovieGoerGroup.SENIOR};\n\t\tdayOfWeekL = new String[] {\"Mon\", \"Tue\", \"Wed\", \"Thu\", \"Fri\", \"Sat\", \"Sun\"};\n\t\tisPublicHolidayL = new String[] {\"true\", \"false\"}; \n\t\tprice = 14;\n\t\tticketType = new TicketType(movieType,cinemaClass,movieGoerGroupL,dayOfWeekL,isPublicHolidayL,price);\n\t\tdata.add(ticketType);\n\t\t\n\t\t//Type 7: Platinum cinemaType\n\t\tmovieType = MovieType.REG;\n\t\tcinemaClass = CinemaClass.PLATINUM;\n\t\tmovieGoerGroupL = new MovieGoerGroup[] {MovieGoerGroup.STUDENT, MovieGoerGroup.ADULT, MovieGoerGroup.SENIOR};\n\t\tdayOfWeekL = new String[] {\"Mon\", \"Tue\", \"Wed\", \"Thu\", \"Fri\", \"Sat\", \"Sun\"};\n\t\tisPublicHolidayL = new String[] {\"true\", \"false\"}; \n\t\tprice = 28;\n\t\tticketType = new TicketType(movieType,cinemaClass,movieGoerGroupL,dayOfWeekL,isPublicHolidayL,price);\n\t\tdata.add(ticketType);\n\t\t\n\t\t//3D movie: price + 2\n\t\tfor(i = 0 ; i < 7 ; i++) {\n\t\t\ttemp = (TicketType) data.get(i);\n\t\t\tticketType = new TicketType(MovieType._3D, temp.getCinemaClass(), temp.getMovieGoerGroupL(),\n\t\t\t\t\t\t\t\t\t\ttemp.getDayOfWeekL(), temp.getIsPublicHolidayL(), temp.getPrice() + 2);\n\t\t\tdata.add(ticketType);\n\t\t}\n\t\t\n\t\t//Blockbuster movie: price + 1\n\t\tfor(i = 0 ; i < 7 ; i++) {\n\t\t\ttemp = (TicketType) data.get(i);\n\t\t\tticketType = new TicketType(MovieType.BLOCKBUSTER, temp.getCinemaClass(), temp.getMovieGoerGroupL(),\n\t\t\t\t\t\t\t\t\t\ttemp.getDayOfWeekL(), temp.getIsPublicHolidayL(), temp.getPrice() + 2);\n\t\t\tdata.add(ticketType);\n\t\t}\n\t\t\n\t\tSerializeDB.writeSerializedObject(filename, data); //Write data\n\t}", "public void setTicketId(int value) {\r\n this.ticketId = value;\r\n }", "public Ticket(int codigo, int codigoSupermercado, LocalDate fechaCompra, LocalTime horaCompra, double PrecioTotal, ArrayList <LineaCompra> lineasTicket) {\n this.setCodigo(codigo);\n this.setCodigoSupermercado(codigoSupermercado);\n this.setFechaCompra(fechaCompra);\n this.setHoraCompra(horaCompra);\n this.setPrecioTotal(PrecioTotal);\n this.setLineasTicket(lineasTicket);\n }", "public void removeTicket(int num){\n if (!tickets.isEmpty() && num < tickets.size() && num > 0){\n tickets.remove(num);\n }\n }", "public int getNoOfTickets() {\n\t\treturn noOfTickets;\r\n\t}", "List<Reservation> trouverlisteDeReservationAyantUneDateDenvoieDeMail();", "private Ticket givenTicketInOrderedBilled() {\n CreateTicketVO createTicketVO = CreateTicketVO.newBuilder()\n .ticketIssuingType(TicketIssuingType.ONE_TICKET_FOR_ALL_PRODUCTS)\n .products(this.products)\n .paymentType(PaymentType.NO_PAYMENT)\n .account(this.account).build();\n TicketOrder ticketOrder = this.ticketFactory.createTickets(createTicketVO);\n Ticket ticket = ticketOrder.getBillingTicket();\n // [1,0] -> [8,0]\n ticket.nextStateOk();\n // [8,0] -> [8,1]\n ticket.nextStateOk();\n // [8,1] -> [8,4]\n ticket.nextStateOk();\n // [8,4] -> [8,2]\n ticket.nextStateOk();\n return ticket;\n }", "@Override\r\n\tpublic Vector getEntries() throws NotesApiException {\n\t\treturn null;\r\n\t}", "public static void main(String[] args) {\n LinkedList<Ticket> ticketQueue = new LinkedList<>();\n LinkedList<Ticket> resolvedTickets = new LinkedList<>();\n\n Scanner scan = new Scanner(System.in);\n\n while(true){\n\n System.out.println(\"1. Enter Ticket\\n2. Delete Ticket by ID\\n3. Delete Ticket by Issue\\n4. Find Ticket \" +\n \"by Reporter\\n5. Display All Tickets\\n6. View Resolved Tickets\\n7. Quit\");\n Integer task = Integer.parseInt(scan.next());\n\n if (task == 1) {\n //Call addTickets, which will let us enter any number of new tickets\n addTickets(ticketQueue);\n\n } else if (task == 2) {\n //delete a ticket\n // Takes two new arguments - one for a list of matching tickets for a search term, and the list of\n // resolved tickets we'll add to once we delete the ticket.\n deleteTicket(ticketQueue, null, resolvedTickets);\n\n } else if (task == 3) {\n // Ask for the search term and find all matching tickets, then delete from those options.\n System.out.println(\"Enter the search term:\");\n LinkedList<Ticket> matchingTickets = searchDescriptions(ticketQueue);\n deleteTicket(ticketQueue, matchingTickets, resolvedTickets);\n\n } else if (task == 4) {\n // Just displays a list of all tickets opened by a certain employee.\n System.out.println(\"Enter the name of the reporter:\");\n LinkedList<Ticket> matchingTickets = searchByName(ticketQueue);\n printAllTickets(matchingTickets);\n\n } else if (task == 5) {\n // Display all the unresolved tickets.\n printAllTickets(ticketQueue);\n\n } else if (task == 6) {\n // Display all the resolved tickets.\n printAllTickets(resolvedTickets);\n }\n\n else if ( task == 7 ) {\n //Quit. Future prototype may want to save all tickets to a file\n System.out.println(\"Quitting program\");\n break;\n }\n else {\n //this will happen for 3 or any other selection that is a valid int\n //TODO Program crashes if you enter anything else - please fix\n //Default will be print all tickets\n printAllTickets(ticketQueue);\n }\n }\n }", "public void setTicketId(int value) {\n this.ticketId = value;\n }", "protected static void addTicketInPriorityOrder(LinkedList<Ticket> tickets, Ticket newTicket){\n\n if (tickets.size() == 0 ) {//Special case - if list is empty, add ticket and return\n tickets.add(newTicket);\n return;\n }\n\n //Tickets with the HIGHEST priority number go at the front of the list. (e.g. 5=server on fire)\n //Tickets with the LOWEST value of their priority number (so the lowest priority) go at the end\n\n int newTicketPriority = newTicket.getPriority();\n\n for (int x = 0; x < tickets.size() ; x++) { //use a regular for loop so we know which element we are looking at\n\n //if newTicket is higher or equal priority than the this element, add it in front of this one, and return\n if (newTicketPriority >= tickets.get(x).getPriority()) {\n tickets.add(x, newTicket);\n return;\n }\n }\n\n //Will only get here if the ticket is not added in the loop\n //If that happens, it must be lower priority than all other tickets. So, add to the end.\n tickets.addLast(newTicket);\n }", "java.util.List<WorldUps.UTruck> \n getTruckstatusList();", "public TaskList (ArrayList<Task> tasks){ this.tasks = tasks;}", "@Override\n\t\t\tpublic void onNext(AutoNewTicketRequest value) {\n\t\t\t\t\n\t\t\t\tSystem.out.println(\"On Next is what!!\");\n\t\t\t\tList<TicketData> ticktDataList = new ArrayList<TicketData>();\n\t\t\t\tSystem.out.println(\"Total Ticket is : \"+ ticktDataList.size());\n\t\t\t\tfor(Ticket t : SimpleTicketStore.getTickets()) {\n\t\t\t\t\tticktDataList.add(Ticket2TicketData(t));\n\t\t\t\t}\n\t\t\t\tIterable<TicketData> ticktDataIterable=ticktDataList;\n\t\t\t\t\n\t\t\t\t\n\t\t\t\tint i=0;\n\t\t\t\tfor(StreamObserver<GetAllTicketResponse> observer: connected_clients) {\n\t\t\t\t\tSystem.out.println(\"Writing down to clietns\");\n\t\t\t\t\tobserver.onNext(GetAllTicketResponse.newBuilder().addAllTicketData(ticktDataIterable).build());\n\t\t\t\t\ti++;\n\t\t\t\t}\n\t\t\t\tSystem.out.println(i);\n\t\t\t}", "private void displayOneTicket(String id){\n clrscr();\n System.out.println(\"Viewing Ticket Details\\n\");\n try{\n String response = getTickets(\"https://alston.zendesk.com/api/v2/tickets/\" + id +\".json\");\n if(response == null){\n System.out.println(\"Sorry! Failed to find a ticket with ID: \" + id + \" This ticket might not exist.\");\n System.out.println(\"Enter anything to continue...\");\n return;\n }\n JsonParser parser = new JsonParser();\n try{\n JsonObject ticket = parser.parse(response).getAsJsonObject().getAsJsonObject(\"ticket\");\n System.out.printf(\"%-25s%s\\n\", \"ID: \", ticket.get(\"id\").toString());\n System.out.printf(\"%-25s%s\\n\", \"Subject: \", ticket.get(\"subject\").toString());\n\n Date date = new SimpleDateFormat(\"yyyy-MM-dd'T'HH:mm:ss'Z'\").parse(ticket.getAsJsonPrimitive(\"created_at\").getAsString());\n System.out.printf(\"%-25s%s\\n\", \"Date Created: \", date);\n\n date = new SimpleDateFormat(\"yyyy-MM-dd'T'HH:mm:ss'Z'\").parse(ticket.getAsJsonPrimitive(\"updated_at\").getAsString());\n System.out.printf(\"%-25s%s\\n\", \"Last Updated: \", date);\n\n System.out.printf(\"%-25s%s\\n\", \"Description: \", ticket.getAsJsonPrimitive(\"description\").getAsString().replace(\"\\n\", \"\\n \"));\n System.out.printf(\"%-25s%s\\n\", \"Requester ID: \", ticket.get(\"requester_id\").toString());\n System.out.printf(\"%-25s%s\\n\", \"Submitter ID: \", ticket.get(\"submitter_id\").toString());\n System.out.printf(\"%-25s%s\\n\", \"Organization ID: \", ticket.get(\"organization_id\").toString());\n System.out.printf(\"%-25s%s\\n\", \"Priority: \", ticket.get(\"priority\").toString());\n System.out.printf(\"%-25s%s\\n\", \"Allow Channelback: \", ticket.get(\"allow_channelback\").toString());\n System.out.printf(\"%-25s%s\\n\", \"Allow Attachments: \", ticket.get(\"allow_attachments\").toString());\n System.out.printf(\"%-25s%s\\n\", \"Status: \", ticket.get(\"status\").toString());\n\n String tagString = \"\";\n JsonArray tags = ticket.get(\"tags\").getAsJsonArray();\n for (JsonElement t: tags) {\n tagString += t + \", \";\n }\n if(tagString.length()>2){\n tagString = tagString.substring(0, tagString.length()-2);\n } else {\n tagString = null;\n }\n System.out.printf(\"%-25s%s\\n\", \"Tags: \", tagString);\n\n System.out.println(\"\\nPlease Press \\\"Enter\\\" to go Back\");\n }\n catch(JsonSyntaxException jse){\n System.out.println(\"Not a valid Json String:\"+jse.getMessage());\n } catch (ParseException e) {\n System.out.println(\"Error parsing date while fetching ticket details\");\n e.printStackTrace();\n }\n } catch (IOException e){\n System.out.println(\"Error with HTTP connection while displaying ticket\");\n }\n\n }" ]
[ "0.75586194", "0.68671143", "0.67782587", "0.67376435", "0.6628127", "0.6615181", "0.65266055", "0.65088093", "0.63738424", "0.62600255", "0.615191", "0.61338454", "0.6118507", "0.6008059", "0.60031945", "0.5914535", "0.5905084", "0.5900563", "0.58943284", "0.5878184", "0.58753514", "0.586414", "0.5857897", "0.5840296", "0.58173114", "0.5811563", "0.5800295", "0.5799145", "0.5789388", "0.5778358", "0.57759947", "0.57717836", "0.5740212", "0.5735645", "0.5733096", "0.5726286", "0.5714775", "0.5707898", "0.57061404", "0.56739557", "0.5622142", "0.5618916", "0.56180143", "0.5586762", "0.55727136", "0.5541013", "0.55388826", "0.5528553", "0.55271167", "0.5519162", "0.5505274", "0.54765445", "0.54526335", "0.5436531", "0.5433941", "0.5430118", "0.54183334", "0.5401137", "0.5386087", "0.53809667", "0.5372593", "0.53665173", "0.53645384", "0.5363524", "0.5331656", "0.5324667", "0.5307355", "0.5293341", "0.5285151", "0.527371", "0.5268771", "0.52687556", "0.5265848", "0.5261259", "0.5258502", "0.52570844", "0.52529156", "0.52397287", "0.52360547", "0.52274716", "0.5210333", "0.52095145", "0.5207028", "0.51972365", "0.5192616", "0.51903754", "0.5188355", "0.51877004", "0.5183788", "0.517475", "0.5173467", "0.51727486", "0.5169269", "0.5164939", "0.5161738", "0.5149253", "0.51461136", "0.5144636", "0.51392585", "0.5139187" ]
0.70152265
1
/ Metodo que llama al metodo que guarda comandas (Tickets) en la JTable.
public static void sendTicket(Ticket t) throws SQLException { tools.Search.deleteTicket(t.getMesa()); if(t.getProductosComanda().size() == 0) { m.getTicketsFrame().setTicketOnTable(t); m.getTablesFrame().setTicketOnTable(t.getMesa()); bbddManager.TicketDBManager.deleteComanda(t.getMesa()); return; } ticketsBar.add(t); m.getTicketsFrame().setTicketOnTable(t); m.getTablesFrame().setTicketOnTable(t.getMesa()); bbddManager.TicketDBManager.insertComanda(t); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void populate(){\n DefaultTableModel dtms = (DefaultTableModel)ticketTable.getModel();\n dtms.setRowCount(0);\n for(Ticket a:ticket)\n {\n Object[] row = new Object[dtms.getColumnCount()];\n row[0]=a;\n row[1]=a.getAirlineNO();\n row[2]=a.getCustomer();\n row[3]=a.getSeat();\n row[4]=a.getAirlineAgency();\n out.println(a+\" \"+a.getAirlineNO()+\" \"+a.getCustomer()+\" \"+a.getSeat()+\" \"+a.getAirlineAgency());\n dtms.addRow(row);\n }\n }", "public void popularTabela() {\n\n try {\n\n RelatorioRN relatorioRN = new RelatorioRN();\n\n ArrayList<PedidoVO> pedidos = relatorioRN.buscarPedidos();\n\n javax.swing.table.DefaultTableModel dtm = (javax.swing.table.DefaultTableModel) tRelatorio.getModel();\n dtm.fireTableDataChanged();\n dtm.setRowCount(0);\n\n for (PedidoVO pedidoVO : pedidos) {\n\n String[] linha = {\"\" + pedidoVO.getIdpedido(), \"\" + pedidoVO.getData(), \"\" + pedidoVO.getCliente(), \"\" + pedidoVO.getValor()};\n dtm.addRow(linha);\n }\n\n } catch (SQLException sqle) {\n\n JOptionPane.showMessageDialog(null, \"Erro: \" + sqle.getMessage(), \"Bordas\", JOptionPane.ERROR_MESSAGE);\n \n } catch (Exception e) {\n\n JOptionPane.showMessageDialog(null, \"Erro: \" + e.getMessage(), \"Bordas\", JOptionPane.ERROR_MESSAGE);\n }\n }", "public DefaultTableModel buscarlotes() {\n \n String encabezados[]= {\"Nombre\",\"Codigo\",\"Lote\",\"Vencimiento\",\"Dias Restantes\"};\n Control.ControlLote c = new Control.ControlLote();\n List<Modelo.Lotes> lotes = null;\n \n try {\n lotes = c.buscarlote();\n \n } catch (ClassNotFoundException ex) {\n Logger.getLogger(AgregarStock.class.getName()).log(Level.SEVERE, null, ex);\n }\n \n Long resta;//para saber cuanto queda de vencimiento\n java.util.Date fechaActual = new Date(); \n \n String [][] data = new String[lotes.size()][5];\n for (int i = 0; i < lotes.size(); i++) {\n \n resta=lotes.get(i).getVencimiento().getTime()-fechaActual.getTime();\n long dias = (resta / (1000 * 60 * 60 * 24))+1;\n \n \n data[i][0] = lotes.get(i).getNombre();\n data[i][1] = Long.toString(lotes.get(i).getCodigo());\n data[i][2] = lotes.get(i).getLote();\n data[i][3] = lotes.get(i).getVencimiento().toString();\n if(dias<1)\n data[i][4] = (\"Vencido\");\n else{\n data[i][4] = Long.toString(dias);\n }\n\n }\n\n jTable1.setDefaultRenderer (Object.class, new MiRender());\n \n return new DefaultTableModel(data,encabezados);\n }", "public void carga_bd_empleados(){\n try {\n Connection conectar = Conexion.conectar();\n PreparedStatement pst = conectar.prepareStatement(\n \"select nombre, edad, cargo, direccion, telefono from empleados\");\n\n ResultSet rs = pst.executeQuery();\n\n table = new JTable(model);\n jScrollPane1.setViewportView(table);\n table.setBackground(Color.yellow);\n\n model.addColumn(\"Nombre\");\n model.addColumn(\"Edad\");\n model.addColumn(\"Cargo\");\n model.addColumn(\"Direccion\");\n model.addColumn(\"Telefono\");\n\n while (rs.next()) {\n Object[] fila = new Object[8];\n //material mimaterial = new material();\n\n for (int i = 0; i < 5; i++) {\n fila[i] = rs.getObject(i + 1);\n }\n\n// model.addRow(fila);\n Empleado mimaterial = this.ChangetoEmpleado(fila);\n this.AddToArrayTableEmpleado(mimaterial);\n\n }\n\n conectar.close();\n \n } catch (SQLException e) {\n System.err.println(\"Error al llenar tabla\" + e);\n JOptionPane.showMessageDialog(null, \"Error al mostrar informacion\");\n\n }\n }", "public void PreencherTabela2() throws SQLException {\n\n String[] colunas = new String[]{\"ID do Pedido\", \"Numero Grafica\", \"Data Emissao\",\"Boleto\"};\n ArrayList dados = new ArrayList();\n Connection connection = ConnectionFactory.getConnection();\n PedidoDAO pedidoDAO = new PedidoDAO(connection);\n ModeloPedido modeloPedido = new ModeloPedido();\n modeloPedido = pedidoDAO.buscaPorId(idPedidoClasse);\n SimpleDateFormat format = new SimpleDateFormat(\"dd/MM/yyyy\");\n\n dados.add(new Object[]{modeloPedido.getId(), modeloPedido.getNumeroGrafica(), format.format(modeloPedido.getDataEmissao()), modeloPedido.isBoleto()});\n\n ModeloTabela modelo = new ModeloTabela(dados, colunas);\n\n jTablePedido.setModel(modelo);\n jTablePedido.setRowSorter(new TableRowSorter(modelo));\n jTablePedido.getColumnModel().getColumn(0).setPreferredWidth(2);\n jTablePedido.getColumnModel().getColumn(0).setResizable(false);\n jTablePedido.getColumnModel().getColumn(1).setPreferredWidth(20);\n jTablePedido.getColumnModel().getColumn(1).setResizable(false);\n\n jTablePedido.getTableHeader().setReorderingAllowed(false);\n connection.close();\n }", "public void llenadoDeTablas() {\n DefaultTableModel modelo = new DefaultTableModel();\n modelo.addColumn(\"ID Articulo\");\n modelo.addColumn(\"Fecha Ingreso\");\n modelo.addColumn(\"Nombre Articulo\");\n modelo.addColumn(\"Talla XS\");\n modelo.addColumn(\"Talla S\");\n modelo.addColumn(\"Talla M\");\n modelo.addColumn(\"Talla L\");\n modelo.addColumn(\"Talla XL\");\n modelo.addColumn(\"Color Articulo\");\n modelo.addColumn(\"Nombre Proveedor\");\n modelo.addColumn(\"Existencias\");\n\n RegistroArticuloDAO registroarcticuloDAO = new RegistroArticuloDAO();\n\n List<RegistroArticulo> registroarticulos = registroarcticuloDAO.select();\n TablaArticulo.setModel(modelo);\n String[] dato = new String[11];\n for (int i = 0; i < registroarticulos.size(); i++) {\n dato[0] = Integer.toString(registroarticulos.get(i).getPK_id_articulo());\n dato[1] = registroarticulos.get(i).getFecha_ingreso();\n dato[2] = registroarticulos.get(i).getNombre_articulo();\n dato[3] = registroarticulos.get(i).getTalla_articuloXS();\n dato[4] = registroarticulos.get(i).getTalla_articuloS();\n dato[5] = registroarticulos.get(i).getTalla_articuloM();\n dato[6] = registroarticulos.get(i).getTalla_articuloL();\n dato[7] = registroarticulos.get(i).getTalla_articuloXL();\n dato[8] = registroarticulos.get(i).getColor_articulo();\n dato[9] = registroarticulos.get(i).getNombre_proveedor();\n dato[10] = registroarticulos.get(i).getExistencia_articulo();\n\n //System.out.println(\"vendedor:\" + vendedores);\n modelo.addRow(dato);\n }\n }", "public void init2(){\n dateTextField.setText(String.valueOf(dateFormat.format(d)));\n Object [][] temp = new Object[realizarVenda.compra.size()][9];\n finalPurchaseTable.setModel(new javax.swing.table.DefaultTableModel(\n temp,\n new String [] {\n \"Pct#\", \"Nome\", \"Descrição\", \"Tamanho\", \"Valor\", \"Qntd\", \"Gênero\", \"Departamento\", \"Loja\"\n }\n ) {\n Class[] types = new Class [] {\n java.lang.Integer.class, java.lang.String.class, java.lang.String.class, java.lang.String.class, java.lang.Object.class, java.lang.Integer.class, java.lang.String.class, java.lang.String.class, java.lang.String.class\n };\n boolean[] canEdit = new boolean [] {\n false, false, false, false, false, false, false, false, false\n };\n\n public Class getColumnClass(int columnIndex) {\n return types [columnIndex];\n }\n\n public boolean isCellEditable(int rowIndex, int columnIndex) {\n return canEdit [columnIndex];\n }\n });\n finalPurchaseTable.setToolTipText(\"Pacote, Nome, Descrição, Tamanho, Valor, Quantidade, Gênero, Departamento, Loja\");\n finalPurchaseTable.getTableHeader().setReorderingAllowed(false);\n jScrollPane1.setViewportView(finalPurchaseTable);\n if (finalPurchaseTable.getColumnModel().getColumnCount() > 0) {\n finalPurchaseTable.getColumnModel().getColumn(0).setPreferredWidth(35);\n finalPurchaseTable.getColumnModel().getColumn(0).setMaxWidth(35);\n finalPurchaseTable.getColumnModel().getColumn(3).setPreferredWidth(45);\n finalPurchaseTable.getColumnModel().getColumn(3).setMaxWidth(45);\n finalPurchaseTable.getColumnModel().getColumn(4).setPreferredWidth(75);\n finalPurchaseTable.getColumnModel().getColumn(4).setMaxWidth(95);\n finalPurchaseTable.getColumnModel().getColumn(5).setPreferredWidth(45);\n finalPurchaseTable.getColumnModel().getColumn(5).setMaxWidth(45);\n finalPurchaseTable.getColumnModel().getColumn(6).setPreferredWidth(50);\n finalPurchaseTable.getColumnModel().getColumn(6).setMaxWidth(50);\n finalPurchaseTable.getColumnModel().getColumn(7).setPreferredWidth(70);\n finalPurchaseTable.getColumnModel().getColumn(7).setMaxWidth(70);\n finalPurchaseTable.getColumnModel().getColumn(8).setPreferredWidth(60);\n finalPurchaseTable.getColumnModel().getColumn(8).setMaxWidth(60);\n }\n for(int row = 0, col = 1;row<realizarVenda.compra.size();row++){\n finalPurchaseTable.setValueAt(realizarVenda.compra.get(row).remessa, row, 0);\n finalPurchaseTable.setValueAt(realizarVenda.compra.get(row).nome, row, col);\n finalPurchaseTable.setValueAt(realizarVenda.compra.get(row).desc, row, col+1);\n finalPurchaseTable.setValueAt(realizarVenda.compra.get(row).tamanho, row, col+2);\n finalPurchaseTable.setValueAt(realizarVenda.compra.get(row).valor.valor_final, row, col+ 3);\n finalPurchaseTable.setValueAt(realizarVenda.compra.get(row).quantidade, row, col+4);\n finalPurchaseTable.setValueAt(realizarVenda.compra.get(row).sexo, row, col+5);\n finalPurchaseTable.setValueAt(realizarVenda.compra.get(row).dept, row, col+6);\n finalPurchaseTable.setValueAt(realizarVenda.compra.get(row).loja, row, col+7);\n }\n percentLabel.setText(String.valueOf(taxa)+\"%\");\n }", "private DefaultTableModel getDatos3(){\n String folio = String.valueOf(venta.ns);\n //consulta sql\n String SQL_SELECT = \"SELECT p.Nombres,dv.Cantidad,dv.PrecioVenta FROM ventas v JOIN detalle_ventas dv ON v.IdVentas=dv.IdVentas JOIN producto p ON p.IdProducto=dv.IdProducto WHERE v.NumeroSerie = \"+folio+\"\";\n try {\n setTitutlos3();\n ps = con.getConnection().prepareStatement(SQL_SELECT);\n RS = ps.executeQuery();\n Object[] fila = new Object[3];\n while (RS.next()){\n fila[0] = RS.getString(1);\n fila[1] = RS.getInt(2);\n fila[2] = RS.getDouble(3);\n DT.addRow(fila);\n }\n //System.out.println(\"si hizo el desmadre\");\n } catch (SQLException e) {\n System.out.println(\"error en la tabla de ticket\");\n }\n \n return DT;\n \n }", "public void llenadoDeTablas() {\n /**\n *\n * creaccion de la tabla de de titulos \n */\n DefaultTableModel modelo = new DefaultTableModel();\n modelo.addColumn(\"ID Bitacora\");\n modelo.addColumn(\"Usuario\");\n modelo.addColumn(\"Fecha\");\n modelo.addColumn(\"Hora\");\n modelo.addColumn(\"Ip\");\n modelo.addColumn(\"host\");\n \n modelo.addColumn(\"Accion\");\n modelo.addColumn(\"Codigo Aplicacion\");\n modelo.addColumn(\"Modulo\");\n /**\n *\n * instaciamiento de las las clases Bitacora y BiracoraDAO\n * intaciamiento de la clases con el llenado de tablas\n */\n BitacoraDao BicDAO = new BitacoraDao();\n List<Bitacora> usuario = BicDAO.select();\n JtProductos1.setModel(modelo);\n String[] dato = new String[9];\n for (int i = 0; i < usuario.size(); i++) {\n dato[0] = usuario.get(i).getId_Bitacora();\n dato[1] = usuario.get(i).getId_Usuario();\n dato[2] = usuario.get(i).getFecha();\n dato[3] = usuario.get(i).getHora();\n dato[4] = usuario.get(i).getHost();\n dato[5] = usuario.get(i).getIp();\n dato[6] = usuario.get(i).getAccion();\n dato[7] = usuario.get(i).getCodigoAplicacion();\n dato[8] = usuario.get(i).getModulo();\n \n //System.out.println(\"vendedor:\" + vendedores);\n modelo.addRow(dato);\n }}", "private void updateTabela() {\n\n if (txBuscar.getText().isEmpty()) {\n ListaEmprestimosBEANs = new ControlerEmprestimos().listaEmprestimoss();\n } else {\n try {\n Integer buscar = Integer.parseInt(txBuscar.getText());\n ListaEmprestimosBEANs = new ArrayList<>();\n ListaEmprestimosBEANs.add(new ControlerEmprestimos().findEmprestimos(buscar));\n } catch (Exception e) {\n\n }\n }\n DefaultTableModel model = new DefaultTableModel(null, new String[]{\"ID\", \"Data de Saida\", \"Data Estimada do Retorno\", \"Data do Retorno\"});\n try {\n jTable1.setModel(model);\n String[] dados = new String[9];\n for (EmprestimosBEAN a : ListaEmprestimosBEANs) {\n dados[0] = String.valueOf(a.getId_emprestimo());\n dados[1] = a.getDtSaida().toString();\n dados[2] = a.getDtVolta().toString();\n dados[3] = a.getDtRetorno() == null ? \"\" : a.getDtRetorno().toString();\n model.addRow(dados);\n }\n } catch (Exception ex) {\n\n }\n\n }", "public verCustos() {\n initComponents();\n ArrayList<finances.custoItems> displayCustos = Estoque.allFinances.get(Estoque.allFinances.size()-1).custos;\n Object [][] temp = new Object[displayCustos.size()][3];\n despesasTable.setModel(new javax.swing.table.DefaultTableModel(\n temp,\n new String [] {\n \"Despesa\", \"Data\", \"Valor\"\n }\n ) {\n boolean[] canEdit = new boolean [] {\n false, false, false\n };\n\n public boolean isCellEditable(int rowIndex, int columnIndex) {\n return canEdit [columnIndex];\n }\n });\n \n for(int row = 0;row<displayCustos.size();row++){\n despesasTable.setValueAt(displayCustos.get(row).nome, row, 0);\n despesasTable.setValueAt(displayCustos.get(row).data, row, 1);\n despesasTable.setValueAt(displayCustos.get(row).valor, row, 2);\n }\n }", "private void listarDatos() {\n DBConnection conListar = new DBConnection();\n DefaultTableModel tableModel = new DefaultTableModel();\n String querty = \"SELECT P.codigo AS Cod_Prod, P.nombre, P.precio_compra AS P_Compra, P.precio_venta AS P_Venta, P.cantidad AS Stock, C.nombre AS Categoria FROM productos AS P JOIN categorias AS C ON P.categorias_id = C.categorias_id\";\n \n tableModel.addColumn(\"Cod. Prod\");\n tableModel.addColumn(\"Nombre\");\n tableModel.addColumn(\"P. Compra\");\n tableModel.addColumn(\"P. Venta\");\n tableModel.addColumn(\"Stock\");\n tableModel.addColumn(\"Categoria\");\n tableStock.setModel(tableModel);\n \n String datos[] = new String[6];\n\n try {\n Statement st = conListar.connetion().createStatement();\n ResultSet rs = st.executeQuery(querty);\n \n while (rs.next()) {\n \n datos[0] = rs.getString(1);\n datos[1] = rs.getString(2);\n datos[2] = rs.getString(3);\n datos[3] = rs.getString(4);\n datos[4] = rs.getString(5);\n datos[5] = rs.getString(6);\n \n tableModel.addRow(datos);\n \n }\n tableStock.setModel(tableModel);\n\n } catch (SQLException e) {\n System.out.println(e.getMessage() + e);\n JOptionPane.showMessageDialog(null, \"Insercion!\", \"Error\", JOptionPane.ERROR);\n } finally {\n try {\n conListar.closeConnection();\n System.err.println(\"Conexion listar stock cerrada\");\n } catch (SQLException ex) {\n Logger.getLogger(Stock.class.getName()).log(Level.SEVERE, null, ex);\n }\n }\n \n }", "public void buscaTodasOSs() {\n try {\n ServicoDAO sDAO = new ServicoDAO(); // instancia a classe ProdutoDB()\n ArrayList<OS> cl = sDAO.consultaTodasOs(); // coloca o método dentro da variável\n\n DefaultTableModel modeloTabela = (DefaultTableModel) jTable1.getModel();\n // coloca a tabela em uma variável do tipo DefaultTableModel, que permite a modelagem dos dados da tabela\n\n for (int i = modeloTabela.getRowCount() - 1; i >= 0; i--) {\n modeloTabela.removeRow(i);\n // loop que limpa a tabela antes de ser atualizada\n }\n\n for (int i = 0; i < cl.size(); i++) {\n // loop que pega os dados e insere na tabela\n Object[] dados = new Object[7]; // instancia os objetos. Cada objeto representa um atributo \n dados[0] = cl.get(i).getNumero_OS();\n dados[3] = cl.get(i).getStatus_OS();\n dados[4] = cl.get(i).getDefeito_OS();\n dados[5] = cl.get(i).getDataAbertura_OS();\n dados[6] = cl.get(i).getDataFechamento_OS();\n\n // pega os dados salvos do banco de dados (que estão nas variáveis) e os coloca nos objetos definidos\n modeloTabela.addRow(dados); // insere uma linha nova a cada item novo encontrado na tabela do BD\n }\n } catch (SQLException ex) {\n JOptionPane.showMessageDialog(null, \"Falha na operação.\\nErro: \" + ex.getMessage());\n } catch (Exception ex) {\n Logger.getLogger(FrmPesquisar.class.getName()).log(Level.SEVERE, null, ex);\n }\n }", "public void calendario4Dias(JTable tabla,String categoria, String f1,String f2,String f3,String f4)\n {String [] columna ={\"Cedula\",\"Nombres\",f1,f2,f3,f4};\n String [] pesos=new String [4];\n String [] fechas=new String [4];\n fechas[0]=f1;\n fechas[1]=f2;\n fechas[2]=f3;\n fechas[3]=f4;\n \n int filas;\n DefaultTableModel encabezado=new DefaultTableModel (null,columna);\n \n tabla.setModel(encabezado);\n String[] entrenadorDtos2 = new String[3];\n String sql = \"select * from federado \";\n PreparedStatement sentencia_sql = null;\n ResultSet rs = null;\n try {sentencia_sql = miConexion.prepareStatement(sql);\n rs = sentencia_sql.executeQuery(sql);\n while (rs.next()) {\n entrenadorDtos2[0]= rs.getString(\"idfederado\");\n entrenadorDtos2[1]= rs.getString(\"nombres\")+\"\"+rs.getString(\"apellidos\");\n encabezado.addRow(entrenadorDtos2);}\n rs.close();}\n catch (Exception e) {\n JOptionPane.showMessageDialog(null, \"Error en obtener los datos \" + e.getMessage());}\n \n /// llenar con peso\n filas=encabezado.getRowCount();\n String cedula,peso;\n for (int i = 0; i < filas; i++) {\n cedula=String.valueOf(encabezado.getValueAt(i, 0));\n for (int j = 0; j <= 3; j++) {\n sql = \"SELECT cargas.peso, cargas.serie \"+\n \"from federado, cargas, entrenamiento\" +\n \" where federado.idfederado=cargas.identrena and entrenamiento.idEntreno=cargas.idfede and cargas.fecha='\"+fechas[j]+\"' and federado.idfederado='\"+cedula+\"' and entrenamiento.tipo='\"+categoria+\"'\";\n \n PreparedStatement sentencia_sql2 = null;\n ResultSet rs2 = null;\n try {sentencia_sql2 = miConexion.prepareStatement(sql);\n rs2 = sentencia_sql2.executeQuery(sql);\n while (rs2.next()) {\n peso= rs2.getString(\"peso\")+\" \"+rs2.getString(\"serie\");\n encabezado.setValueAt(peso, i, j+2);\n }\n rs2.close();}\n catch (Exception e) {\n JOptionPane.showMessageDialog(null, \"Error en obtener los datos \" + e.getMessage());} \n } \n }}", "public void Buscar(){\n String consulta=\"\";\n try {\n tb_Grupo1.setModel(new DefaultTableModel());\n String titulos[]={\"Codigo\",\"Forma de Pago\",\"Descripcion Forma de pago\",\"CPT\",\"Descripcion Nomenclatura\",\"Precio\",\"\",\"\"};\n m=new DefaultTableModel(null,titulos);\n JTable p=new JTable(m);\n String fila[]=new String[8];\n\n Caja_Precio obj=new Caja_Precio();\n consulta=\"exec Caja_Precios_BUSCAR ?\";\n \n PreparedStatement cmd = obj.getCn().prepareStatement(consulta);\n cmd.setString(1, buscartodo.getText());\n ResultSet r= cmd.executeQuery();\n int c=1;\n while(r.next()){\n fila[0]=r.getString(1); // id de hc\n fila[1]=r.getString(2); // codigo de hc\n fila[2]=r.getString(3);\n fila[3]=r.getString(4);\n fila[4]=r.getString(5);\n fila[5]=r.getString(6);\n fila[6]=r.getString(7);\n fila[7]=r.getString(8);\n\n m.addRow(fila);\n c++;\n }\n tb_Grupo1.setModel(m);\n TableRowSorter<TableModel> elQueOrdena=new TableRowSorter<TableModel>(m);\n tb_Grupo1.setRowSorter(elQueOrdena);\n this.tb_Grupo1.setModel(m);\n\n formato();\n } catch (Exception e) {\n System.out.println(\"Error: \" + e.getMessage());\n }\n }", "public void PreencherTabela() throws SQLException {\n try (Connection connection = ConnectionFactory.getConnection()) {\n String[] colunas = new String[]{\"ID\", \"Nome\", \"Nomenclatura\", \"Quantidade\"};\n ArrayList dados = new ArrayList();\n for (ViewProdutoPedido v : viewProdutoPedidos) {\n dados.add(new Object[]{v.getId(), v.getNome(), v.getNomenclatura(), v.getQuantidade()});\n }\n ModeloTabela modelo = new ModeloTabela(dados, colunas);\n jTableItensPedido.setModel(modelo);\n jTableItensPedido.setRowSorter(new TableRowSorter(modelo));\n jTableItensPedido.getColumnModel().getColumn(0).setPreferredWidth(2);\n jTableItensPedido.getColumnModel().getColumn(0).setResizable(false);\n jTableItensPedido.getColumnModel().getColumn(1).setPreferredWidth(20);\n jTableItensPedido.getColumnModel().getColumn(1).setResizable(false);\n jTableItensPedido.getColumnModel().getColumn(2).setPreferredWidth(20);\n jTableItensPedido.getColumnModel().getColumn(2).setResizable(false);\n jTableItensPedido.getColumnModel().getColumn(3).setPreferredWidth(20);\n jTableItensPedido.getColumnModel().getColumn(3).setResizable(false);\n\n }\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n jScrollPane1 = new javax.swing.JScrollPane();\n tableticket = new javax.swing.JTable();\n\n setClosable(true);\n setIconifiable(true);\n setTitle(\"View Ticket Details\");\n\n tableticket.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n {null, null, null, null},\n {null, null, null, null},\n {null, null, null, null},\n {null, null, null, null}\n },\n new String [] {\n \"Title 1\", \"Title 2\", \"Title 3\", \"Title 4\"\n }\n ));\n tableticket.addMouseListener(new java.awt.event.MouseAdapter() {\n public void mouseClicked(java.awt.event.MouseEvent evt) {\n tableticketMouseClicked(evt);\n }\n });\n jScrollPane1.setViewportView(tableticket);\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());\n getContentPane().setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addContainerGap()\n .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 722, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addContainerGap())\n );\n\n pack();\n }", "private void carregarTabela() {\n try {\n\n Vector<String> cabecalho = new Vector();\n cabecalho.add(\"Id\");\n cabecalho.add(\"Nome\");\n cabecalho.add(\"CPF\");\n cabecalho.add(\"Telefone\");\n cabecalho.add(\"Endereço\");\n cabecalho.add(\"E-mail\");\n cabecalho.add(\"Data de Nascimento\");\n\n Vector detalhe = new Vector();\n\n for (Cliente cliente : new NCliente().listar()) {\n Vector<String> linha = new Vector();\n\n linha.add(cliente.getId() + \"\");\n linha.add(cliente.getNome());\n linha.add(cliente.getCpf());\n linha.add(cliente.getTelefone());\n linha.add(cliente.getEndereco());\n linha.add(cliente.getEmail());\n linha.add(cliente.getData_nascimento().toString());\n detalhe.add(linha);\n\n }\n\n tblClientes.setModel(new DefaultTableModel(detalhe, cabecalho));\n\n } catch (Exception e) {\n JOptionPane.showMessageDialog(this, e.getMessage());\n }\n\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n jScrollPane1 = new javax.swing.JScrollPane();\n ticketTable = new javax.swing.JTable();\n backBTN = new javax.swing.JButton();\n jButton1 = new javax.swing.JButton();\n\n ticketTable.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n\n },\n new String [] {\n \"Ticket Order\", \"Airline number\", \"Customer\", \"Seat\", \"Airliner\"\n }\n ));\n jScrollPane1.setViewportView(ticketTable);\n\n backBTN.setText(\"<BACK\");\n backBTN.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n backBTNActionPerformed(evt);\n }\n });\n\n jButton1.setText(\"Delete Ticket\");\n jButton1.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n jButton1ActionPerformed(evt);\n }\n });\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);\n this.setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addContainerGap()\n .addComponent(backBTN)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 548, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGroup(layout.createSequentialGroup()\n .addGap(263, 263, 263)\n .addComponent(jButton1)))\n .addContainerGap(50, Short.MAX_VALUE))\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 386, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(backBTN))\n .addGap(18, 18, 18)\n .addComponent(jButton1)\n .addContainerGap(15, Short.MAX_VALUE))\n );\n }", "private void createTable(){\n Object[][] data = new Object[0][8];\n int i = 0;\n for (Grupo grupo : etapa.getGrupos()) {\n Object[][] dataAux = new Object[data.length+1][8];\n System.arraycopy(data, 0, dataAux, 0, data.length);\n dataAux[i++] = new Object[]{grupo.getNum(),grupo.getAtletas().size(),\"Registar Valores\",\"Selecionar Vencedores\", \"Selecionar Atletas\"};\n data = dataAux.clone();\n }\n\n //COLUMN HEADERS\n String columnHeaders[]={\"Numero do Grupo\",\"Número de Atletas\",\"\",\"\",\"\"};\n\n tableEventos.setModel(new DefaultTableModel(\n data,columnHeaders\n ));\n //SET CUSTOM RENDERER TO TEAMS COLUMN\n tableEventos.getColumnModel().getColumn(2).setCellRenderer(new ButtonRenderer());\n tableEventos.getColumnModel().getColumn(3).setCellRenderer(new ButtonRenderer());\n tableEventos.getColumnModel().getColumn(4).setCellRenderer(new ButtonRenderer());\n\n //SET CUSTOM EDITOR TO TEAMS COLUMN\n tableEventos.getColumnModel().getColumn(2).setCellEditor(new ButtonEditor(new JTextField(), this.etapa));\n tableEventos.getColumnModel().getColumn(3).setCellEditor(new ButtonEditor(new JTextField(), this.etapa));\n tableEventos.getColumnModel().getColumn(4).setCellEditor(new ButtonEditor(new JTextField(), this.etapa));\n\n }", "public void bRevDetailsActionPerformed() {\n try {\n Date today = new Date();\n Calendar cal = new GregorianCalendar();\n cal.setTime(today);\n cal.add(Calendar.DAY_OF_MONTH, +30);\n Date today30 = cal.getTime();\n String day30 = formatter.format(today30.getTime());\n ResultSet rs = DBControl.getResultFromLocalDB(\"SELECT * FROM fas_details WHERE '\" + day30 + \"' > veh_rev_exp AND veh_rev_exp != '\" + nul + \"' ORDER BY veh_rev_exp\");\n DefaultTableModel dtm = (DefaultTableModel) tblRevenue.getModel();\n dtm.setRowCount(0);\n while (rs.next()) {\n Vector v = new Vector();\n v.add(rs.getString(\"equipment_no\"));\n v.add(rs.getString(\"registration_no\"));\n v.add(rs.getString(\"veh_rev_no\"));\n v.add(rs.getString(\"veh_rev_issue\"));\n v.add(rs.getString(\"veh_rev_exp\"));\n dtm.addRow(v);\n }\n } catch (Exception ex) {\n Logger.getLogger(fas_reports.class.getName()).log(Level.SEVERE, null, ex);\n }\n }", "public void setData()\n {\n lbl_f_Name.setText(\"Name: \" + obj_Faculty.getName());\n lbl_f_ID.setText(\"ID: \" + obj_Faculty.getId());\n\n //CODE for fetching data from DB from tbl_Up_Events and show on table\n //Things for DB\n //Connection_to_DB it connects to Access DB\n Connect_to_DB obj_conDB = new Connect_to_DB();\n Connection obj_con = obj_conDB.make_Connection();\n\n //Statement is used for updating, inserting and deleting\n Statement stmt = null;\n ResultSet res = null;\n\n try\n {\n stmt = obj_con.createStatement();\n\n String str_Data = \"select * from tbl_Up_Events\";\n\n res = stmt.executeQuery(str_Data);\n\n while (res.next())\n {\n String Name = res.getString(\"evntName\");\n String Day = res.getString(\"evntDay\");\n String Date = res.getString(\"evntDate\");\n String Venue = res.getString(\"evntVenue\");\n String Budget = res.getString(\"evntBudget\");\n String Descript = res.getString(\"evntDescript\");\n String Club = res.getString(\"evntClub\");\n String Ticket = res.getString(\"evntTicket\");\n\n String table[] =\n {\n Name, Day, Date, Venue, Budget, Descript, Club, Ticket\n };\n\n DefaultTableModel tblModel = (DefaultTableModel) tbl_Event.getModel();\n tblModel.addRow(table);\n }\n\n obj_con.close();\n\n }\n catch (Exception ex)\n {\n JOptionPane.showMessageDialog(null, ex);\n }\n //CODE for tables ENDS\n }", "private void preencherTabelaVeiculoCarga() {\n\n ArrayList dados = new ArrayList();\n cargaDao = new CargaDao();\n Carga carga;\n String[] colunas = new String[]{\"ID\", \"DESCRICAO\", \"STATUS\"};\n\n try {\n final List<Object> listaCarga = cargaDao.listarCargasDoVeiculo(idVeiculoSelecionado);\n\n if (listaCarga != null && listaCarga.size() > 0) {\n for (Object cargaAtual : listaCarga) {\n carga = (Carga) cargaAtual;\n dados.add(new Object[]{carga.getIdCarga(), carga.getDescricao(), carga.getStatus()});\n }\n }\n\n ModeloTabela modTabela = new ModeloTabela(dados, colunas);\n jTB_VeiculoCarga.setModel(modTabela);\n jTB_VeiculoCarga.getColumnModel().getColumn(0).setPreferredWidth(100);\n jTB_VeiculoCarga.getColumnModel().getColumn(0).setResizable(false);\n jTB_VeiculoCarga.getColumnModel().getColumn(1).setPreferredWidth(300);\n jTB_VeiculoCarga.getColumnModel().getColumn(1).setResizable(false);\n jTB_VeiculoCarga.getColumnModel().getColumn(2).setPreferredWidth(150);\n jTB_VeiculoCarga.getColumnModel().getColumn(2).setResizable(false);\n\n jTB_VeiculoCarga.getTableHeader().setReorderingAllowed(false);\n jTB_VeiculoCarga.setAutoResizeMode(JTable.AUTO_RESIZE_OFF);\n jTB_VeiculoCarga.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);\n\n jTB_VeiculoCarga.addMouseListener(new MouseAdapter() {\n\n @Override\n public void mouseClicked(MouseEvent e) {\n try {\n List<Object> lista = cargaDao.listarCargasDoVeiculo(idVeiculoSelecionado);\n cargaSelecionada = (Carga) lista.\n get(jTB_VeiculoCarga.convertRowIndexToModel(jTB_VeiculoCarga.getSelectedRow()));\n\n // if (veiculoDao.listarVeiculosAtivos().size() > 0 && veiculoDao.listarVeiculosAtivos() != null) {}\n } catch (Exception ex) {\n JOptionPane.showMessageDialog(FormVeiculoCargas.this, \"Erro genérico1: \" + ex.getMessage());\n ex.printStackTrace(System.err);\n }\n }\n\n });\n\n } catch (Exception e) {\n JOptionPane.showMessageDialog(this, \"Erro genérico2: \" + e.getMessage());\n }\n }", "private void carregarTabela() {\n try {\n\n Vector<String> cabecalho = new Vector();\n cabecalho.add(\"Id\");\n cabecalho.add(\"Nome\");\n cabecalho.add(\"Telefone\");\n cabecalho.add(\"Titular\");\n cabecalho.add(\"Data de Nascimento\");\n\n Vector detalhe = new Vector();\n\n for (Dependente dependente : new NDependente().listar()) {\n Vector<String> linha = new Vector();\n\n linha.add(dependente.getId() + \"\");\n linha.add(dependente.getNome());\n linha.add(dependente.getTelefone());\n linha.add(new NCliente().consultar(dependente.getCliente_id()).getNome());\n linha.add(dependente.getDataNascimento().toString());\n detalhe.add(linha);\n\n }\n\n tblDependentes.setModel(new DefaultTableModel(detalhe, cabecalho));\n\n } catch (Exception e) {\n JOptionPane.showMessageDialog(this, e.getMessage());\n }\n\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n jScrollPane1 = new javax.swing.JScrollPane();\n tabelaDados = new javax.swing.JTable();\n lblNome = new javax.swing.JLabel();\n txtNome = new javax.swing.JTextField();\n lblCategoria = new javax.swing.JLabel();\n cbCategoria = new javax.swing.JComboBox<>();\n lblPrecoCusto = new javax.swing.JLabel();\n txtPrecoCusto = new javax.swing.JTextField();\n lblData = new javax.swing.JLabel();\n lblQuantidade = new javax.swing.JLabel();\n txtQuantidade = new javax.swing.JTextField();\n lblFornecedor = new javax.swing.JLabel();\n cbMarca = new javax.swing.JComboBox<>();\n lblVendedor = new javax.swing.JLabel();\n txtVendedor = new javax.swing.JTextField();\n jSeparator1 = new javax.swing.JSeparator();\n lblDescricao = new javax.swing.JLabel();\n txtDescricao = new javax.swing.JTextField();\n txtEmail = new javax.swing.JTextField();\n lblEmail = new javax.swing.JLabel();\n lblTelefone = new javax.swing.JLabel();\n txtTelefone = new javax.swing.JTextField();\n jSeparator2 = new javax.swing.JSeparator();\n lblDadosProdutos = new javax.swing.JLabel();\n jSeparator3 = new javax.swing.JSeparator();\n jLabel3 = new javax.swing.JLabel();\n lblCidade = new javax.swing.JLabel();\n txtCidade = new javax.swing.JTextField();\n txtData1 = new javax.swing.JFormattedTextField();\n btnNovo = new javax.swing.JButton();\n btnIncluir = new javax.swing.JButton();\n btnAlterar = new javax.swing.JButton();\n btnExcluir = new javax.swing.JButton();\n btnImprimir = new javax.swing.JButton();\n btnSair = new javax.swing.JButton();\n lblEstadoProduto = new javax.swing.JLabel();\n cbEstadoProduto = new javax.swing.JComboBox<>();\n\n setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);\n setTitle(\"Cadastro dos produtos\");\n addWindowListener(new java.awt.event.WindowAdapter() {\n public void windowOpened(java.awt.event.WindowEvent evt) {\n formWindowOpened(evt);\n }\n });\n getContentPane().setLayout(new org.netbeans.lib.awtextra.AbsoluteLayout());\n\n tabelaDados.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n\n },\n new String [] {\n \"Id\", \"Nome\", \"Marca\", \"Vendedor\", \"Preço Unitário\", \"Quantidade\", \"Data\", \"Estado\"\n }\n ) {\n boolean[] canEdit = new boolean [] {\n false, false, false, false, false, false, false, false\n };\n\n public boolean isCellEditable(int rowIndex, int columnIndex) {\n return canEdit [columnIndex];\n }\n });\n tabelaDados.addMouseListener(new java.awt.event.MouseAdapter() {\n public void mouseClicked(java.awt.event.MouseEvent evt) {\n tabelaDadosMouseClicked(evt);\n }\n });\n jScrollPane1.setViewportView(tabelaDados);\n\n getContentPane().add(jScrollPane1, new org.netbeans.lib.awtextra.AbsoluteConstraints(12, 10, 630, 100));\n\n lblNome.setText(\"Nome do Produto:\");\n getContentPane().add(lblNome, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 150, -1, -1));\n\n txtNome.setToolTipText(\"Digite o nome do produto\");\n txtNome.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n txtNomeActionPerformed(evt);\n }\n });\n getContentPane().add(txtNome, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 170, 310, -1));\n\n lblCategoria.setText(\"Categoria do Produto:\");\n getContentPane().add(lblCategoria, new org.netbeans.lib.awtextra.AbsoluteConstraints(230, 200, -1, -1));\n\n cbCategoria.setModel(new javax.swing.DefaultComboBoxModel<>(new String[] { \"Periféricos\", \"Componentes de Computador\", \"Televisores\", \"Projetores\", \"Cabos\", \"Ferramentas\", \" \", \" \" }));\n cbCategoria.setToolTipText(\"Escolha a categoria do produto\");\n getContentPane().add(cbCategoria, new org.netbeans.lib.awtextra.AbsoluteConstraints(230, 220, 190, -1));\n\n lblPrecoCusto.setText(\"Preço Unitário\");\n getContentPane().add(lblPrecoCusto, new org.netbeans.lib.awtextra.AbsoluteConstraints(250, 250, -1, -1));\n\n txtPrecoCusto.setToolTipText(\"Informe o preço de custo\");\n getContentPane().add(txtPrecoCusto, new org.netbeans.lib.awtextra.AbsoluteConstraints(250, 270, 150, -1));\n\n lblData.setText(\"Data:\");\n getContentPane().add(lblData, new org.netbeans.lib.awtextra.AbsoluteConstraints(490, 250, -1, -1));\n\n lblQuantidade.setText(\"Quantidade:\");\n getContentPane().add(lblQuantidade, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 250, -1, -1));\n\n txtQuantidade.setToolTipText(\"Informe a quantidade\");\n getContentPane().add(txtQuantidade, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 270, 150, -1));\n\n lblFornecedor.setText(\"Marca:\");\n getContentPane().add(lblFornecedor, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 200, -1, -1));\n\n cbMarca.setModel(new javax.swing.DefaultComboBoxModel<>(new String[] { \"Intel\", \"Logitech\", \"Dell\", \"Asus\", \"Samsung\" }));\n cbMarca.setToolTipText(\"Informe a marca\");\n getContentPane().add(cbMarca, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 220, 190, -1));\n\n lblVendedor.setText(\"Vendedor:\");\n getContentPane().add(lblVendedor, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 330, -1, -1));\n getContentPane().add(txtVendedor, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 350, 150, -1));\n getContentPane().add(jSeparator1, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 160, -1, -1));\n\n lblDescricao.setText(\"Descrição:\");\n getContentPane().add(lblDescricao, new org.netbeans.lib.awtextra.AbsoluteConstraints(330, 150, -1, -1));\n\n txtDescricao.setToolTipText(\"Descrição do produto\");\n txtDescricao.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n txtDescricaoActionPerformed(evt);\n }\n });\n getContentPane().add(txtDescricao, new org.netbeans.lib.awtextra.AbsoluteConstraints(330, 170, 310, -1));\n getContentPane().add(txtEmail, new org.netbeans.lib.awtextra.AbsoluteConstraints(250, 350, 150, -1));\n\n lblEmail.setText(\"Email do Vendedor:\");\n getContentPane().add(lblEmail, new org.netbeans.lib.awtextra.AbsoluteConstraints(250, 330, -1, -1));\n\n lblTelefone.setText(\"Telefone do Vendedor:\");\n getContentPane().add(lblTelefone, new org.netbeans.lib.awtextra.AbsoluteConstraints(490, 330, -1, -1));\n getContentPane().add(txtTelefone, new org.netbeans.lib.awtextra.AbsoluteConstraints(490, 350, 150, -1));\n getContentPane().add(jSeparator2, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 142, 630, 10));\n\n lblDadosProdutos.setForeground(new java.awt.Color(0, 0, 255));\n lblDadosProdutos.setText(\"Dados Produto:\");\n getContentPane().add(lblDadosProdutos, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 124, -1, 10));\n getContentPane().add(jSeparator3, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 322, 630, 10));\n\n jLabel3.setForeground(new java.awt.Color(0, 0, 255));\n jLabel3.setText(\"Dados do Fornecedor:\");\n getContentPane().add(jLabel3, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 300, -1, -1));\n\n lblCidade.setText(\"Cidade:\");\n getContentPane().add(lblCidade, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 380, -1, -1));\n getContentPane().add(txtCidade, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 400, 150, -1));\n\n txtData1.setFormatterFactory(new javax.swing.text.DefaultFormatterFactory(new javax.swing.text.DateFormatter()));\n getContentPane().add(txtData1, new org.netbeans.lib.awtextra.AbsoluteConstraints(490, 270, 150, -1));\n\n btnNovo.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/controleprodutos/ícones/icons8-password-reset-24.png\"))); // NOI18N\n btnNovo.setText(\"Novo\");\n btnNovo.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btnNovoActionPerformed(evt);\n }\n });\n getContentPane().add(btnNovo, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 440, 100, -1));\n\n btnIncluir.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/controleprodutos/ícones/icons8-save-close-24.png\"))); // NOI18N\n btnIncluir.setText(\"Incluir\");\n btnIncluir.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btnIncluirActionPerformed(evt);\n }\n });\n getContentPane().add(btnIncluir, new org.netbeans.lib.awtextra.AbsoluteConstraints(110, 440, 100, -1));\n\n btnAlterar.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/controleprodutos/ícones/icons8-change-24.png\"))); // NOI18N\n btnAlterar.setText(\"Alterar\");\n btnAlterar.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btnAlterarActionPerformed(evt);\n }\n });\n getContentPane().add(btnAlterar, new org.netbeans.lib.awtextra.AbsoluteConstraints(210, 440, 100, -1));\n\n btnExcluir.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/controleprodutos/ícones/icons8-trash-can-24.png\"))); // NOI18N\n btnExcluir.setText(\"Excluir\");\n btnExcluir.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btnExcluirActionPerformed(evt);\n }\n });\n getContentPane().add(btnExcluir, new org.netbeans.lib.awtextra.AbsoluteConstraints(310, 440, 100, -1));\n\n btnImprimir.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/controleprodutos/ícones/icons8-printer-maintenance-24.png\"))); // NOI18N\n btnImprimir.setText(\"Imprimir\");\n btnImprimir.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btnImprimirActionPerformed(evt);\n }\n });\n getContentPane().add(btnImprimir, new org.netbeans.lib.awtextra.AbsoluteConstraints(410, 440, 110, -1));\n\n btnSair.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/controleprodutos/ícones/icons8-close-window-24.png\"))); // NOI18N\n btnSair.setText(\"Sair\");\n btnSair.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btnSairActionPerformed(evt);\n }\n });\n getContentPane().add(btnSair, new org.netbeans.lib.awtextra.AbsoluteConstraints(560, 440, -1, -1));\n\n lblEstadoProduto.setText(\"Estado do produto:\");\n getContentPane().add(lblEstadoProduto, new org.netbeans.lib.awtextra.AbsoluteConstraints(450, 200, -1, -1));\n\n cbEstadoProduto.setModel(new javax.swing.DefaultComboBoxModel<>(new String[] { \"Novo\", \"Usado\", \"Conservado\", \"Antigo\" }));\n getContentPane().add(cbEstadoProduto, new org.netbeans.lib.awtextra.AbsoluteConstraints(450, 220, 190, -1));\n\n setSize(new java.awt.Dimension(670, 520));\n setLocationRelativeTo(null);\n }", "private void cargar(List<Personas> listaP) {\n int total= listaP.size();\n Object [][] tab = new Object [total][10];\n int i=0;\n Iterator iter = listaP.iterator();\n while (iter.hasNext()){\n Object objeto = iter.next();\n Personas pro = (Personas) objeto;\n\n tab[i][0]=pro.getLocalidadesid().getProvinciasId();\n tab[i][1]=pro.getLocalidadesid();\n tab[i][2]=pro.getCuilcuit();\n tab[i][3]=pro.getApellido();\n tab[i][4]=pro.getNombres();\n tab[i][5]=pro.getCalle();\n tab[i][6]=pro.getAltura();\n tab[i][7]=pro.getPiso();\n tab[i][8]=pro.getEmail();\n// if(pro.getEmpleados().equals(\"\")){\n tab[i][9]=\"Cliente\";\n // }else{\n // tab[i][7]=\"Empleado\";\n // }\n i++;\n }\njTable1 = new javax.swing.JTable();\n\njTable1.setModel(new javax.swing.table.DefaultTableModel(\ntab,\nnew String [] {\n \"Provincia\", \"Localidad\", \"DNI/Cuit\", \"Apellido\", \"Nombres\", \"Calle\", \"Altura\", \"Piso\", \"Email\", \"Tipo\"\n}\n));\n jScrollPane1.setViewportView(jTable1);\n }", "public void tabla_campos() {\n int rec = AgendarA.tblAgricultor.getSelectedRow();// devuelve un entero con la posicion de la seleccion en la tabla\n ccAgricultor = AgendarA.tblAgricultor.getValueAt(rec, 1).toString();\n crearModeloAgenda();\n }", "public void LlenarTabla(){\n String Query = \"SELECT usuario,fecha_ingreso,hora_ingreso,hora_salida from bitacora\";\n \n DefaultTableModel modelo = new DefaultTableModel();\n jTable1.setModel(modelo);\n Connection cnx = null;\n if (cnx == null) {\n try {\n Class.forName(\"com.mysql.jdbc.Driver\");\n cnx = DriverManager.getConnection(url, user,pass);\n \n Statement st = cnx.prepareStatement(Query);\n ResultSet res = st.executeQuery(Query);\n ResultSetMetaData rsMd = res.getMetaData();\n int cantidadColumnas = rsMd.getColumnCount();\n for (int i = 1; i <= cantidadColumnas; i++) {\n modelo.addColumn(rsMd.getColumnLabel(i));\n }\n while (res.next()){\n Object[] fila = new Object[cantidadColumnas];\n for (int i = 0; i < cantidadColumnas; i++) {\n fila[i]=res.getObject(i+1);\n }\n modelo.addRow(fila);\n \n }\n } catch (ClassNotFoundException ex) {\n throw new ClassCastException(ex.getMessage());\n } catch (SQLException ex) { \n Logger.getLogger(LoginGT.class.getName()).log(Level.SEVERE, null, ex);\n } \n } \n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n jScrollPane4 = new javax.swing.JScrollPane();\n jTable1 = new javax.swing.JTable();\n jTabbedPane1 = new javax.swing.JTabbedPane();\n jPanel2 = new javax.swing.JPanel();\n jPanel6 = new javax.swing.JPanel();\n jScrollPane2 = new javax.swing.JScrollPane();\n tabelaReservas = new javax.swing.JTable();\n btnExcluirReserva = new javax.swing.JButton();\n lbMsg1 = new javax.swing.JLabel();\n jLabel25 = new javax.swing.JLabel();\n jPanel3 = new javax.swing.JPanel();\n jPanel7 = new javax.swing.JPanel();\n jScrollPane3 = new javax.swing.JScrollPane();\n tabelaBuscarReservaHospedes = new javax.swing.JTable();\n btnBuscarHospede = new javax.swing.JButton();\n tfNomeBuscarHospede = new javax.swing.JTextField();\n dataEntradaNoHotel = new com.toedter.calendar.JDateChooser();\n dataPrevistaSaidaDoHotel = new com.toedter.calendar.JDateChooser();\n btnRegistrarEntrada = new javax.swing.JButton();\n jLabel9 = new javax.swing.JLabel();\n jLabel8 = new javax.swing.JLabel();\n jLabel10 = new javax.swing.JLabel();\n jScrollPane5 = new javax.swing.JScrollPane();\n tabelaAcompanhantes = new javax.swing.JTable();\n btnVisualizarAcompanhantes = new javax.swing.JButton();\n jLabel11 = new javax.swing.JLabel();\n jLabel26 = new javax.swing.JLabel();\n jPanel5 = new javax.swing.JPanel();\n jPanel9 = new javax.swing.JPanel();\n jScrollPane6 = new javax.swing.JScrollPane();\n tabelaAdicionarItemConsumo = new javax.swing.JTable();\n jLabel12 = new javax.swing.JLabel();\n jLabel13 = new javax.swing.JLabel();\n jScrollPane7 = new javax.swing.JScrollPane();\n tabelaSelecionarAcomodacaoConsumo = new javax.swing.JTable();\n jLabel14 = new javax.swing.JLabel();\n tfQuantidadeConsumida = new javax.swing.JTextField();\n jLabel15 = new javax.swing.JLabel();\n dataConsumo = new com.toedter.calendar.JDateChooser();\n btnAdicionarItemConsumo = new javax.swing.JButton();\n jLabel27 = new javax.swing.JLabel();\n jPanel4 = new javax.swing.JPanel();\n jPanel8 = new javax.swing.JPanel();\n jScrollPane8 = new javax.swing.JScrollPane();\n tabelaReservasSaida = new javax.swing.JTable();\n btnSelecionarReservaSaida = new javax.swing.JButton();\n lbMsg4 = new javax.swing.JLabel();\n jLabel28 = new javax.swing.JLabel();\n jPanel1 = new javax.swing.JPanel();\n jPanel10 = new javax.swing.JPanel();\n jScrollPane1 = new javax.swing.JScrollPane();\n tabelaHospedes = new javax.swing.JTable();\n btnAdicionarReserva = new javax.swing.JButton();\n jLabel1 = new javax.swing.JLabel();\n jLabel29 = new javax.swing.JLabel();\n\n jTable1.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n {null, null, null, null},\n {null, null, null, null},\n {null, null, null, null},\n {null, null, null, null}\n },\n new String [] {\n \"Title 1\", \"Title 2\", \"Title 3\", \"Title 4\"\n }\n ));\n jScrollPane4.setViewportView(jTable1);\n\n jTabbedPane1.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 18)); // NOI18N\n\n tabelaReservas.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 18)); // NOI18N\n tabelaReservas.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n {null, null, null, null},\n {null, null, null, null},\n {null, null, null, null},\n {null, null, null, null}\n },\n new String [] {\n \"Title 1\", \"Title 2\", \"Title 3\", \"Title 4\"\n }\n ));\n jScrollPane2.setViewportView(tabelaReservas);\n\n btnExcluirReserva.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 20)); // NOI18N\n btnExcluirReserva.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/br/com/hotel/imagem/delete.png\"))); // NOI18N\n btnExcluirReserva.setText(\"Excluir Reserva\");\n btnExcluirReserva.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btnExcluirReservaActionPerformed(evt);\n }\n });\n\n javax.swing.GroupLayout jPanel6Layout = new javax.swing.GroupLayout(jPanel6);\n jPanel6.setLayout(jPanel6Layout);\n jPanel6Layout.setHorizontalGroup(\n jPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel6Layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(jPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel6Layout.createSequentialGroup()\n .addComponent(lbMsg1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addGap(36, 36, 36)\n .addComponent(btnExcluirReserva))\n .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 1076, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n );\n jPanel6Layout.setVerticalGroup(\n jPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel6Layout.createSequentialGroup()\n .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 421, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(18, 18, 18)\n .addGroup(jPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)\n .addComponent(lbMsg1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(btnExcluirReserva, javax.swing.GroupLayout.PREFERRED_SIZE, 36, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n );\n\n jLabel25.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/br/com/hotel/imagem/city.png\"))); // NOI18N\n\n javax.swing.GroupLayout jPanel2Layout = new javax.swing.GroupLayout(jPanel2);\n jPanel2.setLayout(jPanel2Layout);\n jPanel2Layout.setHorizontalGroup(\n jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel2Layout.createSequentialGroup()\n .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel2Layout.createSequentialGroup()\n .addContainerGap()\n .addComponent(jLabel25, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n .addComponent(jPanel6, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n .addContainerGap())\n );\n jPanel2Layout.setVerticalGroup(\n jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel2Layout.createSequentialGroup()\n .addContainerGap()\n .addComponent(jPanel6, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 18, Short.MAX_VALUE)\n .addComponent(jLabel25)\n .addContainerGap())\n );\n\n jTabbedPane1.addTab(\"Visualizar Reservas\", jPanel2);\n\n tabelaBuscarReservaHospedes.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 18)); // NOI18N\n tabelaBuscarReservaHospedes.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n {null, null, null, null},\n {null, null, null, null},\n {null, null, null, null},\n {null, null, null, null}\n },\n new String [] {\n \"Title 1\", \"Title 2\", \"Title 3\", \"Title 4\"\n }\n ));\n jScrollPane3.setViewportView(tabelaBuscarReservaHospedes);\n\n btnBuscarHospede.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 20)); // NOI18N\n btnBuscarHospede.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/br/com/hotel/imagem/search.png\"))); // NOI18N\n btnBuscarHospede.setText(\"Buscar\");\n btnBuscarHospede.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btnBuscarHospedeActionPerformed(evt);\n }\n });\n\n tfNomeBuscarHospede.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 18)); // NOI18N\n\n btnRegistrarEntrada.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 18)); // NOI18N\n btnRegistrarEntrada.setText(\"Registrar Entrada\");\n btnRegistrarEntrada.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btnRegistrarEntradaActionPerformed(evt);\n }\n });\n\n jLabel9.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 18)); // NOI18N\n jLabel9.setText(\"Data Prevista Saída\");\n\n jLabel8.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 18)); // NOI18N\n jLabel8.setText(\"Data Entrada\");\n\n jLabel10.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 18)); // NOI18N\n jLabel10.setText(\"Buscar Hospede\");\n\n tabelaAcompanhantes.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 18)); // NOI18N\n tabelaAcompanhantes.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n {null, null, null, null},\n {null, null, null, null},\n {null, null, null, null},\n {null, null, null, null}\n },\n new String [] {\n \"Title 1\", \"Title 2\", \"Title 3\", \"Title 4\"\n }\n ));\n jScrollPane5.setViewportView(tabelaAcompanhantes);\n\n btnVisualizarAcompanhantes.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 18)); // NOI18N\n btnVisualizarAcompanhantes.setText(\"Visualizar Acompanhantes\");\n\n jLabel11.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 18)); // NOI18N\n jLabel11.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);\n jLabel11.setText(\"Acompanhantes\");\n\n javax.swing.GroupLayout jPanel7Layout = new javax.swing.GroupLayout(jPanel7);\n jPanel7.setLayout(jPanel7Layout);\n jPanel7Layout.setHorizontalGroup(\n jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel7Layout.createSequentialGroup()\n .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)\n .addComponent(jScrollPane3, javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(javax.swing.GroupLayout.Alignment.LEADING, jPanel7Layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)\n .addGroup(jPanel7Layout.createSequentialGroup()\n .addComponent(jLabel10)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(tfNomeBuscarHospede, javax.swing.GroupLayout.PREFERRED_SIZE, 444, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(btnBuscarHospede))\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel7Layout.createSequentialGroup()\n .addComponent(jLabel8)\n .addGap(18, 18, 18)\n .addComponent(dataEntradaNoHotel, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(50, 50, 50)\n .addComponent(jLabel9)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(dataPrevistaSaidaDoHotel, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 65, Short.MAX_VALUE)\n .addComponent(btnRegistrarEntrada)))))\n .addGap(18, 18, 18)\n .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jLabel11, javax.swing.GroupLayout.PREFERRED_SIZE, 289, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGroup(jPanel7Layout.createSequentialGroup()\n .addGap(45, 45, 45)\n .addComponent(btnVisualizarAcompanhantes))\n .addComponent(jScrollPane5, javax.swing.GroupLayout.PREFERRED_SIZE, 273, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n );\n jPanel7Layout.setVerticalGroup(\n jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel7Layout.createSequentialGroup()\n .addGap(11, 11, 11)\n .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel10)\n .addComponent(tfNomeBuscarHospede, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(btnBuscarHospede)\n .addComponent(jLabel11))\n .addGap(18, 18, 18)\n .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)\n .addComponent(jScrollPane3, javax.swing.GroupLayout.DEFAULT_SIZE, 350, Short.MAX_VALUE)\n .addComponent(jScrollPane5, javax.swing.GroupLayout.PREFERRED_SIZE, 0, Short.MAX_VALUE))\n .addGap(18, 18, 18)\n .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)\n .addComponent(dataEntradaNoHotel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(jLabel9, javax.swing.GroupLayout.Alignment.TRAILING)\n .addComponent(dataPrevistaSaidaDoHotel, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(btnRegistrarEntrada)\n .addComponent(btnVisualizarAcompanhantes))\n .addComponent(jLabel8, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.PREFERRED_SIZE, 27, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addContainerGap())\n );\n\n jLabel26.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/br/com/hotel/imagem/city.png\"))); // NOI18N\n\n javax.swing.GroupLayout jPanel3Layout = new javax.swing.GroupLayout(jPanel3);\n jPanel3.setLayout(jPanel3Layout);\n jPanel3Layout.setHorizontalGroup(\n jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel3Layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)\n .addComponent(jPanel7, javax.swing.GroupLayout.PREFERRED_SIZE, 0, Short.MAX_VALUE)\n .addComponent(jLabel26, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n );\n jPanel3Layout.setVerticalGroup(\n jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel3Layout.createSequentialGroup()\n .addContainerGap()\n .addComponent(jPanel7, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addGap(18, 18, 18)\n .addComponent(jLabel26)\n .addContainerGap())\n );\n\n jTabbedPane1.addTab(\"Gerenciar entradas no Hotel\", jPanel3);\n\n tabelaAdicionarItemConsumo.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 18)); // NOI18N\n tabelaAdicionarItemConsumo.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n {null, null, null, null},\n {null, null, null, null},\n {null, null, null, null},\n {null, null, null, null}\n },\n new String [] {\n \"Title 1\", \"Title 2\", \"Title 3\", \"Title 4\"\n }\n ));\n jScrollPane6.setViewportView(tabelaAdicionarItemConsumo);\n\n jLabel12.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 18)); // NOI18N\n jLabel12.setText(\"Itens de Consumo\");\n\n jLabel13.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 18)); // NOI18N\n jLabel13.setText(\"Selecione um Quarto\");\n\n tabelaSelecionarAcomodacaoConsumo.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 18)); // NOI18N\n tabelaSelecionarAcomodacaoConsumo.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n {null, null, null, null},\n {null, null, null, null},\n {null, null, null, null},\n {null, null, null, null}\n },\n new String [] {\n \"Title 1\", \"Title 2\", \"Title 3\", \"Title 4\"\n }\n ));\n jScrollPane7.setViewportView(tabelaSelecionarAcomodacaoConsumo);\n\n jLabel14.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 18)); // NOI18N\n jLabel14.setText(\"Quantidade Consumida desse Item\");\n\n tfQuantidadeConsumida.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 18)); // NOI18N\n\n jLabel15.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 18)); // NOI18N\n jLabel15.setText(\"Data do Consumo:\");\n\n dataConsumo.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 18)); // NOI18N\n\n btnAdicionarItemConsumo.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 20)); // NOI18N\n btnAdicionarItemConsumo.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/br/com/hotel/imagem/add.png\"))); // NOI18N\n btnAdicionarItemConsumo.setText(\"Adicionar Consumo ao Quarto\");\n btnAdicionarItemConsumo.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btnAdicionarItemConsumoActionPerformed(evt);\n }\n });\n\n javax.swing.GroupLayout jPanel9Layout = new javax.swing.GroupLayout(jPanel9);\n jPanel9.setLayout(jPanel9Layout);\n jPanel9Layout.setHorizontalGroup(\n jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel9Layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)\n .addGroup(jPanel9Layout.createSequentialGroup()\n .addGroup(jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jLabel12)\n .addGroup(jPanel9Layout.createSequentialGroup()\n .addComponent(jLabel14)\n .addGap(18, 18, 18)\n .addComponent(tfQuantidadeConsumida, javax.swing.GroupLayout.PREFERRED_SIZE, 95, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(18, 18, 18)\n .addComponent(jLabel15)\n .addGap(18, 18, 18)\n .addComponent(dataConsumo, javax.swing.GroupLayout.PREFERRED_SIZE, 180, javax.swing.GroupLayout.PREFERRED_SIZE)))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(btnAdicionarItemConsumo, javax.swing.GroupLayout.PREFERRED_SIZE, 320, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGroup(jPanel9Layout.createSequentialGroup()\n .addComponent(jScrollPane6)\n .addGap(18, 18, 18)\n .addGroup(jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jLabel13)\n .addComponent(jScrollPane7, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))))\n .addContainerGap())\n );\n jPanel9Layout.setVerticalGroup(\n jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel9Layout.createSequentialGroup()\n .addGroup(jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel12)\n .addComponent(jLabel13))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addGroup(jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jScrollPane6, javax.swing.GroupLayout.DEFAULT_SIZE, 385, Short.MAX_VALUE)\n .addComponent(jScrollPane7, javax.swing.GroupLayout.PREFERRED_SIZE, 0, Short.MAX_VALUE))\n .addGap(18, 18, 18)\n .addGroup(jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(btnAdicionarItemConsumo, javax.swing.GroupLayout.Alignment.TRAILING)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(dataConsumo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGroup(jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel14)\n .addComponent(tfQuantidadeConsumida, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jLabel15))))\n .addContainerGap())\n );\n\n jLabel27.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/br/com/hotel/imagem/city.png\"))); // NOI18N\n\n javax.swing.GroupLayout jPanel5Layout = new javax.swing.GroupLayout(jPanel5);\n jPanel5.setLayout(jPanel5Layout);\n jPanel5Layout.setHorizontalGroup(\n jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel5Layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jPanel9, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(jLabel27, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n .addContainerGap())\n );\n jPanel5Layout.setVerticalGroup(\n jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel5Layout.createSequentialGroup()\n .addContainerGap()\n .addComponent(jPanel9, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addGap(18, 18, 18)\n .addComponent(jLabel27)\n .addContainerGap())\n );\n\n jTabbedPane1.addTab(\"Adicionar Consumo no Quarto\", jPanel5);\n\n tabelaReservasSaida.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 18)); // NOI18N\n tabelaReservasSaida.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n {null, null, null, null},\n {null, null, null, null},\n {null, null, null, null},\n {null, null, null, null}\n },\n new String [] {\n \"Title 1\", \"Title 2\", \"Title 3\", \"Title 4\"\n }\n ));\n jScrollPane8.setViewportView(tabelaReservasSaida);\n\n btnSelecionarReservaSaida.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 20)); // NOI18N\n btnSelecionarReservaSaida.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/br/com/hotel/imagem/add.png\"))); // NOI18N\n btnSelecionarReservaSaida.setText(\"Adicionar Saída\");\n btnSelecionarReservaSaida.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btnSelecionarReservaSaidaActionPerformed(evt);\n }\n });\n\n javax.swing.GroupLayout jPanel8Layout = new javax.swing.GroupLayout(jPanel8);\n jPanel8.setLayout(jPanel8Layout);\n jPanel8Layout.setHorizontalGroup(\n jPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel8Layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(jPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel8Layout.createSequentialGroup()\n .addComponent(lbMsg4, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addGap(18, 18, 18)\n .addComponent(btnSelecionarReservaSaida, javax.swing.GroupLayout.PREFERRED_SIZE, 262, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addComponent(jScrollPane8))\n .addContainerGap())\n );\n jPanel8Layout.setVerticalGroup(\n jPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel8Layout.createSequentialGroup()\n .addContainerGap()\n .addComponent(jScrollPane8, javax.swing.GroupLayout.DEFAULT_SIZE, 401, Short.MAX_VALUE)\n .addGap(18, 18, 18)\n .addGroup(jPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)\n .addComponent(btnSelecionarReservaSaida, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(lbMsg4, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n .addContainerGap())\n );\n\n jLabel28.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/br/com/hotel/imagem/city.png\"))); // NOI18N\n\n javax.swing.GroupLayout jPanel4Layout = new javax.swing.GroupLayout(jPanel4);\n jPanel4.setLayout(jPanel4Layout);\n jPanel4Layout.setHorizontalGroup(\n jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel4Layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)\n .addComponent(jPanel8, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(jLabel28, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n );\n jPanel4Layout.setVerticalGroup(\n jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel4Layout.createSequentialGroup()\n .addContainerGap()\n .addComponent(jPanel8, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addGap(18, 18, 18)\n .addComponent(jLabel28)\n .addContainerGap())\n );\n\n jTabbedPane1.addTab(\"Gerenciar Saídas no Hotel\", jPanel4);\n\n tabelaHospedes.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 18)); // NOI18N\n tabelaHospedes.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n {null, null, null, null},\n {null, null, null, null},\n {null, null, null, null},\n {null, null, null, null}\n },\n new String [] {\n \"Title 1\", \"Title 2\", \"Title 3\", \"Title 4\"\n }\n ));\n jScrollPane1.setViewportView(tabelaHospedes);\n\n btnAdicionarReserva.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 20)); // NOI18N\n btnAdicionarReserva.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/br/com/hotel/imagem/add.png\"))); // NOI18N\n btnAdicionarReserva.setText(\"Adicionar Reserva\");\n btnAdicionarReserva.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btnAdicionarReservaActionPerformed(evt);\n }\n });\n\n jLabel1.setFont(new java.awt.Font(\"Hotel Oriental\", 0, 18)); // NOI18N\n jLabel1.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);\n\n javax.swing.GroupLayout jPanel10Layout = new javax.swing.GroupLayout(jPanel10);\n jPanel10.setLayout(jPanel10Layout);\n jPanel10Layout.setHorizontalGroup(\n jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel10Layout.createSequentialGroup()\n .addGroup(jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jScrollPane1)\n .addGroup(jPanel10Layout.createSequentialGroup()\n .addComponent(jLabel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(btnAdicionarReserva)))\n .addContainerGap())\n );\n jPanel10Layout.setVerticalGroup(\n jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel10Layout.createSequentialGroup()\n .addContainerGap()\n .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 401, Short.MAX_VALUE)\n .addGap(18, 18, 18)\n .addGroup(jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)\n .addComponent(btnAdicionarReserva, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(jLabel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n .addContainerGap())\n );\n\n jLabel29.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/br/com/hotel/imagem/city.png\"))); // NOI18N\n\n javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);\n jPanel1.setLayout(jPanel1Layout);\n jPanel1Layout.setHorizontalGroup(\n jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)\n .addComponent(jPanel10, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(jLabel29, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n );\n jPanel1Layout.setVerticalGroup(\n jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addContainerGap()\n .addComponent(jPanel10, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addGap(18, 18, 18)\n .addComponent(jLabel29)\n .addContainerGap())\n );\n\n jTabbedPane1.addTab(\"Cadastrar Reserva\", jPanel1);\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);\n this.setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(jTabbedPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 1107, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addContainerGap())\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()\n .addGap(0, 0, Short.MAX_VALUE)\n .addComponent(jTabbedPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 746, javax.swing.GroupLayout.PREFERRED_SIZE))\n );\n }", "private void preencherTabela() {\n\t\tList<Cidade> listCidade;\n\t\tCidadeDAO cidadeDAO;\n\t\tObservableList<Cidade> oListCidade;\n\n\t\t// Determina os atributos que irão preencher as colunas\n\t\tcolCidade.setCellValueFactory(new PropertyValueFactory<>(\"nomeCidades\"));\n\t\tcolEstado.setCellValueFactory(new PropertyValueFactory<>(\"nomeEstado\"));\n\t\tcolSigla.setCellValueFactory(new PropertyValueFactory<>(\"siglaEstado\"));\n\t\tcolCodigoCidade.setCellValueFactory(new PropertyValueFactory<>(\"idCidade\"));\n\t\tcolIdEstado.setCellValueFactory(new PropertyValueFactory<>(\"idEstado\"));\n\n\t\t// Instancia a lista de cidades e a DAO\n\t\tlistCidade = new ArrayList<Cidade>();\n\t\tcidadeDAO = new CidadeDAO();\n\n\t\t// Chama o metodo para selecionar todas as cidades e atribuir a lista\n\t\tlistCidade = cidadeDAO.selecionar();\n\n\t\t// Converte a lista de cidades em observablearray\n\t\toListCidade = FXCollections.observableArrayList(listCidade);\n\n\t\t// Adiciona a lista na tabela\n\t\ttblCidades.setItems(oListCidade);\n\t}", "private void enlazarListadoTabla() {\n tblCursos.setItems(listaCursos);\n\n //Enlazar columnas con atributos\n clmNombre.setCellValueFactory(new PropertyValueFactory<Curso, String>(\"nombre\"));\n clmAmbito.setCellValueFactory(new PropertyValueFactory<Curso, String>(\"familiaProfesional\"));\n clmDuracion.setCellValueFactory(new PropertyValueFactory<Curso, Integer>(\"duracion\"));\n }", "private void popularTabela() {\n\n if (CadastroCliente.listaAluno.isEmpty()) {\n DefaultTableModel modelo = (DefaultTableModel) jTable1.getModel();\n modelo.setNumRows(0);\n }\n int t = 0;\n DefaultTableModel modelo = (DefaultTableModel) jTable1.getModel();\n modelo.setNumRows(0);\n int aux = CadastroCliente.listaAluno.size();\n\n while (t < aux) {\n aluno = CadastroCliente.listaAluno.get(t);\n modelo.addRow(new Object[]{aluno.getMatricula(), aluno.getNome(), aluno.getCpf(), aluno.getTel()});\n t++;\n }\n }", "@SuppressWarnings(\"unchecked\")\n \n \n private void table(){\n \n int c;\n \n try{\n \n Connection con1 = ConnectionProvider.getConn();\n Statement stm = con1.createStatement();\n ResultSet rst = stm.executeQuery(\"select * from sales\");\n ResultSetMetaData rstm = rst.getMetaData();\n \n c = rstm.getColumnCount();\n \n DefaultTableModel dtm2 = (DefaultTableModel)jTable1.getModel();\n dtm2.setRowCount(0);\n \n while (rst.next()){\n \n Vector vec = new Vector();\n \n for(int a =1 ; a<=c; a++)\n {\n vec.add(rst.getString(\"CustomerName\"));\n vec.add(rst.getString(\"OrderNo\"));\n vec.add(rst.getString(\"TypeOfService\"));\n vec.add(rst.getString(\"OrderType\"));\n vec.add(rst.getString(\"Descript\"));\n vec.add(rst.getString(\"OrderConfirmation\"));\n vec.add(rst.getString(\"OrderHandledBy\"));\n vec.add(rst.getString(\"OrderDate\"));\n vec.add(rst.getString(\"WarrantyExpireDate\"));\n vec.add(rst.getString(\"FullAmount\"));\n vec.add(rst.getString(\"AmountPaid\"));\n vec.add(rst.getString(\"Balance\"));\n }\n \n dtm2.addRow(vec);\n }\n \n }\n catch(Exception e)\n {\n \n }\n \n \n }", "private void pintarTabla() {\r\n ArrayList<Corredor> listCorredors = gestion.getCorredores();\r\n TableModelCorredores modelo = new TableModelCorredores(listCorredors);\r\n jTableCorredores.setModel(modelo);\r\n TableRowSorter<TableModel> elQueOrdena = new TableRowSorter<>(modelo);\r\n jTableCorredores.setRowSorter(elQueOrdena);\r\n\r\n }", "public void llenadoDeTablas() {\n \n DefaultTableModel modelo1 = new DefaultTableModel();\n modelo1 = new DefaultTableModel();\n modelo1.addColumn(\"ID Usuario\");\n modelo1.addColumn(\"NOMBRE\");\n UsuarioDAO asignaciondao = new UsuarioDAO();\n List<Usuario> asignaciones = asignaciondao.select();\n TablaPerfiles.setModel(modelo1);\n String[] dato = new String[2];\n for (int i = 0; i < asignaciones.size(); i++) {\n dato[0] = (Integer.toString(asignaciones.get(i).getId_usuario()));\n dato[1] = asignaciones.get(i).getNombre_usuario();\n\n modelo1.addRow(dato);\n }\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n jScrollPane1 = new javax.swing.JScrollPane();\n jTOrdenes = new javax.swing.JTable();\n jPanel1 = new javax.swing.JPanel();\n jLabel5 = new javax.swing.JLabel();\n txtOrden = new javax.swing.JTextField();\n txtPago = new javax.swing.JTextField();\n jXDatePicker1 = new org.jdesktop.swingx.JXDatePicker();\n jLabel1 = new javax.swing.JLabel();\n jLabel2 = new javax.swing.JLabel();\n jLabel3 = new javax.swing.JLabel();\n cbxTienda = new javax.swing.JComboBox();\n lblTienda = new javax.swing.JLabel();\n jPanel3 = new javax.swing.JPanel();\n jLabel4 = new javax.swing.JLabel();\n txtQty = new javax.swing.JTextField();\n jLabel6 = new javax.swing.JLabel();\n cbxLibro = new javax.swing.JComboBox();\n lblTit = new javax.swing.JLabel();\n jPanel2 = new javax.swing.JPanel();\n btnAgregarTitulo = new javax.swing.JButton();\n btnEditarTitulo = new javax.swing.JButton();\n btnEliminar = new javax.swing.JButton();\n jMenuBar1 = new javax.swing.JMenuBar();\n menuNueva = new javax.swing.JMenu();\n miNuevaOrden = new javax.swing.JMenuItem();\n jMenu2 = new javax.swing.JMenu();\n verOrden = new javax.swing.JMenuItem();\n verOrdenPorTienda = new javax.swing.JMenuItem();\n jMenuItem1 = new javax.swing.JMenuItem();\n jMenu1 = new javax.swing.JMenu();\n menuEditoriales = new javax.swing.JMenuItem();\n menuPuestos = new javax.swing.JMenuItem();\n menuEmpleados = new javax.swing.JMenuItem();\n menuAutores = new javax.swing.JMenuItem();\n menuTitulos = new javax.swing.JMenuItem();\n menuTitsAuts = new javax.swing.JMenuItem();\n menuTiendas = new javax.swing.JMenuItem();\n menuDescuentos = new javax.swing.JMenuItem();\n\n setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);\n setTitle(\"( ͡° ͜ʖ ͡°) - Sistema de ventas de libros\");\n setResizable(false);\n\n jTOrdenes.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n {null, null, null, null},\n {null, null, null, null},\n {null, null, null, null},\n {null, null, null, null}\n },\n new String [] {\n \"Title 1\", \"Title 2\", \"Title 3\", \"Title 4\"\n }\n ));\n jTOrdenes.addMouseListener(new java.awt.event.MouseAdapter() {\n public void mouseClicked(java.awt.event.MouseEvent evt) {\n jTOrdenesMouseClicked(evt);\n }\n });\n jTOrdenes.addKeyListener(new java.awt.event.KeyAdapter() {\n public void keyReleased(java.awt.event.KeyEvent evt) {\n jTOrdenesKeyReleased(evt);\n }\n });\n jScrollPane1.setViewportView(jTOrdenes);\n\n jLabel5.setText(\"Terminos de Pago\");\n\n txtOrden.setMinimumSize(new java.awt.Dimension(6, 23));\n txtOrden.setPreferredSize(new java.awt.Dimension(150, 23));\n\n txtPago.setMinimumSize(new java.awt.Dimension(6, 23));\n txtPago.setPreferredSize(new java.awt.Dimension(150, 23));\n\n jLabel1.setText(\"Id Tienda\");\n\n jLabel2.setText(\"Numero de Orden\");\n\n jLabel3.setText(\"Fecha de Orden\");\n\n cbxTienda.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n cbxTiendaActionPerformed(evt);\n }\n });\n\n lblTienda.setText(\" \");\n\n javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);\n jPanel1.setLayout(jPanel1Layout);\n jPanel1Layout.setHorizontalGroup(\n jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)\n .addComponent(jLabel1)\n .addComponent(jLabel2)\n .addComponent(jLabel3)\n .addComponent(jLabel5))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(lblTienda, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)\n .addComponent(txtOrden, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(txtPago, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(jXDatePicker1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(cbxTienda, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n .addGap(0, 0, Short.MAX_VALUE)))\n .addContainerGap())\n );\n jPanel1Layout.setVerticalGroup(\n jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel1)\n .addComponent(cbxTienda, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(lblTienda, javax.swing.GroupLayout.PREFERRED_SIZE, 19, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel2)\n .addComponent(txtOrden, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel3)\n .addComponent(jXDatePicker1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel5)\n .addComponent(txtPago, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addContainerGap())\n );\n\n String formats = \"yyyy-MM-dd\";\n\n this.jXDatePicker1.setFormats(formats);\n\n jLabel4.setText(\"Cantidad\");\n\n txtQty.setMinimumSize(new java.awt.Dimension(6, 23));\n txtQty.setPreferredSize(new java.awt.Dimension(150, 23));\n\n jLabel6.setText(\"Titulo\");\n\n cbxLibro.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n cbxLibroActionPerformed(evt);\n }\n });\n\n lblTit.setText(\" \");\n\n javax.swing.GroupLayout jPanel3Layout = new javax.swing.GroupLayout(jPanel3);\n jPanel3.setLayout(jPanel3Layout);\n jPanel3Layout.setHorizontalGroup(\n jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel3Layout.createSequentialGroup()\n .addGap(18, 18, 18)\n .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(lblTit, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addGroup(jPanel3Layout.createSequentialGroup()\n .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)\n .addComponent(jLabel6)\n .addComponent(jLabel4))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)\n .addComponent(txtQty, javax.swing.GroupLayout.PREFERRED_SIZE, 1, Short.MAX_VALUE)\n .addComponent(cbxLibro, 0, 135, Short.MAX_VALUE))\n .addGap(0, 0, Short.MAX_VALUE)))\n .addContainerGap())\n );\n jPanel3Layout.setVerticalGroup(\n jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel3Layout.createSequentialGroup()\n .addGap(12, 12, 12)\n .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(cbxLibro, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jLabel6))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(lblTit, javax.swing.GroupLayout.PREFERRED_SIZE, 19, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 9, Short.MAX_VALUE)\n .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(txtQty, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jLabel4))\n .addContainerGap())\n );\n\n btnAgregarTitulo.setText(\"Agregar\");\n btnAgregarTitulo.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btnAgregarTituloActionPerformed(evt);\n }\n });\n\n btnEditarTitulo.setText(\"Editar\");\n btnEditarTitulo.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btnEditarTituloActionPerformed(evt);\n }\n });\n\n btnEliminar.setText(\"Eliminar\");\n btnEliminar.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btnEliminarActionPerformed(evt);\n }\n });\n\n javax.swing.GroupLayout jPanel2Layout = new javax.swing.GroupLayout(jPanel2);\n jPanel2.setLayout(jPanel2Layout);\n jPanel2Layout.setHorizontalGroup(\n jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel2Layout.createSequentialGroup()\n .addContainerGap()\n .addComponent(btnAgregarTitulo, javax.swing.GroupLayout.PREFERRED_SIZE, 83, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(btnEditarTitulo)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(btnEliminar, javax.swing.GroupLayout.PREFERRED_SIZE, 80, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addContainerGap())\n );\n jPanel2Layout.setVerticalGroup(\n jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel2Layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(btnAgregarTitulo)\n .addComponent(btnEditarTitulo)\n .addComponent(btnEliminar))\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n );\n\n menuNueva.setText(\"Nueva\");\n\n miNuevaOrden.setText(\"Venta\");\n miNuevaOrden.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n miNuevaOrdenActionPerformed(evt);\n }\n });\n menuNueva.add(miNuevaOrden);\n\n jMenuBar1.add(menuNueva);\n\n jMenu2.setText(\"Ver\");\n\n verOrden.setText(\"Orden...\");\n verOrden.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n verOrdenActionPerformed(evt);\n }\n });\n jMenu2.add(verOrden);\n\n verOrdenPorTienda.setText(\"Ordenes por tienda...\");\n verOrdenPorTienda.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n verOrdenPorTiendaActionPerformed(evt);\n }\n });\n jMenu2.add(verOrdenPorTienda);\n\n jMenuItem1.setText(\"Todas las ordenes\");\n jMenuItem1.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n jMenuItem1ActionPerformed(evt);\n }\n });\n jMenu2.add(jMenuItem1);\n\n jMenuBar1.add(jMenu2);\n\n jMenu1.setText(\"Administrar\");\n\n menuEditoriales.setText(\"Editoriales...\");\n menuEditoriales.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n menuEditorialesActionPerformed(evt);\n }\n });\n jMenu1.add(menuEditoriales);\n\n menuPuestos.setText(\"Puestos...\");\n menuPuestos.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n menuPuestosActionPerformed(evt);\n }\n });\n jMenu1.add(menuPuestos);\n\n menuEmpleados.setText(\"Empleados...\");\n menuEmpleados.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n menuEmpleadosActionPerformed(evt);\n }\n });\n jMenu1.add(menuEmpleados);\n\n menuAutores.setText(\"Autores...\");\n menuAutores.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n menuAutoresActionPerformed(evt);\n }\n });\n jMenu1.add(menuAutores);\n\n menuTitulos.setText(\"Titulos...\");\n menuTitulos.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n menuTitulosActionPerformed(evt);\n }\n });\n jMenu1.add(menuTitulos);\n\n menuTitsAuts.setText(\"Titulos-Autores...\");\n menuTitsAuts.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n menuTitsAutsActionPerformed(evt);\n }\n });\n jMenu1.add(menuTitsAuts);\n\n menuTiendas.setText(\"Tiendas...\");\n menuTiendas.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n menuTiendasActionPerformed(evt);\n }\n });\n jMenu1.add(menuTiendas);\n\n menuDescuentos.setText(\"Descuentos...\");\n menuDescuentos.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n menuDescuentosActionPerformed(evt);\n }\n });\n jMenu1.add(menuDescuentos);\n\n jMenuBar1.add(jMenu1);\n\n setJMenuBar(jMenuBar1);\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());\n getContentPane().setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)\n .addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jPanel3, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(jPanel2, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 646, Short.MAX_VALUE)\n .addContainerGap())\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)\n .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 0, Short.MAX_VALUE)\n .addGroup(layout.createSequentialGroup()\n .addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addComponent(jPanel3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(jPanel2, javax.swing.GroupLayout.PREFERRED_SIZE, 40, javax.swing.GroupLayout.PREFERRED_SIZE)))\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n );\n\n pack();\n setLocationRelativeTo(null);\n }", "public void iniciar(ArrayList<Estrategia> estrategias)\n {\n JPanel arriba= new JPanel();\n tabla =new DefaultTableModel()\n {\n public Class<?> getColumnClass(int colum)\n {\n if(colum<3||colum==4)\n {\n return String.class;\n }\n else\n if(colum==3||colum==6|| colum==7||colum==8)\n {\n return Timestamp.class;\n }else\n if(colum==5)\n {\n return Integer.class;\n \n }\n return Boolean.class;\n }\n @Override\n public boolean isCellEditable(int filas, int columnas)\n {\n return columnas==9;\n }\n };\n arriba.setBorder(BorderFactory.createEmptyBorder(4, 4, 4, 4));\n arriba.setLayout(new BorderLayout());\n JScrollPane desplazamientoTabla = new JScrollPane(\n ScrollPaneConstants.VERTICAL_SCROLLBAR_AS_NEEDED,\n ScrollPaneConstants.HORIZONTAL_SCROLLBAR_AS_NEEDED);\n table = new JTable(); \n table.addMouseListener(this);\n table.setModel(tabla);\n tabla.addColumn(\"Servidor\");\n tabla.addColumn(\"Estrategia\");\n tabla.addColumn(\"Sentencia utilizada\");\n tabla.addColumn(\"Primera ejecución\");\n tabla.addColumn(\"Rango de horas\");\n tabla.addColumn(\"Estado\");\n tabla.addColumn(\"Fecha inicio de ultima ejec.\");\n tabla.addColumn(\"Fecha final de ultima ejec.\");\n tabla.addColumn(\"Próxima ejecución\");\n tabla.addColumn(\"eliminar\");\n desplazamientoTabla.setViewportView(table);\n arriba.add(BorderLayout.CENTER,desplazamientoTabla);\n arriba.setBorder(BorderFactory.createStrokeBorder(new BasicStroke(4)));\n arriba.setBorder(BorderFactory.createTitledBorder(BorderFactory.createStrokeBorder(new BasicStroke(1)), \"ESTRATEGIAS\",TitledBorder.CENTER, TitledBorder.DEFAULT_POSITION, new Font(\"Calibri\", 1, 30), new Color(213,18,2)));\n \n dibujar(estrategias);\n\n // botones \n JPanel botones = new JPanel();\n JButton agregar= new JButton(\"agregar\");\n agregar.addActionListener(this);\n JButton eliminar= new JButton(\"modificar estado\");\n eliminar.addActionListener(this);\n eliminar.setActionCommand(\"modificar\");\n JButton atras= new JButton(\"Atras\");\n atras.addActionListener(this);\n atras.setActionCommand(\"atras\");\n botones.add(agregar,BorderLayout.CENTER);\n botones.add(eliminar,BorderLayout.CENTER);\n botones.add(atras,BorderLayout.CENTER);\n \n /// get contentPane\n add(arriba,BorderLayout.CENTER);\n add(botones,BorderLayout.SOUTH);\n this.setExtendedState(MAXIMIZED_BOTH);\n this.setMinimumSize(new Dimension(1200,700));\n setLocationRelativeTo(null);\n setVisible(true);\n setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n }", "private void establecerTablaPlatillos() {\n Object[] columnas = {\"Platillo\", \"Cantidad\", \"Costo\"};\n Object[][] modelo = new Object[platillosAVender.size()][3];\n int x = 0;\n\n for (VentaPlatillo ventaPlatillo : platillosAVender) {\n\n modelo[x][0] = ventaPlatillo.getPlatillo().getNombre();\n modelo[x][1] = ventaPlatillo.getCantidad();\n modelo[x][2] = ventaPlatillo.getCosto();\n x++;\n }\n // Se establece el modelo en la tabla con los datos\n tablaPlatillosAVender.setDefaultEditor(Object.class, null);\n tablaPlatillosAVender.setModel(new DefaultTableModel(modelo, columnas));\n tablaPlatillosAVender.setCellSelectionEnabled(false);\n tablaPlatillosAVender.setRowSelectionAllowed(false);\n txtTotal.setText(total + \"\");\n }", "private void tampilkan() {\n //To change body of generated methods, choose Tools | Templates.\n DefaultTableModel tabelpegawai = new DefaultTableModel();\n tabelpegawai.addColumn(\"NAMA\");\n tabelpegawai.addColumn(\"ALAMAT\");\n tabelpegawai.addColumn(\"HP\");\n tabelpegawai.addColumn(\"BBM\");\n tabelpegawai.addColumn(\"SITUS\");\n \n \n try {\n conek getCnn = new conek();\n con= null;\n con= (com.mysql.jdbc.Connection) getCnn.getConnection();\n String sql = \"select * from toko \";\n Statement stat = con.createStatement();\n ResultSet res=stat.executeQuery(sql);\n while (res.next()){\n tabelpegawai.addRow(new Object[]{res.getString(1),res.getString(2),res.getString(3),res.getString(4),res.getString(5)});\n }\n jTable1.setModel(tabelpegawai);\n } catch(Exception e){}\n }", "public void buscaxcodigo() {\r\n try {\r\n modelo.setCodigobarras(vista.jTbcodigobarras.getText());//C.P.M mandamos el codigo de barras ingresado\r\n rs = modelo.Buscarxcodigobarras();//C.P.M mandamos a consultar ese codigo de barras\r\n DefaultTableModel buscar = new DefaultTableModel() {//C.P.M instanciamos el modelo de la tabla\r\n @Override\r\n public boolean isCellEditable(int rowIndex, int vColIndex) {\r\n return false;\r\n }\r\n };\r\n vista.jTbuscar.setModel(buscar);//C.P.M le mandamos el modelo a la tabla\r\n modelo.estructuraProductos(buscar);//C.P.M obtenemos la estructura de la tabla \"Encabezados\"\r\n ResultSetMetaData rsMd = rs.getMetaData();//C.P.M obtenemos los metadatos de la consulta\r\n int cantidadColumnas = rsMd.getColumnCount();//C.P.M obtenemos las columnas de la consulta\r\n\r\n while (rs.next()) {//C.P.M recorremos el resultado\r\n Object[] fila = new Object[cantidadColumnas];//C.P.M creamos un vector con el tamano de las columnas de el resultado\r\n for (int i = 0; i < cantidadColumnas; i++) {//C.P.M recorremos el arreglo\r\n fila[i] = rs.getObject(i + 1);//C.P.M y vamos insertando el resultado\r\n }\r\n buscar.addRow(fila);//C.P.M le mandamos el arreglo como renglon nuevo\r\n }\r\n\r\n } catch (SQLException ex) {\r\n JOptionPane.showMessageDialog(null, \"Ocurrio un error al buscar por codigo de barras\");\r\n }\r\n }", "public Historial_equipo() {\n initComponents();\n\n user = Login.user;\n IDequipo = GestionarEquipos.IDequipo_update;\n\n setTitle(\"Historial del equipo registrado con el ID \" + IDequipo + \" - Sesión de \" + user);\n setSize(850, 630);\n setResizable(false);\n setLocationRelativeTo(null);\n\n setDefaultCloseOperation(WindowConstants.DISPOSE_ON_CLOSE);\n\n ImageIcon wallpaper = new ImageIcon(\"src/imagenes/wallpapertech.jpg\");\n Icon icono = new ImageIcon(wallpaper.getImage().getScaledInstance(jLabel_Wallpaper.getWidth(), jLabel_Wallpaper.getHeight(), Image.SCALE_DEFAULT));\n jLabel_Wallpaper.setIcon(icono);\n this.repaint();\n\n try {\n Connection cn = Conexion.conectar();\n PreparedStatement pst = cn.prepareStatement(\"select comentario_historial, dia, mes, annio, insumo, revision_tecnica_de from historial where id_equipo = '\" + IDequipo + \"'\");\n ResultSet rs = pst.executeQuery();\n\n jTable_historial = new JTable(model);\n jScrollPane_historial.setViewportView(jTable_historial);\n\n model.addColumn(\"Comentario\");\n model.addColumn(\"Dia\");\n model.addColumn(\"Mes\");\n model.addColumn(\"Año\");\n model.addColumn(\"Insumo Usado\");\n model.addColumn(\"Registro del Tecnico\");\n\n while (rs.next()) {\n Object[] fila = new Object[6];\n\n for (int i = 0; i < 6; i++) {\n fila[i] = rs.getObject(i + 1);\n }\n\n model.addRow(fila);\n\n }\n\n cn.close();\n } catch (SQLException e) {\n\n }\n\n }", "public void atualizarTabelaRespostas(){\n resposta = new Resposta(); \n\n try{\n if(txtIdPergunta.getText().isEmpty()){\n listaRespostas = respostaDao.ListaResposta(0);\n \n }else{\n listaRespostas = respostaDao.ListaResposta(Integer.parseInt(txtIdPergunta.getText()));\n \n }\n }catch (SQLException ex){\n Logger.getLogger(PerguntaView.class.getName()).log(Level.SEVERE, null, ex);\n } \nString dados [][] = new String[listaRespostas.size()][0];\nint i = 0;\nfor(Resposta resposta : listaRespostas){\n dados[i][0] = String.valueOf(resposta.getId());\n dados[i][1] = resposta.getDescricao();\n \n i++;\n}\nString tituloColuna[] ={\"ID Resposta\", \"Resposta\"};\nDefaultTableModel tabelaresposta = new DefaultTableModel();\ntabelaresposta.setDataVector(dados, tituloColuna);\n \n\n tabela_respostas.setModel(new DefaultTableModel(dados, tituloColuna){\n boolean[] canEdit = new boolean[]{\n false, false};\n \n public boolean isCellEditable(int rowIndex, int columnIndex){\n return canEdit[columnIndex];\n }\n \n\n });\ntabela_respostas.getColumnModel().getColumn(0).setPreferredWidth(100);\ntabela_respostas.getColumnModel().getColumn(1).setPreferredWidth(400);\n\nDefaultTableCellRenderer alinhamentoCentro = new DefaultTableCellRenderer();\nalinhamentoCentro.setHorizontalAlignment(SwingConstants.CENTER);\n\n\ntabela_respostas.getColumnModel().getColumn(0).setCellRenderer(alinhamentoCentro);\n\n\ntabela_respostas.setRowHeight(25);\ntabela_respostas.updateUI();\n }", "private void initFlightsTable() {\n try ( Connection con = DbCon.getConnection()) {\n PreparedStatement pst = con.prepareStatement(\"select * from Flights\");\n ResultSet rs = pst.executeQuery();\n ResultSetMetaData rsmd = rs.getMetaData();\n\n int columnCount = rsmd.getColumnCount();\n //create a model to of the flights table to be populated later\n flightsDftTblMdl = (DefaultTableModel) flightsTable.getModel();\n flightsDftTblMdl.setRowCount(0);\n\n while (rs.next()) {\n //holds all valauese from table Flight\n Object[] a = new Object[6];\n //assigning of the values from Flight\n for (int i = 0; i < columnCount; i++) {\n a[0] = rs.getString(\"departure\");\n a[1] = rs.getString(\"destination\");\n a[2] = rs.getString(\"depTime\");\n a[3] = rs.getString(\"arrTime\");\n a[4] = rs.getInt(\"number\");\n a[5] = rs.getDouble(\"price\");\n }// add new row to the model\n flightsDftTblMdl.addRow(a);\n }\n\n } catch (ClassNotFoundException | SQLException ex) {\n Logger.getLogger(BookTicket.class.getName()).log(Level.SEVERE, null, ex);\n }\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n jScrollPane1 = new javax.swing.JScrollPane();\n tableResult = new javax.swing.JTable();\n\n setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);\n setTitle(\"Histórico Parcelas a Liberar\");\n\n tableResult.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n\n },\n new String [] {\n \"Valor\", \"Data Vencimento\"\n }\n ) {\n Class[] types = new Class [] {\n java.lang.String.class, java.lang.String.class\n };\n boolean[] canEdit = new boolean [] {\n false, false\n };\n\n public Class getColumnClass(int columnIndex) {\n return types [columnIndex];\n }\n\n public boolean isCellEditable(int rowIndex, int columnIndex) {\n return canEdit [columnIndex];\n }\n });\n jScrollPane1.setViewportView(tableResult);\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());\n getContentPane().setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addContainerGap()\n .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 333, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addContainerGap()\n .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 278, Short.MAX_VALUE)\n .addContainerGap())\n );\n\n pack();\n }", "private void mostrar() {\n //DefaultTableModel m = new DefaultTableModel();\n m = new DefaultTableModel(){\n @Override\n public boolean isCellEditable(int row, int column) {\n if (column==6) {\n return true;\n }else{\n return false;\n }\n }\n \n };\n tr = new TableRowSorter(m);\n m.setColumnCount(0);\n m.addColumn(\"Id\");\n m.addColumn(\"Nombre\");\n m.addColumn(\"Apellido\");\n m.addColumn(\"Direccion\");\n m.addColumn(\"Correo\");\n m.addColumn(\"Clave\");\n for (ClienteVO cvo : cdao.consultarTabla()) {\n m.addRow(new Object[]{cvo.getId_cliente(),cvo.getNombre_cliente(),cvo.getApellido_cliente(),cvo.getDireccion_cliente(),cvo.getCorreo_cliente(),cvo.getClave_cliente()});\n }\n vista.tblClientes.setModel(m);\n vista.tblClientes.setRowSorter(tr);\n }", "private void cargarTablaConPaquetes() {\n tcId.setCellValueFactory(\n new PropertyValueFactory<Paquete, String>(\"codigo\"));\n tcdescripcion.setCellValueFactory(\n new PropertyValueFactory<Paquete, String>(\"descripcion\"));\n tcDestino.setCellValueFactory(\n new PropertyValueFactory<Paquete, String>(\"destino\"));\n tcEntregado.setCellValueFactory(\n new PropertyValueFactory<Paquete, Boolean>(\"entregado\"));\n\n tbPaqueteria.setItems(data);\n tbPaqueteria.getSelectionModel().selectFirst();\n\n //TODO futura implementacion\n //setDobleClickFila();\n }", "public void tabelaktivitas() {\n DefaultTableModel tbl= new DefaultTableModel();\n tbl.addColumn(\"Group\");\n tbl.addColumn(\"Compart\");\n tbl.addColumn(\"Activity\");\n tbl.addColumn(\"HA\");\n tbl.addColumn(\"Harga\");\n tbl.addColumn(\"Total\");\n tblaktivitas.setModel(tbl);\n try{\n java.sql.Statement statement=(java.sql.Statement)conek.GetConnection().createStatement();\n ResultSet res=statement.executeQuery(\"select * from tblaktivitas\");\n while(res.next())\n {\n tbl.addRow(new Object[]{\n res.getString(\"nama_grup\"),\n res.getString(\"compart\"),\n res.getString(\"pekerjaan\"),\n res.getInt(\"ha\"),\n res.getInt(\"harga\"),\n res.getInt(\"total\")\n });\n tblaktivitas.setModel(tbl); \n }\n }catch (Exception e){\n JOptionPane.showMessageDialog(rootPane,\"Salah\");\n }\n }", "public void updateDisplayBoardTable(){\n try{\n // Connect to db\n Class.forName(\"com.mysql.jdbc.Driver\");\n Connection con = DriverManager.getConnection(\"jdbc:mysql://localhost:3306/nfqdb\", \"root\", \"\");\n \n Statement st = con.createStatement();\n // MySQL Query\n String sql = \"select * from visit\";\n ResultSet rs = st.executeQuery(sql);\n \n // Delete old data from the table\n DefaultTableModel dm = (DefaultTableModel) DisplayBoard.screenTable.getModel();\n int rowCount = dm.getRowCount();\n //Remove rows one by one from the end of the table\n for (int i = rowCount - 1; i >= 0; i--) {\n dm.removeRow(i);\n }\n \n // Add new data in table\n while(rs.next()){\n // data will be added until finish\n String id = \"000\" + String.valueOf(rs.getInt(\"id_visit\")); //conversion due to int value\n String specid = String.valueOf(rs.getInt(\"spec_id\")); //conversion due to int value\n String date = String.valueOf(rs.getTimestamp(\"datetime\"));\n String spcnam = rs.getString(\"spec_name\");\n String cusnam = rs.getString(\"customer_name\");\n String status = rs.getString(\"status\");\n \n // String array for store data into jtable\n \n String tbData[] = {id, specid, date, spcnam, cusnam, status};\n DefaultTableModel tblModel = (DefaultTableModel)DisplayBoard.screenTable.getModel();\n tblModel.addRow(tbData);\n }\n con.close();\n }\n catch(Exception e){\n JOptionPane.showMessageDialog(null, e);\n }\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n jScrollPane1 = new javax.swing.JScrollPane();\n tabela_produto_vedas = new javax.swing.JTable();\n\n setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);\n setTitle(\"Tabela de Produtos\");\n\n tabela_produto_vedas.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n\n },\n new String [] {\n \"Id Produto\", \"Referencia\", \"Modelo\", \"Marca\", \"Tamanho\", \"Quantidade\", \"Cor\", \"Valor Compra\", \"Valor Venda\"\n }\n ) {\n boolean[] canEdit = new boolean [] {\n false, false, false, false, false, false, false, false, false\n };\n\n public boolean isCellEditable(int rowIndex, int columnIndex) {\n return canEdit [columnIndex];\n }\n });\n tabela_produto_vedas.addKeyListener(new java.awt.event.KeyAdapter() {\n public void keyPressed(java.awt.event.KeyEvent evt) {\n tabela_produto_vedasKeyPressed(evt);\n }\n });\n jScrollPane1.setViewportView(tabela_produto_vedas);\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());\n getContentPane().setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jScrollPane1, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, 900, Short.MAX_VALUE)\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 484, javax.swing.GroupLayout.PREFERRED_SIZE)\n );\n\n setSize(new java.awt.Dimension(918, 531));\n setLocationRelativeTo(null);\n }", "public void buscarxdescrip() {\r\n try {\r\n modelo.setDescripcion(vista.jTbdescripcion.getText());//C.P.M le enviamos al modelo la descripcion y consultamos\r\n rs = modelo.Buscarxdescrip();//C.P.M cachamos el resultado de la consulta\r\n\r\n DefaultTableModel buscar = new DefaultTableModel() {//C.P.M creamos el modelo de la tabla\r\n @Override\r\n public boolean isCellEditable(int rowIndex, int vColIndex) {\r\n return false;\r\n }\r\n };\r\n vista.jTbuscar.setModel(buscar);//C.P.M le mandamos el modelo a la tabla\r\n modelo.estructuraProductos(buscar);//C.P.M obtenemos la estructura de la tabla \"encabezados\"\r\n ResultSetMetaData rsMd = rs.getMetaData();//C.P.M obtenemos los metadatos de la consulta\r\n int cantidadColumnas = rsMd.getColumnCount();//C.P.M obtenemos la cantidad de columnas de la consulta\r\n while (rs.next()) {//C.P.M recorremos el resultado\r\n Object[] fila = new Object[cantidadColumnas];//C.P.M creamos un arreglo con una dimencion igual a la cantidad de columnas\r\n for (int i = 0; i < cantidadColumnas; i++) { //C.P.M lo recorremos \r\n fila[i] = rs.getObject(i + 1); //C.P.M vamos insertando los resultados dentor del arreglo\r\n }\r\n buscar.addRow(fila);//C.P.M y lo agregamos como una nueva fila a la tabla\r\n }\r\n\r\n } catch (SQLException ex) {\r\n JOptionPane.showMessageDialog(null, \"Ocurrio un error al buscar producto por descripcion\");\r\n }\r\n }", "public Listagem() {\n initComponents();\n editora = new EditoraPersistencia(\"Editoras.txt\");\n autor = new AutorPersistencia(\"Autores.txt\");\n areaDeConhecimento = new AreaDeConhecimentoPersistencia(\"DDD.txt\");\n colaborador = new ColaboradorPersistencia(\"Colaboradores.txt\");\n livro = new LivroPersistencia(\"Livros.txt\");\n \n // Criando tabela Listar Autor\n DefaultTableModel modelAutores = (DefaultTableModel) jTable_tabelaAutores.getModel();\n jTable_tabelaAutores.setRowSorter(new TableRowSorter(modelAutores)); \n \n // Criando tabala Listar Area de Conhecimento\n DefaultTableModel modelAreasDeConhecimento = (DefaultTableModel) jTable_tabelaAreaDeConhecimento.getModel();\n jTable_tabelaAreaDeConhecimento.setRowSorter(new TableRowSorter(modelAreasDeConhecimento)); \n \n //Criando tabela Listar Colaboradores\n DefaultTableModel modelColaboradores = (DefaultTableModel) jTable_tabelaColaboradores.getModel();\n jTable_tabelaColaboradores.setRowSorter(new TableRowSorter(modelColaboradores));\n \n //Criando tabela Listar Livros\n DefaultTableModel modelLivros = (DefaultTableModel) jTable_tabelaLivros.getModel();\n jTable_tabelaLivros.setRowSorter(new TableRowSorter(modelLivros));\n \n try{\n listarDadosNaTelaEditora(editora.recuperar());\n listarDadosNaTelaAutor(autor.recuperar(),modelAutores);\n listarDadosNaTelaAreaDeConhecimento(areaDeConhecimento.recuperar(), modelAreasDeConhecimento);\n listarDadosNaTelaColaborador(colaborador.recuperar(),modelColaboradores);\n listarDadosNaTelaLivro(livro.recuperar(),modelLivros);\n }catch (Exception erro){\n JOptionPane.showMessageDialog(rootPane, erro);\n }\n }", "public void populateDonorsJTable(){\n \n \n Calculator c = new Calculator();\n DefaultTableModel model = (DefaultTableModel) donorsJTable.getModel();\n donorsJTable.setAutoCreateRowSorter(true);\n model.setRowCount(0);\n \n for(Organization o: ent.getOrganizationDirectory().getOrganizationList()){\n// Organization o=(DonorOrganization) org;\n if(o instanceof DonorOrganization){\n DonorOrganization or=(DonorOrganization) o;\n// for(UserAccount acct :org.getUserAccountDirectory().getUserAccountList()){\n// account=acct;\n for (Employee e : or.getEmployeeDirectory().getEmployeeList()){\n \n Object[] em = new Object[1];\n em[0]=e.getName();\n \n \n if(!em[0].equals(account.getUsername())){\n \n donor = (Donor)e;\n if(donor.getBloodDetails().getBloodType().equals(bloodType)){\n// if(distance>c.calculateDistance(lat1,lon1,donor.getDetails().getLatitude(),donor.getDetails().getLongitude())){\n Object[] row = new Object[8];\n row[0] = e.getName();\n row[1]= account.getUsername();\n row[2] = c.calculateDistance(lat1,lon1,donor.getDetails().getLatitude(),donor.getDetails().getLongitude());\n row[3] = donor.getDetails().getLatitude();\n row[4] = donor.getDetails().getLongitude();\n row[5]=lat1;\n row[6]=lon1;\n row[7]=donor.getDetails().getLocation();\n model.addRow(row);\n// }\n }\n }\n \n \n \n }\n \n }\n \n }\n \n }", "public void verLineaTicket() throws SQLException{\n try (PreparedStatement query = Herramientas.getConexion().prepareStatement(\"SELECT * FROM linea_ticket WHERE codigo_ticket=?\")) {\n query.setInt(1, this.getCodigo());\n try (ResultSet resultado = query.executeQuery()) {\n while(resultado.next()){\n LineaCompra lineaT1=new LineaCompra(resultado.getInt(2),resultado.getInt(3),resultado.getDouble(4));\n this.getLineasTicket().add(lineaT1);\n }\n }\n }\n }", "public void ProductsAcquisition(DefaultTableModel tableModel, int parameter){\n connect();\n ResultSet result = null;\n tableModel.setRowCount(0);\n tableModel.setColumnCount(0);\n String sql = \"SELECT productos.descripcion, productos.presentacion, productos.precio, adquisicion.cantidad,\"\n + \" adquisicion.importe FROM productos JOIN adquisicion JOIN facturas ON productos.id_producto =\"\n + \" adquisicion.producto AND adquisicion.factura = facturas.folio WHERE facturas.folio = ? ORDER BY descripcion\";\n \n try{\n PreparedStatement ps = connect.prepareStatement(sql);\n ps.setInt(1, parameter);\n result = ps.executeQuery();\n if(result != null){\n int columnNumber = result.getMetaData().getColumnCount();\n for(int i = 1; i <= columnNumber; i++){\n tableModel.addColumn(result.getMetaData().getColumnName(i));\n }\n while(result.next()){\n Object []obj = new Object[columnNumber];\n for(int i = 1; i <= columnNumber; i++){\n obj[i-1] = result.getObject(i);\n }\n tableModel.addRow(obj);\n }\n }\n connect.close();\n }catch(SQLException ex){\n ex.printStackTrace();\n } \n }", "public void cargarDatos() {\n \n if(drogasIncautadoList==null){\n return;\n }\n \n \n \n List<Droga> datos = drogasIncautadoList;\n\n Object[][] matriz = new Object[datos.size()][4];\n \n for (int i = 0; i < datos.size(); i++) {\n \n \n //System.out.println(s[0]);\n \n matriz[i][0] = datos.get(i).getTipoDroga();\n matriz[i][1] = datos.get(i).getKgDroga();\n matriz[i][2] = datos.get(i).getQuetesDroga();\n matriz[i][3] = datos.get(i).getDescripcion();\n \n }\n Object[][] data = matriz;\n String[] cabecera = {\"Tipo Droga\",\"KG\", \"Quetes\", \"Descripción\"};\n dtm = new DefaultTableModel(data, cabecera);\n tableDatos.setModel(dtm);\n }", "private void TampilData() {\n DefaultTableModel model = new DefaultTableModel();\n model.addColumn(\"NO\");\n model.addColumn(\"ID\");\n model.addColumn(\"NAME\");\n model.addColumn(\"USERNAME\");\n tabelakses.setModel(model);\n\n //menampilkan data database kedalam tabel\n try {\n int i=1;\n java.sql.Connection conn = new DBConnection().connect();\n java.sql.Statement stat = conn.createStatement();\n ResultSet data = stat.executeQuery(\"SELECT * FROM p_login order by Id asc\");\n while (data.next()) {\n model.addRow(new Object[]{\n (\"\" + i++),\n data.getString(\"Id\"),\n data.getString(\"Name\"),\n data.getString(\"Username\")\n });\n tabelakses.setModel(model);\n }\n } catch (Exception e) {\n System.err.println(\"ERROR:\" + e);\n }\n }", "public static void searchAll(){\r\n try {\r\n singleton.dtm = new DefaultTableModel(); \r\n singleton.dtm.setColumnIdentifiers(general);\r\n home_RegisterUser.table.setModel(singleton.dtm);\r\n \r\n Statement stmt = singleton.conn.createStatement();\r\n ResultSet rs = stmt.executeQuery(\"SELECT * FROM articulos\");\r\n //SELECT a.*,c.nombre FROM articulos a,categorias c,prodcategoria p WHERE a.codigo = p.articulo AND c.categoria_id = p.categoria\r\n \r\n while(rs.next()){\r\n int stock = rs.getInt(\"stock\");\r\n String stock2;\r\n if(stock>0){\r\n stock2 = \"Esta en Stock\";\r\n }else{\r\n stock2 = \"No esta en Stock\";\r\n }\r\n singleton.dtm.addRow(getArrayDeObjectos(rs.getInt(\"codigo\"),rs.getString(\"nombre\"),rs.getString(\"fabricante\"),rs.getFloat(\"precio\"),stock2)); \r\n }\r\n } catch (SQLException ex) {\r\n System.err.println(\"SQL Error: \"+ex);\r\n }catch(Exception ex){\r\n System.err.println(\"Error: \"+ex);\r\n }\r\n }", "public DefaultTableModel getTablaFutbolistas() {\n DefaultTableModel tablemodel = new DefaultTableModel();\n\n int registros = 0;\n String[] columNames = {\"Id\", \"NIF\", \"Nombre\", \"Apellidos\", \"Fecha nac.\", \"Nacionalidad\"};\n //obtenemos la cantidad de registros existentes en la tabla y se almacena en la variable \"registros\"\n //para formar la matriz de datos\n try {\n PreparedStatement pstm = this.getConnection().prepareStatement(\"SELECT count(*) as total FROM Futbolistas\");\n ResultSet res = pstm.executeQuery();\n res.next();\n registros = res.getInt(\"total\");\n close(res);\n } catch (SQLException e) {\n System.err.println(e.getMessage());\n }\n //se crea una matriz con tantas filas y columnas que necesite\n Object[][] data = new String[registros][7];\n try {\n //realizamos la consulta sql y llenamos los datos en la matriz \"Object[][] data\"\n PreparedStatement pstm = this.getConnection().prepareStatement(\"SELECT * FROM Futbolistas\");\n ResultSet res = pstm.executeQuery();\n int i = 0;\n while (res.next()) {\n data[i][0] = res.getString(\"id_futbolista\");\n data[i][1] = res.getString(\"nif\");\n data[i][2] = res.getString(\"nombre\");\n data[i][3] = res.getString(\"apellidos\");\n data[i][4] = res.getString(\"fecha_nacimiento\");\n data[i][5] = res.getString(\"nacionalidad\");\n i++;\n }\n close(res);\n //se añade la matriz de datos en el DefaultTableModel\n tablemodel.setDataVector(data, columNames);\n } catch (SQLException e) {\n System.err.println(e.getMessage());\n }\n return tablemodel;\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n jScrollPane1 = new javax.swing.JScrollPane();\n table = new javax.swing.JTable();\n jPanel1 = new javax.swing.JPanel();\n jLabel1 = new javax.swing.JLabel();\n txtId = new javax.swing.JTextField();\n jButton1 = new javax.swing.JButton();\n jButton2 = new javax.swing.JButton();\n jButton3 = new javax.swing.JButton();\n jButton4 = new javax.swing.JButton();\n txtSearch = new javax.swing.JTextField();\n jLabel4 = new javax.swing.JLabel();\n txtPrice = new javax.swing.JTextField();\n jLabel6 = new javax.swing.JLabel();\n txtDate = new org.jdesktop.swingx.JXDatePicker();\n jLabel9 = new javax.swing.JLabel();\n jScrollPane2 = new javax.swing.JScrollPane();\n tableDetail = new javax.swing.JTable();\n jPanel2 = new javax.swing.JPanel();\n jLabel5 = new javax.swing.JLabel();\n txtSearchDetail = new javax.swing.JTextField();\n jLabel2 = new javax.swing.JLabel();\n txtIdDetail = new javax.swing.JTextField();\n jLabel8 = new javax.swing.JLabel();\n comboBook = new javax.swing.JComboBox();\n jLabel7 = new javax.swing.JLabel();\n txtCount = new javax.swing.JTextField();\n jButton5 = new javax.swing.JButton();\n jButton6 = new javax.swing.JButton();\n jButton7 = new javax.swing.JButton();\n jButton8 = new javax.swing.JButton();\n\n setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);\n setTitle(\"Книги\");\n setResizable(false);\n\n table.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n {},\n {},\n {},\n {}\n },\n new String [] {\n\n }\n ));\n table.addMouseListener(new java.awt.event.MouseAdapter() {\n public void mouseClicked(java.awt.event.MouseEvent evt) {\n tableMouseClicked(evt);\n }\n });\n jScrollPane1.setViewportView(table);\n\n jPanel1.setBorder(javax.swing.BorderFactory.createEtchedBorder());\n\n jLabel1.setText(\"ID\");\n\n txtId.setEditable(false);\n\n jButton1.setText(\"Добавить\");\n jButton1.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n jButton1ActionPerformed(evt);\n }\n });\n\n jButton2.setText(\"Удалить\");\n jButton2.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n jButton2ActionPerformed(evt);\n }\n });\n\n jButton3.setText(\"Обновить\");\n jButton3.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n jButton3ActionPerformed(evt);\n }\n });\n\n jButton4.setText(\"Очистить\");\n jButton4.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n jButton4ActionPerformed(evt);\n }\n });\n\n txtSearch.setToolTipText(\"Искомый текст\");\n txtSearch.addKeyListener(new java.awt.event.KeyAdapter() {\n public void keyReleased(java.awt.event.KeyEvent evt) {\n txtSearchKeyReleased(evt);\n }\n public void keyTyped(java.awt.event.KeyEvent evt) {\n txtSearchKeyTyped(evt);\n }\n });\n\n jLabel4.setText(\"Фильтр\");\n\n jLabel6.setText(\"Итого\");\n\n jLabel9.setText(\"Дата продажи\");\n\n javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);\n jPanel1.setLayout(jPanel1Layout);\n jPanel1Layout.setHorizontalGroup(\n jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jLabel1)\n .addComponent(jLabel4)\n .addComponent(jLabel6)\n .addComponent(jLabel9))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 41, Short.MAX_VALUE)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)\n .addComponent(txtDate, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(txtPrice)\n .addComponent(txtSearch, javax.swing.GroupLayout.Alignment.TRAILING)\n .addComponent(txtId, javax.swing.GroupLayout.DEFAULT_SIZE, 233, Short.MAX_VALUE)))\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel1Layout.createSequentialGroup()\n .addGap(0, 0, Short.MAX_VALUE)\n .addComponent(jButton1, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(jButton2)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jButton4)\n .addComponent(jButton3))))\n .addContainerGap())\n );\n\n jPanel1Layout.linkSize(javax.swing.SwingConstants.HORIZONTAL, new java.awt.Component[] {jButton1, jButton2, jButton3, jButton4});\n\n jPanel1Layout.setVerticalGroup(\n jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(txtSearch, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jLabel4))\n .addGap(18, 18, 18)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel1)\n .addComponent(txtId, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(txtDate, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jLabel9))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel6)\n .addComponent(txtPrice, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGap(44, 44, 44)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jButton1)\n .addComponent(jButton2)\n .addComponent(jButton3))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(jButton4)\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n );\n\n tableDetail.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n {},\n {},\n {},\n {}\n },\n new String [] {\n\n }\n ));\n tableDetail.addMouseListener(new java.awt.event.MouseAdapter() {\n public void mouseClicked(java.awt.event.MouseEvent evt) {\n tableDetailMouseClicked(evt);\n }\n });\n jScrollPane2.setViewportView(tableDetail);\n\n jPanel2.setBorder(javax.swing.BorderFactory.createEtchedBorder());\n\n jLabel5.setText(\"Фильтр\");\n\n txtSearchDetail.setToolTipText(\"Искомый текст\");\n txtSearchDetail.addKeyListener(new java.awt.event.KeyAdapter() {\n public void keyReleased(java.awt.event.KeyEvent evt) {\n txtSearchDetailKeyReleased(evt);\n }\n public void keyTyped(java.awt.event.KeyEvent evt) {\n txtSearchDetailKeyTyped(evt);\n }\n });\n\n jLabel2.setText(\"ID\");\n\n txtIdDetail.setEditable(false);\n\n jLabel8.setText(\"Книга\");\n\n jLabel7.setText(\"Количество\");\n\n jButton5.setText(\"Добавить\");\n jButton5.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n jButton5ActionPerformed(evt);\n }\n });\n\n jButton6.setText(\"Удалить\");\n jButton6.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n jButton6ActionPerformed(evt);\n }\n });\n\n jButton7.setText(\"Обновить\");\n jButton7.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n jButton7ActionPerformed(evt);\n }\n });\n\n jButton8.setText(\"Очистить\");\n jButton8.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n jButton8ActionPerformed(evt);\n }\n });\n\n javax.swing.GroupLayout jPanel2Layout = new javax.swing.GroupLayout(jPanel2);\n jPanel2.setLayout(jPanel2Layout);\n jPanel2Layout.setHorizontalGroup(\n jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel2Layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel2Layout.createSequentialGroup()\n .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jLabel5)\n .addComponent(jLabel2)\n .addComponent(jLabel8)\n .addComponent(jLabel7))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)\n .addComponent(txtCount)\n .addComponent(comboBook, 0, 234, Short.MAX_VALUE)\n .addComponent(txtIdDetail)\n .addComponent(txtSearchDetail)))\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel2Layout.createSequentialGroup()\n .addGap(0, 0, Short.MAX_VALUE)\n .addComponent(jButton5, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(jButton6, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jButton8, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jButton7, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE))))\n .addContainerGap())\n );\n jPanel2Layout.setVerticalGroup(\n jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel2Layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(txtSearchDetail, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jLabel5))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel2)\n .addComponent(txtIdDetail, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jLabel8)\n .addComponent(comboBook, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel7)\n .addComponent(txtCount, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGap(18, 18, 18)\n .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jButton5)\n .addComponent(jButton6)\n .addComponent(jButton7))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(jButton8)\n .addContainerGap())\n );\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());\n getContentPane().setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(jPanel2, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n .addContainerGap())\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)\n .addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 0, Short.MAX_VALUE))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)\n .addComponent(jPanel2, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 0, Short.MAX_VALUE))\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n );\n\n pack();\n }", "public void buscar() { // ATENCION tengo dudas con % telefono% no sale ningun resultado. si sale con telefono%\n String nombre = AgendarA.txtBNombre.getText();\n String apellidos = AgendarA.txtBApellidos.getText();\n String ciudad = AgendarA.txtBCiudad.getText();\n\n modeloagr = new DefaultTableModel(null, columnasAgr) {\n public boolean isCellEditable(int fila, int columna) {\n return false;\n }\n };\n if (AgendarA.chNombre.isSelected() == true && AgendarA.chApellidos.isSelected() == true && AgendarA.chCiudad.isSelected() == true) {\n if (!nombre.equals(\"\") && !apellidos.equals(\"\") && !ciudad.equals(\"\")) {\n tbl.llenarTabla(AgendarA.tblAgricultor, modeloagr, columnasAgr.length, \"SELECT idPersonalExterno,cedula,CONCAT(nombres,' ',apellidos),municipios.Nombre,telefono,telefono2,telefono3 FROM personalexterno,municipios WHERE personalexterno.nombres LIKE '%\" + nombre + \"%' AND personalexterno.apellidos LIKE '%\" + apellidos + \"%' AND municipios.Nombre LIKE '%\" + ciudad + \"%' AND personalexterno.idMunicipio=municipios.idMunicipio AND tipo='agricultor' GROUP BY nombre\");\n tbl.alinearHeaderTable(AgendarA.tblAgenda, headerColumnasAgenda);\n tbl.alinearCamposTable(AgendarA.tblAgricultor, camposColumnas);\n } else {\n JOptionPane.showMessageDialog(null, \"Uno de los campos que selecciono para la busqueda esta vacio\");\n }\n } else if (AgendarA.chNombre.isSelected() == true && AgendarA.chApellidos.isSelected() == true) {\n if (!nombre.equals(\"\") && !apellidos.equals(\"\")) {\n tbl.llenarTabla(AgendarA.tblAgricultor, modeloagr, columnasAgr.length, \"SELECT idPersonalExterno,cedula,CONCAT(nombres,' ',apellidos),municipios.Nombre,telefono,telefono2,telefono3 FROM personalexterno,municipios WHERE personalexterno.nombres LIKE '%\" + nombre + \"%' AND personalexterno.Apellidos LIKE '%\" + apellidos + \"%' AND personalexterno.idMunicipio=municipios.idMunicipio AND tipo='agricultor' GROUP BY cedula\");\n tbl.alinearHeaderTable(AgendarA.tblAgenda, headerColumnasAgenda);\n tbl.alinearCamposTable(AgendarA.tblAgricultor, camposColumnas);\n } else {\n JOptionPane.showMessageDialog(null, \"Uno de los campos que selecciono para la busqueda esta vacio\");\n }\n } else if (AgendarA.chNombre.isSelected() == true && AgendarA.chCiudad.isSelected() == true) {\n if (!nombre.equals(\"\") && !ciudad.equals(\"\")) {\n tbl.llenarTabla(AgendarA.tblAgricultor, modeloagr, columnasAgr.length, \"SELECT idPersonalExterno,nombre,CONCAT(nombres,' ',apellidos),municipios.Nombre,telefono,telefono2,telefono3 FROM personalexterno,municipios WHERE municipios.Nombre LIKE '%\" + ciudad + \"%' AND personalexterno.nombres LIKE '%\" + nombre + \"%' AND personalexterno.idMunicipio=municipios.idMunicipio AND tipo='agricultor' GROUP BY cedula\");\n tbl.alinearHeaderTable(AgendarA.tblAgenda, headerColumnasAgenda);\n tbl.alinearCamposTable(AgendarA.tblAgricultor, camposColumnas);\n } else {\n JOptionPane.showMessageDialog(null, \"Uno de los campos que selecciono para la busqueda esta vacio\");\n }\n } else if (AgendarA.chApellidos.isSelected() == true && AgendarA.chCiudad.isSelected() == true) {\n if (!apellidos.equals(\"\") && !ciudad.equals(\"\")) {\n tbl.llenarTabla(AgendarA.tblAgricultor, modeloagr, columnasAgr.length, \"SELECT idPersonalExterno,personalexterno.cedula,nombres,apellidos,municipios.Nombre FROM personalexterno,municipios WHERE municipios.Nombre LIKE '%\" + ciudad + \"%' AND personalexterno.apellidos LIKE '%\" + apellidos + \"%' AND personalexterno.idMunicipio=municipios.idMunicipio AND tipo='agricultor' GROUP BY cedula\");\n tbl.alinearHeaderTable(AgendarA.tblAgenda, headerColumnasAgenda);\n tbl.alinearCamposTable(AgendarA.tblAgricultor, camposColumnas);\n } else {\n JOptionPane.showMessageDialog(null, \"Uno de los campos que selecciono para la busqueda esta vacio\");\n }\n } else if (AgendarA.chNombre.isSelected() == true) {\n if (!nombre.equals(\"\")) {\n tbl.llenarTabla(AgendarA.tblAgricultor, modeloagr, columnasAgr.length, \"SELECT idPersonalExterno,cedula,CONCAT(nombres,' ',apellidos),municipios.Nombre,telefono,telefono2,telefono3 FROM personalexterno,municipios WHERE personalexterno.nombres LIKE '%\" + nombre + \"%' AND personalexterno.idMunicipio=municipios.idMunicipio AND tipo='agricultor' GROUP BY cedula\");\n tbl.alinearHeaderTable(AgendarA.tblAgenda, headerColumnasAgenda);\n tbl.alinearCamposTable(AgendarA.tblAgricultor, camposColumnas);\n } else {\n JOptionPane.showMessageDialog(null, \"Uno de los campos que selecciono para la busqueda esta vacio\");\n }\n } else if (AgendarA.chApellidos.isSelected() == true) {\n if (!apellidos.equals(\"\")) {\n tbl.llenarTabla(AgendarA.tblAgricultor, modeloagr, columnasAgr.length, \"SELECT idPersonalExterno,cedula,CONCAT(nombres,' ',apellidos),municipios.Nombre,telefono,telefono2,telefono3 FROM personalexterno,municipios WHERE personalexterno.apellidos LIKE '%\" + apellidos + \"%' AND personalexterno.idMunicipio=municipios.idMunicipio AND tipo='agricultor' GROUP BY cedula\");\n tbl.alinearHeaderTable(AgendarA.tblAgenda, headerColumnasAgenda);\n tbl.alinearCamposTable(AgendarA.tblAgricultor, camposColumnas);\n } else {\n JOptionPane.showMessageDialog(null, \"Uno de los campos que selecciono para la busqueda esta vacio\");\n }\n } else if (AgendarA.chCiudad.isSelected() == true) {\n if (!ciudad.equals(\"\")) {\n tbl.llenarTabla(AgendarA.tblAgricultor, modeloagr, columnasAgr.length, \"SELECT idPersonalExterno,cedula,CONCAT(nombres,' ',apellidos),municipios.Nombre,telefono,telefono2,telefono3 FROM personalexterno,municipios WHERE municipios.Nombre LIKE '%\" + ciudad + \"%' AND personalexterno.idMunicipio=municipios.idMunicipio AND tipo='agricultor' GROUP BY cedula\");\n tbl.alinearHeaderTable(AgendarA.tblAgenda, headerColumnasAgenda);\n tbl.alinearCamposTable(AgendarA.tblAgricultor, camposColumnas);\n } else {\n JOptionPane.showMessageDialog(null, \"Uno de los campos que selecciono para la busqueda esta vacio\");\n }\n } else {\n JOptionPane.showMessageDialog(null, \"Ninguno de los campos de busqueda esta seleccionado\");\n }\n tbl.rowNumberTabel(AgendarA.tblAgricultor);\n //desactivar_checkbox();\n }", "public static void searchPrinter(){\r\n try { \r\n singleton.dtm = new DefaultTableModel();\r\n singleton.dtm.setColumnIdentifiers(printers);\r\n home_RegisterUser.table.setModel(singleton.dtm);\r\n \r\n Statement stmt = singleton.conn.createStatement();\r\n ResultSet rs = stmt.executeQuery(\"SELECT * FROM articulos a,impresora r WHERE a.codigo = r.codart\");\r\n \r\n while(rs.next()){\r\n int stock = rs.getInt(\"stock\");\r\n String stock2;\r\n if(stock>0){\r\n stock2 = \"Esta en Stock\";\r\n }else{\r\n stock2 = \"No esta en Stock\";\r\n }\r\n \r\n int color = rs.getInt(\"color\");\r\n String color2;\r\n if(color!=0){\r\n color2 = \"Si\";\r\n }else{\r\n color2 = \"No\";\r\n }\r\n \r\n singleton.dtm.addRow(getArrayDeObjectosPrinter(rs.getInt(\"codigo\"),rs.getString(\"nombre\"),rs.getString(\"fabricante\"),rs.getFloat(\"precio\"),stock2,rs.getString(\"tipo\"),color2,rs.getInt(\"ppm\")));\r\n\r\n }\r\n } catch (SQLException ex) {\r\n System.err.println(\"SQL Error: \"+ex);\r\n }catch(Exception ex){\r\n System.err.println(\"Error: \"+ex);\r\n }\r\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n jScrollPane1 = new javax.swing.JScrollPane();\n jtPost = new javax.swing.JTable();\n jButton1 = new javax.swing.JButton();\n jLabel1 = new javax.swing.JLabel();\n txtNroPost = new javax.swing.JTextField();\n btnOrderFecha = new javax.swing.JButton();\n cobOrdenar = new javax.swing.JComboBox<>();\n\n setClosable(true);\n setForeground(new java.awt.Color(102, 153, 255));\n setIconifiable(true);\n setMaximizable(true);\n setResizable(true);\n setTitle(\"Mis Post\");\n addInternalFrameListener(new javax.swing.event.InternalFrameListener() {\n public void internalFrameActivated(javax.swing.event.InternalFrameEvent evt) {\n }\n public void internalFrameClosed(javax.swing.event.InternalFrameEvent evt) {\n }\n public void internalFrameClosing(javax.swing.event.InternalFrameEvent evt) {\n }\n public void internalFrameDeactivated(javax.swing.event.InternalFrameEvent evt) {\n }\n public void internalFrameDeiconified(javax.swing.event.InternalFrameEvent evt) {\n }\n public void internalFrameIconified(javax.swing.event.InternalFrameEvent evt) {\n }\n public void internalFrameOpened(javax.swing.event.InternalFrameEvent evt) {\n formInternalFrameOpened(evt);\n }\n });\n\n jtPost.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n\n },\n new String [] {\n \"Post\", \"Story\", \"Url fb\", \"Fecha\", \"Nro Likes\", \"Likes\"\n }\n ) {\n Class[] types = new Class [] {\n java.lang.String.class, java.lang.String.class, java.lang.String.class, java.lang.String.class, java.lang.Long.class, java.lang.Integer.class\n };\n\n public Class getColumnClass(int columnIndex) {\n return types [columnIndex];\n }\n });\n jtPost.setColumnSelectionAllowed(true);\n jtPost.addMouseListener(new java.awt.event.MouseAdapter() {\n public void mouseClicked(java.awt.event.MouseEvent evt) {\n jtPostMouseClicked(evt);\n }\n });\n jScrollPane1.setViewportView(jtPost);\n jtPost.getColumnModel().getSelectionModel().setSelectionMode(javax.swing.ListSelectionModel.SINGLE_INTERVAL_SELECTION);\n if (jtPost.getColumnModel().getColumnCount() > 0) {\n jtPost.getColumnModel().getColumn(0).setPreferredWidth(200);\n jtPost.getColumnModel().getColumn(1).setPreferredWidth(200);\n jtPost.getColumnModel().getColumn(2).setPreferredWidth(200);\n jtPost.getColumnModel().getColumn(3).setPreferredWidth(100);\n jtPost.getColumnModel().getColumn(5).setPreferredWidth(200);\n }\n\n jButton1.setText(\"Mostrar Posts\");\n jButton1.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n jButton1ActionPerformed(evt);\n }\n });\n\n jLabel1.setText(\"#Post a mostrar:\");\n\n txtNroPost.setText(\"10\");\n\n btnOrderFecha.setText(\"Order por Fecha\");\n btnOrderFecha.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btnOrderFechaActionPerformed(evt);\n }\n });\n\n cobOrdenar.setModel(new javax.swing.DefaultComboBoxModel<>(new String[] { \"Item 1\", \"Item 2\", \"Item 3\", \"Item 4\" }));\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());\n getContentPane().setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 836, Short.MAX_VALUE)\n .addGroup(layout.createSequentialGroup()\n .addComponent(jLabel1)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(txtNroPost, javax.swing.GroupLayout.PREFERRED_SIZE, 75, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addComponent(jButton1)\n .addGap(65, 65, 65)\n .addComponent(cobOrdenar, javax.swing.GroupLayout.PREFERRED_SIZE, 136, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addComponent(btnOrderFecha)\n .addGap(0, 0, Short.MAX_VALUE)))\n .addContainerGap())\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addGap(15, 15, 15)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jButton1)\n .addComponent(txtNroPost, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(btnOrderFecha)\n .addComponent(cobOrdenar, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addComponent(jLabel1))\n .addGap(18, 18, 18)\n .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 441, Short.MAX_VALUE)\n .addContainerGap())\n );\n\n pack();\n }", "private void llenar_tabla() {\n \n try {\n DefaultTableModel modelo;\n conexion cnx = new conexion();\n Connection registros = cnx.conexion();\n String[] nombre_atributos = {\"id_producto\", \"nombre\",\"id_categoria\"};\n String sql = (\"SELECT *FROM producto\");\n modelo = new DefaultTableModel(null, nombre_atributos);\n Statement st = (Statement) registros.createStatement();\n ResultSet rs = st.executeQuery(sql);\n String[] filas = new String[3];\n\n while (rs.next()) {\n filas[0] = rs.getString(\"id_producto\");\n filas[1] = rs.getString(\"nombre\");\n filas[2] = rs.getString(\"id_categoria\");\n modelo.addRow(filas);\n\n }\n jtabla.setModel(modelo);\n registros.close();\n } catch (SQLException ex) {\n Logger.getLogger(responsable.class.getName()).log(Level.SEVERE, null, ex);\n }\n \n }", "public void atualizarTabelaFunc() throws SQLException {\n DefaultTableModel model = (DefaultTableModel) tabelaFunc.getModel();\n model.setNumRows(0);\n dadosDAO dados = new dadosDAO();\n String pesquisa = funcField.getText().toUpperCase();\n for (funcionario func : dados.readFuncionarios()){\n if (!funcField.getText().equals(\"\")){\n if (nomeBtnFunc.isSelected()){\n if (func.getNome().contains(pesquisa)){\n model.addRow(new Object[]{\n func.getId_func(),\n nomeProprio(func.getNome()),\n func.getCpf(),\n func.getDt_nascimento(),\n func.getSexo(),\n func.getTelfix(),\n func.getRamal(),\n func.getTelcel(),\n func.getCep(),\n func.getCargo(),\n func.getTurno(),\n func.getSalario()\n });\n }\n } else if (cpfBtnFunc.isSelected()){\n if (funcField.getText().equals(func.getCpf())) {\n model.addRow(new Object[]{\n func.getId_func(),\n nomeProprio(func.getNome()),\n func.getCpf(),\n func.getDt_nascimento(),\n func.getSexo(),\n func.getTelfix(),\n func.getRamal(),\n func.getTelcel(),\n func.getCep(),\n func.getCargo(),\n func.getTurno(),\n func.getSalario()\n });\n }\n } else {\n if (funcField.getText().equals(String.valueOf(func.getId_func()))){\n model.addRow(new Object[]{\n func.getId_func(),\n nomeProprio(func.getNome()),\n func.getCpf(),\n func.getDt_nascimento(),\n func.getSexo(),\n func.getTelfix(),\n func.getRamal(),\n func.getTelcel(),\n func.getCep(),\n func.getCargo(),\n func.getTurno(),\n func.getSalario()\n });\n }\n }\n } else {\n model.addRow(new Object[]{\n func.getId_func(),\n nomeProprio(func.getNome()),\n func.getCpf(),\n func.getDt_nascimento(),\n func.getSexo(),\n func.getTelfix(),\n func.getRamal(),\n func.getTelcel(),\n func.getCep(),\n func.getCargo(),\n func.getTurno(),\n func.getSalario()\n });\n }\n }\n }", "private void createTableBill(){\r\n //Se crean y definen las columnas de la Tabla\r\n TableColumn col_orden = new TableColumn(\"#\"); \r\n TableColumn col_city = new TableColumn(\"Ciudad\");\r\n TableColumn col_codigo = new TableColumn(\"Código\"); \r\n TableColumn col_cliente = new TableColumn(\"Cliente\"); \r\n TableColumn col_fac_nc = new TableColumn(\"FAC./NC.\"); \r\n TableColumn col_fecha = new TableColumn(\"Fecha\");\r\n TableColumn col_monto = new TableColumn(\"Monto\"); \r\n TableColumn col_anulada = new TableColumn(\"A\");\r\n \r\n //Se establece el ancho de cada columna\r\n this.objectWidth(col_orden , 25, 25); \r\n this.objectWidth(col_city , 90, 150); \r\n this.objectWidth(col_codigo , 86, 86); \r\n this.objectWidth(col_cliente , 165, 300); \r\n this.objectWidth(col_fac_nc , 70, 78); \r\n this.objectWidth(col_fecha , 68, 68); \r\n this.objectWidth(col_monto , 73, 73); \r\n this.objectWidth(col_anulada , 18, 18);\r\n\r\n col_fac_nc.setCellFactory(new Callback<TableColumn, TableCell>() {\r\n @Override\r\n public TableCell call(TableColumn param) {\r\n return new TableCell<Fxp_Archguip_det, String>() {\r\n @Override\r\n public void updateItem(String item, boolean empty) {\r\n super.updateItem(item, empty);\r\n setText(empty ? null : getString());\r\n setAlignment(Pos.CENTER);\r\n }\r\n\r\n private String getString() {\r\n String ret = \"\";\r\n if (getItem() != null) {\r\n ret = getItem().toString();\r\n if (ret.equals(\"0\"))\r\n ret = \"\";\r\n } else {\r\n ret = \"\";\r\n }\r\n return ret;\r\n } \r\n };\r\n }\r\n }); \r\n\r\n col_fecha.setCellFactory(new Callback<TableColumn, TableCell>() {\r\n @Override\r\n public TableCell call(TableColumn param) {\r\n return new TableCell<Fxp_Archguip_det, Date>() {\r\n @Override\r\n public void updateItem(Date item, boolean empty) {\r\n super.updateItem(item, empty);\r\n if(!empty){\r\n setText(item.toLocalDate().toString());\r\n setAlignment(Pos.CENTER);\r\n }\r\n else\r\n setText(null);\r\n }\r\n };\r\n }\r\n }); \r\n\r\n col_monto.setCellFactory(new Callback<TableColumn, TableCell>() {\r\n @Override\r\n public TableCell call(TableColumn param) {\r\n return new TableCell<Fxp_Archguid, Double>() {\r\n @Override\r\n public void updateItem(Double item, boolean empty) {\r\n super.updateItem(item, empty);\r\n setText(empty ? null : getString());\r\n setAlignment(Pos.CENTER_RIGHT);\r\n }\r\n\r\n private String getString() {\r\n String ret = \"\";\r\n if (getItem() != null) {\r\n String gi = getItem().toString();\r\n NumberFormat df = DecimalFormat.getInstance();\r\n df.setMinimumFractionDigits(2);\r\n df.setRoundingMode(RoundingMode.DOWN);\r\n\r\n ret = df.format(Double.parseDouble(gi));\r\n } else {\r\n ret = \"0,00\";\r\n }\r\n return ret;\r\n } \r\n };\r\n }\r\n }); \r\n\r\n col_anulada.setCellFactory(new Callback<TableColumn, TableCell>() {\r\n @Override\r\n public TableCell call(TableColumn param) {\r\n return new TableCell<Fxp_Archguid, Integer>() {\r\n @Override\r\n public void updateItem(Integer item, boolean empty) {\r\n super.updateItem(item, empty);\r\n setText(empty ? null : getString());\r\n setAlignment(Pos.CENTER);\r\n }\r\n\r\n private String getString() {\r\n String ret = \"\";\r\n if (getItem() != null) {\r\n ret = getItem().toString();\r\n if (ret.equals(\"0\"))\r\n ret = \"\";\r\n\r\n setTextFill(isSelected() ? Color.WHITE :\r\n ret.equals(\"0\") ? Color.BLACK :\r\n ret.equals(\"1\") ? Color.RED : Color.GREEN);\r\n } else {\r\n ret = \"\";\r\n }\r\n return ret;\r\n } \r\n };\r\n }\r\n }); \r\n\r\n //Se define la columna de la tabla con el nombre del atributo del objeto USUARIO correspondiente\r\n col_orden.setCellValueFactory( \r\n new PropertyValueFactory<>(\"orden\") );\r\n col_city.setCellValueFactory( \r\n new PropertyValueFactory<>(\"ciudad\") );\r\n col_codigo.setCellValueFactory( \r\n new PropertyValueFactory<>(\"codigo\") );\r\n col_cliente.setCellValueFactory( \r\n new PropertyValueFactory<>(\"cliente\") );\r\n col_fac_nc.setCellValueFactory( \r\n new PropertyValueFactory<>(\"numdocs\") );\r\n col_fecha.setCellValueFactory( \r\n new PropertyValueFactory<>(\"fecdoc\") );\r\n col_monto.setCellValueFactory( \r\n new PropertyValueFactory<>(\"monto\") );\r\n col_anulada.setCellValueFactory( \r\n new PropertyValueFactory<>(\"anulada\") );\r\n \r\n //Se Asigna ordenadamente las columnas de la tabla\r\n tb_factura.getColumns().addAll(\r\n col_orden, col_city, col_codigo, col_cliente, col_fac_nc, col_fecha, \r\n col_monto, col_anulada \r\n ); \r\n \r\n //Se Asigna menu contextual \r\n tb_factura.setRowFactory((TableView<Fxp_Archguid> tableView) -> {\r\n final TableRow<Fxp_Archguid> row = new TableRow<>();\r\n final ContextMenu contextMenu = new ContextMenu();\r\n final MenuItem removeMenuItem = new MenuItem(\"Anular Factura\");\r\n removeMenuItem.setOnAction((ActionEvent event) -> {\r\n switch (tipoOperacion){\r\n case 1:\r\n tb_factura.getItems().remove(tb_factura.getSelectionModel().getSelectedIndex());\r\n break;\r\n case 2:\r\n tb_factura.getItems().get(tb_factura.getSelectionModel().getSelectedIndex()).setAnulada(1);\r\n col_anulada.setVisible(false);\r\n col_anulada.setVisible(true);\r\n break;\r\n }\r\n });\r\n contextMenu.getItems().add(removeMenuItem);\r\n // Set context menu on row, but use a binding to make it only show for non-empty rows:\r\n row.contextMenuProperty().bind(\r\n Bindings.when(row.emptyProperty())\r\n .then((ContextMenu)null)\r\n .otherwise(contextMenu)\r\n );\r\n return row ; \r\n });\r\n \r\n //Se define el comportamiento de las teclas ARRIBA y ABAJO en la tabla\r\n EventHandler eh = new EventHandler<KeyEvent>(){\r\n @Override\r\n public void handle(KeyEvent ke){\r\n //Si fue presionado la tecla ARRIBA o ABAJO\r\n if (ke.getCode().equals(KeyCode.UP) || ke.getCode().equals(KeyCode.DOWN)){ \r\n //Selecciona la FILA enfocada\r\n selectedRowInvoice();\r\n }\r\n }\r\n };\r\n //Se Asigna el comportamiento para que se ejecute cuando se suelta una tecla\r\n tb_factura.setOnKeyReleased(eh); \r\n }", "public void cargarTabla(String servidor){\n String base_de_datos1=cbBaseDeDatos.getSelectedItem().toString();\n String sql =\"USE [\"+base_de_datos1+\"]\\n\" +\n \"SELECT name FROM sysobjects where xtype='U' and category <> 2\";\n // JOptionPane.showMessageDialog(null,\"SQL cargarbases \"+sql);\n Conexion cc = new Conexion();\n Connection cn=cc.conectarBase(servidor, base_de_datos1);\n modeloTabla=new DefaultTableModel();\n String fila[]=new String[1] ;\n String[] titulos={\"Tablas\"} ;\n try {\n Statement psd = cn.createStatement();\n ResultSet rs=psd.executeQuery(sql);\n if(modeloTabla.getColumnCount()<2){\n modeloTabla.addColumn(titulos[0]);\n //modeloTabla.addColumn(titulos[1]);\n }\n while(rs.next()){\n fila[0]=rs.getString(\"name\");\n // fila[1]=\"1\";\n modeloTabla.addRow(fila);\n }\n tblTablas.setModel(modeloTabla);\n }catch(Exception ex){\n JOptionPane.showMessageDialog(null, ex+\" al cargar tabla\");\n }\n }", "public DefaultTableModel tablaempleados(JTable listaempleados)throws SQLException{\n Connection conexion = null;\n limpiartabla(listaempleados);\n try{\n conexion = GestionSQL.openConnection();\n if(conexion.getAutoCommit()){\n conexion.setAutoCommit(false);\n }\n DefaultTableModel modelo = (DefaultTableModel) listaempleados.getModel();\n EmpleadosDatos empleadodatos = new EmpleadosDatos();\n List<Empleado>empleados = empleadodatos.select();\n datosfila = new Object[modelo.getColumnCount()];\n \n //La tabla de se llena mediante un FOR usando la lista de objectos empleado traida desde metodo select\n for(int i = 0; i<empleados.size(); i++){\n datosfila[0]=empleados.get(i).getIdempleado();\n datosfila[1]=empleados.get(i).getNombre();\n datosfila[2]=empleados.get(i).getDNI();\n datosfila[3]=empleados.get(i).getTelefono();\n datosfila[4]=empleados.get(i).getEmail();\n modelo.addRow(datosfila);\n }\n }catch(SQLException e){\n System.out.println(\"Error en listadoempleados: \"+e);\n System.out.println(\"Entramos al rollback ¿Whynot?\");\n try{\n conexion.rollback();\n }catch(SQLException ex){\n ex.printStackTrace();\n System.out.println(\"Error en rollback\");\n }finally{\n if(conexion != null){\n conexion.close();\n }\n }\n }\n //retornamos el modelo que es el aspecto y los datos que le daremos a la tabla\n return modelo;\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n jSeparator2 = new javax.swing.JSeparator();\n jPanel1 = new javax.swing.JPanel();\n jScrollPane1 = new javax.swing.JScrollPane();\n Tabla = new javax.swing.JTable();\n jSeparator1 = new javax.swing.JSeparator();\n jPanel2 = new javax.swing.JPanel();\n jLabel5 = new javax.swing.JLabel();\n titulo = new javax.swing.JTextField();\n jLabel6 = new javax.swing.JLabel();\n jLabel7 = new javax.swing.JLabel();\n jLabel8 = new javax.swing.JLabel();\n jLabel9 = new javax.swing.JLabel();\n cat = new javax.swing.JTextField();\n Editorial = new javax.swing.JTextField();\n autor = new javax.swing.JTextField();\n an = new javax.swing.JTextField();\n jLabel4 = new javax.swing.JLabel();\n jSeparator3 = new javax.swing.JSeparator();\n guardar = new javax.swing.JLabel();\n jLabel2 = new javax.swing.JLabel();\n salir = new javax.swing.JLabel();\n Actualizar = new javax.swing.JLabel();\n\n Tabla.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n {null, null, null, null, null, null},\n {null, null, null, null, null, null},\n {null, null, null, null, null, null},\n {null, null, null, null, null, null}\n },\n new String [] {\n \"Código\", \"Titulo\", \"Año\", \"Autor\", \"Editorial\", \"Categoria\"\n }\n ) {\n Class[] types = new Class [] {\n java.lang.Integer.class, java.lang.String.class, java.lang.String.class, java.lang.String.class, java.lang.String.class, java.lang.String.class\n };\n boolean[] canEdit = new boolean [] {\n false, false, false, false, false, false\n };\n\n public Class getColumnClass(int columnIndex) {\n return types [columnIndex];\n }\n\n public boolean isCellEditable(int rowIndex, int columnIndex) {\n return canEdit [columnIndex];\n }\n });\n Tabla.addMouseListener(new java.awt.event.MouseAdapter() {\n public void mouseClicked(java.awt.event.MouseEvent evt) {\n TablaMouseClicked(evt);\n }\n });\n jScrollPane1.setViewportView(Tabla);\n\n javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);\n jPanel1.setLayout(jPanel1Layout);\n jPanel1Layout.setHorizontalGroup(\n jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel1Layout.createSequentialGroup()\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 445, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(14, 14, 14))\n );\n jPanel1Layout.setVerticalGroup(\n jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addGap(36, 36, 36)\n .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 118, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n );\n\n jSeparator1.setOrientation(javax.swing.SwingConstants.VERTICAL);\n\n jLabel5.setText(\"Titulo:\");\n\n jLabel6.setText(\"Categoria:\");\n\n jLabel7.setText(\"Autor:\");\n\n jLabel8.setText(\"Editorial:\");\n\n jLabel9.setText(\"Año:\");\n\n autor.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n autorActionPerformed(evt);\n }\n });\n\n jLabel4.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/Imagenes/refresh.png\"))); // NOI18N\n\n javax.swing.GroupLayout jPanel2Layout = new javax.swing.GroupLayout(jPanel2);\n jPanel2.setLayout(jPanel2Layout);\n jPanel2Layout.setHorizontalGroup(\n jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel2Layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jLabel6)\n .addComponent(jLabel9)\n .addComponent(jLabel5))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)\n .addComponent(cat, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, 126, Short.MAX_VALUE)\n .addComponent(titulo)\n .addComponent(an))\n .addGap(18, 18, 18)\n .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)\n .addComponent(jLabel7, javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jLabel8, javax.swing.GroupLayout.Alignment.LEADING))\n .addGap(10, 10, 10)\n .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(Editorial, javax.swing.GroupLayout.PREFERRED_SIZE, 127, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(autor, javax.swing.GroupLayout.PREFERRED_SIZE, 127, javax.swing.GroupLayout.PREFERRED_SIZE)))\n .addGroup(jPanel2Layout.createSequentialGroup()\n .addGap(143, 143, 143)\n .addComponent(jLabel4)\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n );\n jPanel2Layout.setVerticalGroup(\n jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel2Layout.createSequentialGroup()\n .addContainerGap()\n .addComponent(jLabel4)\n .addGap(13, 13, 13)\n .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(Editorial, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(titulo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jLabel5)\n .addComponent(jLabel8)))\n .addGap(18, 18, 18)\n .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel6)\n .addComponent(cat, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel7)\n .addComponent(autor, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))\n .addGap(18, 18, 18)\n .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jLabel9)\n .addComponent(an, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGap(0, 27, Short.MAX_VALUE))\n );\n\n guardar.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/Imagenes/Metro-Save-Blue-256.png\"))); // NOI18N\n guardar.addMouseListener(new java.awt.event.MouseAdapter() {\n public void mouseClicked(java.awt.event.MouseEvent evt) {\n guardarMouseClicked(evt);\n }\n });\n\n jLabel2.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/Imagenes/clean-android-limpiar-logo.png\"))); // NOI18N\n jLabel2.addMouseListener(new java.awt.event.MouseAdapter() {\n public void mouseClicked(java.awt.event.MouseEvent evt) {\n jLabel2MouseClicked(evt);\n }\n });\n\n salir.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/Imagenes/close-150192_960_720.png\"))); // NOI18N\n salir.addMouseListener(new java.awt.event.MouseAdapter() {\n public void mouseClicked(java.awt.event.MouseEvent evt) {\n salirMouseClicked(evt);\n }\n });\n\n Actualizar.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/Imagenes/1485969921-5-refresh_78908.png\"))); // NOI18N\n Actualizar.addMouseListener(new java.awt.event.MouseAdapter() {\n public void mouseClicked(java.awt.event.MouseEvent evt) {\n ActualizarMouseClicked(evt);\n }\n });\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());\n getContentPane().setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jSeparator3)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()\n .addGap(0, 0, Short.MAX_VALUE)\n .addComponent(guardar)\n .addGap(26, 26, 26)\n .addComponent(Actualizar)\n .addGap(18, 18, 18)\n .addComponent(jLabel2)\n .addGap(18, 18, 18)\n .addComponent(salir))\n .addGroup(layout.createSequentialGroup()\n .addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, 454, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(jSeparator1, javax.swing.GroupLayout.PREFERRED_SIZE, 11, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(jPanel2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(0, 0, Short.MAX_VALUE)))\n .addContainerGap())\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)\n .addComponent(jSeparator1, javax.swing.GroupLayout.PREFERRED_SIZE, 284, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)\n .addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(jPanel2, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addComponent(jSeparator3, javax.swing.GroupLayout.PREFERRED_SIZE, 10, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jLabel2)\n .addComponent(guardar)\n .addComponent(salir))\n .addComponent(Actualizar))\n .addGap(12, 12, 12))\n );\n\n pack();\n }", "private JTable getTablePacientes() {\n\t\t\n\t\t try {\n\t \t ConnectDatabase db = new ConnectDatabase();\n\t\t\t\tResultSet rs = db.sqlstatment().executeQuery(\"SELECT * FROM PACIENTE WHERE NOMBRE LIKE '%\"+nombre.getText()+\"%' AND APELLIDO LIKE '%\"+apellido.getText()+\"%'AND DNI LIKE '%\"+dni.getText()+\"%'\");\n\t\t\t\tObject[] transf = QueryToTable.getSingle().queryToTable(rs);\n\t\t\t\treturn table = new JTable(new DefaultTableModel((Vector<Vector<Object>>)transf[0], (Vector<String>)transf[1]));\t\t\n\t\t\t} catch(Exception e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t\treturn table;\n\t}", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">\n private void initComponents() {\n\n jPanel6 = new javax.swing.JPanel();\n jPanel1 = new javax.swing.JPanel();\n jPanel5 = new javax.swing.JPanel();\n jTabbedPane1 = new javax.swing.JTabbedPane();\n jPanel2 = new javax.swing.JPanel();\n jLabel1 = new javax.swing.JLabel();\n custCombo = new javax.swing.JComboBox<>();\n jLabel2 = new javax.swing.JLabel();\n vehCombo = new javax.swing.JComboBox<>();\n jScrollPane3 = new javax.swing.JScrollPane();\n jPanel7 = new javax.swing.JPanel();\n jLabel13 = new javax.swing.JLabel();\n jScrollPane1 = new javax.swing.JScrollPane();\n custTable = new javax.swing.JTable();\n returnBtn = new javax.swing.JButton();\n jLabel3 = new javax.swing.JLabel();\n jScrollPane2 = new javax.swing.JScrollPane();\n vehTable = new javax.swing.JTable();\n rentBtn = new javax.swing.JButton();\n vehReturnDate = new com.toedter.calendar.JDateChooser();\n reportLabel = new javax.swing.JLabel();\n jLabel17 = new javax.swing.JLabel();\n jScrollPane4 = new javax.swing.JScrollPane();\n rentTable = new javax.swing.JTable();\n histBtn = new javax.swing.JButton();\n dispAllBtn = new javax.swing.JButton();\n jScrollPane5 = new javax.swing.JScrollPane();\n sortTable = new javax.swing.JTable();\n sortVehBtn = new javax.swing.JButton();\n sortCustBtn = new javax.swing.JButton();\n jLabel14 = new javax.swing.JLabel();\n jPanel3 = new javax.swing.JPanel();\n jLabel4 = new javax.swing.JLabel();\n jLabel6 = new javax.swing.JLabel();\n jSeparator2 = new javax.swing.JSeparator();\n jLabel7 = new javax.swing.JLabel();\n jLabel8 = new javax.swing.JLabel();\n jLabel9 = new javax.swing.JLabel();\n snameTxt = new javax.swing.JTextField();\n nameTxt = new javax.swing.JTextField();\n idTxt = new javax.swing.JTextField();\n phoneTxt = new javax.swing.JTextField();\n saveBtn = new javax.swing.JButton();\n clearBtn = new javax.swing.JButton();\n jPanel4 = new javax.swing.JPanel();\n jLabel5 = new javax.swing.JLabel();\n jSeparator3 = new javax.swing.JSeparator();\n jLabel10 = new javax.swing.JLabel();\n modelTxt = new javax.swing.JTextField();\n jLabel11 = new javax.swing.JLabel();\n jLabel12 = new javax.swing.JLabel();\n rentTxt = new javax.swing.JTextField();\n saveBtn1 = new javax.swing.JButton();\n clearBtn1 = new javax.swing.JButton();\n catCombo = new javax.swing.JComboBox<>();\n jLabel15 = new javax.swing.JLabel();\n closeLabel = new javax.swing.JLabel();\n minimazeLabel = new javax.swing.JLabel();\n jPanel8 = new javax.swing.JPanel();\n\n setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);\n setUndecorated(true);\n\n jPanel6.setBackground(new java.awt.Color(153, 0, 153));\n\n jPanel1.setBackground(new java.awt.Color(255, 255, 255));\n\n jPanel5.setBackground(new java.awt.Color(102, 102, 102));\n\n jTabbedPane1.setBackground(new java.awt.Color(102, 102, 102));\n jTabbedPane1.setFont(new java.awt.Font(\"SansSerif\", 1, 14)); // NOI18N\n\n jPanel2.setLayout(null);\n\n jLabel1.setFont(new java.awt.Font(\"SansSerif\", 1, 14)); // NOI18N\n jLabel1.setForeground(new java.awt.Color(255, 255, 255));\n jLabel1.setText(\"Choose Existing Customer:\");\n jPanel2.add(jLabel1);\n jLabel1.setBounds(115, 40, 190, 31);\n\n custCombo.setFont(new java.awt.Font(\"SansSerif\", 0, 12)); // NOI18N\n custCombo.setModel(new javax.swing.DefaultComboBoxModel<>(new String[] { \"Select name...\" }));\n custCombo.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n custComboActionPerformed(evt);\n }\n });\n jPanel2.add(custCombo);\n custCombo.setBounds(115, 89, 190, 31);\n\n jLabel2.setFont(new java.awt.Font(\"SansSerif\", 1, 14)); // NOI18N\n jLabel2.setForeground(new java.awt.Color(255, 255, 255));\n jLabel2.setText(\"Choose Vehicle Catagory:\");\n jPanel2.add(jLabel2);\n jLabel2.setBounds(531, 40, 189, 31);\n\n vehCombo.setFont(new java.awt.Font(\"SansSerif\", 0, 12)); // NOI18N\n vehCombo.setModel(new javax.swing.DefaultComboBoxModel<>(new String[] { \"Select catagory...\", \"Luxury Sedans\", \"Luxury SUV's\" }));\n vehCombo.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n vehComboActionPerformed(evt);\n }\n });\n jPanel2.add(vehCombo);\n vehCombo.setBounds(531, 89, 189, 31);\n\n jScrollPane3.setHorizontalScrollBarPolicy(javax.swing.ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER);\n\n jPanel7.setBackground(new java.awt.Color(102, 102, 102));\n\n jLabel13.setFont(new java.awt.Font(\"SansSerif\", 1, 14)); // NOI18N\n jLabel13.setForeground(new java.awt.Color(255, 255, 255));\n jLabel13.setText(\"Vehicle Rented by Customer:\");\n\n custTable.setFont(new java.awt.Font(\"SansSerif\", 0, 12)); // NOI18N\n custTable.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n\n },\n new String [] {\n \"Rental Number\", \"Date of Rent\", \"Return Date\", \"Total Price\"\n }\n ) {\n boolean[] canEdit = new boolean [] {\n false, false, false, false\n };\n\n public boolean isCellEditable(int rowIndex, int columnIndex) {\n return canEdit [columnIndex];\n }\n });\n jScrollPane1.setViewportView(custTable);\n if (custTable.getColumnModel().getColumnCount() > 0) {\n custTable.getColumnModel().getColumn(0).setResizable(false);\n custTable.getColumnModel().getColumn(1).setResizable(false);\n custTable.getColumnModel().getColumn(2).setResizable(false);\n custTable.getColumnModel().getColumn(3).setResizable(false);\n }\n\n returnBtn.setFont(new java.awt.Font(\"SansSerif\", 0, 12)); // NOI18N\n returnBtn.setText(\"Return\");\n returnBtn.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));\n returnBtn.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n returnBtnActionPerformed(evt);\n }\n });\n\n jLabel3.setFont(new java.awt.Font(\"SansSerif\", 1, 14)); // NOI18N\n jLabel3.setForeground(new java.awt.Color(255, 255, 255));\n jLabel3.setText(\"Return Date:\");\n\n vehTable.setFont(new java.awt.Font(\"SansSerif\", 0, 12)); // NOI18N\n vehTable.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n\n },\n new String [] {\n \"Module\", \"Catagory\", \"Rental Price\", \"Available\"\n }\n ) {\n boolean[] canEdit = new boolean [] {\n false, false, false, false\n };\n\n public boolean isCellEditable(int rowIndex, int columnIndex) {\n return canEdit [columnIndex];\n }\n });\n jScrollPane2.setViewportView(vehTable);\n if (vehTable.getColumnModel().getColumnCount() > 0) {\n vehTable.getColumnModel().getColumn(0).setResizable(false);\n vehTable.getColumnModel().getColumn(1).setResizable(false);\n vehTable.getColumnModel().getColumn(2).setResizable(false);\n vehTable.getColumnModel().getColumn(3).setResizable(false);\n }\n\n rentBtn.setFont(new java.awt.Font(\"SansSerif\", 0, 12)); // NOI18N\n rentBtn.setText(\"Rent\");\n rentBtn.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));\n rentBtn.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n rentBtnActionPerformed(evt);\n }\n });\n\n vehReturnDate.setToolTipText(\"select return date\");\n vehReturnDate.setFont(new java.awt.Font(\"SansSerif\", 0, 14)); // NOI18N\n vehReturnDate.setMinSelectableDate(new java.util.Date(-62135773128000L));\n\n reportLabel.setFont(new java.awt.Font(\"SansSerif\", 1, 14)); // NOI18N\n reportLabel.setForeground(new java.awt.Color(255, 255, 255));\n reportLabel.setText(\"Display Rentals:\");\n\n jLabel17.setFont(new java.awt.Font(\"SansSerif\", 1, 14)); // NOI18N\n jLabel17.setForeground(new java.awt.Color(255, 255, 255));\n jLabel17.setText(\"List & Sort All:\");\n\n rentTable.setFont(new java.awt.Font(\"SansSerif\", 0, 12)); // NOI18N\n rentTable.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n\n },\n new String [] {\n \"Rental Number\", \"Date of Rent\", \"Return Date\", \"Total Price\"\n }\n ) {\n boolean[] canEdit = new boolean [] {\n false, false, false, false\n };\n\n public boolean isCellEditable(int rowIndex, int columnIndex) {\n return canEdit [columnIndex];\n }\n });\n jScrollPane4.setViewportView(rentTable);\n if (rentTable.getColumnModel().getColumnCount() > 0) {\n rentTable.getColumnModel().getColumn(0).setResizable(false);\n rentTable.getColumnModel().getColumn(1).setResizable(false);\n rentTable.getColumnModel().getColumn(2).setResizable(false);\n rentTable.getColumnModel().getColumn(3).setResizable(false);\n }\n\n histBtn.setFont(new java.awt.Font(\"SansSerif\", 0, 12)); // NOI18N\n histBtn.setText(\"History\");\n histBtn.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));\n histBtn.setMaximumSize(new java.awt.Dimension(99, 25));\n histBtn.setMinimumSize(new java.awt.Dimension(99, 25));\n histBtn.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n histBtnActionPerformed(evt);\n }\n });\n\n dispAllBtn.setFont(new java.awt.Font(\"SansSerif\", 0, 12)); // NOI18N\n dispAllBtn.setText(\"Outstanding\");\n dispAllBtn.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));\n dispAllBtn.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n dispAllBtnActionPerformed(evt);\n }\n });\n\n sortTable.setFont(new java.awt.Font(\"SansSerif\", 0, 12)); // NOI18N\n sortTable.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n\n },\n new String [] {\n \"Module\", \"Catagory\", \"Rental Price\", \"Available\"\n }\n ) {\n boolean[] canEdit = new boolean [] {\n false, false, false, false\n };\n\n public boolean isCellEditable(int rowIndex, int columnIndex) {\n return canEdit [columnIndex];\n }\n });\n jScrollPane5.setViewportView(sortTable);\n if (sortTable.getColumnModel().getColumnCount() > 0) {\n sortTable.getColumnModel().getColumn(0).setResizable(false);\n sortTable.getColumnModel().getColumn(1).setResizable(false);\n sortTable.getColumnModel().getColumn(2).setResizable(false);\n sortTable.getColumnModel().getColumn(3).setResizable(false);\n }\n\n sortVehBtn.setFont(new java.awt.Font(\"SansSerif\", 0, 12)); // NOI18N\n sortVehBtn.setText(\"Vehicles\");\n sortVehBtn.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));\n sortVehBtn.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n sortVehBtnActionPerformed(evt);\n }\n });\n\n sortCustBtn.setFont(new java.awt.Font(\"SansSerif\", 0, 12)); // NOI18N\n sortCustBtn.setText(\"Customers\");\n sortCustBtn.setToolTipText(\"Show All Customers Sorted\");\n sortCustBtn.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));\n sortCustBtn.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n sortCustBtnActionPerformed(evt);\n }\n });\n\n javax.swing.GroupLayout jPanel7Layout = new javax.swing.GroupLayout(jPanel7);\n jPanel7.setLayout(jPanel7Layout);\n jPanel7Layout.setHorizontalGroup(\n jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel7Layout.createSequentialGroup()\n .addGap(177, 177, 177)\n .addComponent(returnBtn)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(rentBtn, javax.swing.GroupLayout.PREFERRED_SIZE, 70, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(188, 188, 188))\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel7Layout.createSequentialGroup()\n .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel7Layout.createSequentialGroup()\n .addGap(25, 25, 25)\n .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 363, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jLabel13)\n .addComponent(reportLabel)\n .addComponent(jScrollPane4, javax.swing.GroupLayout.PREFERRED_SIZE, 363, javax.swing.GroupLayout.PREFERRED_SIZE)))\n .addGroup(jPanel7Layout.createSequentialGroup()\n .addGap(68, 68, 68)\n .addComponent(histBtn, javax.swing.GroupLayout.PREFERRED_SIZE, 83, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(100, 100, 100)\n .addComponent(dispAllBtn)))\n .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel7Layout.createSequentialGroup()\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 68, Short.MAX_VALUE)\n .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)\n .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 351, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGroup(jPanel7Layout.createSequentialGroup()\n .addComponent(jLabel3, javax.swing.GroupLayout.PREFERRED_SIZE, 137, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(vehReturnDate, javax.swing.GroupLayout.PREFERRED_SIZE, 165, javax.swing.GroupLayout.PREFERRED_SIZE)))\n .addComponent(jLabel17, javax.swing.GroupLayout.PREFERRED_SIZE, 105, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jScrollPane5, javax.swing.GroupLayout.PREFERRED_SIZE, 351, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGap(52, 52, 52))\n .addGroup(jPanel7Layout.createSequentialGroup()\n .addGap(98, 98, 98)\n .addComponent(sortVehBtn)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(sortCustBtn)\n .addGap(86, 86, 86))))\n );\n jPanel7Layout.setVerticalGroup(\n jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel7Layout.createSequentialGroup()\n .addGap(39, 39, 39)\n .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)\n .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel3, javax.swing.GroupLayout.PREFERRED_SIZE, 31, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jLabel13, javax.swing.GroupLayout.PREFERRED_SIZE, 31, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addComponent(vehReturnDate, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n .addGap(18, 18, 18)\n .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 159, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 159, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGap(18, 18, 18)\n .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(returnBtn)\n .addComponent(rentBtn))\n .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel7Layout.createSequentialGroup()\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(sortVehBtn)\n .addGap(55, 55, 55))\n .addGroup(jPanel7Layout.createSequentialGroup()\n .addGap(43, 43, 43)\n .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(reportLabel, javax.swing.GroupLayout.PREFERRED_SIZE, 31, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jLabel17, javax.swing.GroupLayout.PREFERRED_SIZE, 31, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel7Layout.createSequentialGroup()\n .addGap(18, 18, 18)\n .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jScrollPane4, javax.swing.GroupLayout.PREFERRED_SIZE, 159, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jScrollPane5, javax.swing.GroupLayout.PREFERRED_SIZE, 159, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGap(18, 18, 18)\n .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(histBtn, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(dispAllBtn))\n .addContainerGap(55, Short.MAX_VALUE))\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel7Layout.createSequentialGroup()\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(sortCustBtn)\n .addGap(54, 54, 54))))))\n );\n\n jScrollPane3.setViewportView(jPanel7);\n\n jPanel2.add(jScrollPane3);\n jScrollPane3.setBounds(0, 126, 835, 331);\n\n jLabel14.setIcon(new ImageIcon(\"2.jpg\")); // NOI18N\n jPanel2.add(jLabel14);\n jLabel14.setBounds(0, 0, 835, 485);\n\n jTabbedPane1.addTab(\" Rent Vehicle \", new ImageIcon(\"favicon2.jpg\"), jPanel2); // NOI18N\n\n jPanel3.setBackground(new java.awt.Color(102, 102, 102));\n\n jLabel4.setBackground(new java.awt.Color(255, 255, 255));\n jLabel4.setFont(new java.awt.Font(\"SansSerif\", 1, 16)); // NOI18N\n jLabel4.setForeground(new java.awt.Color(255, 255, 255));\n jLabel4.setText(\"Create Customer:\");\n\n jLabel6.setBackground(new java.awt.Color(255, 255, 255));\n jLabel6.setFont(new java.awt.Font(\"SansSerif\", 1, 15)); // NOI18N\n jLabel6.setForeground(new java.awt.Color(255, 255, 255));\n jLabel6.setText(\"Name:\");\n\n jLabel7.setBackground(new java.awt.Color(255, 255, 255));\n jLabel7.setFont(new java.awt.Font(\"SansSerif\", 1, 15)); // NOI18N\n jLabel7.setForeground(new java.awt.Color(255, 255, 255));\n jLabel7.setText(\"Surname:\");\n\n jLabel8.setBackground(new java.awt.Color(255, 255, 255));\n jLabel8.setFont(new java.awt.Font(\"SansSerif\", 1, 15)); // NOI18N\n jLabel8.setForeground(new java.awt.Color(255, 255, 255));\n jLabel8.setText(\"I.D Number:\");\n\n jLabel9.setBackground(new java.awt.Color(255, 255, 255));\n jLabel9.setFont(new java.awt.Font(\"SansSerif\", 1, 15)); // NOI18N\n jLabel9.setForeground(new java.awt.Color(255, 255, 255));\n jLabel9.setText(\"Phone Number:\");\n\n snameTxt.setFont(new java.awt.Font(\"SansSerif\", 0, 14)); // NOI18N\n\n nameTxt.setFont(new java.awt.Font(\"SansSerif\", 0, 14)); // NOI18N\n\n idTxt.setFont(new java.awt.Font(\"SansSerif\", 0, 14)); // NOI18N\n idTxt.addKeyListener(new java.awt.event.KeyAdapter() {\n public void keyTyped(java.awt.event.KeyEvent evt) {\n idTxtKeyTyped(evt);\n }\n });\n\n phoneTxt.setFont(new java.awt.Font(\"SansSerif\", 0, 14)); // NOI18N\n phoneTxt.addKeyListener(new java.awt.event.KeyAdapter() {\n public void keyTyped(java.awt.event.KeyEvent evt) {\n phoneTxtKeyTyped(evt);\n }\n });\n\n saveBtn.setFont(new java.awt.Font(\"SansSerif\", 0, 12)); // NOI18N\n saveBtn.setText(\"Save\");\n saveBtn.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n saveBtnActionPerformed(evt);\n }\n });\n\n clearBtn.setFont(new java.awt.Font(\"SansSerif\", 0, 12)); // NOI18N\n clearBtn.setText(\"Clear\");\n clearBtn.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n clearBtnActionPerformed(evt);\n }\n });\n\n javax.swing.GroupLayout jPanel3Layout = new javax.swing.GroupLayout(jPanel3);\n jPanel3.setLayout(jPanel3Layout);\n jPanel3Layout.setHorizontalGroup(\n jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel3Layout.createSequentialGroup()\n .addComponent(jSeparator2, javax.swing.GroupLayout.PREFERRED_SIZE, 835, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(0, 0, Short.MAX_VALUE))\n .addGroup(jPanel3Layout.createSequentialGroup()\n .addGap(76, 76, 76)\n .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel3Layout.createSequentialGroup()\n .addComponent(clearBtn, javax.swing.GroupLayout.PREFERRED_SIZE, 74, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(saveBtn, javax.swing.GroupLayout.PREFERRED_SIZE, 74, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(81, 81, 81))\n .addGroup(jPanel3Layout.createSequentialGroup()\n .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jLabel4)\n .addGroup(jPanel3Layout.createSequentialGroup()\n .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jLabel6)\n .addComponent(jLabel7)\n .addComponent(jLabel8)\n .addComponent(jLabel9))\n .addGap(153, 153, 153)\n .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(phoneTxt, javax.swing.GroupLayout.PREFERRED_SIZE, 237, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(idTxt, javax.swing.GroupLayout.PREFERRED_SIZE, 237, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(snameTxt, javax.swing.GroupLayout.PREFERRED_SIZE, 237, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(nameTxt, javax.swing.GroupLayout.PREFERRED_SIZE, 237, javax.swing.GroupLayout.PREFERRED_SIZE))))\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))))\n );\n jPanel3Layout.setVerticalGroup(\n jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel3Layout.createSequentialGroup()\n .addGap(40, 40, 40)\n .addComponent(jLabel4, javax.swing.GroupLayout.PREFERRED_SIZE, 31, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(7, 7, 7)\n .addComponent(jSeparator2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(43, 43, 43)\n .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel6)\n .addComponent(nameTxt, javax.swing.GroupLayout.PREFERRED_SIZE, 35, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGap(30, 30, 30)\n .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel7)\n .addComponent(snameTxt, javax.swing.GroupLayout.PREFERRED_SIZE, 37, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGap(30, 30, 30)\n .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(idTxt, javax.swing.GroupLayout.PREFERRED_SIZE, 37, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jLabel8))\n .addGap(30, 30, 30)\n .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(phoneTxt, javax.swing.GroupLayout.PREFERRED_SIZE, 37, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jLabel9))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 63, Short.MAX_VALUE)\n .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(saveBtn)\n .addComponent(clearBtn))\n .addGap(34, 34, 34))\n );\n\n jTabbedPane1.addTab(\" Add New Customer \", new ImageIcon(\"/favicon3.png\"), jPanel3); // NOI18N\n\n jPanel4.setLayout(null);\n\n jLabel5.setFont(new java.awt.Font(\"SansSerif\", 1, 16)); // NOI18N\n jLabel5.setForeground(new java.awt.Color(255, 255, 255));\n jLabel5.setText(\"Create Vehicle:\");\n jPanel4.add(jLabel5);\n jLabel5.setBounds(76, 40, 131, 31);\n jPanel4.add(jSeparator3);\n jSeparator3.setBounds(0, 77, 835, 2);\n\n jLabel10.setFont(new java.awt.Font(\"SansSerif\", 1, 14)); // NOI18N\n jLabel10.setForeground(new java.awt.Color(255, 255, 255));\n jLabel10.setText(\"Model:\");\n jPanel4.add(jLabel10);\n jLabel10.setBounds(75, 131, 55, 35);\n\n modelTxt.setFont(new java.awt.Font(\"SansSerif\", 0, 14)); // NOI18N\n jPanel4.add(modelTxt);\n modelTxt.setBounds(330, 132, 237, 30);\n\n jLabel11.setFont(new java.awt.Font(\"SansSerif\", 1, 14)); // NOI18N\n jLabel11.setForeground(new java.awt.Color(255, 255, 255));\n jLabel11.setText(\"Category:\");\n jPanel4.add(jLabel11);\n jLabel11.setBounds(75, 197, 67, 37);\n\n jLabel12.setFont(new java.awt.Font(\"SansSerif\", 1, 14)); // NOI18N\n jLabel12.setForeground(new java.awt.Color(255, 255, 255));\n jLabel12.setText(\"Rental Price:\");\n jPanel4.add(jLabel12);\n jLabel12.setBounds(75, 266, 89, 37);\n\n rentTxt.setEditable(false);\n rentTxt.setFont(new java.awt.Font(\"SansSerif\", 0, 14)); // NOI18N\n jPanel4.add(rentTxt);\n rentTxt.setBounds(330, 266, 130, 30);\n\n saveBtn1.setFont(new java.awt.Font(\"SansSerif\", 0, 12)); // NOI18N\n saveBtn1.setText(\"Save\");\n saveBtn1.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n saveBtn1ActionPerformed(evt);\n }\n });\n jPanel4.add(saveBtn1);\n saveBtn1.setBounds(679, 422, 74, 25);\n\n clearBtn1.setFont(new java.awt.Font(\"SansSerif\", 0, 12)); // NOI18N\n clearBtn1.setText(\"Clear\");\n clearBtn1.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n clearBtn1ActionPerformed(evt);\n }\n });\n jPanel4.add(clearBtn1);\n clearBtn1.setBounds(75, 422, 74, 25);\n\n catCombo.setBackground(new java.awt.Color(102, 102, 102));\n catCombo.setFont(new java.awt.Font(\"SansSerif\", 0, 12)); // NOI18N\n catCombo.setForeground(new java.awt.Color(153, 153, 153));\n catCombo.setModel(new javax.swing.DefaultComboBoxModel<>(new String[] { \"Select category...\", \"Sedan\", \"SUV\" }));\n catCombo.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n catComboActionPerformed(evt);\n }\n });\n jPanel4.add(catCombo);\n catCombo.setBounds(330, 200, 130, 30);\n\n jLabel15.setIcon(new ImageIcon(\"1.jpg\")); // NOI18N\n jPanel4.add(jLabel15);\n jLabel15.setBounds(0, 0, 835, 485);\n\n jTabbedPane1.addTab(\" Add New Vehicle \", new ImageIcon(\"favicon.jpg\"), jPanel4); // NOI18N\n\n javax.swing.GroupLayout jPanel5Layout = new javax.swing.GroupLayout(jPanel5);\n jPanel5.setLayout(jPanel5Layout);\n jPanel5Layout.setHorizontalGroup(\n jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jTabbedPane1)\n );\n jPanel5Layout.setVerticalGroup(\n jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jTabbedPane1)\n );\n\n closeLabel.setFont(new java.awt.Font(\"SansSerif\", 1, 16)); // NOI18N\n closeLabel.setText(\" X \");\n closeLabel.setToolTipText(\"Exit\");\n closeLabel.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));\n closeLabel.addMouseListener(new java.awt.event.MouseAdapter() {\n public void mouseClicked(java.awt.event.MouseEvent evt) {\n closeLabelMouseClicked(evt);\n }\n public void mouseEntered(java.awt.event.MouseEvent evt) {\n closeLabelMouseEntered(evt);\n }\n public void mouseExited(java.awt.event.MouseEvent evt) {\n closeLabelMouseExited(evt);\n }\n });\n\n minimazeLabel.setFont(new java.awt.Font(\"SansSerif\", 1, 25)); // NOI18N\n minimazeLabel.setText(\" - \");\n minimazeLabel.setToolTipText(\"minimaze\");\n minimazeLabel.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));\n minimazeLabel.addMouseListener(new java.awt.event.MouseAdapter() {\n public void mouseClicked(java.awt.event.MouseEvent evt) {\n minimazeLabelMouseClicked(evt);\n }\n public void mouseEntered(java.awt.event.MouseEvent evt) {\n minimazeLabelMouseEntered(evt);\n }\n public void mouseExited(java.awt.event.MouseEvent evt) {\n minimazeLabelMouseExited(evt);\n }\n });\n\n jPanel8.setBackground(new java.awt.Color(102, 102, 102));\n\n javax.swing.GroupLayout jPanel8Layout = new javax.swing.GroupLayout(jPanel8);\n jPanel8.setLayout(jPanel8Layout);\n jPanel8Layout.setHorizontalGroup(\n jPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 0, Short.MAX_VALUE)\n );\n jPanel8Layout.setVerticalGroup(\n jPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 50, Short.MAX_VALUE)\n );\n\n javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);\n jPanel1.setLayout(jPanel1Layout);\n jPanel1Layout.setHorizontalGroup(\n jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jPanel5, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel1Layout.createSequentialGroup()\n .addContainerGap()\n .addComponent(minimazeLabel)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(closeLabel)\n .addContainerGap())\n .addComponent(jPanel8, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n );\n jPanel1Layout.setVerticalGroup(\n jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(closeLabel)\n .addComponent(minimazeLabel, javax.swing.GroupLayout.PREFERRED_SIZE, 23, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGap(0, 0, 0)\n .addComponent(jPanel8, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(0, 0, 0)\n .addComponent(jPanel5, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n );\n\n javax.swing.GroupLayout jPanel6Layout = new javax.swing.GroupLayout(jPanel6);\n jPanel6.setLayout(jPanel6Layout);\n jPanel6Layout.setHorizontalGroup(\n jPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel6Layout.createSequentialGroup()\n .addContainerGap()\n .addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addContainerGap())\n );\n jPanel6Layout.setVerticalGroup(\n jPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel6Layout.createSequentialGroup()\n .addContainerGap()\n .addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addContainerGap())\n );\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());\n getContentPane().setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addGap(0, 0, 0)\n .addComponent(jPanel6, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(0, 0, 0))\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jPanel6, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n );\n\n pack();\n }", "private void Actualizar_Tabla() {\n String[] columNames = {\"iditem\", \"codigo\", \"descripcion\", \"p_vent\", \"p_comp\", \"cant\", \"fecha\"};\n dtPersona = db.Select_Item();\n // se colocan los datos en la tabla\n DefaultTableModel datos = new DefaultTableModel(dtPersona, columNames);\n jTable1.setModel(datos);\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">\n private void initComponents() {\n \tthis.setTitle(\"BOOKING\");\n \tfinal Object[][] data = new Object[100][8];\n final Object[] Colheads={\"regno\",\"type\",\"driver\",\"availibility\",\"Speed\",\"Startplace\",\"reading/day\",\"Maintenance\"};\n final DefaultTableModel model = new DefaultTableModel(data,Colheads);\n \n jScrollPane1 = new javax.swing.JScrollPane();\n jTable1 = new javax.swing.JTable(model);\n jButton1 = new javax.swing.JButton();\n jLabel1 = new javax.swing.JLabel();\n jTextField1 = new javax.swing.JTextField();\n\n setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);\n\n try{ \n \t System.out.println(\"success1\");\n \n \n System.out.println(\"jjjjjjjjjjjj\");\n Connection con=DriverManager.getConnection(\"jdbc:mysql://localhost:3306/cab_service\",\"root\",\"hamzah\"); \n if (con != null) {\n System.out.println(\"A database connection has been established!\");\n }\n \n System.out.println(\"success2\");\n Statement st= con.createStatement(); \n String s1=\"select * from taxi\"; \n System.out.println(\"success3\");\n ResultSet rs=st.executeQuery(s1); \n int N = model.getRowCount();\n while(N > 0){ model.removeRow(N-1); N--; }\n int i=0; \n \n while(rs.next()){ \n \tSystem.out.println(\"success9\");\n \t data[i][0]=rs.getInt(\"regno\");\n \tSystem.out.println(\"success7\");\n data[i][1]=rs.getString(\"Type\"); \n \n data[i][2]=rs.getString(\"Driver\"); \n \n data[i][3]=rs.getString(\"Availability\");\n System.out.println(\"hiiiiiiiii\");\n data[i][4]=rs.getInt(\"Speed\"); \n data[i][5]=rs.getString(\"Startplace\"); \n // data[i][6]=rs.getInt(\"Starty\"); \n data[i][6]=rs.getInt(\"readingperday\"); \n data[i][7]=rs.getString(\"maintinance_details\"); \n model.addRow(data[i]);\n i++;\n \n } \n \n \n rs.close(); \n st.close(); \n con.close(); \n }catch(Exception e){ \n\t System.out.println(\"success8\");\n } \n System.out.println(\"tableeeeee\");\n jScrollPane1.setViewportView(jTable1);\n\n jButton1.setFont(new java.awt.Font(\"Tahoma\", 1, 18)); // NOI18N\n jButton1.setForeground(new java.awt.Color(0, 0, 204));\n jButton1.setText(\"BOOK\");\n jButton1.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n \tif(jTextField1.getText()!=null){\n \ttry{ \n \t\t Connection con =DriverManager.getConnection(\"jdbc:mysql://localhost:3306/cab_service\",\"root\",\"hamzah\"); \n \t if (con != null) {\n \t System.out.println(\"A database connection has been established!\");\n \t }\n \t System.out.println(\"success1\");\n \t PreparedStatement statement=con.prepareStatement(\n \"INSERT INTO taxi WHERE regno = ?\");\n \t System.out.println(\"success4\");\n statement.setString(1, jTextField1.getText()); \n con = DriverManager.getConnection(\n \"jdbc:mysql://localhost:3306/cab_service\", \"root\",\n \"hamzah\");\n Statement st= con.createStatement(); \n String s1=\"UPDATE taxi SET Availability= REPLACE( Availability , 'available', 'busy' ) WHERE regno LIKE '\"+jTextField1.getText()+\"'\";\n \n st.executeUpdate(s1);\n // st.executeUpdate(s2);\n st.close();\n con.close();\n System.out.println(\"success6\");\n statement.setString(4, \"busy\");\n System.out.println(\"success5\");\n statement.executeUpdate();\n System.out.println(\"success2\");\n \t\n \t\n \t\n \t}\n \tcatch(Exception e){\n \t\te.getMessage();\n \t\t}\n \t jTextField1.setText(\"\");\n\n \tSystem.out.println(\"success3\");\n \t}\n \t jButton1ActionPerformed(evt);\n \t\n }\n });\n\n jLabel1.setText(\"Registration Number:\");\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());\n getContentPane().setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 592, Short.MAX_VALUE)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()\n .addContainerGap()\n .addComponent(jButton1, javax.swing.GroupLayout.PREFERRED_SIZE, 142, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(10, 10, 10))\n .addGroup(layout.createSequentialGroup()\n .addGap(52, 52, 52)\n .addComponent(jLabel1, javax.swing.GroupLayout.PREFERRED_SIZE, 158, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(jTextField1, javax.swing.GroupLayout.PREFERRED_SIZE, 191, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addContainerGap(287, Short.MAX_VALUE))\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 428, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(39, 39, 39)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel1, javax.swing.GroupLayout.PREFERRED_SIZE, 28, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jTextField1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGap(35, 35, 35)\n .addComponent(jButton1, javax.swing.GroupLayout.PREFERRED_SIZE, 36, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addContainerGap(19, Short.MAX_VALUE))\n );\n\n pack();\n }", "public void Tabla_Credito(int numero, String campo) {\r\n DefaultTableModel modelo = new DefaultTableModel();\r\n String[] cabeceras = new String[]{\"Cod_Venta\", \"Abonado\", \"Total\"};\r\n modelo.setColumnIdentifiers(cabeceras);\r\n switch (numero) {\r\n case 1:\r\n CadSql = \"SELECT c.cod_venta, c.abono, c.total FROM credito c, clientes cli WHERE cli.id=c.id_cliente AND cli.rut='\" + campo + \"';\";\r\n break;\r\n case 2:\r\n CadSql = \"SELECT c.cod_venta, c.abono, c.total FROM credito c, clientes cli WHERE cli.id=c.id_cliente AND cli.rut='\" + campo + \"';\";\r\n break;\r\n }\r\n try {\r\n String[] datos = new String[3];\r\n Statement st = this.cn.createStatement();\r\n ResultSet rs = st.executeQuery(CadSql);\r\n while (rs.next()) {\r\n datos[0] = rs.getString(1);\r\n datos[1] = rs.getString(2);\r\n datos[2] = rs.getString(3);\r\n modelo.addRow(datos);\r\n }\r\n if (numero == 1) {\r\n tbIngresoAbonos.setModel(modelo);\r\n } else if (numero == 2) {\r\n tblistadoclientescredito.setModel(modelo);\r\n }\r\n\r\n //if(numero==1){interfaz_venta_.tbventa.setModel(modelo);}else{interfaz_administracion.tblistado.setModel(modelo);}\r\n } catch (Exception ex) {\r\n //JOptionPane.showMessageDialog(null, ex);\r\n }\r\n }", "public DefaultTableModel getTablaFutbolistasPersonalizada(String nombre) {\n DefaultTableModel tablemodel = new DefaultTableModel();\n int registros = 0;\n String[] columNames = {\"Id\", \"NIF\", \"Nombre\", \"Apellidos\", \"Fecha nac.\", \"Nacionalidad\", \"Temporada\"};\n //obtenemos la cantidad de registros existentes en la tabla y se almacena en la variable \"registros\"\n //para formar la matriz de datos\n try {\n PreparedStatement pstm = this.getConnection().prepareStatement(\"SELECT count(*) as total FROM Futbolistas\");\n ResultSet res = pstm.executeQuery();\n res.next();\n registros = res.getInt(\"total\");\n close(res);\n } catch (SQLException e) {\n System.err.println(e.getMessage());\n }\n //se crea una matriz con tantas filas y columnas que necesite\n Object[][] data = new String[registros][8];\n try {\n //realizamos la llamada al procedimiento de la bd y llenamos los datos en la matriz \"Object[][] data\"\n PreparedStatement pstm = this.getConnection().prepareStatement(\"{call buscarJugadores(?)}\");\n pstm.setString(1, nombre);\n ResultSet res = pstm.executeQuery();\n int i = 0;\n while (res.next()) {\n data[i][0] = res.getString(\"id_futbolista\");\n data[i][1] = res.getString(\"nif\");\n data[i][2] = res.getString(\"nombre\");\n data[i][3] = res.getString(\"apellidos\");\n data[i][4] = res.getString(\"fecha_nacimiento\");\n data[i][5] = res.getString(\"nacionalidad\");\n data[i][6] = res.getString(\"temporada\");\n i++;\n }\n close(res);\n //se añade la matriz de datos en el DefaultTableModel\n tablemodel.setDataVector(data, columNames);\n } catch (SQLException e) {\n System.err.println(e.getMessage());\n }\n return tablemodel;\n }", "private void tablaConsultasMouseClicked(java.awt.event.MouseEvent evt) {\n datosconsulta = new DefaultTableModel();\n datosconsulta.addColumn(\"Cod Mascota\");\n datosconsulta.addColumn(\"Mascota\");\n datosconsulta.addColumn(\"Cod Enfermedad\");\n datosconsulta.addColumn(\"Enfermedad\");\n datosconsulta.addColumn(\"Diagnostico\");\n datosconsulta.addColumn(\"Notas\");\n datosconsulta.addColumn(\"Cod Vacuna\");\n datosconsulta.addColumn(\"Vacuna\");\n datosconsulta.addColumn(\"Aplicación\");\n datosconsulta.addColumn(\"Proxima\");\n tablaDatosDeconsulta.setModel(datosconsulta);\n cargarDatos();\n }", "private void loadTickets() {\n\t\topenTickets.clear();\n\t\tclosedTickets.clear();\n\t\tArrayList<Ticket> tickets = jdbc.getTickets();\n\t\t\n\t\tfor (Ticket t : tickets) {\n\t\t\tUser u = jdbc.get_user(t.submittedBy);\n\t\t\tString submittedBy = \"Submitted By: \"+u.get_lastname()+\", \"+u.get_firstname();\n\t\t\tString id = \"Ticket ID: \"+t.ticketID;\n\t\t\tString title = \"Title: \"+t.title;\n\t\t\tif (t.isDone) {\n\t\t\t\tString status = \"Status: Closed\";\n\t\t\t\tString s = String.format(\"%-40s%-40s%-40s%-40s\", id, title, submittedBy, status);\n\t\t\t\tclosedTickets.addElement(s);\n\t\t\t} else {\n\t\t\t\tString status = \"Status: Open\";\n\t\t\t\tString s = String.format(\"%-30s%-30s%-30s%-30s\", id, title, submittedBy, status);\n\t\t\t\topenTickets.addElement(s);\n\t\t\t}\n\t\t}\n\t}", "private void buscarProducto() {\n EntityManagerFactory emf= Persistence.createEntityManagerFactory(\"pintureriaPU\");\n List<Almacen> listaproducto= new FacadeAlmacen().buscarxnombre(jTextField1.getText().toUpperCase());\n DefaultTableModel modeloTabla=new DefaultTableModel();\n modeloTabla.addColumn(\"Id\");\n modeloTabla.addColumn(\"Producto\");\n modeloTabla.addColumn(\"Proveedor\");\n modeloTabla.addColumn(\"Precio\");\n modeloTabla.addColumn(\"Unidades Disponibles\");\n modeloTabla.addColumn(\"Localizacion\");\n \n \n for(int i=0; i<listaproducto.size(); i++){\n Vector vector=new Vector();\n vector.add(listaproducto.get(i).getId());\n vector.add(listaproducto.get(i).getProducto().getDescripcion());\n vector.add(listaproducto.get(i).getProducto().getProveedor().getNombre());\n vector.add(listaproducto.get(i).getProducto().getPrecio().getPrecio_contado());\n vector.add(listaproducto.get(i).getCantidad());\n vector.add(listaproducto.get(i).getLocalizacion());\n modeloTabla.addRow(vector);\n }\n jTable1.setModel(modeloTabla);\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n jTabbedPane1 = new javax.swing.JTabbedPane();\n jPanel1 = new javax.swing.JPanel();\n jLabel1 = new javax.swing.JLabel();\n cmbPiece = new javax.swing.JComboBox<>();\n cmbProvider = new javax.swing.JComboBox<>();\n jLabel2 = new javax.swing.JLabel();\n jLabel3 = new javax.swing.JLabel();\n txtQuantity = new javax.swing.JTextField();\n jLabel4 = new javax.swing.JLabel();\n jScrollPane1 = new javax.swing.JScrollPane();\n tblWarehouse = new javax.swing.JTable();\n btnSave = new javax.swing.JButton();\n lblDate = new javax.swing.JLabel();\n btnClear = new javax.swing.JButton();\n btnUpdate = new javax.swing.JButton();\n btnDelete = new javax.swing.JButton();\n jPanel2 = new javax.swing.JPanel();\n jPanel3 = new javax.swing.JPanel();\n jLabel6 = new javax.swing.JLabel();\n dtpFrom = new org.jdesktop.swingx.JXDatePicker();\n jLabel7 = new javax.swing.JLabel();\n jLabel5 = new javax.swing.JLabel();\n dtpTo = new org.jdesktop.swingx.JXDatePicker();\n btnReport = new javax.swing.JButton();\n\n setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);\n\n jLabel1.setText(\"Pieza:\");\n\n cmbPiece.setModel(new javax.swing.DefaultComboBoxModel<>(new String[] { \"Item 1\", \"Item 2\", \"Item 3\", \"Item 4\" }));\n\n cmbProvider.setModel(new javax.swing.DefaultComboBoxModel<>(new String[] { \"Item 1\", \"Item 2\", \"Item 3\", \"Item 4\" }));\n\n jLabel2.setText(\"Proveedor:\");\n\n jLabel3.setText(\"Cantidad:\");\n\n jLabel4.setText(\"Fecha de compra:\");\n\n tblWarehouse.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n {null, null, null, null, null},\n {null, null, null, null, null},\n {null, null, null, null, null},\n {null, null, null, null, null}\n },\n new String [] {\n \"Id\", \"Pieza\", \"Proveedor\", \"Cantidad\", \"Fecha de compra\"\n }\n ) {\n boolean[] canEdit = new boolean [] {\n false, false, false, false, false\n };\n\n public boolean isCellEditable(int rowIndex, int columnIndex) {\n return canEdit [columnIndex];\n }\n });\n tblWarehouse.addMouseListener(new java.awt.event.MouseAdapter() {\n public void mouseClicked(java.awt.event.MouseEvent evt) {\n tblWarehouseMouseClicked(evt);\n }\n });\n jScrollPane1.setViewportView(tblWarehouse);\n if (tblWarehouse.getColumnModel().getColumnCount() > 0) {\n tblWarehouse.getColumnModel().getColumn(0).setResizable(false);\n tblWarehouse.getColumnModel().getColumn(1).setResizable(false);\n tblWarehouse.getColumnModel().getColumn(2).setResizable(false);\n tblWarehouse.getColumnModel().getColumn(3).setResizable(false);\n tblWarehouse.getColumnModel().getColumn(4).setResizable(false);\n }\n\n btnSave.setText(\"Guardar\");\n btnSave.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btnSaveActionPerformed(evt);\n }\n });\n\n lblDate.setText(\"jLabel5\");\n\n btnClear.setText(\"Limpiar\");\n btnClear.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btnClearActionPerformed(evt);\n }\n });\n\n btnUpdate.setText(\"Modificar\");\n btnUpdate.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btnUpdateActionPerformed(evt);\n }\n });\n\n btnDelete.setText(\"Eliminar\");\n btnDelete.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btnDeleteActionPerformed(evt);\n }\n });\n\n javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);\n jPanel1.setLayout(jPanel1Layout);\n jPanel1Layout.setHorizontalGroup(\n jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)\n .addComponent(jLabel1)\n .addComponent(cmbPiece, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(jLabel2)\n .addComponent(cmbProvider, 0, 114, Short.MAX_VALUE)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addComponent(jLabel3)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addComponent(txtQuantity)))\n .addComponent(lblDate))\n .addGap(0, 0, Short.MAX_VALUE))\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel1Layout.createSequentialGroup()\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jLabel4)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)\n .addComponent(btnSave, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(btnUpdate, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)))\n .addGap(18, 18, 18)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(btnDelete, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(btnClear, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))))\n .addGap(18, 18, 18)\n .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 375, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addContainerGap())\n );\n jPanel1Layout.setVerticalGroup(\n jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 275, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addComponent(jLabel1)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(cmbPiece, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(jLabel2)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(cmbProvider, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel3)\n .addComponent(txtQuantity, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGap(10, 10, 10)\n .addComponent(jLabel4)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(lblDate)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(btnSave)\n .addComponent(btnClear))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(btnUpdate)\n .addComponent(btnDelete))))\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n );\n\n jTabbedPane1.addTab(\"Bodegas\", jPanel1);\n\n jPanel3.setBackground(new java.awt.Color(255, 255, 255));\n\n jLabel6.setText(\"Desde:\");\n\n dtpFrom.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n dtpFromActionPerformed(evt);\n }\n });\n\n jLabel7.setText(\"Hasta:\");\n\n jLabel5.setFont(new java.awt.Font(\"Tahoma\", 0, 18)); // NOI18N\n jLabel5.setText(\"Datos del reporte\");\n\n dtpTo.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n dtpToActionPerformed(evt);\n }\n });\n\n btnReport.setText(\"Imprimir\");\n btnReport.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btnReportActionPerformed(evt);\n }\n });\n\n javax.swing.GroupLayout jPanel3Layout = new javax.swing.GroupLayout(jPanel3);\n jPanel3.setLayout(jPanel3Layout);\n jPanel3Layout.setHorizontalGroup(\n jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel3Layout.createSequentialGroup()\n .addGap(20, 20, 20)\n .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)\n .addComponent(btnReport)\n .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel3Layout.createSequentialGroup()\n .addComponent(jLabel6)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addComponent(dtpFrom, javax.swing.GroupLayout.PREFERRED_SIZE, 141, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(43, 43, 43)\n .addComponent(jLabel7)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addComponent(dtpTo, javax.swing.GroupLayout.PREFERRED_SIZE, 140, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addComponent(jLabel5)))\n .addContainerGap(25, Short.MAX_VALUE))\n );\n jPanel3Layout.setVerticalGroup(\n jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel3Layout.createSequentialGroup()\n .addGap(5, 5, 5)\n .addComponent(jLabel5)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel6)\n .addComponent(dtpFrom, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jLabel7)\n .addComponent(dtpTo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addComponent(btnReport)\n .addGap(0, 13, Short.MAX_VALUE))\n );\n\n javax.swing.GroupLayout jPanel2Layout = new javax.swing.GroupLayout(jPanel2);\n jPanel2.setLayout(jPanel2Layout);\n jPanel2Layout.setHorizontalGroup(\n jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel2Layout.createSequentialGroup()\n .addGap(77, 77, 77)\n .addComponent(jPanel3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addContainerGap(86, Short.MAX_VALUE))\n );\n jPanel2Layout.setVerticalGroup(\n jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel2Layout.createSequentialGroup()\n .addGap(26, 26, 26)\n .addComponent(jPanel3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addContainerGap(164, Short.MAX_VALUE))\n );\n\n jTabbedPane1.addTab(\"Reportes\", jPanel2);\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());\n getContentPane().setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jTabbedPane1)\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jTabbedPane1)\n );\n\n pack();\n }", "private void agregarDatoATable() {\n\t\tString nombre = textNombre.getText();\n\t\tint deporte = (int)spinnerDeporte.getValue();\n\t\tint musica = (int)spinnerMusica.getValue();\n\t\tint espectaculo = (int)spinnerEspectaculo.getValue();\n\t\tint ciencia = (int)spinnerCiencia.getValue();\n\t\t\n\t\t//Reseteo los inputs para los proximos datos\n\t\ttextNombre.setText(\"\");\n\t\tspinnerDeporte.setValue(1);\n\t\tspinnerMusica.setValue(1);\n\t\tspinnerEspectaculo.setValue(1);\n\t\tspinnerCiencia.setValue(1);\n\t\t\n\t\t//Agrego todos los datos al array\n\t\tdatos.add(new Persona(nombre,deporte,musica,espectaculo,ciencia));\n\t\t\n\t\t//Agrego los datos a la JTable\n\t\tmodel.addRow(new String[]{ nombre, String.valueOf(deporte), String.valueOf(musica),\n\t\t\t\tString.valueOf(espectaculo), String.valueOf(ciencia) });\n\t\ttable.setModel(model);\n\t}", "private void setTableModel(List<SlotDto> slots){\n \n int size = 0;\n if(slots != null && !slots.isEmpty())\n size = slots.size();\n \n Object [][] slotsArr = new Object [25][9];\n\n // set days to table cells\n slotsArr[0][0] = \"Sunday\";\n slotsArr[5][0] = \"Monday\";\n slotsArr[10][0] = \"Tuesday\";\n slotsArr[15][0] = \"Wednesday\";\n slotsArr[20][0] = \"Thursday\";\n\n // loop for days' rows of schedule\n for(int r =0;r<5;r++){\n r=r*5;\n \n // loop for slots' columns of schedule \n for (int c=0 ; c<4 ; c++){ \n int cell=c*2;\n \n // loop to get slot of indexed day and time slot \n for( int i=0 ; i<size ; i++ ){\n if( (slots.get(i).getNum()== (c+1) && (slots.get(i).getDay().equals(slotsArr[r][0])) ) ){\n \n // set course name and code od slot \n slotsArr[r][cell+1] = slots.get(i).getCourse().getName();\n slotsArr[r][cell+2] = slots.get(i).getCourse().getCode();\n \n // set type of slot \n slotsArr[r+2][cell+1] = slots.get(i).getSlot_type();\n \n // set location of slot\n slotsArr[r+3][cell+1] = slots.get(i).getLocation().getName();\n \n \n // check slot type then set plt of slot\n if(slots.get(i).getSlot_type().equals(\"LECTURE\")){\n slotsArr[r+3][cell+2] = slots.get(i).getCourse().getPlt_lecture().getCode();\n System.out.println(\"plt\"+slots.get(i).getCourse().getPlt_lecture().getCode());\n }\n if(slots.get(i).getSlot_type().equals(\"SECTION\")){\n slotsArr[r+3][cell+2] = slots.get(i).getCourse().getPlt_lecture().getCode();\n System.out.println(\"plt\"+slots.get(i).getCourse().getPlt_lecture().getCode()); \n }\n \n // set student number of slot \n slotsArr[r+4][cell+1] = \"STUDENT NUMBER\";\n slotsArr[r+4][cell+2] = slots.get(i).getStudent_number();\n \n /*\n * set staff of slot then check if members > 1 then concatenate all members' names\n * and set to cell */\n String staff = slots.get(i).getStaff().get(0).getPosition() + \"/\" +\n slots.get(i).getStaff().get(0).getName() ;\n \n System.out.println(\"staff size\" + slots.get(i).getStaff().size()); \n System.out.println(\"user size\" + slots.get(i).getUser().size()); \n \n if(slots.get(i).getStaff().size()>1){\n for(int j=1 ; j<slots.get(i).getStaff().size() ; j++ ){\n staff=staff+\" # \" +slots.get(i).getStaff().get(j).getPosition()+\"/\"+\n slots.get(i).getStaff().get(j).getName() ; \n }\n }\n slotsArr[r+1][cell+1] = staff;\n \n /*\n * set user email of slot then check if users > 1 then concatenate all users' email \n * and set to cell */ \n String[] email = slots.get(i).getUser().get(0).getEmail().split(\"@\", 2);\n String user = email[0];\n if(slots.get(i).getUser().size()>1){\n for(int k=0 ; k<slots.get(i).getUser().size() ; k++){\n String[] _email = slots.get(i).getUser().get(k).getEmail().split(\"@\", 2);\n user = user +\" # \" + _email[0]; \n }\n }\n slotsArr[r+1][cell+2] = user;\n }\n }\n }\n }\n scheduleTable.setModel(new javax.swing.table.DefaultTableModel(slotsArr,\n new String [] {\n \"Time Slot\", \"First\",\" \", \"Second\", \" \" ,\"Third\",\" \",\"Fourth\",\" \"\n }\n ));\n\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n jLabel1 = new javax.swing.JLabel();\n consulta = new javax.swing.JButton();\n jTextField1 = new javax.swing.JTextField();\n jTextField2 = new javax.swing.JTextField();\n jTextField3 = new javax.swing.JTextField();\n jTextField4 = new javax.swing.JTextField();\n jTextField5 = new javax.swing.JTextField();\n jTextField6 = new javax.swing.JTextField();\n jLabel2 = new javax.swing.JLabel();\n jLabel3 = new javax.swing.JLabel();\n jLabel4 = new javax.swing.JLabel();\n jLabel5 = new javax.swing.JLabel();\n jLabel6 = new javax.swing.JLabel();\n jLabel7 = new javax.swing.JLabel();\n jSeparator1 = new javax.swing.JSeparator();\n jScrollPane1 = new javax.swing.JScrollPane();\n tareas = new javax.swing.JTable();\n jButton1 = new javax.swing.JButton();\n jButton2 = new javax.swing.JButton();\n jButton3 = new javax.swing.JButton();\n\n setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);\n setTitle(\"Actividades por evento\");\n\n jLabel1.setText(\"Actividades por evento\");\n\n consulta.setText(\"Ver actividad\");\n consulta.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n consultaActionPerformed(evt);\n }\n });\n\n jTextField1.setEditable(false);\n jTextField1.setAction(jButton1.getAction());\n jTextField1.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n jTextField1ActionPerformed(evt);\n }\n });\n\n jLabel2.setText(\"Numero de evento\");\n\n jLabel3.setText(\"Numero de cliente\");\n\n jLabel4.setText(\"Hora del evento\");\n\n jLabel5.setText(\"Tipo de evento\");\n\n jLabel6.setText(\"Ciudad del evento\");\n\n jLabel7.setText(\"Fecha del evento\");\n\n tareas.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n\n },\n new String [] {\n \"Title 1\", \"Title 2\", \"Title 3\", \"Title 4\"\n }\n ));\n jScrollPane1.setViewportView(tareas);\n\n jButton1.setText(\"Agregar\");\n jButton1.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n jButton1ActionPerformed(evt);\n }\n });\n\n jButton2.setText(\"modificar\");\n jButton2.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n jButton2ActionPerformed(evt);\n }\n });\n\n jButton3.setText(\"Eliminar\");\n jButton3.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n jButton3ActionPerformed(evt);\n }\n });\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());\n getContentPane().setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jLabel4)\n .addComponent(jLabel5)\n .addComponent(jLabel6)\n .addComponent(jLabel7))\n .addGap(20, 20, 20)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jTextField3)\n .addComponent(jTextField4)\n .addComponent(jTextField5)\n .addComponent(jTextField6)))\n .addGroup(layout.createSequentialGroup()\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jLabel1)\n .addGroup(layout.createSequentialGroup()\n .addComponent(jLabel2)\n .addGap(18, 18, 18)\n .addComponent(jTextField1, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(18, 18, 18)\n .addComponent(jLabel3)\n .addGap(18, 18, 18)\n .addComponent(jTextField2, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE)))\n .addGap(0, 35, Short.MAX_VALUE)))\n .addGap(18, 18, 18))\n .addGroup(layout.createSequentialGroup()\n .addComponent(jButton1)\n .addGap(44, 44, 44)\n .addComponent(jButton2)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(jButton3)\n .addContainerGap())\n .addGroup(layout.createSequentialGroup()\n .addComponent(consulta)\n .addGap(0, 0, Short.MAX_VALUE))\n .addGroup(layout.createSequentialGroup()\n .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 0, Short.MAX_VALUE)\n .addContainerGap())))\n .addComponent(jSeparator1)\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addContainerGap()\n .addComponent(jLabel1)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel2)\n .addComponent(jLabel3)\n .addComponent(jTextField2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jTextField1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel4)\n .addComponent(jTextField3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel5)\n .addComponent(jTextField4, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jTextField5, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jLabel6))\n .addGap(18, 18, 18)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jTextField6, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jLabel7))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addComponent(jSeparator1, javax.swing.GroupLayout.PREFERRED_SIZE, 11, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(1, 1, 1)\n .addComponent(consulta)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 90, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(18, 18, 18)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jButton1)\n .addComponent(jButton2)\n .addComponent(jButton3))\n .addContainerGap(23, Short.MAX_VALUE))\n );\n\n pack();\n }", "public void llenarTabla() {\n\n String matriz[][] = new String[lPComunes.size()][2];\n\n for (int i = 0; i < AccesoFichero.lPComunes.size(); i++) {\n matriz[i][0] = AccesoFichero.lPComunes.get(i).getPalabra();\n matriz[i][1] = AccesoFichero.lPComunes.get(i).getCodigo();\n\n }\n\n jTableComun.setModel(new javax.swing.table.DefaultTableModel(\n matriz,\n new String[]{\n \"Palabra\", \"Morse\"\n }\n ) {// Bloquea que las columnas se puedan editar, haciendo doble click en ellas\n @SuppressWarnings(\"rawtypes\")\n Class[] columnTypes = new Class[]{\n String.class, String.class\n };\n\n @SuppressWarnings({\"unchecked\", \"rawtypes\"})\n @Override\n public Class getColumnClass(int columnIndex) {\n return columnTypes[columnIndex];\n }\n boolean[] columnEditables = new boolean[]{\n false, false\n };\n\n @Override\n public boolean isCellEditable(int row, int column) {\n return columnEditables[column];\n }\n });\n\n }", "private void updateTable() throws ClassNotFoundException, SQLException {\n ResultSet set=new SetBillController().getSells();\n DefaultTableModel model=(DefaultTableModel)jTable1.getModel();\n jTable1.removeAll();\n while(set.next()){\n Object [] row={set.getString(1),set.getString(5),set.getString(2),\n set.getString(4),set.getString(3)};\n model.addRow(row);\n }\n }", "private void jTable1MouseClicked(java.awt.event.MouseEvent evt) {\n\n if (evt.getClickCount() == 1) {\n int row = jTable1.getSelectedRow();\n jTabbedPane1.setEnabledAt(2, true);\n id = (int) jTable1.getValueAt(row, 0);\n\n jTabbedPane1.setEnabledAt(0, false);\n jTabbedPane1.setEnabledAt(1, false);\n jTabbedPane1.setSelectedIndex(2);\n // jDateChooser2.setDateFormatString(jTable1.getValueAt(row, 1) + \"\");\n// java.sql.Date fecFormatoDate = null;\n// try {\n// SimpleDateFormat sdf = new java.text.SimpleDateFormat(\"yyyy-MM-dd\", new Locale(\"es\", \"ES\"));\n// fecFormatoDate = new java.sql.Date(sdf.parse(jTable1.getValueAt(row, 1).toString()).getTime());\n// System.out.println(\"Fecha con el formato java.sql.Date: \" + fecFormatoDate);\n// } catch (Exception ex) {\n// System.out.println(\"Error al obtener el formato de la fecha/hora: \" + ex.getMessage());\n// }\n // jDateChooser2.setDate(fecFormatoDate);\n// jTextField4.setText(jTable1.getValueAt(row, 2) + \"\");\n\n Date fecha = (Date) jTable1.getValueAt(row, 1);\n jDateChooser2.setDate(fecha);\n Citas citas = (Citas) jTable1.getValueAt(row, 3);\n jComboBox3.setSelectedIndex(citas.getPosicion());\n\n if (jTable1.getValueAt(row, 3).toString().length() <= 4) {\n String horas = jTable1.getValueAt(row, 3).toString().substring(0, 1);\n SpinnerNumberModel model1 = new SpinnerNumberModel(Integer.parseInt(horas), 9, 18, 1);\n jSpinner4.setModel(model1);\n } else {\n String horas = jTable1.getValueAt(row, 3).toString().substring(0, 2);\n SpinnerNumberModel model1 = new SpinnerNumberModel(Integer.parseInt(horas), 9, 18, 1);\n jSpinner4.setModel(model1);\n }\n\n String m = jTable1.getValueAt(row, 3).toString();\n String mm = m.substring(m.length() - 2, m.length());\n if (mm.substring(0, 1).equals(\"0\")) {\n SpinnerNumberModel model1 = new SpinnerNumberModel(Integer.parseInt(mm.substring(1, 2)), 0, 60, 1);\n jSpinner5.setModel(model1);\n } else {\n SpinnerNumberModel model1 = new SpinnerNumberModel(Integer.parseInt(mm), 0, 60, 1);\n jSpinner5.setModel(model1);\n }\n\n }\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n jLabel1 = new javax.swing.JLabel();\n jb_report = new javax.swing.JButton();\n jLabel3 = new javax.swing.JLabel();\n jcb_customers = new javax.swing.JComboBox<>();\n jb_findCustomer = new javax.swing.JButton();\n jb_customerSales = new javax.swing.JButton();\n jLabel4 = new javax.swing.JLabel();\n jcb_products = new javax.swing.JComboBox<>();\n jb_findProduct = new javax.swing.JButton();\n jb_productSales = new javax.swing.JButton();\n jb_allSales = new javax.swing.JButton();\n jScrollPane1 = new javax.swing.JScrollPane();\n jt_salesTable = new javax.swing.JTable();\n\n setBackground(new java.awt.Color(63, 81, 181));\n\n jLabel1.setBackground(new java.awt.Color(0, 121, 107));\n jLabel1.setFont(new java.awt.Font(\"Trebuchet MS\", 1, 14)); // NOI18N\n jLabel1.setForeground(new java.awt.Color(255, 255, 255));\n jLabel1.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);\n jLabel1.setText(\"REPORTE DE VENTAS\");\n\n jb_report.setBackground(new java.awt.Color(48, 63, 159));\n jb_report.setFont(new java.awt.Font(\"Trebuchet MS\", 1, 14)); // NOI18N\n jb_report.setForeground(new java.awt.Color(255, 255, 255));\n jb_report.setText(\"VER REPORTE\");\n jb_report.setBorder(null);\n jb_report.setBorderPainted(false);\n\n jLabel3.setFont(new java.awt.Font(\"Trebuchet MS\", 0, 14)); // NOI18N\n jLabel3.setForeground(new java.awt.Color(255, 255, 255));\n jLabel3.setText(\"Nombre\");\n\n jcb_customers.setBackground(new java.awt.Color(48, 63, 159));\n jcb_customers.setFont(new java.awt.Font(\"Trebuchet MS\", 0, 14)); // NOI18N\n jcb_customers.setForeground(new java.awt.Color(255, 255, 255));\n jcb_customers.setModel(new javax.swing.DefaultComboBoxModel<>(new String[] { \"Rubi\", \"Sergio\", \"Alessandra\", \"Oswaldo\", \"Sarah\" }));\n jcb_customers.setBorder(null);\n jcb_customers.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n jcb_customersActionPerformed(evt);\n }\n });\n\n jb_findCustomer.setBackground(new java.awt.Color(48, 63, 159));\n jb_findCustomer.setFont(new java.awt.Font(\"Trebuchet MS\", 0, 14)); // NOI18N\n jb_findCustomer.setForeground(new java.awt.Color(255, 255, 255));\n jb_findCustomer.setText(\"Buscar\");\n jb_findCustomer.setBorder(null);\n jb_findCustomer.setBorderPainted(false);\n\n jb_customerSales.setBackground(new java.awt.Color(48, 63, 159));\n jb_customerSales.setFont(new java.awt.Font(\"Trebuchet MS\", 0, 14)); // NOI18N\n jb_customerSales.setForeground(new java.awt.Color(255, 255, 255));\n jb_customerSales.setText(\"CLIENTES\");\n jb_customerSales.setBorder(null);\n jb_customerSales.setBorderPainted(false);\n\n jLabel4.setFont(new java.awt.Font(\"Trebuchet MS\", 0, 14)); // NOI18N\n jLabel4.setForeground(new java.awt.Color(255, 255, 255));\n jLabel4.setText(\"Producto\");\n\n jcb_products.setBackground(new java.awt.Color(48, 63, 159));\n jcb_products.setFont(new java.awt.Font(\"Trebuchet MS\", 0, 14)); // NOI18N\n jcb_products.setForeground(new java.awt.Color(255, 255, 255));\n jcb_products.setModel(new javax.swing.DefaultComboBoxModel<>(new String[] { \"Chocolate\", \"Cereal\", \"Galletas\", \"Pasta\", \"Atún\" }));\n jcb_products.setBorder(null);\n jcb_products.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n jcb_productsActionPerformed(evt);\n }\n });\n\n jb_findProduct.setBackground(new java.awt.Color(48, 63, 159));\n jb_findProduct.setFont(new java.awt.Font(\"Trebuchet MS\", 0, 14)); // NOI18N\n jb_findProduct.setForeground(new java.awt.Color(255, 255, 255));\n jb_findProduct.setText(\"Buscar\");\n jb_findProduct.setBorder(null);\n jb_findProduct.setBorderPainted(false);\n\n jb_productSales.setBackground(new java.awt.Color(48, 63, 159));\n jb_productSales.setFont(new java.awt.Font(\"Trebuchet MS\", 0, 14)); // NOI18N\n jb_productSales.setForeground(new java.awt.Color(255, 255, 255));\n jb_productSales.setText(\"PRODUCTOS\");\n jb_productSales.setBorder(null);\n jb_productSales.setBorderPainted(false);\n jb_productSales.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n jb_productSalesActionPerformed(evt);\n }\n });\n\n jb_allSales.setBackground(new java.awt.Color(48, 63, 159));\n jb_allSales.setFont(new java.awt.Font(\"Trebuchet MS\", 1, 14)); // NOI18N\n jb_allSales.setForeground(new java.awt.Color(255, 255, 255));\n jb_allSales.setText(\"TODAS\");\n jb_allSales.setBorder(null);\n jb_allSales.setBorderPainted(false);\n\n jScrollPane1.setBorder(null);\n jScrollPane1.setForeground(new java.awt.Color(255, 255, 255));\n\n jt_salesTable.setBackground(new java.awt.Color(48, 63, 159));\n jt_salesTable.setFont(new java.awt.Font(\"Trebuchet MS\", 0, 10)); // NOI18N\n jt_salesTable.setForeground(new java.awt.Color(255, 255, 255));\n jt_salesTable.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n {null},\n {null},\n {null},\n {null},\n {null},\n {null},\n {null},\n {null}\n },\n new String [] {\n \"Compras de la tienda\"\n }\n ));\n jt_salesTable.setGridColor(new java.awt.Color(63, 81, 181));\n jt_salesTable.setSelectionBackground(new java.awt.Color(48, 63, 159));\n jt_salesTable.setSelectionForeground(new java.awt.Color(255, 255, 255));\n jScrollPane1.setViewportView(jt_salesTable);\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);\n this.setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jLabel1, javax.swing.GroupLayout.DEFAULT_SIZE, 733, Short.MAX_VALUE)\n .addComponent(jb_report, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(jb_allSales, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addGroup(layout.createSequentialGroup()\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()\n .addComponent(jLabel4)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(jcb_products, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n .addGroup(layout.createSequentialGroup()\n .addComponent(jLabel3)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addComponent(jcb_customers, javax.swing.GroupLayout.PREFERRED_SIZE, 252, javax.swing.GroupLayout.PREFERRED_SIZE)))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addComponent(jb_findProduct, javax.swing.GroupLayout.PREFERRED_SIZE, 90, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(jb_productSales, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n .addGroup(layout.createSequentialGroup()\n .addComponent(jb_findCustomer, javax.swing.GroupLayout.PREFERRED_SIZE, 90, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(jb_customerSales, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))))\n .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 733, Short.MAX_VALUE))\n .addContainerGap())\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addContainerGap()\n .addComponent(jLabel1)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jb_findCustomer, javax.swing.GroupLayout.PREFERRED_SIZE, 33, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jcb_customers, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jLabel3, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(jb_customerSales, javax.swing.GroupLayout.PREFERRED_SIZE, 33, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jb_findProduct, javax.swing.GroupLayout.PREFERRED_SIZE, 33, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jcb_products, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jLabel4, javax.swing.GroupLayout.PREFERRED_SIZE, 33, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jb_productSales, javax.swing.GroupLayout.PREFERRED_SIZE, 33, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(jb_allSales, javax.swing.GroupLayout.PREFERRED_SIZE, 33, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 258, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(jb_report, javax.swing.GroupLayout.PREFERRED_SIZE, 33, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addContainerGap())\n );\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n jButton1 = new javax.swing.JButton();\n jLabel1 = new javax.swing.JLabel();\n nome = new javax.swing.JTextField();\n Pesquisar = new javax.swing.JButton();\n jScrollPane1 = new javax.swing.JScrollPane();\n jtable = new javax.swing.JTable();\n PesTodos = new javax.swing.JButton();\n jLabel2 = new javax.swing.JLabel();\n jTF_id = new javax.swing.JTextField();\n jButton2 = new javax.swing.JButton();\n jLabel12 = new javax.swing.JLabel();\n\n setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);\n\n jButton1.setText(\"Pesquisar\");\n jButton1.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n jButton1ActionPerformed(evt);\n }\n });\n\n jLabel1.setText(\"Consultar por modelo:\");\n\n Pesquisar.setText(\"Pesquisar\");\n Pesquisar.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n PesquisarActionPerformed(evt);\n }\n });\n\n jtable.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(0, 0, 0)));\n jtable.setFont(new java.awt.Font(\"Arial\", 0, 12)); // NOI18N\n jtable.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n\n },\n new String [] {\n \"chassi\", \"modelo\", \"fabricante\", \"cor\", \"ano\", \"pre\", \"id\"\n }\n ) {\n Class[] types = new Class [] {\n java.lang.Integer.class, java.lang.String.class, java.lang.String.class, java.lang.String.class, java.lang.String.class, java.lang.String.class, java.lang.Integer.class\n };\n\n public Class getColumnClass(int columnIndex) {\n return types [columnIndex];\n }\n });\n jScrollPane1.setViewportView(jtable);\n\n PesTodos.setText(\"Todos\");\n PesTodos.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n PesTodosActionPerformed(evt);\n }\n });\n\n jLabel2.setText(\"chassi:\");\n\n jButton2.setText(\"voltar\");\n\n jLabel12.setFont(new java.awt.Font(\"Tahoma\", 0, 36)); // NOI18N\n jLabel12.setText(\"Consulta Veículo\");\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());\n getContentPane().setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jScrollPane1)\n .addGroup(layout.createSequentialGroup()\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)\n .addComponent(jLabel12, javax.swing.GroupLayout.PREFERRED_SIZE, 342, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGroup(layout.createSequentialGroup()\n .addComponent(jLabel1)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(nome, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(Pesquisar)\n .addGap(18, 18, 18)\n .addComponent(jLabel2)\n .addGap(18, 18, 18)\n .addComponent(jTF_id, javax.swing.GroupLayout.PREFERRED_SIZE, 57, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(18, 18, 18)\n .addComponent(jButton1)))\n .addGap(26, 26, 26)\n .addComponent(jButton2)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 30, Short.MAX_VALUE)\n .addComponent(PesTodos)))\n .addContainerGap())\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addContainerGap()\n .addComponent(jLabel12, javax.swing.GroupLayout.PREFERRED_SIZE, 82, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(18, 18, 18)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel1)\n .addComponent(nome, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(Pesquisar)\n .addComponent(PesTodos)\n .addComponent(jLabel2)\n .addComponent(jTF_id, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jButton1)\n .addComponent(jButton2))\n .addGap(18, 18, 18)\n .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 187, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addContainerGap())\n );\n\n pack();\n }", "public JTable getJrTbl() {\n\t\tForMngJrArticleModel fmngJr = new ForMngJrArticleModel();\n\t\tDefaultTableModel defModel = new DefaultTableModel(0,7);\n\t\tJTable jTblForJr = new JTable(defModel);\n\t\tfor(int i =0; i<getJrArtArrayList().size();i++) {\n\t\t\tfmngJr = getJrArtArrayList().get(i);\n\t\t\t//condition to check if there is id of the logged in researcher in the loaned out to column \n\t\t\tif(fmngJr.getNmOfRe().contains(loggedReseId)) {\n\t\t\t\tObject[] objData = {fmngJr.getArNmOfJr(), fmngJr.getAuthNmOfJr(),fmngJr.getNmOfJr(), fmngJr.getYrOfJr(), fmngJr.getVolOfJr(),fmngJr.getIssOfJr(),fmngJr.getPgOfJr()};\n\t\t\t\tdefModel.addRow(objData);\n\t\t\t}\n\t\t}\n\n\t\tString reColTitles[] = {\"Name of Article\", \"Author/s\",\"Journal Title\", \"<html>Publication<br>Year</html>\",\"Volume No.\",\"Issue No.\",\"Page No.\"};\n\t\tdefModel.setColumnIdentifiers(reColTitles);\n\t\tjTblForJr.setRowHeight(28);\n\n\t\tJTableHeader tblHeader = jTblForJr.getTableHeader();\n\t\ttblHeader.setPreferredSize(new Dimension(100,35));\n\t\ttblHeader.setBackground(new Color(21, 34, 49));\n\t\ttblHeader.setForeground(Color.WHITE);\n\n\t\treturn jTblForJr;\n\t}", "private void mostrarReservas() {\n\t\tJFReservasAdmin jfres =new JFReservasAdmin();\n\t\tjfres.setVisible(true);\n\t\t\n\t\tMap<Integer,Reserva> reservas = modelo.obtenerReservasPeriodo(per.getIdPeriodo());\n\t\tDefaultTableModel dtm = new DefaultTableModel(new Object[][] {},\n\t\t\t\tnew String[] { \"Dia\", \"Hora\", \"Email\" });\n\n\t\tfor (Integer key : reservas.keySet()) {\n\n\t\t\tdtm.addRow(new Object[] { reservas.get(key).getReserva_dia(), reservas.get(key).getReserva_hora(),reservas.get(key).getEmail() });\n\t\t}\n\t\tjfres.tReservas.setModel(dtm);\n\t}", "public DefaultTableModel Ordernar() {\n String sql;\n sql = \"SELECT idempleado,empleados.documento,nombre,apellido,sueldo,trabajo FROM empleados,personas WHERE empleados.documento=personas.documento ORDER BY idempleado\";\n try {\n setTitulos();\n PS = con.Conectarse().prepareStatement(sql);\n rst = PS.executeQuery();\n Object[] fila = new Object[6];\n while (rst.next()) {\n fila[0] = rst.getInt(\"idempleado\");\n fila[1] = rst.getString(\"documento\");\n fila[2] = rst.getString(\"nombre\");\n fila[3] = rst.getString(\"apellido\");\n fila[4] = rst.getDouble(\"sueldo\");\n fila[5] = rst.getString(\"trabajo\");\n DIM.addRow(fila);\n }\n\n } catch (SQLException e) {\n Toolkit.getDefaultToolkit().beep();\n JOptionPane.showMessageDialog(null, \"NO EXISTEN DATOS\", \"AVISO\", JOptionPane.INFORMATION_MESSAGE);\n }\n return DIM;\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n jLabel1 = new javax.swing.JLabel();\n jLabel2 = new javax.swing.JLabel();\n cbBaseDeDatos = new javax.swing.JComboBox();\n jButton1 = new javax.swing.JButton();\n jScrollPane1 = new javax.swing.JScrollPane();\n tblTablas = new javax.swing.JTable();\n chHorizontal = new javax.swing.JCheckBox();\n chVertical = new javax.swing.JCheckBox();\n jLabel3 = new javax.swing.JLabel();\n jPanel1 = new javax.swing.JPanel();\n jScrollPane2 = new javax.swing.JScrollPane();\n jlColumnas = new javax.swing.JList();\n btnPasarNomCol = new javax.swing.JButton();\n btnAgregar = new javax.swing.JButton();\n jScrollPane5 = new javax.swing.JScrollPane();\n txtColumnas = new javax.swing.JList();\n jScrollPane6 = new javax.swing.JScrollPane();\n jlAtributos = new javax.swing.JList();\n cbSigno = new javax.swing.JComboBox();\n jScrollPane7 = new javax.swing.JScrollPane();\n jlCondicion = new javax.swing.JList();\n btnAgregarFiltro = new javax.swing.JButton();\n txtCondicion = new javax.swing.JTextField();\n jScrollPane3 = new javax.swing.JScrollPane();\n jlSigno = new javax.swing.JList();\n cbOPeradorLogico = new javax.swing.JComboBox();\n jScrollPane8 = new javax.swing.JScrollPane();\n jlOperadorLogico = new javax.swing.JList();\n btnCrear = new javax.swing.JButton();\n jLabel4 = new javax.swing.JLabel();\n txtNombrePubli = new javax.swing.JTextField();\n btnCancelar = new javax.swing.JButton();\n chSinFiltro = new javax.swing.JCheckBox();\n jLabel5 = new javax.swing.JLabel();\n chInmediatamente = new javax.swing.JCheckBox();\n chShedule = new javax.swing.JCheckBox();\n txtTiempo1 = new javax.swing.JTextField();\n cbFrequencia = new javax.swing.JComboBox();\n txtTiempo = new javax.swing.JTextField();\n cbFrequenciaP = new javax.swing.JComboBox();\n\n setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);\n\n jLabel1.setText(\"Tablas\");\n\n jLabel2.setText(\"Base de Datos\");\n\n jButton1.setText(\"jButton1\");\n jButton1.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n jButton1ActionPerformed(evt);\n }\n });\n\n tblTablas.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n {null},\n {null},\n {null},\n {null}\n },\n new String [] {\n \"Tablas\"\n }\n ));\n jScrollPane1.setViewportView(tblTablas);\n\n chHorizontal.setText(\"Horizontal\");\n chHorizontal.addItemListener(new java.awt.event.ItemListener() {\n public void itemStateChanged(java.awt.event.ItemEvent evt) {\n chHorizontalItemStateChanged(evt);\n }\n });\n chHorizontal.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n chHorizontalActionPerformed(evt);\n }\n });\n\n chVertical.setText(\"Vertical\");\n chVertical.addItemListener(new java.awt.event.ItemListener() {\n public void itemStateChanged(java.awt.event.ItemEvent evt) {\n chVerticalItemStateChanged(evt);\n }\n });\n chVertical.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n chVerticalActionPerformed(evt);\n }\n });\n\n jLabel3.setText(\"Filtro\");\n\n jlColumnas.setSelectionMode(javax.swing.ListSelectionModel.SINGLE_SELECTION);\n jScrollPane2.setViewportView(jlColumnas);\n\n btnPasarNomCol.setText(\">\");\n btnPasarNomCol.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btnPasarNomColActionPerformed(evt);\n }\n });\n\n btnAgregar.setText(\"Agregar Columna\");\n btnAgregar.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btnAgregarActionPerformed(evt);\n }\n });\n\n jScrollPane5.setViewportView(txtColumnas);\n\n jScrollPane6.setViewportView(jlAtributos);\n\n cbSigno.setModel(new javax.swing.DefaultComboBoxModel(new String[] { \"=\", \"<\", \">\", \">=\", \"<=\", \"<>\" }));\n\n jScrollPane7.setViewportView(jlCondicion);\n\n btnAgregarFiltro.setText(\"Agregar Filtro\");\n btnAgregarFiltro.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btnAgregarFiltroActionPerformed(evt);\n }\n });\n\n jScrollPane3.setViewportView(jlSigno);\n\n cbOPeradorLogico.setModel(new javax.swing.DefaultComboBoxModel(new String[] { \"AND\", \"OR\" }));\n\n jScrollPane8.setViewportView(jlOperadorLogico);\n\n btnCrear.setText(\"Crear\");\n btnCrear.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btnCrearActionPerformed(evt);\n }\n });\n\n jLabel4.setText(\"Nombre Publicacion:\");\n\n btnCancelar.setText(\"Cancelar\");\n btnCancelar.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btnCancelarActionPerformed(evt);\n }\n });\n\n javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);\n jPanel1.setLayout(jPanel1Layout);\n jPanel1Layout.setHorizontalGroup(\n jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addComponent(btnAgregar)\n .addGap(0, 0, Short.MAX_VALUE))\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jScrollPane5, javax.swing.GroupLayout.PREFERRED_SIZE, 86, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)\n .addComponent(btnPasarNomCol, javax.swing.GroupLayout.PREFERRED_SIZE, 42, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 85, javax.swing.GroupLayout.PREFERRED_SIZE)))\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel1Layout.createSequentialGroup()\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(jLabel4)\n .addGap(18, 18, 18)\n .addComponent(txtNombrePubli, javax.swing.GroupLayout.PREFERRED_SIZE, 127, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(39, 39, 39))\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addGap(28, 28, 28)\n .addComponent(jScrollPane6, javax.swing.GroupLayout.PREFERRED_SIZE, 81, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(27, 27, 27)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addComponent(cbSigno, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(18, 18, 18)\n .addComponent(txtCondicion, javax.swing.GroupLayout.PREFERRED_SIZE, 99, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addComponent(jScrollPane3, javax.swing.GroupLayout.PREFERRED_SIZE, 41, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(18, 18, 18)\n .addComponent(jScrollPane7, javax.swing.GroupLayout.PREFERRED_SIZE, 99, javax.swing.GroupLayout.PREFERRED_SIZE)))\n .addGap(18, 18, 18)))\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)\n .addComponent(cbOPeradorLogico, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(jScrollPane8, javax.swing.GroupLayout.PREFERRED_SIZE, 0, Short.MAX_VALUE)\n .addComponent(btnCrear, javax.swing.GroupLayout.DEFAULT_SIZE, 63, Short.MAX_VALUE)))\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel1Layout.createSequentialGroup()\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(btnCancelar))))\n .addComponent(btnAgregarFiltro, javax.swing.GroupLayout.PREFERRED_SIZE, 103, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))))\n );\n jPanel1Layout.setVerticalGroup(\n jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(cbSigno, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(txtCondicion, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(cbOPeradorLogico, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(btnPasarNomCol))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)\n .addComponent(jScrollPane7, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, 97, Short.MAX_VALUE)\n .addComponent(jScrollPane3, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.PREFERRED_SIZE, 0, Short.MAX_VALUE)\n .addComponent(jScrollPane2, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.PREFERRED_SIZE, 0, Short.MAX_VALUE)\n .addComponent(jScrollPane8, javax.swing.GroupLayout.PREFERRED_SIZE, 0, Short.MAX_VALUE)\n .addComponent(jScrollPane6, javax.swing.GroupLayout.PREFERRED_SIZE, 0, Short.MAX_VALUE))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel1Layout.createSequentialGroup()\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(btnAgregarFiltro)\n .addComponent(btnAgregar))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addComponent(jScrollPane5, javax.swing.GroupLayout.PREFERRED_SIZE, 91, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(17, 17, 17))\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel1Layout.createSequentialGroup()\n .addComponent(btnCancelar)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel4)\n .addComponent(txtNombrePubli, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(btnCrear))\n .addGap(27, 27, 27))))\n );\n\n chSinFiltro.setText(\"Sin Filtro\");\n chSinFiltro.addItemListener(new java.awt.event.ItemListener() {\n public void itemStateChanged(java.awt.event.ItemEvent evt) {\n chSinFiltroItemStateChanged(evt);\n }\n });\n chSinFiltro.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n chSinFiltroActionPerformed(evt);\n }\n });\n\n jLabel5.setText(\"SnapshotAgent\");\n\n chInmediatamente.setText(\"Crear inmediatamente un Snapshot\");\n\n chShedule.setText(\"Horario de ejcucion del Agente Snapshot\");\n\n cbFrequencia.setModel(new javax.swing.DefaultComboBoxModel(new String[] { \"Diariamente\" }));\n\n cbFrequenciaP.setModel(new javax.swing.DefaultComboBoxModel(new String[] { \"Horas\", \"Minutos\", \"Segundos\" }));\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());\n getContentPane().setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jLabel5)\n .addComponent(chShedule)\n .addComponent(chInmediatamente))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(txtTiempo1)\n .addComponent(cbFrequenciaP, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(txtTiempo)\n .addComponent(cbFrequencia, javax.swing.GroupLayout.Alignment.TRAILING, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n .addGap(32, 32, 32))\n .addGroup(layout.createSequentialGroup()\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jLabel1, javax.swing.GroupLayout.PREFERRED_SIZE, 65, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jLabel2))\n .addGap(33, 33, 33)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)\n .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 0, Short.MAX_VALUE)\n .addComponent(cbBaseDeDatos, javax.swing.GroupLayout.PREFERRED_SIZE, 129, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGap(18, 18, 18)\n .addComponent(jButton1, javax.swing.GroupLayout.PREFERRED_SIZE, 29, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(18, 18, 18)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(chHorizontal)\n .addComponent(chVertical)\n .addComponent(jLabel3)\n .addComponent(chSinFiltro))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED, 10, Short.MAX_VALUE)))\n .addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addContainerGap())\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel2)\n .addComponent(cbBaseDeDatos, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jButton1))\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jLabel1, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE)))\n .addGroup(layout.createSequentialGroup()\n .addComponent(jLabel3)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addComponent(chHorizontal)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addComponent(chVertical)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addComponent(chSinFiltro)))\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addGap(44, 44, 44)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addComponent(jLabel5)\n .addGap(18, 18, 18)\n .addComponent(chInmediatamente)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addComponent(chShedule)\n .addGap(0, 0, Short.MAX_VALUE))\n .addGap(31, 31, 31))\n .addGap(53, 53, 53))\n .addGroup(layout.createSequentialGroup()\n .addGap(30, 30, 30)\n .addComponent(cbFrequencia, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(18, 18, 18)\n .addComponent(txtTiempo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(cbFrequenciaP, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(txtTiempo1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(0, 0, Short.MAX_VALUE))))\n .addGroup(layout.createSequentialGroup()\n .addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addContainerGap())))\n );\n\n pack();\n }", "public void MakeTableData()\r\n {\n classes = ResetClasses();\r\n \r\n // 'WHATS ON' TAB SELECTED\r\n if (selectedTab == 0)\r\n {\r\n // iterate through days\r\n for (int i = 0; i < daysPerWeek; i++)\r\n {\r\n // iterate through times and rooms\r\n for (int j = 0; j < totalSlots; j++)\r\n {\r\n LessonClass a = weekArray[(weekNo -1)].dayArray[i].dayMap.get(roomNtime[j]);\r\n if (a != null)\r\n {\r\n if (byAllFlag == true)\r\n {\r\n classes[j][i] = a.toString();\r\n }\r\n else if (bySubjectFlag == true)\r\n {\r\n if (a.subject == subComb)\r\n {\r\n classes[j][i] = a.toString();\r\n }\r\n }\r\n else if (byTutorFlag == true)\r\n {\r\n if (a.tutorName == tutComb)\r\n {\r\n classes[j][i] = a.toString();\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n // 'DIARY' TAB SELECTED\r\n else if (selectedTab == 1)\r\n {\r\n if (userLoggedIn != null)\r\n { \r\n // iterate through days\r\n for (int i = 0; i < daysPerWeek; i++)\r\n {\r\n // iterate through times and rooms\r\n for (int j = 0; j < totalSlots; j++)\r\n {\r\n // pertinent tracks if ID is in register\r\n boolean pertinent = false;\r\n LessonClass a = weekArray[(weekNo -1)].dayArray[i].dayMap.get(roomNtime[j]);\r\n if (a != null)\r\n {\r\n for (String s : a.register)\r\n {\r\n if (userLoggedIn.equals(s))\r\n {\r\n pertinent = true;\r\n }\r\n } \r\n \r\n if (byAllFlag == true && pertinent == true)\r\n {\r\n classes[j][i] = a.toString();\r\n }\r\n else if (bySubjectFlag == true && pertinent == true)\r\n {\r\n if (a.subject == subComb)\r\n {\r\n classes[j][i] = a.toString();\r\n }\r\n }\r\n else if (byTutorFlag == true && pertinent == true)\r\n {\r\n if (a.tutorName == tutComb)\r\n {\r\n classes[j][i] = a.toString();\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }", "public void displayLoanToJTable()\n {\n DefaultTableModel model = (DefaultTableModel) loan_results_jTable.getModel();\n Object rowData[] = new Object[7];\n for(int i = 0; i < _list.size(); i++)\n {\n rowData[0] = _list.get(i)._Bname;\n rowData[1] = _list.get(i)._LoanId;\n rowData[2] = _list.get(i)._ISBN;\n rowData[3] = _list.get(i)._CardId;\n rowData[4] = _list.get(i)._DateOut;\n rowData[5] = _list.get(i)._DueDate;\n rowData[6] = _list.get(i)._DateIn; \n model.addRow(rowData);\n } \n }", "public SelecaoGuardada(Facade facade) throws SQLException {\n initComponents();\n this.facade = facade;\n DefaultTableModel dm = new DefaultTableModel(){\n @Override\n public boolean isCellEditable(int row, int column) {\n if( column == 5 || column == 6)return true; return false;\n }};\n \n\n\n this.dm = dm;\n dm.setColumnIdentifiers(new String [] {\"Número de Save\",\"Nome\", \"Número Contribuinte\", \"Data\", \"Modelo\",\"Retomar\",\"Apagar\"});\n jTable1.setModel(dm);\n\n\n }", "public void Show_Products_in_jTable()\n {\n ArrayList<Patient> list = getPatientList();\n DefaultTableModel model = (DefaultTableModel) jTablePatient.getModel();\n //Clear jTable;\n model.setRowCount(0);\n Object[] row = new Object[5];\n for(int i=0;i<list.size();i++)\n {\n row[0] = list.get(i).getID();\n row[1] = list.get(i).getName();\n row[2] = list.get(i).getAge();\n row[3] = list.get(i).getContactNumber();\n row[4] = list.get(i).getDoctor();\n \n model.addRow(row);\n }\n }", "public void buscarproducto() {\r\n try {\r\n modelo.setNombre(vista.jTbnombre2.getText());//C.P.M le mandamos al modelo el nombre del producto\r\n rs = modelo.Buscar();//C.P.M obtenemos el resultado del modelos\r\n if (rs.equals(\"\")) {//C.P.M en caso de que el resultado venga vacio notificamos a el usuario que no encontro el producto\r\n JOptionPane.showMessageDialog(null, \"No se encontro: \" + vista.jTbnombre2.getText() + \" en la base de datos.\");\r\n }\r\n //C.P.M Para establecer el modelo al JTable\r\n DefaultTableModel buscar = new DefaultTableModel() {\r\n @Override\r\n public boolean isCellEditable(int rowIndex, int vColIndex) {//C.P.M Aqui le decimos que no seran editables los campos de la tabla\r\n return false;\r\n }\r\n };\r\n vista.jTbuscar.setModel(buscar);//C.P.M le mandamos el modelo\r\n modelo.estructuraProductos(buscar);//C.P.M Auui obtenemos la estructura de la tabla(\"Los encabezados\")\r\n ResultSetMetaData rsMd = rs.getMetaData();//C.P.M Obtenemos los metadatos para obtener la cantidad del columnas que llegan\r\n int cantidadColumnas = rsMd.getColumnCount();//C.P.M la cantidad la alojamos dentro de un entero\r\n while (rs.next()) {//C.P.M recorremos el resultado \r\n Object[] fila = new Object[cantidadColumnas];//C.P.M Creamos un objeto con el numero de columnas\r\n for (int i = 0; i < cantidadColumnas; i++) {//C.P.M lo recoremos ese vector\r\n fila[i] = rs.getObject(i + 1);//C.P.M Aqui vamos insertando la informacion obtenida de la base de datos\r\n }\r\n buscar.addRow(fila);//C.P.M y agregamos el arreglo como una nueva fila a la tabla\r\n }\r\n } catch (SQLException ex) {\r\n JOptionPane.showMessageDialog(null, \"Ocurio un error al buscar el producto\");\r\n }\r\n\r\n }", "public FormJoueur(Competition competition)\n\t{\n\t\tsuper(\"Liste des joueurs de la compétition\", true, true);\n\t\t//setClosable(false);\n\t\tthis.competition = competition;\n\t\tcompetition.addObserver(this);\t\t\n\t\tJoueursTableModel modelJoueur = new JoueursTableModel();\t\t\t\t\n\t\tsorter = new TableSorter(modelJoueur);\n\t\ttableJoueurs = new JTable(sorter);\n\t\tsorter.setTableHeader(tableJoueurs.getTableHeader());\n\t\ttableJoueurs.setPreferredScrollableViewportSize(new Dimension(500, 70));\n\t\ttableJoueurs.setAutoscrolls(true);\t\t\n\t\ttableJoueurs.getTableHeader().setToolTipText(\n\t\t\t\t\"Click to specify sorting; Control-Click to specify secondary sorting\");\n\t\t\t\t\n\t\tmodelJoueur.addTableModelListener(this);\n\t\tPlaceTableCellRenderer renderer = new PlaceTableCellRenderer();\n\t\tPlaceTableCellRenderer renderer2 = new PlaceTableCellRenderer();\n\t\ttableJoueurs.setDefaultRenderer( Number.class, renderer );\n\t\ttableJoueurs.setDefaultRenderer( String.class, renderer2 );\t\t\n\t\trenderer.setHorizontalAlignment(PlaceTableCellRenderer.CENTER);\n\n\t\t\n\t\tJScrollPane scrollPane = new JScrollPane(tableJoueurs);\n\t\t//add(scrollPane);\t\t\t\n\t\tsetBounds(10, 10, 500, 300);\n\tGridBagConstraints constraints = new GridBagConstraints();\n\tJPanel panel = new JPanel(new BorderLayout());\n\t\tpanel.setLayout(new GridBagLayout());\n\t\ttableJoueurs.getSelectionModel().addListSelectionListener(new ListSelectionListener()\n\t\t{\n\t\t\tpublic void valueChanged(ListSelectionEvent arg0)\n\t\t\t{\n\t\t\t\tselectionJoueurChanged(arg0);\n\n\t\t\t}\n\t\t});\t\t\n\t\ttableJoueurs.addKeyListener(new KeyListener()\n\t\t{\n\t\t\tpublic void keyTyped(KeyEvent e)\n\t\t\t{\n\t\t\t}\n\n\t\t\tpublic void keyPressed(KeyEvent e)\n\t\t\t{\n\t\t\t\tactionKeyPressed(e);\n\n\t\t\t}\n\n\t\t\tpublic void keyReleased(KeyEvent e)\n\t\t\t{\n\t\t\t}\n\t\t});\n\t\t\n\t\trbLincencie.addChangeListener(\n\t\t\tnew ChangeListener()\n\t\t\t{\n\t\t\t\tpublic void stateChanged(ChangeEvent e)\n\t\t\t\t{\n\t\t\t\t\trbLincencieStateChanged(e);\n\t\t\t\t}\n\t\t\t});\n\t\tbAjouter.addActionListener(\n\t\t\tnew ActionListener()\n\t\t\t{\n\t\t\t\tpublic void actionPerformed(ActionEvent e)\n\t\t\t\t{\n\t\t\t\t\tajouterJoueur(e);\n\t\t\t\t}\n\t\t\t});\n\n\t\tbAddClub.addActionListener(\n\t\t\tnew ActionListener()\n\t\t\t{\n\t\t\t\tpublic void actionPerformed(ActionEvent e)\n\t\t\t\t{\n\t\t\t\t\tajouterClub(e);\n\t\t\t\t}\n\t\t\t});\n\n\t\tbImprimerPresents.addActionListener(\n\t\t\tnew ActionListener()\n\t\t\t{\n\t\t\t\tpublic void actionPerformed(ActionEvent e)\n\t\t\t\t{\n\t\t\t\t\timprimerPresents(e);\n\t\t\t\t}\n\t\t\t});\n\n\t\t\t\n\t\tbImprimerJoueurs.addActionListener(\n\t\t\tnew ActionListener()\n\t\t\t{\n\t\t\t\tpublic void actionPerformed(ActionEvent e)\n\t\t\t\t{\n\t\t\t\t\timprimerJoueurs(e);\n\t\t\t\t}\n\t\t\t});\n\t\t\n\t\tbSupprimer.addActionListener(\n\t\t\tnew ActionListener()\n\t\t\t{\n\t\t\t\tpublic void actionPerformed(ActionEvent e)\n\t\t\t\t{\n\t\t\t\t\tsupprimerJoueur(e);\n\t\t\t\t}\n\t\t\t});\n\n\t\tbModifier.addActionListener(\n\t\t\tnew ActionListener()\n\t\t\t{\n\t\t\t\tpublic void actionPerformed(ActionEvent e)\n\t\t\t\t{\n\t\t\t\t\tmodifierJoueur(e);\n\t\t\t\t}\n\t\t\t});\n\n\t\tbSauverListe.addActionListener(\n\t\t\tnew ActionListener()\n\t\t\t{\n\t\t\t\tpublic void actionPerformed(ActionEvent e)\n\t\t\t\t{\n\t\t\t\t\tsauverListe(e);\n\t\t\t\t}\n\t\t\t});\n\n\t\tbSauverSelection.addActionListener(\n\t\t\tnew ActionListener()\n\t\t\t{\n\t\t\t\tpublic void actionPerformed(ActionEvent e)\n\t\t\t\t{\n\t\t\t\t\tsauverSelection(e);\n\t\t\t\t}\n\t\t\t});\n\t\t\t\n\t\t\t\n\t\tbChargerListe.addActionListener(\n\t\t\tnew ActionListener()\n\t\t\t{\n\t\t\t\tpublic void actionPerformed(ActionEvent e)\n\t\t\t\t{\n\t\t\t\t\tchargerListe(e);\n\t\t\t\t}\n\t\t\t});\n\n bRAZPart.addActionListener(\n new ActionListener()\n {\n public void actionPerformed(ActionEvent e)\n {\n clearParticipation(e);\n }\n });\n\t\t\n bAjouter.setToolTipText(\"Ajoute ce joueur à la liste des joueurs.\");\n bAddClub.setToolTipText(\"Ajoute le club renseigné à la liste des clubs.\");\n bChargerListe.setToolTipText(\"Charge une liste de joueurs à partir d'un fichier.\");\n bImprimerJoueurs.setToolTipText(\"Imprime la liste des joueurs.\");\n bImprimerPresents.setToolTipText(\"Imprime la liste des joueurs présents dans le tournoi.\");\n bModifier.setToolTipText(\"Modifie le joueur sélectionné.\");\n bRAZPart.setToolTipText(\"Remet à zéro le nombre de participation de tous les joueurs.\");\n bSauverListe.setToolTipText(\"Sauvegarde la liste des joueurs dans un fichier.\");\n bSauverSelection.setToolTipText(\"Sauvegarde la liste des joueurs présents dans un fichier.\");\n bSupprimer.setToolTipText(\"Efface le joueur sélectionné.\");\n tfCltNew.setToolTipText(\"Nouveau classement (EX:1685)\");\n cbCltOld.setToolTipText(\"Ancien classement\");\n tfClub.setToolTipText(\"Permet de renseigner un nouveau club\");\n \n\t\tint ligne = 0;\n\t\t//================= 1ere ligne =========================\n\t\tligne++;\n\t\tconstraints.gridy = ligne;\n\t\tconstraints.gridx = 3;\n\t\tconstraints.gridwidth = 1;\n\t\tconstraints.gridheight = 1;\n\t\tconstraints.weightx = 0.0;\n\t\tconstraints.weighty = 0.0;\n\t\tconstraints.anchor = GridBagConstraints.NORTHEAST;\n\t\tconstraints.fill = GridBagConstraints.NONE;\n\t\tconstraints.ipadx = 0;\n\t\tconstraints.ipady = 0;\n\t\tconstraints.insets = new Insets(2, 2, 2, 2);\n\t\tpanel.add(lblNom, constraints);\n\t\t\n\t\tconstraints.gridy = ligne;\n\t\tconstraints.gridx = 4;\n\t\tconstraints.gridwidth = 3;\n\t\tconstraints.gridheight = 1;\n\t\tconstraints.weightx = 0.0;\n\t\tconstraints.weighty = 0.0;\n\t\tconstraints.anchor = GridBagConstraints.NORTHWEST;\n\t\tconstraints.fill = GridBagConstraints.NONE;\n\t\tconstraints.ipadx = 0;\n\t\tconstraints.ipady = 0;\n\t\tconstraints.insets = new Insets(2, 2, 2, 2);\n\t\tpanel.add(tfNom, constraints);\n\n\t\tconstraints.gridx = 0;\n\t\tconstraints.gridy = ligne;\n\t\tconstraints.gridwidth = 3;\n\t\tconstraints.gridheight = 9;\n\t\tconstraints.weightx = 1.0;\n\t\tconstraints.weighty = 0.8;\n\t\tconstraints.anchor = GridBagConstraints.CENTER;\n\t\tconstraints.fill = GridBagConstraints.BOTH;\n\t\tconstraints.ipadx = 0;\n\t\tconstraints.ipady = 0;\n\t\tconstraints.insets = new Insets(2, 2, 2, 2);\n\t\tpanel.add(scrollPane, constraints);\n\n\n\t\tconstraints.gridx = 3;\n\t\tconstraints.gridy = ++ligne;\n\t\tconstraints.gridwidth = 1;\n\t\tconstraints.gridheight = 1;\n\t\tconstraints.weightx = 0.0;\n\t\tconstraints.weighty = 0.0;\n\t\tconstraints.anchor = GridBagConstraints.NORTHEAST;\n\t\tconstraints.fill = GridBagConstraints.NONE;\n\t\tconstraints.ipadx = 0;\n\t\tconstraints.ipady = 0;\n\t\tconstraints.insets = new Insets(2, 2, 2, 2);\n\t\tpanel.add(lblPrenom, constraints);\n\n\t\tconstraints.gridx = 4;\n\t\tconstraints.gridwidth = 3;\n\t\tconstraints.gridheight = 1;\n\t\tconstraints.weightx = 0.0;\n\t\tconstraints.weighty = 0.0;\n\t\tconstraints.anchor = GridBagConstraints.NORTHWEST;\n\t\tconstraints.fill = GridBagConstraints.NONE;\n\t\tconstraints.ipadx = 0;\n\t\tconstraints.ipady = 0;\n\t\tconstraints.insets = new Insets(2, 2, 2, 2);\n\t\tpanel.add(tfPrenom, constraints);\n\n\t\t//================= 3eme ligne =========================\n\t\tbgSexe.add(rbFeminin);\n\t\tbgSexe.add(rbMasculin);\n\t\tconstraints.gridx = 3;\n\t\tconstraints.gridy = ++ligne;\n\t\tconstraints.gridwidth = 1;\n\t\tconstraints.gridheight = 1;\n\t\tconstraints.weightx = 0.0;\n\t\tconstraints.weighty = 0.0;\n\t\tconstraints.anchor = GridBagConstraints.NORTHWEST;\n\t\tconstraints.fill = GridBagConstraints.NONE;\n\t\tconstraints.ipadx = 0;\n\t\tconstraints.ipady = 0;\n\t\tconstraints.insets = new Insets(2, 2, 2, 2);\n\t\tpanel.add(lblMasculin, constraints);\n\n\t\tconstraints.gridx = 4;\n\t\tconstraints.gridwidth = 1;\n\t\tconstraints.gridheight = 1;\n\t\tconstraints.weightx = 0.0;\n\t\tconstraints.weighty = 0.0;\n\t\tconstraints.anchor = GridBagConstraints.NORTHWEST;\n\t\tconstraints.fill = GridBagConstraints.NONE;\n\t\tconstraints.ipadx = 0;\n\t\tconstraints.ipady = 0;\n\t\tconstraints.insets = new Insets(2, 2, 2, 2);\n\t\tpanel.add(rbMasculin, constraints);\n\n\t\tconstraints.gridx = 5;\n\t\tconstraints.gridwidth = 1;\n\t\tconstraints.gridheight = 1;\n\t\tconstraints.weightx = 0.0;\n\t\tconstraints.weighty = 0.0;\n\t\tconstraints.anchor = GridBagConstraints.NORTHWEST;\n\t\tconstraints.fill = GridBagConstraints.NONE;\n\t\tconstraints.ipadx = 0;\n\t\tconstraints.ipady = 0;\n\t\tconstraints.insets = new Insets(2, 2, 2, 2);\n\t\tpanel.add(lblFeminin, constraints);\n\n\t\tconstraints.gridx = 6;\n\t\tconstraints.gridwidth = 1;\n\t\tconstraints.gridheight = 1;\n\t\tconstraints.weightx = 0.0;\n\t\tconstraints.weighty = 0.0;\n\t\tconstraints.anchor = GridBagConstraints.NORTHWEST;\n\t\tconstraints.fill = GridBagConstraints.NONE;\n\t\tconstraints.ipadx = 0;\n\t\tconstraints.ipady = 0;\n\t\tconstraints.insets = new Insets(2, 2, 2, 2);\n\t\tpanel.add(rbFeminin, constraints);\n\t\t//================= 3eme ligne =========================\n\t\tbgLicencie.add(rbLincencie);\n\t\tbgLicencie.add(rbNonLicencie);\n\t\tconstraints.gridx = 3;\n\t\tconstraints.gridy = ++ligne;\n\t\tconstraints.gridwidth = 1;\n\t\tconstraints.gridheight = 1;\n\t\tconstraints.weightx = 0.0;\n\t\tconstraints.weighty = 0.0;\n\t\tconstraints.anchor = GridBagConstraints.NORTHWEST;\n\t\tconstraints.fill = GridBagConstraints.NONE;\n\t\tconstraints.ipadx = 0;\n\t\tconstraints.ipady = 0;\n\t\tconstraints.insets = new Insets(2, 2, 2, 2);\n\t\tpanel.add(new JLabel(\"licencié\"), constraints);\n\n\t\tconstraints.gridx = 4;\n\t\tconstraints.gridwidth = 1;\n\t\tconstraints.gridheight = 1;\n\t\tconstraints.weightx = 0.0;\n\t\tconstraints.weighty = 0.0;\n\t\tconstraints.anchor = GridBagConstraints.NORTHWEST;\n\t\tconstraints.fill = GridBagConstraints.NONE;\n\t\tconstraints.ipadx = 0;\n\t\tconstraints.ipady = 0;\n\t\tconstraints.insets = new Insets(2, 2, 2, 2);\n\t\tpanel.add(rbLincencie, constraints);\n\n\t\tconstraints.gridx = 5;\n\t\tconstraints.gridwidth = 1;\n\t\tconstraints.gridheight = 1;\n\t\tconstraints.weightx = 0.0;\n\t\tconstraints.weighty = 0.0;\n\t\tconstraints.anchor = GridBagConstraints.NORTHWEST;\n\t\tconstraints.fill = GridBagConstraints.NONE;\n\t\tconstraints.ipadx = 0;\n\t\tconstraints.ipady = 0;\n\t\tconstraints.insets = new Insets(2, 2, 2, 2);\n\t\tpanel.add(new JLabel(\"Non licencié\"), constraints);\n\n\t\tconstraints.gridx = 6;\n\t\tconstraints.gridwidth = 1;\n\t\tconstraints.gridheight = 1;\n\t\tconstraints.weightx = 0.0;\n\t\tconstraints.weighty = 0.0;\n\t\tconstraints.anchor = GridBagConstraints.NORTHWEST;\n\t\tconstraints.fill = GridBagConstraints.NONE;\n\t\tconstraints.ipadx = 0;\n\t\tconstraints.ipady = 0;\n\t\tconstraints.insets = new Insets(2, 2, 2, 2);\n\t\tpanel.add(rbNonLicencie, constraints);\n\n\t\t//=======================================================\n\t\tconstraints.gridx = 3;\n\t\tconstraints.gridy = ++ligne;\n\t\tconstraints.gridwidth = 1;\n\t\tconstraints.gridheight = 1;\n\t\tconstraints.weightx = 0.0;\n\t\tconstraints.weighty = 0.0;\n\t\tconstraints.anchor = GridBagConstraints.NORTHWEST;\n\t\tconstraints.fill = GridBagConstraints.NONE;\n\t\tconstraints.ipadx = 0;\n\t\tconstraints.ipady = 0;\n\t\tconstraints.insets = new Insets(2, 2, 2, 2);\n\t\tpanel.add(new JLabel(\"Club\"), constraints);\n\n\t\tconstraints.gridx = 4;\n\t\tconstraints.gridwidth = 1;\n\t\tconstraints.gridheight = 1;\n\t\tconstraints.weightx = 0.0;\n\t\tconstraints.weighty = 0.0;\n\t\tconstraints.anchor = GridBagConstraints.NORTHWEST;\n\t\tconstraints.fill = GridBagConstraints.NONE;\n\t\tconstraints.ipadx = 0;\n\t\tconstraints.ipady = 0;\n\t\tconstraints.insets = new Insets(2, 2, 2, 2);\n\t\tpanel.add(cbClub, constraints);\n\t\t\n\t\tconstraints.gridx = 5;\n\t\tpanel.add(tfClub, constraints);\n\t\t\n\t\tconstraints.gridx = 6;\n\t\tpanel.add(bAddClub, constraints);\n\t\t\n\n\t\t//=================== 4ème ligne =========================\n\t\tconstraints.gridx = 3;\n\t\tconstraints.gridy = ++ligne;\n\t\tconstraints.gridwidth = 1;\n\t\tconstraints.gridheight = 1;\n\t\tconstraints.weightx = 0.0;\n\t\tconstraints.weighty = 0.0;\n\t\tconstraints.anchor = GridBagConstraints.NORTHWEST;\n\t\tconstraints.fill = GridBagConstraints.NONE;\n\t\tconstraints.ipadx = 0;\n\t\tconstraints.ipady = 0;\n\t\tconstraints.insets = new Insets(2, 2, 2, 2);\n\t\tpanel.add(lblClt, constraints);\n\n\t\tconstraints.gridx = 4;\n\t\tconstraints.gridwidth = 1;\n\t\tconstraints.gridheight = 1;\n\t\tconstraints.weightx = 0.0;\n\t\tconstraints.weighty = 0.0;\n\t\tconstraints.anchor = GridBagConstraints.NORTHWEST;\n\t\tconstraints.fill = GridBagConstraints.NONE;\n\t\tconstraints.ipadx = 0;\n\t\tconstraints.ipady = 0;\n\t\tconstraints.insets = new Insets(2, 2, 2, 2);\n\t\tpanel.add(tfCltNew, constraints);\n\n\t\tconstraints.gridx = 5;\n\t\tconstraints.gridwidth = 1;\n\t\tconstraints.gridheight = 1;\n\t\tconstraints.weightx = 0.0;\n\t\tconstraints.weighty = 0.0;\n\t\tconstraints.anchor = GridBagConstraints.NORTHWEST;\n\t\tconstraints.fill = GridBagConstraints.NONE;\n\t\tconstraints.ipadx = 0;\n\t\tconstraints.ipady = 0;\n\t\tconstraints.insets = new Insets(2, 2, 2, 2);\n\t\tpanel.add(cbCltOld, constraints);\n\t\t\n\t\tconstraints.gridx = 6;\n\t\ttfNumero.setToolTipText(\"joueurs numérotés\");\n\t\tpanel.add(tfNumero, constraints);\n\t\t\n\t\t//=================== 4ème ligne =========================\n\t\tconstraints.gridx = 3;\n\t\tconstraints.gridy = ++ligne;\n\t\tconstraints.gridwidth = 1;\n\t\tconstraints.gridheight = 1;\n\t\tconstraints.weightx = 0.0;\n\t\tconstraints.weighty = 0.0;\n\t\tconstraints.anchor = GridBagConstraints.NORTHWEST;\n\t\tconstraints.fill = GridBagConstraints.NONE;\n\t\tconstraints.ipadx = 0;\n\t\tconstraints.ipady = 0;\n\t\tconstraints.insets = new Insets(2, 2, 2, 2);\n\t\tpanel.add(new JLabel(\"Catégorie\"), constraints);\n\n\t\tconstraints.gridx = 4;\n\t\tconstraints.gridwidth = 3;\n\t\tconstraints.gridheight = 1;\n\t\tconstraints.weightx = 0.0;\n\t\tconstraints.weighty = 0.0;\n\t\tconstraints.anchor = GridBagConstraints.NORTHWEST;\n\t\tconstraints.fill = GridBagConstraints.NONE;\n\t\tconstraints.ipadx = 0;\n\t\tconstraints.ipady = 0;\n\t\tconstraints.insets = new Insets(2, 2, 2, 2);\n\t\tpanel.add(cbCategorie, constraints);\n\n\t\t//================== 5 ligne ====================\n\t\t\n\t\tJPanel panelButtonsJoueurs = new JPanel(new GridLayout(1,3));\n\t\tconstraints.gridx = 3;\n\t\tconstraints.gridy = ++ligne;\n\t\tconstraints.gridwidth = 5;\n\t\tconstraints.gridheight = 1;\n\t\tconstraints.weightx = 0.0;\n\t\tconstraints.weighty = 0.0;\n\t\tconstraints.anchor = GridBagConstraints.NORTH;\n\t\tconstraints.fill = GridBagConstraints.NONE;\n\t\tconstraints.ipadx = 0;\n\t\tconstraints.ipady = 0;\n\t\tconstraints.insets = new Insets(2, 2, 2, 2);\n\t\tpanel.add(panelButtonsJoueurs, constraints);\n\t\t\n\t\tpanelButtonsJoueurs.add(bAjouter);\n\t\tpanelButtonsJoueurs.add(bModifier);\n\t\tpanelButtonsJoueurs.add(bSupprimer);\n\t\t\n\t\t\n\t\tJPanel panelButtonsListe = new JPanel(new GridLayout(3,2));\n\t\tconstraints.gridx = 3;\n\t\tconstraints.gridy = ++ligne;\n\t\tconstraints.gridwidth = 5;\n\t\tconstraints.gridheight = 1;\n\t\tconstraints.weightx = 0.0;\n\t\tconstraints.weighty = 0.0;\n\t\tconstraints.anchor = GridBagConstraints.SOUTH;\n\t\tconstraints.fill = GridBagConstraints.NONE;\n\t\tconstraints.ipadx = 0;\n\t\tconstraints.ipady = 0;\n\t\tconstraints.insets = new Insets(2, 2, 2, 2);\n\t\tpanel.add(panelButtonsListe, constraints);\n\t\tpanelButtonsListe.add(bSauverListe);\n\t\tpanelButtonsListe.add(bSauverSelection);\n\t\tpanelButtonsListe.add(bChargerListe);\n\t\tpanelButtonsListe.add(bImprimerPresents);\n\t\tpanelButtonsListe.add(bImprimerJoueurs);\n panelButtonsListe.add(bRAZPart);\n\t\t\n\t\t\n\t\tbSauverListe.setFocusable(false);\n\t\tbSauverSelection.setFocusable(false);\n\t\tbChargerListe.setFocusable(false);\n\t\tbImprimerPresents.setFocusable(false);\n\t\tbImprimerJoueurs.setFocusable(false);\t\n\t\t\n\t\t\n\t\tselectDefaultValue();\n\t\tgetContentPane().add(BorderLayout.CENTER, panel);\t\t\n\t\tsetResizable(true);\n\t\tsetMaximizable(true);\n\t\tsetIconifiable(true);\n\t\t//pack();\n\t}", "private void export(final TableFacade tableFacade) {\r\n\t\t tableFacade.setColumnProperties(\"id.invPexProductosExistencia.invArtArticulo.artCodigo\",\r\n\t\t\t\t\"id.invPexProductosExistencia.invArtArticulo.artNombre\",\r\n\t\t\t\t\"eboCantidadProducto\",\"eboSaldo\");\r\n\t\tTable table = tableFacade.getTable();\r\n\t\t\r\n\t\t//---- Titulo de la tabla\r\n\t\ttable.setCaptionKey(\"tbl.abo.caption\");\r\n\t\t\r\n\t\tRow row = table.getRow();\r\n\t\tColumn nombreColumna = row.getColumn(\"id.invPexProductosExistencia.invArtArticulo.artCodigo\");\r\n\t\tnombreColumna.setTitleKey(\"tbl.abo.id.invArtArticulo.artCodigo.x\");\r\n\r\n\t\tnombreColumna = row.getColumn(\"id.invPexProductosExistencia.invArtArticulo.artNombre\");\r\n\t\tnombreColumna.setTitleKey(\"tbl.abo.id.invArtArticulo.artNombre.x\");\r\n\t\t\r\n\t\tnombreColumna = row.getColumn(\"eboCantidadProducto\");\r\n\t\tnombreColumna.setTitleKey(\"tbl.abo.eboCantidadProducto\");\r\n\t\t\r\n\t\tnombreColumna = row.getColumn(\"eboSaldo\");\r\n\t\tnombreColumna.setTitleKey(\"tbl.abo.eboSaldo\");\r\n\t\tnombreColumna.getCellRenderer().setCellEditor(new CellEditor() {\r\n\t\t\tpublic Object getValue(Object item, String property, int rowcount) {\r\n\t\t\t\tObject value = new BasicCellEditor().getValue(item, property,\r\n\t\t\t\t\t\trowcount);\r\n\t\t\t\tInvEboExistenciaBodega existenciaBodega = (InvEboExistenciaBodega) item;\r\n\t\t\t\t\r\n\t\t\t\tvalue = Format.formatDinero(existenciaBodega.getEboSaldo());\r\n\t\t\t\treturn value;\r\n\t\t\t}\r\n\t\t});\r\n\t\t\r\n\t\ttableFacade.render();\r\n\t}", "public void echantillon_zone(){\n\n JLabel lbl_Echantillon = new JLabel(\"Offre d'\\u00E9chantillons :\");\n lbl_Echantillon.setBounds(340, 170, 119, 16);\n add(lbl_Echantillon);\n\n // MODEL\n final DefaultTableModel model = new DefaultTableModel();\n final DefaultTableCellRenderer rightRenderer = new DefaultTableCellRenderer();\n rightRenderer.setHorizontalAlignment(JLabel.RIGHT);\n Object[][] o = new Object[sizeVector][2];\n for(int i = 0; i < sizeVector; i++){\n o[i][0] = medicaments.get(i)[0];\n o[i][1] = medicaments.get(i)[1];\n }\n // TABLE DATA\n model.setDataVector(o, new Object[]{\"M\\u00E9dicament\",\"Qt\\u00E9\"});\n\n\n // TABLE\n result_table = new JTable(model);\n result_table.setBounds(475, 170, 200, 150);\n result_table.getColumnModel().getColumn(1).setMaxWidth(40);\n result_table.getColumnModel().getColumn(1).setCellRenderer(rightRenderer);\n result_table.setEnabled(false);\n add(result_table);\n\n\n // SCROLLPANE\n JScrollPane apne= new JScrollPane(result_table);\n apne.setBounds(475, 170, 200, 150);\n add(apne);\n\n\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n jPanel1 = new javax.swing.JPanel();\n jLabel1 = new javax.swing.JLabel();\n jLabel2 = new javax.swing.JLabel();\n jLabel3 = new javax.swing.JLabel();\n jLabel4 = new javax.swing.JLabel();\n jLabel5 = new javax.swing.JLabel();\n destino = new javax.swing.JComboBox<>();\n dia = new javax.swing.JComboBox<>();\n aerolinea = new javax.swing.JComboBox<>();\n precio = new javax.swing.JComboBox<>();\n tiempo = new javax.swing.JComboBox<>();\n hora = new javax.swing.JComboBox<>();\n jLabel6 = new javax.swing.JLabel();\n jButton1 = new javax.swing.JButton();\n jButton2 = new javax.swing.JButton();\n jButton3 = new javax.swing.JButton();\n jButton4 = new javax.swing.JButton();\n jScrollPane1 = new javax.swing.JScrollPane();\n tabla = new javax.swing.JTable();\n jLabel7 = new javax.swing.JLabel();\n jLabel8 = new javax.swing.JLabel();\n jLabel9 = new javax.swing.JLabel();\n id = new javax.swing.JTextField();\n nombre = new javax.swing.JTextField();\n cel = new javax.swing.JTextField();\n jButton5 = new javax.swing.JButton();\n\n setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);\n\n jPanel1.setBackground(new java.awt.Color(255, 255, 255));\n\n jLabel1.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/logo JS.jpg\"))); // NOI18N\n\n jLabel2.setBackground(new java.awt.Color(255, 255, 255));\n jLabel2.setFont(new java.awt.Font(\"Dialog\", 1, 36)); // NOI18N\n jLabel2.setForeground(new java.awt.Color(0, 102, 153));\n jLabel2.setText(\"Aerolinea\");\n\n jLabel3.setBackground(new java.awt.Color(255, 255, 255));\n jLabel3.setFont(new java.awt.Font(\"Dialog\", 1, 36)); // NOI18N\n jLabel3.setForeground(new java.awt.Color(0, 102, 153));\n jLabel3.setText(\"Horarios\");\n\n jLabel4.setBackground(new java.awt.Color(255, 255, 255));\n jLabel4.setFont(new java.awt.Font(\"Dialog\", 1, 36)); // NOI18N\n jLabel4.setForeground(new java.awt.Color(0, 102, 153));\n jLabel4.setText(\"Precios\");\n\n jLabel5.setBackground(new java.awt.Color(255, 255, 255));\n jLabel5.setFont(new java.awt.Font(\"Dialog\", 1, 36)); // NOI18N\n jLabel5.setForeground(new java.awt.Color(0, 102, 153));\n jLabel5.setText(\"Destinos\");\n\n destino.setBackground(new java.awt.Color(204, 204, 204));\n destino.setFont(new java.awt.Font(\"Dialog\", 1, 14)); // NOI18N\n destino.setForeground(new java.awt.Color(51, 51, 51));\n destino.setModel(new javax.swing.DefaultComboBoxModel<>(new String[] { \"Elija una opcion\", \"Madrid\", \"CDMX\", \"Panamá\", \"Roma\", \"USA\", \"Londres\" }));\n destino.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n destinoActionPerformed(evt);\n }\n });\n\n dia.setBackground(new java.awt.Color(204, 204, 204));\n dia.setFont(new java.awt.Font(\"Dialog\", 1, 14)); // NOI18N\n dia.setForeground(new java.awt.Color(51, 51, 51));\n dia.setModel(new javax.swing.DefaultComboBoxModel<>(new String[] { \"Elija una opcion\", \"Lunes\", \"Martes\", \"Miércoles\", \"Jueves\", \"Viernes\", \"Sábado \", \"Domingo\" }));\n\n aerolinea.setBackground(new java.awt.Color(204, 204, 204));\n aerolinea.setFont(new java.awt.Font(\"Dialog\", 1, 14)); // NOI18N\n aerolinea.setForeground(new java.awt.Color(51, 51, 51));\n aerolinea.setModel(new javax.swing.DefaultComboBoxModel<>(new String[] { \"Elija una opcion\", \"American Airlines\", \"Avianca\", \"Delta\", \"Iberia\", \"Interjet\", \"Volaris\" }));\n aerolinea.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n aerolineaActionPerformed(evt);\n }\n });\n\n precio.setBackground(new java.awt.Color(204, 204, 204));\n precio.setFont(new java.awt.Font(\"Dialog\", 1, 14)); // NOI18N\n precio.setForeground(new java.awt.Color(51, 51, 51));\n precio.setModel(new javax.swing.DefaultComboBoxModel<>(new String[] { \"Elija una opcion\", \"$200\", \"$300\", \"$400\", \"$500\", \"$600\", \"$700\" }));\n\n tiempo.setBackground(new java.awt.Color(204, 204, 204));\n tiempo.setFont(new java.awt.Font(\"Dialog\", 1, 14)); // NOI18N\n tiempo.setForeground(new java.awt.Color(51, 51, 51));\n tiempo.setModel(new javax.swing.DefaultComboBoxModel<>(new String[] { \"Elija una opcion\", \"Diurno\", \"Nocturno\" }));\n\n hora.setBackground(new java.awt.Color(204, 204, 204));\n hora.setFont(new java.awt.Font(\"Dialog\", 1, 14)); // NOI18N\n hora.setForeground(new java.awt.Color(51, 51, 51));\n hora.setModel(new javax.swing.DefaultComboBoxModel<>(new String[] { \"Elija una opcion\", \"12:00\", \"01:00\", \"02:00\", \"03:00\", \"04:00\", \"05:00\", \"06:00\", \"07:00\", \"08:00\", \"09:00\", \"10:00\", \"11:00\" }));\n\n jLabel6.setBackground(new java.awt.Color(255, 255, 255));\n jLabel6.setFont(new java.awt.Font(\"DialogInput\", 3, 36)); // NOI18N\n jLabel6.setForeground(new java.awt.Color(0, 102, 153));\n jLabel6.setText(\"Arme el vuelo a su gusto:\");\n\n jButton1.setBackground(new java.awt.Color(255, 255, 255));\n jButton1.setFont(new java.awt.Font(\"Dialog\", 1, 14)); // NOI18N\n jButton1.setForeground(new java.awt.Color(0, 102, 153));\n jButton1.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/btnInicio(Imagen).png\"))); // NOI18N\n jButton1.setText(\"Volver\");\n jButton1.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n jButton1ActionPerformed(evt);\n }\n });\n\n jButton2.setBackground(new java.awt.Color(255, 255, 255));\n jButton2.setFont(new java.awt.Font(\"Dialog\", 1, 14)); // NOI18N\n jButton2.setForeground(new java.awt.Color(0, 102, 153));\n jButton2.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/btnGuardar(Imagen).png\"))); // NOI18N\n jButton2.setText(\"Reservar\");\n jButton2.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n jButton2ActionPerformed(evt);\n }\n });\n\n jButton3.setBackground(new java.awt.Color(255, 255, 255));\n jButton3.setFont(new java.awt.Font(\"Dialog\", 1, 14)); // NOI18N\n jButton3.setForeground(new java.awt.Color(0, 102, 153));\n jButton3.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/btnSalir(Imagen).png\"))); // NOI18N\n jButton3.setText(\"Cancelar\");\n jButton3.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n jButton3ActionPerformed(evt);\n }\n });\n\n jButton4.setBackground(new java.awt.Color(255, 255, 255));\n jButton4.setFont(new java.awt.Font(\"Dialog\", 1, 14)); // NOI18N\n jButton4.setForeground(new java.awt.Color(0, 102, 153));\n jButton4.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/btnLimpiar(Imagen).png\"))); // NOI18N\n jButton4.setText(\"Limpiar\");\n jButton4.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n jButton4ActionPerformed(evt);\n }\n });\n\n tabla.setBackground(new java.awt.Color(204, 204, 204));\n tabla.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(0, 102, 153)));\n tabla.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n\n },\n new String [] {\n \"Nombre\", \"Identificación\", \"Celular\", \"Aerolínea\", \"Destino\", \"Día\", \"Tiempo\", \"Hora\", \"Precio\"\n }\n ));\n jScrollPane1.setViewportView(tabla);\n\n jLabel7.setBackground(new java.awt.Color(255, 255, 255));\n jLabel7.setFont(new java.awt.Font(\"Dialog\", 1, 14)); // NOI18N\n jLabel7.setForeground(new java.awt.Color(0, 102, 153));\n jLabel7.setText(\"Nombre completo:\");\n\n jLabel8.setBackground(new java.awt.Color(255, 255, 255));\n jLabel8.setFont(new java.awt.Font(\"Dialog\", 1, 14)); // NOI18N\n jLabel8.setForeground(new java.awt.Color(0, 102, 153));\n jLabel8.setText(\"N` de indentificación\");\n\n jLabel9.setBackground(new java.awt.Color(255, 255, 255));\n jLabel9.setFont(new java.awt.Font(\"Dialog\", 1, 14)); // NOI18N\n jLabel9.setForeground(new java.awt.Color(0, 102, 153));\n jLabel9.setText(\"N` de celular\");\n\n id.setBackground(new java.awt.Color(204, 204, 204));\n\n nombre.setBackground(new java.awt.Color(204, 204, 204));\n\n cel.setBackground(new java.awt.Color(204, 204, 204));\n\n jButton5.setBackground(new java.awt.Color(255, 255, 255));\n jButton5.setFont(new java.awt.Font(\"Dialog\", 1, 14)); // NOI18N\n jButton5.setForeground(new java.awt.Color(0, 102, 153));\n jButton5.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/btnSalida(Imagen).png\"))); // NOI18N\n jButton5.setText(\"Salir\");\n jButton5.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n jButton5ActionPerformed(evt);\n }\n });\n\n javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);\n jPanel1.setLayout(jPanel1Layout);\n jPanel1Layout.setHorizontalGroup(\n jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addComponent(jLabel1, javax.swing.GroupLayout.PREFERRED_SIZE, 649, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(52, 52, 52))\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel1Layout.createSequentialGroup()\n .addComponent(jLabel6)\n .addGap(73, 73, 73)))\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addComponent(jButton2)\n .addGap(50, 50, 50)\n .addComponent(jButton3)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(jButton4)\n .addGap(61, 61, 61)\n .addComponent(jButton1)\n .addGap(64, 64, 64)\n .addComponent(jButton5))\n .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 801, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGap(0, 25, Short.MAX_VALUE))\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addGap(98, 98, 98)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)\n .addComponent(jLabel8)\n .addComponent(jLabel7)\n .addComponent(jLabel9))\n .addGap(55, 55, 55)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(nombre, javax.swing.GroupLayout.PREFERRED_SIZE, 289, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(id, javax.swing.GroupLayout.PREFERRED_SIZE, 289, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(cel, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.PREFERRED_SIZE, 289, javax.swing.GroupLayout.PREFERRED_SIZE)))\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel1Layout.createSequentialGroup()\n .addComponent(jLabel2)\n .addGap(26, 26, 26))\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addComponent(aerolinea, javax.swing.GroupLayout.PREFERRED_SIZE, 153, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(34, 34, 34)))\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(destino, javax.swing.GroupLayout.PREFERRED_SIZE, 153, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jLabel5))\n .addGap(18, 18, 18)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(dia, javax.swing.GroupLayout.PREFERRED_SIZE, 153, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(tiempo, javax.swing.GroupLayout.PREFERRED_SIZE, 153, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(hora, javax.swing.GroupLayout.PREFERRED_SIZE, 153, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jLabel3, javax.swing.GroupLayout.Alignment.TRAILING))\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addGap(26, 26, 26)\n .addComponent(jLabel4))\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addGap(18, 18, 18)\n .addComponent(precio, javax.swing.GroupLayout.PREFERRED_SIZE, 153, javax.swing.GroupLayout.PREFERRED_SIZE)))))\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n );\n jPanel1Layout.setVerticalGroup(\n jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addContainerGap()\n .addComponent(jScrollPane1))\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addComponent(jLabel6, javax.swing.GroupLayout.PREFERRED_SIZE, 102, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(12, 12, 12)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel2)\n .addComponent(jLabel5)\n .addComponent(jLabel3)\n .addComponent(jLabel4))\n .addGap(18, 18, 18)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(aerolinea, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(dia, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(destino, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(precio, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))\n .addGap(37, 37, 37)\n .addComponent(tiempo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(44, 44, 44)\n .addComponent(hora, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(26, 26, 26)\n .addComponent(jLabel1)))\n .addGap(18, 18, 18)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jLabel7)\n .addComponent(nombre, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addGap(18, 18, 18)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jButton1)\n .addComponent(jButton3, javax.swing.GroupLayout.PREFERRED_SIZE, 48, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jButton4, javax.swing.GroupLayout.PREFERRED_SIZE, 48, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jButton2, javax.swing.GroupLayout.PREFERRED_SIZE, 51, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jButton5, javax.swing.GroupLayout.PREFERRED_SIZE, 51, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel1Layout.createSequentialGroup()\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 23, Short.MAX_VALUE)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel8)\n .addComponent(id, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGap(24, 24, 24)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel9)\n .addComponent(cel, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGap(30, 30, 30))))\n );\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());\n getContentPane().setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()\n .addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(0, 0, Short.MAX_VALUE))\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()\n .addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(0, 0, Short.MAX_VALUE))\n );\n\n pack();\n }", "private void IniciarTabla(){\n \n // limpia los datos de los Label y los datos relacionados a la actualizacion de los datos e inhabilita y habilitar botones\nthis.jLabelId.setText(\"Id\");\nthis.jnombre.setText(\"\");\ngrabarCambios.setEnabled(false);\njBotonAgregar.setEnabled(true);\n\n DefaultTableModel dfm = new DefaultTableModel();\n tabla = this.jTabla;\n tabla.setModel(dfm);\n \n // agrega los datos al index de la tabla \n dfm.setColumnIdentifiers(new Object[]{\"id\",\"Comuna\",\"Estado\"});\n Conexion cn = new Conexion();\n rs = cn.SeleccionarTodosComunas();\n try{\n // se recorre rs donde estan los resultados de la busqueda de los datos de la tabla comuna\n while(rs.next()){\n String activo =\"\";\n if (rs.getInt(\"COM_ESTADO\")==1) {\n activo = \"activo\";\n } else {\n activo = \"no activo\";};\n // se agrega la fila con los datos de la columna \n dfm.addRow(new Object[]{rs.getInt(\"COM_ID\"),rs.getString(\"COM_NOMBRE\"),activo});\n }\n \n } catch(Exception e){\n System.out.println(\"Error Revisar funcion TableModel\" + e);\n }\n }" ]
[ "0.70732653", "0.67495346", "0.67413056", "0.6714875", "0.6609138", "0.65617585", "0.65610385", "0.6532698", "0.6484529", "0.64743763", "0.63734514", "0.636235", "0.63552046", "0.6353111", "0.6347577", "0.63397175", "0.6299014", "0.6290655", "0.6280261", "0.625113", "0.6235713", "0.62062365", "0.6177934", "0.61720425", "0.6168188", "0.6159837", "0.61571646", "0.61563134", "0.6155172", "0.6131512", "0.6097478", "0.6094304", "0.6086136", "0.60834587", "0.6063835", "0.6054259", "0.6023792", "0.6020249", "0.6019676", "0.6007262", "0.5998138", "0.59950966", "0.59915894", "0.5975346", "0.5975307", "0.5975099", "0.5965041", "0.5957112", "0.5949978", "0.5940105", "0.59361637", "0.5932371", "0.59312254", "0.5921592", "0.59210396", "0.5918445", "0.591771", "0.5910686", "0.5907636", "0.59075814", "0.59070235", "0.58963525", "0.5889004", "0.58883154", "0.58777136", "0.5870797", "0.5870354", "0.586683", "0.5863", "0.5860724", "0.5854661", "0.58545595", "0.5848451", "0.5843077", "0.5842419", "0.5841315", "0.5835482", "0.5833612", "0.58296835", "0.5826956", "0.582513", "0.582109", "0.58191526", "0.5808912", "0.58042634", "0.58033943", "0.5801946", "0.58005923", "0.5799833", "0.5797774", "0.57965595", "0.5793162", "0.5789271", "0.57878476", "0.5783135", "0.5782003", "0.57812876", "0.5781139", "0.57801545", "0.5775846" ]
0.65889823
5
/ Metodo main de la aplicacion.
public static void main(String[] args) { latch = new CountDownLatch(2); new InitApp(); try { latch.await(); } catch (InterruptedException e2) { e2.printStackTrace(); } latch = new CountDownLatch(1); m = new MainWindow(); try { latch.await(); } catch (InterruptedException e3) { e3.printStackTrace(); } m.setVisible(true); // Abrimos la ventana principal latch = new CountDownLatch(1); if (Main.numTaules == 0) new ConfigTablesDialog(latch).setVisible(true); else latch.countDown(); latch = new CountDownLatch(1); m.loadTickets(); try { latch.await(); } catch (InterruptedException e1) { e1.printStackTrace(); } m.resetUIForUpdates(); m.getTablesFrame().onTableNumChangeCreateButtons(); // Abrimos el server try { MainServer mS = new MainServer(m); } catch (ClassNotFoundException | IOException | SQLException e) { e.printStackTrace(); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static void main() {\n \n }", "private Main() {\n\n super();\n }", "public static void main(){\n\t}", "public static void main()\n\t{\n\t}", "public static void main(String[] args) {\r\n \t\r\n // Creates new controller named the main controller\r\n GlobalResources.MainControl = new Control();\r\n // Starts main application\r\n GlobalResources.MainControl.StartApplication();\r\n }", "Main ()\n\t{\n\t\tview = new View ();\t\t\n\t\tmodel = new Model(view);\n\t\tcontroller = new Controller(model, view);\n\t}", "public Main() {\n \n \n }", "public Main() {\n\t\tsuper();\n\t}", "public Main() {\r\n\t\tsuper();\r\n\t\tinitialize();\r\n\r\n\t}", "public static void main(String[] args){\n\t\tView view = new View();\r\n\t\tDatabaseInteraction model = new DatabaseInteraction();\r\n\r\n\t\t//Initialize controller. \r\n\t\tController controller = new Controller(view,model);\r\n\r\n\t\t//Connect database, start user interaction, and let the controller respond to user options. \r\n\t\tmodel.connectDatabase();\r\n\t\tcontroller.userInteracion();\r\n\t\tcontroller.respondToUserOption();\r\n\r\n\t}", "public static void main(String[] args) {\n mainController controll = new mainController(\"127.0.0.1\");\n MainFrame mf = MainFrame.getInstance();\n mf.setController(controll);\n mf.setVisible(true);\n\n //메인메뉴 띄우기\n mf.changeView(Mode.MAIN);\n }", "public main() {\n initComponents();\n \n }", "public static void main(String args []){\n Vista miVista=new Vista();\n ListaEstudiantes miListaEstudiantes=new ListaEstudiantes();\n Grupo miGrupo=new Grupo();\n Controlador miControlador=new Controlador(miVista,miListaEstudiantes,miGrupo);\n miControlador.iniciar();\n\n }", "public static void main(String[] args) { \n\t\t usuarios=ArchivoJSON.LeerData();\n\t\t \t\t \n\t\t EventQueue.invokeLater(new Runnable() {\n\t\t\t\tpublic void run() {\n\t\t\t\t\ttry {\n\t\t\t\t\t\tEjecutarSegundoPlano API = new EjecutarSegundoPlano();\n\t\t\t\t\t\tAPI.execute();\n\t\t\t\t//\t\tSoloMonedasCirculantes();\n\t\t\t\t\t\tRegistrarUsuario frame = new RegistrarUsuario();\n\t\t\t\t\t\tframe.setLocationRelativeTo(null);\n\t\t\t\t\t\tframe.setVisible(true);\t\t\t\n\t\t\t\t\t} catch (Exception e) {\n\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t});\n }", "private Main ()\n {\n super ();\n }", "public static void main() {\n }", "public static void main(String[] args) {\n\t\tLabel saludoLabel = new Label();\n\t\tsaludoLabel.setText(\"Aquí saldra el saludo\");\n\t\tsaludoLabel.setBounds(20, 20, 120, 50); //x, y, ancho alto\n\t\t\n\t\t// creamos un botón para saludar\n\t\tButton saludarButton = new Button();\n\t\tsaludarButton.setLabel(\"Saludar\");\n\t\tsaludarButton.setBounds(20, 80, 120, 30); //x, y, ancho alto\n\t\t//Establecemos un listenes para la pulsación del botón\n\t\tsaludarButton.addActionListener(e -> saludoLabel.setText(\"¡¡¡Hola Mundo!!!\")); //Mostramos el saludo en la etiqueta\n\t\t//panel (contenedor) que contiene etiqueta y botón\n\t\tPanel rootPanel = new Panel();\n\t\trootPanel.setLayout(null);\n\t\trootPanel.add(saludoLabel);\n\t\trootPanel.add(saludarButton);\n\t\t\n\t\t//ventana\n\t\tFrame frame = new Frame();\n\t\tframe.setTitle(\"Hola Mundo\");\n\t\tframe.setSize(320, 200);\n\t\tframe.setResizable(false);\n\t\tframe.setLocationRelativeTo(null);\n\t\tframe.add(rootPanel);\n\t\tframe.addWindowListener(new WindowAdapter() {\n\t\t\t@Override\n\t\t\tpublic void windowClosing(WindowEvent e) {\n\t\t\t\tframe.dispose();\n\t\t\t}\n\t\t});\n\t\t\n\t\tframe.setVisible(true);\n\t\t\n\t}", "public static void main(String []args){\n\n }", "public static void main(String[]args) {\n\t\n\t\t\n\n}", "public static void main (String []args){\n }", "public static void main(String[] args) {\n MainIntrence mainintrence = new MainIntrence();\r\n\r\n\r\n\r\n }", "public static void main(String[] args){\n\n main_menu();\n\n }", "public ProgramWilmaa()\n\t{\n\t}", "void startup();", "void startup();", "public Main() {\r\n\t}", "public static void main(String[] args) {\r\n rellenarDatos();\r\n mostrarTodosLosProductos();\r\n mostrarMediaGraduacionBebidasAlcoholicas();\r\n }", "public static void main(String[] args) {\n\t\t\tdoctorFile=new FileUtil<>();\n\t\t\tmedicineFile=new FileUtil<>();\n\t\t\tregistrantionController=new RegistrationController();\n\t\t\t\n\t\t\t/**\n\t\t\t * 将医生信息存储到“医生信息.txt”文件中\n\t\t\t */\n\n\t\t\tDoctorController doctorContoller=new DoctorController();\n\t doctorFile.fileWrite(doctorContoller.getDoctors(), \"医生信息.txt\");\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t/**\n\t\t\t * 将药品信息存储到“药品信息.txt”文件中\n\t\t\t */\n\t\t\tMedicineController medicineController=new MedicineController();\n\t\t\tmedicineFile.fileWrite(medicineController.medicineList,\"药品信息.txt\");\n\t\t\t\n\t\t\tMainWindow mainWindow=new MainWindow();\n\t\t\tmainWindow.main(null);\n\t\t\t\n\t\t\t/**\n\t\t\t * 将挂号信息存储到“挂号详情.txt”文件中\n\t\t\t */\n\t\t\tregistrantionController.addRgistrationToFile();\n\t\t\t\n\t\t\t\n\t\t}", "public static void main(String[] args){\n\n MyApp myApp = new MyApp(); //1\n myApp.runMyApp(); //2\n System.out.println(\"End of Program\"); //3\n }", "private Main() {}", "public static void main(String []args){\n }", "public static void main(String []args){\n }", "public void startApp()\r\n\t{\n\t}", "public void main(){\n }", "public static void main(String[] args) {\n C.saluta();\n\n }", "public static void main(String[] args) {\n \n \n \n \n }", "public static void main(String[] args) {\n try{\r\n listaProducto = new ArrayList();\r\n\r\n altaProducto();\r\n listarProducto();\r\n\r\n new VentanaPrincipal().setVisible(true);\r\n }\r\n catch(Exception e){\r\n JOptionPane.showMessageDialog(null, e.getClass());\r\n }\r\n }", "public MainEntry() {\n\t\tthis.taskController = new Controller();\n\t}", "public void startup(){}", "private Main() {\n }", "public static void main(String[] args)\r\n {\n\t\t System.out.println(\"************* Welocome To My Application ************* \");\r\n\t\t MainMenu();\r\n }", "public static void main(String[] args) {\r\n\t\tjava.awt.EventQueue.invokeLater(new Runnable() {\r\n\t\t\tpublic void run() {\r\n\t\t\t VentanaPrincipal = new CInterfazGrafica();\r\n\t\t\t\tVentanaPrincipal.setVisible(true);\r\n\t\t //ColaEntrada Cola1 = new ColaEntrada();\r\n\t\t //ColaSalida Cola2 = new ColaSalida(); \t\r\n\t\t //InterfazHWVer3 Maurix = new InterfazHWVer3(Cola1, Cola2, VentanaPrincipal);\r\n\t\t\t}\r\n\t });\r\n\t}", "public void start()\n {\n uploadDataFromFile();\n menu.home();\n home();\n }", "public MainEntryPoint() {\r\n\r\n }", "public static void main(String []args){\n miFichero = new Fichero(\"peliculas.xml\");\n //cargamos los datos del fichero\n misPeliculas = (ListaPeliculas) miFichero.leer();\n\n //si no habia fichero\n\n if(misPeliculas == null) {\n misPeliculas = new ListaPeliculas();\n }\n int opcion;\n do{\n mostrarMenu();\n opcion = InputData.pedirEntero(\"algo\");\n switch (opcion){\n case 1:\n altaPelicula();\n break;\n case 2:\n break;\n case 3:\n break;\n case 4:\n break;\n }\n\n }while(opcion!= 0);\n }", "public static void main(String[] args) {\n\t\tAbstractDataHandlerFactory dataHandlerFactory = DataHandler.getDataHandlerInstance(); \n\t\t\n\t\t// Create a Controller object to begin the application and control code flow \n\t\tController control = new Controller(dataHandlerFactory);\t\n\t}", "public void Main(){\n }", "public static void main(String[] args) {\n \r\n MenuPrincipal iniciar=new MenuPrincipal();\r\n iniciar.mostrarMenu();\r\n \r\n \r\n }", "public static void main(String[] args) {\n\t\tVue vu= new Vue();\n\t\tvu.init();\n\t\tModel m= new Model();\t\t\n\t\tControleur con = new Controleur(m, vu);\n\t\t\n\n\t}", "public static void main(String args[]) throws Exception\n {\n \n \n \n }", "public static void main(String[] args) {\n//\n// controller.setSoldierRank(0, \"Turai\");\n// controller.addModel(new Model(2, \"Lera\", \"RavSamal\"));\n// controller.updateViews();\n\n Controller controller = new Controller();\n controller.addModel(new Model(1, \"Gal\", \"Citizen\"));\n controller.addModel(new Model(12121, \"bubu\", \"Smar\"));\n controller.addModel(new Model(624, \"Groot\", \"Tree\"));\n controller.addModel(new Model(-10, \"Deadpool\", \"Awesome\"));\n controller.addModel(new Model(100, \"Nikita\", \"Citizen\"));\n\n controller.presentUI();\n\n controller.updateViews();\n }", "public static void main(String[] args) {\n rellenarDatos();\n \n //ejercicio01();\n //ejercicio02();\n ejercicio03();\n }", "public static void main(String[] args) {\n Kendaraan.data();\n }", "public static void main(){\n\t\tint option = getUserOption();\n\t\t/** switch case option start below */\n\t\tswitch (option){\n\t\t\tcase 1 : ToScreen.listEmployee(employee.getAllEmployee(), true); main();\n\t\t\t\tbreak;\n\t\t\tcase 2 : listStaffByCategory();\n\t\t\t\tbreak;\n\t\t\tcase 3 : ToScreen.listAdminStaffTask(employee.getAllAdminStaff(), true);main();\n\t\t\t\tbreak;\n\t\t\tcase 4 : searchStaffByName();\n\t\t\t\tbreak;\n\t\t\tcase 5 : ToScreen.listAnimal(animals.getAllAnimals(), true); main();\n\t\t\t\tbreak;\n\t\t\tcase 6 : ListAnimalByType();\n\t\t\t\tbreak;\n\t\t\tcase 7 : searchAnimalByName();\n\t\t\t\tbreak;\n\t\t\tcase 8 : MenuReception.main();\n\t\t\t\tbreak;\n\t\t\tcase 9 : System.exit(0);\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\tmain();\n\t\t}\n\t}", "public static void main(String[] args) {\n InitStart.Init();\r\n new MainMenuView().displayMenu();\r\n\r\n }", "public static void main(String[] args) {\n\t\tJFrame frame = new JFrame();\n\t\tSistemaAdministracionGanadera sistema=SistemaAdministracionGanadera.getInstancia();\n\t\tframe.getContentPane().add(new NuevaCategoriaView(sistema));\n\t\tframe.setDefaultCloseOperation(WindowConstants.DISPOSE_ON_CLOSE);\n\t\tframe.pack();\n\t\tframe.setVisible(true);\n\t}", "public static void main(String[] args){\n ClienteController obj1 = new ClienteController();\r\n //chamar o método inserir desse objeto\r\n obj1.inserir(11, \"Pietra\");\r\n obj1.inserir(12, \"Maila\");\r\n obj1.inserir(13, \"Patricia\");\r\n obj1.mostrarTodosClientes();\r\n //executar e conferir no BD\r\n }", "public Main() {}", "public static void main(String[] args) {\n\t\tEventQueue.invokeLater(new Runnable() {\n\t\t\tpublic void run() {\n\t\t\t\ttry {\n\t\t\t\t\tprinc frame = new princ();\n\t\t\t\t\tframe.setVisible(true);\n\t\t\t\t\tframe.setTitle(\"Storyteller\");\n\t\t\t\t\t//la ventana no se puede redimensionar\n\t\t\t\t\tframe.setResizable(false);\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t//falta hacer que la ventana aparezca en el centrode la pantalla\n\t\t\t\t} catch (Exception e) {\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t}", "public static void main(String[] args) {\n \n }", "public static void main(String[] args) {\n \n }", "public static void main(String[] args) {\n \n }", "public static void main(String[] args) {\n \n }", "public static void main(String[] args) {\n \n }", "public static void main(String[] args) {\n \n }", "public static void main(String[] args) {\r\n// Use for unit testing\r\n }", "public Main() {\n\t\tsuper();\n\t\tInitScreen screen = new InitScreen();\n\t\tpushScreen(screen);\n\t\tUiApplication.getUiApplication().repaint();\n\t}", "public static void main(String[] args) {\n\t\tcontato = new Contato();\n\t\ttry {\n\t\t\tcontato.RecuperarLista();\n\t\t} catch (IOException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t}", "public static void main(String[] args) {\n\n\t\tWindow.startOkno();\n\t\tWindow.zacni.setEnabled(false);\n\n\t\tSystem.out.println(\"Spoustim...\");\n\n\t\tGenerator.generujSouradniceACesty();\n\t\tInputOutput.zapisSouradniceACestyDoSouboru();\n\t\tMatice.vygenerujMatice();\n\n\t\tFile f = new File(InputOutput.MATICE_CEST_SOUBOR);\n\t\tif (f.exists() && !f.isDirectory()) {\n\t\t\tMatice.nactiMaticiNejkratsichCestZeSouboru();\n\t\t} else {\n\t\t\tSystem.out.println(\"Generuji matici nejkratsich cest\");\n\t\t\tMatice.vytvorNejkratsiCesty();\n\t\t\tInputOutput.zapisMaticeNejkratsichCest(Matice.maticeNejkratsichCest);\n\t\t}\n\n\t\tSystem.out.println(\"Pripraveno...\");\n\t\tWindow.zacni.setEnabled(true);\n\t\tWindow.aktualizace.setEnabled(true);\n\t}", "public static void main(String[] args) {\n DatabaseController.login();\r\n\r\n //Log in to email\r\n Email.login();\r\n\r\n //Update local database - in real deployment this would run twice per day, not every startup\r\n SyncMain.main(new String[]{});\r\n\r\n //Load cached data\r\n CSVController.loadFiles();\r\n\r\n //Start GUI\r\n launch(args);\r\n\r\n }", "public static void main(String[] args) \r\n {\r\n Erreur = MenuPrincipal();\r\n if (Erreur != 0)\r\n { //Afficher l'erreur du programme\r\n }\r\n //Le programme ce termine proprement\r\n }", "public static void main(String[] args) {\n \n \n \n\t}", "public static void main(String[] args) {\r\n\t\t\r\n\t\tJFrame frame = new JFrame(\"Solitaire\");\r\n\t\tframe.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\r\n\t\t\r\n\t\tController control = new Controller();\r\n\t\tframe.getContentPane().add(new Panel(control));\r\n\t\tframe.pack();\r\n\t\tframe.setSize(1000,500);\r\n\t\t\r\n\t\tframe.setVisible(true);\r\n\t}", "public static void main(String[] args) {\n\t \t\n\t \t\n\t }", "public static void main(String[] args) {\n\r\n Starter starter = new Starter();\r\n starter.start();\r\n\r\n\r\n }", "public static void main(String[] args) {\n\t\tinicialitzarGUI();\r\n\t\tviewtable();\r\n\t}", "public void myapp() {\n\n\n }", "public static void main(String[] args) {\r\n Burbuja B = new Burbuja ();\r\n B.ordenar();\r\n \r\n \r\n }", "public static void main(String[] args){\n ViewLogin viewLogin = new ViewLogin();\n OuvinteViewLogin ouvinte = new OuvinteViewLogin(viewLogin);\n viewLogin.setLocationRelativeTo(null);\n viewLogin.setVisible(true);\n \n JogadorDAO ddao = new JogadorDAO();\n ddao.listar();\n }", "public static void main(String[] args)\r\t{", "public static void main(String[] args) {\n\t\ttry {\n\t\t\tString status=Allow_log.chek_log();\n\t\t\tif(status.equals(\"active\")){\n\t\t\t\t\n\t\t\t\tLogin_view obj=new Login_view();\n\t\t\t\tobj.buildGUI();\n\t\t\t}\n\t\t\telse if(status.equals(\"inactive\")){\n\t\t\t\tMain_view.main(null);\n\t\t\t}\n\t\t} catch (Exception e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t\tJOptionPane.showMessageDialog(null,\"Database Missing !!!\");\n\t\t}\n\t}", "public static void main(String[] args) {\n staticFiles.location(\"/public\");\n //This will listen to GET requests to /model and return a clean new model\n get(\"/model\", (req, res) -> newModel());\n //This will listen to POST requests and expects to receive a game model, as well as location to fire to\n post(\"/fire/:row/:col\", (req, res) -> fireAt(req));\n //This will listen to POST requests and expects to receive a game model, as well as location to place the ship\n post(\"/placeShip/:id/:row/:col/:orientation\", (req, res) -> placeShip(req));\n }", "public static void main(String[] args) {\n\ntoplama();\n\n\t\t\n\t}", "public static void main(String[] args) {\n \n \n }", "public static void main(String[] args) {\n \n \n }", "public static void main(String[] args) {// mais é o Start Point da aplicação\n\t// estou na classe e dentro do metodo\n\tSystem.out.print(\"Olá mundo\");\n\t\n}", "public static void main(String[] args) {\n staticFiles.location(\"/public\");\n\n //This will listen to GET requests to /model and return a clean new model\n get(\"/model/:Version\", (req, res) -> newModel( req ));\n\n //This will listen to POST requests and expects to receive a game model, as well as location to fire to\n post(\"/fire/:Version/:row/:col/:hard\", (req, res) -> fireAt( req ));\n //This will handle the scan feature\n post(\"/scan/:Version/:row/:col/:hard\", (req, res) -> scan( req ));\n\n //This will listen to POST requests and expects to receive a game model, as well as location to place the ship\n post(\"/placeShip/:Version/:id/:row/:col/:orientation/:hard\", (req, res) -> placeShip( req ));\n }", "private void start() {\n\n\t}", "public static void main(String[] args) {\r\n System.out.println(\"***debut serveur gestion ***\");\r\n new ServeurGestion(50003).fonctionnementService();\r\n \r\n }", "public void factoryMainScreen()\n\t{\n\t\t\n\t}", "public static void main(String args[]){\n\n createConnection();\n\n if (conn == null) {\n System.err.println(\"Failed to establish connection!\");\n }\n\n new App();\n\n }", "public static void main( String[] args )\n\t{\n\t\trunApp();\n\t}", "public static void main(String[] args){\n eLivros handler = new eLivros();\n }", "public static void main(String[] args) {\n\t\t/**Mandamos a llamar el metodo estatico ya que no requiere ser instanciado*/\n\t\tClaseInservible.ejecutarEstatico();\n\t}", "public static void main(String[] args) {\n\t\tSwingUtilities.invokeLater(new Runnable() {\n\t\t\tpublic void run() {\n\t\t\t\tSistema sistema=Sistema.getInstancia();\n\t\t\t\tDatos datos=Datos.getInstancia();\n\t\t\t\tMenu inst = new Menu(sistema);\n\t\t\t\tinst.setLocationRelativeTo(null);\n\t\t\t\tinst.setVisible(true);\n\t\t\t}\n\t\t});\n\t}", "public static void main(String[] args) {\n\t\t\r\n\t\tSystem.out.println(\"Start main\");\r\n\t\tSystem.out.println(\"sum of two num :\"+ new AppManager().sum(5,10));\r\n\t\tSystem.out.println(\"End main\");\r\n\t\t\r\n\t\t\r\n\t}", "public static void main(String[] args) {\n\r\n\t\tClienteView vista = new ClienteView();\r\n\t\tCliente modelo = llenarDatosCliente();\r\n\r\n\t\t// se crea un objeto controlados y se le pasa\r\n\t\t// un model y un view\r\n\t\tClienteControlador controller = new ClienteControlador(modelo, vista);\r\n\r\n\t\t// se muestra los datos del cliente\r\n\t\tcontroller.actualizaVista();\r\n\r\n\t\t// actualizamos un cliente y mostramos los datos de nuevo\r\n\r\n\t\tcontroller.SetNombre(\"Felipe mistico\");\r\n\t\tcontroller.SetApellido(\"Magia\");\r\n\t\tcontroller.setId(6543);\r\n\t\tcontroller.actualizaVista();\r\n\r\n\t}", "public static void main (String [] args){\r\n //Creo el objeto\r\n Formulario Form= new Formulario();\r\n Form.setBounds(0,0,400,550);\r\n Form.setVisible(true);\r\n Form.setLocationRelativeTo(null);\r\n \r\n }", "public MainController() {\n initializeControllers();\n initializeGui();\n runGameLoop();\n }", "public static void main(String[] args) throws Exception {\n\t\t\t\t\t\t\n\t\t\t\t\n\t\t\t}" ]
[ "0.746413", "0.72014195", "0.7132432", "0.7044771", "0.7041134", "0.7033955", "0.702887", "0.6952257", "0.69441396", "0.69207895", "0.6913276", "0.68945086", "0.68842125", "0.6851401", "0.6848329", "0.6781761", "0.67583394", "0.675598", "0.67467254", "0.67357683", "0.6733441", "0.672975", "0.67138815", "0.66999125", "0.66999125", "0.66965246", "0.6690591", "0.66843724", "0.6683225", "0.66523814", "0.6649486", "0.6649486", "0.66484255", "0.66427076", "0.66409683", "0.66372764", "0.6611244", "0.66084814", "0.66016394", "0.6600074", "0.6594639", "0.6589915", "0.65840346", "0.6577199", "0.6577152", "0.6574975", "0.65714085", "0.6565554", "0.6563944", "0.6562991", "0.6562833", "0.65607494", "0.6560675", "0.6540304", "0.6536804", "0.65212387", "0.6520999", "0.6509024", "0.6507985", "0.6506947", "0.6506947", "0.6506947", "0.6506947", "0.6506947", "0.6506947", "0.6501668", "0.65015566", "0.64941835", "0.6493302", "0.64932024", "0.646996", "0.6467719", "0.6464458", "0.64625496", "0.64616203", "0.64546853", "0.6452065", "0.6450982", "0.644491", "0.6444865", "0.6444094", "0.6442651", "0.64409786", "0.64404595", "0.64404595", "0.64387196", "0.6436908", "0.64361733", "0.6435797", "0.64354366", "0.6432651", "0.64246", "0.6423041", "0.64169765", "0.64128536", "0.6411679", "0.64085084", "0.6408281", "0.640392", "0.6403488" ]
0.6462927
73
Only admin role is allowed to edit
private void hideToolbarFromNonAdminUsers(FormLayout formLayout, Layout toolbar) { // TODO AbstractForm in Maddon should have overridden setReadOnly // method that would do this if (SecurityUtils.getSubject().hasRole("admin")) { toolbar.setVisible(true); for (Component component : formLayout) { component.setReadOnly(false); } } else { toolbar.setVisible(false); for (Component component : formLayout) { component.setReadOnly(true); } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n protected String requiredPutPermission() {\n return \"admin\";\n }", "public boolean isAdmin();", "boolean isAdmin();", "@Override\n protected String requiredPostPermission() {\n return \"admin\";\n }", "@Override\n protected String requiredDeletePermission() {\n return \"admin\";\n }", "public boolean isAdmin()\n {\n return admin;\n }", "public boolean isAdmin()\n {\n return admin;\n }", "void ensureAdminAccess() {\n Account currentAccount = SecurityContextHolder.getContext().getAccount();\n if (!currentAccount.isAdmin()) {\n throw new IllegalStateException(\"Permission denied.\");\n }\n }", "private void checkAdminOrModerator(HttpServletRequest request, String uri)\n throws ForbiddenAccessException, ResourceNotFoundException {\n if (isAdministrator(request)) {\n return;\n }\n\n ModeratedItem moderatedItem = getModeratedItem(uri);\n if (moderatedItem == null) {\n throw new ResourceNotFoundException(uri);\n }\n\n String loggedInUser = getLoggedInUserEmail(request);\n if (moderatedItem.isModerator(loggedInUser)) {\n return;\n }\n\n throw new ForbiddenAccessException(loggedInUser);\n }", "@PreAuthorize(\"hasAuthority('ROLE_ADMIN')\")\n @RequestMapping\n public String admin() {\n return \"admin\";\n }", "public boolean isAdmin() {\r\n return admin;\r\n }", "public boolean isAdmin() {\n return admin;\n }", "public boolean getIsAdmin() {\n return isAdmin;\n }", "public boolean isIsAdmin() {\r\n return isAdmin;\r\n }", "public void setEditAuthUserContentAdmin(final boolean val) {\n editAuthUserType |= UserAuth.contentAdminUser;\n }", "boolean isAdminDirect() {\n return isAdministrator;\n }", "public String getAdminRole() {\r\n\t\treturn adminRole;\r\n\t}", "public java.util.ArrayList getEditRoles() {\n\t\tjava.util.ArrayList roles = new java.util.ArrayList();\n\t\troles.add(\"ArendaMainEconomist\");\n\t\troles.add(\"ArendaEconomist\");\n\t\troles.add(\"administrator\");\n\t\treturn roles;\n\t}", "public void setAdmin(boolean value) {\r\n this.admin = value;\r\n }", "public Boolean getCanEdit() {\r\n return getAttributeAsBoolean(\"canEdit\");\r\n }", "public String getPermissionAdmin() {\n return permissionAdmin;\n }", "boolean isAdmin() {\n\n if (isAdminDirect()) {\n return true;\n }\n\n RoleManager rm = getRoleManager();\n Iterator it = getAllRoles().iterator();\n\n while (it.hasNext()) {\n try {\n if (((Grantee) rm.getGrantee(\n (String) it.next())).isAdminDirect()) {\n return true;\n }\n } catch (HsqlException he) {\n throw Trace.runtimeError(Trace.RETRIEVE_NEST_ROLE_FAIL,\n he.getMessage());\n }\n }\n\n return false;\n }", "public boolean asAdmin() {\n\t\treturn asAdmin;\n\t}", "public abstract boolean canEditAccessRights(OwObject object_p) throws Exception;", "public java.util.ArrayList getEditRoles() {\n\tjava.util.ArrayList roles = new java.util.ArrayList();\n\troles.add(\"ArendaMainEconomist\");\n\troles.add(\"ArendaEconomist\");\n\troles.add(\"administrator\");\n\treturn roles;\n}", "public boolean asAdmin() {\n\t\t\treturn asAdmin;\n\t\t}", "void checkAdmin() throws HsqlException {\n Trace.check(isAdmin(), Trace.ACCESS_IS_DENIED);\n }", "public Boolean isModoAdmin() {\r\n\t\treturn this.modoAdmin;\r\n\t}", "public boolean getAdminPermission(boolean isAdmin)\n {\n return isAdmin;\n }", "public java.util.ArrayList getEditRoles() {\n\tjava.util.ArrayList roles = new java.util.ArrayList();\n\troles.add(\"administrator\");\n\troles.add(\"StorageManager\");\n\treturn roles;\n}", "public String getIsAdmin() {\n return isAdmin;\n }", "@Path(\"admin_area\")\n @GET\n @View(\"admin_page.jsp\")\n @RolesAllowed(\"admin\")\n public void sayRole(@Context SecurityContext securityContext) {\n\n logger.info(\"AdminRole :: \" + securityContext.isUserInRole(\"AdminRole\"));\n logger.info(\"admin :: \" + securityContext.isUserInRole(\"admin\"));\n logger.info(\"INFO :: \" + securityContext.isSecure());\n\n }", "public void setAdmin(boolean admin) {\n this.admin = admin;\n }", "public void setAdmin( boolean admin )\n {\n this.admin = admin;\n }", "java.lang.String getAdmin();", "public boolean isAdministrator() {\r\n return doesUserHaveRole(UserRole.ADMINISTRATOR);\r\n }", "@Override\n\tpublic Map<String, Object> isAdminList(Map<String, Object> map) {\n\t\treturn approvalDao.isAdminList(map);\n\t}", "public Integer getIsadmin() {\r\n return isadmin;\r\n }", "public static void ShowAdminPreferences() {\n if (Controller.permission.GetUserPermission(\"EditUser\")) {\n ToggleVisibility(UsersPage.adminWindow);\n } else {\n DialogWindow.NoAccessTo(\"Admin options\");\n }\n }", "@Override\n\tpublic boolean isAdminRole(String userName) throws Exception {\n\t\treturn false;\n\t}", "@RolesAllowed(RoleEnum.ROLE_ADMIN)\n\tpublic Integer saveAdmin(Admin admin);", "boolean makeAdmin(User user);", "@Override\n public boolean userCanAccess(int id) {\n return true;\n }", "private boolean isAdmin() {\n\t\tString name = (String) session.getAttribute(\"name\");\n\t\tif (name.equals(ADMIN)) {\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}", "public boolean systemAdminOnly()\n {\n return false;\n }", "public void invertAdminStatus() {\n this.isAdmin = !(this.isAdmin);\n }", "@WithMockUser(username = \"admin\", authorities = {\"ADMIN\"})\n @Test\n @DisplayName(\"Allowed get books requests for ADMIN role \")\n void getByAdmin() throws Exception {\n mockMvc.perform(get(\"/books\").with(csrf())).andExpect(status().isOk());\n }", "public boolean isAdmin() {\r\n admin = userBean.isAdmin(email);\r\n return admin;\r\n }", "public boolean isDefaultAdminRole() {\r\n\t\treturn this.getName().equals(\"Role_Administrator\");\r\n\t}", "public boolean checkAdmin()\r\n\t{\r\n\t\tboolean admin=false;\r\n\t\tint length=user_records.size();\r\n\t\tfor(int i=0;i<length;i++)\r\n\t\t{\r\n\t\t\tif(((User)user_records.get(i)).get_username().equals(\"administrator\"))\r\n\t\t\t{\r\n\t\t\t\tadmin=true;\r\n\t\t\t\tbreak;\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn admin;\r\n\t}", "public Long getAdminRoleId() {\n\t\treturn this.adminRoleId;\n\t}", "public boolean Admin() {\n\t\tif (choiceAdmin.getSelectedIndex() == 0 || choiceAdmin.getSelectedIndex() == 2) {\n\t\t\tlblCorreoDelAdministrador.setVisible(true);\n\t\t\ttextField.setVisible(true);\n\t\t\tadmin = 0;\n\t\t\treturn false;\n\t\t} else {\n\t\t\tlblCorreoDelAdministrador.setVisible(false);\n\t\t\ttextField.setVisible(false);\n\t\t\tadmin = 1;\n\t\t\treturn true;\n\t\t}\n\t}", "@Override\n\tpublic Collection<? extends GrantedAuthority> getAuthorities() {\n\t\treturn Arrays.asList(new SimpleGrantedAuthority(\"ROLE_ADMIN\"));\n\t}", "public void setIsAdmin(boolean isAdmin) {\r\n this.isAdmin = isAdmin;\r\n }", "@Override\n public boolean canEdit(Context context, Item item) throws java.sql.SQLException\n {\n // can this person write to the item?\n return authorizeService.authorizeActionBoolean(context, item, Constants.WRITE, true);\n }", "@GET\n @Path(\"/admin\")\n public String isAdmin() {\n return ResponseUtil.SendSuccess(response, \"\\\"isAdmin\\\":\\\"\" + SessionUtil.isAdmin(request) + \"\\\"\");\n }", "public void setAdmin(int admin) {\n this.admin = admin;\n }", "@Override\r\n\tpublic Admin changeRole(Admin admin) {\n\t\treturn null;\r\n\t}", "public boolean isCurrentUserAdmin(){\n if (getAdminUserFromId(currentUserId)!=null){\n return true;\n }\n else{\n return false;\n }\n }", "@Test\n @DisplayName(\"delete returns 403 when user is not admin\")\n void delete_Returns403_WhenUserIsNotAdmin() {\n Anime savedAnime = animeRepository.save(AnimeCreator.createAnimeToBeSaved());\n devDojoRepository.save(USER);\n \n ResponseEntity<Void> animeResponseEntity = testRestTemplateRoleUser.exchange(\n \"/animes/admin/{id}\",\n HttpMethod.DELETE,\n null,\n Void.class,\n savedAnime.getId()\n );\n\n Assertions.assertThat(animeResponseEntity).isNotNull();\n \n Assertions.assertThat(animeResponseEntity.getStatusCode()).isEqualTo(HttpStatus.FORBIDDEN);\n }", "default void protectAdmin(@NotNull HttpSession session)\n {\n this.protect(session);\n\n if (!auth(session).isAdmin()) {\n throw new ResponseStatusException(HttpStatus.UNAUTHORIZED, \"Login please as admin\");\n }\n }", "private boolean isUserAnAdmin(String login) {\n EUser user = null;\n try {\n user = eUserController.findUserByLogin(login);\n if (user.getStatus().equals(EUser.statusAdmin)) {\n return true;\n } else {\n return false;\n }\n } catch (Exception ex) {\n return false;\n //throw new AuthenticationException(\"Incorrect login.\");\n }\n }", "void setAdminStatus(User user, boolean adminStatus);", "public boolean canEdit() throws GTClientException\n {\n return isNewEntity();\n }", "public int getAdmin() {\n return admin;\n }", "protected final void runAsAdmin() {\n authenticationTestingUtil.grantAdminAuthority( this.applicationContext );\n }", "@Override\n\tpublic boolean modify(Administrateur admin) {\n\t\ttry\n\t\t{\n\t\t\topenCurrentSessionWithTransaction();\n\t\t\tgetCurrentSession().update(admin);\n\t\t\tcloseCurrentSessionWithTransaction();\n\t\t\treturn true;\n\t\t}\n\t\tcatch(Exception e)\n\t\t{\n\t\t\te.printStackTrace();\n\t\t\treturn false;\n\t\t}\n\t}", "public void removeAdminRole()\r\n {\r\n getSemanticObject().removeProperty(swpres_adminRole);\r\n }", "@Override\n public boolean isRole() {\n return false;\n }", "@Test\n public void testDenyAccessWithRoleCondition() {\n denyAccessWithRoleCondition(false);\n }", "public boolean isAllowed(BaseAction actionClass) {\r\n\t\tint role = getCurrentRole();\r\n\t\tif ((role & User.ROLE_ADMINISTRATOR) != 0) {\r\n\t\t\treturn true;\r\n\t\t}\r\n\t\tInteger requiredRoles = privilegeDef.get(actionClass.getClass().getSimpleName());\r\n\t\treturn requiredRoles == null || (requiredRoles & role) != 0;\r\n\t}", "public boolean isInAdminRole(SecurityContextHolderAwareRequestWrapper securityWrapper) {\n return securityWrapper.isUserInRole(Role.ADMIN.name());\n }", "@Override\n\tpublic void editRole(Role role) {\n\t\trd.editRole(role);\n\t}", "@Action( value=\"editAdmin\", results= {\n @Result(name=SUCCESS, type=\"dispatcher\", location=\"/jsp/editauser.jsp\") } ) \n public String editAdmin() \n {\n \t ActionContext contexto = ActionContext.getContext();\n \t \n \t ResultSet result1=null;\n \t\n \t PreparedStatement ps1=null;\n \t try \n \t {\n \t\t getConection();\n \t\t \n \t if ((String) contexto.getSession().get(\"loginId\")!=null)\n \t {\n String consulta1 =(\"SELECT * FROM USUARIO WHERE nick= '\"+ getNick()+\"';\");\n ps1 = con.prepareStatement(consulta1);\n result1=ps1.executeQuery();\n \n while(result1.next())\n {\n nombre= result1.getString(\"nombre\");\n apellido=result1.getString(\"apellido\");\n nick= result1.getString(\"nick\");\n passwd=result1.getString(\"passwd\");\n mail=result1.getString(\"mail\");\n \t \n }\n rol=\"ADMIN\";\n }\n \t } catch (Exception e) \n \t { \n \t \t System.err.println(\"Error\"+e); \n \t \t return SUCCESS;\n \t } finally\n \t { try\n \t {\n \t\tif(con != null) con.close();\n \t\tif(ps1 != null) ps1.close();\n \t\tif(result1 !=null) result1.close();\n \t\t\n } catch (Exception e) \n \t \t {\n \t System.err.println(\"Error\"+e); \n \t \t }\n \t }\n \t\t return SUCCESS;\n \t}", "public void setCanEdit(Boolean canEdit) {\r\n setAttribute(\"canEdit\", canEdit, true);\r\n }", "private boolean isRoleModified(User user) {\n\t\treturn isAdmin != null && !user.getRole().equals(getRole());\n\t}", "public boolean publicAdmin() {\n try {\n return getConfig().getPublicAdmin();\n } catch (Throwable t) {\n t.printStackTrace();\n return false;\n }\n }", "public abstract OwUIAccessRightsModul getEditAccessRightsSubModul(OwObject object_p) throws Exception;", "public boolean isDashboardEditEnabled() {\n return dashboardEditEnabled;\n }", "public boolean adminContent(User user, Object obj) {\n if (hasGrant(user,\n toGrant(getRelevantURIForSecurity(obj, false, false, false), GrantType.ADMIN_CONTENT))) {\n return true;\n }\n return false;\n }", "public boolean canEditUserData(Session session, User user);", "public void setAdminRole(org.semanticwb.model.Role value)\r\n {\r\n if(value!=null)\r\n {\r\n getSemanticObject().setObjectProperty(swpres_adminRole, value.getSemanticObject());\r\n }else\r\n {\r\n removeAdminRole();\r\n }\r\n }", "public boolean isUpdateRight() {\r\n if (getUser() != null) {\r\n return getUser().hasPermission(\"/vocabularies\", \"u\");\r\n }\r\n return false;\r\n }", "@Test\n public void testDenyAccessWithNegateRoleCondition() {\n denyAccessWithRoleCondition(true);\n }", "private void setPrivilagesToModifyUser(User user){\n\t\tsetFields(false);\n\t\tif (!LoginWindowController.loggedUser.getPermissions().equals(\"administrator\"))\n\t\t{\n\t\t\tif (LoginWindowController.loggedUser.getId() != user.getId()){\n\t\t\t\tif ((user.getPermissions().equals(\"manager\")) \n\t\t\t\t\t\t|| (user.getPermissions().equals(\"administrator\"))){\n\t\t\t\t\tsetFields(true);\n\t\t\t\t}\n\t\t\t\tif (user.getPermissions().equals(\"pracownik\")){\n\t\t\t\t\tsetFields(false);\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\telse {\n\t\t\t\tsetFields(false);\n\t\t\t\tdeleteMenuItem.setDisable(true);\n\t\t\t}\n\t\t}\n\t\telse {\n\t\t\tif (LoginWindowController.loggedUser.getId() == user.getId()){\n\t\t\t\tdeleteMenuItem.setDisable(true);\n\t\t\t\tuserPermissionsBox.setDisable(true);\n\t\t\t}\n\t\t}\n\t}", "@Override\n\tpublic boolean canEdit(IAccounterServerCore clientObject,\n\t\t\tboolean goingToBeEdit) throws AccounterException {\n\t\treturn true;\n\t}", "public boolean hasAdminAccess(User user){\n return (user.hasOneOf(RoleValue.COMPANY_ADMIN, RoleValue.APP_ADMIN) && hasAccess(user));\n }", "@RequestMapping (value = \"/edit\", method = RequestMethod.GET)\r\n public String edit (ModelMap model, Long id)\r\n {\r\n TenantAccount tenantAccount = tenantAccountService.find (id);\r\n Set<Role> roles =tenantAccount.getRoles ();\r\n model.put (\"tenantAccount\", tenantAccount);\r\n if (roles != null && roles.iterator ().hasNext ())\r\n {\r\n model.put (\"roleInfo\", roles.iterator ().next ());\r\n }\r\n return \"tenantAccount/edit\";\r\n }", "public boolean canDo (Player player, Type type, boolean isAdmin){\r\n\t\tif (isAdmin || isOwner(player.getName()))\r\n\t\t\treturn true;\r\n\t\t\r\n\t\tif (!isMember(player.getName()))\r\n\t\t\treturn false; \r\n\t\t\r\n\t\tswitch (type) {\r\n\t\t\tcase ADD:\r\n\t\t\tcase GET:\r\n\t\t\t\treturn true;\r\n\t\t\tdefault:\r\n\t\t\t\treturn false;\r\n\t\t}\r\n\t}", "public int getAdminLevel()\n\t{\n\t\treturn m_adminLevel;\n\t}", "public String getAdminUser() {\n return adminUser;\n }", "@Override\n\tpublic boolean isAdmin() {\n\t\treturn isOnline() && bukkitPlayer.hasPermission(Permission.ADMIN_NODE);\n\t}", "@Override\r\n\tpublic boolean getDeleAdmin(int A_id) {\n\t\treturn adi.deleAdmin(A_id);\r\n\t}", "public boolean isAdmin(String accessToken, String appName) {\n if (accessToken == null) {\n return false;\n }\n AuthAccessInfo access = accessTokens.get(accessToken);\n if (access != null) {\n return !access.getReadonly() && appName.equals(access.getAppName());\n }\n return false;\n }", "public boolean isUserAdmin(int userId){\n if (getAdminUserFromId(userId)!=null){\n return true;\n }\n else{\n return false;\n }\n }", "public void setUserAdmin(boolean isUserAdmin) {\r\n this.userAdmin = isUserAdmin;\r\n }", "public void setIsadmin(Integer isadmin) {\r\n this.isadmin = isadmin;\r\n }", "@RequestMapping(value = \"/{id}/edit\", method = RequestMethod.GET)\n public String editRole(@PathVariable Long id, Model model) {\n model.addAttribute(\"roleEdit\", roleFacade.getRoleById(id));\n return (WebUrls.URL_ROLE+\"/edit\");\n }", "public boolean Admin(int admin) {\n this.flag = admin;\n if (admin == 1) {\n flag = 1;\n return true;\n } else {\n flag = 0;\n return false;\n }\n }", "@Test(expected = AccessDeniedException.class)\n public void permissionDeniedIsThrownWhenUserIsNonOwnerNonAdmin()\n throws Exception {\n Recipe testRecipe = new Recipe();\n testRecipe.setId(1L);\n testRecipe.setOwner(\n new User(\"name\", \"username\", \"password\")\n );\n\n // Given user that is non-owner, non-admin\n User nonOwnerNonAdmin = new User();\n nonOwnerNonAdmin.setRole(new Role(\"ROLE_USER\"));\n\n assertThat(\n \"user is non owner\",\n nonOwnerNonAdmin,\n not(\n is(testRecipe.getOwner())\n )\n );\n\n // Given that when recipeDao.findOne(1L) will be called\n // testRecipe will be returned\n when(\n recipeDao.findOne(anyLong())\n ).thenReturn(testRecipe);\n\n // When checkIfUserIsAdminIsCalled\n recipeService.checkIfUserCanEditRecipe(\n nonOwnerNonAdmin, testRecipe\n );\n\n // Then AccessDeniedException should be thrown\n }", "public boolean isGroupAdmin(int userId){\n return userId == groupAdmin;\n }" ]
[ "0.73202986", "0.6975894", "0.6868764", "0.6816135", "0.66565514", "0.6599878", "0.6599878", "0.6554502", "0.65202254", "0.65056354", "0.6500155", "0.6485542", "0.6468053", "0.6456964", "0.6443095", "0.64421624", "0.64192927", "0.64136577", "0.6413237", "0.64129883", "0.6381997", "0.6374638", "0.63600963", "0.6345794", "0.63281983", "0.6313567", "0.63001955", "0.6287814", "0.6287013", "0.62278885", "0.6200534", "0.6143676", "0.6131368", "0.6124257", "0.6120288", "0.61153793", "0.6112474", "0.6108265", "0.61082375", "0.61071736", "0.6097312", "0.60872793", "0.6069762", "0.6061779", "0.6039856", "0.60170096", "0.59975517", "0.5989392", "0.5984535", "0.5943626", "0.59272254", "0.59160507", "0.5904647", "0.590169", "0.5891723", "0.5883283", "0.5860393", "0.58497787", "0.5835283", "0.58211327", "0.5811868", "0.58023816", "0.5801741", "0.57806635", "0.5774692", "0.5770542", "0.5762479", "0.5755137", "0.57460874", "0.57416093", "0.57388395", "0.5719454", "0.5718921", "0.5716161", "0.5715654", "0.57145387", "0.5714052", "0.5704001", "0.56998926", "0.56909543", "0.5682962", "0.5682447", "0.56605226", "0.5654113", "0.56485593", "0.5642631", "0.56389004", "0.56266814", "0.5624578", "0.562094", "0.5620752", "0.5619452", "0.56051177", "0.5593183", "0.55926114", "0.55919117", "0.55860823", "0.55807906", "0.5577745", "0.5575377", "0.5572649" ]
0.0
-1
Used when changing the port number, reinitializes the DatagramSocket if new port number.
public void setPort(int portNo) { if(port != portNo) { port = portNo; init(); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void initServerSock(int port) throws IOException {\n\tserver = new ServerSocket(port);\n\tserver.setReuseAddress(true);\n }", "public void initialize() throws SocketException{\n defPortUsed = true;\n initializeReal(defPortNumber, defPacketSize);\n }", "public void setupUDP(int port) throws SocketException\n\t{\n\t\tdataSocket = new DatagramSocket(port);\n\t\tUDPRunning = true;\n\t}", "public void setPort(int port);", "public void setPort(int port);", "private void initServerSocket()\n\t{\n\t\tboundPort = new InetSocketAddress(port);\n\t\ttry\n\t\t{\n\t\t\tserverSocket = new ServerSocket(port);\n\n\t\t\tif (serverSocket.isBound())\n\t\t\t{\n\t\t\t\tSystem.out.println(\"Server bound to data port \" + serverSocket.getLocalPort() + \" and is ready...\");\n\t\t\t}\n\t\t}\n\t\tcatch (Exception e)\n\t\t{\n\t\t\tSystem.out.println(\"Unable to initiate socket.\");\n\t\t}\n\n\t}", "public synchronized void initListenInfo(@Nonnull String address, int port) {\n if (listenAddress != null) {\n throw new IllegalStateException(\"Already initialized\");\n }\n this.listenAddress = address;\n this.listenPort = port;\n }", "public void setPort(final int p) {\n this.port = p;\n }", "public void setPort(final int p) {\n this.port = p;\n }", "public void setPort(int p) {\n\t\tport = p;\n\t}", "public Server(int port){\n\t\ttry {\n\t\t\tdatagramSocket = new DatagramSocket(port);\n\t\t\trequest = new byte[280];\n\t\t} catch (SocketException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t\n\t}", "public void port (int port) {\n this.port = port;\n }", "private void setPort(int value) {\n \n port_ = value;\n }", "private void setPort(int value) {\n \n port_ = value;\n }", "public UDPserver(int port) throws SocketException {//constructor\r\n\t\trandom = new Random();\r\n\t\tsocket = new DatagramSocket(port);\r\n\t}", "public void initialize(int otherPort, int _packetSize) throws SocketException{\n defPortUsed = false;\n if(otherPort == 0){\n otherPort = defPortNumber;\n defPortUsed = true;\n }\n\n if(_packetSize == 0){\n _packetSize = defPacketSize;\n }\n initializeReal(otherPort, _packetSize);\n }", "void setServicePort( int p );", "public Communicator(int localPort) throws java.net.SocketException\r\n {\r\n datagramSocket = new DatagramSocket(localPort);\r\n }", "final public void setPort(int port) {\n this.port = port;\n }", "public void setPort(int port) {\n m_Port = port;\n }", "public void setPort(int port) {\r\n this.port = port;\r\n }", "protected void bind(InetAddress host, int port) throws IOException {\n localport = port;\n }", "public final void setRemoteSocketPort(int port){\r\n remoteSocketPort = port;\r\n }", "public ChatRoomServer(int portNumber){\n this.ClientPort = portNumber;\n }", "public void setPort (int port) {\n this.port = port;\n }", "public void setPort(Integer port) {\n this.port = port;\n }", "public void setPort(int value) {\n this.port = value;\n }", "public void setPort(int port) {\r\n\t\tthis.port = port;\r\n\t}", "public void setPort(int port) {\r\n\t\tthis.port = port;\r\n\t}", "public void setPortNumber(int value) {\n this.portNumber = value;\n }", "private static void openServerSocket(int port) {\n\t\ttry {\n\t\t\tserverSocket = new ServerSocket(port);\n\t\t} catch (IOException e) {\n\t\t\tSystem.out.println(\"Server Error\");\n\t\t}\n\t}", "public void setDefaultPort() {\r\n\t\tsetPort(DEFAULT_PORT);\r\n\t}", "public GameServer(int portNum)\n\t{\n\t\tport = portNum;\n\t}", "public void setPort(Integer port) {\n this.port = port;\n }", "public void setPort(Integer port) {\n this.port = port;\n }", "public void setPort(Integer port) {\n this.port = port;\n }", "public void setPort(Integer port) {\n this.port = port;\n }", "public void setPort(Integer port) {\n this.port = port;\n }", "public void setPort(int port) {\n this.port = port;\n }", "public void setPort(int port) {\n this.port = port;\n }", "public void setPort(int port) {\n this.port = port;\n }", "public void setPort(int port) {\n this.port = port;\n }", "public void setPort(int port) {\n this.port = port;\n }", "public void setPort(int port) {\n this.port = port;\n }", "private void run()throws IOException{\r\n Port = portNumb(); \r\n}", "public DefaultTCPServer(int port) throws Exception {\r\n\t\tserverSocket = new ServerSocket(port);\t}", "@Override\n\tpublic void setPort(Integer port) {\n\t\tthis.port=port;\n\t}", "public void init() throws IOException {\r\n try {\r\n serverSocket = new ServerSocket(PORT);\r\n this.running = true;\r\n } catch (IOException e) {\r\n System.out.println(e);\r\n }\r\n }", "Builder setPort(String port);", "public void startNetwork(int port);", "public void setPort(int port) {\n\t\tthis.port = port;\n\t}", "public void setPort(int port) {\n\t\tthis.port = port;\n\t}", "private void clearPort() {\n \n port_ = 0;\n }", "private void clearPort() {\n \n port_ = 0;\n }", "public void createSocket() \n { \n try \n { \n socket = new DatagramSocket(); \n } \n catch (Exception ex) \n { \n System.out.println(\"UDPPinger Exception: \" + ex); \n } \n }", "public void setPortNumber(java.lang.Integer portNumber) {\r\n this.portNumber = portNumber;\r\n }", "void port(int port);", "void port(int port);", "public void setPortNumber(long portNumber) {\n this.portNumber = portNumber;\n }", "public void setPortNumber(int portNumber) {\n this.portNumber = portNumber;\n }", "public CameraPiSocket(int port_arg){\n\t\tport = port_arg;\n\t}", "public UDPLayer() \n\t\tthrows SocketException\n\t{\n\t\tthis(0, true); // use any available port on the local host machine\n\t\t// TODO use -1 instead of 0?\n\t}", "private void initSocket(String host, String port) throws IOException {\n\t\t// check the validity of the host name\n\t\tif (host == null || host.isEmpty()) throw new IllegalArgumentException(\"host == null || host.isEmpty()\");\n\t\t// check the validity of the port number\n\t\tint p = 0;\n\t\ttry {\n\t\t\tp = Integer.parseInt(port);\n\t\t} catch (NumberFormatException e) {\n\t\t\tthrow new IllegalArgumentException(\"Illegal port argument\");\n\t\t}\n\t\tif (p <= 0) {\n\t\t\tthrow new IllegalArgumentException(\"Illegal port argument\");\n\t\t}\n\t\t// establish the network connection\n\t\ttry {\n\t\t\tthis.socket = new Socket(host, p);\n\t\t} catch (IOException e) {\n\t\t\tgetErrorManager().error(\"Failed to establish the network connection\", e,\n\t\t\t\tErrorManager.OPEN_FAILURE);\n\t\t\tthrow e;\n\t\t}\n\t\tsuper.internalSetOutputStream(new BufferedOutputStream(this.socket.getOutputStream()));\n\t}", "private void setUpConnection(final String IP_ADDR, final int portNumber) {\n\n Runnable runnable = new Runnable() {\n @Override\n public void run() {\n try {\n\n // Not thread safe (Destroy could be calling close at the same time)\n socket.connect((new InetSocketAddress(\n InetAddress.getByName(IP_ADDR), portNumber)));\n Log.d(TAG, \"Connection Successfull\");\n\n } catch (UnknownHostException e) {\n Log.e(TAG, \"Connection Failed\");\n e.printStackTrace();\n } catch (IOException e) {\n Log.e(TAG, \"Connection Failed\");\n e.printStackTrace();\n }\n }\n };\n\n connectionThread = new Thread(runnable);\n connectionThread.start();\n\t}", "public void setPort(String port) {\r\n this.port = port;\r\n }", "public Node(int port) {\n this();\n portnum = port;\n }", "private int determineFreePort() throws IOException\n {\n final Socket sock = new Socket();\n sock.bind(null);\n final int port = sock.getLocalPort();\n sock.close();\n return port;\n }", "public Builder setPort(int value) {\n\n port_ = value;\n onChanged();\n return this;\n }", "public Builder setPort(int value) {\n\n port_ = value;\n onChanged();\n return this;\n }", "public Builder setPort(int value) {\n \n port_ = value;\n onChanged();\n return this;\n }", "public Builder setPort(int value) {\n \n port_ = value;\n onChanged();\n return this;\n }", "@Override\n public int getPortNumber() {\n return 0;\n }", "public void setPort(int a_port)\n\t{\n\t\tif (!isValidPort(a_port))\n\t\t{\n\t\t\tm_iInetPort = -1;\n\t\t}\n\t\telse\n\t\t{\n\t\t\tm_iInetPort = a_port;\n\t\t}\n\t}", "public static boolean isUDPPortFreeToUse(int port) {\n if (port < MIN_PORT_NUMBER || port > MAX_PORT_NUMBER) {\n throw new IllegalArgumentException(\"Invalid start port: \" + port);\n }\n\n try (DatagramSocket ds = new DatagramSocket(port)) {\n ds.setReuseAddress(true);\n return true;\n } catch (IOException e) {\n // Do nothing\n }\n return false;\n }", "protected void bind() throws SocketException {\n super.bind();\n\n //start the secure socket\n dtlsSocket = options.getSecurePort() > 0 ? new DatagramSocket(options.getSecurePort()) : new DatagramSocket();\n dtslReceiverThread = createDatagramServer(\"mqttsn-dtls-receiver\", options.getReceiveBuffer(), dtlsSocket);\n }", "Builder port(int port);", "private void startListen() {\n try {\n listeningSocket = new ServerSocket(listeningPort);\n } catch (IOException e) {\n throw new RuntimeException(\"Cannot open listeningPort \" + listeningPort, e);\n }\n }", "public void startServerSocket(Integer port) throws IOException {\n this.port = port;\n startMEthod();\n }", "public void setPortNumber(int paramPortNo) {\n\tiPortNo = paramPortNo;\n }", "public void setUdpServerPort(int udpServerPort)\n \t{\n \t\tthis.udpServerPort = udpServerPort;\n \t}", "@Override\r\n\tpublic void initial() {\n\t\ttry {\r\n\t\t\tserverSocket = new ServerSocket(port);\r\n\t\t} catch (IOException e) {\r\n\t\t\t// TODO Auto-generated catch block\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t\t// System.out.println(\"LocalProxy run on \" + port);\r\n\t}", "public void testSetPort() {\n }", "public void setHttpPort(Integer port) {\n\t\tif (myNode != null) {\n\t\t\tthrow new IllegalStateException(\"change of port only before startup!\");\n\t\t}\n\t\tif (port == null || port < 1) {\n\t\t\thttpPort = 0;\n\t\t} else {\n\t\t\thttpPort = port;\n\t\t}\n\t}", "@Override\n\tpublic int getLocalPort() {\n\t\treturn 0;\n\t}", "@Override\n\tpublic int getLocalPort() {\n\t\treturn 0;\n\t}", "public void setPort(int port) {\n this.port = port;\n prefs.putInt(\"AEUnicastOutput.port\", port);\n }", "public void setPort(final String port){\n this.port=port;\n }", "public UDPConnector(int port, InetAddress host, \n\t\t\tint type) throws SocketException {\n\t\tthis.port = port;\n\t\tif(type==0) { \t//server\n\t\t\ts = new DatagramSocket(port);\n\t\t} else { \t\t//client\n\t\t\tthis.host = host;\n\t\t\ts = new DatagramSocket();\n\t\t}\n\t}", "public void startUDP() {\n try {\n DatagramSocket socket = new DatagramSocket(port);\n byte[] buf = new byte[256];\n while (running) {\n DatagramPacket packet = new DatagramPacket((sbyte[])(object) buf, buf.length);\n socket.receive(packet);\n upd_count++;\n packet = new DatagramPacket(buf, buf.length, packet.getAddress(), packet.getPort());\n String received = new String(packet.getData(), 0, packet.getLength());\n process(received.substring(0, received.indexOf('\\0')));\n buf = new byte[256];\n }\n socket.close();\n }\n catch(Exception e) {\n e.printStackTrace();\n }\n }", "public Builder listeningPort(final Optional<Integer> maybeListeningPort) {\n this.listeningPort = maybeListeningPort.filter(port -> port != 0);\n return this;\n }", "public static void setPort(int port){\n catalogue.port = port;\n }", "@Override\n\t\tpublic int getLocalPort() {\n\t\t\treturn 0;\n\t\t}", "public void setPort(int param){\r\n \r\n // setting primitive attribute tracker to true\r\n localPortTracker =\r\n param != java.lang.Integer.MIN_VALUE;\r\n \r\n this.localPort=param;\r\n \r\n\r\n }", "public void setPort(int param){\r\n \r\n // setting primitive attribute tracker to true\r\n localPortTracker =\r\n param != java.lang.Integer.MIN_VALUE;\r\n \r\n this.localPort=param;\r\n \r\n\r\n }", "private void startPortManager() throws GrpcException {\n\t\t/* start PortManager */\t\t\n\t\ttry {\n\t\t\tinformationManager.lockInformationManager();\n\t\t\t\n\t\t\tProperties localHostInfo =\n\t\t\t\t(Properties) informationManager.getLocalMachineInfo();\n\t\t\t\n\t\t\t/* PortManager without SSL */\n\t\t\tint port = Integer.parseInt((String) localHostInfo.get(\n\t\t\t\tNgInformationManager.KEY_CLIENT_LISTEN_PORT_RAW));\n\t\t\tportManagerNoSecure = new PortManager(this, false, port);\n\n\t\t\t/* PortManager with authonly is not implemented. */\n\n\t\t\t/* PortManager with GSI */\n\t\t\tport = Integer.parseInt((String) localHostInfo.get(\n\t\t\t\t\tNgInformationManager.KEY_CLIENT_LISTEN_PORT_GSI));\t\n\t\t\tportManagerGSI = new PortManager(this, PortManager.CRYPT_GSI, port);\n\n\t\t\t/* PortManager with SSL */\n\t\t\tport = Integer.parseInt((String) localHostInfo.get(\n\t\t\t\t\tNgInformationManager.KEY_CLIENT_LISTEN_PORT_SSL));\t\n\t\t\tportManagerSSL = new PortManager(this, PortManager.CRYPT_SSL, port);\n\n\t\t} catch (NumberFormatException e) {\n\t\t\tthrow new NgInitializeGrpcClientException(e);\n\t\t} catch (IOException e) {\n\t\t\tthrow new NgIOException(e);\n\t\t} finally {\n\t\t\tinformationManager.unlockInformationManager();\n\t\t}\n\t}", "public DNSUDPConnector() {\r\n\t\t\treset();\r\n\t\t}", "public Server(int port) {\n this.port = port;\n try {\n socket = new DatagramSocket(port);\n } catch (SocketException e) {\n e.printStackTrace();\n }\n run = new Thread(this, \"Server\");\n run.start();\n }", "public static boolean isTCPPortFreeToUse(int port) {\n if (port < MIN_PORT_NUMBER || port > MAX_PORT_NUMBER) {\n throw new IllegalArgumentException(\"Invalid start port: \" + port);\n }\n\n try (ServerSocket ss = new ServerSocket(port)) {\n ss.setReuseAddress(true);\n return true;\n } catch (IOException e) {\n // Do nothing\n }\n return false;\n }", "public com.example.DNSLog.Builder setPort(int value) {\n validate(fields()[6], value);\n this.port = value;\n fieldSetFlags()[6] = true;\n return this;\n }", "public PeerBuilder ports(int port) {\n\t\tthis.udpPort = port;\n\t\tthis.tcpPort = port;\n\t\treturn this;\n\t}" ]
[ "0.6864262", "0.6611402", "0.65697294", "0.63493305", "0.63493305", "0.6295403", "0.6185939", "0.61836743", "0.6183564", "0.61610085", "0.6148454", "0.6078744", "0.6077159", "0.6077159", "0.60559887", "0.6041838", "0.603654", "0.60323304", "0.60296375", "0.60233784", "0.6022652", "0.60064095", "0.5996385", "0.59740055", "0.59711003", "0.59585816", "0.595259", "0.5947906", "0.5947906", "0.5944582", "0.59432447", "0.59341145", "0.59322506", "0.5925212", "0.59194374", "0.59194374", "0.59194374", "0.59194374", "0.59069794", "0.59069794", "0.59069794", "0.59069794", "0.59069794", "0.59069794", "0.589126", "0.58782953", "0.587743", "0.58732474", "0.5867449", "0.58530205", "0.5831835", "0.5831835", "0.58074814", "0.58074814", "0.5798053", "0.5779044", "0.5776052", "0.5776052", "0.57750976", "0.57682264", "0.5760753", "0.57586884", "0.57445985", "0.57330626", "0.5731574", "0.57227904", "0.57161176", "0.5698255", "0.5698255", "0.5688325", "0.5688325", "0.56842667", "0.5679337", "0.5672974", "0.56667656", "0.5664365", "0.5662731", "0.56591225", "0.56522113", "0.5650676", "0.56444836", "0.5636675", "0.56353503", "0.56301993", "0.56301993", "0.5622063", "0.56208384", "0.56151956", "0.56107754", "0.56075627", "0.5600982", "0.5600295", "0.5597461", "0.5597461", "0.5597295", "0.5587255", "0.558122", "0.5580566", "0.5573191", "0.5567038" ]
0.64803314
3
Used when changing the host address, reinitializes the DatagramSocket if new host address.
public void setHost(String address) { final String adr = address; new Thread() { @Override public void run() { try { if (!host.equals(InetAddress.getByName(adr))) { host = InetAddress.getByName(adr); init(); } } catch (UnknownHostException e) { e.printStackTrace(); } } }.start(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public final void setRemoteSocketAddress(String host){\r\n remoteSocketHost = host;\r\n }", "@Override\n\tprotected void populateRemoteHost() {\n\t\tthrow noSocket();\n\t}", "synchronized public void setHost(String host) {\n this.host = host;\n if (checkClient()) {\n prefs.put(\"AEUnicastOutput.host\", host);\n }\n }", "public void host() throws IOException {\n\t\tserverSocket = new ServerSocket(getPort());\n\t\twhile (true) {\n\t\t\thandleNewConnections();\n\t\t}\n\t}", "public void setHost(InetAddress host) throws IllegalArgumentException,\n SipParseException{\n\tLogWriter.logMessage(LogWriter.TRACE_DEBUG,\"setHost() \" + host);\n Via via=(Via)sipHeader;\n \n if (host==null)\n throw new IllegalArgumentException\n (\"JAIN-SIP EXCEPTION: host is null\");\n else {\n String hname = host.getHostAddress();\n gov.nist.sip.net.Host h = new gov.nist.sip.net.Host();\n h.setHostAddress(hname);\n via.setHost(h);\n }\n }", "void resetToDefaultServerAddress();", "public void reInit() {\n super.reInit();\n if (m_nameAddress != null) {\n m_nameAddress.reInit();\n }\n }", "public void setHostAddress(int value) {\n this.hostAddress = value;\n }", "public void initialize() throws SocketException{\n defPortUsed = true;\n initializeReal(defPortNumber, defPacketSize);\n }", "public DNSUDPConnector() {\r\n\t\t\treset();\r\n\t\t}", "public void changeOwnIP(InetAddress newOwnIP){\n boolean bound = false;\n\n this.ownIP = newOwnIP;\n\n this.packetLock.lock();\n\n this.ds.close();\n\n\n while (!bound) {\n try {\n this.ds = new DatagramSocket(null);\n InetSocketAddress isa = new InetSocketAddress(this.ownIP, this.ownPort);\n this.ds.bind(isa);\n bound = true;\n this.ds.setSendBufferSize(3000000);\n //System.out.println(\"(FASTUNICASTSENDER) BOUND TO \" + this.ownIP + \":\" + this.ownPort);\n //changeHasConnection(true);\n this.packetLock.unlock();\n\n } catch (SocketException e) {\n //System.out.println(\"(FASTUNICASTSENDER) ERROR BINDING TO \" + this.ownIP + \":\" + this.ownPort);\n e.printStackTrace();\n }\n\n if(!bound){\n try {\n Thread.sleep(500);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }\n }\n }", "final public void setHost(String host) {\n this.host = host;\n }", "public Builder host(String newHost) {\n host = newHost;\n return this;\n }", "@Override\r\n\tpublic void initial() {\n\t\ttry {\r\n\t\t\tserverSocket = new ServerSocket(port);\r\n\t\t} catch (IOException e) {\r\n\t\t\t// TODO Auto-generated catch block\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t\t// System.out.println(\"LocalProxy run on \" + port);\r\n\t}", "public void setAddress(String address) {\n try {\n if (address == null ||\n address.equals(\"\") ||\n address.equals(\"localhost\")) {\n m_Address = InetAddress.getLocalHost().getHostName();\n }\n } catch (Exception ex) {\n log.error(\"setAddress()\",ex);\n }\n m_Address = address;\n }", "public Builder clearHost() {\n\n host_ = getDefaultInstance().getHost();\n onChanged();\n return this;\n }", "public void setDefaultHost() {\r\n\t\tsetHost(DEFAULT_HOST);\r\n\t}", "public void setHost(String host);", "private void initServerSock(int port) throws IOException {\n\tserver = new ServerSocket(port);\n\tserver.setReuseAddress(true);\n }", "private void storeHostAddresses() {\n savedHostAddresses.clear();\n /* port */\n savedPort = portComboBox.getStringValue();\n /* addresses */\n for (final Host host : getBrowser().getClusterHosts()) {\n final GuiComboBox cb = addressComboBoxHash.get(host);\n final String address = cb.getStringValue();\n if (address == null || \"\".equals(address)) {\n savedHostAddresses.remove(host);\n } else {\n savedHostAddresses.put(host, address);\n }\n host.getBrowser().getDrbdVIPortList().add(savedPort);\n }\n }", "public void createSocket() \n { \n try \n { \n socket = new DatagramSocket(); \n } \n catch (Exception ex) \n { \n System.out.println(\"UDPPinger Exception: \" + ex); \n } \n }", "Target(String host) {\n try {\n address = new InetSocketAddress(InetAddress.getByName(host), 80);\n } catch (UnknownHostException e) {\n// e.printStackTrace(); //To change body of catch statement use File | Settings | File Templates.\n failure = e;\n }\n }", "public void clearHostnamePort() {\n hostports.clear();\n }", "@Override\n\tpublic void set(SocketAddress v) {\n\t\tsuper.set(Objects.requireNonNull(v));\n\t}", "public boolean isReuseAddress()\r\n/* 159: */ {\r\n/* 160: */ try\r\n/* 161: */ {\r\n/* 162:176 */ return this.javaSocket.getReuseAddress();\r\n/* 163: */ }\r\n/* 164: */ catch (SocketException e)\r\n/* 165: */ {\r\n/* 166:178 */ throw new ChannelException(e);\r\n/* 167: */ }\r\n/* 168: */ }", "public void setHost(String host) {\n this.host = host;\n }", "private void setHostName(String hostId)\n\t{\n\t\ttry\n\t\t{\n\t\t\tInetAddress localMachine = InetAddress.getLocalHost();\n\t\t\tString hostName = localMachine.getHostName();\n\t\t\tString address = localMachine.getHostAddress();\n\t\t\thost = ((!Strings.isEmpty(hostName)) ? hostName + \"/\" + address : address) + \"/\" +\n\t\t\t\t\thostId;\n\t\t}\n\t\tcatch (UnknownHostException e)\n\t\t{\n\t\t}\n\n\t\tif (Strings.isEmpty(host))\n\t\t{\n\t\t\thost = \"<unknown>\";\n\t\t}\n\t}", "public void setHost(String host) {\n this.host = host;\n }", "public void setHost(String host) {\n this.host = host;\n }", "public void setHost(String host) {\n this.host = host;\n }", "public void setHost(String host) {\n this.host = host;\n }", "public void setHost(String host) {\n this.host = host;\n }", "public void newHost(Host aHost);", "public static void setBroadcastInetAddress(InetAddress addr)\n {\n broadcastInetAddress = addr;\n broadcastInetAddressAndPort = InetAddressAndPort.getByAddress(broadcastInetAddress);\n }", "public void setHost(String hostName)\n {\n this.hostName = hostName;\n }", "private static void updateInfo(\n Host host, Row row, Cluster.Manager cluster, boolean isInitialConnection) {\n if (!row.isNull(\"data_center\") || !row.isNull(\"rack\"))\n updateLocationInfo(\n host, row.getString(\"data_center\"), row.getString(\"rack\"), isInitialConnection, cluster);\n\n String version = row.getString(\"release_version\");\n host.setVersion(version);\n\n // Before CASSANDRA-9436 local row did not contain any info about the host addresses.\n // After CASSANDRA-9436 (2.0.16, 2.1.6, 2.2.0 rc1) local row contains two new columns:\n // - broadcast_address\n // - rpc_address\n // After CASSANDRA-9603 (2.0.17, 2.1.8, 2.2.0 rc2) local row contains one more column:\n // - listen_address\n // After CASSANDRA-7544 (4.0) local row also contains:\n // - broadcast_port\n // - listen_port\n\n InetSocketAddress broadcastRpcAddress = null;\n if (row.getColumnDefinitions().contains(\"native_address\")) {\n InetAddress nativeAddress = row.getInet(\"native_address\");\n int nativePort = row.getInt(\"native_port\");\n broadcastRpcAddress = new InetSocketAddress(nativeAddress, nativePort);\n } else if (row.getColumnDefinitions().contains(\"native_transport_address\")) {\n // DSE 6.8 introduced native_transport_address and native_transport_port for the\n // listen address. Also included is native_transport_port_ssl (in case users\n // want to setup a different port for SSL and non-SSL conns).\n InetAddress nativeAddress = row.getInet(\"native_transport_address\");\n int nativePort = row.getInt(\"native_transport_port\");\n if (cluster.getCluster().getConfiguration().getProtocolOptions().getSSLOptions() != null\n && !row.isNull(\"native_transport_port_ssl\")) {\n nativePort = row.getInt(\"native_transport_port_ssl\");\n }\n broadcastRpcAddress = new InetSocketAddress(nativeAddress, nativePort);\n } else if (row.getColumnDefinitions().contains(\"rpc_address\")) {\n InetAddress rpcAddress = row.getInet(\"rpc_address\");\n broadcastRpcAddress = new InetSocketAddress(rpcAddress, cluster.connectionFactory.getPort());\n }\n // Before CASSANDRA-9436, system.local doesn't have rpc_address, so this might be null. It's not\n // a big deal because we only use this for server events, and the control node doesn't receive\n // events for itself.\n host.setBroadcastRpcAddress(broadcastRpcAddress);\n\n InetSocketAddress broadcastSocketAddress = null;\n if (row.getColumnDefinitions().contains(\"peer\")) { // system.peers\n int broadcastPort =\n row.getColumnDefinitions().contains(\"peer_port\") ? row.getInt(\"peer_port\") : 0;\n broadcastSocketAddress = new InetSocketAddress(row.getInet(\"peer\"), broadcastPort);\n } else if (row.getColumnDefinitions().contains(\"broadcast_address\")) { // system.local\n int broadcastPort =\n row.getColumnDefinitions().contains(\"broadcast_port\") ? row.getInt(\"broadcast_port\") : 0;\n broadcastSocketAddress =\n new InetSocketAddress(row.getInet(\"broadcast_address\"), broadcastPort);\n }\n host.setBroadcastSocketAddress(broadcastSocketAddress);\n\n // in system.local only for C* versions >= 2.0.17, 2.1.8, 2.2.0 rc2,\n // not yet in system.peers as of C* 3.2\n InetSocketAddress listenAddress = null;\n if (row.getColumnDefinitions().contains(\"listen_address\")) {\n int listenPort =\n row.getColumnDefinitions().contains(\"listen_port\") ? row.getInt(\"listen_port\") : 0;\n listenAddress = new InetSocketAddress(row.getInet(\"listen_address\"), listenPort);\n }\n host.setListenSocketAddress(listenAddress);\n\n if (row.getColumnDefinitions().contains(\"workload\")) {\n String dseWorkload = row.getString(\"workload\");\n host.setDseWorkload(dseWorkload);\n }\n if (row.getColumnDefinitions().contains(\"graph\")) {\n boolean isDseGraph = row.getBool(\"graph\");\n host.setDseGraphEnabled(isDseGraph);\n }\n if (row.getColumnDefinitions().contains(\"dse_version\")) {\n String dseVersion = row.getString(\"dse_version\");\n host.setDseVersion(dseVersion);\n }\n host.setHostId(row.getUUID(\"host_id\"));\n host.setSchemaVersion(row.getUUID(\"schema_version\"));\n\n EndPoint endPoint = cluster.configuration.getPolicies().getEndPointFactory().create(row);\n if (endPoint != null) {\n host.setEndPoint(endPoint);\n }\n }", "public DHT() throws UnknownHostException, SocketException {\n socket = new DatagramSocket(sendPort);\n recSocket = new DatagramSocket(recPort);\n systemMap = new HashMap<>();\n systemMap.put(0,InetAddress.getByName(\"129.21.22.196\")); //glados\n systemMap.put(1,InetAddress.getByName(\"129.21.30.37\")); //queeg\n systemMap.put(2,InetAddress.getByName(\"129.21.34.80\")); // comet\n systemMap.put(3,InetAddress.getByName(\"129.21.37.49\")); // rhea\n systemMap.put(4,InetAddress.getByName(\"129.21.37.42\")); // domino\n systemMap.put(5,InetAddress.getByName(\"129.21.37.55\")); // gorgon\n systemMap.put(6,InetAddress.getByName(\"129.21.37.30\")); // kinks\n\n\n }", "private void establishConnection() throws UnknownHostException, \n \t\t\t\t\t\t\t\t\t\t IOException {\n \t socket = new Socket(serverIP, serverPort);\n }", "private static void init() {\n System.setProperty(\"java.net.preferIPv4Stack\", \"true\");\r\n }", "protected void setHostname(final String host) {\n this.host = host;\n }", "@Override\n protected void doBind(SocketAddress localAddress) throws Exception {}", "public void setReuseAddress (boolean on) {\n reuseAddrEnabled = on;\n }", "public void setHost(String host) throws IllegalArgumentException,\n SipParseException {\n \n\t LogWriter.logMessage(LogWriter.TRACE_DEBUG,\"setHost() \" + host);\n Via via=(Via)sipHeader;\n if ( host==null )\n throw new IllegalArgumentException\n (\"JAIN-EXCEPTION: host argument is null\");\n else via.setHost(host); \n }", "static void test4 () throws Exception {\n server = new ServerSocket (0);\n int port = server.getLocalPort();\n\n /* create an IPv4 mapped address corresponding to local host */\n\n byte[] b = {0,0,0,0,0,0,0,0,0,0,(byte)0xff,(byte)0xff,0,0,0,0};\n byte[] ia4 = ia4addr.getAddress();\n b[12] = ia4[0];\n b[13] = ia4[1];\n b[14] = ia4[2];\n b[15] = ia4[3];\n\n InetAddress dest = InetAddress.getByAddress (b);\n c1 = new Socket (dest, port);\n s1 = server.accept ();\n simpleDataExchange (c1,s1);\n c1.close ();\n s1.close ();\n server.close ();\n System.out.println (\"Test4: OK\");\n }", "public void setHost(HostAgent host){\n\tthis.host = host;\n }", "private void rebind() {\n\t\tnotaryServers = Client.locateNotaries();\n\t\tconnectToUsers();\n\t\t//lookUpUsers();\n\n\t}", "private void parseHost(VirtualHost host, Node hostNode) {\r\n Node item = hostNode.getAttributes().getNamedItem(\"hostDomain\");\r\n if (item != null && item.getNodeValue() != null) {\r\n host.setHostDomain(item.getNodeValue());\r\n }\r\n item = hostNode.getAttributes().getNamedItem(\"hostPort\");\r\n if (item != null && item.getNodeValue() != null) {\r\n host.setHostPort(item.getNodeValue());\r\n }\r\n item = hostNode.getAttributes().getNamedItem(\"hostScheme\");\r\n if (item != null && item.getNodeValue() != null) {\r\n host.setHostScheme(item.getNodeValue());\r\n }\r\n item = hostNode.getAttributes().getNamedItem(\"name\");\r\n if (item != null && item.getNodeValue() != null) {\r\n host.setName(item.getNodeValue());\r\n }\r\n item = hostNode.getAttributes().getNamedItem(\"resourceDomain\");\r\n if (item != null && item.getNodeValue() != null) {\r\n host.setResourceDomain(item.getNodeValue());\r\n }\r\n item = hostNode.getAttributes().getNamedItem(\"resourcePort\");\r\n if (item != null && item.getNodeValue() != null) {\r\n host.setResourcePort(item.getNodeValue());\r\n }\r\n item = hostNode.getAttributes().getNamedItem(\"resourceScheme\");\r\n if (item != null && item.getNodeValue() != null) {\r\n host.setResourceScheme(item.getNodeValue());\r\n }\r\n item = hostNode.getAttributes().getNamedItem(\"serverAddress\");\r\n if (item != null && item.getNodeValue() != null) {\r\n host.setServerAddress(item.getNodeValue());\r\n }\r\n item = hostNode.getAttributes().getNamedItem(\"serverPort\");\r\n if (item != null && item.getNodeValue() != null) {\r\n host.setServerPort(item.getNodeValue());\r\n }\r\n // Loops the list of \"attach\" instructions\r\n setAttach(host, hostNode);\r\n }", "protected void doBind(SocketAddress localAddress) throws Exception {}", "private void initSocket(String host, String port) throws IOException {\n\t\t// check the validity of the host name\n\t\tif (host == null || host.isEmpty()) throw new IllegalArgumentException(\"host == null || host.isEmpty()\");\n\t\t// check the validity of the port number\n\t\tint p = 0;\n\t\ttry {\n\t\t\tp = Integer.parseInt(port);\n\t\t} catch (NumberFormatException e) {\n\t\t\tthrow new IllegalArgumentException(\"Illegal port argument\");\n\t\t}\n\t\tif (p <= 0) {\n\t\t\tthrow new IllegalArgumentException(\"Illegal port argument\");\n\t\t}\n\t\t// establish the network connection\n\t\ttry {\n\t\t\tthis.socket = new Socket(host, p);\n\t\t} catch (IOException e) {\n\t\t\tgetErrorManager().error(\"Failed to establish the network connection\", e,\n\t\t\t\tErrorManager.OPEN_FAILURE);\n\t\t\tthrow e;\n\t\t}\n\t\tsuper.internalSetOutputStream(new BufferedOutputStream(this.socket.getOutputStream()));\n\t}", "void host(String host);", "void host(String host);", "private void initServerSocket()\n\t{\n\t\tboundPort = new InetSocketAddress(port);\n\t\ttry\n\t\t{\n\t\t\tserverSocket = new ServerSocket(port);\n\n\t\t\tif (serverSocket.isBound())\n\t\t\t{\n\t\t\t\tSystem.out.println(\"Server bound to data port \" + serverSocket.getLocalPort() + \" and is ready...\");\n\t\t\t}\n\t\t}\n\t\tcatch (Exception e)\n\t\t{\n\t\t\tSystem.out.println(\"Unable to initiate socket.\");\n\t\t}\n\n\t}", "public void setSocket(SocketWrapper socket);", "public void setHost(String p_host) throws MalformedURIException {\n if (p_host == null || p_host.length() == 0) {\n if (p_host != null) {\n m_regAuthority = null;\n }\n m_host = p_host;\n m_userinfo = null;\n m_port = -1;\n return;\n }\n else if (!isWellFormedAddress(p_host)) {\n throw new MalformedURIException(\"Host is not a well formed address!\");\n }\n m_host = p_host;\n m_regAuthority = null;\n }", "public void connect(String host) throws IllegalStateException,\n \t\t\tIOException, JHGDException {\n \t\tconnect(host, HGDConsts.DEFAULT_PORT);\n \t}", "public void reconnectServer(String hostName,int portNum) throws UnknownHostException, IOException {\n\t\tsocket=new Socket(hostName,portNum);\n\t\tdin = new DataInputStream(socket.getInputStream());\n\t\tdout = new DataOutputStream(socket.getOutputStream());\n\t\tthis.hostName = hostName;\n\t\tthis.portNum = portNum;\n\t}", "private void initialize(){\n\t\ttry\n\t\t{\n\t\t\tString[] packet = setPacket();\n\t\t\tif (validatePacket(packet))\n\t\t\t{\n\t\t\t\tsend(packet);\n\t\t\t}\n\t\t}\n\t\tcatch (Exception e)\n\t\t{\n\t\t\tSystem.out.println(e.getMessage());\n\t\t\tSystem.out.println(\"Something went wrong...\");\n\t\t\tresetClient();\n\t\t}\n\t}", "public EchoClient(String address) {\n try {\n socket = new DatagramSocket();\n } catch (SocketException e) {\n // TODO Auto-generated catch block\n e.printStackTrace();\n }\n try {\n inetAddress = InetAddress.getByName((address != null) ? address : \"localhost\");\n } catch (UnknownHostException e) {\n // TODO Auto-generated catch block\n e.printStackTrace();\n }\n }", "public void setGuessHostname(boolean val);", "public void setAddress(InetAddress address) {\r\n\t\tthis.address = address;\r\n\t}", "private static void init() {\n\t\ttry {\n\t\t\tlocalAddr = InetAddress.getLocalHost();\n\t\t\tlogger.info(\"local IP:\" + localAddr.getHostAddress());\n\t\t} catch (UnknownHostException e) {\n\t\t\tlogger.info(\"try again\\n\");\n\t\t}\n\t\tif (localAddr != null) {\n\t\t\treturn;\n\t\t}\n\t\t// other way to get local IP\n\t\tEnumeration<InetAddress> localAddrs;\n\t\ttry {\n\t\t\t// modify your network interface name\n\t\t\tNetworkInterface ni = NetworkInterface.getByName(networkInterface);\n\t\t\tif (ni == null) {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tlocalAddrs = ni.getInetAddresses();\n\t\t\tif (localAddrs == null || !localAddrs.hasMoreElements()) {\n\t\t\t\tlogger.error(\"choose NetworkInterface\\n\" + getNetworkInterface());\n\t\t\t\treturn;\n\t\t\t}\n\t\t\twhile (localAddrs.hasMoreElements()) {\n\t\t\t\tInetAddress tmp = localAddrs.nextElement();\n\t\t\t\tif (!tmp.isLoopbackAddress() && !tmp.isLinkLocalAddress() && !(tmp instanceof Inet6Address)) {\n\t\t\t\t\tlocalAddr = tmp;\n\t\t\t\t\tlogger.info(\"local IP:\" + localAddr.getHostAddress());\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t} catch (Exception e) {\n\t\t\tlogger.error(\"Failure when init ProxyUtil\", e);\n\t\t\tlogger.error(\"choose NetworkInterface\\n\" + getNetworkInterface());\n\t\t}\n\t}", "public void setHost(String host) {\n this.host = host == null ? null : host.trim();\n }", "private void initServer() throws IOException {\r\n \t\tLogger.logMessage(\"Binding Server to \" + this.serverIpAddress + \":\" + this.serverPort);\r\n \r\n \t\tthis.isAlive = true;\r\n \t\tthis.serverSocket = new ServerSocket(this.serverPort, this.backLog, this.serverIpAddress);\r\n \t\tthis.dataLayer = DataLayerFactory.getDataLayer();\r\n \r\n \t\t// Generate the grouplist\r\n \t\tCollection<String> dbGroupList = this.dataLayer.getGroups();\r\n \r\n \t\tfor (String group : dbGroupList) {\r\n \t\t\tthis.groupList.addGroup(group);\r\n \t\t}\r\n \r\n \t\tLogger.logMessage(\"Server successfuly bound!\");\r\n \t}", "public Communicator() throws SocketException\r\n {\r\n datagramSocket = new DatagramSocket();\r\n }", "void connect() throws UnknownHostException, IOException {\n\t\tif (isConnected()) {\n\t\t\tdisconnect();\n\t\t}\n\t\t\n\t\tif (!ssl) {\n\t\t\tsock = new Socket();\n\t\t} else {\n\t\t\tsock = SSLSocketFactory.getDefault().createSocket();\n\t\t}\n\t\tsock.connect(new InetSocketAddress(host, port));\n\t\t\n\t\tif (sock != null) {\n\t\t\tsock.setKeepAlive(true);\n\t\t\tinStream = new UByteInputStream(new BufferedInputStream(sock.getInputStream(), sock.getReceiveBufferSize()));\n\t\t\tconnected();\n\t\t}\n\t}", "T setHostName(String hostName);", "private String GetHostAddress() throws UnknownHostException {\n return Inet4Address.getLocalHost().getHostAddress();\n }", "public static void rebuildSocket() throws IOException {\n try {\n buildSocket();\n } catch (Exception e) {\n throw new IOException();\n }\n }", "public SocketChannelConfig setReuseAddress(boolean reuseAddress)\r\n/* 215: */ {\r\n/* 216: */ try\r\n/* 217: */ {\r\n/* 218:221 */ this.javaSocket.setReuseAddress(reuseAddress);\r\n/* 219: */ }\r\n/* 220: */ catch (SocketException e)\r\n/* 221: */ {\r\n/* 222:223 */ throw new ChannelException(e);\r\n/* 223: */ }\r\n/* 224:225 */ return this;\r\n/* 225: */ }", "public Builder setHost(\n java.lang.String value) {\n if (value == null) {\n throw new NullPointerException();\n }\n\n host_ = value;\n onChanged();\n return this;\n }", "public void setHost(Player roomHost) {\r\n this.roomHost = roomHost;\r\n }", "public void SetHost(GUI host) {\n\t\tm_Host = host;\n\t}", "public void addressChanged() {\n\t\t// the variable OSCPortOut tries to get an instance of OSCPortOut\n\t\t// at the address indicated by the addressWidget\n\t\ttry {\n\t\t\toscPort =\n\t\t\t\tnew OSCPortOut(InetAddress.getByName(addressWidget.getText()));\n\t\t\t// if the oscPort variable fails to be instantiated then sent\n\t\t\t// the error message\n\t\t} catch (final Exception ex) {\n\t\t\tshowError(\"Couldn't set address\");\n\t\t}\n\t}", "protected String adjustHost(final String host) {\n if (host.startsWith(HTTP_PROTOCOL)) {\n return host.replace(HTTP_PROTOCOL, EMPTY_STRING);\n } else if (host.startsWith(HTTPS_PROTOCOL)) {\n return host.replace(HTTPS_PROTOCOL, EMPTY_STRING);\n }\n return host;\n }", "void refreshNodeHostCount(int nodeHostCount);", "public void setHost(String host) {\n setSyslogHost(host);\n }", "public WSocket() throws SocketException, UnknownHostException {\r\n\t\tthis.socket = new DatagramSocket();\r\n\t\tthis.port = socket.getLocalPort();\r\n\t\tthis.addr = InetAddress.getByName(\"localhost\");\r\n\t}", "public void setHostDataNode(TDataNodeLocation hostDataNode) {\n this.hostDataNode = hostDataNode;\n }", "public boolean setupSocket() throws ExitProgram {\n\t\tboolean success = false;\n\t\t\n\t\tthis.showNamedMessage(\"Trying to open a new socket...\");\n\t\twhile (this.socket == null) { \n\t\t\ttry {\n\t\t\t\tthis.socket = TransportLayer.openNewDatagramSocket(this.ownPort);\n\t\t\t\tthis.showNamedMessage(\"Client now bound to port \" + ownPort);\n\t\t\t\tsuccess = true;\n\t\t\t} catch (SocketException e) {\n\t\t\t\tthis.showNamedError(\"Something went wrong when opening the socket: \"\n\t\t\t\t\t\t+ e.getLocalizedMessage());\n\t\t\t\tif (!textUI.getBoolean(\"Do you want to try again?\")) {\n\t\t\t\t\tthrow new exceptions.ExitProgram(\"User indicated to exit the \"\n\t\t\t\t\t\t\t+ \"program after socket opening failure.\");\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn success;\n\t}", "public UdpPacketSender() {\r\n\t\ttry {\r\n\t\t\tthis.socket = new DatagramSocket();\r\n\t\t} catch (final SocketException e) {\r\n\t\t\tlog.log(Level.SEVERE, e.getMessage(), e);\r\n\t\t}\r\n\t}", "void connect() throws UnsupportedProtocolVersionException {\n if (isShutdown) return;\n\n List<Host> hosts = new ArrayList<Host>(cluster.metadata.getContactPoints());\n // shuffle so that multiple clients with the same contact points don't all pick the same control\n // host\n Collections.shuffle(hosts);\n setNewConnection(reconnectInternal(hosts.iterator(), true));\n }", "public void init() throws IOException {\r\n try {\r\n serverSocket = new ServerSocket(PORT);\r\n this.running = true;\r\n } catch (IOException e) {\r\n System.out.println(e);\r\n }\r\n }", "public FakeDns unknownHost() {\n this.addresses = Collections.emptyList();\n return this;\n }", "public DatagramSocket createUnboundDatagramSocket()\n throws SocketException;", "public HostSync(int portNumber, long bufferTime, String streamAddress, int streamPort) {\n\n\t\ttry {\n\t\t\thostAddress = Utils.getIP();\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t\thostAddress = \"ERROR\"; // Good idea? Not sure. Probably not. Look into.\n\t\t}\n\n\t\tthis.bufferTime = bufferTime;\n\n\t\tthis.portNumber = portNumber;\n\t\tthis.streamAddress = streamAddress;\n\t\tthis.streamPort = streamPort;\n\t\tnetworkLog = new NetworkLog();\n\t\tclients = new HashMap<String, ClientConnection>();\n\t\t\n\t\ttry {\n\t\t\tserverSocket = new ServerSocket(portNumber);\n\t\t} catch(IOException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t}", "public void setHost(com.vmware.converter.DistributedVirtualSwitchHostMemberConfigSpec[] host) {\r\n this.host = host;\r\n }", "public DNSUDPTransport() {\r\n\t\tlistHostPort = new ArrayList();\r\n\t\tconnTimeout = 0;\r\n\t}", "public static void setBroadcastInetAddressAndPort(InetAddressAndPort addr)\n {\n broadcastInetAddress = addr.getAddress();\n broadcastInetAddressAndPort = addr;\n }", "public boolean initAndConnectToServer() {\n try {\n mTCPSocket.connect(new InetSocketAddress(mIpAdress, port), 1000);\n } catch (IOException e) {\n e.printStackTrace();\n return false;\n }\n return true;\n }", "private boolean checkHostAddressesFieldsChanged() {\n boolean changed = false;\n for (final Host host : getBrowser().getClusterHosts()) {\n final GuiComboBox cb = addressComboBoxHash.get(host);\n if (cb == null) {\n continue;\n }\n final String haSaved = savedHostAddresses.get(host);\n final Object value = cb.getValue();\n if (!Tools.areEqual(haSaved, value)) {\n changed = true;\n }\n cb.setBackground(null, haSaved, false);\n }\n /* port */\n final GuiComboBox pcb = portComboBox;\n if (pcb != null) {\n if (!Tools.areEqual(savedPort, pcb.getValue())) {\n changed = true;\n }\n pcb.setBackground(null,\n savedPort,\n false);\n }\n return changed;\n }", "public Intermediary()\r\n\t{\r\n\t\ttry {\r\n\t\t\treceiveSocket = new DatagramSocket(68);\r\n\t\t\tsendReceiveSocket = new DatagramSocket();\t\t\t\r\n\t\t\t\r\n\t\t} catch (SocketException se) {\r\n\t\t\tse.printStackTrace();\r\n\t\t\tSystem.exit(1);\r\n\t\t} \r\n\t\t\r\n\t\treqID = 1;\r\n\t\tSystem.out.println(\"===== INTERMEDIATE HOST STARTED =====\\n\");\r\n\t}", "public Builder setHostBytes(\n com.google.protobuf.ByteString value) {\n if (value == null) {\n throw new NullPointerException();\n }\n checkByteStringIsUtf8(value);\n\n host_ = value;\n onChanged();\n return this;\n }", "public void setSocksProxyHost(String host) {\n this.socksProxyHost = host;\n }", "private static InetAddress getLocalHost() throws UnknownHostException {\n InetAddress addr;\n try {\n addr = InetAddress.getLocalHost();\n } catch (ArrayIndexOutOfBoundsException e) {\n addr = InetAddress.getByName(null);\n }\n return addr;\n }", "public boolean openConnection(String address) {\n\t\t\ttry {\n\t\t\t\t// the following line wont work because server already occupies that port\n\t\t\t\t// socket = new DatagramSocket(port);\n\t\t\t\t// now we will bind to any port that is available\n\t\t\t\t// however this way server needs to know the port we are sending from\n\t\t\t\t// UDP protocoll: we dont have to connect to serverto begin with\n\t\t\t\tsocket = new DatagramSocket();\n\t\t\t} catch (SocketException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t\treturn false;\n\t\t\t}\n\t\t\ttry {\n\t\t\t\tip = InetAddress.getByName(address);\n\t\t\t} catch (UnknownHostException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t\treturn false;\n\t\t\t}\n\t\t\treturn true;\n\t}", "public interface DatagramSocketFactory\n{\n /**\n * Creates an unbound DatagramSocket:\n * - i.e <tt>return new DatagramSocket((SocketAddress) null)</tt>.\n *\n * @return An unbound DatagramSocket.\n *\n * @throws SocketException if the socket could not be opened.\n */\n public DatagramSocket createUnboundDatagramSocket()\n throws SocketException;\n}", "public void startUDP() {\n try {\n DatagramSocket socket = new DatagramSocket(port);\n byte[] buf = new byte[256];\n while (running) {\n DatagramPacket packet = new DatagramPacket((sbyte[])(object) buf, buf.length);\n socket.receive(packet);\n upd_count++;\n packet = new DatagramPacket(buf, buf.length, packet.getAddress(), packet.getPort());\n String received = new String(packet.getData(), 0, packet.getLength());\n process(received.substring(0, received.indexOf('\\0')));\n buf = new byte[256];\n }\n socket.close();\n }\n catch(Exception e) {\n e.printStackTrace();\n }\n }", "void clearAddress() {\n mAddress = HdmiCec.ADDR_UNREGISTERED;\n }", "private synchronized void reconnectIfNecessary() {\n if (DEBUG) {\n Log.d(LOG_TAG, \"Reconnect if necessary called...\");\n }\n if (mStarted && mClient == null) {\n connect(mIpAdress, mPort);\n }\n }", "protected void bind(InetAddress host, int port) throws IOException {\n localport = port;\n }" ]
[ "0.63162154", "0.62248933", "0.6082256", "0.5844826", "0.5802217", "0.5757216", "0.5669773", "0.558958", "0.55893284", "0.55859995", "0.5549105", "0.55307335", "0.55085224", "0.55014914", "0.5484542", "0.54760945", "0.54656726", "0.54566437", "0.54314137", "0.5407661", "0.5394852", "0.537809", "0.53525364", "0.5342782", "0.53330094", "0.5302278", "0.52955306", "0.52907103", "0.52907103", "0.52907103", "0.52907103", "0.52907103", "0.5280193", "0.5278896", "0.5272775", "0.5270164", "0.5258711", "0.5248726", "0.5246144", "0.5236284", "0.5216924", "0.5208881", "0.52064735", "0.52062786", "0.5187586", "0.51867837", "0.518423", "0.5175451", "0.51689595", "0.5161814", "0.5161814", "0.5144813", "0.514048", "0.5138034", "0.5133352", "0.51111174", "0.51000124", "0.50948936", "0.5061534", "0.50477815", "0.5044817", "0.5044373", "0.5036797", "0.50314397", "0.5031305", "0.50281227", "0.502459", "0.5017541", "0.50057864", "0.5004958", "0.49812225", "0.49807552", "0.4980576", "0.49769905", "0.4976368", "0.49748114", "0.49712172", "0.4970521", "0.4964253", "0.49617395", "0.49605706", "0.49571759", "0.49563885", "0.49469346", "0.4946915", "0.49279076", "0.49215344", "0.49144104", "0.49139434", "0.4911563", "0.49106574", "0.49037102", "0.49033713", "0.4902897", "0.4897388", "0.48957315", "0.4893824", "0.4890151", "0.4878147", "0.48767176" ]
0.64898384
0
Used in MainActivity to send simple string messages. Creates a packet holding the message and sends it to the host address and port number.
public void sendMessage(String message) { final String msg = message; new Thread() { @Override public void run() { DatagramPacket packet = new DatagramPacket(msg.getBytes(), msg.length(), host, port); try { datagramSocket.send(packet); Log.d(DEBUG_TAG, "sent packet"); Log.d(DEBUG_TAG, "host: " + host); Log.d(DEBUG_TAG, "port: " + port); } catch (IOException e) { e.printStackTrace(); } } }.start(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void send (String messageToSend) throws IOException {\n byte[] ba = messageToSend.getBytes();\n \n packetToSend = new DatagramPacket (ba, ba.length, serverIPAddress, PORT);\n \n //Envia el paquete por el socket.\n clientSocket.send(packetToSend);\n }", "public void send(String msg){\r\n\t\ttry{\r\n\t\t\tbyte[] buf = msg.getBytes();\r\n \tInetAddress address = InetAddress.getByName(server);\r\n \tDatagramPacket packet = new DatagramPacket(buf, buf.length, address, PORT);\r\n \tsocket.send(packet);\r\n }catch(Exception e){}\r\n\t\t\r\n\t}", "private void sendRequest( String msg ){ \r\n\r\n\t\tRequest message = new Request(); // construction of Request object\r\n\t\tmessage.c = c_id;\r\n\t\tmessage.s = seq_number;\r\n\t\tmessage.op = msg;\r\n\t\t\r\n\t\tString str_msg = message.toString(); //generate string message\r\n\t\tdisplayArea.append( \"\\nCLI\"+c_id+\" Sending packet containing: \" + str_msg + \"\\n\" );\r\n\t\t\t\t\r\n\t\tbyte data[] = str_msg.getBytes(); // convert to bytes\r\n\t\t \r\n\t\ttry{\t\t\t\t\t\t\t\t\t\r\n\t\t\tDatagramPacket sendPacket = new DatagramPacket( data, data.length, InetAddress.getLocalHost(), serverPort );\r\n\t\t\tsocket.send( sendPacket ); // send packet\r\n\t\t\tdisplayArea.append( \"Packet sent\\n\" );\r\n\t\t\tdisplayArea.setCaretPosition(\r\n\t\t\tdisplayArea.getText().length() );\r\n\t\t\tseq_number++; //increment seq_number\r\n\t\t}\r\n\t\tcatch ( IOException ioException )\r\n\t\t{\r\n\t\t\tdisplayMessage( ioException.toString() + \"\\n\" );\r\n\t\t\tioException.printStackTrace();\r\n\t\t} // end catch\r\n\t\t\r\n\t}", "void send(String message);", "public void send(String msg) throws IOException {\n\t\tbyte[] data = msg.getBytes() ;\n DatagramPacket packet = new DatagramPacket(data, data.length, host, port);\n s.send(packet);\n\t}", "private void bluetoothSendMsg(String s) {\n byte [] msgOnBuf;\n msgOnBuf = s.getBytes();\n try {\n outStream.write(msgOnBuf);\n } catch (IOException e) {\n Log.d(TAG,\"send message fail!\");\n }\n }", "void sendMessage(Message m) throws IOException {\n String msg = m.toString();\n\n buffer = msg.getBytes(\"Windows-1256\");\n toServer = new DatagramPacket(buffer, buffer.length,\n InetAddress.getByName(sendGroup), port);\n if (m.getType() == Message.DATA) {\n manager.mManager.addMessage(m);\n }\n\n System.out.println(getName() + \"-->\" + m);\n serverSocket.send(toServer);\n }", "@Override\r\n public void onClick(View v) {\n String msg = ed_msg.getText().toString();\r\n try {\r\n\t\t\t\t\tsend(HOST, PORT, msg.getBytes());\r\n\t\t\t\t\t\r\n\t \tmHandler.sendMessage(mHandler.obtainMessage()); \r\n\t \tcontent =HOST +\":\"+ msg +\"\\n\";\r\n\t\t\t\t} catch (IOException e) {\r\n\t\t\t\t\t// TODO Auto-generated catch block\r\n\t\t\t\t\te.printStackTrace();\r\n\t\t\t\t}\r\n }", "public void sendPacket(String data) throws IOException {\n\n BufferedWriter out = new BufferedWriter(new OutputStreamWriter(socket.getOutputStream()));\n out.write(data + \"\\0\");\n out.flush();\n }", "public void sendMessagePacket(String to, String message, Message.Type type) {\n Message msg = new Message(to, type);\n msg.setBody(message);\n xmppConnection.sendPacket(msg);\n// receiveMessage(connection);\n }", "static public void startSending(String add,int port,byte[] data,int mode){\n }", "public void sendString(String s) throws IOException{\n\t\tbyte[] b = s.getBytes();\n\t\tDatagramPacket packet = new DatagramPacket(b, b.length, mIP, port);\n\t\tmSocket.send(packet);\n\t}", "public abstract void send(String data, String toAddress);", "public void send(String message, InetAddress targetAddress, int targetPort ) throws Exception {\r\n if (datagramSocket==null) return;\r\n\r\n if (message==null)\r\n throw new Exception(\"Cannot send an empty message\");\r\n\r\n if (targetAddress ==null)\r\n throw new Exception(\"Invalid target address\");\r\n\r\n if (targetPort <= 0)\r\n throw new Exception(\"Invalid target port\");\r\n\r\n byte[] sendData = message.getBytes(UTF_16BE);\r\n DatagramPacket packet = new DatagramPacket(sendData, sendData.length, targetAddress, targetPort);\r\n datagramSocket.send(packet);\r\n }", "void sendData(String msg) throws IOException\n {\n if ( msg.length() == 0 ) return;\n//\n msg += \"\\n\";\n// Log.d(msg, msg);\n if (outputStream != null)\n outputStream.write(msg.getBytes());\n// myLabel.setText(\"Data Sent\");\n// myTextbox.setText(\" \");\n }", "private void sendBroadcast(String messageStr) {\n StrictMode.ThreadPolicy policy = new StrictMode.ThreadPolicy.Builder().permitAll().build();\n StrictMode.setThreadPolicy(policy);\n byte[] sendData = messageStr.getBytes();\n try {\n DatagramSocket sendSocket = new DatagramSocket(null);\n sendSocket.setReuseAddress(true);\n sendSocket.bind(new InetSocketAddress(9876));\n sendSocket.setBroadcast(true);\n\n //Broadcast to all IP addresses on subnet\n try {\n DatagramPacket sendPacket = new DatagramPacket(sendData, sendData.length, InetAddress.getByName(\"255.255.255.255\"), 9876);\n sendSocket.send(sendPacket);\n Log.i(getClass().getName(), \"Request packet sent to: 255.255.255.255 (DEFAULT)\");\n } catch (Exception e) {\n Log.e(\"sendBroadcast\", \"IOException: \" + e.getMessage());\n }\n } catch (IOException e) {\n Log.e(\"sendBroadcast\", \"IOException: \" + e.getMessage());\n }\n }", "public void onClickSend(View view) {\n //String string = editText.getText().toString();\n //serialPort.write(string.getBytes());\n //tvAppend(txtResponse, \"\\nData Sent : \" + string + \"\\n\");\n }", "public void send(String str) {\r\n\t\tif (s != null) {\r\n\t\t\ttry {\r\n\t\t\t\tdos.writeByte(LiteServer.STRING_CONST);\r\n\t\t\t\tdos.writeUTF(str);\r\n\t\t\t\tif (autoFlush) {\r\n\t\t\t\t\tdos.flush();\r\n\t\t\t\t}\r\n\t\t\t} catch (IOException e) {\r\n\t\t\t\t// TODO Auto-generated catch block\r\n\t\t\t\te.printStackTrace();\r\n\t\t\t}\r\n\r\n\t\t} else {\r\n\t\t\t// if the socket is null\r\n\t\t}\r\n\r\n\t}", "public void sendMsg(String address, String title, String content);", "public boolean Send(String message) {\r\n\t\t\r\n\t\t//Add a new line so it gets entered into the robot console \r\n\t\tmessage = message.concat(\"\\n\");\r\n\t\t\r\n\t\t//Construct ip address of Robot by team number \r\n\t\taddress = this.numberToAddress(NetConsole.window.getTeam());\r\n\t\t\r\n\t\t//deconstruct String into byte array \r\n\t\tbyte[] sendData = message.getBytes();\r\n\t\t\r\n\t\t//deconstruct packet for cleansing\r\n\t\tDatagramPacket packet = null;\r\n\t\t\r\n\t\t//reconstruct packet with default port \r\n\t\tpacket = new DatagramPacket(sendData, sendData.length, address, 6668);\r\n\t\ttry {\r\n\t\t\t//Send all the Packets!\r\n\t\t\tserverSocket.send(packet);\r\n\t\t} catch (IOException e) {\r\n\t\t\tNetConsole.window.error(\"Error Sending Packets\");\r\n\t\t\te.printStackTrace();\r\n\t\t\t\r\n\t\t\t//Just in case we want to know if the proccess was successful\r\n\t\t\treturn false;\r\n\t\t}\r\n\t\treturn true;\r\n\t\r\n\t}", "private void sendToClient(String string) {\n\t\r\n}", "public void sendDatagramPacket(String message){\r\n\t\ttry {\r\n\t\t\tInetAddress serverHost = InetAddress.getByName(this.serverIP);\t\r\n\t\t\tbyte[] byteMsg = message.getBytes();\r\n\t\t\tDatagramPacket request = new DatagramPacket(byteMsg, byteMsg.length, serverHost, this.serverPort);\r\n\t\t\tudpSocket.send(request);\r\n\t\t} catch (SocketException e) {\r\n\t\t\tSystem.err.println(\"# UDPClient Socket error: \" + e.getMessage());\r\n\t\t\te.printStackTrace();\r\n\t\t} catch (IOException e) {\r\n\t\t\tSystem.err.println(\"# UDPClient IO error: \" + e.getMessage());\r\n\t\t}\r\n\t}", "public void sendMessage(String s){\r\n\t\tsynchronized(msgToSend){ // synchronized to maintain thread-safety\r\n\t\t\tmsgToSend.append(s + \"\\n\");\r\n\t\t}\r\n\t}", "private void sendMessage(String message){\n\t\ttry{\n\t\t\toutput.writeObject(\"Punk Ass Server: \" + message);\n\t\t\toutput.flush();\n\t\t\tshowMessage(\"\\nPunk Ass Server: \" + message); \n\t\t}catch(IOException ioe){\n\t\t\tchatWindow.append(\"\\n Message not sent, try again or typing something else\");\n\t\t\t\n\t\t}\n\t\t\n\t}", "public void sendUdpMessageToESP() {\n\n DatagramPacket packet = null;\n try {\n packet = new DatagramPacket(message.getBytes(), message.length(), InetAddress.getByName(ESP_IPaddress), 6900);\n sender.send(packet);\n\n } catch (IOException e) {\n e.printStackTrace();\n }\n }", "public void send(Address from, String message);", "public void send(Packet packet);", "public void sendMessage(final String message) {\n\n Runnable runnable = new Runnable() {\n @Override\n public void run() {\n\n if (null != sendBuffer) {\n Log.d(TAG, \"Sending: \" + message);\n sendBuffer.println(message);\n sendBuffer.flush();\n }\n }\n };\n\n Thread thread = new Thread(runnable);\n thread.start();\n }", "void sendUnicast(InetAddress hostname, String message);", "public void sendPacket(String message) {\n try {\r\n Thread.sleep(1000);\r\n } catch (InterruptedException ie) {\r\n }\r\n\r\n if (ipAddress == null) {\r\n MessageEvent e = new MessageEvent(MessageType.SendWarning);\r\n e.description = \"cannot send message to unreported device\";\r\n e.HWid = HWid;\r\n RGPIO.message(e);\r\n } else if (status == PDeviceStatus.ACTIVE) {\r\n UDPSender.send(message, ipAddress, this, RGPIO.devicePort);\r\n }\r\n }", "void sendMessage(String msg);", "public void sendUdpMessageToDrone() {\n\n DatagramPacket packet = null;\n try {\n packet = new DatagramPacket(message.getBytes(), message.length(), InetAddress.getByName(\"127.0.0.1\"), 6000);\n sender.send(packet);\n\n } catch (IOException e) {\n e.printStackTrace();\n }\n }", "void transmit(String protocol, String message);", "public void onClick(View v) {\n setBottonSingleTest();\n viewPager.setCurrentItem(0);\n\n\n try{\n DatagramSocket socket = new DatagramSocket();\n byte[] buf = \"hello world\".getBytes();\n\n DatagramPacket packet = new DatagramPacket(buf,\n buf.length,\n InetAddress.getByName(\"255.255.255.255\"),\n 666);\n //给服务端发送数据\n socket.send(packet);\n socket.close();\n }catch (IOException e){\n System.out.println(e);\n }\n }", "public void sendUdpMessageToDrone(ActionEvent actionEvent) {\n\n String message = testmessagebox.getText();\n DatagramPacket packet = null;\n try {\n packet = new DatagramPacket(message.getBytes(), message.length(), InetAddress.getByName(\"127.0.0.1\"), 6000);\n sender.send(packet);\n\n } catch (IOException e) {\n e.printStackTrace();\n }\n }", "void SendPacket(int packetIdentifier);", "public void sendMessage(String message) {}", "private void sendMessage() {\n\t\tString text = myMessagePane.getText();\n\t\tMessage msg = new Message(text, myData.userName, myData.color);\n\n\t\tcommunicationsHandler.send(msg);\n\n\t\t// De-escape xml-specific characters\n\t\tXmlParser xmlParser = new XmlParser(myData);\n\t\tString outText = xmlParser.deEscapeXMLChars(msg.text);\n\t\tmsg.text = outText;\n\n\t\tmyMessagePane.setText(\"\");\n\t\tupdateMessageArea(msg);\n\n\t}", "void sendMulticast(String message);", "protected void sendToServer(String string) {\r\n System.out.println(\"Sending to server: \" + string);\r\n toServer.println(string);\r\n toServer.flush();\r\n }", "public void sendMessage(String message);", "public void onSend(View v){\n Socket msocket;\n try {\n msocket = IO.socket(\"http://10.0.2.2:9080/\");\n } catch (Exception e) {\n throw new RuntimeException(e);\n }\n //msocket=cApp.getSocket();\n msocket.connect();\n msocket.emit(\"sendTest\",\"fkg\");\n msocket.on(\"sendTest\",onSendTest);\n }", "public void sendPacket(Packet pPacket) {\n mPacket = pPacket;\r\n \r\n \r\n }", "@Override\n\tpublic void send(String msg) {\n\t\t\n\t\t\n\t\n\t}", "@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tif(!chatEditText.getText().toString().equals(\"\"))\n\t\t\t\t{\n\t\t\t\t\tString sendData = chatEditText.getText().toString();\n\t\t\t\t\tSendPacketTask task = new SendPacketTask (UDP_SERVER_PORT, wifi);\n\t\t\t\t\ttask.execute(sendData);\n\t\t\t\t\tchatEditText.setText(\"\");\n\t\t\t\t}\n\t\t\t}", "public void send(String message) {\n byte[] data = message.getBytes(Charset.forName(\"UTF-8\"));\n final Payload payload = new Payload(OPCODE_TEXT, data);\n\n new Thread(new Runnable() {\n @Override\n public void run() {\n webSocketConnection.sendInternal(payload);\n }\n\n }).start();\n }", "void sendRequest(String message);", "public void sendMsgToClient() {\n\n try {\n\n writer = new PrintWriter(new BufferedWriter(new OutputStreamWriter(socket.getOutputStream())), true);\n\n Log.d(TAG, \"The transmitted data:\" + msg);\n\n writer.println(msg);\n\n } catch (Exception e) {\n\n e.printStackTrace();\n\n }\n\n }", "@Override\n\tpublic void send(String msg) {\n\t}", "public static void main(String[] args) {\r\n\r\n\r\n System.out.println(\"Welcome to my Data Comms Protocol Project\");\r\n //Packet DataPacket1 = new Packet(55, \"hello world\");\r\n //DataPacket1.calcChecksum();\r\n //DataPacket1.calcStrToSend();\r\n //DataPacket1.TellMeAboutYourself();\r\n DataCommsMachine sender = new DataCommsMachine(\"Sammy the sender\");\r\n DataCommsMachine receiver = new DataCommsMachine(\"Rachel the receiver\");\r\n //System.out.println(\"Please enter the message you want to send via the packet switching network\");\r\n //String message = userInput.nextLine();\r\n String message = \"hello world this is a really long message that i will be using for debuging &*£(%^836578265 more stuff folowing this rubbish yooo wooo wooo\";\r\n System.out.println(\"the message \"+message+\" will now be prepared into packets and send. Bear with.....\");\r\n sender.preparePackets(message);\r\n\r\n }", "void sendMessage(String message) throws SocketIOException;", "public void sendToServer(String msg) throws IOException {\n if (clientSocket == null || output == null) {\n throw new SocketException(\"socket does not exist\");\n }\n\n // messageQueue.offer(msg);\n // sendFromMessageQueue();\n \n // 發送中文\n byte[] bytes = msg.getBytes(\"big5\");\n int[] ints = new int[bytes.length];\n for (int i = 0, l = bytes.length; i < l; i++) {\n ints[i] = bytes[i] & 0xff;\n output.write(ints[i]);\n }\n output.writeBytes(\"\\n\");\n }", "private void send(final String data) {\n\t\tif (null != PinPadController) {\n\t\t\tnew Thread() {\n\t\t\t\tpublic void run() {\n\t\t\t\t\tPinPadController.PINPad_sendToPinPad(data);\n\t\t\t\t};\n\t\t\t}.start();\n\t\t\tToast.makeText(this, \"send\", Toast.LENGTH_SHORT).show();\n\t\t}\n\t}", "public void sendString(String string) throws RemoteException, IOException, InterruptedException;", "public static void sendUdpPacket(String text, InetAddress address, int port, DatagramSocket socket) throws IOException {\n var buf = text.getBytes();\n\n // Step 2 : Create the datagramPacket for sending the data\n var DpSend = new DatagramPacket(buf, buf.length, address, port);\n\n // Step 3 : invoke the send call to actually send the data\n socket.send(DpSend);\n }", "public void send(final String data) throws IOException {\r\n\t\t//Writes the packet as a byte buffer, using the data from the packet and converting in to bytes\r\n\t\t//Adds an end-of-packet footer to the data\r\n\t\tif(channel.isConnected()) {\r\n\t\t\tchannel.write(ByteBuffer.wrap((data + \"%EOP%\").getBytes()));\r\n\t\t}\r\n\t}", "public static void sendMessage(String message) {\r\n\t\tbtService.write(message.getBytes());\r\n\t}", "public void sendMicroServer(String message, Long num) throws Exception {\n InetAddress ip = InetAddress.getByName(\"localhost\");\n \tDatagramPacket dp = new DatagramPacket(message.getBytes(), message.length(), ip, (int) (7000+num));\n \ttoMicroServer.send(dp);\n System.out.printf(\"Sending message '%s' to micro-service %s\\n\", message, num);\n\t\n }", "public void sendPacket() throws IOException {\n\t\tbyte[] buf = playerList.toString().getBytes();\n\n\t\t// send the message to the client to the given address and port\n\t\tInetAddress address = packet.getAddress();\n\t\tint port = packet.getPort();\n\t\tpacket = new DatagramPacket(buf, buf.length, address, port);\n\t\tsocket.send(packet);\n\t}", "private void formWriteBegin() {\n\t\tsendData = new byte[4];\n\t\tsendData[0] = 0;\n\t\tsendData[1] = 4;\n\t\tsendData[2] = 0;\n\t\tsendData[3] = 0;\n\t\t\n\t\t// Now that the data has been set up, let's form the packet.\n\t\tsendPacket = new DatagramPacket(sendData, 4, receivePacket.getAddress(),\n\t\t\t\treceivePacket.getPort());\t\n\t}", "public void sendMessageToMobile(final String str) {\r\n\r\n\t\tnew Thread(new Runnable() {\r\n\r\n\t\t\t@Override\r\n\t\t\tpublic void run() {\r\n\t\t\t\ttry {\r\n\t\t\t\t\tPrintWriter out = new PrintWriter(new OutputStreamWriter(s.getOutputStream(), \"utf-8\"), true);\r\n\r\n\t\t\t\t\tif (!str.isEmpty()){\r\n\t\t\t\t\t\tout.println(str);\r\n\t\t\t\t\t\tout.flush();\r\n\t\t\t\t\t\tSystem.out.println(\"sent to mobile: \"+ str);\r\n\t\t\t\t\t} \r\n\t\t\t\t}\r\n\t\t\t\tcatch (IOException e) {\r\n\t\t\t\t\te.printStackTrace();\r\n\t\t\t\t} \r\n\t\t\t}\r\n\t\t}).start();\r\n\t}", "public void onClickSend(View view) {\n String string = editText.getText().toString();\n serialPort.write(string.getBytes());\n tvAppend(textView, \"\\nData Sent : \" + string + \"\\n\");\n\n }", "public void send(String request){\n try {\n streamOut.writeUTF(request);\n streamOut.flush();\n connected = true;\n System.out.println(clientID+\": send: \"+request);\n } catch (IOException ioe) {\n System.out.println(ioe);\n System.out.println(clientID+\": failedToSend: \"+request+\": IOException: \"+ioe);\n }\n }", "public void send(String message) throws IOException {\r\n OutputStream stream = socket.getOutputStream();\r\n PrintWriter writer = new PrintWriter(stream);\r\n writer.println(message);\r\n writer.flush();\r\n }", "public void sendPing(PingMessage ping)\n {\n InetAddress host = ping.getIP();\n int port = ping.getPort();\n String msg = ping.getPayload();\n try\n {\n DatagramPacket packet = \n new DatagramPacket(msg.getBytes(), msg.length(), host, port);\n socket.send(packet);\n } \n catch (Exception ex)\n {\n System.out.println(\"UDPPinger Exception: \" + ex);\n }\n }", "public void sendData(String data) {\n\t\tIoBuffer buf = IoBuffer.allocate(data.getBytes().length + 10);\n\t\tbuf.put(data.getBytes());\n\t\tbuf.put((byte)0x00);\n\t\tbuf.flip();\n\t\tsendData(buf);\n\t}", "private void sendMessage(String message) {\n\t\t// Check that we're actually connected before trying anything\n\t\tif (mChatService.getState() != BluetoothCommService.STATE_CONNECTED) {\n\t\t\tToast.makeText(this, R.string.not_connected, Toast.LENGTH_SHORT)\n\t\t\t\t\t.show();\n\t\t\treturn;\n\t\t}\n\n\t\t// Check that there's actually something to send\n\t\tif (message.length() > 0) {\n\t\t\t// Get the message bytes and tell the BluetoothCommService to write\n\t\t\tbyte[] send = message.getBytes();\n\t\t\tmChatService.write(send);\n\n\t\t\t// Reset out string buffer to zero and clear the edit text field\n\t\t\tmOutStringBuffer.setLength(0);\n\t\t\t// mOutEditText.setText(mOutStringBuffer);\n\t\t}\n\t}", "public void send(){ \n\t\tserverAddress=tfTxtIpServer.getText();\n\t\tserverPort=\"3232\";\n\t\ttext=tfTxtMsg.getText();\n try{\n\t\t\t// get the \"registry\"\n registry=LocateRegistry.getRegistry(\n serverAddress,\n (new Integer(serverPort)).intValue()\n );\n\t\t // look up the remote object\n rmiServer=(ReceiveMessageInterface)(registry.lookup(\"rmiServer\"));\n\t\t\t// call the remote method\n rmiServer.receiveMessage(text);\n }\n catch(RemoteException e){\n e.printStackTrace();\n }\n catch(NotBoundException e){\n e.printStackTrace();\n } \n }", "public void sendPacket(String label, byte[] data) throws UnknownHostException {\n\t\tif (data != null && data.length + PACKET_HEADER_SIZE > SERVER_PACKET_MAX_SIZE) {\n\t\t\tSystem.err.println(\"Couldn't send packet, too much data. \");\n\t\t\treturn;\n\t\t}\n\t\t\n\t\twhile (label.length() < 4) \n\t\t\tlabel = label + \" \";\n\t\tbyte[] labelArray = Arrays.copyOf(label.getBytes(Charset.forName(\"UTF-8\")), 4);\n\t\t\n\t\tbyte[] portArray = new byte[4];\n\t\tportArray[0] = (byte) (socket.getLocalPort() >> 24 & 0xFF);\n\t\tportArray[1] = (byte) (socket.getLocalPort() >> 16 & 0xFF);\n\t\tportArray[2] = (byte) (socket.getLocalPort() >> 8 & 0xFF);\n\t\tportArray[3] = (byte) (socket.getLocalPort() & 0xFF);\n\t\t\n\t\tbyte[] header = addArrays(\n\t\t\t\taddArrays(\n\t\t\t\t\t\tlabelArray, InetAddress.getLocalHost().getAddress()), \n\t\t\t\tportArray);\n\t\t\n\t\tDatagramPacket packet;\n\t\tif (data == null) {\n\t\t\tpacket = new DatagramPacket(header, header.length, connectedIP, SERVER_PORT);\n\t\t}else {\n\t\t\tbyte[] completeData = addArrays(header, data);\n\t\t\tpacket = new DatagramPacket(completeData, completeData.length, connectedIP, SERVER_PORT);\n\t\t}\n\t\t\n\t\ttry {\n\t\t\tsocket.send(packet);\n\t\t} catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t}", "void send();", "void sendPacket(Packet p){\n InetAddress address=p.getDestination().getAddress();\n if (this.socket.isClosed()){\n return;\n }\n if (chatRooms.containsKey(address)){\n chatRooms.get(address).sendMessage(p);\n }else{\n Socket distant;\n Discussion discussion;\n try {\n distant = new Socket(address, NetworkManager.UNICAST_PORT);\n discussion = new Discussion(distant);\n discussion.addObserver(this);\n chatRooms.put(distant.getInetAddress(), discussion);\n new Thread(discussion).start();\n discussion.sendMessage(p);\n } catch (IOException e) {\n System.out.println(\"Erreur à l'envois d'un nouveau message\");\n }\n }\n }", "private void sendMessage() {\n if (mRecipientAddress == null) {\n if (mDevices.getSelectedItem() == null) {\n mStatusText.append(\"Please select a device to message.\\n\");\n return;\n }\n if (mMessage.getText() == null || mMessage.getText().toString().equals(\"\")) {\n mStatusText.append(\"Please enter a message to send.\\n\");\n return;\n }\n }\n WifiDirectClientAsyncTask t = new WifiDirectClientAsyncTask(this, mMessage.getText().toString());\n if (Build.VERSION.SDK_INT>=Build.VERSION_CODES.HONEYCOMB)\n t.executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR);\n else\n t.execute();\n }", "private void sendPacket(InetAddress address, byte[] data) {\n try {\n send.setAddress(address);\n send.setData(Encryption.encrypt(data));\n socket.send(send);\n } catch (Exception e) {\n e.printStackTrace();\n }\n }", "public abstract void send(String message) throws IOException;", "public void sendHelloMessage() {\n getSocketController().send(getMessageController().createHelloMessage(\"Сервер\", getUser().getName()));\n }", "private void sendMessage(String message) {\n if (mBtService.getState() != BluetoothService.STATE_CONNECTED) {\n Toast.makeText(this, R.string.not_connected, Toast.LENGTH_SHORT).show();\n return;\n }\n\n // Check that there's actually something to send\n if (message.length() > 0) {\n // Get the message bytes and tell the BluetoothChatService to write\n byte[] send = message.getBytes();\n mBtService.write(send);\n\n // Reset out string buffer to zero and clear the edit text field\n mOutStringBuffer.setLength(0);\n }\n }", "public void send(Message msg);", "public Message(Socket s, Packet p) {\n // userName = \"\";\n socket = s;\n packet = p;\n }", "public void sendMessage(String message) {\n\t\tsocketTextOut.println(message);\n\t\tsocketTextOut.flush();\n\t}", "@Override\r\n\tpublic void sendMessage(String message) {\n\t\t\r\n\t}", "public static void sendData(String message) {\n try // send object to server\n {\n output.writeObject(message);\n output.flush(); // flush data to output\n displayMessage(\"\\nSend to Server:\");\n displayMessage(\"\\n\" + message);\n } // end try\n catch (IOException ioException) {\n displayArea.append(\"\\nError writing object\");\n } // end catch\n }", "public static void broadcast(final Context context, String tContentString)\r\n\t\t\tthrows IOException {\r\n\r\n\t\tbyte[] buffer = tContentString.getBytes();\r\n\t\tDatagramPacket dataPacket;\r\n\t\tfinal DatagramSocket udpSocket = new DatagramSocket();\r\n\r\n\t\ttry {\r\n\t\t\tInetAddress address = InetAddress.getByName(broadcastAddress);\r\n\t\t\tdataPacket = new DatagramPacket(buffer, buffer.length, address,\r\n\t\t\t\t\t8000);\r\n\r\n\t\t\tudpSocket.send(dataPacket);\r\n\t\t\tfinal int port = udpSocket.getLocalPort();\r\n\t\t\tLog.d(tagString, \"SendUDP LocalPort: \" + port);\r\n\r\n\t\t\tnew Thread() {\r\n\t\t\t\tpublic void run() {\r\n\r\n\t\t\t\t\ttry {\r\n\t\t\t\t\t\tbyte data[] = new byte[1024];\r\n\t\t\t\t\t\tDatagramPacket packet = new DatagramPacket(data,\r\n\t\t\t\t\t\t\t\tdata.length);\r\n\t\t\t\t\t\tudpSocket.receive(packet);\r\n\t\t\t\t\t\tString result = new String(packet.getData(),\r\n\t\t\t\t\t\t\t\tpacket.getOffset(), packet.getLength());\r\n\t\t\t\t\t\tURI tServer = new URI(result);\r\n\t\t\t\t\t\tserverHost = tServer.getHost();\r\n\t\t\t\t\t\tserverPort = tServer.getPort();\r\n\t\t\t\t\t\tudpSocket.close();\r\n\t\t\t\t\t} catch (Exception e) {\r\n\t\t\t\t\t\t// TODO: handle exception\r\n\t\t\t\t\t\te.printStackTrace();\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\t\t\t}.start();\r\n\t\t} catch (UnknownHostException e) {\r\n\t\t\t// TODO Auto-generated catch block\r\n\t\t\tLog.e(tagString, \"UnKnown network Address, check if connected\");\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t}", "public void sendMessage(String message) {\n\t\ttry {\n\t\t\tout.writeUTF(message);\n\t\t\tserver.CommunicationLog.info(\"Sent:\" + message + \" to \" + clientSocket.getInetAddress().toString());\n\t\t} catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t}", "public void sendMessage(String message) {\n\t\tSystem.out.println(\"DEBUG : response sent by server = \" + message);\n\t\tprinter.println(message);\n\t}", "private void sendMessage(String message) {\n if (mChatService.getState() != BluetoothChatService.STATE_CONNECTED) {\n // Toast.makeText(this, R.string.not_connected, Toast.LENGTH_SHORT).show();\n return;\n }\n\n if (message.length() > 0) {\n byte[] send = message.getBytes();\n mChatService.write(send);\n mOutStringBuffer.setLength(0);\n\n }\n }", "private void writeData(String data) {\n try {\n outStream = btSocket.getOutputStream();\n } catch (IOException e) {\n }\n\n String message = data;\n byte[] msgBuffer = message.getBytes();\n\n try {\n outStream.write(msgBuffer);\n } catch (IOException e) {\n }\n }", "public final boolean sendString(final DatagramPacket mDatagramPacket,\n final String string) {\n try {\n // Create the byte buffer\n final byte[] buffer = string.getBytes(\"UTF-8\");\n // Create the UDP packet\n final DatagramPacket packet = new DatagramPacket(buffer,\n buffer.length, mDatagramPacket.getAddress(),\n mDatagramPacket.getPort());\n // And send the UDP packet\n mSocket.send(packet);\n // Print some information\n System.out.println(\"Sending message: \" + string);\n return true;\n } catch (final IOException exc) {\n System.out.println(\"Sending failed\");\n return false;\n }\n }", "public EchoClientHandler()\n {\n String data = \"hello zhang kylin \" ;\n firstMessage = Unpooled.buffer(2914) ;\n firstMessage.writeBytes(data.getBytes()) ;\n }", "@Override\r\n public void onCreate(Bundle savedInstanceState) {\r\n super.onCreate(savedInstanceState);\r\n setContentView(R.layout.activity_main);\r\n\r\n \r\n\t\tStrictMode.setThreadPolicy(new StrictMode.ThreadPolicy.Builder()\r\n\t\t.detectDiskReads()\r\n\t\t.detectDiskWrites()\r\n\t\t.detectNetwork() //or .detectAll() for all detectable problems\r\n\t\t.penaltyLog()\r\n\t\t.build());\r\n\t\tStrictMode.setVmPolicy(new StrictMode.VmPolicy.Builder()\r\n\t\t.detectLeakedSqlLiteObjects()\r\n\t\t.detectLeakedClosableObjects()\r\n\t\t.penaltyLog()\r\n\t\t.penaltyDeath()\r\n\t\t.build());\r\n \r\n tv_msg = (TextView) findViewById(R.id.TextView);\r\n ed_msg = (EditText) findViewById(R.id.EditText01);\r\n btn_send = (Button) findViewById(R.id.Button02);\r\n \r\n \r\n try {\r\n\t\t\tDatagramSocket =new DatagramSocket();\r\n\t\t} catch (SocketException e1) {\r\n\t\t\t// TODO Auto-generated catch block\r\n\t\t\te1.printStackTrace();\r\n\t\t}\r\n \r\n btn_send.setOnClickListener(new Button.OnClickListener() {\r\n\r\n @Override\r\n public void onClick(View v) {\r\n // TODO Auto-generated method stub\r\n String msg = ed_msg.getText().toString();\r\n try {\r\n\t\t\t\t\tsend(HOST, PORT, msg.getBytes());\r\n\t\t\t\t\t\r\n\t \tmHandler.sendMessage(mHandler.obtainMessage()); \r\n\t \tcontent =HOST +\":\"+ msg +\"\\n\";\r\n\t\t\t\t} catch (IOException e) {\r\n\t\t\t\t\t// TODO Auto-generated catch block\r\n\t\t\t\t\te.printStackTrace();\r\n\t\t\t\t}\r\n }\r\n });\r\n }", "private void sendMessage(String message) {\n\n // we need to encrypt message using destination public-key\n if (destinationPublicKey == null) return;\n\n /**\n * Encrypt Message Here\n */\n PublicKey publicKey = getPublicKey(Base64.decode(destinationPublicKey, Base64.URL_SAFE));\n KeyPair keyPair = new KeyPair(publicKey, null);\n SecurityKey securityKey = new SecurityKey(keyPair);\n String encryptedMessage = securityKey.encrypt(message);\n\n socket.emit(\"message\", encryptedMessage);\n\n // add raw text to recycler_view\n messages.add(new Message(nickname,messageEditText.getText().toString(),0));\n\n ChatAdapter adapter = new ChatAdapter(getApplicationContext(),messages);\n adapter.notifyDataSetChanged();\n\n chatRecyclerView.setAdapter(adapter);\n\n // clear text box\n messageEditText.setText(\"\");\n }", "void sent(String s);", "public void sendMessageToServer(String message) {\n if (outputStream != null) {\n outputStream.println(message);\n } else {\n System.out.println(\"No OutputStream!\");\n }\n }", "public void sendmsg(Message msg){\n try {\n oos.writeObject(new Datapacket(1, null, msg,null, null));\n } catch (IOException e) {\n e.printStackTrace();\n }\n }", "@Override\n public void run() {\n if (this.clientInterfaceTCP.getConnected())\n this.clientInterfaceTCP.sendString(this.messageToSend);\n }", "@Override\n\tprotected void onCreate(Bundle savedInstanceState) {\n\t\tsuper.onCreate(savedInstanceState);\n\t\tsetContentView(R.layout.main);\n\t\t\n\t\tmEditIP = (EditText) findViewById(R.id.editIP);\n\t\tmEditPort = (EditText)findViewById(R.id.editPort);\n\t\tmBtnSend = (Button)findViewById(R.id.button1);\n\t\tmUDPReturn = (TextView)findViewById(R.id.textShow);\n\t\t\n\t\tmBtnSend.setOnClickListener(new Button.OnClickListener(){\n\n\t\t\t/* (non-Javadoc)\n\t\t\t * @see android.view.View.OnClickListener#onClick(android.view.View)\n\t\t\t */\n\t\t\t@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\t// TODO Auto-generated method stub\n\t\t\t\tmUDPReturn.setText(\"Text string\");\n\t\t\t\tmSocketThread = new Thread(){\n\n\t\t\t\t\t/* (non-Javadoc)\n\t\t\t\t\t * @see java.lang.Thread#run()\n\t\t\t\t\t */\n\t\t\t\t\t@Override\n\t\t\t\t\tpublic void run() {\n\t\t\t\t\t\t// TODO Auto-generated method stub\n\t\t\t\t\t\tsuper.run();\n\t\t\t\t\t\tLog.i(LOG_TAG, \"start thread run\");\n\t\t\t\t\t\tDatagramSocket mDatagramSocket = null;\n\t\t\t\t\t\tInetAddress mRemoteAddress = null;\n\t\t\t\t\t\tint mRemotePort;\n\t\t\t\t\t\tDatagramPacket mPacket;\n\t\t\t\t\t\tString mBuffer = \"KVM,k1p0\";\n\t\t\t\t\t\t\n\t\t\t\t\t\ttry{\n\t\t\t\t\t\t\tmDatagramSocket = new DatagramSocket();\n\t\t\t\t\t\t}\n\t\t\t\t\t\tcatch(SocketException e1){\n\t\t\t\t\t\t\te1.printStackTrace();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t/*judge edit is null*/\n\t\t\t\t\t\tif(\"\".equals(mEditIP.getText().toString().trim())){\n\t\t\t\t\t\t\tLog.w(LOG_TAG, \"IP is null\");\n\t\t\t\t\t\t\tmDatagramSocket.close();\n\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t}\n\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\tLog.i(LOG_TAG, \"IP is \" + mEditIP.getText().toString());\n\t\t\t\t\t\t\tmRemoteAddress = InetAddress.getByName(mEditIP.getText().toString());\n\t\t\t\t\t\t} catch (UnknownHostException e) {\n\t\t\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif(\"\".equals(mEditPort.getText().toString().trim())){\n\t\t\t\t\t\t\tLog.w(LOG_TAG, \"Port is null\");\n\t\t\t\t\t\t\tmDatagramSocket.close();\n\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tmRemotePort = Integer.valueOf(mEditPort.getText().toString());\n\t\t\t\t\t\tLog.i(LOG_TAG, \"Port is \" + mRemotePort);\n\t\t\t\t\t\t\n\t\t\t\t\t\tmPacket = new DatagramPacket(mBuffer.getBytes(), mBuffer.length(),mRemoteAddress ,mRemotePort);\n\t\t\t\t\t\t\n\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\tmDatagramSocket.send(mPacket);\n\t\t\t\t\t\t} catch (IOException e) {\n\t\t\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tbyte[] mRecvBuf = new byte[1024];\n\t\t\t\t\t\tDatagramPacket mRecvPacket = new DatagramPacket(mRecvBuf, mRecvBuf.length);\n\t\t\t\t\t\t\n\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\tMessage mMsg = new Message();\n\t\t\t\t\t\t\tBundle mData = new Bundle();\n\t\t\t\t\t\t\tmDatagramSocket.receive(mRecvPacket);\n\t\t\t\t\t\t\tString mRecvString = new String(mRecvPacket.getData(), mRecvPacket.getOffset(), mRecvPacket.getLength());\n\t\t\t\t\t\t\tLog.i(LOG_TAG, \"result = \" + mRecvString);\n\t\t\t\t\t\t\tmData.putString(\"Socket\", mRecvString);\n\t\t\t\t\t\t\tmMsg.setData(mData);\n\t\t\t\t\t\t\tmSocketHandler.sendMessage(mMsg);\n\t\t\t\t\t\t} catch (IOException e) {\n\t\t\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tmDatagramSocket.close();\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t};\n\t\t\t\t\n\t\t\t\tmSocketThread.start();\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\n\t\t);\n\t}", "public void sendMsg(String message, InetAddress IP, int port){\n\t\tif(port < 0) {\n\t\t\treturn;\n\t\t}\n\t\tSystem.out.println(\"Sending message from server: \" + message + \"to: \" + IP + \":\" + port);\n\t\tbyte[] msg = message.getBytes();\n\n\t\tDatagramPacket packet = new DatagramPacket(msg, msg.length, IP, port);\n\t\ttry {\n\t\t\tserverSocket.send(packet);\n\t\t} catch (IOException e) {\n\t\t\tSystem.out.println(\"Error broadcasting message: \" + e.toString());\n\t\t\treturn;\n\t\t}\n\t}", "public void send( String data ) {\n SendRunnable sendRunnable = new SendRunnable( data );\n Thread sendThread = new Thread( sendRunnable );\n sendThread.start();\n }", "public void write(String message) {\n Log.d(TAG, \"...Data to send: \" + message + \"...\");\n byte[] msgBuffer = message.getBytes();\n try {\n mmOutStream.write(msgBuffer);\n } catch (IOException e) {\n Log.d(TAG, \"...Error data send: \" + e.getMessage() + \"...\");\n }\n }", "public void write(String message) {\n Log.d(TAG, \"...Data to send: \" + message + \"...\");\n byte[] msgBuffer = message.getBytes();\n try {\n mmOutStream.write(msgBuffer);\n } catch (IOException e) {\n Log.d(TAG, \"...Error data send: \" + e.getMessage() + \"...\");\n }\n }", "protected void sendMessage() throws IOException {\r\n\t\tif (smscListener != null) {\r\n\t\t\tint procCount = processors.count();\r\n\t\t\tif (procCount > 0) {\r\n\t\t\t\tString client;\r\n\t\t\t\tSimulatorPDUProcessor proc;\r\n\t\t\t\tlistClients();\r\n\t\t\t\tif (procCount > 1) {\r\n\t\t\t\t\tSystem.out.print(\"Type name of the destination> \");\r\n\t\t\t\t\tclient = keyboard.readLine();\r\n\t\t\t\t} else {\r\n\t\t\t\t\tproc = (SimulatorPDUProcessor) processors.get(0);\r\n\t\t\t\t\tclient = proc.getSystemId();\r\n\t\t\t\t}\r\n\t\t\t\tfor (int i = 0; i < procCount; i++) {\r\n\t\t\t\t\tproc = (SimulatorPDUProcessor) processors.get(i);\r\n\t\t\t\t\tif (proc.getSystemId().equals(client)) {\r\n\t\t\t\t\t\tif (proc.isActive()) {\r\n\t\t\t\t\t\t\tSystem.out.print(\"Type the message> \");\r\n\t\t\t\t\t\t\tString message = keyboard.readLine();\r\n\t\t\t\t\t\t\tDeliverSM request = new DeliverSM();\r\n\t\t\t\t\t\t\ttry {\r\n\t\t\t\t\t\t\t\trequest.setShortMessage(message);\r\n\t\t\t\t\t\t\t\tproc.serverRequest(request);\r\n\t\t\t\t\t\t\t\tSystem.out.println(\"Message sent.\");\r\n\t\t\t\t\t\t\t} catch (WrongLengthOfStringException e) {\r\n\t\t\t\t\t\t\t\tSystem.out.println(\"Message sending failed\");\r\n\t\t\t\t\t\t\t\tevent.write(e, \"\");\r\n\t\t\t\t\t\t\t} catch (IOException ioe) {\r\n\t\t\t\t\t\t\t} catch (PDUException pe) {\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\tSystem.out.println(\"This session is inactive.\");\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t} else {\r\n\t\t\t\tSystem.out.println(\"No client connected.\");\r\n\t\t\t}\r\n\t\t} else {\r\n\t\t\tSystem.out.println(\"You must start listener first.\");\r\n\t\t}\r\n\t}" ]
[ "0.6790634", "0.67081386", "0.66483474", "0.6600215", "0.655483", "0.6536981", "0.6438391", "0.64323616", "0.64217025", "0.6377267", "0.6301495", "0.62994516", "0.62965703", "0.62905574", "0.624064", "0.6232033", "0.62027377", "0.6197615", "0.6160901", "0.615078", "0.6150342", "0.61459535", "0.6141292", "0.6126067", "0.6100528", "0.60942954", "0.60907495", "0.60877347", "0.60843974", "0.60725695", "0.6072542", "0.6046082", "0.6039601", "0.60344297", "0.6023777", "0.6014675", "0.5978556", "0.59633213", "0.5951385", "0.59422725", "0.5936724", "0.59242374", "0.59111047", "0.59108216", "0.5905785", "0.5905108", "0.59039", "0.58840746", "0.58835924", "0.5871116", "0.5868962", "0.58602667", "0.58593154", "0.58522856", "0.58489525", "0.582544", "0.5824603", "0.5815678", "0.581235", "0.5811781", "0.58100563", "0.58099246", "0.5805532", "0.5803088", "0.58012897", "0.5784446", "0.5782887", "0.57811236", "0.57771474", "0.57711315", "0.57711005", "0.5766717", "0.5765364", "0.5756484", "0.57532305", "0.5745739", "0.5739978", "0.57359046", "0.5730158", "0.5727889", "0.572718", "0.5716483", "0.57140124", "0.5713797", "0.57105947", "0.5697892", "0.5686805", "0.56855", "0.5666344", "0.5661795", "0.5660631", "0.5660021", "0.5655303", "0.5653201", "0.56491184", "0.56458586", "0.56299275", "0.56298894", "0.56298894", "0.5624899" ]
0.68217576
0
Adds the given values to the first set of values. One of the UnitStatValues should represent a bonus (e.g. it doesn't max sense to add 2 unit's hps together)
public UnitStatValues add(UnitStatValues other) { str += other.str; agi += other.agi; fort += other.fort; percep += other.percep; maxHp += other.maxHp; maxSp += other.maxSp; damage += other.damage; atkspd += other.atkspd; atk += other.atk; def += other.def; force += other.force; stab += other.stab; dodge += other.dodge; armor += other.armor; armorPiercing += other.armorPiercing; percentArmor += other.percentArmor; armorNegate += other.armorNegate; rangedDamage += other.rangedDamage; rangedAtk += other.rangedAtk; rangedForce += other.rangedForce; return this; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public final void plus (Unit unit) throws ArithmeticException {\n\t\tboolean error = false;\n\t\tif (((mksa|unit.mksa)&_abs)!=0) {\t// Special dates\n\t\t\tif (mksa != (_abs^unit.mksa)) error = true;\n\t\t\telse mksa |= _abs;\t\t\t// Result is a date\n\t\t}\n\t\telse error = (mksa&(~_pic)) != (unit.mksa&(~_pic));\n\t\tif (error) throw new ArithmeticException\n\t\t(\"****Unit: can't combine: \" + symbol + \" + \" + unit.symbol);\n\t\t/* Addition in log scale: a+b=a+f*log(1.+10^((b-a)/f)) */\n\t\tvalue += (unit.value*unit.factor)/factor;\n\t}", "public Stats addToAllStats(int amountToAdd) {\n Stats sum = new Stats();\n for (Stat stat : Stat.values()) {\n Integer value = getStat(stat);\n if (value != null) {\n sum.setStat(stat, value + amountToAdd);\n }\n }\n return sum;\n }", "public final void add() {\n\t\tif (size > 1) {\n\n\t\t\tdouble topMostValue = pop();\n\t\t\tdouble secondTopMostValue = pop();\n\t\t\tpush(secondTopMostValue + topMostValue);\n\t\t}\n\t}", "public Measurement addValues(List<ProbeValue> values) {\n\tattributes.addAll(values);\n\treturn this;\n }", "public static Stats of(double... values) {\n/* 122 */ StatsAccumulator acummulator = new StatsAccumulator();\n/* 123 */ acummulator.addAll(values);\n/* 124 */ return acummulator.snapshot();\n/* */ }", "public void addValues(String variable, int value, String unit, String metaType, boolean update)\n\t{\n\t\t// Convert single number into array, to store as dataset\n\t\tint[] values = new int[1];\n\t\tvalues[0] = value;\n\t\taddValues(variable, values, unit, metaType, update);\n\t}", "public void addUnits(Unit[] u)\r\n\t{\r\n\t\tfor(int i = 0; i < u.length; i++)\r\n\t\t{\r\n\t\t\tthis.addUnit(u[i]);\r\n\t\t}\r\n\t}", "@Override\n\tpublic void\n\tscalarAdd( double value )\n\t{\n\t\tdata[0] += value;\n\t\tdata[1] += value;\n\t\tdata[2] += value;\n\t}", "public UnitStatValues subtract(UnitStatValues other) {\n\t\tstr -= other.str;\n\t\tagi -= other.agi;\n\t\tfort -= other.fort;\n\t\tpercep -= other.percep;\n\n\t\tmaxHp -= other.maxHp;\n\t\tmaxSp -= other.maxSp;\n\n\t\tdamage -= other.damage;\n\t\t\n\t\tatkspd -= other.atkspd;\n\t\t\n\t\tatk -= other.atk;\n\t\tdef -= other.def;\n\t\tforce -= other.force;\n\t\tstab -= other.stab;\n\t\tdodge -= other.dodge;\n\n\t\tarmor -= other.armor;\n\t\tarmorPiercing -= other.armorPiercing;\n\t\tpercentArmor -= other.percentArmor;\n\t\tarmorNegate -= other.armorNegate;\n\t\t\n\t\trangedDamage -= other.rangedDamage;\n\t\trangedAtk -= other.rangedAtk;\n\t\trangedForce -= other.rangedForce;\n\n\t\treturn this;\n\t}", "public void addValues(String variable, float value, String unit, String metaType, boolean update) throws Exception\n\t{\n\t\t// Convert single number into array, to store as dataset\n\t\tfloat[] values = new float[1];\n\t\tvalues[0] = value;\n\t\taddValues(variable, values, unit, metaType, update);\n\t}", "private void addMetrics(List<MetricDatum> list,\n MetricValues metricValues,\n StandardUnit unit) {\n List<MachineMetric> machineMetrics = metricValues.getMetrics();\n List<Long> values = metricValues.getValues();\n for (int i=0; i < machineMetrics.size(); i++) {\n MachineMetric metric = machineMetrics.get(i);\n long val = values.get(i).longValue();\n // skip zero values in some cases\n if (val != 0 || metric.includeZeroValue()) {\n MetricDatum datum = new MetricDatum()\n .withMetricName(metric.getMetricName())\n .withDimensions(\n new Dimension()\n .withName(metric.getDimensionName())\n .withValue(metric.name()))\n .withUnit(unit)\n .withValue((double) val)\n ;\n list.add(datum);\n }\n }\n }", "public void sumValues(){\n\t\tint index = 0;\n\t\tDouble timeIncrement = 2.0;\n\t\tDouble timeValue = time.get(index);\n\t\tDouble packetValue;\n\t\twhile (index < time.size()){\n\t\t\tDouble packetTotal = 0.0;\n\t\t\twhile (timeValue < timeIncrement && index < packets.size()){\n\t\t\t\ttimeValue = time.get(index);\n\t\t\t\tpacketValue = packets.get(index);\n\t\t\t\tpacketTotal= packetTotal + packetValue;\n\t\t\t\tindex = index + 1;\n\t\t\t}\n\t\t\tArrayList<Double> xy = new ArrayList<Double>();\n\t\t\txy.add(timeIncrement);\n\t\t\txy.add(packetTotal);\n\t\t\ttotalIncrements.add(xy);\n\t\t\t// to get max and min need separate arrays\n\t\t\ttimeIncrements.add(timeIncrement);\n\t\t\tbyteIncrements.add(packetTotal);\n\t\t\ttimeIncrement = timeIncrement + 2.0;\t\n\t\t}\n\t\treturn;\n\n\t}", "protected void updateValues(){\n double total = 0;\n for(int i = 0; i < values.length; i++){\n values[i] = \n operation(minimum + i * (double)(maximum - minimum) / (double)numSteps);\n \n total += values[i];\n }\n for(int i = 0; i < values.length; i++){\n values[i] /= total;\n }\n }", "public static void singleValue(String name, double value, String units) {\n openMinorTag(\"stat\");\n attribute(\"name\",name);\n attribute(\"value\",value);\n if (units != null) attribute(\"units\",units);\n closeMinorTag();\n }", "public void add(double val) {\n sum += val;\n sumQ += val * val;\n count++;\n if (val < min) min = val;\n if (val > max) max = val;\n }", "public void add(MyDouble val) {\n this.setValue(this.getValue() + val.getValue());\n }", "public static Stats of(int... values) {\n/* 133 */ StatsAccumulator acummulator = new StatsAccumulator();\n/* 134 */ acummulator.addAll(values);\n/* 135 */ return acummulator.snapshot();\n/* */ }", "public void addValue() {\n addValue(1);\n }", "public void addValues(String variable, double value, String unit, String metaType, boolean update)\n\t{\n\t\t// Convert single number into array, to store as dataset\n\t\tDouble[][] values = new Double[1][1];\n\t\tvalues[0][0] = value;\n\t\taddValues(variable, values, unit, metaType, update);\n\t}", "void addStatisticsCalculation(ProcessingUnitStatisticsId statisticsId);", "private void calculeStatAdd() {\n resourceA = this.getContext().getGame().getPlayer(idPlayer).getInventory().getValueRessource(type);\n int win = resourceA - resourceB;\n int diff = (resourceB - resourceA) + value;\n this.getContext().getStats().incNbRessourceWinPlayers(idPlayer,type,win);\n this.getContext().getStats().incNbRessourceExtendMaxPlayers(idPlayer,type,diff);\n }", "public Statistic(String name, double[] values) {\n super(name);\n moments = new double[5];\n reset();\n if (values != null) {\n collect(values);\n }\n }", "void add(double val) {\r\n\t\tresult = result + val;\r\n\t}", "@Override\n\tpublic double add(double in1, double in2) {\n\t\treturn 0;\n\t}", "public Statistic(double[] values) {\n this(null, values);\n }", "public int changeUnits(int additionalUnits){\n if (units + additionalUnits < 1){\n return 0;\n }\n else {\n units += additionalUnits;\n return units;\n }\n }", "@Override\r\n\tpublic double add() {\r\n\t\tdouble outcome = firstVariable + secondVariable;\r\n\t\treturn outcome;\r\n\t\r\n\t}", "private void addValueToStatMap(HashMap<String, ArrayList<Double>> map, String key, Double value) {\r\n if (!map.containsKey(key)) {\r\n map.put(key, new ArrayList<Double>());\r\n }\r\n map.get(key).add(value);\r\n }", "public UnitsBuilder addUnit(double valueInBaseUnit, String... unitSymbolsPatterns) {\n units.add(new Unit(unitSymbolsPatterns, valueInBaseUnit));\n return this;\n }", "public void addValue(double newValue) {\n\t\tdouble delta = newValue - mean;\n\t\tn += 1;\n\t\tmean += delta / n;\n\t\ts += delta * (newValue - mean);\n\t}", "public void addValue(double value) {\r\n\t\tvalues.add(value);\r\n\t}", "public static void add(float[] u, float[] v) {\n for (int i = 0; i < u.length; i++) {\n u[i] += v[i];\n }\n }", "public void merge(Statistics statistics) {\n Set<Entry<String, Integer>> entrySet = statistics.entrySet();\n for (Entry<String, Integer> entry : entrySet) {\n Integer integer = super.get(entry.getKey());\n if (integer == null) {\n super.put(entry.getKey(), entry.getValue());\n } else {\n super.put(entry.getKey(), Integer.valueOf(integer.intValue() + entry.getValue().intValue()));\n }\n\n }\n }", "public void addToUnitPrice(BigDecimal addThisValue) {\r\n if (getItemUnitPrice() == null) {\r\n setItemUnitPrice(BigDecimal.ZERO);\r\n }\r\n BigDecimal addedPrice = getItemUnitPrice().add(addThisValue);\r\n setItemUnitPrice(addedPrice);\r\n }", "public void add()\r\n {\r\n resultDoubles = Operations.addition(leftOperand, rightOperand);\r\n resultResetHelper();\r\n }", "private void UpdateAdds() {\n Adds = (Level + CurrentHealth)/10;\n }", "@Override\n\tpublic void onAdd(final CSimulation game, final CUnit unit) {\n\t\tfinal List<CUnitAttack> unitSpecificAttacks = unit.getUnitSpecificAttacks();\n\t\tfinal int originalAttackCount = unitSpecificAttacks.size();\n\t\toriginalBaseAttackRates = new float[originalAttackCount];\n\t\tfor (int i = 0; i < originalAttackCount; i++) {\n\t\t\tfinal CUnitAttack originalAttack = unitSpecificAttacks.get(i);\n\t\t\toriginalBaseAttackRates[i] = originalAttack.getCooldownTime();\n\t\t}\n\t\tunit.setDisableAttacks(true);\n\t\tsuper.onAdd(game, unit);\n\t}", "private void addAllStats(\n java.lang.Iterable<? extends net.iGap.proto.ProtoChannelGetMessagesStats.ChannelGetMessagesStatsResponse.Stats> values) {\n ensureStatsIsMutable();\n com.google.protobuf.AbstractMessageLite.addAll(\n values, stats_);\n }", "public static UnitP Addition(UnitP first, UnitP second)\n {\n return OperationsPublic.PerformUnitOperation\n (\n first, second, Operations.Addition,\n OperationsOther.GetOperationString(first, second, Operations.Addition)\n );\n }", "public void addValues(List newValues) {\n synchronized (values) {\n values.addAll(newValues);\n }\n }", "public void addStats(Stats that) {\n totalRequests += that.totalRequests;\n remoteRequests += that.remoteRequests;\n totalCancels += that.totalCancels;\n totalFails += that.totalFails;\n remoteData += that.remoteData;\n localData += that.localData;\n totalLatency += that.totalLatency;\n }", "public static Stats of(Iterable<? extends Number> values) {\n/* 99 */ StatsAccumulator accumulator = new StatsAccumulator();\n/* 100 */ accumulator.addAll(values);\n/* 101 */ return accumulator.snapshot();\n/* */ }", "public void addAll(Object... values) {\n verifyModifiable();\n\n if (values.length == 1 && values[0] instanceof Tuple)\n addAll((Tuple) values[0]);\n else\n Collections.addAll(elements, values);\n }", "@Test\n\tpublic void addWorksForModeNone() {\n\t\tfinal FloatTimeSeries t0 = new FloatTreeTimeSeries();\n\t\tt0.addValues(TimeSeriesUtils.createStepFunction(10, 0, 10, 10, 0)); // constant function = 10\n\t\tfinal FloatTimeSeries t1 = new FloatTreeTimeSeries();\n\t\tt1.addValues(TimeSeriesUtils.createStepFunction(5, 20, 25, 20, 0)); // constant function = 20\n\t\tfinal ReadOnlyTimeSeries sum = MultiTimeSeriesUtils.add(Arrays.<ReadOnlyTimeSeries> asList(t0, t1), 0, 120, true, null, false);\n\t\tAssert.assertEquals(\"Time series sum has wrong number of data points\", 13, sum.size());\n\t\tAssert.assertEquals(\"Unexpected value in time series sum\", 30, sum.getValue(20).getValue().getIntegerValue());\n\t\tAssert.assertEquals(\"Unexpected value in time series sum\", 20, sum.getValue(45).getValue().getIntegerValue());\n\t\tAssert.assertEquals(\"Unexpected value in time series sum\", 10, sum.getValue(80).getValue().getIntegerValue());\n\t}", "public void add(Double addedAmount) {\n }", "public static void singleValue(String name, long value, String units) {\n openMinorTag(\"stat\");\n attribute(\"name\",name);\n attribute(\"value\",value);\n if (units != null) attribute(\"units\",units);\n closeMinorTag();\n }", "private void updateValue() {\n int minValue = 100; //Minimum value to be calculated, initialized to a large number\n value = 0; //Value reinitialized to 0\n for (Integer i : values) {\n if (i > value && i <= 21) {\n value = i; //Sets value to maximum value less than or equal to 21\n }\n if (i < minValue) {\n minValue = i; //Sets minimum value to lowest value in the list\n }\n }\n if (value == 0) {\n value = minValue; //Sets value to minValue if no values 21 or less\n }\n valueLabel.setText(\"Value: \" + value); //Sets text of value label\n if (value > 21) {\n bust(); //Busts if value greater than 21\n }\n }", "@Override\n public InterpreterValue add(InterpreterValue v) {\n\n // If the given value is a IntegerValue create a new DoubleValue from\n // the addition-result\n if(v instanceof IntegerValue) return new DoubleValue(getValue() + ((IntegerValue) v).getValue());\n\n // If the given value is a DoubleValue create a new DoubleValue from\n // the addition-result\n if(v instanceof DoubleValue) return new DoubleValue(getValue() + ((DoubleValue) v).getValue());\n\n // In other case just throw an error\n throw new Error(\"Operator '+' is not defined for type double and \" + v.getName());\n\n }", "public void add(Number v)\n\t{ total = total + v.doubleValue(); }", "public void addValues(String variable, Double[] values, String unit, String metaType, boolean update)\n\t{\n\t\tif(map.containsKey(variable) && update)\n\t\t{\n\t\t\tRecordingObject object = map.get(variable);\n\t\t\tobject.setValues(values);\n\t\t\tobject.setYValuesLenght(values.length);\n\t\t}\n\t\telse\n\t\t{\n\t\t\tRecordingObject o = new RecordingObject();\n\t\t\to.setMetaType(metaType);\n\t\t\to.setVariable(variable);\n\t\t\to.setUnit(unit);\n\t\t\to.setValues(values);\n\t\t\to.setDataType(Datatype.CLASS_FLOAT);\n\t\t\to.setDataBytes(8);\n\t\t\to.setYValuesLenght(values.length);\n\t\t\tmap.put(variable, o);\n\t\t}\n\t}", "private int getUnitListValue() {\r\n\t\tint value = 0;\r\n\t\tfor (Unit unit : this.unitList) {\r\n\t\t\tvalue += unit.getValue();\r\n\t\t}\r\n\t\treturn value;\r\n\t}", "public void addValues(String variable, int[] values, String unit, String metaType, boolean update)\n\t{\n\t\tRecordingObject o = new RecordingObject();\n\t\to.setMetaType(metaType);\n\t\to.setVariable(variable);\n\t\to.setUnit(unit);\n\t\to.setValues(values);\n\t\to.setDataType(Datatype.CLASS_INTEGER);\n\t\to.setDataBytes(4);\n\t\to.setYValuesLenght(values.length);\n\t\tif(map.containsKey(variable) && update)\n\t\t{\n\t\t\tRecordingObject object = map.get(variable);\n\t\t\tint[] oldValues = (int[]) object.getValues();\n\t\t\toldValues = ArrayUtils.addAll(oldValues, values);\n\t\t\tobject.setValues(oldValues);\n\t\t\tobject.setYValuesLenght(oldValues.length);\n\t\t}\n\t\telse\n\t\t{\n\t\t\tmap.put(variable, o);\n\t\t}\n\t}", "@Parameters({\"12, 2, 14\", \"3, 4, 7\", \"4, 4, 8\", \"1, 2, 3\", \"1, 2, 3\", \"10, 4, 14\", \"100, 100, 200\", \"50, 25, 75\",\n \"50, 25, 75\", \"30, 30, 60\", \"0, 0, 0\", \"2147483646, 1, 2147483647\"})\n public void testAddMethod(double a, double b, double result) {\n assertEquals(result, calc.add(a, b), 0.1);\n }", "private void addItemToAllRegisteredTypes(List<String> legTypes, StatType statType, double item) {\n\t\tfor ( String legType : legTypes ) {\n\n\t\t\t// ... finally add the \"item\" to the correct bin in the container:\n\t\t\tint idx = this.statsContainer.get(statType).getIndex(item) ;\n\t\t\tthis.statsContainer.get(statType).inc( legType, idx ) ;\n\n\t\t\t// also add it to the sums container:\n\t\t\tthis.sumsContainer.get(statType).addValue( legType, item ) ;\n\n\t\t}\n\t}", "protected void addMaterialStats(MaterialId location, IMaterialStats... stats) {\n allMaterialStats.computeIfAbsent(location, materialId -> new ArrayList<>())\n .addAll(Arrays.asList(stats));\n }", "@Override\r\n public void calculate() {\r\n // do the calculations\r\n this.categories = new String[]{\"one\", \"two\"};\r\n this.data = new double[]{75, 50};\r\n }", "protected void add() {\n\t\tfinal float previous = value;\n\t\tvalue = Math.min(max, value + incrementStep);\n\n\t\tif (value != previous) {\n\t\t\tupdateAndAlertListener();\n\t\t}\n\n\t\treturn;\n\t}", "private void addExactlyOne(Integer[] values){\n ArrayList<Integer> list = new ArrayList<>();\n clauses.add(new ArrayList<Integer>(Arrays.asList(values)));\n //negation of each combination of the variables (nchoose2)\n for (int i=0; i < values.length ; i++){\n for (int j=i+1; j < values.length; j++){\n ArrayList<Integer> clause = new ArrayList<Integer>();\n int firstNo = values[i];\n int secondNo = values[j];\n clause.add(firstNo*-1);\n clause.add(secondNo*-1);\n clauses.add(clause);\n }\n }\n }", "public void add (Double constant) {\n if (myCoefficients.size() == 0) {\n myCoefficients.add(constant);\n }\n else {\n double value = myCoefficients.get(0) + constant;\n myCoefficients.set(0, value);\n }\n\n }", "public static Stats of(long... values) {\n/* 145 */ StatsAccumulator acummulator = new StatsAccumulator();\n/* 146 */ acummulator.addAll(values);\n/* 147 */ return acummulator.snapshot();\n/* */ }", "private void addStats(net.iGap.proto.ProtoChannelGetMessagesStats.ChannelGetMessagesStatsResponse.Stats value) {\n if (value == null) {\n throw new NullPointerException();\n }\n ensureStatsIsMutable();\n stats_.add(value);\n }", "public void addValues(String variable, float[] values, String unit, String metaType, boolean update)\n\t{\n\t\tRecordingObject o = new RecordingObject();\n\t\to.setMetaType(metaType);\n\t\to.setVariable(variable);\n\t\to.setUnit(unit);\n\t\to.setValues(values);\n\t\t// H5Datatype type = new H5Dataype(CLASS_FLOAT, 8, NATIVE, -1);\n\t\to.setDataType(Datatype.CLASS_FLOAT);\n\t\to.setDataBytes(4);\n\t\to.setYValuesLenght(values.length);\n\t\tif(map.containsKey(variable) && update)\n\t\t{\n\t\t\tRecordingObject object = map.get(variable);\n\t\t\tfloat[] oldValues = (float[]) object.getValues();\n\t\t\toldValues = ArrayUtils.addAll(oldValues, values);\n\t\t\tobject.setValues(oldValues);\n\t\t\tobject.setYValuesLenght(oldValues.length);\n\t\t}\n\t\telse\n\t\t{\n\t\t\tmap.put(variable, o);\n\t\t}\n\t}", "@Override\n public void addTags(NBTStatsInfo nbtStats) {\n double value = FileHelper.getValue(this.values, nbtStats.random);\n nbtStats.addTag(this.name, new NBTTagFloat((float) value));\n }", "@Override\n\tpublic int add(int val1, int val2) {\n\t\tthis.test++;\n\t\tSystem.out.println(this.test);\n\t\treturn val1+val2;\n\t}", "public void add(int index, double value) {\n\t\t\n\t}", "public static String addToStatistics(){\n\t\tString addedStats = Start.addToStatistics();\n\t\t//add\n\t\t//e.g.: addedStats += MyReport();\n\t\treturn addedStats;\n\t}", "org.hl7.fhir.Quantity addNewValueQuantity();", "private void updateStats()\n\t{\n\n\t\tint[] temp = simulation.getStatValue();\n\t\tfor(int i = 0; i < temp.length; i++)\n\t\t{\n\t\t\tthis.statsValues[i].setText(Integer.toString(temp[i]));\n\t\t}\n\t\t\n\t\tint[] temp2 = simulation.getNumberInEachLine();\n\t\tfor(int i = 0; i < temp2.length; i++)\n\t\t{\n\t\t\tthis.eatValues[i].setText(Integer.toString(temp2[i]));\n\t\t}\n\t}", "public final void sum (Unit unit) throws ArithmeticException {\n\t\tdouble ls, dv;\n\t\tint error = 0;\n\t\tlong rlog, ulog;\n\t\tif (((mksa|unit.mksa)&_LOG) == 0) { \t// No log scale at all !\n\t\t\tthis.plus(unit); \n\t\t\treturn; \n\t\t}\n\t\tif (DEBUG>0) { dump(\"...sum:term1\"); unit.dump(\"...sum:term2\"); }\n\t\tif ((mksa&(~_LOG)) != (unit.mksa&(~_LOG))) throw new ArithmeticException\n\t\t(\"****Unit: can't sum: \" + symbol + \" + \" + unit.symbol);\n\t\trlog = mksa&(_log|_mag);\n\t\tulog = unit.mksa&(_log|_mag);\n\t\tif (rlog != ulog) {\t\t// Not the Same log scale -- convert\n\t\t\tUnit tunit = new Unit(this);\n\t\t\ttunit.convertFrom(unit);\t// Convert the argument unit to target.\n\t\t\tthis.sum(tunit);\t\t// Now, the units are the same!\n\t\t\treturn;\n\t\t}\n\t\t// Here, we have the same log scales\n\t\t// if (rlog == 0) { this.plus(unit); return; } -- already seen\n\t\tls = (rlog&_mag) != 0 ? -2.5 : 1.0 ;\n\t\t/* Addition in log scale: a+b=a+f*log(1.+10^((b-a)/f)) */\n\t\tdv = unit.value - value;\n\t\tvalue += ls*AstroMath.log(1.+(unit.factor/factor)*Math.exp(dv/ls)) ;\n\t}", "public void addValue(int i) {\n value = value + i;\n }", "public void add(Unit u) {\n getBody().getUnits().add(u);\n }", "void addStat(JSONArray src, String type, int stat) {\n\t\tif (src.isEmpty()) {\n\t\t\tsrc.add(0, type);\n\t\t\tsrc.add(1, stat);\n\t\t} else {\n\t\t\tstat = (Integer) src.get(1) + stat;\n\t\t\tsrc.set(1, stat);\n\t\t}\n\t}", "public void addValues(String variable, Double[][] values, String unit, String metaType, boolean update)\n\t{\n\t\tif(map.containsKey(variable) && update)\n\t\t{\n\t\t\tRecordingObject object = map.get(variable);\n\t\t\tobject.setValues(values);\n\t\t\tobject.setYValuesLenght(values.length);\n\t\t\tif(values[0].length > 1)\n\t\t\t{\n\t\t\t\tobject.setXValuesLenght(values[0].length);\n\t\t\t}\n\t\t}\n\t\telse\n\t\t{\n\t\t\tRecordingObject o = new RecordingObject();\n\t\t\to.setMetaType(metaType);\n\t\t\to.setVariable(variable);\n\t\t\to.setUnit(unit);\n\t\t\to.setValues(values);\n\t\t\to.setDataType(Datatype.CLASS_FLOAT);\n\t\t\to.setDataBytes(8);\n\t\t\to.setYValuesLenght(values.length);\n\t\t\tif(values[0].length > 1)\n\t\t\t{\n\t\t\t\to.setXValuesLenght(values[0].length);\n\t\t\t}\n\t\t\tmap.put(variable, o);\n\t\t}\n\t}", "public static void add(List<Double> vector, List<Double> toAdd) {\n for (int i = 0; i < vector.size(); i++) {\n double sum = vector.get(i) + toAdd.get(i);\n vector.set(i, sum);\n }\n }", "public double addToSpent(double addAmount){\r\n\t\tspent +=addAmount;\r\n\t\treturn spent;\r\n\t}", "public void add(double sthis, Vec vthat, double sthat);", "@Override\n public void step(final EvaluationContext theContext)\n {\n // pop the top 2 values and add them\n // and push the result onto the value stack\n //\n final Double theSecondOperand = theContext.popValue();\n final Double theFirstOperand = theContext.popValue();\n theContext.pushValue(theFirstOperand + theSecondOperand);\n }", "public AmmoAmountUncapped add(AmmoAmountUncapped r){\n Map<AmmoColor,Integer> newMap = new EnumMap<>(getAmounts());\n for (Map.Entry<AmmoColor, Integer> i: r.getAmounts().entrySet()){\n newMap.put(i.getKey(), getAmounts().get(i.getKey())+i.getValue());\n }\n return new AmmoAmountUncapped(newMap);\n }", "private static void add(List<Point> points, int param, double value) {\r\n add(points, param, value, false);\r\n }", "public void increaseStat(Stat stat, int amount) {\n int actualValue = getStat(stat);\n stats.put(stat, actualValue + amount);\n }", "public static Stats of(Iterator<? extends Number> values) {\n/* 111 */ StatsAccumulator accumulator = new StatsAccumulator();\n/* 112 */ accumulator.addAll(values);\n/* 113 */ return accumulator.snapshot();\n/* */ }", "public void jibxAddValues(List values) {\n if (values != null) {\n allocateValues();\n this.values.addAll(values);\n }\n }", "public void addAllMetrics(Iterable<String> values) {\n ensureMetricsIsMutable();\n AbstractMessageLite.addAll(values, this.metrics_);\n }", "public void addValue(Row value)\n\t{\n\t\tallValues.add(value);\n\t}", "@Override\n public void agg(double newVal)\n {\n aggVal += newVal;\n firstTime = false;\n }", "public void addTotal() {\n for (int i = 0; i < itemsInOrder.size(); i++) {\n this.dblTotal += itemsInOrder.get(i).getPrice();\n }\n }", "void add(double p1, double p2){\n this.p1 += p1;\n this.p2 += p2;\n }", "@Override\r\n\tpublic void addValues(final IScope scope, final IContainer values) {}", "public double add(double firstNumber, double secondNUmber){\n\t\treturn firstNumber + secondNUmber;\n\t}", "public int totalValue() {\r\n\t\tint total = 0;\r\n\t\tfor(Item item: items) {\r\n\t\t\ttotal = total + item.getValue();\r\n\t\t}\r\n\t\treturn total;\r\n\t}", "public void addFuel(double fuelToAdd){\n\n fuelRemaining = fuelRemaining + fuelToAdd;\n }", "public void testPlus() {\n \tMeasurement a = new Measurement(1,10);\n \tMeasurement b = new Measurement(1,13);\n \tMeasurement c = a.plus(b);\n \t\n assertTrue(a.getFeet() == 1);\n assertTrue(a.getInches() == 10);\n assertTrue(b.getFeet() == 2);\n assertTrue(b.getInches() == 1);\n \n assertTrue(c.getFeet() == 3);\n assertTrue(c.getInches() == 11);\n }", "public void test_getTypedValues_accuracy() {\n instance.addTypedValue(typedValue);\n assertEquals(\"TypedValue got incorrectly\", 1, instance.getTypedValues().size());\n }", "public static int addN(int... values) {\n\t\tint sum = 0;\n\t\tfor (int currentValue : values) {\n\t\t\tsum += currentValue;\n\t\t}\n\t\treturn sum;\n\t}", "public void modStat(double amount, Stat stat)\n\t{\n\t\tswitch(stat)\n\t\t{\n\t\t\tcase MAX_HEALTH:\n\t\t\t\tmaxHealth += amount;\n\t\t\t\tbreak;\n\t\t\tcase ATTACK:\n\t\t\t\tattack += amount;\n\t\t\t\tbreak;\n\t\t\tcase DEFENCE:\n\t\t\t\tdefence += amount;\n\t\t\t\tbreak;\n\t\t\tcase POTION_POWER:\n\t\t\t\tpotionPower += amount;\n\t\t\t\tbreak;\n\t\t\tcase HEALTH_ON_KILL:\n\t\t\t\thealthOnKill += amount;\n\t\t\t\tbreak;\n\t\t\tcase GOLD_ON_KILL:\n\t\t\t\tgoldOnKill += amount;\n\t\t\t\tbreak;\n\t\t\tcase MAX_HEALTH_ON_HIT:\n\t\t\t\tmaxHealthOnHit += amount;\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\t// Shouldn't ever happen\n\t\t\t\tbreak;\n\t\t}\n\t}", "public void add(int value) {\n m_value += value;\n }", "public double getThroughput( ArrayList<Double> values ) {\n\t\treturn sum(values);\n\t}", "@Override\n public void agg(Object newVal)\n {\n aggVal += (Double)newVal;\n firstTime = false;\n }", "public void add(Object incValue) {\n\t\tvalue = operate(\n\t\t\t\ttransform(value),\n\t\t\t\ttransform(incValue),\n\t\t\t\t(v1, v2) -> v1 + v2,\n\t\t\t\t(v1, v2) -> v1 + v2\n\t\t);\n\t}", "public float getTotalValue(StockStatus stockStatus[]) {\r\n\t\tfloat totalValue = getStocksValue(stockStatus) + getBalance();\r\n\t\treturn totalValue;\r\n\t}" ]
[ "0.57076013", "0.5678584", "0.5675949", "0.56439394", "0.5617978", "0.5535154", "0.5517211", "0.5514879", "0.5512836", "0.54330426", "0.5421005", "0.5402351", "0.5361583", "0.5312967", "0.53098935", "0.5281721", "0.52807754", "0.5239673", "0.5211566", "0.52079", "0.5201338", "0.5199522", "0.5186279", "0.5167036", "0.51659817", "0.5164482", "0.51476586", "0.5137516", "0.51294994", "0.51179296", "0.50997514", "0.50771177", "0.5077109", "0.5067441", "0.5055297", "0.50312835", "0.5018675", "0.5017856", "0.5015414", "0.49901745", "0.49832934", "0.49615127", "0.49567264", "0.49522194", "0.49508807", "0.49494466", "0.49446496", "0.4942425", "0.494134", "0.49273485", "0.492559", "0.49246562", "0.49235293", "0.49205434", "0.49135834", "0.4896534", "0.48855388", "0.48846874", "0.48740706", "0.48675954", "0.4853361", "0.48434663", "0.48343512", "0.48290366", "0.4828651", "0.48249802", "0.48202923", "0.48197344", "0.48118177", "0.4807573", "0.4807362", "0.4804859", "0.48042127", "0.4789575", "0.47841555", "0.47806707", "0.47703457", "0.47672424", "0.4748065", "0.47444907", "0.47301933", "0.47299513", "0.4728978", "0.47098845", "0.47068673", "0.47048697", "0.47025794", "0.4699806", "0.46991664", "0.46956092", "0.46925107", "0.46910578", "0.4685218", "0.46832722", "0.4669488", "0.46644711", "0.46556425", "0.46483934", "0.4646433", "0.46423063" ]
0.7514172
0
Subtracts from the second set of values from the first
public UnitStatValues subtract(UnitStatValues other) { str -= other.str; agi -= other.agi; fort -= other.fort; percep -= other.percep; maxHp -= other.maxHp; maxSp -= other.maxSp; damage -= other.damage; atkspd -= other.atkspd; atk -= other.atk; def -= other.def; force -= other.force; stab -= other.stab; dodge -= other.dodge; armor -= other.armor; armorPiercing -= other.armorPiercing; percentArmor -= other.percentArmor; armorNegate -= other.armorNegate; rangedDamage -= other.rangedDamage; rangedAtk -= other.rangedAtk; rangedForce -= other.rangedForce; return this; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public JavaPairRDD<String, Integer> substractExample(){\n return firstSet\n .subtractByKey(secondSet);\n }", "public void subtract(Vector rhs) {\r\n for (int i = 0; i < components.length; i++) {\r\n components[i] -= rhs.components[i];\r\n }\r\n }", "@Override\n\tpublic double subtract(double in1, double in2) {\n\t\treturn 0;\n\t}", "public static <T, Z> void subtract(List<T> list1, List<Z> list2) {\n int origSize = list1.size();\n outer:\n for (int i = 0; i < list1.size(); i++) {\n T item = list1.get(i);\n for (int j = 0; j < list2.size(); j++) {\n if (item.equals(list2.get(j))) {\n list1.remove(item);\n i--;\n continue outer;\n }\n }\n }\n }", "public static int minus(int value1, int value2){\r\n return value1 - value2;\r\n }", "private int[] subtract(int xStart, int[] x, int yStart, int[] y)\n {\n int iT = x.length - 1;\n int iV = y.length - 1;\n long m;\n int borrow = 0;\n\n do\n {\n m = (((long)x[iT]) & IMASK) - (((long)y[iV--]) & IMASK) + borrow;\n\n x[iT--] = (int)m;\n\n if (m < 0)\n {\n borrow = -1;\n }\n else\n {\n borrow = 0;\n }\n } while (iV >= yStart);\n\n while (iT >= xStart)\n {\n m = (((long)x[iT]) & IMASK) + borrow;\n x[iT--] = (int)m;\n\n if (m < 0)\n {\n borrow = -1;\n }\n else\n {\n break;\n }\n }\n\n return x;\n }", "private static int[] subtract(int xStart, int[] x, int yStart, int[] y)\n {\n int iT = x.length;\n int iV = y.length;\n long m;\n int borrow = 0;\n\n do\n {\n m = ((long)x[--iT] & IMASK) - ((long)y[--iV] & IMASK) + borrow;\n x[iT] = (int)m;\n\n// borrow = (m < 0) ? -1 : 0;\n borrow = (int)(m >> 63);\n }\n while (iV > yStart);\n\n if (borrow != 0)\n {\n while (--x[--iT] == -1)\n {\n }\n }\n\n return x;\n }", "public static ArrayList<Float> mathematicalSubtract(ArrayList<Float> firstWave, ArrayList<Float> secondWave) {\r\n ArrayList<Float> newWave = new ArrayList<>();\r\n //int size = 0;\r\n //if (firstWave.size() < secondWave.size()) {\r\n // size = firstWave.size();\r\n //} else {\r\n // size = secondWave.size();\r\n //}\r\n int size = getSize(firstWave,secondWave);\r\n for (int i = 0; i < size; i++) {\r\n newWave.add(i, firstWave.get(i) - secondWave.get(i));\r\n }\r\n return newWave;\r\n }", "public void subtract() {\n\t\t\n\t}", "public void testMinus() {\n \tMeasurement a = new Measurement(2,6);\n \tMeasurement b = new Measurement(1,5);\n \tMeasurement c = a.minus(b);\n \t\n assertTrue(a.getFeet() == 2);\n assertTrue(a.getInches() == 6);\n assertTrue(b.getFeet() == 1);\n assertTrue(b.getInches() == 5);\n \n assertTrue(c.getFeet() == 1);\n assertTrue(c.getInches() == 1);\n }", "public void subtract()\r\n {\r\n resultDoubles = Operations.subtraction(leftOperand, rightOperand);\r\n resultResetHelper();\r\n }", "public static void subtract(int[] n1, int[] n2, int[] result, int[]sign) {\n\t\tint b = n1.length-1;\n\t\tint carry = 0;\n\t\t\n\t\tboolean smaller = (compareTo(n2, n1) < 0);\n//\t\t// confirm that n2 is smaller than n1. If so, we reverse. Assume that\n//\t\t// n2 is smaller.\n//\t\tboolean smaller = true;\n//\t\tfor (int i = 0; i < n1.length; i++) {\n//\t\t\tif (n2[i] == n1[i]) { \n//\t\t\t\tcontinue;\n//\t\t\t}\n//\n//\t\t\t// Must be able to report by now...\n//\t\t\tif (n2[i] > n1[i]) {\n//\t\t\t\tsmaller = false;\n//\t\t\t}\n//\t\t\tbreak;\n//\t\t}\n\t\t\n\t\twhile (b >= 0) {\n\t\t\t\n\t\t\tint s = n1[b] - n2[b];\n\t\t\tif (!smaller) { s = -s; }\n\t\t\ts += carry;\n\t\t\tif (s >= 0) {\n\t\t\t\tresult[b] = s;\n\t\t\t\tcarry = 0;\n\t\t\t} else {\n\t\t\t\tcarry = -1;\n\t\t\t\tresult[b] = s + 10;\n\t\t\t}\n\t\t\t\n\t\t\tb--;\n\t\t}\n\t\t\n\t\tif (!smaller) {\n\t\t\tsign[0] = -1;\n\t\t} else {\n\t\t\tsign[0] = carry+0;\n\t\t}\n\t}", "@Override\n public SetI subtract(SetI other) {\n int[] newArr = new int[count];\n int i = 0;\n\n // For each element I have,\n for (Integer e : this) {\n // If you do not...\n if (!other.contains(e)) {\n newArr[i++] = e;\n }\n }\n\n return new Set(newArr, i);\n }", "public static SinglyLinkedList<Poly> subtraction(SinglyLinkedList.Entry<Poly> list1,\n\t\t\tSinglyLinkedList.Entry<Poly> list2) {\n\t\tSinglyLinkedList<Poly> list3 = new SinglyLinkedList();\n\t\twhile (list2 != null) {\n\t\t\tPoly p = list2.element;\n\t\t\tp.num = p.num * -1;\n\t\t\tlist3.add(p);\n\t\t\tlist2 = list2.next;\n\t\t}\n\t\treturn addition(list1, list3.head.next);\n\t}", "private static int[] subtract(int[] big, int[] little) {\n int bigIndex = big.length;\n int result[] = new int[bigIndex];\n int littleIndex = little.length;\n long difference = 0;\n\n // Subtract common parts of both numbers\n while (littleIndex > 0) {\n difference = (big[--bigIndex] & LONG_MASK) -\n (little[--littleIndex] & LONG_MASK) +\n (difference >> 32);\n result[bigIndex] = (int)difference;\n }\n\n // Subtract remainder of longer number while borrow propagates\n boolean borrow = (difference >> 32 != 0);\n while (bigIndex > 0 && borrow)\n borrow = ((result[--bigIndex] = big[bigIndex] - 1) == -1);\n\n // Copy remainder of longer number\n while (bigIndex > 0)\n result[--bigIndex] = big[bigIndex];\n\n return result;\n }", "public int subtraction(int a, int b){\n return a - b;\n }", "@Override\n\tpublic int sub(int val1, int val2) {\n\t\treturn val1 - val2;\n\t}", "public Inatnum subtract(Inatnum a){//purpose: to subtract 2 values\n\t\ttry {return(this.pred().subtract(a).pred());}//take the previous value of this and the previous value of a until one of them hits zero and then return the other value\n\t\tcatch(Exception e) {System.out.println(\"Error add: \"+ e.getMessage());// otherwise return an error, this needs to be greater than or equal to a otherise we'd get a negative\n\t\t\t\t \t\t\t\t\t\t\t// and there are no negative natural numbers\n\t\treturn null;}\n\t\t\t}", "public static <T extends Vector> T Substract(T a, T b,T result){\n if(Match(a,b)) {\n for (int i = 0; i < result.axis.length; i++) {\n result.axis[i] = a.axis[i] - b.axis[i];\n }\n return result;\n }\n return result;\n }", "public V difference(V v1, V v2);", "public void\n\tsub( Vector3 other )\n\t{\n\t\tdata[0] -= other.data[0];\n\t\tdata[1] -= other.data[1];\n\t\tdata[2] -= other.data[2];\n\t}", "public Polynomial subtraction(int position_1, int position_2) {\n Polynomial polynomial;\n if (collection.get(position_1).getLength() > collection.get(position_2).getLength())\n polynomial = new Polynomial(collection.get(position_1).getLength());\n else\n polynomial = new Polynomial(collection.get(position_2).getLength());\n\n for (int i = 0; i < polynomial.getLength(); i++) {\n double a, b;\n try {\n a = collection.get(position_1).getValue(i);\n } catch (Exception e) {\n a = 0;\n }\n try {\n b = collection.get(position_2).getValue(i);\n } catch (Exception e) {\n b = 0;\n }\n\n polynomial.setValue(i, a - b);\n }\n\n return polynomial;\n }", "default int subtract(int num1, int num2) {\n\t\treturn num1-num2;\n\t}", "int subtraction(int a, int b) {\n return a-b;\r\n }", "public void subtractRows(int i1,int i2){\n\t\tint n = length();\n\t\tif (i1 < 0 || i1 >= n || i2 < 0 || i2 >= n) {\n\t\t\tthrow new IllegalArgumentException();\n\t\t}\n\t\tfor (int k = 0; k < n; k++) {\n\t\t\tdouble c = get(i2, k);\n\t\t\tset(i2, k, c - get(i1, k));\n\t\t}\n\t}", "public static RuntimeValue subtract(RuntimeValue left, RuntimeValue right) throws RuntimeException {\n if (isDiscreteIntSamples(left, right)) {\n return new RuntimeValue(\n RuntimeValue.Type.DISCRETE_INT_SAMPLE,\n Operators.subtractIntegers(left.getDiscreteIntSample(), right.getDiscreteIntSample())\n );\n }\n\n if (isDiscreteFloatSamples(left, right)) {\n return new RuntimeValue(\n RuntimeValue.Type.DISCRETE_FLOAT_SAMPLE,\n Operators.subtractFloats(left.getDiscreteFloatSample(), right.getDiscreteFloatSample())\n );\n }\n\n if (isDiscreteFloatSample(left) && hasSingleValue(left.getDiscreteFloatSample()) && isContinuousSample(right)) {\n return new RuntimeValue(\n RuntimeValue.Type.CONTINUOUS_SAMPLE,\n right.getContinuousSample().add(-1 * left.getDiscreteFloatSample().single())\n );\n }\n\n if (isDiscreteFloatSample(right) && hasSingleValue(right.getDiscreteFloatSample()) && isContinuousSample(left)) {\n return new RuntimeValue(\n RuntimeValue.Type.CONTINUOUS_SAMPLE,\n left.getContinuousSample().add(-1 * right.getDiscreteFloatSample().single())\n );\n }\n\n throw new RuntimeException(\"Subtracting incompatible types\");\n }", "@Override\n\tpublic float subtrair(float op1, float op2) {\n\t\treturn op1 - op2;\n\t}", "@Override\n public Float minus(Float lhs, Float rhs) {\n\t\n\tfloat res = lhs - rhs;\n\treturn res;\n }", "@Override\r\n\tpublic int sub(int a,int b) {\n\t\treturn a-b;\r\n\t}", "public static List<Range<Long>> subtract(Range<Long> a, Range<Long> b) {\n\t\tRangeSet<Long> set = TreeRangeSet.create();\n\t\tset.add(a);\n\t\tset.remove(b);\n\t\treturn set.asRanges()\n\t\t\t\t.stream()\n\t\t\t\t.map(r -> toRange(lowerEndpoint(r), upperEndpoint(r)))\n\t\t\t\t.collect(Collectors.toList());\n\t}", "public Vector subtract (Vector other) {\n Vector t =new Vector(head.subtract(other.head));\n return t;\n }", "default DiscreteDoubleMap2D minus(DiscreteDoubleMap2D other) {\r\n\t\treturn (x, y) -> this.getValueAt(x, y) - other.getValueAt(x, y);\r\n\t}", "private void subtraction()\n\t{\n\t\tFun = Function.SUBTRACT; //Function set to determine what action should be taken later.\n\t\t\n\t\t\tsetLeftValue();\n\t\t\tentry.grabFocus();\n\t\t\n\t}", "public static VectorIntf subtract(VectorIntf x, VectorIntf y) {\r\n if (x==null) throw new IllegalArgumentException(\"1st arg is null\");\r\n if (y==null) throw new IllegalArgumentException(\"2nd arg is null\");\r\n final int n = x.getNumCoords();\r\n if (n!=y.getNumCoords())\r\n throw new IllegalArgumentException(\"dimensions don't match\");\r\n VectorIntf z = x.newInstance(); // x.newCopy();\r\n for (int i=0; i<n; i++) {\r\n try {\r\n z.setCoord(i, x.getCoord(i) - y.getCoord(i));\r\n }\r\n catch (parallel.ParallelException e) { // can never get here\r\n e.printStackTrace();\r\n }\r\n }\r\n return z;\r\n }", "public SVector subtract(SVector other) {\n this.x -= other.getX();\n this.y -= other.getY();\n this.z -= other.getZ();\n return this;\n }", "@Override\r\n\tprotected double operate(double d1, double d2) {\n\t\tSystem.out.println(\"减法求值\");\r\n\t\treturn d1-d2;\r\n\t}", "public Vector subtract(Vector other){\n\t\treturn new Vector(x-other.x, y-other.y, z-other.z);\n\t}", "@Test\n public void subtract() {\n assertEquals(\"Wrong vector subtract\", new Vector(1, 1, 1),\n new Vector(new Point3D(2, 3, 4)).subtract(new Vector(new Point3D(1, 2, 3))));\n\n }", "public static BIGNUM subtract(BIGNUM bn1, BIGNUM bn2) {\n\t\tBIGNUM newbn = new BIGNUM(-bn2.NUM, bn2.E);\n\t\treturn add(bn1, newbn);\n\t}", "public void substract(int sub) {\r\n value -= sub;\r\n }", "public Vector subtract(Vector other) {\n\t\treturn new Vector(x - other.x, y - other.y);\n\t}", "public int subtract(int number1, int number2)\n\t\tthrows CalculatorOperationException;", "public static Matrix subtract(Matrix first, Matrix second) {\n \n Matrix result = new Matrix(first.getRows(), first.getClumns());\n \n for (int row = 0; row < first.getRows(); row++) {\n for (int col = 0; col < first.getClumns(); col++) {\n result.matrix[row][col] = first.matrix[row][col] - second.matrix[row][col];\n }\n }\n \n return result;\n }", "public void substract1() {\r\n value--;\r\n }", "public ZYSet<ElementType> difference(ZYSet<ElementType> otherSet){\n ZYSet<ElementType> result = new ZYArraySet<ElementType>();\n for(ElementType e :this){\n if(!otherSet.contains(e)){\n result.add(e);\n }\n }\n return result;\n }", "@Override\n\tpublic double substract(double a, double b) {\n\t\treturn (a-b);\n\t}", "public static Digit minus(Digit first, Digit second){\n return Operations.minus(first.copy(), second.copy());\n }", "public static double subtract(int left, int right){\n return left - right;\n }", "public CLImage2D subtract(CLImage2D in1, CLImage2D in2) {\n\t\treturn process(subtractImage, in1, in2);\n\t}", "public static Object subtract(Object val1, Object val2) {\n\t\tif (isFloat(val1) && isFloat(val2)) {\n\t\t\treturn ((BigDecimal) val1).subtract((BigDecimal) val2);\n\t\t} else if (isFloat(val1) && isInt(val2)) {\n\t\t\treturn ((BigDecimal) val1).subtract(new BigDecimal(\n\t\t\t\t\t(BigInteger) val2));\n\t\t} else if (isInt(val1) && isFloat(val2)) {\n\t\t\treturn new BigDecimal((BigInteger) val1)\n\t\t\t\t\t.subtract((BigDecimal) val2);\n\t\t} else if (isInt(val1) && isInt(val2)) {\n\t\t\treturn ((BigInteger) val1).subtract((BigInteger) val2);\n\t\t}\n\t\tthrow new OrccRuntimeException(\"type mismatch in subtract\");\n\t}", "public T minus( T B ) {\n convertType.specify(this, B);\n T A = convertType.convert(this);\n B = convertType.convert(B);\n T ret = A.createLike();\n\n A.ops.minus(A.mat, B.mat, ret.mat);\n return ret;\n }", "public final GFElement subtract(GFElement minuend)\n {\n return add(minuend);\n }", "public static int subtractTwoNumbers(int num1, int num2){\n int subtraction = num1 - num2;\n return subtraction;\n }", "public static Interval subtraction(Interval in1, Interval in2){\r\n //in1.print();\r\n //in2.print();\r\n return new Interval(in1.getFirstExtreme()-in2.getSecondExtreme(),in1.getSecondExtreme()-in2.getFirstExtreme(),in1.getFEincluded()=='['&&in2.getSEincluded()==']'?in1.getFEincluded():'(',in1.getSEincluded()==']'&&in2.getFEincluded()=='['?in1.getSEincluded():')');\r\n }", "public static String subtract(String num1, String num2) {\n\t\t// *** WRITE YOUR CODE HERE ***\n\t}", "static int[] Differenz(int[] a, int[] b){\n int i = a.length - 1;\n int[] c = new int [a.length];\n Arrays.fill(c, 0);\n while (i >= 0){\n if ((a[i] - b[i]) < 0){\n c[i] = (a[i] + 10) - b[i];\n c[i-1]--;\n }\n else c[i] = a[i] - b[i];\n i--;\n }\n return c;\n }", "public ArrBag<T> difference( ArrBag<T> other )\n {\n // THIS ARRBAG WILL NEVER TRIGGER AN UPSIZE BECUASE YOU MADE IT JUST BIG ENOUGH FOR THE LARGEST POSSIBLE DIFF\n ArrBag<T> diffResult = new ArrBag<T>(this.size() + other.size());\n int differenceCount = 0;\n\n for(int i =0; i<this.size(); i++)\n {\n if(!other.contains(this.get(i)) && !diffResult.contains(this.get(i)))\n {\n diffResult.add(this.get(i));\n }\n // change the 0 to the right value for diff\n }\n return diffResult; \n }", "public Collection<Plan> getMinusPlan(CompilerContext context, Collection<Plan> p1, Collection<Plan> p2) {\n return p1.stream().flatMap( pp1 ->\n p2.stream().flatMap(pp2 ->\n Stream.of(context.asPlan(new Difference(pp1, pp2)))\n )\n ).collect(Collectors.toList());\n }", "@Override\n public SetInterface<T> difference(SetInterface<T> rhs) {\n //create return SetInterface\n SetInterface<T> result = new ArraySet();\n //Look through the calling set\n for(int i = 0; i < numItems; i++){\n //if the item is NOT also in the param set, add it to result\n if(!rhs.contains(arr[i]))\n result.addItem(arr[i]);\n }\n return result;\n }", "public static void subVectors( double[] v1, double[] v2, double[] result ) {\n result[0] = v1[0] - v2[0];\n result[1] = v1[1] - v2[1];\n result[2] = v1[2] - v2[2];\n }", "private int calculamenos(String a, String b) {\n int res=0;\n res= Integer.valueOf(a) - Integer.valueOf(b);\n return res;\n \n }", "public BigInt minus(BigInt rhs) throws BigIntException {\n if (null == rhs) {\n throw new BigIntException(\"null parameter\");\n }\n\n if (!isPositive && rhs.isPositive) {\n // -x-y=-(x+y)\n BigInt num1 = new BigInt(number, true);\n BigInt num2 = new BigInt(rhs.number, true);\n\n BigInt result = num1.plus(num2);\n result.swapSign();\n\n return result;\n } else if (!isPositive && !rhs.isPositive) {\n // -x-(-y)=y-x\n BigInt num1 = new BigInt(number, true);\n BigInt num2 = new BigInt(rhs.number, true);\n\n return num2.minus(num1);\n } else if (isPositive && !rhs.isPositive) {\n // x-(-y)=x+y\n return plus(new BigInt(rhs.number, true));\n }\n\n // x-y\n int length = Math.max(number.size(), rhs.number.size());\n\n // Set the bigger and the smaller number\n ArrayList<Integer> bigger, smaller;\n boolean isDiffPositive = isGreater(rhs);\n if (isDiffPositive) {\n // this is greater\n bigger = new ArrayList<Integer>(number);\n smaller = new ArrayList<Integer>(rhs.number);\n } else {\n // rhs is greater\n bigger = new ArrayList<Integer>(rhs.number);\n smaller = new ArrayList<Integer>(number);\n }\n\n ArrayList<Integer> diff = new ArrayList<Integer>();\n int digit_diff = 0;\n for (int i = 0; i < length; ++i) {\n int subtracting_current_digit = getDigit(bigger, i);\n int subtracted_current_digit = getDigit(smaller, i);\n\n digit_diff = subtracting_current_digit - subtracted_current_digit;\n if (0 > digit_diff) {\n // The subtracted is bigger so we need to borrow\n borrow(bigger, i);\n digit_diff += 10;\n }\n\n diff.add(digit_diff);\n }\n\n return new BigInt(diff, isDiffPositive);\n }", "public void sub(vec3 a, vec3 b) {\r\n\t\tx = a.x - b.x;\r\n\t\ty = a.y - b.y;\r\n\t\tz = a.z - b.z;\r\n\t}", "public Percentage minus(Percentage other) {\n return new Percentage(amount.minus(other.amount));\n }", "public Integer substractNumbers(List<Integer> numbers) throws Exception;", "public ResourceSpec subtract(final ResourceSpec other) {\n\t\tcheckNotNull(other, \"Cannot subtract null resources\");\n\n\t\tif (this.equals(UNKNOWN) || other.equals(UNKNOWN)) {\n\t\t\treturn UNKNOWN;\n\t\t}\n\n\t\tcheckArgument(other.lessThanOrEqual(this), \"Cannot subtract a larger ResourceSpec from this one.\");\n\n\t\tfinal ResourceSpec target = new ResourceSpec(\n\t\t\tthis.cpuCores.subtract(other.cpuCores),\n\t\t\tthis.taskHeapMemory.subtract(other.taskHeapMemory),\n\t\t\tthis.taskOffHeapMemory.subtract(other.taskOffHeapMemory),\n\t\t\tthis.managedMemory.subtract(other.managedMemory));\n\n\t\ttarget.extendedResources.putAll(extendedResources);\n\n\t\tfor (Resource resource : other.extendedResources.values()) {\n\t\t\ttarget.extendedResources.merge(resource.getName(), resource, (v1, v2) -> {\n\t\t\t\tfinal Resource subtracted = v1.subtract(v2);\n\t\t\t\treturn subtracted.getValue().compareTo(BigDecimal.ZERO) == 0 ? null : subtracted;\n\t\t\t});\n\t\t}\n\t\treturn target;\n\t}", "public Units minus(Units units)\n\t{\n\t\tUnits result = new Units();\n\t\tfor (Unit unit : this)\n\t\t{\n\t\t\tif (!units.contains(unit))\n\t\t\t{\n\t\t\t\tresult.add(unit);\n\t\t\t}\n\t\t}\n\t\treturn result;\n\t}", "private void minus() throws Exception{\n\t\tif(!(stackBiggerThanTwo())) throw new Exception(\"Stack hat zu wenig einträge mindestens 2 werden gebraucht!!\");\n\t\telse{\n\t\t\tvalue1=stack.pop();\n\t\t\tvalue2=stack.pop();\n\t\t\tstack.push(value2-value1);\n\t\t}\n\t}", "public void sub(int x, int y) {\r\n\t\tint diff = x - y;\r\n\t\tSystem.out.println(\"Subtracting\tIntegers: \" + diff);\r\n\t}", "@Override\n\tpublic IMatrix sub(IMatrix other) {\n\t\tif (this.getColsCount() != other.getColsCount()\n\t\t\t\t|| this.getRowsCount() != other.getRowsCount()) {\n\t\t\tthrow new IncompatibleOperandException(\n\t\t\t\t\t\"For operation 'sub' matrixes should be compatible!\");\n\t\t}\n\t\tint m = this.getRowsCount();\n\t\tint n = this.getColsCount();\n\t\tfor (int i = 0; i < m; i++) {\n\t\t\tfor (int j = 0; j < n; j++) {\n\t\t\t\tthis.set(i, j, this.get(i, j) - other.get(i, j));\n\t\t\t}\n\t\t}\n\t\treturn this;\n\t}", "public void testMinus() {\r\n System.out.println(\"Minus\");\r\n Double [][] n = new Double[][]{{-3., -2.5, -1., 0., 1., 2., 3.4, 3.5, 1.1E300, -1.1E300}, \r\n {-3., 2.5, 0., 0., 1., -2., 3., 3.7, 1.1E300, 1.1E300}, \r\n {0., -5., -1., 0., 0., 4., 0.4, -0.2, 0., -2.2E300}};\r\n for(int i = 0; i < 10; i++){\r\n Double x = n[0][i];\r\n Double y = n[1][i];\r\n double expResult = n[2][i];\r\n double result = MathOp.Minus(x, y);\r\n assertEquals(expResult, result, 0.001);\r\n }\r\n }", "public void subtract(int value) {\n m_value -= value;\n }", "@Override\n\tpublic int arithmetical(int first, int second) {\n\t\treturn first - second;\n\t}", "public static Vector subtract(Vector v1, Vector v2) {\r\n Vector w = new Vector(v1);\r\n w.subtract(v2);\r\n return w;\r\n }", "@Override\n public BinaryType subtractToBinary(BinaryType minuend) {\n int intMinuend = minuend.asInt().getValue();\n int intSubtrahend = this.asInt().getValue();\n return TypeFactory.getIntType(intMinuend - intSubtrahend).asBinary();\n }", "public Coordinate subtract(Coordinate other) {\n return new Coordinate(usubtract(_coord, other._coord));\n }", "public final void minus (Unit unit) throws ArithmeticException {\n\t\tboolean error = false;\n\t\tif (((mksa|unit.mksa)&_abs)!=0) {\t// Special dates\n\t\t\tif (mksa == unit.mksa)\t\t// date1 - date2\n\t\t\t\tmksa ^= _abs;\t\t\t// ... not a date any more\n\t\t\telse if ((unit.mksa&_abs)!=0) error = true;\n\t\t}\n\t\telse error = (mksa&(~_pic)) != (unit.mksa&(~_pic));\n\t\tif (error) throw new ArithmeticException\n\t\t(\"****Unit: can't combine: \" + symbol + \" - \" + unit.symbol);\n\t\tvalue -= (unit.value*unit.factor)/factor;\n\t}", "public org.apache.spark.mllib.linalg.distributed.BlockMatrix subtract (org.apache.spark.mllib.linalg.distributed.BlockMatrix other) { throw new RuntimeException(); }", "public int soustraire(int a, int b){\r\n\t\treturn a-b;\r\n\t}", "void minus(int a, int b){\n\t\tSystem.out.println(\"Method-3 (2 different Data Types) Minus is: \" + (a-b));\n\t}", "BaseNumber subtract(BaseNumber operand);", "public static <T> List<T> difference(List<T> a, List<T> b) {\n\t\tList<T> acc = new ArrayList<T>();\n\t\tfor (T t : a)\n\t\t\tif (!b.contains(t))\n\t\t\t\tacc.add(t);\n\t\treturn acc;\n\t}", "public Interval diff(Interval other) {\n\t\treturn this.plus(other.mul(new Interval(\"-1\", \"-1\")));\n\t}", "public static void subtractValue(List<Integer> locations, int delta) {\n if (locations == null) return;\n for (int i = 0; i < locations.size(); i++) {\n locations.set(i, locations.get(i) - delta);\n }\n }", "public SetSet setDifference(SetSet second){\n\t\tSetSet result = new SetSet();\n\t\tfor(int i=0;i<size();i++){\n\t\t\tif(second.contains(get(i))==-1){\n\t\t\t\tresult.add(get(i));\n\t\t\t}\n\t\t}\n\t\treturn result;\n\t}", "public final void subtractFromThis(GFElement minuend)\n {\n addToThis(minuend);\n }", "public static Matrix minus(Matrix amat, Matrix bmat){\r\n \tif((amat.nrow!=bmat.nrow)||(amat.ncol!=bmat.ncol)){\r\n \t\tthrow new IllegalArgumentException(\"Array dimensions do not agree\");\r\n \t}\r\n \tint nr=amat.nrow;\r\n \tint nc=amat.ncol;\r\n \tMatrix cmat = new Matrix(nr,nc);\r\n \tdouble[][] carray = cmat.getArrayReference();\r\n \tfor(int i=0; i<nr; i++){\r\n \t\tfor(int j=0; j<nc; j++){\r\n \t\tcarray[i][j]=amat.matrix[i][j] - bmat.matrix[i][j];\r\n \t\t}\r\n \t}\r\n \treturn cmat;\r\n \t}", "public double subtract(double firstNumber, double secondNUmber){\n\t\treturn firstNumber - secondNUmber;\n\t}", "public static void sub(Vec2 a, Vec2 b, Vec2 dest) {\r\n\t\tdest.x = a.x - b.x;\r\n\t\tdest.y = a.y - b.y;\r\n\t}", "public static BinaryExpression subtract(Expression expression0, Expression expression1) {\n return makeBinary(ExpressionType.Subtract, expression0, expression1);\n }", "public void subtract (int value) {\r\n\t\ttotal = total - value;\r\n\t\thistory = history + \" - \" + value;\r\n\t}", "public Vector2D minus(Vector2D rhs)\n {\n return new Vector2D(this.x - rhs.x, this.y - rhs.y);\n }", "void minus(int a) {\n this.result -= a; // 이렇게 result 변수가 있는 인스턴스의 주소를 사용하여 계산을 수행한다.\n }", "static int subs(int firstnumber, int secondnumber) {\n return (firstnumber - secondnumber);\n\n }", "public double getDifference()\n {\n return first - second;\n }", "public T subtract(T measure);", "public final void sub(Matrix3f m1, Matrix3f m2) {\n\tset(\n\t m1.m00 - m2.m00,\n\t m1.m01 - m2.m01,\n\t m1.m02 - m2.m02,\n\t m1.m10 - m2.m10,\n\t m1.m11 - m2.m11,\n\t m1.m12 - m2.m12,\n\t m1.m20 - m2.m20,\n\t m1.m21 - m2.m21,\n\t m1.m22 - m2.m22\n\t );\n }", "public void substract(double skalar) {\r\n for (int i = 0; i < matrix.length; i++) {\r\n for (int j = 0; j < matrix[0].length; j++) {\r\n matrix[i][j] -= skalar;\r\n }\r\n }\r\n }", "private final static void ddsub(final double[] a, final double[] b, double[] c) {\n\tdouble t1 = a[0] - b[0];\n\tdouble e = t1 - a[0];\n\tdouble t2 = ((-b[0] - e) + (a[0] - (t1 - e))) + a[1] - b[1];\n\tdouble s1 = t1 + t2;\n\tc[0] = s1;\n\tc[1] = t2 - (s1 - t1);\n\treturn;\n }", "public Matrix subtract(Matrix m2)\n\t{\n\t\tMatrix result = new Matrix(new double[m2.matrix.length][m2.matrix.length]); \n\t\tfor (int i = 0; i < m2.matrix.length; i++)\n\t\t{\n\t\t\tfor (int j = 0; j < m2.matrix.length; j++)\n\t\t\t{\n\t\t\t\tresult.matrix[i][j] = matrix[i][j] - m2.matrix[i][j];\n\t\t\t}\n\t\t}\n\t\treturn result;\n\t}" ]
[ "0.7244955", "0.70289195", "0.6958457", "0.69547707", "0.6930407", "0.6921116", "0.691635", "0.687725", "0.683311", "0.68212783", "0.6808177", "0.67813563", "0.67694604", "0.6708684", "0.6696801", "0.6680779", "0.66690326", "0.6639085", "0.66024345", "0.65789413", "0.6516843", "0.65130603", "0.6441967", "0.64415056", "0.64309883", "0.64232284", "0.6404044", "0.63988423", "0.6391365", "0.638048", "0.6364473", "0.63604707", "0.6358195", "0.63450426", "0.63405365", "0.6338095", "0.6336603", "0.63251644", "0.631173", "0.63036096", "0.63024116", "0.63009584", "0.629475", "0.62929785", "0.62905866", "0.62796444", "0.62757576", "0.627003", "0.6208811", "0.6202121", "0.62013596", "0.6200908", "0.6194502", "0.61797506", "0.6174411", "0.6172165", "0.61612844", "0.6157495", "0.6145473", "0.6143024", "0.61187804", "0.6096943", "0.60938835", "0.6086735", "0.60846406", "0.60808796", "0.60657674", "0.6056", "0.60535294", "0.6046828", "0.60355574", "0.6022586", "0.60206336", "0.6012963", "0.6011411", "0.6005971", "0.600044", "0.5989022", "0.59811383", "0.59802467", "0.5975718", "0.5971248", "0.5939394", "0.5927953", "0.5920043", "0.59188306", "0.59185594", "0.590735", "0.59069043", "0.5903362", "0.5888117", "0.5876409", "0.5869002", "0.5861689", "0.58579266", "0.58450186", "0.5841712", "0.5834965", "0.58328605", "0.5825833" ]
0.6670566
16
Sets both damage and ranged damage to value
public void setGeneralDamage(float value) { damage = value; rangedDamage = value; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void setDamage(double d) {\n damage = d;\n }", "public Builder setDamage(int value) {\n bitField0_ |= 0x00000080;\n damage_ = value;\n onChanged();\n return this;\n }", "public void setDamage(double damage) {\r\n\t\tthis.damage = damage;\r\n\t}", "public Builder setDamage(int value) {\n bitField0_ |= 0x00000200;\n damage_ = value;\n onChanged();\n return this;\n }", "public void setDamage(int d) {\r\n this.damage = d;\r\n }", "public Builder setDamage(int value) {\n bitField0_ |= 0x00000400;\n damage_ = value;\n onChanged();\n return this;\n }", "public Builder setDamage(int value) {\n bitField0_ |= 0x00000400;\n damage_ = value;\n onChanged();\n return this;\n }", "public Builder setDamage(int value) {\n bitField0_ |= 0x00000400;\n damage_ = value;\n onChanged();\n return this;\n }", "public void setDamage(int damage) {\r\n\t\tthis.damage = damage;\r\n\t}", "public void setHungerDamage(float hunger);", "public void applyDamage(int damage)\r\n\t{\r\n\r\n\t}", "public void setDamage() {\n\t\tRandom rand = new Random();\n\t\tint damage = rand.nextInt(getMaxDamage()) + 1;\n\t\tthis.damage = damage;\n\t}", "public void damage(int amount) {\n \tshield = shield - amount;\n }", "public void setDamage(float damage) {\n if (grid != null) {\n grid.assertUnlocked();\n }\n\n if (damage < 0) {\n throw new IllegalArgumentException(\"Invalid damage value: \" + damage);\n }\n\n this.damage = damage;\n }", "public void setDamage(int damage) {\n\t\tWeapon.itemDamage = damage;\n\t}", "public void hit(int melee_dmg,int range_dmg) {\n melee_dmg=this.current_atk-30;\n range_dmg=this.current_atk-60;\n }", "protected void takeDamage(int damage)\n {\n health = health - damage;\n \n }", "@Override\r\n\tpublic void damage(float amount) {\n\t\t\r\n\t}", "@Override\n\tpublic void damage(float f) {\n\t\t\n\t}", "public int setDamage(int damage) {\n\t\tthis.damage = damage;\n\t\treturn 0;\n\t}", "public void takeDamage(double damage){\n damage -= this.armor;\n this.health -= damage;\n }", "public void setDmg(int enemyDmg){\r\n this.enemyDmg = enemyDmg;\r\n }", "public void setDamageTaken(double damage){\n\t\tlifeForce -= damage;\n\t\tif (! (lifeForce > 0) ) {\n\t\t\tJOptionPane.showMessageDialog(null, \"You Died - GAME OVER\");\n\t\t\tSystem.exit(0);\n\t\t}\n\t}", "public void takeDamage(int damage);", "private void takeDamage(int damage){ health -= damage;}", "public void setSiegeWeaponDamage(short siegeWeaponDamage);", "private void damage(){\n\n LevelMap.getLevel().damage(dmg);\n //System.out.println(\"died\");\n setDie();\n }", "public void setWeaponDamage (int weaponDamage)\r\n\t{\r\n\t\tthis.weaponDamage = weaponDamage;\r\n\t}", "protected void setItemDamage(Material material, int damage) \r\n\t{\tthis.itemDamage.put(material, damage);\t}", "public void setHandThrowDamage(short handThrowDamage);", "public void takeDamage(int damage) {\n\t\tlife = (life-damage<0)?0:life-damage;\n\t}", "public void setBowDamage(short bowDamage);", "@Override\n\tpublic void takeDamage(double damage) {\n\n\t}", "public void setOverhitValues(final L2Character attacker, final double damage)\n\t{\n\t\t// Calculate the over-hit damage\n\t\t// Ex: mob had 10 HP left, over-hit skill did 50 damage total, over-hit damage is 40\n\t\tfinal double overhitDmg = (getCurrentHp() - damage) * -1;\n\t\t\n\t\tif (overhitDmg < 0)\n\t\t{\n\t\t\t// we didn't killed the mob with the over-hit strike. (it wasn't really an over-hit strike)\n\t\t\t// let's just clear all the over-hit related values\n\t\t\toverhitEnabled(false);\n\t\t\toverhitDamage = 0;\n\t\t\toverhitAttacker = null;\n\t\t\t\n\t\t\treturn;\n\t\t}\n\t\t\n\t\toverhitEnabled(true);\n\t\toverhitDamage = overhitDmg;\n\t\toverhitAttacker = attacker;\n\t}", "void decreaseHealth(Float damage);", "public void takeDamage(int damage) {\r\n this.health -= damage;\r\n if(this.health < 0)\r\n this.health = 0;\r\n }", "public void takeDamage(int dmg){\r\n this.currHP -= dmg;\r\n }", "public void setDamage(double newDamage) {\n Validations.nonNegative(newDamage, \"newDamage\");\n damage = newDamage;\n }", "public int giveDamage();", "public void damagePlayer(int damage){\n hero.decreaseHp(damage);\n }", "public void receiveDamage(double damage) {\r\n health = health - damage;\r\n }", "public void damaged() {\n this.damageState = DamageState.DAMAGED;\n }", "public void takeDamage(int damage) {\n this.damageTaken += damage;\n }", "public void setLastDamage ( double damage ) {\n\t\texecute ( handle -> handle.setLastDamage ( damage ) );\n\t}", "public int takeDamage(int damage) {\n damage -= ARMOR;\r\n // set new hp\r\n return super.takeDamage(damage);\r\n }", "public void hurt(int damage)\n {\n \t hp -= (damage - ( damage * armor / 100 ));\n \t //System.out.println(\"hp: \" + hp);\n }", "public void applyDamage(int damage)\n\t{\n\t\tthis.currHP -= damage;\n\t\tif(currHP <= 0)\n\n\t\t{\n\t\t\tthis.currHP = 0;\n\t\t\tthis.kill();\n\t\t}\n\t\t\t\n\t}", "public void suffer(int damage){\r\n\t\thp -= damage;\r\n\t\tinvulnerable = true;\r\n\t}", "public void reduceHealth(int damage){\n health -= damage;\n }", "protected void setItemDamageLevel(Material material, double damage) \r\n\t{\tthis.itemDamageLevel.put(material, damage);\t}", "public void takeDamage (double damage)\n {\n getComponent(HealthC.class).decrease(damage);\n if (getComponent(HealthC.class).isDead())\n {\n setActive(false);\n }\n }", "@Override\n\tpublic void setAttack(double attack) {\n\n\t}", "public void damage(int damageTaken) {\n //TODO: Create specific damage methods instead of damage calls everywhere(see damagedByBullet())\n if (!invincible) {\n this.hp -= damageTaken;\n }\n }", "public void takedmg(int dmg){\n curHp -= dmg;\n }", "private void subtractEnemySheild(int damage) {\n this.enemyShield -= damage;\n }", "public void SetHealth(int h)\n{\n\thealth=h;\n}", "public Shot(int damage) {\n\t\tthis.damage = damage;\n\t}", "private float setAttackAbsorption(HashMap content) {\n\t\tfloat change = calculateAbsorption();\n this.attackDamageModifier = baseDamageModifier + change;\n//System.out.println(\"attack: \" + this.attackDamageModifier);\n content.put(\"attack_damage_modifier\", \"\" + this.attackDamageModifier);\n\t\treturn change*ABSORPTION_PRICE_MULTIPLIER;\n }", "protected void setProjectileDamage(CharacterDamageManager.ProjectileType type, int damage) \r\n\t{\tthis.projectileDamage.put(type, damage);\t}", "private void subtractPlayerSheild(int damage) {\n this.playerShield -= damage;\n }", "public void takeDamage(int damage) {\r\n health -= damage;\r\n if(health<=0)setAlive(false);\r\n }", "public void damage ( double amount ) {\n\t\texecute ( handle -> handle.damage ( amount ) );\n\t}", "public void takeDamage(int dmg) {\n\t\thealth -= dmg;\n\t}", "public void damageDevice() {\n\t\t\r\n\t}", "public void addDamage(int amount) {\n\t\tdamage = amount;\n\t}", "public abstract void setHealth(int health);", "boolean takeDamage(int dmg);", "public void damage(double amount, Unit source, int type) {\n damage(amount, source);\r\n }", "public void setHealth(double Health){\r\n health = Health;\r\n }", "public void getDamaged(float dmg) {\n\t\tStagePanel.addValueLabel(parentGP,dmg,Commons.cAttack);\n\t\tif(shield - dmg >= 0) {\n\t\t\tshield-=dmg;\n\t\t\tdmg = 0;\n\t\t}else {\n\t\t\tdmg-=shield;\n\t\t\tshield = 0;\n\t\t}\n\t\tif(health-dmg > 0) {\n\t\t\thealth-=dmg;\n\t\t}else {\n\t\t\thealth = 0;\n\t\t}\n\t\tSoundEffect.play(\"Hurt.wav\");\n\t}", "public void takeDamage(int damage) {\n Random rand = new Random();\n int game = rand.nextInt(51) + 75;\n double game2 = (double) game;\n double percDamage = game2/100.0;\n double realSomething = (double) damage;\n double actualDamageNotReal = realSomething * percDamage;\n int actualDamage = (int) actualDamageNotReal;\n int actualDmg = actualDamage - this.armour;\n if (actualDmg <= 0){\n actualDmg = 0;\n }\n this.health -= actualDmg;\n slowDisplay(String.format(\"%s takes %s damage, now at %s\\n\",this.name,actualDmg,this.health));\n\n }", "public final void applyDamage(DamageDTO damage) {\n int rolledDamage = damage.getMaxDamage();\n if (rolledDamage > 0) {\n this.currentHitPoints -= rolledDamage;\n }\n if (this.currentHitPoints <= 0) {\n this.die();\n }\n }", "public void setAttack(double attack) {\n this.attack = attack;\n }", "public void setTempDmg(int tDmg){\r\n this.tDmg = dmg;\r\n }", "public void takeDamage(int amount){\r\n\t\tthis.life = this.life - amount;\r\n\t}", "public void resetDamagedRange() {\r\n fDamagedRange[0] = Integer.MAX_VALUE;\r\n fDamagedRange[1] = Integer.MIN_VALUE;\r\n }", "int getDamage();", "int getDamage();", "int getDamage();", "int getDamage();", "int getDamage();", "public void setHealth(double h){\n health = h;\n }", "public void setDefense(float defense)\n {\n this.defense = defense;\n }", "public void damage(Hero other) {\n this.weapon.knockBack(other, this.state, this.dir);\n }", "public void beAttacked(int damage) {\r\n\t\tif (health > damage) {\r\n\t\t\thealth -= damage;\r\n\t\t}else {\r\n\t\t\thealth = 0;\r\n\t\t}\r\n\t}", "public void calibrated() {\n weaponDamage = weaponDamage + 10;\r\n }", "public void setBdamage(int bdamage) {\r\n\t\tthis.bdamage = bdamage;\r\n\t}", "public void reduceHealth(int ammo_damage){\n this.health -= ammo_damage;\n }", "@ZenCodeType.Method\n @ZenCodeType.Setter(\"damageRodBy\")\n public static void damageRodBy(ItemFishedEvent internal, int damage) {\n \n internal.damageRodBy(damage);\n }", "public void damage ( double amount , Entity source ) {\n\t\texecute ( handle -> handle.damage ( amount , source ) );\n\t}", "public void damageRange(JTextComponent tc, int p0, int p1) {\n damageRange(tc, p0, p1, Position.Bias.Forward, Position.Bias.Backward);\n }", "@Override\n public int doDamage() {\n if (difficulty <5)\n return damage;\n else \n return damage*2;\n }", "@Override\r\n\tpublic void setHealth(int strike) {\n\t\t\r\n\t}", "public void setAttack(int attack) {\n base.setAttack(attack);\n }", "@Override\n\tpublic void setDefense(double defense) {\n\n\t}", "public void takeDamage(double num) {\r\n \r\n int damage = (int)Math.round(num);\r\n this.health -= damage;\r\n this.state=this.color+16;\r\n if (damage <= 5) {\r\n if (this.playerNum == 1)\r\n this.positionX -= 40;\r\n else \r\n this.positionX += 40;\r\n }\r\n else if (this.playerNum == 1)\r\n this.positionX -= damage * 6;\r\n else\r\n this.positionX += damage * 6;\r\n \r\n }", "@Override\n public void hardMode() {\n super.setHP(1800);\n super.getFrontAttack().setBaseDamage(37.5);\n super.getRightAttack().setBaseDamage(37.5);\n super.getBackAttack().setBaseDamage(37.5);\n super.getLeftAttack().setBaseDamage(37.5);\n }", "@Test\n\tpublic void testSetHealth() {\n\t\tnpc.setLevel(1);\n\t\tnpc.setHealth(10);\n\t\tassertTrue(npc.getBaseHealth() == 10);\n\t\tnpc.setHealth(35);\n\t\tassertFalse(npc.getBaseHealth() == 10);\n\t\tassertTrue(npc.getBaseHealth() == 35);\n\t}", "public int takeDamage(int damage) \r\n\t{\r\n\t\t//Pre: an int damage\r\n\t\t//Post: reduces health variable by damage\r\n\t\tif(health - damage > 0) \r\n\t\t{\r\n\t\t\thealth -= damage;\r\n\t\t}\r\n\t\telse \r\n\t\t{\r\n\t\t\thealth = 0;\r\n\t\t}\r\n\t\treturn health;\r\n\t}", "public void damage(int damage, int penetration) {\n int def = defense;\n if (shield != null ) def += shield.getDefense();\n def = defense - penetration;\n if (def < 0) def = 0;\n if (def >= damage) return;\n health -= (damage - def);\n if (health < 0) health = 0;\n decreaseMoral((damage-def)/30);\n if (leader)\n color = new Color(color.getRed(), color.getGreen() + (damage-def)/2, color.getBlue() + (damage-def)/2);\n else\n color = new Color(color.getRed(), color.getGreen() + (damage-def)*2 , color.getBlue() + (damage-def)*2);\n }" ]
[ "0.7543186", "0.75391537", "0.75263995", "0.7526201", "0.7492949", "0.74847907", "0.74847907", "0.7483473", "0.7373431", "0.7302155", "0.72603625", "0.7161977", "0.71310025", "0.71038777", "0.70371157", "0.6970876", "0.6955048", "0.6912381", "0.6858503", "0.6838986", "0.6829355", "0.6827098", "0.6778108", "0.6768131", "0.6766191", "0.6749688", "0.67198884", "0.6702803", "0.6633468", "0.6633158", "0.6630089", "0.6594087", "0.65589917", "0.655084", "0.6513373", "0.6500719", "0.64944255", "0.64827543", "0.64723825", "0.64384824", "0.64340186", "0.6429542", "0.64148825", "0.6413477", "0.6408799", "0.63686794", "0.63574505", "0.63503486", "0.63453764", "0.633856", "0.6305928", "0.6302392", "0.62866104", "0.62799454", "0.6278491", "0.6276014", "0.62630284", "0.6251781", "0.62390167", "0.62292", "0.62290287", "0.62233573", "0.62062806", "0.6187637", "0.6175621", "0.6170482", "0.6158818", "0.61509013", "0.6148442", "0.614648", "0.6144857", "0.6139827", "0.613541", "0.6127404", "0.61263514", "0.61008775", "0.6098445", "0.6098445", "0.6098445", "0.6098445", "0.6098445", "0.60980463", "0.6059667", "0.6032678", "0.60302675", "0.60216874", "0.6020903", "0.60178524", "0.6010417", "0.5998018", "0.5997951", "0.5990952", "0.59888077", "0.598668", "0.5978405", "0.59743", "0.5960279", "0.5958077", "0.5947392", "0.5944661" ]
0.7502481
4
when music is playing in some media player
public static void main(String[] args) { MS_WindowsAPIManager.fireMediaEvent(MediaEventTypeEnum.PREV_TRACK); MS_CodingUtils.sleep(4000); MS_WindowsAPIManager.fireMediaEvent(MediaEventTypeEnum.STOP_MUSIC); MS_CodingUtils.sleep(3000); MS_WindowsAPIManager.fireMediaEvent(MediaEventTypeEnum.PLAY_PAUSE_MUSIC); MS_CodingUtils.sleep(3000); MS_WindowsAPIManager.fireMediaEvent(MediaEventTypeEnum.NEXT_TRACK); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void initialMusic(){\n\n }", "public void playMusic() {\n\t\tthis.music.start();\n\t}", "private void play()\n {\n if(AudioDetector.getInstance().isNoAudio())\n {\n return;\n }\n\n stop();\n musicPlayer.play();\n }", "@Override\r\n public void handleMediaEvent(MediaEvent event) {\r\n if(running){\r\n try {\r\n Media media = event.getSource();\r\n String pluginName = media.getPluginName();\r\n Map<String,Object> location = SharedLocationService.getLocation(media.getPluginLocationId());\r\n switch(event.getEventType()){\r\n case PLAYER_PLAY:\r\n Map<String,Object> playerData = media.getNowPlayingData();\r\n publishMediaItem((String)location.get(\"floorname\"),(String)location.get(\"name\"),pluginName,\"action\",event.getEventType().toString().toLowerCase());\r\n publishMediaItem((String)location.get(\"floorname\"),(String)location.get(\"name\"),pluginName,\"type\",((MediaPlugin.ItemType)playerData.get(\"ItemType\")).toString().toLowerCase());\r\n if ((MediaPlugin.ItemType)playerData.get(\"ItemType\") == MediaPlugin.ItemType.AUDIO) {\r\n publishMediaItem((String)location.get(\"floorname\"),(String)location.get(\"name\"),pluginName,\"title\",(String)playerData.get(MediaPlugin.ItemDetails.TITLE.toString()));\r\n publishMediaItem((String)location.get(\"floorname\"),(String)location.get(\"name\"),pluginName,\"title artist\",(String)playerData.get(MediaPlugin.ItemDetails.TITLE_ARTIST.toString()));\r\n publishMediaItem((String)location.get(\"floorname\"),(String)location.get(\"name\"),pluginName,\"album\",(String)playerData.get(MediaPlugin.ItemDetails.ALBUM.toString()));\r\n publishMediaItem((String)location.get(\"floorname\"),(String)location.get(\"name\"),pluginName,\"album artist\",(String)playerData.get(MediaPlugin.ItemDetails.ALBUM_ARTIST.toString()));\r\n publishMediaItem((String)location.get(\"floorname\"),(String)location.get(\"name\"),pluginName,\"duration\",playerData.get(MediaPlugin.ItemDetails.DURATION.toString()).toString());\r\n } else {\r\n publishMediaItem((String)location.get(\"floorname\"),(String)location.get(\"name\"),pluginName,\"title\",(String)playerData.get(MediaPlugin.ItemDetails.TITLE.toString()));\r\n publishMediaItem((String)location.get(\"floorname\"),(String)location.get(\"name\"),pluginName,\"duration\",playerData.get(MediaPlugin.ItemDetails.DURATION.toString()).toString());\r\n }\r\n break;\r\n case PLAYER_PAUSE:\r\n publishMediaItem((String)location.get(\"floorname\"),(String)location.get(\"name\"),pluginName,\"action\",event.getEventType().toString().toLowerCase());\r\n break;\r\n case PLAYER_STOP:\r\n publishMediaItem((String)location.get(\"floorname\"),(String)location.get(\"name\"),pluginName,\"action\",event.getEventType().toString().toLowerCase());\r\n break;\r\n }\r\n } catch (Exception ex) {\r\n LOG.error(\"Could not publish to broker: {}\", ex.getMessage(), ex);\r\n }\r\n }\r\n }", "public void StartMusic(int music_id);", "public static void updateMusic()\r\n\t{\r\n\t\tif ( Settings.isMusicOn() && !musicPlaying() )\r\n\t\t\tstartMusic();\r\n\t\telse if ( !Settings.isMusicOn() && musicPlaying() )\r\n\t\t\tstopMusic();\r\n\t}", "public void playMedia() {\n\t\tif (MainActivity.mPlayer == null) {\n\t\t\tMainActivity.mPlayer = new MediaPlayer();\n\t\t\tMainActivity.mPlayer.setAudioStreamType(AudioManager.STREAM_MUSIC);\n\t\t\tMainActivity.currentSong = song;\n\t\t\tMainActivity.currentAlbum = album;\n\t\t}\n\t\tif (!MainActivity.currentSong.getTitleKey().equals(song.getTitleKey())) {\n\t\t\tMainActivity.currentSong = song;\n\t\t\tMainActivity.currentAlbum = album;\n\t\t\tMainActivity.mPlayer.reset();\n\t\t}\n\n\t\ttitle = song.getTitle();\n\t\talbumTitle = album.getAlbum();\n\t\talbumArt = album.getAlbumArt();\n\n\t\ttry {\n\t\t\tMainActivity.mPlayer.setDataSource(this, song.getUri());\n\t\t\tMainActivity.mPlayer.prepare();\n\t\t} catch (IllegalArgumentException e) {\n\t\t\tLog.i(TAG, e.getMessage(), e);\n\t\t\te.printStackTrace();\n\t\t} catch (SecurityException e) {\n\t\t\tLog.i(TAG, e.getMessage(), e);\n\t\t\te.printStackTrace();\n\t\t} catch (IllegalStateException e) {\n\t\t\tLog.i(TAG, e.getMessage(), e);\n\t\t\te.printStackTrace();\n\t\t} catch (IOException e) {\n\t\t\tLog.i(TAG, e.getMessage(), e);\n\t\t\te.printStackTrace();\n\t\t}\n\t\tMainActivity.mPlayer.setOnPreparedListener(new OnPreparedListener() {\n\t\t\t@Override\n\t\t\tpublic void onPrepared(MediaPlayer mp) {\n\t\t\t\tmp.start();\n\t\t\t}\n\t\t});\n\t\tMainActivity.mPlayer.setOnCompletionListener(new OnCompletionListener() {\n\n\t\t\t@Override\n\t\t\tpublic void onCompletion(MediaPlayer mp) {\n\t\t\t\tnext();\n\t\t\t}\n\n\t\t});\n\n\t\tnew Handler(getMainLooper()).post(new Runnable() {\n\t\t\t@Override\n\t\t\tpublic void run() {\n\t\t\t\tupdateMainActivity();\n\t\t\t\tupdateNowPlaying();\n\t\t\t}\n\t\t});\n\t}", "private void play() {\n /** Memanggil File MP3 \"indonesiaraya.mp3\" */\n try {\n mp.prepare();\n } catch (IllegalStateException e) {\n e.printStackTrace();\n } catch (IOException e) {\n e.printStackTrace();\n }\n\n /** Menjalankan Audio */\n mp.start();\n\n /** Penanganan Ketika Suara Berakhir */\n mp.setOnCompletionListener(new OnCompletionListener() {\n @Override\n public void onCompletion(MediaPlayer mp) {\n stateAwal();\n }\n });\n }", "public boolean musicOn ()\n\t{\n\t\tif (musicInt == 0)\n\t\t\treturn true;\n\t\telse\n\t\t\treturn false;\n\t}", "void startMusic(AudioTrack newSong);", "public void play() {\n\t\tif(currentPlayingItem==null) return;\n\t\tif(!mediaPlayer.isPlaying()) mediaPlayer.start();\n\t\tupdateNotification();\n\t\tsendBroadcast(new Intent(\"com.andreadec.musicplayer.playpausechanged\"));\n\t}", "@Override\r\n public void show()\r\n {\r\n // De inmediato, ponemos en marcha una melodia\r\n if (!juego.getAdminComponentes().get(\"Audios/bgmusic06.ogg\", Music.class).isPlaying())\r\n {\r\n juego.getAdminComponentes().get(\"Audios/bgmusic06.ogg\", Music.class).play();\r\n juego.getAdminComponentes().get(\"Audios/bgmusic06.ogg\", Music.class).setLooping(true);\r\n }\r\n }", "@Override\n public void onPrepared(MediaPlayer mp) {\n playMedia();\n }", "public void playSelectSong() {\n isStart = false;\n if (getCurrentSong() == 0) {\n audioList.get(getCurrentSong()).setSelect(true);\n playListAdapter.notifyItemChanged(getCurrentSong());\n }\n isPauseResume = false;\n if (player != null) {\n player.stopMedia();\n }\n if (!isDestroyed()) {\n playAudio(audioList.get(getCurrentSong()).getData());\n }\n /*new Handler().postDelayed(new Runnable() {\n @Override\n public void run() {\n if (!isDestroyed()) {\n playAudio(audioList.get(getCurrentSong()).getData());\n }\n }\n }, DELAY_TIME);*/\n }", "private void startPlay() {\n isPlaying = true;\n isPaused = false;\n playMusic();\n }", "public void onPlayStart(){\n\n\t}", "public void StartMusic(musicenum_t music_id);", "@Override\n public void onCompletion(MediaPlayer mediaPlayer) {\n stopMusic();\n }", "public abstract String playMedia ();", "void changeMusic(AudioTrack newSong);", "public void playMusic() {\n\t\ttry {\n\t\t\tsoundManager.playMusic(\"bgroundmusic\");\n\t\t} catch (Exception e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\n\t}", "private void playSound() {\n if (isFlashOn) {\n mp = MediaPlayer.create(this, R.raw.light_switch_off);\n } else {\n mp = MediaPlayer.create(this, R.raw.light_switch_on);\n }\n mp.setOnCompletionListener(new MediaPlayer.OnCompletionListener() {\n\n @Override\n public void onCompletion(MediaPlayer mp) {\n // TODO Auto-generated method stub\n mp.release();\n }\n });\n mp.start();\n }", "private void matikanAlarm() {\n\t\t\n\t\tif (mediaplayer.isPlaying() == true) {\n\t\t\t//matikan media player\n\t\t\tmediaplayer.pause();\n\t\t}\n\t\telse {\n\t\t\t//tidak melakukan apa apa\n\t\t}\t\t\t\t\n\t}", "@Override\n\tpublic void nowPlaying() {\n\t}", "public void playAudio() {\n\t\tmusic[currentSong].stop();\n\t\tcurrentSong++;\n\t\tcurrentSong %= music.length;\n\t\tmusic[currentSong].play();\n\t}", "@Override\n\t\t\tpublic boolean onError(MediaPlayer mp, int what, int extra) {\n\t\t\t\tif(null != player){\n\t\t\t\t\tplayer.release();\n\t\t\t\t\tplayer = null;\n\t\t\t\t}\n\t\t\t\tMusic m = listMusic.get(currentId);\n\t\t\t\tString url = m.getUrl();\n\t\t\t\tUri mUri = Uri.parse(url);\n\t\t\t\tplayer = new MediaPlayer();\n\t\t\t\tplayer.reset();\n\t\t\t\tplayer.setAudioStreamType(AudioManager.STREAM_MUSIC);\n\t\t\t\ttry {\n\t\t\t\t\tplayer.setDataSource(getApplicationContext(),mUri);\n\t\t\t\t\tplayer.prepare();\n\t\t\t\t} catch (IllegalArgumentException e) {\n\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t} catch (SecurityException e) {\n\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t} catch (IllegalStateException e) {\n\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t} catch (IOException e) {\n\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tplayer.start();\n\t\t\t\treturn false;\n\t\t\t}", "@Override\n\tpublic void OnGameStart() {\n\t\tsuper.OnGameStart();\n\t\tMusicManage.setLoopingMusic(tumMusic, true);\n\t\tMusicManage.playMusic(tumMusic);\n\t}", "@Override\n public void onPrepared(MediaPlayer mp) {\n Log.d(TAG, \"onPrepared() called\");\n mMediaPlayer.start();\n\n // Notify listeners that a new track has started.\n PreferenceManager.getDefaultSharedPreferences(getApplicationContext())\n .edit()\n .putString(MainActivity.PREF_CURRENT_ALBUM, playListItem.getAlbumName())\n .putString(MainActivity.PREF_CURRENT_ARTIST_NAME, playListItem.getArtistName())\n .putString(MainActivity.PREF_CURRENT_ARTIST_SPOTIFY_ID, playListItem.getArtistId())\n .putString(MainActivity.PREF_CURRENT_TRACK_NAME, playListItem.getTrackName())\n .putString(MainActivity.PREF_CURRENT_TRACK_SPOTIFY_ID, playListItem.getTrackId())\n .putString(MainActivity.PREF_CURRENT_TRACK_URL, playListItem.getTrackUri())\n .putBoolean(MainActivity.PREF_IS_PLAYING, true)\n .commit();\n\n Intent intent = new Intent(TRACK_START_BROADCAST_FILTER);\n intent.putExtra(SpotifyStreamerActivity.KEY_CURRENT_TRACK, playListItem);\n LocalBroadcastManager.getInstance(StreamerMediaService.this).sendBroadcast(intent);\n }", "public static boolean musicPlaying()\r\n\t{\r\n\t\tif ( musicPlayer == null )\r\n\t\t\treturn false;\r\n\t\telse\r\n\t\t\treturn musicPlayer.isPlaying();\r\n\t}", "@Override\n public void onPrepared(MediaPlayer mp) {\n Log.d(TAG, \"onPrepared: GOTTING CALLED\");\n playMedia();\n }", "public interface OnMediaPlayingListener {\n /**\n * duration for the media file\n * @param duration milliseconds\n */\n void onStart(int duration);\n\n void onComplete();\n\n /**\n * media play progress\n * @param currentPosition milliseconds\n */\n void onProgress(int currentPosition);\n}", "public void initMusicPlayer() {\n PatariSingleton.getInstance().getMediaPlayer().setWakeMode(getApplicationContext(), PowerManager.PARTIAL_WAKE_LOCK);\n PatariSingleton.getInstance().getMediaPlayer().setAudioStreamType(AudioManager.STREAM_MUSIC);\n PatariSingleton.getInstance().getMediaPlayer().setOnPreparedListener(this);\n PatariSingleton.getInstance().getMediaPlayer().setOnCompletionListener(this);\n PatariSingleton.getInstance().getMediaPlayer().setOnErrorListener(this);\n PatariSingleton.getInstance().getMediaPlayer().setOnBufferingUpdateListener(this);\n try {\n if (wifiLock != null && wifiLock.isHeld()) {\n wifiLock.release();\n }\n } catch (Exception e) {\n e.printStackTrace();\n }\n try {\n wifiLock = ((WifiManager) getApplication().getApplicationContext().getSystemService(Context.WIFI_SERVICE)).createWifiLock(WifiManager.WIFI_MODE_FULL, \"mylock\");\n wifiLock.acquire();\n } catch (Exception e) {\n e.printStackTrace();\n }\n IS_PROGRESS = false;\n }", "@Override\r\n\tpublic boolean isPlaying() {\n\t\treturn mediaPlayer.isPlaying();\r\n\t}", "public void play() {\n\t\tmusic.play();\n\t\tsyncPosition();\n\t}", "public interface MediaPlayer {\n void play(String audioType, String fileName);\n}", "private static void playAudio(String musicFile) {\n }", "private void startMusic() {\r\n final Format input1 = new AudioFormat(AudioFormat.MPEGLAYER3);\r\n final Format input2 = new AudioFormat(AudioFormat.MPEG);\r\n final Format output = new AudioFormat(AudioFormat.LINEAR);\r\n PlugInManager.addPlugIn(\r\n \"com.sun.media.codec.audio.mp3.JavaDecoder\",\r\n new Format[]{input1, input2},\r\n new Format[]{output},\r\n PlugInManager.CODEC\r\n );\r\n try {\r\n final File f = new File(\"support_files//tetris.mp3\");\r\n myPlayer = Manager.createPlayer(new MediaLocator(f.toURI().toURL()));\r\n } catch (final NoPlayerException | IOException e) {\r\n e.printStackTrace();\r\n }\r\n if (myPlayer != null) {\r\n myPlayer.start();\r\n }\r\n }", "public interface MediaPlayer {\n public void play(String audioType, String fileName);\n}", "public interface MediaPlayer {\n public void play(String audioType, String fileName);\n}", "@Override\n public void onPrepared(MediaPlayer mediaPlayer) {\n\n }", "public boolean isPlaying(StarObjectClass self){ \r\n \t\tStarCLEMediaPlayer mediaplayer = (StarCLEMediaPlayer)WrapAndroidClass.GetAndroidObject(self,\"AndroidObject\");\r\n \t\tif( mediaplayer == null )\r\n \t\t\treturn false;\r\n \t\treturn mediaplayer.isPlaying();\r\n \t}", "public static void startMusic()\r\n\t{\r\n\t\tif ( musicPlayer == null )\r\n\t\t\tmusicPlayer = new MusicPlayer( \"Music2.mid\" );\r\n\t\telse\r\n\t\t\tmusicPlayer.play();\r\n\t}", "public void play(boolean music) {\n\t\tplay(1.0f, 1.0f, music);\n\t}", "public static void startMusic()\n\t{\n\t\tmusic.loop();\n\t}", "public void setMusicOn(boolean on){\r\n\t\tmusicOn = on;\r\n\t}", "protected void startMediaPlayer() {\n\n Log.i(LOG_TAG, \"startMediaPlayer\");\n\n // If media player is pause or playing, just play\n if (mpState.equals(RadioPlayerService.MP_PAUSED)) {\n // Play!!!\n mediaPlayer.start();\n radioStation.setPlaying(true);\n playingTimeRunning = true;\n setMPState(RadioPlayerService.MP_PLAYING);\n sendStatus();\n\n //Retrieve meta data from server\n if (radioStation.getListenType().equals(\"0\") || radioStation.getListenType().equals(\"1\")) {\n refreshMetadata(radioStation.getListenUrl());\n }\n\n } else if (mpState.equals(RadioPlayerService.MP_PLAYING)) {\n //We are already playing, well do nothing\n\n } else if (mpState.equals(RadioPlayerService.MP_ERROR)) {\n\n //Media player should be reset\n\n } else {\n //Because prepareAsync() can take too long if radio station server isn't reachable, check for it\n setMPState(RadioPlayerService.MP_CONNECTING);\n mediaPlayer.prepareAsync();\n sendStatus();\n }\n\n }", "public void playerUpdate(Player player, String event, Object eventData) {\n if (event.equals(PlayerListener.END_OF_MEDIA)) {\n if ((!myShouldPause) && (!myGamePause)) {\n try {\n myPlayer.start();\n } catch (Exception e) {\n // the music isn't necessary, so we ignore exceptions.\n }\n }\n }\n }", "public void playSound() {\n\t\tmediaPlayer.play();\n\t}", "private void musicClicked() {\n MatchScreen.setMusicVolume(MatchScreen.getMusicVolume() == 0 ? 0.5f : 0);\n setSoundButtonColor(MatchScreen.getMusicVolume() == 0, music);\n }", "public void playSong() {\n player.reset();\n Song playedSong;\n //get the right song\n if (shuffle) {\n int newSong = shuffleIndexes.get(songPosn);\n playedSong = songs1.get(newSong);\n } else {\n playedSong = songs1.get(songPosn);\n }\n songTitle = playedSong.getSongName();\n Uri uri = Uri.parse(playedSong.getSongLocation());\n try {\n player.setDataSource(getApplicationContext(), uri);\n } catch (Exception e) {\n Log.e(\"MUSIC SERVICE\", \"Error setting data source\", e);\n }\n state = PlaybackStateCompat.STATE_PLAYING;\n player.prepareAsync();\n showNotification();\n }", "public boolean getBackgroundMusic(){\n return backgroundMusicOn;\n }", "public void mp3(View view) {\n mp1 = MediaPlayer.create(this, R.raw.heyjude);\n mp1.setLooping(false);\n mp1.setVolume(100, 100);\n mp1.start();\n }", "public static void start(Context c, int music, boolean force) {\r\n if ((!force) && (currentMusic_ != INVALID_NUMBER)) {\r\n // already playing some music and not forced to change immediately\r\n if (music != INVALID_NUMBER) {\r\n nextMusic_ = music;\r\n MediaPlayer mp = players_.get(music);\r\n if (mp == null) {\r\n mp = MediaPlayer.create(c, music);\r\n players_.put(music, mp);\r\n }\r\n MediaPlayer cp = players_.get(currentMusic_);\r\n if (cp != null) {\r\n cp.setOnCompletionListener(new OnCompletionListener() {\r\n @Override\r\n public void onCompletion(MediaPlayer p) {\r\n MusicHandler.next();\r\n }\r\n });\r\n cp.setLooping(false);\r\n }\r\n }\r\n return;\r\n }\r\n if (currentMusic_ == music) {\r\n // already playing this music\r\n return;\r\n }\r\n if (currentMusic_ != INVALID_NUMBER) {\r\n // playing some other music, pause it and change\r\n pause();\r\n }\r\n currentMusic_ = music;\r\n MediaPlayer mp = players_.get(music);\r\n if (mp != null) {\r\n if (!mp.isPlaying()) {\r\n // Note: This continues the piece where it last let off\r\n mp.setLooping(true);\r\n mp.setOnCompletionListener(null);\r\n mp.start();\r\n return;\r\n }\r\n } else {\r\n mp = MediaPlayer.create(c, music);\r\n players_.put(music, mp);\r\n if (mp == null) {\r\n // Log an error, but don't do anthing (we do not want to risk f/c the app)\r\n Log.e(TAG, \"player was not created successfully\");\r\n } else {\r\n mp.setLooping(true);\r\n mp.setOnCompletionListener(null);\r\n mp.start();\r\n }\r\n }\r\n }", "boolean play();", "@Override\n public void playStart() {\n }", "@Override\r\n\t\t\t\tpublic void onCompletion (MediaPlayer theMediaPlayer) \r\n\t\t\t\t{\n\t\t\t\t\t// 11/03/2017 ECU check if any looping is needed\r\n\t\t\t\t\t// -------------------------------------------------------------\r\n\t\t\t\t\tif (loopCounter <= 0)\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t// ---------------------------------------------------------\r\n\t\t\t\t\t\t// 11/03/2017 ECU everything done so just check on the global \r\n\t\t\t\t\t\t// media player\r\n\t\t\t\t\t\t// ---------------------------------------------------------\r\n\t\t\t\t\t\t// 10/03/2017 ECU check if the global media player needs to be\r\n\t\t\t\t\t\t// 'resumed'\r\n\t\t\t\t\t\t// 15/03/2019 ECU whether there is a 'paused' media or not\r\n\t\t\t\t\t\t// it is necessary to release the resources\r\n\t\t\t\t\t\t// used in this class\r\n\t\t\t\t\t\t// ---------------------------------------------------------\r\n\t\t\t\t\t\tif (mediaPlayerPaused)\r\n\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\t// -----------------------------------------------------\r\n\t\t\t\t\t\t\t// 10/03/2017 ECU the global media player needs to be resumed\r\n\t\t\t\t\t\t\t// -----------------------------------------------------\r\n\t\t\t\t\t\t\tMusicPlayer.playOrPause (true);\r\n\t\t\t\t\t\t\t// -----------------------------------------------------\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t// ---------------------------------------------------------\r\n\t\t\t\t\t\t// 04/09/2017 ECU make sure the resources are released\r\n\t\t\t\t\t\t// 05/09/2017 ECU changed to use the local method\r\n\t\t\t\t\t\t// 15/03/2019 ECU changed to always release resources\r\n\t\t\t\t\t\t// ---------------------------------------------------------\r\n\t\t\t\t\t\tstop ();\r\n\t\t\t\t\t\t// ---------------------------------------------------------\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t// ---------------------------------------------------------\r\n\t\t\t\t\t\t// 11/03/2017 ECU check about loops\r\n\t\t\t\t\t\t// ---------------------------------------------------------\r\n\t\t\t\t\t\tmediaPlayer.seekTo (theLoopPosition);\r\n\t\t\t\t\t\tmediaPlayer.start ();\r\n\t\t\t\t\t\t// ---------------------------------------------------------\r\n\t\t\t\t\t\t// 11/03/2017 ECU decrement the loop counter\r\n\t\t\t\t\t\t// ---------------------------------------------------------\r\n\t\t\t\t\t\tloopCounter--;\r\n\t\t\t\t\t\t// ---------------------------------------------------------\r\n\t\t\t\t\t}\r\n\t\t\t\t\t// -------------------------------------------------------------\r\n\t\t\t\t}", "public void play() {\n\t\t\r\n\t}", "public void onPlayerPlay() {\n\t\trunOnUiThread(new Runnable() {\n\t\t\tpublic void run() {\n\t\t\t\tplay.setVisibility(View.GONE);\n\t\t\t\tpause.setVisibility(View.VISIBLE);\n\t\t\t\tsetCurrentTrack();\n\t\t\t}\n\t\t});\n\t}", "public void playFromNotification() {\n play(mRadioUrl);\n }", "@Override\n\tpublic void onPrepared(MediaPlayer mp) {\n\t\tmp.start();\n\t}", "public void play()\n\t{\n\t\tif (canPlay)\n\t\t{\n\t\t\tsong.play();\n\t\t\tsong.rewind();\n\t\t\tif (theSong == \"SG1\" || theSong == \"SG2\")\n\t\t\t\tcanPlay = false;\n\t\t}\n\t}", "public void pauseSong() {\n if (mp.isPlaying()) {\n mp.pause();\n }\n }", "private void nyalakanAlarm() {\n\t\t\n\t\tif (mediaplayer.isPlaying() == false) {\n\t\t\t//nyalakan alarm bahaya\n\t\t\tmediaplayer.start();\n\t\t}\n\t\telse {\n\t\t\t//tidak melakukan apa apa\n\t\t}\t\t\n\t}", "public void play(){\n Log.d(TAG, \"startAudio: called\");\n if(mMediaPlayer!=null){\n\n mMediaPlayer.start();\n mProgressBar.setProgress(mMediaPlayer.getCurrentPosition());\n mProgressBar.setMax(mMediaPlayer.getDuration());\n\n // updating progress bar\n seekHandler.postDelayed(updateSeekBar, 5);\n }\n }", "public boolean reset(final PlayListItem playListItem) {\n\n try {\n stop();\n\n mCurrentlyPlaying = playListItem;\n\n mMediaPlayer = MediaPlayer.create(this, Uri.parse(playListItem.getTrackUri()));\n mMediaPlayer.setAudioStreamType(AudioManager.STREAM_MUSIC);\n\n // Keeps the device running, but allows the screen to turn off.\n mMediaPlayer.setWakeMode(getApplicationContext(), PowerManager.PARTIAL_WAKE_LOCK);\n\n mMediaPlayer.setOnPreparedListener(new MediaPlayer.OnPreparedListener() {\n\n @Override\n public void onPrepared(MediaPlayer mp) {\n\n // Media has loaded and we're ready to begin playing.\n Log.d(TAG, \"onPrepared() called\");\n mMediaPlayer.start();\n\n // Notify listeners that a new track has started.\n PreferenceManager.getDefaultSharedPreferences(getApplicationContext())\n .edit()\n .putString(MainActivity.PREF_CURRENT_ALBUM, playListItem.getAlbumName())\n .putString(MainActivity.PREF_CURRENT_ARTIST_NAME, playListItem.getArtistName())\n .putString(MainActivity.PREF_CURRENT_ARTIST_SPOTIFY_ID, playListItem.getArtistId())\n .putString(MainActivity.PREF_CURRENT_TRACK_NAME, playListItem.getTrackName())\n .putString(MainActivity.PREF_CURRENT_TRACK_SPOTIFY_ID, playListItem.getTrackId())\n .putString(MainActivity.PREF_CURRENT_TRACK_URL, playListItem.getTrackUri())\n .putBoolean(MainActivity.PREF_IS_PLAYING, true)\n .commit();\n\n Intent intent = new Intent(TRACK_START_BROADCAST_FILTER);\n intent.putExtra(SpotifyStreamerActivity.KEY_CURRENT_TRACK, playListItem);\n LocalBroadcastManager.getInstance(StreamerMediaService.this).sendBroadcast(intent);\n }\n });\n\n mMediaPlayer.setOnErrorListener(new MediaPlayer.OnErrorListener() {\n\n @Override\n public boolean onError(MediaPlayer mp, int what, int extra) {\n Log.d(TAG, \"onError() called. what:\" + what + \" extra:\" + extra);\n return false;\n }\n });\n\n mMediaPlayer.setOnCompletionListener(new MediaPlayer.OnCompletionListener() {\n\n @Override\n public void onCompletion(MediaPlayer mp) {\n\n if (!continueOnCompletion) {\n\n mNotificationManager.cancel(NotificationTarget.NOTIFICATION_ID);\n\n PreferenceManager.getDefaultSharedPreferences(getApplicationContext())\n .edit()\n .putBoolean(MainActivity.PREF_IS_PLAYING, false)\n .commit();\n }\n\n // Notify listeners that the track has completed.\n Intent intent = new Intent(TRACK_STOP_BROADCAST_FILTER);\n LocalBroadcastManager.getInstance(StreamerMediaService.this).sendBroadcast(intent);\n }\n\n });\n\n } catch (Exception e) {\n Log.e(TAG, \"Error in reset(): \" + e.getMessage());\n return false;\n }\n\n return true;\n }", "@Override\r\n\tpublic void opening(MediaPlayer mediaPlayer)\r\n\t{\n\r\n\t}", "@Override\n protected void onStop() {\n super.onStop();\n stopMusic();\n }", "private void playHintAudio() {\n AudioManager audioManager = (AudioManager)getContext().getSystemService(Context.AUDIO_SERVICE);\n int mode = audioManager.getRingerMode();\n Log.d(TAG,\"mode = \" + mode);\n\n if(mode != AudioManager.RINGER_MODE_SILENT && mode != AudioManager.RINGER_MODE_VIBRATE) {\n // prize modify for bug 44603 by zhaojian 20171205 start\n mMediaPlayer = MediaPlayer.create(getContext(),R.raw.hb_sound2);\n Log.d(\"debug\",\"isNotifySound = \" + getConfig().isNotifySound());\n if(getConfig().isNotifySound()) {\n mMediaPlayer.setOnPreparedListener(new MediaPlayer.OnPreparedListener() {\n @Override\n public void onPrepared(MediaPlayer mp) {\n mp.start();\n }\n });\n mMediaPlayer.setOnCompletionListener(new MediaPlayer.OnCompletionListener() {\n @Override\n public void onCompletion(MediaPlayer mp) {\n mp.release();\n }\n });\n mMediaPlayer.start();\n }\n // prize modify for bug 44603 by zhaojian 20171205 end\n }\n }", "private void start() {\n\t\t// 开启播放器\n\t\tmCurrentMediaPlayer.start();\n\t\tsetState(STARTED);\n\n\t\t// 开启计时心跳\n\t\tmHandler.postDelayed(mUpdateTimeTask, 500);\n\t\tif (mPlayerEngineListener != null) {\n\t\t\tmPlayerEngineListener.onTrackStart();\n\t\t}\n\t\t// 开启频谱\n\t\t// mHandler.postDelayed(mSetFxAndUI, 500);\n\t\t// setupVisualizerFxAndUI();\n\n\t\tLog.i(this.getClass().getSimpleName(), \" music player : started...\");\n\t}", "@Override\n\tpublic void play() {\n\n\t}", "@Override\n\tpublic void play() {\n\t\t\n\t}", "public void playSoundtrack() {\n if(this.musicEnabled) {\n try {\n Clip soundtrackClip = AudioSystem.getClip();\n AudioInputStream inputStream = AudioSystem.getAudioInputStream(new BufferedInputStream(Assets.soundTrack));\n soundtrackClip.open(inputStream);\n soundtrackClip.start();\n soundtrackClip.loop(Clip.LOOP_CONTINUOUSLY);\n } catch (Exception e) {\n e.printStackTrace();\n System.err.println(e.getMessage());\n }\n }\n }", "public void play() {\n\t\tint requestStatus = mAudioManager.requestAudioFocus(\n\t\t\t\tmAudioFocusListener, AudioManager.STREAM_MUSIC,\n\t\t\t\tAudioManager.AUDIOFOCUS_GAIN);\n\n\t\tif (DEBUG)\n\t\t\tLog.d(TAG, \"Starting playback: audio focus request status = \"\n\t\t\t\t\t+ requestStatus);\n\n\t\tif (requestStatus != AudioManager.AUDIOFOCUS_REQUEST_GRANTED) {\n\t\t\treturn;\n\t\t}\n\n\t\tmAudioManager.registerMediaButtonEventReceiver(new ComponentName(this\n\t\t\t\t.getPackageName(), MediaButtonIntentReceiver.class.getName()));\n\n\t\tif (mPlayer.isInitialized()) {\n\t\t\t// if we are at the end of the song, go to the next song first\n\t\t\tlong duration = mPlayer.duration();\n\t\t\tif (mRepeatMode != REPEAT_CURRENT && duration > 2000\n\t\t\t\t\t&& mPlayer.position() >= duration - 2000) {\n\t\t\t\tgotoNext(true);\n\t\t\t}\n\n\t\t\tmPlayer.start();\n\t\t\t// make sure we fade in, in case a previous fadein was stopped\n\t\t\t// because\n\t\t\t// of another focus loss\n\t\t\tmMediaplayerHandler.removeMessages(FADEDOWN);\n\t\t\tmMediaplayerHandler.sendEmptyMessage(FADEUP);\n\n\t\t\tif (!mIsSupposedToBePlaying) {\n\t\t\t\tmIsSupposedToBePlaying = true;\n\t\t\t\tnotifyChange(EVENT_PLAYSTATE_CHANGED);\n\t\t\t}\n\n\t\t\tupdateNotification();\n\t\t} else if (mPlayListLen <= 0) {\n\t\t\t// This is mostly so that if you press 'play' on a bluetooth headset\n\t\t\t// without every having played anything before, it will still play\n\t\t\t// something.\n\t\t\tshuffleAll();\n\t\t}\n\t}", "@Override\n public void run() {\n // TODO Auto-generated method stub\n running = true;\n AudioFile song = musicFiles.get(currentSongIndex);\n song.play();\n while(running){\n if(!song.isPlaying()){\n currentSongIndex++;\n if(currentSongIndex >= musicFiles.size()){\n currentSongIndex = 0;\n }\n song = musicFiles.get(currentSongIndex);\n song.play();\n }\n try{\n Thread.sleep(1);\n }\n catch (InterruptedException e){\n e.printStackTrace();\n } \n }\n }", "public interface AudioPlayListener {\n\n\n /**\n * 播放\n * @param url 音频url 包括网络url,本地路径,raw资源文件\n */\n void play(String url,OnAudioPlayListener onAudioPlayListener);\n\n /**\n * 暂停\n */\n void pause();\n\n /**\n * 开始\n */\n void start();\n\n /**\n * 重新播放\n */\n void restart();\n\n\n boolean isPlaying();\n\n\n /**\n * 获取音频时长\n * @return\n */\n long getDuration();\n\n /**\n * 仅仅获取音频时长,由于获取是时长是异步操作,通过回调方式回去\n * @param sourceUrl 音频文件url或者本地路径\n *\n *note 只支持单个音频文件,如果要支持列表多个音频文件,是从服务器端返回总时长\n **/\n void getOnlyDuration(String sourceUrl,OnAudioPlayListener2 listener);\n\n\n /**\n * 释放播放器\n */\n void release();\n\n /**\n * 获取播放的位置\n */\n long getCurrentPosition();\n\n /**\n * 设置循环播放\n * @param isLoop\n */\n void setLooping(boolean isLoop);\n}", "public void startSong() {\n if (trackPlaying) {\n trackPlaying = false;\n mp.finish();\n\n System.out.print(mp.isFinished() + \"+\" + mp.isPaused());\n }\n\t\n\t//The startSong overloads start and pause. If the song is pause, then resume.\n if (mp.isPaused() && !mp.isFinished()) {\n mp.resume();\n return;\n }\n\n sequence = sc.getSongSequence();\n try {\n mp.start(sequence);\n } catch (InvalidMidiDataException ex) {\n Logger.getLogger(uMusicPlayerController.class.getName()).log(Level.SEVERE, null, ex);\n } catch (MidiUnavailableException ex) {\n Logger.getLogger(uMusicPlayerController.class.getName()).log(Level.SEVERE, null, ex);\n }\n }", "private void setupPlayer() {\n player = MediaPlayer.create(MediaPlayerActivity.this, R.raw.byte_music);\n updateState(MediaPlayerState.STATE_PREPARED);\n }", "public interface MediaPlayer {\n public void play();\n}", "@Override\n public void onCompletion(MediaPlayer mp) {\n if(isRepeat){\n // repeat is on play same song again\n playSong(currentSongIndex);\n } else if(isShuffle){\n // shuffle is on - play a random song\n Random rand = new Random();\n currentSongIndex = rand.nextInt((songsList.size() - 1) - 0 + 1) + 0;\n playSong(currentSongIndex);\n } else{\n // no repeat or shuffle ON - play next song\n if(currentSongIndex < (songsList.size() - 1)){\n playSong(currentSongIndex + 1);\n currentSongIndex = currentSongIndex + 1;\n }else{\n // play first song\n playSong(0);\n currentSongIndex = 0;\n }\n }\n\n }", "public void onPrepared(MediaPlayer player) {\n //player.start();\n }", "@Override\n public void initialize() {\n //talonOrchestra.playMusic();\n }", "private void startPlaying() {\n try {\n mPlayer = new MediaPlayer();\n try {\n mPlayer.setDataSource(audioFile.getAbsolutePath());\n mPlayer.prepare();\n mPlayer.start();\n } catch (IOException e) {\n Log.e(LOG_TAG, \"prepare() failed\");\n }\n showTimer(false);\n } catch (Exception e) {\n logException(e, \"MicManualFragment_startPlaying()\");\n }\n\n }", "@Override\n public void onSeekComplete(MediaPlayer mp) {\n }", "@Override\n public void onSeekComplete(MediaPlayer mp) {\n }", "@Override\n public void updateSongValue() {\n\n if (!MusicManager.isPlaying())\n {\n if (newFragAuto !=null)\n {\n newFragAuto.setPlaying(MusicManager.isPlaying());\n }\n playNewSong();\n } else\n {\n MusicManager.pause();\n Log.e(\"UpdateSongVal\", \"AlreadyPlaying\");\n }\n// newFragAuto.updateValues(MusicManager.isPlaying());\n\n }", "boolean isPlaying() { return playing; }", "public interface MediaPlayer {\r\n\r\n public void play(String mediaType,String fileName);\r\n}", "@Override\n public void onCompletion(MediaPlayer mp) {\n mp.reset();\n nextMusic();\n\n }", "public void play()\n {\n this.mediaPlayer = new MediaPlayer(file);\n this.mediaPlayer.setVolume(volume);\n\n // Listener for end of media.\n mediaPlayer.setOnEndOfMedia(() -> {\n this.mediaPlayer.stop();\n });\n\n mediaPlayer.play();\n }", "public void playAudio() {\n\n }", "@Override\n public void onReceive(Context arg0, Intent arg1) {\n\n String action=arg1.getAction();\n if(action.equals(\"com.example.musicplayer.play\"))\n {\n mp.start();\n control_functions(PLAY);\n }\n else if(action.equals(\"com.example.musicplayer.pause\"))\n {\n mp.pause();\n control_functions(PAUSE);\n }\n else if(action.equals(\"com.example.musicplayer.next\"))\n {\n try\n {\n String name=arg1.getStringExtra(\"name\");\n Uri uri = Uri.parse(name);//Environment.getExternalStorageDirectory().getPath()+\"/songs/\"+name);\n mp.reset();\n mp.setDataSource(arg0, uri);\n mp.setAudioStreamType(AudioManager.STREAM_MUSIC);\n mp.setLooping(true);\n mp.prepare();\n mp.start();seek.setMax(mp.getDuration());\n }catch (Exception e) {\n // TODO: handle exception\n }\n }\n else if(action.equals(\"com.example.musicplayer.previous\"))\n {\n try\n {\n String name=arg1.getStringExtra(\"name\");\n Uri uri = Uri.parse(name);//Environment.getExternalStorageDirectory().getPath()+\"/songs/\"+name);\n mp.reset();\n mp.setDataSource(arg0, uri);\n mp.setAudioStreamType(AudioManager.STREAM_MUSIC);\n mp.setLooping(true);\n mp.prepare();\n mp.start();\n seek.setMax(mp.getDuration());\n }catch (Exception e) {\n // TODO: handle exception\n }\n }\n\n else if(action.equals(\"com.example.musicplayer.frmList\"))\n {\n //Toast.makeText(SongService.this, \"previous\", 1).show();\n try\n {\n String name=arg1.getStringExtra(\"name\");\n Uri uri = Uri.parse(name);//Environment.getExternalStorageDirectory().getPath()+\"/songs/\"+name);\n filePath=uri.getPath();\n //Toast.makeText(getApplicationContext(),name,1).show();\n mp.reset();\n mp.setDataSource(arg0, uri);\n mp.setAudioStreamType(AudioManager.STREAM_MUSIC);\n mp.setLooping(true);\n mp.prepare();\n mp.start();\n seek.setMax(mp.getDuration());\n seek.setOnSeekBarChangeListener((SeekBar.OnSeekBarChangeListener) arg0);\n control_functions(NEW);\n new sendSong().execute();\n } catch (Exception e) {\n // TODO: handle exception\n }\n }\n else if(action.equals(\"com.example.musicplayer.frwd\"))\n {\n if(mp.getDuration()-mp.getCurrentPosition()>1250)\n {\n mp.seekTo(mp.getCurrentPosition()+1250);\n }\n else\n {\n mp.seekTo(mp.getDuration());\n }\n }\n else if(action.equals(\"com.example.musicplayer.rvrse\"))\n {\n if(mp.getCurrentPosition()>1250)\n {\n mp.seekTo(mp.getCurrentPosition()-1250);\n }\n else\n {\n mp.seekTo(0);\n }\n }\n else if(action.equals(\"com.example.musicplayer.jststarted\"))\n {\n if(mp.isPlaying())\n {\n CreateGroup.play_pause.setText(\"PAUSE\");\n }\n }\n else if(action.equals(\"com.example.musicplayer.seekBar\"))\n {\n seek=CreateGroup.seek;\n seek.setMax(mp.getDuration());\n seek.setOnSeekBarChangeListener((SeekBar.OnSeekBarChangeListener) arg0);\n //seek.setProgress(0);\n }\n else if(action.equals(\"com.example.musicplayer.addlist\"))\n {\n ArrayList<MusicData> list=arg1.getParcelableArrayListExtra(\"list\");\n }\n else if(action.equals(\"com.example.musicplayer.seekBarComp\"))\n {\n try\n {\n String name=arg1.getStringExtra(\"name\");\n Uri uri = Uri.parse(Environment.getExternalStorageDirectory().getPath()+\"/songs/\"+name);\n mp.reset();\n mp.setDataSource(arg0, uri);\n mp.setAudioStreamType(AudioManager.STREAM_MUSIC);\n mp.setLooping(true);\n mp.prepare();\n mp.start();seek.setMax(mp.getDuration());\n }catch (Exception e) {\n // TODO: handle exception\n }\n }\n }", "@Override\n public void playStop() {\n }", "public void onClickPlay() {\n if (player != null) {\n if (player.mediaPlayer.isPlaying()) {\n player.pauseMedia();\n changePlayPauseIcon(PLAY);\n isPauseResume = !isPauseResume;\n playListAdapter.setPlayPause(true);\n } else {\n if (isPauseResume) {\n player.resumeMedia();\n changePlayPauseIcon(PAUSE);\n isPauseResume = !isPauseResume;\n playListAdapter.setPlayPause(false);\n } else {\n playSelectSong();\n }\n }\n } else {\n playSelectSong();\n }\n\n }", "public static void startMusic()\n\t{\n\t\tif (music == null)\n\t\t{\n\t\t\tloadMusic();\n\t\t\tif (music.size() < 2)\n\t\t\t{\n\t\t\t\tthrow new GameLogicException(\"At least two songs must be specified.\");\n\t\t\t}\n\t\t}\n\t\t\n\t\tcurrentMusicFile = 0;\n\t\tmusic.get(currentMusicFile).setVolume(musicVolume / 100.f);\n\t\tmusic.get(currentMusicFile).play();\n\t\tmusic.get(currentMusicFile).setOnCompletionListener(musicOnCompletionListener);\n\t}", "@Override\n\t\t\t\t\t\t\tpublic void onPrepared(MediaPlayer mediaPlayer) {\n\t\t\t\t\t\t\t\tmediaPlayer.setPlaybackSpeed(1.0f);\n\t\t\t\t\t\t\t\tbtnPlay.setImageResource(R.drawable.pause_icon);\n\t\t\t\t\t\t\t\tnowPrepare = false;\n\n\t\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\t\tList<MusicBean> datas = mAdapter.getData();\n\t\t\t\t\t\t\t\t\tfor (int i = 0; i < datas.size(); i++) {\n\t\t\t\t\t\t\t\t\t\tif (datas.get(i).getUrl().equals(path)) {\n\t\t\t\t\t\t\t\t\t\t\tmAdapter.setSelectItemPosi(i);\n\t\t\t\t\t\t\t\t\t\t\tmAdapter.notifyDataSetChanged();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t} catch (Exception e) {\n\t\t\t\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}", "private void playMusicWithPosition(int position, List<Song> songs) {\n if (position >= songs.size()) {\n position = 0;\n }\n song = songs.get(position);\n filehientai = songs.get(position).getData();\n\n isPlay = true;\n tv_fileduocchon.setText(song.getTitle());\n tv_fileduocchon.setOnClickListener(this);\n\n btnPlay.setImageResource(android.R.drawable.ic_media_pause);\n startService(createIntentService(filehientai));\n }", "public void play(){\n\t\t\n\t}", "@Override\n public SoundClip getGameMusic(){\n return gameMusic;\n }", "@Override\n\t\t\tpublic boolean onError(MediaPlayer mp, int what, int extra) {\n\t\t\t\tLog.d(\"Error in Video playing\",\"\"+what);\n\t\t\t\treturn true;\n\t\t\t}", "public void onPrepared(MediaPlayer player) {\n player.start(); \n }", "@Override\n public void onCompletion(MediaPlayer mediaPlayer) {\n }" ]
[ "0.74028426", "0.73968554", "0.7318718", "0.72862446", "0.7249258", "0.72358453", "0.7174249", "0.71558154", "0.71500504", "0.7127881", "0.71081215", "0.7104589", "0.7080015", "0.7057468", "0.6995124", "0.6981115", "0.6975359", "0.6970095", "0.6943196", "0.6942955", "0.6937322", "0.6928564", "0.6897405", "0.6892597", "0.68893415", "0.6868104", "0.68284714", "0.68272185", "0.6819786", "0.68135124", "0.67857486", "0.67852074", "0.677311", "0.67606056", "0.6742437", "0.674201", "0.67353654", "0.67066926", "0.67066926", "0.67062134", "0.6698473", "0.6697348", "0.6683494", "0.66753626", "0.6674175", "0.6669627", "0.66632676", "0.66620475", "0.66601425", "0.66475695", "0.6647248", "0.66367763", "0.6633307", "0.662612", "0.6612453", "0.6608399", "0.6597124", "0.659009", "0.65881294", "0.65848035", "0.65812635", "0.65810317", "0.6574223", "0.65637064", "0.6557953", "0.655337", "0.6545912", "0.6535816", "0.65232307", "0.6516923", "0.6516125", "0.6514413", "0.65129864", "0.65100914", "0.6510054", "0.6508086", "0.65016013", "0.65007746", "0.649644", "0.6494922", "0.6491818", "0.64883024", "0.64880925", "0.64880925", "0.6486535", "0.6485078", "0.6484023", "0.64829034", "0.64796305", "0.6472849", "0.64715964", "0.64714795", "0.646981", "0.6463344", "0.6456774", "0.6455127", "0.6451364", "0.6439836", "0.6438243", "0.64369196", "0.64345104" ]
0.0
-1
/ Below: methods overridden from the adaptee class. All calls are redirected to the adaptee.
@Override public EList<SourceRef> getSource() { return adaptee.getSource(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "public interface Adaptable {\n\n}", "public interface IAdapter extends IManagable {\n\n /**\n \t * Instruct the adapter to configure itself. The adapter will call the\n \t * pipeline to configure itself, the pipeline will call the individual\n \t * pipes to configure themselves.\n \t * @see nl.nn.adapterframework.pipes.AbstractPipe#configure()\n \t * @see PipeLine#configure()\n \t */\n \tpublic void configure() throws ConfigurationException;\n \t\n \t/**\n \t * The messagekeeper is used to keep the last x messages, relevant to\n \t * display in the web-functions.\n \t */ \n\tpublic MessageKeeper getMessageKeeper();\n\tpublic IReceiver getReceiverByName(String receiverName);\n\tpublic Iterator getReceiverIterator();\n\tpublic PipeLineResult processMessage(String messageId, String message, IPipeLineSession pipeLineSession);\n\tpublic PipeLineResult processMessageWithExceptions(String messageId, String message, IPipeLineSession pipeLineSession) throws ListenerException;\n\n \tpublic void registerPipeLine (PipeLine pipeline) throws ConfigurationException;\n \tpublic void setName(String name);\n \tpublic boolean isAutoStart();\n\tpublic String toString();\n\n\tpublic String formatErrorMessage(String errorMessage, Throwable t, String originalMessage, String messageID, INamedObject objectInError, long receivedTime);\n\t\t\n\tpublic void forEachStatisticsKeeperBody(StatisticsKeeperIterationHandler hski, Object data, int action) throws SenderException ;\n\n /**\n * state to put in PipeLineResult when a PipeRunException occurs.\n */\n\tpublic String getErrorState();\n}", "@Override\n protected void prot() {\n }", "abstract public void setUpAdapter();", "@Override\n public Adapter adapt(Notifier notifier, Object type)\n {\n return super.adapt(notifier, this);\n }", "private void offer() {\n\t\t\t\n\t\t}", "@Override\n\tpublic Adapter adapt(Notifier notifier, Object type) {\n\t\treturn super.adapt(notifier, this);\n\t}", "@Override\n\tpublic Adapter adapt(Notifier notifier, Object type) {\n\t\treturn super.adapt(notifier, this);\n\t}", "@Override\n\tpublic Adapter adapt(Notifier notifier, Object type) {\n\t\treturn super.adapt(notifier, this);\n\t}", "@Override\n\tpublic Adapter adapt(Notifier notifier, Object type) {\n\t\treturn super.adapt(notifier, this);\n\t}", "@Override\n\tpublic Adapter adapt(Notifier notifier, Object type) {\n\t\treturn super.adapt(notifier, this);\n\t}", "@Override\n\tpublic Adapter adapt(Notifier notifier, Object type) {\n\t\treturn super.adapt(notifier, this);\n\t}", "@Override\n\tpublic Adapter adapt(Notifier notifier, Object type) {\n\t\treturn super.adapt(notifier, this);\n\t}", "@Override\n\tpublic Adapter adapt(Notifier notifier, Object type) {\n\t\treturn super.adapt(notifier, this);\n\t}", "@Override\n\tpublic Adapter adapt(Notifier notifier, Object type) {\n\t\treturn super.adapt(notifier, this);\n\t}", "@Override\n\tpublic Adapter adapt(Notifier notifier, Object type) {\n\t\treturn super.adapt(notifier, this);\n\t}", "@Override\n\tpublic Adapter adapt(Notifier notifier, Object type) {\n\t\treturn super.adapt(notifier, this);\n\t}", "@Override\n\tpublic Adapter adapt(Notifier notifier, Object type) {\n\t\treturn super.adapt(notifier, this);\n\t}", "@Override\n\tpublic Adapter adapt(Notifier notifier, Object type) {\n\t\treturn super.adapt(notifier, this);\n\t}", "@Override\n\tpublic Adapter adapt(Notifier notifier, Object type) {\n\t\treturn super.adapt(notifier, this);\n\t}", "@Override\n\tpublic Adapter adapt(Notifier notifier, Object type) {\n\t\treturn super.adapt(notifier, this);\n\t}", "@Override\r\n\tpublic Adapter adapt(Notifier notifier, Object type) {\r\n\t\treturn super.adapt(notifier, this);\r\n\t}", "@Override\r\n\tpublic Adapter adapt(Notifier notifier, Object type) {\r\n\t\treturn super.adapt(notifier, this);\r\n\t}", "@Override\r\n\tpublic Adapter adapt(Notifier notifier, Object type) {\r\n\t\treturn super.adapt(notifier, this);\r\n\t}", "@Override\r\n\tpublic Adapter adapt(Notifier notifier, Object type) {\r\n\t\treturn super.adapt(notifier, this);\r\n\t}", "@Override\n\tprotected void setListenerAndAdapter() {\n\t\t\n\t}", "@Override\n\tpublic void anular() {\n\n\t}", "@Override\n public void perish() {\n \n }", "@Override\n\tpublic void debite() {\n\t\t\n\t}", "@Override\n public void apply() {\n }", "@Override\n\tpublic void grabar() {\n\t\t\n\t}", "@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}", "@Override\n protected void extend(ServerConnector target) {\n\n }", "@Override\n\tpublic void emprestimo() {\n\n\t}", "@Override\n\tpublic void apply() {\n\t\t\n\t}", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "@Override\n\tprotected void interr() {\n\t}", "public interface AdapterInterface {\n}", "@Override\n\tpublic void call() {\n\t\t\n\t}", "@Override\n\tpublic void entrenar() {\n\t\t\n\t}", "@Override\n\t\t\tprotected void configure() {\n\t\t\t}", "@Override\n public void feedingHerb() {\n\n }", "@Override\r\n\t\t\tpublic void buscar() {\n\r\n\t\t\t}", "private void initializeAdapter() {\n }", "FrameIntroGUI_botonRecibir_actionAdapter(FrameIntroGUI adaptee) {\n\t\tthis.adaptee = adaptee;\n\t}", "FrameIntroGUI_botonSalir_actionAdapter(FrameIntroGUI adaptee) {\n\t\tthis.adaptee = adaptee;\n\t}", "@Override\n\tpublic void conferenceroom() {\n\t\t\n\t}", "OutputSetup_this_windowAdapter(OutputSetup adaptee) {\n this.adaptee = adaptee;\n }", "FrameIntroGUI_botonDescargaSobre_actionAdapter(FrameIntroGUI adaptee) {\n\t\tthis.adaptee = adaptee;\n\t}", "@Override\n\tpublic void einkaufen() {\n\t}", "private static void createDepthFirstAdaptor(Environment result,\n\t\t\tEnvironment extEnv)\n\t{\n\n\t\t// Create a extended depth first analysis adapter and add it to extEnv\n\t\tJavaName jname = new JavaName(result.getAstPackage() + \".analysis\", \"DepthFirstAnalysis\"\n\t\t\t\t+ extEnv.getName() + \"Adaptor\");\n\t\tIClassDefinition extAdaptor = ClassFactory.createCustom(jname, result);\n\n\t\t// Find the base DepthFirstAnalysisAdaptor and set it as super to the\n\t\t// newly created one\n\t\tIClassDefinition baseAdaptor = result.lookUp(\"DepthFirstAnalysisAdaptor\");\n\t\textAdaptor.setSuper(baseAdaptor);\n\t\textAdaptor.setAbstract(true);\n\t\textAdaptor.setAnnotation(\"@SuppressWarnings({\\\"all\\\"})\");\n\n\t\t// Find the interface I<extensions name>Analysis interface and implement it\n\t\tIInterfaceDefinition extensionAnalysisInterface = result.lookUpInterface(\"I\"\n\t\t\t\t+ extEnv.getName() + \"Analysis\");\n\t\textAdaptor.addInterface(extensionAnalysisInterface);\n\n\t\t// Find the base visitedNode field\n\t\t// FIXME \"\".get(0) is not the best way of getting the field :)\n\t\tField queue = baseAdaptor.getFields().get(0);\n\n\t\t// The inherited field type also need to be imported because it is used\n\t\t// in the constructor\n\t\t((InterfaceDefinition) extAdaptor).imports.add(queue.type);\n\n\t\t/**\n\t\t * Go Through all the classes in the extension and add the corresponding methods in the extended analysis and\n\t\t * remove them in the base analysis\n\t\t */\n\t\tfor (IClassDefinition c : getExtClasses(result.getClasses(), extEnv.getName(), result))\n\t\t{\n\t\t\tswitch (result.classToType.get(c))\n\t\t\t{\n\n\t\t\t\tcase Custom:\n\t\t\t\t\tbreak;\n\t\t\t\tcase Production:\n\t\t\t\tcase SubProduction:\n\t\t\t\t{\n\t\t\t\t\tAnalysisAdaptorDefaultMethod mIn = new AnalysisAdaptorDefaultMethod(c);\n\t\t\t\t\tmIn.setDefaultPostfix(\"In\");\n\t\t\t\t\tmIn.setClassDefinition(c);\n\n\t\t\t\t\textAdaptor.addMethod(mIn);\n\t\t\t\t\tAnalysisAdaptorDefaultMethod mOut = new AnalysisAdaptorDefaultMethod(c);\n\t\t\t\t\tmOut.setDefaultPostfix(\"Out\");\n\t\t\t\t\tmOut.setClassDefinition(c);\n\n\t\t\t\t\textAdaptor.addMethod(mOut);\n\n\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase Alternative:\n\t\t\t\tcase Token:\n\t\t\t\t{\n\n\t\t\t\t\t// IClassDefinition superDef = c.getSuperDef();\n\n\t\t\t\t\tAnalysisDepthFirstAdaptorCaseMethod m = new AnalysisDepthFirstAdaptorCaseMethod();\n\t\t\t\t\tm.setVisitedNodesField(queue);\n\t\t\t\t\tm.setClassDefinition(c);\n\t\t\t\t\textAdaptor.addMethod(m);\n\n\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase Unknown:\n\t\t\t\t\tbreak;\n\n\t\t\t}\n\n\t\t\tAnalysisAdaptorCaseMethod mIn = new AnalysisAdaptorCaseMethod(c);\n\t\t\tmIn.setMethodNamePrefix(\"in\");\n\t\t\tmIn.setDefaultPostfix(\"In\");\n\t\t\tmIn.setClassDefinition(c);\n\t\t\t// mIn.setEnvironment(source);\n\t\t\textAdaptor.addMethod(mIn);\n\n\t\t\tAnalysisAdaptorCaseMethod mOut = new AnalysisAdaptorCaseMethod(c);\n\t\t\tmOut.setMethodNamePrefix(\"out\");\n\t\t\tmOut.setDefaultPostfix(\"Out\");\n\t\t\tmOut.setClassDefinition(c);\n\t\t\t// mOut.setEnvironment(source);\n\t\t\textAdaptor.addMethod(mOut);\n\n\t\t\t// Remove the case for the existing adaptor\n\t\t\tList<Method> toBeRemoved = new LinkedList<Method>();\n\t\t\tfor (Method method : baseAdaptor.getMethods())\n\t\t\t{\n\t\t\t\tif (method.classDefinition == c)\n\t\t\t\t{\n\t\t\t\t\ttoBeRemoved.add(method);\n\t\t\t\t}\n\t\t\t}\n\t\t\tbaseAdaptor.getMethods().removeAll(toBeRemoved);\n\n\t\t}\n\n\t}", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}", "public <T extends ListAdapter & Filterable> void setAdapter(T adapter) {\n/* 453 */ throw new RuntimeException(\"Stub!\");\n/* */ }", "@Override\n\tpublic void suggestExchange() {\n\t\t\n\t}", "FrameIntroGUI_botonEditar_actionAdapter(FrameIntroGUI adaptee) {\n\t\tthis.adaptee = adaptee;\n\t}", "protected abstract void bind();", "protected abstract void bind();", "FrameIntroGUI_botonEnviar_actionAdapter(FrameIntroGUI adaptee) {\n\t\tthis.adaptee = adaptee;\n\t}", "public Adapter adapt(Notifier notifier, Object type) {\r\n\t\treturn super.adapt(notifier, this);\r\n\t}", "@Override\r\n\tpublic void cast() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void cast() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void cast() {\n\t\t\r\n\t}", "Object adapt(final T src);", "@Override\r\n\tpublic void cast() {\n\r\n\t}", "@Override\n\tpublic void sacrifier() {\n\t\t\n\t}", "@Override\n\tpublic void driving() {\n\t\t\n\t}", "@Override\n\tprotected void getExras() {\n\n\t}", "@Override\npublic void add(ObjectAdapter compAdapter) {\n\t\n}", "@Override\n\tpublic void bind() {\n\t\t\n\t}", "@Override\n\tpublic void alterar() {\n\t\t\n\t}", "@Override\n\tpublic void e() {\n\n\t}", "public String toString() {\n\t\treturn adaptee.toString();\n\t}", "public interface ConnectableElement extends TypedElement { // <-- [user code injected with eMoflon]\r\n\r\n\t// [user code injected with eMoflon] -->\r\n}", "@Override\n\tpublic void buscar() {\n\t\t\n\t}", "@Override\n\tpublic void ligar() {\n\t\t\n\t}", "@Override\r\n\tprotected void attachListeners() {\n\t\t\r\n\t}", "@Override\n\tprotected void prepare() {\n\t\t\n\t}", "public Adapter createEObjectAdapter() {\r\n\t\treturn null;\r\n\t}", "public Adapter createEObjectAdapter() {\r\n\t\treturn null;\r\n\t}", "public Adapter createEObjectAdapter() {\r\n\t\treturn null;\r\n\t}", "public Adapter createEObjectAdapter() {\r\n\t\treturn null;\r\n\t}", "public Adapter createEObjectAdapter() {\r\n\t\treturn null;\r\n\t}", "public Adapter createEObjectAdapter() {\r\n\t\treturn null;\r\n\t}", "public Adapter createEObjectAdapter() {\r\n\t\treturn null;\r\n\t}", "@Override\r\n\tprotected void prepare()\r\n\t{\r\n\r\n\t}", "FrameIntroGUI_botonJuegoRed_actionAdapter(FrameIntroGUI adaptee) {\n\t\tthis.adaptee = adaptee;\n\t}", "@Override\n\tvoid receiveCall() {\n\n\t}", "@Override\n protected void configure() {\n }", "public Adapter createEObjectAdapter() {\n\t\treturn null;\n\t}", "public Adapter createEObjectAdapter() {\n\t\treturn null;\n\t}", "public Adapter createEObjectAdapter() {\n\t\treturn null;\n\t}", "public Adapter createEObjectAdapter() {\n\t\treturn null;\n\t}", "public Adapter createEObjectAdapter() {\n\t\treturn null;\n\t}", "public Adapter createEObjectAdapter() {\n\t\treturn null;\n\t}", "public Adapter createEObjectAdapter() {\n\t\treturn null;\n\t}", "public Adapter createEObjectAdapter() {\n\t\treturn null;\n\t}", "public Adapter createEObjectAdapter() {\n\t\treturn null;\n\t}" ]
[ "0.6578253", "0.6405299", "0.63575786", "0.62612927", "0.6244685", "0.61904377", "0.6144546", "0.6129686", "0.6020316", "0.6020316", "0.6020316", "0.6020316", "0.6020316", "0.6020316", "0.6020316", "0.6020316", "0.6020316", "0.6020316", "0.6020316", "0.6020316", "0.6020316", "0.6020316", "0.6020316", "0.60036755", "0.60036755", "0.60036755", "0.60036755", "0.5994541", "0.5944356", "0.5937035", "0.59043115", "0.5824275", "0.58105963", "0.5804426", "0.5797662", "0.57509905", "0.5739028", "0.5727463", "0.57170904", "0.5662077", "0.5659672", "0.56571853", "0.56543905", "0.5639139", "0.5638964", "0.56361383", "0.56276834", "0.55982274", "0.5587631", "0.5587076", "0.5574368", "0.55604136", "0.553564", "0.5530607", "0.5530607", "0.55260545", "0.5525412", "0.55220914", "0.5516277", "0.54854757", "0.54854757", "0.5485106", "0.5477025", "0.54721576", "0.54721576", "0.54721576", "0.54610723", "0.5458981", "0.545769", "0.5423967", "0.5421088", "0.54156584", "0.54137427", "0.5412291", "0.5408502", "0.5402599", "0.5389824", "0.5381255", "0.5377629", "0.53747183", "0.53741336", "0.5357501", "0.5357501", "0.5357501", "0.5357501", "0.5357501", "0.5357501", "0.5357501", "0.53551686", "0.53516155", "0.53445107", "0.5342758", "0.53410316", "0.53410316", "0.53410316", "0.53410316", "0.53410316", "0.53410316", "0.53410316", "0.53410316", "0.53410316" ]
0.0
-1
Creates new form LoginWindow
public LoginWindow(Modelo miModelo) { initComponents(); miControlador = new ControladorLoginWindow(this, miModelo); this.miModelo=miModelo; this.setLocationRelativeTo(null); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public LoginWindow()\n {\n super(\"Login\");\n\n myLoginPanel = new LoginPanel(this);\n this.setResizable(false);\n this.setContentPane(makePanel());\n this.pack();\n this.setVisible(true);\n }", "private void genLoginGui(){\n loginFrame = new JFrame(\"Log in\");\n\n // login panel, inputs name\n loginPanel = new JPanel();\n loginPanel.setLayout(new FlowLayout());\n nameLabel = new JLabel(\"Name\");\n nameTextFiled = new JTextField();\n nameTextFiled.setPreferredSize(new Dimension(100, 20));\n nameTextFiled.addActionListener(clientAction);\n nameTextFiled.setActionCommand(\"ENTERROOM\");\n\n btnEnterRoom = new JButton(\"Enter Room\");\n btnEnterRoom.addActionListener(clientAction);\n btnEnterRoom.setActionCommand(\"ENTERROOM\");\n\n loginPanel.add(nameLabel);\n loginPanel.add(nameTextFiled);\n loginPanel.add(btnEnterRoom);\n\n loginFrame.add(loginPanel, BorderLayout.CENTER);\n\n loginFrame.setSize(700, 500);\n loginFrame.setLocation(0, 200);\n loginFrame.add(loginPanel);\n loginFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n loginFrame.setVisible(true);\n }", "public Login() \n {\n super();\n create();\n this.setVisible(true);\n initComponents();\n }", "public void loginBuilder(){\n loginFrame = new JFrame(\"Coronos Login\");\n loginFrame.setLayout(new GridLayout(3, 1));\n\n jpUserName = new JPanel(new FlowLayout());\n jtfUserNameField = new JTextField(10);\n userNameLabel = new JLabel(\"Username:\");\n userNameLabel.setLabelFor(jtfUserNameField);\n jpUserName.add(userNameLabel);\n jpUserName.add(jtfUserNameField);\n loginFrame.add(jpUserName);\n \n jpPassWord = new JPanel(new FlowLayout());\n passWordField = new JPasswordField(10);\n passWordLabel = new JLabel(\"Password:\");\n passWordField.addActionListener(this);\n passWordField.setActionCommand(\"Login\");\n passWordLabel.setLabelFor(passWordField);\n jpPassWord.add(passWordLabel);\n jpPassWord.add(passWordField);\n loginFrame.add(jpPassWord);\n \n jpOptions = new JPanel(new FlowLayout());\n loginButton = new JButton(\"Login\");\n loginButton.addActionListener(this);\n showPassword = new JButton(\"Reveal Password\");\n showPassword.addActionListener(this);\n jpOptions.add(loginButton);\n jpOptions.add(showPassword);\n loginFrame.add(jpOptions);\n \n loginFrame.setLocationRelativeTo(null);\n loginFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n loginFrame.setVisible(true);\n loginFrame.pack();\n }", "private Widget createLoginPanel(final IViewContext<ICommonClientServiceAsync> viewContext)\n {\n DockPanel loginPanel = new DockPanel();\n // WORKAROUND The mechanism behind the autofill support does not work in testing\n if (!GWTUtils.isTesting())\n {\n final LoginPanelAutofill loginWidget = LoginPanelAutofill.get(viewContext);\n loginPanel.add(loginWidget, DockPanel.CENTER);\n } else\n {\n final LoginWidget loginWidget = new LoginWidget(viewContext);\n loginPanel.add(loginWidget, DockPanel.CENTER);\n }\n return loginPanel;\n }", "public LoginW() {\n this.setUndecorated(true);\n initComponents();\n origin = pnlBackG.getBackground();\n lblErrorLogin.setVisible(false);\n this.setLocationRelativeTo(null);\n Fondo();\n }", "public LoginUI() {\n\t\tparentFrame = Main.getMainFrame();\n\t\tparentFrame.setVisible(true);\n\n\t\tsetLayout(new BorderLayout(5, 5));\n\t\tadd(initFields(), BorderLayout.NORTH);\n\t\tadd(initButtons(), BorderLayout.CENTER);\n\t}", "public Login() {\n initComponents();\n this.setLocationRelativeTo(null);\n AWTUtilities.setWindowOpaque(this, false);\n }", "public Login() {\n initComponents();\n setDefaultCloseOperation(HIDE_ON_CLOSE);\n }", "public LoginFrame() {\n\t\tsetJFrame();\n\t\t\n\t\tbuildGUI();\n\t}", "private void createAdminPanel() {\n username = new JTextField(8);\n password = new JPasswordField(8);\n JPanel loginArea = adminLoginPanels();\n JPanel buttons = adminLoginButtons();\n loginFrame = new JFrame();\n loginFrame.setLayout(new BorderLayout());\n loginFrame.getRootPane().setBorder(BorderFactory.createEmptyBorder(10,10,10,10));\n loginLabel = new JLabel(\"Please log in as administrator\", SwingConstants.CENTER);\n loginFrame.getContentPane().add(loginLabel, BorderLayout.NORTH);\n loginFrame.getContentPane().add(loginArea, BorderLayout.CENTER);\n loginFrame.getContentPane().add(buttons, BorderLayout.SOUTH);\n loginFrame.setVisible(true);\n loginFrame.pack();\n }", "public Form getLoginForm() {\n if (LoginForm == null) {//GEN-END:|14-getter|0|14-preInit\n // write pre-init user code here\n LoginForm = new Form(\"Welcome\", new Item[]{getTextField()});//GEN-BEGIN:|14-getter|1|14-postInit\n LoginForm.addCommand(getExitCommand());\n LoginForm.addCommand(getOkCommand());\n LoginForm.setCommandListener(this);//GEN-END:|14-getter|1|14-postInit\n // write post-init user code here\n }//GEN-BEGIN:|14-getter|2|\n return LoginForm;\n }", "public LoginPanel() {\n initComponents();\n JFrame loginFrame=new JFrame(\"LOGIN\");\n loginFrame.add(this);\n loginFrame.pack();\n loginFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n loginFrame.setVisible(true);\n login.addActionListener(new ActionListener(){\n @Override\n public void actionPerformed(ActionEvent e) {\n \n try {\n \n int response=NetIO.Login.loginReq(UNAME.getText(), PASS.getText());\n if(response==0)\n {\n new DayPlanner();\n loginFrame.setVisible(false);\n }\n else if(response==-1)\n {\n error.setText(\"SERVER ERROR\");\n }\n else if(response==1)\n {\n error.setText(\"INVALID USERNAME OR PASSWORD\");\n }\n } catch (Exception ex) {\n Logger.getLogger(LoginPanel.class.getName()).log(Level.SEVERE, null, ex);\n }\n \n }\n });\n reg.addActionListener(new ActionListener(){\n @Override\n public void actionPerformed(ActionEvent e) {\n RegisterPanel.open();\n }\n });\n \n }", "void goToLogin() {\n mainFrame.setPanel(panelFactory.createPanel(PanelFactoryOptions.panelNames.LOGIN));\n }", "@AutoGenerated\r\n\tprivate Panel buildPnlLogin() {\n\t\tpnlLogin = new Panel();\r\n\t\tpnlLogin.setImmediate(false);\r\n\t\tpnlLogin.setWidth(\"-1px\");\r\n\t\tpnlLogin.setHeight(\"500px\");\r\n\t\t\r\n\t\t// layoutLogin\r\n\t\tlayoutLogin = buildLayoutLogin();\r\n\t\tpnlLogin.setContent(layoutLogin);\r\n\t\t\r\n\t\treturn pnlLogin;\r\n\t}", "public Login(){\n\t\tthis.setTitle(\"DSI | Sokoban\");\n\t\tvalido = false;\n\t\tthis.getContentPane().setLayout(new FlowLayout());\n\t\tcrearLabels();\n\t\tcrearBotones();\n\t\tthis.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n\t\tthis.setPreferredSize(new Dimension(250, 200));\n\t\tthis.pack();\n\t\tthis.setResizable(false);\n\t\tthis.setVisible(true);\n\t\tthis.setLocationRelativeTo(null);\n\t}", "public T01Login() {\n initComponents();\n btnMenu.setVisible(false);\n }", "@Override\r\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tSwingUtilities.invokeLater(new Runnable() {\r\n\t\t\t public void run() {\r\n\t\t\t try {\r\n\t\t\t NewLogin window = new NewLogin();\r\n\t\t\t window.setVisible(true);\r\n\t\t\t } catch (Exception e) {\r\n\t\t\t e.printStackTrace();\r\n\t\t\t }\r\n\t\t\t }\r\n\t\t\t });\r\n\t\t\t\t\r\n \t\r\n\t\t\t\t\r\n\t\t\t}", "public Login() {\n\t\tinitComponents();\n\t\tthis.setTitle(\"学生成绩管理系统-登录\");\n\t\tthis.setResizable(false);\n\t\tthis.setLocationRelativeTo(null);\n\t}", "public login() {\n initComponents();\n setLocationRelativeTo(null);\n this.setDefaultCloseOperation(login.DO_NOTHING_ON_CLOSE);\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n loginPanel = new javax.swing.JPanel();\n usernameLabel = new javax.swing.JLabel();\n usernameTextField = new javax.swing.JTextField();\n passwordLabel = new javax.swing.JLabel();\n passwordField = new javax.swing.JPasswordField();\n loginButton = new javax.swing.JButton();\n exitButton = new javax.swing.JButton();\n\n setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);\n org.jdesktop.application.ResourceMap resourceMap = org.jdesktop.application.Application.getInstance(ke.go.moh.oec.reception.gui.App.class).getContext().getResourceMap(LoginDialog.class);\n setTitle(resourceMap.getString(\"Form.title\")); // NOI18N\n setName(\"Form\"); // NOI18N\n setResizable(false);\n\n loginPanel.setBorder(javax.swing.BorderFactory.createEtchedBorder());\n loginPanel.setName(\"loginPanel\"); // NOI18N\n\n usernameLabel.setText(resourceMap.getString(\"usernameLabel.text\")); // NOI18N\n usernameLabel.setName(\"usernameLabel\"); // NOI18N\n\n usernameTextField.setText(resourceMap.getString(\"usernameTextField.text\")); // NOI18N\n usernameTextField.setName(\"usernameTextField\"); // NOI18N\n\n passwordLabel.setText(resourceMap.getString(\"passwordLabel.text\")); // NOI18N\n passwordLabel.setName(\"passwordLabel\"); // NOI18N\n\n passwordField.setText(resourceMap.getString(\"passwordField.text\")); // NOI18N\n passwordField.setName(\"passwordField\"); // NOI18N\n\n javax.swing.GroupLayout loginPanelLayout = new javax.swing.GroupLayout(loginPanel);\n loginPanel.setLayout(loginPanelLayout);\n loginPanelLayout.setHorizontalGroup(\n loginPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(loginPanelLayout.createSequentialGroup()\n .addContainerGap()\n .addGroup(loginPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(passwordLabel)\n .addComponent(usernameLabel))\n .addGap(18, 18, 18)\n .addGroup(loginPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(usernameTextField, javax.swing.GroupLayout.DEFAULT_SIZE, 264, Short.MAX_VALUE)\n .addComponent(passwordField, javax.swing.GroupLayout.DEFAULT_SIZE, 264, Short.MAX_VALUE))\n .addContainerGap())\n );\n loginPanelLayout.setVerticalGroup(\n loginPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(loginPanelLayout.createSequentialGroup()\n .addContainerGap()\n .addGroup(loginPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(usernameLabel)\n .addComponent(usernameTextField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addGroup(loginPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(passwordLabel)\n .addComponent(passwordField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n );\n\n javax.swing.ActionMap actionMap = org.jdesktop.application.Application.getInstance(ke.go.moh.oec.reception.gui.App.class).getContext().getActionMap(LoginDialog.class, this);\n loginButton.setAction(actionMap.get(\"login\")); // NOI18N\n loginButton.setText(resourceMap.getString(\"loginButton.text\")); // NOI18N\n loginButton.setName(\"loginButton\"); // NOI18N\n\n exitButton.setAction(actionMap.get(\"quit\")); // NOI18N\n exitButton.setText(resourceMap.getString(\"exitButton.text\")); // NOI18N\n exitButton.setName(\"exitButton\"); // NOI18N\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());\n getContentPane().setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(loginPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()\n .addComponent(loginButton)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(exitButton)))\n .addContainerGap())\n );\n\n layout.linkSize(javax.swing.SwingConstants.HORIZONTAL, new java.awt.Component[] {exitButton, loginButton});\n\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addContainerGap()\n .addComponent(loginPanel, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(exitButton)\n .addComponent(loginButton))\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n );\n\n pack();\n }", "public LoginGUI() {\n \n initComponents();\n }", "public void createLoginPopUp(JButton loginButton) {\n\t\tJPanel loginPanel = new JPanel();\n\n\t\tHintTextField usernameEntry = new HintTextField(\"Username\");\n\t\tusernameEntry.setPreferredSize(new Dimension(150, 25));\n\n\t\tHintPasswordField passwordEntry = new HintPasswordField(\"Password\");\n\t\tpasswordEntry.setPreferredSize(new Dimension(150, 25));\n\n\t\tBox vBox = Box.createVerticalBox(); // Align components in one column\n\t\tvBox.add(usernameEntry);\n\t\tvBox.add(passwordEntry);\n\n\t\tloginPanel.add(vBox);\n\t\tObject options[] = { \"Login\", \"Cancel\" };\n\n\t\tint selection = JOptionPane.showOptionDialog(null, loginPanel, \"BTS Login\", JOptionPane.OK_CANCEL_OPTION,\n\t\t\t\tJOptionPane.PLAIN_MESSAGE, null, options, options[0]);\n\n\t\tif (selection == JOptionPane.OK_OPTION) {\n\t\t\tString username = usernameEntry.getText();\n\t\t\tString password = String.valueOf(passwordEntry.getPassword());\n\t\t\t// Call Login method in uicontroller and take action based on result\n\t\t\tEmployee logged_in_result = uiController_.login(username + \":\" + password);\n\t\t\tif (logged_in_result == null) {\n\t\t\t\t// Show login failed message\n\t\t\t\tJOptionPane.showMessageDialog(uiController_.getFrame(), \"Unrecognized Login Credentials\",\n\t\t\t\t\t\t\"Invalid Login\", JOptionPane.WARNING_MESSAGE);\n\t\t\t} else if (logged_in_result instanceof Manager) {\n\t\t\t\t// Get components\n\t\t\t\t((DefaultComboBoxModel<String>) pageSelector.getModel()).addElement(\"Assignment\");\n\t\t\t\tJPanel viewHolder = (JPanel) (uiController_.getFrame().getContentPane().getComponent(0));\n\t\t\t\tCardLayout layout = (CardLayout) viewHolder.getLayout();\n\t\t\t\tloginButton.setVisible(false);\n\n\t\t\t\t// Create new ManagerPanel if it doesn't exist\n\t\t\t\tif (!uiController_.checkPanelExists(\"ManagerPanel\", viewHolder)) {\n\t\t\t\t\tviewHolder.add(new ManagerPanel(uiController_).getPanel_(), \"ManagerPanel\");\n\t\t\t\t}\n\n\t\t\t\t// Change view to manager panel\n\t\t\t\tlayout.show(viewHolder, \"ManagerPanel\");\n\t\t\t} else if (logged_in_result instanceof Developer) {\n\t\t\t\t((DefaultComboBoxModel<String>) pageSelector.getModel()).addElement(\"Assignment\");\n\t\t\t\tpageSelector.addActionListener(new ActionListener() {\n\n\t\t\t\t\t@Override\n\t\t\t\t\tpublic void actionPerformed(ActionEvent arg0) {\n\t\t\t\t\t\tif (pageSelector.getSelectedItem().equals(\"Assignment\")) {\n\t\t\t\t\t\t\t// Switch to Ordinary panel\n\t\t\t\t\t\t\tJPanel viewHolder = (JPanel) (uiController_.getFrame().getContentPane().getComponent(0));\n\t\t\t\t\t\t\tCardLayout layout = (CardLayout) viewHolder.getLayout();\n\t\t\t\t\t\t\tlayout.show(viewHolder, \"DeveloperPanel\");\n\t\t\t\t\t\t}\n\n\t\t\t\t\t}\n\n\t\t\t\t});\n\t\t\t\t// Get components\n\t\t\t\tJPanel viewHolder = (JPanel) (uiController_.getFrame().getContentPane().getComponent(0));\n\t\t\t\tCardLayout layout = (CardLayout) viewHolder.getLayout();\n\t\t\t\tloginButton.setVisible(false);\n\t\t\t\t// Create new DeveloperPanel if it doesn't exist\n\t\t\t\tif (!uiController_.checkPanelExists(\"DeveloperPanel\", viewHolder)) {\n\t\t\t\t\tviewHolder.add(new DeveloperPanel(uiController_).getPanel_(), \"DeveloperPanel\");\n\t\t\t\t}\n\n\t\t\t\t// Change view to developer panel\n\t\t\t\tlayout.show(viewHolder, \"DeveloperPanel\");\n\t\t\t}\n\t\t}\n\t}", "public loginForm() {\n initComponents();\n \n }", "private JButton getLoginButton() {\n\t\tif (LoginButton == null) {\n\t\t\tLoginButton = new JButton();\n\t\t\tLoginButton.setBounds(new Rectangle(140, 230, 80, 25));\n\t\t\tLoginButton.setText(\"Login\");\n\t\t\tLoginButton.addActionListener(new ActionListener () {\n\t\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\tif(NameTextField.getText().compareTo(\"admin\")==0)\n\t\t\t\t\t{\n//\t\t\t\t\t\tSystem.out.println(\"clicked\");\n\t\t\t\t\t\tif(String.valueOf(PasswordField.getPassword()).equals(\"mds\"))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\n\t\t\t\t\t\t\tMainFrame m = new MainFrame();\n//\t\t\t\t\t\t\tm.setBounds(0,0,900,600);\n\t\t\t\t\t\t\tm.setVisible(true);\n\t\t\t\t\t\t\tcloseWindow();\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t\tshowMessageDialog(\"Invalid Username or Password\");\n\t\t\t\t\t}\n\t\t\t\t\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\t\treturn LoginButton;\n\t}", "public LoginFrame() {\n try {\n for (javax.swing.UIManager.LookAndFeelInfo info : javax.swing.UIManager.getInstalledLookAndFeels()) {\n if (\"Windows\".equals(info.getName())) {\n javax.swing.UIManager.setLookAndFeel(info.getClassName());\n break;\n }\n }\n } catch (ClassNotFoundException ex) {\n java.util.logging.Logger.getLogger(LoginFrame.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);\n } catch (InstantiationException ex) {\n java.util.logging.Logger.getLogger(LoginFrame.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);\n } catch (IllegalAccessException ex) {\n java.util.logging.Logger.getLogger(LoginFrame.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);\n } catch (javax.swing.UnsupportedLookAndFeelException ex) {\n java.util.logging.Logger.getLogger(LoginFrame.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);\n }\n this.getContentPane().setBackground(new Color(91, 173, 236));\n initComponents();\n setDefaultFocus();\n \n }", "public LoginGUI1(String judul, int posX, int posY, int width,\n\t\t\tint height, JFrame parent) {\n\t\tsetBounds(100, 100, 450, 300);\n\t\tgetContentPane().setLayout(null);\n\t\t\n\t\tJLabel label = new JLabel(\"\");\n\t\tlabel.setBounds(41, 60, 46, 14);\n\t\tgetContentPane().add(label);\n\t\t\n\t\tJLabel lblNewLabel = new JLabel(\"ID :\");\n\t\tlblNewLabel.setBounds(51, 125, 46, 14);\n\t\tgetContentPane().add(lblNewLabel);\n\t\t\n\t\tJLabel lblNewLabel_1 = new JLabel(\"Password :\");\n\t\tlblNewLabel_1.setBounds(51, 164, 60, 14);\n\t\tgetContentPane().add(lblNewLabel_1);\n\t\t\n\t\ttxtUser = new JTextField();\n\t\ttxtUser.setBounds(168, 122, 86, 20);\n\t\tgetContentPane().add(txtUser);\n\t\ttxtUser.setColumns(10);\n\t\t\n\t\tJButton btnLogin = new JButton(\"Login\");\n\t\tbtnLogin.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tString usr=txtUser.getText();\n\t\t\t\t//String pass=Users.generateMD5(txtPass.getText());\n\t\t\t\t//String pDef=Users.generateMD5(\"lh091011\");\n\t\t\t\tString pass=(txtPass.getText());\n\t\t\t\tString pDef=(\"lh091011\");\n\t\t\t\t\n\t\t\t\tint jml=ut.viewAll().size();\n\t\t\t\tUsers lg=ut.cariById(txtUser.getText());\n\t\t\t\tif(jml==0 && usr.equals(\"adm\") && pass.equals(pDef)){\n\t\t\t\t\t((MainGUI)getParent()).setLogin(\"adm\",\"A\");\n\t\t\t\t\tdispose();\n\t\t\t\t}else if(usr.equals(lg.getId()) && pass.equals(lg.getPass())){\n\t\t\t\t\t((MainGUI)getParent()).setLogin(lg.getId(),lg.getJenis());\n\t\t\t\t\tdispose();\n\t\t\t\t}else{\n\t\t\t\t\tJOptionPane.showMessageDialog(null, \"Username dan Password salah\", \"Toko Obat\", JOptionPane.ERROR_MESSAGE);\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\tbtnLogin.setBounds(55, 207, 89, 23);\n\t\tgetContentPane().add(btnLogin);\n\t\t\n\t\tJButton btnExit = new JButton(\"Exit\");\n\t\tbtnExit.setBounds(165, 207, 89, 23);\n\t\tgetContentPane().add(btnExit);\n\t\t\n\t\ttxtPass = new JPasswordField();\n\t\ttxtPass.setBounds(168, 161, 86, 20);\n\t\tgetContentPane().add(txtPass);\n\t\t\n\t\tJLabel lblSilahkanLoginDisini = new JLabel(\"Silahkan Login Disini\");\n\t\tlblSilahkanLoginDisini.setFont(new Font(\"Sylfaen\", Font.PLAIN, 13));\n\t\tlblSilahkanLoginDisini.setBounds(103, 85, 126, 14);\n\t\tgetContentPane().add(lblSilahkanLoginDisini);\n\t\t\n\t\tJLabel lblNewLabel_2 = new JLabel(\"Aplikasi Penjualan Toko Obat Herbal\");\n\t\tlblNewLabel_2.setFont(new Font(\"Traditional Arabic\", Font.PLAIN, 15));\n\t\tlblNewLabel_2.setBounds(41, 60, 237, 14);\n\t\tgetContentPane().add(lblNewLabel_2);\n\n\t}", "public LoginPage() {\n initComponents();\n Point center = GraphicsEnvironment.getLocalGraphicsEnvironment().getCenterPoint();\n int windowWidth = this.getWidth();\n int windowHeight = this.getHeight();\n this.setBounds(center.x - windowWidth / 2, center.y - windowHeight / 2, windowWidth,\n windowHeight);\n this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n this.setVisible(true);\n }", "public pageLogin() {\n initComponents();\n labelimage.setBorder(new EmptyBorder(0,0,0,0));\n enterButton.setBorder(null);\n enterButton.setContentAreaFilled(false);\n enterButton.setVisible(true);\n usernameTextField.setText(\"Username\");\n usernameTextField.setForeground(new Color(153,153,153));\n passwordTextField.setText(\"Password\");\n passwordTextField.setForeground(new Color(153,153,153));\n usernameAlert.setText(\" \");\n passwordAlert.setText(\" \");\n \n }", "public Login() {\r\n\t\ttry {\r\n\t\t\tUIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());\r\n\t\t} catch (Exception e) {\r\n\t\t\t// TODO Auto-generated catch block\r\n\t\t\te.printStackTrace();\r\n\t\t} \r\n\t\tsetTitle(\"Login\");\r\n\t\tsetResizable(false);\r\n\t\tsetDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\r\n\t\tsetSize(300,380);\r\n\t\tsetLocationRelativeTo(null);\r\n\t\tcontentPane = new JPanel();\r\n\t\tcontentPane.setBorder(new EmptyBorder(5, 5, 5, 5));\r\n\t\tsetContentPane(contentPane);\r\n\t\tcontentPane.setLayout(null);\r\n\t\t\r\n\t\ttxtName = new JTextField();\r\n\t\ttxtName.setBounds(48, 66, 197, 20);\r\n\t\tcontentPane.add(txtName);\r\n\t\ttxtName.setColumns(10);\r\n\t\t\r\n\t\tJLabel lblNewLabel = new JLabel(\"Name\");\r\n\t\tlblNewLabel.setFont(new Font(\"Times New Roman\", Font.BOLD, 11));\r\n\t\tlblNewLabel.setBounds(124, 41, 46, 14);\r\n\t\tcontentPane.add(lblNewLabel);\r\n\t\t\r\n\t\ttxtIp = new JTextField();\r\n\t\ttxtIp.setBounds(48, 174, 197, 20);\r\n\t\tcontentPane.add(txtIp);\r\n\t\ttxtIp.setColumns(10);\r\n\t\t\r\n\t\tJLabel lblIpAddress = new JLabel(\"IP Address\");\r\n\t\tlblIpAddress.setFont(new Font(\"Times New Roman\", Font.BOLD, 11));\r\n\t\tlblIpAddress.setBounds(102, 134, 74, 14);\r\n\t\tcontentPane.add(lblIpAddress);\r\n\t\t\r\n\t\tJButton btnLogin = new JButton(\"Login\");\r\n\t\tbtnLogin.addActionListener(new ActionListener() {\r\n\t\t\tpublic void actionPerformed(ActionEvent e) {\r\n\t\t\t\t\r\n\t\t\t\t name = txtName.getText();\r\n\t\t\t\t ip=txtIp.getText();\r\n\t\t\t\t \r\n\t\t\t\t\r\n\t\t\t\tlogin();\r\n\t\t\t\t\r\n\t\t\t}\r\n\t\t});\r\n\t\tbtnLogin.setBounds(102, 248, 89, 23);\r\n\t\tcontentPane.add(btnLogin);\r\n\t}", "public Login() {\n \n initComponents();\n \n this.setLocationRelativeTo(null);\n connect = new DataConnect();\n LoginError.setVisible(false);\n this.setResizable(false);\n Username.setDocument(new JtextLimit(8));\n \n }", "public Main() {\n initComponents();\n LogIn.setVisible(true);\n LogIn.setVisible(true);\n LogIn.setLocationRelativeTo(null);\n }", "private void initialize() {\r\n\t\tframe = new JFrame();\r\n\t\tframe.setBounds(410, 210, 450, 300);\r\n\t\tframe.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\r\n\t\tframe.getContentPane().setLayout(null);\r\n\t\t\r\n\t\t\r\n\t\ttextField = new JTextField();\r\n\t\ttextField.setBounds(262, 83, 86, 20);\r\n\t\tframe.getContentPane().add(textField);\r\n\t\ttextField.setColumns(10);\r\n\t\t\r\n\t\tJLabel lbl1 = new JLabel(\"UserName\");\r\n\t\tlbl1.setBounds(103, 86, 60, 14);\r\n\t\tframe.getContentPane().add(lbl1);\r\n\t\tJLabel err = new JLabel(\"\");\r\n\t\terr.setBounds(71, 23, 277, 14);\r\n\t\tframe.getContentPane().add(err);\r\n\t\t\r\n\t\tJLabel lNewLabel_1 = new JLabel(\"Password\");\r\n\t\tlNewLabel_1.setBounds(103, 139, 92, 14);\r\n\t\tframe.getContentPane().add(lNewLabel_1);\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\tJButton btnNewButton = new JButton(\"Login\");\r\n\t\tbtnNewButton.addActionListener(new ActionListener() {\r\n\t\t\tpublic void actionPerformed(ActionEvent e) {\r\n\t\t\t\t\r\n\t\t\t\ttry {\r\n\t\t\t\t\tString uname = textField.getText();\r\n\t\t\t\t\tString password = new String(passwordField.getPassword());\r\n\t\t\t\t\tint num = ConnectDB.Login(uname,password);\r\n\t\t\t\t\r\n\t\t\t\tif(num==0)\r\n\t\t\t\t{\r\n\t\t\t\t\tDialogMessage.showInfoDialog(\"Employee Login\");\r\n\t\t\t\t\tMenu m = new Menu();\r\n\t\t\t\t\tm.Newscreen();\r\n\t\t\t\t\tframe.setVisible(false);\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\telse if(num==2)\r\n\t\t\t\t{\r\n\t\t\t\t\tDialogMessage.showInfoDialog(\"Employee Login\");\r\n\t\t\t\t\tMenu m = new Menu();\r\n\t\t\t\t\tm.Newscreen();\r\n\t\t\t\t\tframe.setVisible(false);\r\n\t\t\t\t}\r\n\t\t\t\telse\r\n\t\t\t\t{\r\n\t\t\t\t\tDialogMessage.showWarningDialog(\"ERROR\");\r\n\t\t\t\t}\r\n\t\t\t\t} catch (SQLException e2) {\r\n\t\t\t\t\t// TODO Auto-generated catch block\r\n\t\t\t\t\te2.printStackTrace();\r\n\t\t\t\t} catch (NoSuchAlgorithmException e1) {\r\n\t\t\t\t\t// TODO Auto-generated catch block\r\n\t\t\t\t\te1.printStackTrace();\r\n\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t});\r\n\t\tbtnNewButton.setBounds(106, 196, 89, 23);\r\n\t\tframe.getContentPane().add(btnNewButton);\r\n\t\t\r\n\t\tJButton btnNewButton_1 = new JButton(\"Exit\");\r\n\t\tbtnNewButton_1.addActionListener(new ActionListener() {\r\n\t\t\tpublic void actionPerformed(ActionEvent e) {\r\n\t\t\t\tSystem.exit(0);\r\n\t\t\t}\r\n\t\t});\r\n\t\tbtnNewButton_1.setBounds(262, 196, 89, 23);\r\n\t\tframe.getContentPane().add(btnNewButton_1);\r\n\t\t\r\n\t\tpasswordField = new JPasswordField();\r\n\t\tpasswordField.setBounds(262, 136, 86, 20);\r\n\t\tframe.getContentPane().add(passwordField);\r\n\t\t\r\n\t\r\n\t}", "private Component createLogin() {\n CustomLayout custom = new CustomLayout(\"../../sampler/layouts/examplecustomlayout\");\n\n // Create components and bind them to the location tags\n // in the custom layout.\n username = new TextField();\n custom.addComponent(username, \"username\");\n\n password = new PasswordField();\n custom.addComponent(password, \"password\");\n\n Button ok = new Button(\"Login\");\n custom.addComponent(ok, \"okbutton\");\n\n // Add login listener\n ok.addListener(this);\n\n return custom;\n\n }", "public login() {\n initComponents();\n }", "public Login()\r\n\t{\r\n\t\t//Initialize the GUI\r\n\t\tthis.initializeGUI();\r\n\r\n\t\t//Setup the JFrame\r\n\t\tthis.setTitle(Application.NAME);\r\n\t\tthis.setSize(600, 400);\r\n\t\tthis.setResizable(false);\r\n\t\tthis.setLocationRelativeTo(null);\r\n\t\tthis.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\r\n\t\tthis.setIconImage(Application.LOGO.getImage());\r\n\r\n\t\tthis.setVisible(true);\r\n\t}", "public Login() {\n initComponents();\n this.setTitle(\"Login\");\n setLocationRelativeTo(null);\n }", "public MainView() {\r\n LoginOverlay login = new LoginOverlay();\r\n login.setOpened(true);\r\n LoginI18n i18n = LoginI18n.createDefault();\r\n i18n.setHeader(new LoginI18n.Header());\r\n i18n.getHeader().setTitle(\"Webvision\");\r\n i18n.getHeader().setDescription(\"Please login, if you don't have an account you will be redirected to finish registration.\");\r\n i18n.getForm().setUsername(\"Email\");\r\n i18n.getForm().setPassword(\"Password\");\r\n login.setI18n(i18n);\r\n login.addLoginListener(event -> {\r\n String email = event.getUsername();\r\n User user = userService.findByEmail(email);\r\n if (user == null) {\r\n login.close();\r\n UI.getCurrent().navigate(RegistrationView.ROUTE);\r\n } else {\r\n String password = event.getPassword();\r\n boolean isAuthenticated = password.equals(user.getPassword());\r\n if (isAuthenticated) {\r\n CurrentUser.setCurrentUser(user);\r\n login.close();\r\n UI.getCurrent().navigate(HomeView.ROUTE);\r\n }\r\n login.setError(true);\r\n }\r\n });\r\n add(login);\r\n }", "private Dialog<Pair<String, String>> getLoginDialog() {\n Dialog<Pair<String, String>> dialog = new Dialog<>();\n dialog.setTitle(\"Login\");\n dialog.setHeaderText(\"Look, a Custom Login Dialog\");\n\n ButtonType loginButtonType = new ButtonType(\"Login\", ButtonBar.ButtonData.OK_DONE);\n dialog.getDialogPane().getButtonTypes().addAll(loginButtonType, ButtonType.CANCEL);\n\n // Create the username and password labels and fields.\n GridPane grid = new GridPane();\n grid.setHgap(10);\n grid.setVgap(10);\n grid.setPadding(new Insets(20, 150, 10, 10));\n\n TextField username = new TextField();\n username.setPromptText(\"Username\");\n PasswordField password = new PasswordField();\n password.setPromptText(\"Password\");\n\n grid.add(new Label(\"Username:\"), 0, 0);\n grid.add(username, 1, 0);\n grid.add(new Label(\"Password:\"), 0, 1);\n grid.add(password, 1, 1);\n\n // Enable/Disable login button depending on whether a username was entered.\n Node loginButton = dialog.getDialogPane().lookupButton(loginButtonType);\n loginButton.setDisable(true);\n\n // Do some validation (using the Java 8 lambda syntax).\n username.textProperty().addListener((observable, oldValue, newValue) -> {\n loginButton.setDisable(newValue.trim().isEmpty());\n });\n\n dialog.getDialogPane().setContent(grid);\n\n // Request focus on the username field by default.\n Platform.runLater(username::requestFocus);\n\n // Convert the result to a username-password-pair when the login button is clicked.\n dialog.setResultConverter(dialogButton -> {\n if (dialogButton == loginButtonType) {\n return new Pair<>(username.getText(), password.getText());\n }\n return null;\n });\n return dialog;\n }", "public LogInForm() {\n initComponents();\n this.setLocationRelativeTo(null);\n }", "public Login() {\n initComponents();\n setIconImage(new ImageIcon(getClass().getResource(\"/login/imagenes/logo_150px.png\")).getImage()); //cambiar icono\n LOGO.requestFocusInWindow(); //hacer que no se focusee el textfield usuario ni bien abrir el programa\n this.setLocationRelativeTo(null);\n }", "private void initialize() {\r\n\t\tframe = new JFrame();\r\n\t\tframe.setBounds(100, 100, 450, 300);\r\n\t\tframe.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\r\n\t\tframe.getContentPane().setLayout(null);\r\n\t\t\r\n\t\tJLabel lblLogin = new JLabel(\"Login:\");\r\n\t\tlblLogin.setBounds(89, 80, 61, 14);\r\n\t\tframe.getContentPane().add(lblLogin);\r\n\t\t\r\n\t\tJLabel lblSenha = new JLabel(\"Senha:\");\r\n\t\tlblSenha.setBounds(89, 123, 48, 14);\r\n\t\tframe.getContentPane().add(lblSenha);\r\n\t\t\r\n\t\tlogin = new JTextField();\r\n\t\tlogin.setBounds(232, 77, 96, 20);\r\n\t\tframe.getContentPane().add(login);\r\n\t\tlogin.setColumns(10);\r\n\t\t\r\n\t\tsenha = new JTextField();\r\n\t\tsenha.setBounds(232, 120, 96, 20);\r\n\t\tframe.getContentPane().add(senha);\r\n\t\tsenha.setColumns(10);\r\n\t\t\r\n\t\tJButton btnNewButton = new JButton(\"Entrar\");\r\n\t\tbtnNewButton.addActionListener(new ActionListener() {\r\n\t\t\tpublic void actionPerformed(ActionEvent e) {\r\n\t\t\t\tString l=login.getText();\r\n\t\t\t\tString s=senha.getText();\r\n\t\t\t\tif(l.equals(\"admin\") && s.equals(\"admin\"))\r\n\t\t\t\t{\r\n\t\t\t\t\tJOptionPane.showMessageDialog(frame, \"Acesso liberado\");\r\n\t\t\t\t Menu menu = new Menu();\r\n\t\t\t\t menu.setVisible(true);\r\n\t\t\t\t}\r\n\t\t\t\telse\r\n\t\t\t\t\tJOptionPane.showMessageDialog(frame, \"Acesso negado\");\r\n\t\t\t}\r\n\t\t});\r\n\t\tbtnNewButton.setBounds(171, 192, 89, 23);\r\n\t\tframe.getContentPane().add(btnNewButton);\r\n\t\t\r\n\t\tJLabel lblLogin_1 = new JLabel(\"Login\");\r\n\t\tlblLogin_1.setFont(new Font(\"Tahoma\", Font.BOLD, 15));\r\n\t\tlblLogin_1.setBounds(192, 30, 48, 23);\r\n\t\tframe.getContentPane().add(lblLogin_1);\r\n\t}", "public Login() {\n initComponents();\n \n }", "public Login() {\n initComponents();\n }", "public Login() {\n initComponents();\n }", "public Login() {\n initComponents();\n }", "public Login() {\n initComponents();\n }", "public Login() {\n initComponents();\n }", "public Login() {\n initComponents();\n }", "public Login() {\n initComponents();\n }", "public Login() {\n initComponents();\n }", "public Login() {\n initComponents();\n }", "public Login() {\n initComponents();\n }", "public Login() {\n initComponents();\n }", "public Login() {\n initComponents();\n }", "public Login() {\n initComponents();\n }", "public Login() {\n initComponents();\n }", "public Login() {\n initComponents();\n }", "public Login() {\n initComponents();\n }", "public AuthenticationWindow create(String userName, char[] password, String server, boolean isUserNameEditable,\n boolean isRememberPassword, Object icon, String windowTitle, String windowText, String usernameLabel,\n String passwordLabel, String errorMessage, String signupLink)\n {\n long requestId = System.currentTimeMillis();\n AuthWindowImpl authWindow = new AuthWindowImpl(requestId, userName, password, server, isUserNameEditable,\n isRememberPassword, windowTitle, windowText, usernameLabel, passwordLabel);\n\n requestMap.put(requestId, authWindow);\n return authWindow;\n }", "public Login() {\n initComponents();\n this.setLocationRelativeTo(null);\n \n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n jButton1 = new javax.swing.JButton();\n jMenuBar1 = new javax.swing.JMenuBar();\n jMenu1 = new javax.swing.JMenu();\n jMenu2 = new javax.swing.JMenu();\n Password = new javax.swing.JPasswordField();\n Username = new javax.swing.JTextField();\n jLabel1 = new javax.swing.JLabel();\n jLabel2 = new javax.swing.JLabel();\n Login = new javax.swing.JButton();\n CreateAccount = new javax.swing.JButton();\n exit = new javax.swing.JButton();\n LoginError = new javax.swing.JLabel();\n filler1 = new javax.swing.Box.Filler(new java.awt.Dimension(0, 0), new java.awt.Dimension(0, 0), new java.awt.Dimension(32767, 32767));\n\n jButton1.setText(\"jButton1\");\n\n jMenu1.setText(\"File\");\n jMenuBar1.add(jMenu1);\n\n jMenu2.setText(\"Edit\");\n jMenuBar1.add(jMenu2);\n\n setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);\n setTitle(\"Inventory Login\");\n setBackground(new java.awt.Color(0, 0, 0));\n setBounds(new java.awt.Rectangle(240, 240, 240, 240));\n setForeground(java.awt.Color.white);\n setName(\"TEST\"); // NOI18N\n setUndecorated(true);\n setOpacity(0.95F);\n setType(java.awt.Window.Type.POPUP);\n\n Password.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n PasswordActionPerformed(evt);\n }\n });\n\n Username.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n UsernameActionPerformed(evt);\n }\n });\n\n jLabel1.setText(\"Password:\");\n\n jLabel2.setText(\"Username:\");\n\n Login.setText(\"Login\");\n Login.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n LoginActionPerformed(evt);\n }\n });\n\n CreateAccount.setText(\"Create Account\");\n CreateAccount.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n CreateAccountActionPerformed(evt);\n }\n });\n\n exit.setText(\"Exit\");\n exit.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n exitActionPerformed(evt);\n }\n });\n\n LoginError.setFont(new java.awt.Font(\"Tahoma\", 2, 14)); // NOI18N\n LoginError.setForeground(new java.awt.Color(255, 0, 0));\n LoginError.setLabelFor(LoginError);\n LoginError.setText(\"Not a valid login\");\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());\n getContentPane().setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addGap(83, 83, 83)\n .addComponent(Login, javax.swing.GroupLayout.PREFERRED_SIZE, 93, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(18, 18, 18)\n .addComponent(CreateAccount)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addComponent(exit, javax.swing.GroupLayout.PREFERRED_SIZE, 113, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(0, 66, Short.MAX_VALUE))\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jLabel2, javax.swing.GroupLayout.PREFERRED_SIZE, 80, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jLabel1))\n .addGap(29, 29, 29)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(LoginError, javax.swing.GroupLayout.PREFERRED_SIZE, 134, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)\n .addComponent(Password, javax.swing.GroupLayout.DEFAULT_SIZE, 158, Short.MAX_VALUE)\n .addComponent(Username)))\n .addGap(127, 127, 127))\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()\n .addComponent(filler1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(224, 224, 224))))\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addGap(49, 49, 49)\n .addComponent(filler1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(38, 38, 38)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(Username, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jLabel2, javax.swing.GroupLayout.PREFERRED_SIZE, 22, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGap(26, 26, 26)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(Password, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jLabel1))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(LoginError)\n .addGap(15, 15, 15)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(Login)\n .addComponent(CreateAccount)\n .addComponent(exit))\n .addContainerGap(34, Short.MAX_VALUE))\n );\n\n jLabel2.getAccessibleContext().setAccessibleName(\"userName\");\n\n pack();\n }", "public login() {\n initComponents();\n \n \n }", "public LoginFrame() {\n initComponents();\n this.setLocationRelativeTo(null);\n LoginPanel.setVisible(true);\n SSNPanel.setVisible(false);\n\n }", "public LoginSARH() {\n\t\tsetDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n\t\tsetBounds(100, 100, 450, 300);\n\t\tcontentPane = new JPanel();\n\t\tcontentPane.setBackground(Color.DARK_GRAY);\n\t\tcontentPane.setBorder(new EmptyBorder(5, 5, 5, 5));\n\t\tsetContentPane(contentPane);\n\t\tcontentPane.setLayout(null);\n\t\t\n\t\tJLabel lblUsuario = new JLabel(\"USUARIO\");\n\t\tlblUsuario.setBounds(51, 105, 46, 14);\n\t\tcontentPane.add(lblUsuario);\n\t\t\n\t\tJLabel lblContrasea = new JLabel(\"CONTRASE\\u00D1A\");\n\t\tlblContrasea.setBounds(51, 152, 101, 14);\n\t\tcontentPane.add(lblContrasea);\n\t\t\n\t\ttxtUsuario = new JTextField();\n\t\ttxtUsuario.setBounds(169, 102, 143, 20);\n\t\tcontentPane.add(txtUsuario);\n\t\ttxtUsuario.setColumns(10);\n\t\t\n\t\ttxtPassword = new JPasswordField();\n\t\ttxtPassword.setBounds(169, 149, 143, 20);\n\t\tcontentPane.add(txtPassword);\n\t\t\n\t\tbtnIngresar = new JButton(\"INGRESAR\");\n\t\tbtnIngresar.addActionListener(this);\n\t\tbtnIngresar.setBounds(335, 122, 89, 23);\n\t\tcontentPane.add(btnIngresar);\n\t\t\n\t\tJLabel lblLogin = new JLabel(\"LOGIN\");\n\t\tlblLogin.setBounds(106, 38, 46, 14);\n\t\tcontentPane.add(lblLogin);\n\t}", "public Login() {\n initComponents();\n setLocationRelativeTo(null);\n }", "public Login() {\n initComponents();\n setLocationRelativeTo(null);\n }", "private void initialize() {\n\t\tfrmLogin = new JFrame();\n\t\tfrmLogin.setTitle(\"Login\");\n\t\tfrmLogin.setBounds(100, 100, 727, 493);\n\t\tfrmLogin.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n\t\tfrmLogin.getContentPane().setLayout(null);\n\n\t\tJLabel lblNombreDeUsuario = new JLabel(\"Nombre de Usuario\");\n\t\tlblNombreDeUsuario.setFont(new Font(\"Tahoma\", Font.PLAIN, 18));\n\t\tlblNombreDeUsuario.setBounds(26, 52, 160, 20);\n\t\tfrmLogin.getContentPane().add(lblNombreDeUsuario);\n\n\t\ttextField = new JTextField();\n\t\ttextField.setBounds(246, 50, 255, 26);\n\t\tfrmLogin.getContentPane().add(textField);\n\t\ttextField.setColumns(10);\n\n\t\tJLabel lblContrasea = new JLabel(\"Contrase\\u00F1a\");\n\t\tlblContrasea.setFont(new Font(\"Tahoma\", Font.PLAIN, 18));\n\t\tlblContrasea.setBounds(26, 115, 160, 20);\n\t\tfrmLogin.getContentPane().add(lblContrasea);\n\n\t\tpasswordField = new JPasswordField();\n\t\tpasswordField.setBounds(246, 113, 255, 26);\n\t\tfrmLogin.getContentPane().add(passwordField);\n\n\t\tJRadioButton rdbtnEntrarComoRegistrado = new JRadioButton(\"Entrar como registrado\");\n\t\tbuttonGroup.add(rdbtnEntrarComoRegistrado);\n\n\t\trdbtnEntrarComoRegistrado.setFont(new Font(\"Tahoma\", Font.PLAIN, 18));\n\t\trdbtnEntrarComoRegistrado.setBounds(100, 187, 255, 29);\n\t\tfrmLogin.getContentPane().add(rdbtnEntrarComoRegistrado);\n\n\t\tJRadioButton rdbtnEntrarComoInvitado = new JRadioButton(\"Entrar como invitado\");\n\t\tbuttonGroup.add(rdbtnEntrarComoInvitado);\n\n\t\trdbtnEntrarComoInvitado.setFont(new Font(\"Tahoma\", Font.PLAIN, 18));\n\t\trdbtnEntrarComoInvitado.setBounds(100, 253, 255, 29);\n\t\tfrmLogin.getContentPane().add(rdbtnEntrarComoInvitado);\n\n\t\tJCheckBox chckbxAceptaCondicionesPara = new JCheckBox(\"Acepta condiciones para entrar\");\n\n\t\tchckbxAceptaCondicionesPara.setFont(new Font(\"Tahoma\", Font.PLAIN, 18));\n\t\tchckbxAceptaCondicionesPara.setBounds(26, 311, 448, 29);\n\t\tfrmLogin.getContentPane().add(chckbxAceptaCondicionesPara);\n\n\t\tJButton btnEntrar = new JButton(\"Entrar\");\n\t\tbtnEntrar.setEnabled(false);\n\t\tbtnEntrar.setBounds(209, 392, 115, 29);\n\t\tfrmLogin.getContentPane().add(btnEntrar);\n\n\t\tJButton btnSalir = new JButton(\"Salir\");\n\n\t\tbtnSalir.setBounds(497, 392, 115, 29);\n\t\tfrmLogin.getContentPane().add(btnSalir);\n\t\tbtnSalir.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tint r = JOptionPane.showConfirmDialog(null, \"desea salir\", \"salir\", JOptionPane.YES_NO_OPTION);\n\t\t\t\tif (r == 0)\n\t\t\t\t\tSystem.exit(0);\n\n\t\t\t}\n\t\t});\n\t\trdbtnEntrarComoRegistrado.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tif (rdbtnEntrarComoRegistrado.isSelected())\n\t\t\t\t\tbtnEntrar.setEnabled(true);\n\t\t\t\telse {\n\t\t\t\t\tbtnEntrar.setEnabled(false);\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\trdbtnEntrarComoInvitado.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tif (rdbtnEntrarComoInvitado.isSelected())\n\t\t\t\t\tJOptionPane.showMessageDialog(null, \"acepta las condiciones\", \"acepta\",\n\t\t\t\t\t\t\tJOptionPane.INFORMATION_MESSAGE);\n\t\t\t}\n\t\t});\n\t\tchckbxAceptaCondicionesPara.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tif (chckbxAceptaCondicionesPara.isSelected())\n\t\t\t\t\tbtnEntrar.setEnabled(true);\n\t\t\t\telse {\n\t\t\t\t\tbtnEntrar.setEnabled(false);\n\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\tbtnEntrar.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tif (rdbtnEntrarComoRegistrado.isSelected()) {\n\t\t\t\t\tif (!textField.getText().equals(passwordField.getText()) || textField.getText().equals(\"\")) {\n\t\t\t\t\t\tJOptionPane.showMessageDialog(null, \"Login incorrecto\", \"login mal \",\n\t\t\t\t\t\t\t\tJOptionPane.ERROR_MESSAGE);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tJOptionPane.showMessageDialog(null, \"Login correcto\", \"login ok \",\n\t\t\t\t\t\t\t\tJOptionPane.INFORMATION_MESSAGE);\n\t\t\t\t\t\tproducto.getFrmCompra().setVisible(true);\n\t\t\t\t\t\tfrmLogin.setVisible(false);\n\t\t\t\t\t\tproducto.getTextField().setText(textField.getText());\n\t\t\t\t\t}\n\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif(rdbtnEntrarComoInvitado.isSelected()) {\n\t\t\t\t\tif(chckbxAceptaCondicionesPara.isSelected()) {\n\t\t\t\t\t\tJOptionPane.showMessageDialog(null, \"todo ok\", \"ok\",\n\t\t\t\t\t\t\t\tJOptionPane.INFORMATION_MESSAGE);\t\n\t\t\t\t\t\tproducto.getFrmCompra().setVisible(true);\n\t\t\t\t\t\tfrmLogin.setVisible(false);\n\t\t\t\t\t}else {\n\t\t\t\t\t\tJOptionPane.showMessageDialog(null, \"acepta condicones\", \"mal \",\n\t\t\t\t\t\t\t\tJOptionPane.ERROR_MESSAGE);\n\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\n\t}", "public LoginPanel(Controller theController) {\n\t\tsuper();\n\t\tmyController = theController;\n\t\tusername = new JTextField();\n\t\tpassword = new JPasswordField();\n\t\tsubmit = new JButton(\"Login\");\n\t\tcreate();\n\t}", "public Login() {\n initComponents();\n this.setLocationRelativeTo(null);\n }", "public Login() {\n initComponents();\n this.setLocationRelativeTo(null);\n }", "public LogIn() {\n initComponents();\n }", "private void initialize() {\n\t\tfrmLogin = new JFrame();\n\t\tfrmLogin.setTitle(\"Login\");\n\t\tfrmLogin.setResizable(false);\n\t\tfrmLogin.setBounds(100, 100, 502, 197);\n\t\tfrmLogin.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n\t\tfrmLogin.getContentPane().setLayout(null);\n\t\t\n\t\ttxtUsr = new JTextField();\n\t\ttxtUsr.setBounds(215, 18, 262, 27);\n\t\tfrmLogin.getContentPane().add(txtUsr);\n\t\ttxtUsr.setColumns(10);\n\t\t\n\t\tJButton btnLogin = new JButton(\"\");\n\t\tImage img_ = new ImageIcon(this.getClass().getResource(\"/ok.png\")).getImage();\n\t\tbtnLogin.setIcon(new ImageIcon(img_));\n\t\tbtnLogin.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent arg0) {\n\t\t\t\ttry{\n\t\t\t\t\tString query = \"select * from usuario where usuarioLogin=? and usuarioSenha=? \";\n\t\t\t\t\tPreparedStatement pst= conn.prepareStatement(query);\n\t\t\t\t\tpst.setString(1, txtUsr.getText());\n\t\t\t\t\tpst.setString(2, txtPasswd.getText());\n\t\t\t\t\t\n\t\t\t\t\tResultSet rs = pst.executeQuery();\n\t\t\t\t\tint count = 0;\n\t\t\t\t\twhile(rs.next())\n\t\t\t\t\t{\n\t\t\t\t\t\tcount++;\n\t\t\t\t\t}\n\t\t\t\t\tif(count == 1)\n\t\t\t\t\t{\n\t\t\t\t\t\t//JOptionPane.showMessageDialog(null, \"User Name or Passwd is correct\");\n\t\t\t\t\t\tfrmLogin.dispose();\n\t\t\t\t\t\tEmployeeinfo emplinfo = new Employeeinfo();\n\t\t\t\t\t\templinfo.setVisible(true);\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\telse if(count >1)\n\t\t\t\t\t{\n\t\t\t\t\t\tJOptionPane.showMessageDialog(null, \"Duplicated User and Passwd\");\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tJOptionPane.showMessageDialog(null, \"User Name or Passwd is not correct, Try Again!\");\n\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\trs.close();\n\t\t\t\t\tpst.close();\n\t\t\t\t}\n\t\t\t\tcatch(Exception e)\n\t\t\t\t{\n\t\t\t\t\tJOptionPane.showMessageDialog(null, e);\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t});\n\t\tbtnLogin.setBounds(159, 118, 24, 23);\n\t\tfrmLogin.getContentPane().add(btnLogin);\n\t\t\n\t\tJLabel lblUsurio = new JLabel(\"Usu\\u00E1rio\");\n\t\tlblUsurio.setBounds(159, 24, 46, 14);\n\t\tfrmLogin.getContentPane().add(lblUsurio);\n\t\t\n\t\tJLabel lblSenha = new JLabel(\"Senha\");\n\t\tlblSenha.setBounds(159, 55, 46, 14);\n\t\tfrmLogin.getContentPane().add(lblSenha);\n\t\t\n\t\ttxtPasswd = new JPasswordField();\n\t\ttxtPasswd.setEchoChar('*');\n\t\ttxtPasswd.setBounds(215, 49, 262, 27);\n\t\tfrmLogin.getContentPane().add(txtPasswd);\n\t\t\n\t\tlblNewLabel = new JLabel(\"\");\n\t\tImage img = new ImageIcon(this.getClass().getResource(\"/Login.png\")).getImage();\n\t\tlblNewLabel.setIcon(new ImageIcon(img));\n\t\tlblNewLabel.setBounds(21, 17, 128, 124);\n\t\tfrmLogin.getContentPane().add(lblNewLabel);\n\t}", "public LoginForm() {\n initComponents();\n }", "public Login() {\n initComponents();\n \n }", "public Login() {\n initComponents();\n setLocationRelativeTo(this);\n }", "public void premutoLogin()\n\t{\n\t\tnew _FINITO_funzione_loginGUI();\n\t}", "public Login() {\n\n initComponents();\n jTextFieldUsuario.requestFocus();\n \n// setLocationRelativeTo(null);\n }", "public Login() {\n initComponents();\n txtAccountStatus.setVisible(false); \n showDate(); // Class para sa Date\n showTime(); // Class para sa Time\n }", "public Login(HlavniJFrame hl) {\n this.hlavni = hl;\n initComponents();\n }", "UserLoginPanel() {\n\t\tJPanel myPanel = new MyPanel();\n\t\tJPanel feedbackPanel = new FeedbackPanel();\n\n\t\tthis.setLayout(new GridLayout(3, 1));\n\t\tthis.add(feedbackPanel);\n\t\tthis.add(myPanel);\n\t\tthis.add(new JPanel());\n\n\t\tthis.setVisible(true);\n\t}", "private LoginMenu() {\n\n\t\t\n\t\t/**\n\t\t * Fenêtre positionnée comme tableau de ligne/colonne avec un espace en hauteur\n\t\t * et largeur\n\t\t **/\n\n\t\tmenuLogin = new JPanel(new GridLayout(2, 1, 0, 0));\n\t\tmenuLogin.setBackground(new Color(200, 100, 100));\n\n\t\t/**\n\t\t * Ajout du login et mot de passe via un tableau\n\t\t **/\n\n\t\tmenuLogin.add(InitialisationDuMenu());\n\t\tmenuLogin.add(InitDesBouttons());\n\t}", "public login() {\n initComponents();\n setTitle(\"COLLAGE MANAGEMENT SYSTEM\");\n }", "public LoginFrame() {\n\t\tloginFrame = new JFrame(\"회원가입\");\n\t\tloginFrame.setBounds(500, 490, 440, 290);\n\t\tloginFrame.setLayout(null);\n\n\t\tidLabel = new JLabel(\"ID : \");\n\t\tidLabel.setBounds(80, 50, 50, 30);\n\t\tloginFrame.add(idLabel);\n\n\t\tuserId = new TextField(10);\n\t\tuserId.setBounds(150, 50, 200, 30);\n\t\tloginFrame.add(userId);\n\n\t\tpasswdLabel = new JLabel(\"PW : \");\n\t\tpasswdLabel.setBounds(80, 80, 50, 30);\n\t\tloginFrame.add(passwdLabel);\n\n\t\tuserPw = new TextField(10);\n\t\tuserPw.setBounds(150, 80, 200, 30);\n\t\tuserPw.setEchoChar('*');\n\t\tloginFrame.add(userPw);\n\n\t\tloginBt = new JButton(\"로그인\");\n\t\tloginBt.setBounds(70, 120, 80, 50); // 버튼 위치 설정\n\t\tloginFrame.add(loginBt);\n\n\t\tfindIdBt = new JButton(\"아이디 / 비밀번호찾기\");\n\t\tfindIdBt.setBounds(170, 120, 180, 50); // 버튼 위치 설정\n\t\tloginFrame.add(findIdBt);\n\n\t\tjoinBt = new JButton(\"회원가입\");\n\t\tjoinBt.setBounds(70, 180, 280, 30);\n\t\tloginFrame.add(joinBt);\n\n//\t\tmap.put(\"aaa\", \"11\");\n//\t\tmap.put(\"bbb\", \"22\");\n//\t\tmap.put(\"ccc\", \"33\");\n//\t\tmap.put(\"ddd\", \"44\");\n//\t\tmap.put(\"eee\", \"55\");\n\t\t\n\t\t\n\t\tinsertTestUsers();\n\n\t\tloginFrame.setVisible(true);\n\n\t\tloginBt.addActionListener(new ActionListener() {\n\t\t\t@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\n\t\t\t\tString id = userId.getText();\n\t\t\t\tString pw = userPw.getText();\n\t\t\t\tuserPw.setText(\"\");\n\n\t\t\t\tDialog dialog = new Dialog(loginFrame, \"불일치!\", true);\n\n\t\t\t\ttry {\n\t\t\t\t\tConnection conn = getConnection();\n\t\t\t\t\tPreparedStatement ps = conn.prepareStatement(\"SELECT * FROM User WHERE userId = ?\");\n\t\t\t\t\tps.setString(1, id);\n\t\t\t\t\tResultSet rs = ps.executeQuery();\n\t\t\t\t\tif (!rs.next()) {\n//\t\t\t\t\tif (!map.containsKey(id)) {\n\t\t\t\t\t\tdialog.setBounds(100, 100, 200, 150);\n\t\t\t\t\t\tdialog.add(new Label(\"아이디가 존재하지 않습니다.\"));\n\t\t\t\t\t\t\n\t\t\t\t\t\tdialog.addWindowListener(new WindowListener());\n\t\t\t\t\t\tdialog.setVisible(true);\n\t\t\t\t\t\t\n\t\t\t\t\t\tuserId.setText(\"\");\n\t\t\t\t\t\tuserId.requestFocus();\n\t\t\t\t\t} else if (!rs.getString(\"password\").equals(pw)) {\n//\t\t\t\t\t} else if (!map.get(id).equals(pw)) {\n\t\t\t\t\t\tdialog.setBounds(100, 100, 200, 150);\n\t\t\t\t\t\tdialog.add(new Label(\"암호가 일치하지 않습니다.\"));\n\t\t\t\t\t\t\n\t\t\t\t\t\tdialog.addWindowListener(new WindowListener());\n\t\t\t\t\t\tdialog.setVisible(true);\n\t\t\t\t\t\tuserPw.requestFocus();\n\t\t\t\t\t\t\n\t\t\t\t\t} else {\n\t\t\t\t\t\t// setVisible(false);\n\t\t\t\t\t\tloginFrame.dispose();\n\t\t\t\t\t\tnew Client();\n\t\t\t\t\t}\n\t\t\t\t\tps.close();\n\t\t\t\t\tconn.close();\n\t\t\t\t} catch (Exception exeption) {\n\t\t\t\t\texeption.printStackTrace();\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\tjoinBt.addActionListener(new Register());\n\n\t}", "public loginGUI() {\r\n\r\n\t\tsuper.frame.setTitle(\"Login\");\r\n\t\ttry {\r\n\t\t\tJLabel label = new JLabel(new ImageIcon(ImageIO.read(new File(\"..\\\\images\\\\login-background.png\"))));\r\n\t\t\tframe.setContentPane(label);\r\n\t\t} catch (IOException e) {\r\n\t\t\tSystem.out.println(\"Image doesn't exist...\");\r\n\t\t}\r\n\r\n\t\tcopyright();\r\n\t\tlabels();\r\n\t\ttextField();\r\n\t\tstartButton();\r\n\t\tsignup();\r\n\r\n\t\tsuper.frame.setVisible(true);\r\n\t}", "public void OpenLoginScreen(ActionEvent event) throws IOException {\n Parent tripViewParent = FXMLLoader.load(getClass().getResource(\"login.fxml\")); // Carregando o arquivo fxml\n\n Stage window = new Stage();\n window.setResizable(false);\n window.setScene(new Scene(tripViewParent));\n window.show();\n\n ((Stage)(((Button)event.getSource()).getScene().getWindow())).close();\n }", "@SuppressWarnings(\"serial\")\n\tpublic AdminLogin()\n {\n \tLoginLabel = new JLabel(\"Logedin As: \");\n \tLoginName = new JLabel(\"\");\n \t\n \tLoginLabel.setForeground(Color.red);\n \tUName = new JLabel(\"Staff ID:\t\");\n \tPword = new JLabel(\"Password:\t\");\n \t\n \tresetPassword = new JButton();\n \t\n \tresetPassword.setText(\"<HTML>Forgot Password? <FONT color=\\\"#000099\\\"><U>Reset Password</U></FONT></HTML>\");\n \tresetPassword.setHorizontalAlignment(SwingConstants.LEFT);\n \tresetPassword.setBorderPainted(false);\n \tresetPassword.setFont(new Font(\"Dialog\", Font.PLAIN, 10));\n \n \t\n \tUserName = new JTextField(\"\", 20);\n \tPassword = new JPasswordField(\"\", 20);\n \tLogIn = new JButton(\"Login\");\n \tLogout = new JButton(\"Logout\");\n \tLogout.setEnabled(false);\n \tgbc = new GridBagConstraints();\n \t\n \tdb = new DatabaseHelper();\n \t\n \n \t\n \t\n \t//Make the panel wider than it really needs, so\n //the window's wide enough for the tabs to stay\n //in one row.\n \tcard = new JPanel() {\n\t public Dimension getPreferredSize() {\n\t Dimension size = super.getPreferredSize();\n\t size.width += extraWindowWidth;\n\t return size;\n\t }\n\t }; \n\t \n\t resetPasswordCliclListner();\n }", "public LoginFrame() {\n initComponents();\n this.setIconImage(new ImageIcon(getClass().getResource(\"/image/Home/Logo Company.png\")).getImage());\n //\n UIManager UI = new UIManager();\n UI.put(\"OptionPane.background\", Color.white);\n UI.put(\"Panel.background\", Color.white);\n //\n setBackground(new Color(0, 0, 0, 0));\n setLocationRelativeTo(null);\n userNameTextField.requestFocus();\n setTitle(\"Click Login\");\n }", "public Login() {\n initComponents();\n hideregister ();\n }", "public FormLogin() {\n initComponents();\n open_db();\n setLocationRelativeTo(this);\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n Background = new keeptoo.KGradientPanel();\n topPanel = new keeptoo.KGradientPanel();\n LoginText = new javax.swing.JLabel();\n Username = new javax.swing.JLabel();\n Password = new javax.swing.JLabel();\n UserLogin = new javax.swing.JTextField();\n PassLogin = new javax.swing.JPasswordField();\n cancelButton = new javax.swing.JButton();\n loginButton = new javax.swing.JButton();\n\n setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);\n\n Background.setkEndColor(new java.awt.Color(135, 211, 124));\n Background.setkStartColor(new java.awt.Color(27, 188, 155));\n\n topPanel.setkEndColor(new java.awt.Color(44, 62, 80));\n topPanel.setkGradientFocus(50);\n topPanel.setkStartColor(new java.awt.Color(34, 49, 63));\n\n LoginText.setFont(new java.awt.Font(\"Arial\", 0, 18)); // NOI18N\n LoginText.setForeground(new java.awt.Color(236, 236, 236));\n LoginText.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);\n LoginText.setText(\"Login as Student\");\n\n javax.swing.GroupLayout topPanelLayout = new javax.swing.GroupLayout(topPanel);\n topPanel.setLayout(topPanelLayout);\n topPanelLayout.setHorizontalGroup(\n topPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 0, Short.MAX_VALUE)\n .addGroup(topPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(topPanelLayout.createSequentialGroup()\n .addContainerGap()\n .addComponent(LoginText, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addContainerGap()))\n );\n topPanelLayout.setVerticalGroup(\n topPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 58, Short.MAX_VALUE)\n .addGroup(topPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(topPanelLayout.createSequentialGroup()\n .addContainerGap()\n .addComponent(LoginText, javax.swing.GroupLayout.DEFAULT_SIZE, 36, Short.MAX_VALUE)\n .addContainerGap()))\n );\n\n Username.setFont(new java.awt.Font(\"Arial\", 1, 18)); // NOI18N\n Username.setForeground(new java.awt.Color(238, 238, 238));\n Username.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);\n Username.setIcon(new javax.swing.ImageIcon(\"D:\\\\Facultate\\\\Java\\\\Librarie\\\\Icons\\\\icons8-name-filled-30.png\")); // NOI18N\n Username.setText(\"Username:\");\n\n Password.setFont(new java.awt.Font(\"Arial\", 1, 18)); // NOI18N\n Password.setForeground(new java.awt.Color(238, 238, 238));\n Password.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);\n Password.setIcon(new javax.swing.ImageIcon(\"D:\\\\Facultate\\\\Java\\\\Librarie\\\\Icons\\\\icons8-lock-30.png\")); // NOI18N\n Password.setText(\"Password:\");\n\n UserLogin.setBackground(new java.awt.Color(218, 223, 225));\n UserLogin.setFont(new java.awt.Font(\"Arial\", 0, 18)); // NOI18N\n UserLogin.setHorizontalAlignment(javax.swing.JTextField.CENTER);\n\n PassLogin.setBackground(new java.awt.Color(218, 223, 225));\n PassLogin.setFont(new java.awt.Font(\"Arial\", 0, 18)); // NOI18N\n PassLogin.setHorizontalAlignment(javax.swing.JTextField.CENTER);\n\n cancelButton.setBackground(new java.awt.Color(210, 215, 211));\n cancelButton.setFont(new java.awt.Font(\"Arial\", 1, 18)); // NOI18N\n cancelButton.setText(\"Cancel\");\n cancelButton.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n cancelButtonActionPerformed(evt);\n }\n });\n\n loginButton.setBackground(new java.awt.Color(210, 215, 211));\n loginButton.setFont(new java.awt.Font(\"Arial\", 1, 18)); // NOI18N\n loginButton.setText(\"Login\");\n loginButton.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n loginButtonActionPerformed(evt);\n }\n });\n\n javax.swing.GroupLayout BackgroundLayout = new javax.swing.GroupLayout(Background);\n Background.setLayout(BackgroundLayout);\n BackgroundLayout.setHorizontalGroup(\n BackgroundLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(topPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, BackgroundLayout.createSequentialGroup()\n .addContainerGap(93, Short.MAX_VALUE)\n .addGroup(BackgroundLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)\n .addGroup(BackgroundLayout.createSequentialGroup()\n .addComponent(cancelButton, javax.swing.GroupLayout.PREFERRED_SIZE, 120, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addComponent(loginButton, javax.swing.GroupLayout.PREFERRED_SIZE, 120, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGroup(BackgroundLayout.createSequentialGroup()\n .addGroup(BackgroundLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)\n .addComponent(Username, javax.swing.GroupLayout.PREFERRED_SIZE, 153, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(Password, javax.swing.GroupLayout.PREFERRED_SIZE, 153, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGap(18, 18, 18)\n .addGroup(BackgroundLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(UserLogin, javax.swing.GroupLayout.PREFERRED_SIZE, 249, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(PassLogin, javax.swing.GroupLayout.PREFERRED_SIZE, 249, javax.swing.GroupLayout.PREFERRED_SIZE))))\n .addGap(87, 87, 87))\n );\n BackgroundLayout.setVerticalGroup(\n BackgroundLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(BackgroundLayout.createSequentialGroup()\n .addComponent(topPanel, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(98, 98, 98)\n .addGroup(BackgroundLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(UserLogin, javax.swing.GroupLayout.PREFERRED_SIZE, 28, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(Username, javax.swing.GroupLayout.PREFERRED_SIZE, 40, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGap(18, 18, 18)\n .addGroup(BackgroundLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(PassLogin, javax.swing.GroupLayout.PREFERRED_SIZE, 28, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(Password, javax.swing.GroupLayout.PREFERRED_SIZE, 40, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGap(18, 18, 18)\n .addGroup(BackgroundLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(loginButton, javax.swing.GroupLayout.PREFERRED_SIZE, 40, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(cancelButton, javax.swing.GroupLayout.PREFERRED_SIZE, 40, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addContainerGap(94, Short.MAX_VALUE))\n );\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());\n getContentPane().setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(Background, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(Background, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n );\n\n pack();\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n jLabel1 = new javax.swing.JLabel();\n jLabel2 = new javax.swing.JLabel();\n txtuser = new javax.swing.JTextField();\n txtpass = new javax.swing.JPasswordField();\n btllogin = new javax.swing.JButton();\n btexit = new javax.swing.JButton();\n jLabel4 = new javax.swing.JLabel();\n jDesktopPane1 = new javax.swing.JDesktopPane();\n jLabel3 = new javax.swing.JLabel();\n\n setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);\n setTitle(\"Login - Camte Laundry Kiloan\");\n setIconImages(null);\n\n jLabel1.setFont(new java.awt.Font(\"Calibri\", 1, 14)); // NOI18N\n jLabel1.setText(\"User ID\");\n\n jLabel2.setFont(new java.awt.Font(\"Calibri\", 1, 14)); // NOI18N\n jLabel2.setText(\"Password\");\n\n txtuser.setMargin(new java.awt.Insets(4, 4, 4, 4));\n txtuser.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n txtuserActionPerformed(evt);\n }\n });\n txtuser.addKeyListener(new java.awt.event.KeyAdapter() {\n public void keyReleased(java.awt.event.KeyEvent evt) {\n txtuserKeyReleased(evt);\n }\n });\n\n txtpass.setMargin(new java.awt.Insets(4, 4, 4, 4));\n txtpass.addKeyListener(new java.awt.event.KeyAdapter() {\n public void keyReleased(java.awt.event.KeyEvent evt) {\n txtpassKeyReleased(evt);\n }\n });\n\n btllogin.setFont(new java.awt.Font(\"DFGothic-EB\", 0, 14)); // NOI18N\n btllogin.setText(\"LOGIN\");\n btllogin.setMargin(new java.awt.Insets(4, 16, 4, 16));\n btllogin.setMaximumSize(new java.awt.Dimension(67, 23));\n btllogin.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btlloginActionPerformed(evt);\n }\n });\n\n btexit.setFont(new java.awt.Font(\"DFGothic-EB\", 0, 14)); // NOI18N\n btexit.setText(\"EXIT\");\n btexit.setMargin(new java.awt.Insets(4, 16, 4, 16));\n btexit.setName(\"\"); // NOI18N\n btexit.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n btexitActionPerformed(evt);\n }\n });\n\n jLabel4.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/laundryproject/images/laundrydesignicon.jpg\"))); // NOI18N\n jLabel4.setMaximumSize(new java.awt.Dimension(512, 512));\n jLabel4.setMinimumSize(new java.awt.Dimension(512, 512));\n\n jDesktopPane1.setBackground(new java.awt.Color(51, 51, 51));\n\n jLabel3.setBackground(new java.awt.Color(153, 255, 255));\n jLabel3.setFont(new java.awt.Font(\"Bell Gothic Std Black\", 0, 18)); // NOI18N\n jLabel3.setForeground(new java.awt.Color(255, 255, 255));\n jLabel3.setText(\"LOGIN ADMIN\");\n\n jDesktopPane1.setLayer(jLabel3, javax.swing.JLayeredPane.DEFAULT_LAYER);\n\n javax.swing.GroupLayout jDesktopPane1Layout = new javax.swing.GroupLayout(jDesktopPane1);\n jDesktopPane1.setLayout(jDesktopPane1Layout);\n jDesktopPane1Layout.setHorizontalGroup(\n jDesktopPane1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jDesktopPane1Layout.createSequentialGroup()\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(jLabel3)\n .addGap(162, 162, 162))\n );\n jDesktopPane1Layout.setVerticalGroup(\n jDesktopPane1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jDesktopPane1Layout.createSequentialGroup()\n .addContainerGap(21, Short.MAX_VALUE)\n .addComponent(jLabel3)\n .addGap(21, 21, 21))\n );\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());\n getContentPane().setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jDesktopPane1, javax.swing.GroupLayout.Alignment.TRAILING)\n .addGroup(layout.createSequentialGroup()\n .addGap(38, 38, 38)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)\n .addGroup(layout.createSequentialGroup()\n .addComponent(jLabel4, javax.swing.GroupLayout.PREFERRED_SIZE, 70, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(18, 18, 18)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jLabel1)\n .addComponent(jLabel2)))\n .addComponent(btllogin, javax.swing.GroupLayout.PREFERRED_SIZE, 125, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addGap(44, 44, 44)\n .addComponent(btexit, javax.swing.GroupLayout.PREFERRED_SIZE, 125, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGroup(layout.createSequentialGroup()\n .addGap(19, 19, 19)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(txtpass, javax.swing.GroupLayout.PREFERRED_SIZE, 163, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(txtuser, javax.swing.GroupLayout.PREFERRED_SIZE, 163, javax.swing.GroupLayout.PREFERRED_SIZE))))\n .addContainerGap(69, Short.MAX_VALUE))\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addComponent(jDesktopPane1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(18, 18, 18)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)\n .addGroup(layout.createSequentialGroup()\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel1)\n .addComponent(txtuser, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGap(27, 27, 27)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(txtpass, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(jLabel2)))\n .addComponent(jLabel4, javax.swing.GroupLayout.PREFERRED_SIZE, 84, javax.swing.GroupLayout.PREFERRED_SIZE))\n .addGap(27, 27, 27)\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(btllogin, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(btexit))\n .addContainerGap(25, Short.MAX_VALUE))\n );\n\n pack();\n setLocationRelativeTo(null);\n }", "public void loginScreen() {\n\t\t\n\t\t//Initialize windows\n\t\tDimension loginSize = new Dimension(loginWidth, loginHeight);\n\t\tloginWindow = new JFrame(\"Login\");\n\t\tloginWindow.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n\t\tloginWindow.setSize(loginSize);\n\t\tloginWindow.setBackground(new Color(51, 153, 255));\n\t\tloginWindow.setLayout(new BorderLayout());\n\t\tloginWindow.setResizable(false);\n\t\tloginWindow.setLocationRelativeTo(null);\n\t\t\n\t\t//Set Background\n\t\tJLabel background = new JLabel(new ImageIcon(\"Resource/loginBackground.jpg\"));\n\t\tbackground.setBounds(0, 0, loginWidth, loginHeight);\n\t\tloginWindow.add(background);\n\t\t\n\t\t//LoginIcon JLabel\n\t\tJLabel loginIcon = new JLabel(new ImageIcon(\"Resource/EOS-icon.png\"));\n\t\tloginIcon.setBounds(255, 30, 90, 90);\n\t\tbackground.add(loginIcon);\n\t\t\n\t\t//Username JLabel\n\t\tJLabel usernameL = new JLabel(\"Username\");\n\t\tusernameL.setForeground(Color.LIGHT_GRAY);\n\t\tusernameL.setBackground(Color.WHITE);\n\t\tusernameL.setFont(masterFont);\n\t\tusernameL.setOpaque(true);\n\t\tusernameL.setEnabled(false);\n\t\tusernameL.setBounds(215, 145, 200, 35);\n\t\tbackground.add(usernameL);\n\t\t\n\t\t//UserIcon JLabel\n\t\tImageIcon userIcon = new ImageIcon(\"Resource/username.png\");\n\t\tImage userImage = userIcon.getImage().getScaledInstance(35, 35, Image.SCALE_SMOOTH);\n\t\tJLabel userIconL = new JLabel(new ImageIcon(userImage));\n\t\tuserIconL.setBounds(180, 145, 35, 35);\n\t\tuserIconL.setOpaque(true);\n\t\tbackground.add(userIconL);\n\t\t\n\t\t//Username JTextField\n\t\tusernameTF = new JTextField();\n\t\tusernameTF.setBounds(215, 145, 200, 35);\n\t\tusernameTF.setOpaque(false);\n\t\tusernameTF.addMouseListener(this);\n\t\tbackground.add(usernameTF);\n\t\t\n\t\t//Password JLabel\n\t\tJLabel passwordL = new JLabel(\"Password\");\n\t\tpasswordL.setForeground(Color.LIGHT_GRAY);\n\t\tpasswordL.setBackground(Color.WHITE);\n\t\tpasswordL.setFont(masterFont);\n\t\tpasswordL.setOpaque(true);\n\t\tpasswordL.setEnabled(false);\n\t\tpasswordL.setBounds(215, 210, 200, 35);\n\t\tbackground.add(passwordL);\n\t\t\n\t\t//PasswordIcon JLabel\n\t\tImageIcon passwordIcon = new ImageIcon(\"Resource/password.png\");\n\t\tImage passwordImage = passwordIcon.getImage().getScaledInstance(35, 35, Image.SCALE_SMOOTH);\n\t\tJLabel passwordIconL = new JLabel(new ImageIcon(passwordImage));\n\t\tpasswordIconL.setBounds(180, 210, 35, 35);\n\t\tpasswordIconL.setOpaque(true);\n\t\tbackground.add(passwordIconL);\n\n\t\t//Password JPasswordField\n\t\tpasswordPF = new JPasswordField();\n\t\tpasswordPF.setBounds(215, 210, 200, 35);\n\t\tpasswordPF.setForeground(Color.BLACK);\n\t\tpasswordPF.setOpaque(false);\n\t\tpasswordPF.addMouseListener(this);\n\t\tbackground.add(passwordPF);\n\t\t\n\t\t//Login JButton\n\t\tJButton loginB = new JButton(\"LOGIN\");\n\t\tloginB.setBounds(200, 280, 95, 45);\n\t\tloginB.setFont(masterFont);\n\t\tloginB.setOpaque(true);\n\t\tloginB.addActionListener(new ActionListener() {\n\t public void actionPerformed(ActionEvent e) {\n\t \tlogin = true;\n\t \tif (usernameTF.getText().equals(\"jmn7080\")) {\n\t \t\t\n\t \t\t//Retrieve password input by user\n\t\t\t\tchar[] input = passwordPF.getPassword();\n\t\t\t\tchar[] correctPassword = { 's', 'a', 'v', 'e', 'm', 'e'};\n\t\t\t\t\t\n\t\t\t\tif (isPasswordCorrect(input, correctPassword)) {\n\t\t\t\t\tloginWindow.dispose();\n\t\t\t\t\tcreateTempData();\n\t\t\t\t\tteacherPortalScreen();\n\t\t\t\t\t\n\t\t\t\t} else {\n\t\t\t\t\tJOptionPane.showMessageDialog(loginWindow,\"Incorrect login or password\",\n\t\t\t\t\t\t\t\"Error\",JOptionPane.ERROR_MESSAGE);\n\t\t\t\t\tpasswordPF.setText(\"\");\n\t\t\t \t}\n\t } else {\n\t\t\t\tJOptionPane.showMessageDialog(loginWindow,\"Invalid username\",\n\t\t\t\t\t\t\"Error\",JOptionPane.ERROR_MESSAGE);\n\t\t\t\tusernameTF.setText(\"\");\n\t\t\t\tpasswordPF.setText(\"\");\n\t }\n\t }\n\t \t});\n\t\tbackground.add(loginB);\n\t\t\n\t\t//Sign-up JButton\n\t\tJButton signupB = new JButton(\"SIGN UP\");\n\t\tsignupB.setBounds(305, 280, 95, 45);\n\t\tsignupB.setFont(masterFont);\n\t\tsignupB.setOpaque(true);\n\t\tsignupB.addActionListener(new ActionListener() {\n\t public void actionPerformed(ActionEvent e) {\n\t \tloginWindow.dispose();\n\t \t\tnewUserScreen();\n\t }\n\t \t});\n\t\tbackground.add(signupB);\n\t\t\n\t\t//Forgot Username JButton\n\t\tJButton forgotUsernameB = new JButton(\"Forgot your username?\");\n\t\tforgotUsernameB.setBounds(200, 180, 200, 35);\n\t\tforgotUsernameB.setFont(new Font(\"Candara\", Font.PLAIN, 12));\n\t\tforgotUsernameB.setOpaque(false);\n\t\tforgotUsernameB.setContentAreaFilled(false);\n\t\tforgotUsernameB.setBorderPainted(false);\n\t\tforgotUsernameB.setForeground(Color.WHITE);\n\t\tforgotUsernameB.addActionListener(new ActionListener() {\n\t public void actionPerformed(ActionEvent e) {\n\t \tloginWindow.dispose();\n\t \t\t//forgotUsernameScreen();\n\t }\n\t \t});\n\t\tbackground.add(forgotUsernameB);\n\t\t\n\t\t//Forgot Password JButton\n\t\tJButton forgotPasswordB = new JButton(\"Forgot your password?\");\n\t\tforgotPasswordB.setBounds(200, 240, 200, 35);\n\t\tforgotPasswordB.setFont(new Font(\"Candara\", Font.PLAIN, 12));\n\t\tforgotPasswordB.setOpaque(false);\n\t\tforgotPasswordB.setContentAreaFilled(false);\n\t\tforgotPasswordB.setBorderPainted(false);\n\t\tforgotPasswordB.setForeground(Color.WHITE);\n\t\tforgotPasswordB.addActionListener(new ActionListener() {\n\t public void actionPerformed(ActionEvent e) {\n\t \tloginWindow.dispose();\n\t \t\t//forgotPasswordScreen();\n\t }\n\t \t});\n\t\tbackground.add(forgotPasswordB);\n\t\t\n\t\t//Display the window\n\t\tloginWindow.pack();\n\t\tloginWindow.setVisible(true);\n\t}", "public LoginFrame() {\n initComponents();\n }", "private void initializeLogInPanel() {\r\n\r\n // set up Login Panel\r\n loginPanel = new JPanel(new GridBagLayout());\r\n loginConstraints = new GridBagConstraints();\r\n loginPanel.setBackground(MainGUI.backgroundColor);\r\n\r\n login_directionLabel = new JLabel(\"Employee Login\");\r\n login_usernameLabel = new JLabel(\"Username:\");\r\n login_passwordLabel = new JLabel(\"Password:\");\r\n login_directionLabel.setFont(new Font(login_directionLabel.getFont().getFontName(), Font.PLAIN, 40));\r\n\r\n login_directionLabel.setForeground(MainGUI.fontColor);\r\n login_usernameLabel.setForeground(MainGUI.fontColor);\r\n login_passwordLabel.setForeground(MainGUI.fontColor);\r\n\r\n login_usernameTextField = new JTextField(12);\r\n login_passwordField = new JPasswordField(12);\r\n\r\n loginButton = new JButton(\"Login\");\r\n loginButton.setForeground(MainGUI.fontColor);\r\n\r\n // add login label\r\n loginConstraints.gridx = 10;\r\n loginConstraints.gridy = 10;\r\n loginConstraints.weighty = 0.2;\r\n loginConstraints.gridwidth = 20;\r\n loginConstraints.anchor = GridBagConstraints.NORTH;\r\n loginConstraints.insets = new Insets(50, 5, 0, 30);\r\n loginPanel.add(login_directionLabel, loginConstraints);\r\n\r\n // add username label\r\n loginConstraints.gridy = 20;\r\n loginConstraints.weighty = 0;\r\n loginConstraints.gridwidth = 10;\r\n loginConstraints.insets = new Insets(40, 40, 0, 0);\r\n loginPanel.add(login_usernameLabel, loginConstraints);\r\n\r\n // add password label\r\n loginConstraints.gridy = 30;\r\n loginConstraints.gridwidth = 10;\r\n loginConstraints.insets = new Insets(10, 40, 0, 0);\r\n loginPanel.add(login_passwordLabel, loginConstraints);\r\n\r\n // add username textfield\r\n loginConstraints.gridx = 20;\r\n loginConstraints.gridy = 20;\r\n loginConstraints.gridwidth = 20;\r\n loginConstraints.insets = new Insets(40, 0, 0, 35);\r\n loginPanel.add(login_usernameTextField, loginConstraints);\r\n\r\n // add password textfield\r\n loginConstraints.gridy = 30;\r\n loginConstraints.gridwidth = 10;\r\n loginConstraints.insets = new Insets(12, 0, 0, 35);\r\n loginPanel.add(login_passwordField, loginConstraints);\r\n\r\n // add login button\r\n loginConstraints.gridx = 10;\r\n loginConstraints.gridy = 40;\r\n loginConstraints.weighty = 1;\r\n loginConstraints.ipadx = 15;\r\n loginConstraints.ipady = 10;\r\n loginConstraints.gridwidth = 20;\r\n loginConstraints.anchor = GridBagConstraints.NORTH;\r\n loginConstraints.insets = new Insets(30, 0, 0, 40);\r\n loginPanel.add(loginButton, loginConstraints);\r\n\r\n }", "@Override\n public void loginScreen() {\n logIn = new GUILogInScreen().getPanel();\n frame.setContentPane(logIn);\n ((JButton) logIn.getComponent(4)).addActionListener(e -> {\n setUsername();\n });\n }", "public LoginUI(Escola sistema) {\n\t\tsetBackground(Color.WHITE);\n\t\tsetResizable(false);\n\t\tsetType(Type.NORMAL);\n\t\tsetTitle(\"Login Page\");\n\t\tsetDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n\t\tsetBounds(100, 100, 770, 500);\n\t\t\n\t\tcontentPane = new JPanel();\n\t\tcontentPane.setForeground(new Color(0, 0, 0));\n\t\tcontentPane.setBackground(new Color(240, 230, 140));\n\t\tcontentPane.setBorder(new MatteBorder(4, 4, 4, 4, (Color) new Color(218, 165, 32)));\n\t\tcontentPane.setLayout(null);\n\t\tsetContentPane(contentPane);\n\t\t\n\t\tlblRegistro = new JLabel(\"Nº do Registro:\");\n\t\tlblRegistro.setForeground(new Color(0, 0, 0));\n\t\tlblRegistro.setFont(new Font(\"Arial\", Font.BOLD | Font.ITALIC, 35));\n\t\tlblRegistro.setBounds(61, 232, 262, 48);\n\t\t\n\t\ttxtRegistro = new JTextField();\n\t\ttxtRegistro.setForeground(new Color(105, 105, 105));\n\t\ttxtRegistro.setBackground(new Color(211, 211, 211));\n\t\ttxtRegistro.setFont(new Font(\"Arial\", Font.BOLD, 20));\n\t\ttxtRegistro.setText(\"Insira o número do Registro\");\n\t\ttxtRegistro.setBounds(333, 239, 340, 38);\n\t\ttxtRegistro.addKeyListener(new KeyAdapter() {\n\t public void keyTyped(KeyEvent evt) {\n\t \tchar c = evt.getKeyChar();\n\t if(!(((c >= '0') && (c <= '9')) || (c == java.awt.event.KeyEvent.VK_BACK_SPACE) || (c == java.awt.event.KeyEvent.VK_DELETE))) {\n\t getToolkit().beep();\n\t evt.consume();\n\t }\n\t }\n\t\t});\n\t\ttxtRegistro.addMouseListener(new MouseAdapter() {\n\t public void mouseClicked(MouseEvent evt) {\n\t if(txtRegistro.getText().equals(\"Insira o número do Registro\")) {\n\t \ttxtRegistro.setText(\"\");\n\t txtRegistro.repaint();\n\t txtRegistro.revalidate();\n\t } \n\t }\n\t });\n\t\ttxtRegistro.addFocusListener(new FocusAdapter() {\n\t\t\tpublic void focusLost(FocusEvent evt) {\n\t\t\t\tif(txtRegistro.getText().equals(\"\")) {\n\t\t\t\t\ttxtRegistro.setText(\"Insira o número do Registro\");\n\t\t\t\t\ttxtRegistro.repaint();\n\t txtRegistro.revalidate();\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\t\n\t\tlblSenha = new JLabel(\"Senha:\");\n\t\tlblSenha.setForeground(Color.BLACK);\n\t\tlblSenha.setFont(new Font(\"Arial\", Font.BOLD | Font.ITALIC, 35));\n\t\tlblSenha.setBounds(198, 292, 125, 48);\n\t\t\n\t\tsenhaVisivel = false;\n\t\ttxtSenha = new JPasswordField();\n\t\ttxtSenha.setForeground(new Color(105, 105, 105));\n\t\ttxtSenha.setBackground(new Color(211, 211, 211));\n\t\ttxtSenha.setFont(new Font(\"Arial\", Font.BOLD, 20));\n\t\ttxtSenha.setEchoChar((char)0);\n\t\ttxtSenha.setText(\"Insira a Senha\");\n\t\ttxtSenha.setBounds(333, 299, 340, 38);\n\t\ttxtSenha.addMouseListener(new MouseAdapter() {\n\t public void mouseClicked(MouseEvent evt) {\n\t if((new String(txtSenha.getPassword())).equals(\"Insira a Senha\")) {\n\t \tif(senhaVisivel) {\n\t \t\ttxtSenha.setEchoChar((char)0);\n\t \t} else {\n\t \t\ttxtSenha.setEchoChar(\"*\".charAt(0));\n\t \t}\n\t \ttxtSenha.setText(\"\");\n\t txtSenha.repaint();\n\t txtSenha.revalidate();\n\t } \n\t }\n\t });\n\t\ttxtSenha.addFocusListener(new FocusAdapter() {\n\t\t\tpublic void focusLost(FocusEvent evt) {\n\t\t\t\tif((new String(txtSenha.getPassword())).equals(\"\")) {\n\t\t\t\t\ttxtSenha.setEchoChar((char)0);\n\t\t\t\t\ttxtSenha.setText(\"Insira a Senha\");\n\t\t\t\t\ttxtSenha.repaint();\n\t txtSenha.revalidate();\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\t\n\t\tbtnLogin = new JButton(\"Login\");\n\t\tbtnLogin.setFont(new Font(\"Arial\", Font.BOLD, 22));\n\t\tbtnLogin.setBounds(261, 368, 216, 48);\n\t\tbtnLogin.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent evt) {\n\t\t\t\ttry {\n\t\t\t\t\tcontaLogada = sistema.checkLogin(txtRegistro.getText(), new String(txtSenha.getPassword()));\n\t\t\t\t\tEventQueue.invokeLater(new Runnable() {\n\t\t\t\t\t\tpublic void run() {\n\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\tPagPrincipalUI frame = new PagPrincipalUI(sistema, contaLogada);\n\t\t\t\t\t\t\t\tframe.setVisible(true);\n\t\t\t\t\t\t\t} catch (Exception e) {\n\t\t\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t\t\tdispose();\n\t\t\t\t} catch (LoginFalhouException e) {\n\t\t\t\t\tJOptionPane.showMessageDialog(null, \"Registro ou Senha INVÁLIDO!\", \"ERRO no Login\", JOptionPane.ERROR_MESSAGE);\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\t\n\t\tchckbxVerSenha = new JCheckBox();\n\t\tchckbxVerSenha.setBackground(new Color(240, 230, 140));\n\t\tchckbxVerSenha.setBounds(679, 302, 32, 32);\n\t\tchckbxVerSenha.setIcon(new ImageIcon(new ImageIcon(\".\\\\UI Icons\\\\eyeX.png\").getImage().getScaledInstance(25, 25, Image.SCALE_DEFAULT)));\n\t\tchckbxVerSenha.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent evt) {\n\t\t\t\tif (chckbxVerSenha.isSelected()) {\n\t\t\t\t\ttxtSenha.setEchoChar((char)0);\n\t\t\t\t\tsenhaVisivel = true;\n\t\t\t\t\tchckbxVerSenha.setIcon(new ImageIcon(new ImageIcon(\".\\\\UI Icons\\\\eye.png\").getImage().getScaledInstance(24, 24, Image.SCALE_DEFAULT)));\n\t\t\t\t} else {\n\t\t\t\t\tif(!(new String(txtSenha.getPassword())).equals(\"Insira a Senha\")) {\n\t\t\t\t\t\ttxtSenha.setEchoChar(\"*\".charAt(0));\n\t\t\t\t\t}\n\t\t\t\t\tsenhaVisivel = false;\n\t\t\t\t\tchckbxVerSenha.setIcon(new ImageIcon(new ImageIcon(\".\\\\UI Icons\\\\eyeX.png\").getImage().getScaledInstance(25, 25, Image.SCALE_DEFAULT)));\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\t\n\t\tcontentPane.add(lblRegistro);\n\t\tcontentPane.add(txtRegistro);\n\t\tcontentPane.add(lblSenha);\n\t\tcontentPane.add(txtSenha);\n\t\tcontentPane.add(btnLogin);\n\t\tcontentPane.add(chckbxVerSenha);\n\t}", "@Override\n\t\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\t\ttry {\n\t\t\t\t\t\tloginPage = new LoginGUI();\n\t\t\t\t\t} catch (ClassNotFoundException | IOException e1) {\n\t\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\t\te1.printStackTrace();\n\t\t\t\t\t}\n\t\t\t\t\tloginPage.setVisible(true);\n\t\t\t\t\t\n\t\t\t\t\tdispose();\n\t\t\t\t}", "public UserLogin() {\n initComponents();\n setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);\n }", "public Login() {\n initComponents();\n this.setTitle(\"Login\");\n this.setLocationRelativeTo(null);\n this.pack();\n // Asignanado objecto\n adminUsers = new usuarioAdmin();\n \n // No hay inicializacion de usuarios\n sys.us[0] = new Usuario();\n sys.us[0].setId(\"admin\");\n sys.us[0].setNombre(\"admin\");\n sys.us[0].setApellido(\"admin\");\n sys.us[0].setUser(\"admin\");\n sys.us[0].setPassword(\"admin\");\n sys.us[0].setRol(\"admin\");\n }" ]
[ "0.77798134", "0.7487561", "0.74544805", "0.7319445", "0.7228107", "0.7172311", "0.7073647", "0.70703477", "0.70614487", "0.7033141", "0.69639236", "0.6948532", "0.6930426", "0.69273835", "0.69060403", "0.69015855", "0.6864539", "0.68562156", "0.6841404", "0.6820494", "0.6814666", "0.67889714", "0.67622274", "0.6756103", "0.6746872", "0.67360693", "0.673406", "0.6729601", "0.6715294", "0.67086416", "0.6696825", "0.6696191", "0.6694958", "0.66946775", "0.66717255", "0.66612816", "0.66238385", "0.6606279", "0.6604309", "0.66029525", "0.6584115", "0.6569047", "0.6560033", "0.6552509", "0.6552509", "0.6552509", "0.6552509", "0.6552509", "0.6552509", "0.6552509", "0.6552509", "0.6552509", "0.6552509", "0.6552509", "0.6552509", "0.6552509", "0.6552509", "0.6552509", "0.6552509", "0.6547894", "0.654758", "0.65473104", "0.65429384", "0.65305203", "0.6530168", "0.6521677", "0.6521677", "0.6519848", "0.6491988", "0.64884996", "0.64884996", "0.6482734", "0.6475654", "0.6468437", "0.64675456", "0.6462396", "0.646061", "0.6460485", "0.64568114", "0.6439889", "0.64360344", "0.64350873", "0.64324564", "0.64321035", "0.642999", "0.64273226", "0.6411907", "0.6410703", "0.6410022", "0.6410018", "0.6408739", "0.64062774", "0.64053196", "0.6397104", "0.6396888", "0.63968605", "0.63936293", "0.63898176", "0.638358", "0.63827604" ]
0.6908806
14
This method is called from within the constructor to initialize the form. WARNING: Do NOT modify this code. The content of this method is always regenerated by the Form Editor.
@SuppressWarnings("unchecked") // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents private void initComponents() { jLabel2 = new javax.swing.JLabel(); botonGoogle = new javax.swing.JButton(); botonFb = new javax.swing.JButton(); jLabel1 = new javax.swing.JLabel(); jPanel1 = new javax.swing.JPanel(); jLabel3 = new javax.swing.JLabel(); jLabel4 = new javax.swing.JLabel(); textFieldEmail = new javax.swing.JTextField(); jLabel5 = new javax.swing.JLabel(); jLabel6 = new javax.swing.JLabel(); passwordField = new javax.swing.JPasswordField(); botonEntrar = new javax.swing.JButton(); jLabel2.setText("jLabel2"); setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE); setAutoRequestFocus(false); setBackground(new java.awt.Color(244, 247, 247)); setPreferredSize(new java.awt.Dimension(250, 355)); setResizable(false); addWindowListener(new java.awt.event.WindowAdapter() { public void windowClosing(java.awt.event.WindowEvent evt) { formWindowClosing(evt); } }); getContentPane().setLayout(new org.netbeans.lib.awtextra.AbsoluteLayout()); botonGoogle.setIcon(new javax.swing.ImageIcon(getClass().getResource("/images/inicia_google.png"))); // NOI18N botonGoogle.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { botonGoogleActionPerformed(evt); } }); getContentPane().add(botonGoogle, new org.netbeans.lib.awtextra.AbsoluteConstraints(20, 286, 200, 30)); botonFb.setIcon(new javax.swing.ImageIcon(getClass().getResource("/images/inicia_fb.png"))); // NOI18N botonFb.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { botonFbActionPerformed(evt); } }); getContentPane().add(botonFb, new org.netbeans.lib.awtextra.AbsoluteConstraints(20, 246, 200, 30)); jLabel1.setFont(new java.awt.Font("Sawasdee", 1, 15)); // NOI18N jLabel1.setForeground(new java.awt.Color(1, 1, 1)); jLabel1.setHorizontalAlignment(javax.swing.SwingConstants.CENTER); jLabel1.setText("- O REGÍSTRATE AQUÍ -"); jLabel1.addMouseListener(new java.awt.event.MouseAdapter() { public void mouseClicked(java.awt.event.MouseEvent evt) { jLabel1MouseClicked(evt); } public void mouseExited(java.awt.event.MouseEvent evt) { jLabel1MouseExited(evt); } public void mouseEntered(java.awt.event.MouseEvent evt) { jLabel1MouseEntered(evt); } }); getContentPane().add(jLabel1, new org.netbeans.lib.awtextra.AbsoluteConstraints(20, 320, 200, -1)); jPanel1.setBackground(new java.awt.Color(192, 237, 228)); jPanel1.setLayout(new org.netbeans.lib.awtextra.AbsoluteLayout()); jLabel3.setIcon(new javax.swing.ImageIcon(getClass().getResource("/images/flecha30x30.png"))); // NOI18N jLabel3.setToolTipText("Atrás"); jLabel3.addMouseListener(new java.awt.event.MouseAdapter() { public void mouseClicked(java.awt.event.MouseEvent evt) { jLabel3MouseClicked(evt); } }); jPanel1.add(jLabel3, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 10, -1, -1)); jLabel4.setFont(new java.awt.Font("Sawasdee", 1, 24)); // NOI18N jLabel4.setForeground(new java.awt.Color(100, 104, 105)); jLabel4.setText("INICIA SESIÓN"); jPanel1.add(jLabel4, new org.netbeans.lib.awtextra.AbsoluteConstraints(50, 10, -1, 30)); getContentPane().add(jPanel1, new org.netbeans.lib.awtextra.AbsoluteConstraints(0, 0, 250, 50)); textFieldEmail.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { textFieldEmailActionPerformed(evt); } }); getContentPane().add(textFieldEmail, new org.netbeans.lib.awtextra.AbsoluteConstraints(20, 100, 200, 30)); jLabel5.setFont(new java.awt.Font("Sawasdee", 1, 15)); // NOI18N jLabel5.setHorizontalAlignment(javax.swing.SwingConstants.CENTER); jLabel5.setText("CONTRASEÑA"); getContentPane().add(jLabel5, new org.netbeans.lib.awtextra.AbsoluteConstraints(20, 130, 120, 30)); jLabel6.setFont(new java.awt.Font("Sawasdee", 1, 15)); // NOI18N jLabel6.setHorizontalAlignment(javax.swing.SwingConstants.CENTER); jLabel6.setText("E-MAIL:"); getContentPane().add(jLabel6, new org.netbeans.lib.awtextra.AbsoluteConstraints(20, 67, 70, 40)); passwordField.addMouseListener(new java.awt.event.MouseAdapter() { public void mouseEntered(java.awt.event.MouseEvent evt) { passwordFieldMouseEntered(evt); } }); passwordField.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { passwordFieldActionPerformed(evt); } }); passwordField.addPropertyChangeListener(new java.beans.PropertyChangeListener() { public void propertyChange(java.beans.PropertyChangeEvent evt) { passwordFieldPropertyChange(evt); } }); getContentPane().add(passwordField, new org.netbeans.lib.awtextra.AbsoluteConstraints(20, 160, 200, 30)); botonEntrar.setIcon(new javax.swing.ImageIcon(getClass().getResource("/images/inicia_correo.png"))); // NOI18N botonEntrar.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { botonEntrarActionPerformed(evt); } }); getContentPane().add(botonEntrar, new org.netbeans.lib.awtextra.AbsoluteConstraints(20, 210, 200, 30)); pack(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Form() {\n initComponents();\n }", "public MainForm() {\n initComponents();\n }", "public MainForm() {\n initComponents();\n }", "public MainForm() {\n initComponents();\n }", "public frmRectangulo() {\n initComponents();\n }", "public form() {\n initComponents();\n }", "public AdjointForm() {\n initComponents();\n setDefaultCloseOperation(HIDE_ON_CLOSE);\n }", "public FormListRemarking() {\n initComponents();\n }", "public MainForm() {\n initComponents();\n \n }", "public FormPemilihan() {\n initComponents();\n }", "public GUIForm() { \n initComponents();\n }", "public FrameForm() {\n initComponents();\n }", "public TorneoForm() {\n initComponents();\n }", "public FormCompra() {\n initComponents();\n }", "public muveletek() {\n initComponents();\n }", "public Interfax_D() {\n initComponents();\n }", "public quanlixe_form() {\n initComponents();\n }", "public SettingsForm() {\n initComponents();\n }", "public RegistrationForm() {\n initComponents();\n this.setLocationRelativeTo(null);\n }", "public Soru1() {\n initComponents();\n }", "public FMainForm() {\n initComponents();\n this.setResizable(false);\n setLocationRelativeTo(null);\n }", "public soal2GUI() {\n initComponents();\n }", "public EindopdrachtGUI() {\n initComponents();\n }", "public MechanicForm() {\n initComponents();\n }", "public AddDocumentLineForm(java.awt.Frame parent) {\n super(parent);\n initComponents();\n myInit();\n }", "public quotaGUI() {\n initComponents();\n }", "public BloodDonationGUI() {\n initComponents();\n }", "public Customer_Form() {\n initComponents();\n setSize(890,740);\n \n \n }", "public PatientUI() {\n initComponents();\n }", "public myForm() {\n\t\t\tinitComponents();\n\t\t}", "public Oddeven() {\n initComponents();\n }", "public Magasin() {\n initComponents();\n }", "public intrebarea() {\n initComponents();\n }", "public RadioUI()\n {\n initComponents();\n }", "public NewCustomerGUI() {\n initComponents();\n }", "public ZobrazUdalost() {\n initComponents();\n }", "public FormUtama() {\n initComponents();\n }", "public p0() {\n initComponents();\n }", "public INFORMACION() {\n initComponents();\n this.setLocationRelativeTo(null); \n }", "public ProgramForm() {\n setLookAndFeel();\n initComponents();\n }", "public AmountReleasedCommentsForm() {\r\n initComponents();\r\n }", "public form2() {\n initComponents();\n }", "public MainForm() {\n\t\tsuper(\"Hospital\", List.IMPLICIT);\n\n\t\tstartComponents();\n\t}", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n setName(\"Form\"); // NOI18N\n setRequestFocusEnabled(false);\n setVerifyInputWhenFocusTarget(false);\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);\n this.setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 465, Short.MAX_VALUE)\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 357, Short.MAX_VALUE)\n );\n }", "public LixeiraForm() {\n initComponents();\n setLocationRelativeTo(null);\n }", "public kunde() {\n initComponents();\n }", "public frmMain() {\n initComponents();\n }", "public frmMain() {\n initComponents();\n }", "public MusteriEkle() {\n initComponents();\n }", "public DESHBORDPANAL() {\n initComponents();\n }", "public GUIForm() {\n initComponents();\n inputField.setText(NO_FILE_SELECTED);\n outputField.setText(NO_FILE_SELECTED);\n progressLabel.setBackground(INFO);\n progressLabel.setText(SELECT_FILE);\n }", "public frmVenda() {\n initComponents();\n }", "public FrmMenu() {\n initComponents();\n }", "public Botonera() {\n initComponents();\n }", "public OffertoryGUI() {\n initComponents();\n setTypes();\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents()\n {\n\n setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);\n setBackground(new java.awt.Color(255, 255, 255));\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());\n getContentPane().setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 983, Short.MAX_VALUE)\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 769, Short.MAX_VALUE)\n );\n\n pack();\n }", "public JFFornecedores() {\n initComponents();\n }", "public EnterDetailsGUI() {\n initComponents();\n }", "public vpemesanan1() {\n initComponents();\n }", "public Kost() {\n initComponents();\n }", "public UploadForm() {\n initComponents();\n }", "public FormHorarioSSE() {\n initComponents();\n }", "public frmacceso() {\n initComponents();\n }", "public HW3() {\n initComponents();\n }", "public Managing_Staff_Main_Form() {\n initComponents();\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents()\n {\n\n setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);\n getContentPane().setLayout(null);\n\n pack();\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n setName(\"Form\"); // NOI18N\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);\n this.setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 400, Short.MAX_VALUE)\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 300, Short.MAX_VALUE)\n );\n }", "public sinavlar2() {\n initComponents();\n }", "public P0405() {\n initComponents();\n }", "public IssueBookForm() {\n initComponents();\n }", "public MiFrame2() {\n initComponents();\n }", "public Choose1() {\n initComponents();\n }", "public MainForm() {\n initComponents();\n\n String oldAuthor = prefs.get(\"AUTHOR\", \"\");\n if(oldAuthor != null) {\n this.authorTextField.setText(oldAuthor);\n }\n String oldBook = prefs.get(\"BOOK\", \"\");\n if(oldBook != null) {\n this.bookTextField.setText(oldBook);\n }\n String oldDisc = prefs.get(\"DISC\", \"\");\n if(oldDisc != null) {\n try {\n int oldDiscNum = Integer.parseInt(oldDisc);\n oldDiscNum++;\n this.discNumberTextField.setText(Integer.toString(oldDiscNum));\n } catch (Exception ex) {\n this.discNumberTextField.setText(oldDisc);\n }\n this.bookTextField.setText(oldBook);\n }\n\n\n }", "public GUI_StudentInfo() {\n initComponents();\n }", "public JFrmPrincipal() {\n initComponents();\n }", "public Lihat_Dokter_Keseluruhan() {\n initComponents();\n }", "public bt526() {\n initComponents();\n }", "public Pemilihan_Dokter() {\n initComponents();\n }", "public Ablak() {\n initComponents();\n }", "@Override\n\tprotected void initUi() {\n\t\t\n\t}", "@SuppressWarnings(\"unchecked\")\n\t// <editor-fold defaultstate=\"collapsed\" desc=\"Generated\n\t// Code\">//GEN-BEGIN:initComponents\n\tprivate void initComponents() {\n\n\t\tlabel1 = new java.awt.Label();\n\t\tlabel2 = new java.awt.Label();\n\t\tlabel3 = new java.awt.Label();\n\t\tlabel4 = new java.awt.Label();\n\t\tlabel5 = new java.awt.Label();\n\t\tlabel6 = new java.awt.Label();\n\t\tlabel7 = new java.awt.Label();\n\t\tlabel8 = new java.awt.Label();\n\t\tlabel9 = new java.awt.Label();\n\t\tlabel10 = new java.awt.Label();\n\t\ttextField1 = new java.awt.TextField();\n\t\ttextField2 = new java.awt.TextField();\n\t\tlabel14 = new java.awt.Label();\n\t\tlabel15 = new java.awt.Label();\n\t\tlabel16 = new java.awt.Label();\n\t\ttextField3 = new java.awt.TextField();\n\t\ttextField4 = new java.awt.TextField();\n\t\ttextField5 = new java.awt.TextField();\n\t\tlabel17 = new java.awt.Label();\n\t\tlabel18 = new java.awt.Label();\n\t\tlabel19 = new java.awt.Label();\n\t\tlabel20 = new java.awt.Label();\n\t\tlabel21 = new java.awt.Label();\n\t\tlabel22 = new java.awt.Label();\n\t\ttextField6 = new java.awt.TextField();\n\t\ttextField7 = new java.awt.TextField();\n\t\ttextField8 = new java.awt.TextField();\n\t\tlabel23 = new java.awt.Label();\n\t\ttextField9 = new java.awt.TextField();\n\t\ttextField10 = new java.awt.TextField();\n\t\ttextField11 = new java.awt.TextField();\n\t\ttextField12 = new java.awt.TextField();\n\t\tlabel24 = new java.awt.Label();\n\t\tlabel25 = new java.awt.Label();\n\t\tlabel26 = new java.awt.Label();\n\t\tlabel27 = new java.awt.Label();\n\t\tlabel28 = new java.awt.Label();\n\t\tlabel30 = new java.awt.Label();\n\t\tlabel31 = new java.awt.Label();\n\t\tlabel32 = new java.awt.Label();\n\t\tjButton1 = new javax.swing.JButton();\n\n\t\tlabel1.setFont(new java.awt.Font(\"Segoe UI Semibold\", 0, 18)); // NOI18N\n\t\tlabel1.setText(\"It seems that some of the buttons on the ATM machine are not working!\");\n\n\t\tlabel2.setFont(new java.awt.Font(\"Segoe UI Semibold\", 0, 18)); // NOI18N\n\t\tlabel2.setText(\"Unfortunately these numbers are exactly what Professor has to use to type in his password.\");\n\n\t\tlabel3.setFont(new java.awt.Font(\"Segoe UI Semibold\", 0, 18)); // NOI18N\n\t\tlabel3.setText(\n\t\t\t\t\"If you want to eat tonight, you have to help him out and construct the numbers of the password with the working buttons and math operators.\");\n\n\t\tlabel4.setFont(new java.awt.Font(\"Segoe UI Semibold\", 0, 14)); // NOI18N\n\t\tlabel4.setText(\"Denver's Password: 2792\");\n\n\t\tlabel5.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel5.setText(\"import java.util.Scanner;\\n\");\n\n\t\tlabel6.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel6.setText(\"public class ATM{\");\n\n\t\tlabel7.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel7.setText(\"public static void main(String[] args){\");\n\n\t\tlabel8.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel8.setText(\"System.out.print(\");\n\n\t\tlabel9.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel9.setText(\" -\");\n\n\t\tlabel10.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel10.setText(\");\");\n\n\t\ttextField1.addActionListener(new java.awt.event.ActionListener() {\n\t\t\tpublic void actionPerformed(java.awt.event.ActionEvent evt) {\n\t\t\t\ttextField1ActionPerformed(evt);\n\t\t\t}\n\t\t});\n\n\t\tlabel14.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel14.setText(\"System.out.print( (\");\n\n\t\tlabel15.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel15.setText(\"System.out.print(\");\n\n\t\tlabel16.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel16.setText(\"System.out.print( ( (\");\n\n\t\tlabel17.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel17.setText(\")\");\n\n\t\tlabel18.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel18.setText(\" +\");\n\n\t\tlabel19.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel19.setText(\");\");\n\n\t\tlabel20.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel20.setText(\" /\");\n\n\t\tlabel21.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel21.setText(\" %\");\n\n\t\tlabel22.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel22.setText(\" +\");\n\n\t\tlabel23.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel23.setText(\");\");\n\n\t\tlabel24.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel24.setText(\" +\");\n\n\t\tlabel25.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel25.setText(\" /\");\n\n\t\tlabel26.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel26.setText(\" *\");\n\n\t\tlabel27.setCursor(new java.awt.Cursor(java.awt.Cursor.DEFAULT_CURSOR));\n\t\tlabel27.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel27.setText(\")\");\n\n\t\tlabel28.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel28.setText(\")\");\n\n\t\tlabel30.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel30.setText(\"}\");\n\n\t\tlabel31.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel31.setText(\"}\");\n\n\t\tlabel32.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel32.setText(\");\");\n\n\t\tjButton1.setFont(new java.awt.Font(\"Segoe UI Semibold\", 0, 14)); // NOI18N\n\t\tjButton1.setText(\"Check\");\n\t\tjButton1.addActionListener(new java.awt.event.ActionListener() {\n\t\t\tpublic void actionPerformed(java.awt.event.ActionEvent evt) {\n\t\t\t\tjButton1ActionPerformed(evt);\n\t\t\t}\n\t\t});\n\n\t\tjavax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);\n\t\tlayout.setHorizontalGroup(layout.createParallelGroup(Alignment.LEADING)\n\t\t\t\t.addGroup(layout.createSequentialGroup().addGap(28).addGroup(layout\n\t\t\t\t\t\t.createParallelGroup(Alignment.LEADING).addComponent(getDoneButton()).addComponent(jButton1)\n\t\t\t\t\t\t.addComponent(label7, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addComponent(label6, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addComponent(label5, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addComponent(label4, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addComponent(label3, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t.addComponent(label1, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t.addGap(1)\n\t\t\t\t\t\t\t\t.addComponent(label2, GroupLayout.PREFERRED_SIZE, 774, GroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t.addGap(92).addGroup(layout.createParallelGroup(Alignment.LEADING).addGroup(layout\n\t\t\t\t\t\t\t\t\t\t.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.LEADING, false)\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label15, GroupLayout.PREFERRED_SIZE, 145,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField8, GroupLayout.PREFERRED_SIZE, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(2)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label21, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField7, GroupLayout.PREFERRED_SIZE, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label8, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField1, GroupLayout.PREFERRED_SIZE, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label9, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED).addComponent(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\ttextField2, GroupLayout.PREFERRED_SIZE, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label31, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup().addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label14, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(37))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup().addGap(174)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField5, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t20, GroupLayout.PREFERRED_SIZE)))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label18, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(7)))\n\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.LEADING).addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.TRAILING, false).addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField4, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t20, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label17, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label22, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField9, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t20, GroupLayout.PREFERRED_SIZE)))\n\t\t\t\t\t\t\t\t\t\t\t\t.addGap(20)\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label23, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label20, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField3, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t20, GroupLayout.PREFERRED_SIZE)))\n\t\t\t\t\t\t\t\t\t\t\t\t.addGap(20).addComponent(label19, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup().addGap(23).addComponent(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tlabel10, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))))\n\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label16, GroupLayout.PREFERRED_SIZE, 177,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField12, GroupLayout.PREFERRED_SIZE, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label24, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField6, GroupLayout.PREFERRED_SIZE, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label27, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label25, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField11, GroupLayout.PREFERRED_SIZE, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label28, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addGap(1)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label26, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField10, GroupLayout.PREFERRED_SIZE, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED).addComponent(label32,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))))\n\t\t\t\t\t\t.addComponent(label30, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t.addContainerGap(GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)));\n\t\tlayout.setVerticalGroup(\n\t\t\t\tlayout.createParallelGroup(Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap()\n\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.TRAILING)\n\t\t\t\t\t\t\t\t.addComponent(label1, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t.addComponent(label2, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t.addGap(1)\n\t\t\t\t\t\t.addComponent(label3, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t.addComponent(label4, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t.addComponent(label5, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t.addComponent(label6, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t.addComponent(label7, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t.createParallelGroup(\n\t\t\t\t\t\t\t\t\t\tAlignment.TRAILING)\n\t\t\t\t\t\t\t\t.addGroup(\n\t\t\t\t\t\t\t\t\t\tlayout.createSequentialGroup().addGroup(layout.createParallelGroup(\n\t\t\t\t\t\t\t\t\t\t\t\tAlignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createSequentialGroup().addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.TRAILING).addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label9,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label8,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField1,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\ttextField2, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label10,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(3)))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(19)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField5,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label14,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup().addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label18,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label17,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField4,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(1))))\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label20, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label19, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField3, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)))\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup().addGap(78)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label27, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup().addGap(76)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField11, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup().addGap(75)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label32,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField10,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tShort.MAX_VALUE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.TRAILING, false)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tAlignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label15,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField8,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label21,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField7,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(27))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tAlignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField9,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tAlignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label22,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tlayout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(3)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tlabel23,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(29)))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label16,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField12,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tAlignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label24,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField6,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(1))))))\n\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t.addComponent(label25, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t.addComponent(label28, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t.addComponent(label26, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)))\n\t\t\t\t\t\t.addGap(30)\n\t\t\t\t\t\t.addComponent(label31, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addGap(25)\n\t\t\t\t\t\t.addComponent(label30, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addGap(26).addComponent(jButton1).addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t.addComponent(getDoneButton()).addContainerGap(23, Short.MAX_VALUE)));\n\t\tthis.setLayout(layout);\n\n\t\tlabel16.getAccessibleContext().setAccessibleName(\"System.out.print( ( (\");\n\t\tlabel17.getAccessibleContext().setAccessibleName(\"\");\n\t\tlabel18.getAccessibleContext().setAccessibleName(\" +\");\n\t}", "public Pregunta23() {\n initComponents();\n }", "public FormMenuUser() {\n super(\"Form Menu User\");\n initComponents();\n }", "public AvtekOkno() {\n initComponents();\n }", "public busdet() {\n initComponents();\n }", "public ViewPrescriptionForm() {\n initComponents();\n }", "public Ventaform() {\n initComponents();\n }", "public Kuis2() {\n initComponents();\n }", "public CreateAccount_GUI() {\n initComponents();\n }", "public POS1() {\n initComponents();\n }", "public Carrera() {\n initComponents();\n }", "public EqGUI() {\n initComponents();\n }", "public JFriau() {\n initComponents();\n this.setLocationRelativeTo(null);\n this.setTitle(\"BuNus - Budaya Nusantara\");\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n setBackground(new java.awt.Color(204, 204, 204));\n setMinimumSize(new java.awt.Dimension(1, 1));\n setPreferredSize(new java.awt.Dimension(760, 402));\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);\n this.setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 750, Short.MAX_VALUE)\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 400, Short.MAX_VALUE)\n );\n }", "public nokno() {\n initComponents();\n }", "public dokter() {\n initComponents();\n }", "public ConverterGUI() {\n initComponents();\n }", "public hitungan() {\n initComponents();\n }", "public Modify() {\n initComponents();\n }", "public frmAddIncidencias() {\n initComponents();\n }", "public FP_Calculator_GUI() {\n initComponents();\n \n setVisible(true);\n }" ]
[ "0.73201853", "0.7291607", "0.7291607", "0.7291607", "0.7285772", "0.7248832", "0.721371", "0.72083634", "0.71965843", "0.7190274", "0.71847606", "0.71592176", "0.71481156", "0.70935035", "0.70799935", "0.70570904", "0.6987588", "0.6977819", "0.69557554", "0.6953564", "0.6945299", "0.6942377", "0.69355065", "0.69326174", "0.69278985", "0.69251215", "0.69248855", "0.6911974", "0.6911815", "0.68930984", "0.68926644", "0.6890748", "0.689013", "0.6889194", "0.68833196", "0.68817353", "0.68812305", "0.68779206", "0.6875422", "0.6874629", "0.687249", "0.6859694", "0.6857467", "0.6855978", "0.68553996", "0.68549085", "0.6853271", "0.6853271", "0.68530285", "0.68427855", "0.6837456", "0.68367314", "0.682818", "0.6828002", "0.6826416", "0.6823491", "0.6823434", "0.68172073", "0.6816386", "0.6810029", "0.68090403", "0.680861", "0.6807909", "0.6807168", "0.680365", "0.67955285", "0.6795115", "0.6792028", "0.6790702", "0.6789993", "0.67889", "0.67872643", "0.6782707", "0.67665267", "0.6765798", "0.6765086", "0.6755966", "0.6755084", "0.6751955", "0.6750892", "0.67433685", "0.67388666", "0.6737211", "0.6735823", "0.673344", "0.67278177", "0.67267376", "0.67203826", "0.6716326", "0.67144203", "0.6713941", "0.6707991", "0.67068243", "0.6704236", "0.6701207", "0.66996884", "0.6698865", "0.6697606", "0.6693878", "0.6691149", "0.6689875" ]
0.0
-1
load the application context
public static void main(String[] args) { ClassPathXmlApplicationContext context = new ClassPathXmlApplicationContext("applicationContextPart2.xml"); // get bean from the application context Coach theCoach = context.getBean("myCoach", Coach.class); // call the method from the beans System.out.println(theCoach.getDailyWorkout()); System.out.println(theCoach.getFortune()); // close the application context context.close(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public abstract ApplicationLoader.Context context();", "public void initContext() {\n\t\tClassLoader originalContextClassLoader =\n\t\t\t\tThread.currentThread().getContextClassLoader();\n\t\tThread.currentThread().setContextClassLoader(MY_CLASS_LOADER);\n\t\t//this.setClassLoader(MY_CLASS_LOADER);\n\n\t\tcontext = new ClassPathXmlApplicationContext(\"beans.xml\");\n\t\tsetParent(context);\n\n\n\t\t// reset the original CL, to try to prevent crashing with\n\t\t// other Java AI implementations\n\t\tThread.currentThread().setContextClassLoader(originalContextClassLoader);\n\t}", "public static Context getAppContext() {\n return _BaseApplication.context;\n }", "ApplicationContext getAppCtx();", "public static Context getContext(){\n return appContext;\n }", "public static void initializeApp(Context context) {\n }", "@Override\n public void onApplicationEvent(ContextRefreshedEvent event) {\n\n appContext = event.getApplicationContext();\n System.out.println(appContext.getId());\n\n\n log.info(\"api-web初始化\");\n try {\n ApiUtils_.init(appContext);\n } catch (Exception e) {\n log.warn(\"初始化异常!\", e);\n }\n log.info(\"api-web初始化完成\");\n }", "private void initContext() {\n contextId = System.getProperty(CONFIG_KEY_CERES_CONTEXT, DEFAULT_CERES_CONTEXT);\n\n // Initialize application specific configuration keys\n homeDirKey = String.format(\"%s.%s\", contextId, CONFIG_KEY_HOME);\n debugKey = String.format(\"%s.%s\", contextId, CONFIG_KEY_DEBUG);\n configFileKey = String.format(\"%s.%s\", contextId, CONFIG_KEY_CONFIG_FILE_NAME);\n modulesDirKey = String.format(\"%s.%s\", contextId, CONFIG_KEY_MODULES);\n libDirsKey = String.format(\"%s.%s\", contextId, CONFIG_KEY_LIB_DIRS);\n mainClassKey = String.format(\"%s.%s\", contextId, CONFIG_KEY_MAIN_CLASS);\n classpathKey = String.format(\"%s.%s\", contextId, CONFIG_KEY_CLASSPATH);\n applicationIdKey = String.format(\"%s.%s\", contextId, CONFIG_KEY_APP);\n logLevelKey = String.format(\"%s.%s\", contextId, CONFIG_KEY_LOG_LEVEL);\n consoleLogKey = String.format(\"%s.%s\", contextId, CONFIG_KEY_CONSOLE_LOG);\n\n // Initialize default file and directory paths\n char sep = File.separatorChar;\n defaultRelConfigFilePath = String.format(\"%s/%s\", DEFAULT_CONFIG_DIR_NAME, configFileKey).replace('/', sep);\n defaultHomeConfigFilePath = String.format(\"${%s}/%s\", homeDirKey, defaultRelConfigFilePath).replace('/', sep);\n defaultHomeModulesDirPath = String.format(\"${%s}/%s\", homeDirKey, DEFAULT_MODULES_DIR_NAME).replace('/', sep);\n defaultHomeLibDirPath = String.format(\"${%s}/%s\", homeDirKey, DEFAULT_LIB_DIR_NAME).replace('/', sep);\n }", "public ApplicationContext() {\n FileInputStream in;\n props = new Properties();\n try {\n in = new FileInputStream(\"gamesettings.properties\");\n props.load(in);\n } catch (FileNotFoundException ex) {\n props.setProperty(\"name\", \"Player\");\n props.setProperty(\"url\", \"0.0.0.0\");\n \n } catch (IOException ex) {\n props.setProperty(\"name\", \"Player\");\n props.setProperty(\"url\", \"0.0.0.0\");\n }\n }", "@Test\n public void contextLoad() throws Exception {\n testCase1();\n }", "static Application getContext() {\n if (ctx == null)\n // TODO: 2019/6/18\n// throw new RuntimeException(\"please init LogXixi\");\n return null;\n else\n return ctx;\n }", "public void init() {\n\n\t\tString rootdir = null;\n\t\ttry {\n\t\t\trootdir = ServletActionContext.getServletContext().getRealPath(\"/\");\n\t\t} catch (Exception ex) {\n\n\t\t}\n\n\t\tif (rootdir == null) {\n\t\t\trootdir = \"/Users/huangic/Documents/jetty-6.1.22/webapps/TransWeb\";\n\t\t}\n\n\t\tlogger.debug(rootdir);\n\t\tString classesdir = rootdir + \"/WEB-INF/classes/\";\n\t\tthis.xmlBatchRule = ReadXML(classesdir\n\t\t\t\t+ \"applicationContext-BatchRule.xml\");\n\t\tthis.xmlDB = ReadXML(classesdir + \"applicationContext-DB.xml\");\n\t\tthis.xmlSystem = ReadXML(classesdir + \"applicationContext-system.xml\");\n\n\t}", "public void contextInitialized(ServletContextEvent event) {\n\t\tthis.contextLoader = createContextLoader();\n\t\tif (this.contextLoader == null) {\n\t\t\tthis.contextLoader = this;\n\t\t}\n\t\tthis.contextLoader.initWebApplicationContext(event.getServletContext());\n\t\tUserBuffer.getInstance();\n\t}", "protected void init()\n {\n context.setConfigured(false);\n ok = true;\n\n if (!context.getOverride())\n {\n processContextConfig(\"context.xml\", false);\n processContextConfig(getHostConfigPath(org.apache.catalina.startup.Constants.HostContextXml), false);\n }\n // This should come from the deployment unit\n processContextConfig(context.getConfigFile(), true);\n }", "public MyApp() {\n sContext = this;\n }", "public Context getApplicationContext();", "private AppContext()\n {\n }", "private DiaryApplication getApp() {\n ServletContext application = (ServletContext) context.getMessageContext().get(MessageContext.SERVLET_CONTEXT);\n synchronized (application) {\n DiaryApplication diaryApp = (DiaryApplication) application.getAttribute(\"diaryApp\");\n if (diaryApp == null) {\n try {\n diaryApp = new DiaryApplication();\n diaryApp.setAllPath(application.getRealPath(\"WEB-INF/bookings.xml\"), application.getRealPath(\"WEB-INF/students.xml\"), application.getRealPath(\"WEB-INF/tutors.xml\"));\n application.setAttribute(\"diaryApp\", diaryApp);\n } catch (JAXBException ex) {\n Logger.getLogger(soapService.class.getName()).log(Level.SEVERE, null, ex);\n } catch (IOException ex) {\n Logger.getLogger(soapService.class.getName()).log(Level.SEVERE, null, ex);\n }\n }\n return diaryApp;\n }\n }", "private AppConfigLoader() {\r\n\r\n\t\tProperties appConfigPropertySet = new Properties();\r\n\t\tProperties envConfigPropertySet = new Properties();\r\n\r\n\t\ttry {\r\n\r\n\t\t\t// read properties file\r\n\t\t\tInputStream appConfigPropertyStream = AppConfigLoader.class\r\n\t\t\t\t\t.getResourceAsStream(\"/config/baseAppConfig.properties\");\r\n\t\t\tappConfigPropertySet.load(appConfigPropertyStream);\r\n\r\n\t\t\tInputStream envConfigPropertyStream = null;\r\n\r\n\t\t\t// check if current environment is defined (QA, Integration or Staging)\r\n\t\t\tif (System.getProperty(\"environment\") != null) {\r\n\t\t\t\tenvConfigPropertyStream = AppConfigLoader.class\r\n\t\t\t\t\t\t.getResourceAsStream(\"/config/\" + System.getProperty(\"environment\") + \"/appConfig.properties\");\r\n\t\t\t\tSystem.out.println(\"********'ENVIRONMENT Details taken from Runtime'********\");\r\n\t\t\t\tSystem.out.println(\"********'\" + System.getProperty(\"environment\") + \" ENVIRONMENT'********\");\r\n\t\t\t\tenvironment = System.getProperty(\"environment\");\r\n\t\t\t} else {\r\n\t\t\t\tenvConfigPropertyStream = AppConfigLoader.class.getResourceAsStream(\r\n\t\t\t\t\t\t\"/config/\" + appConfigPropertySet.getProperty(\"CurrentEnvironment\") + \"/appConfig.properties\");\r\n\t\t\t\tSystem.out.println(\"********'ENVIRONMENT Details taken from Baseapp config property file'********\");\r\n\t\t\t\tSystem.out.println(\r\n\t\t\t\t\t\t\"********'\" + appConfigPropertySet.getProperty(\"CurrentEnvironment\") + \" ENVIRONMENT'********\");\r\n\t\t\t\tenvironment = appConfigPropertySet.getProperty(\"CurrentEnvironment\");\r\n\t\t\t}\r\n\r\n\t\t\tenvConfigPropertySet.load(envConfigPropertyStream);\r\n\r\n\t\t\tthis.sampleURL = envConfigPropertySet.getProperty(\"SampleUrl\");\r\n\t\t\tthis.sampleAPIURL = envConfigPropertySet.getProperty(\"SampleAPIUrl\");\r\n\r\n\t\t\tthis.sampleDbConnectionString = envConfigPropertySet.getProperty(\"SampleConnectionString\");\r\n\r\n\t\t\tenvConfigPropertyStream.close();\r\n\t\t\tappConfigPropertyStream.close();\r\n\r\n\t\t} catch (IOException e) {\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t}", "private ApplicationContext()\n\t{\n\t}", "public static void initApplicationContext(Context appContext) {\n // Conceding that occasionally in tests, native is loaded before the browser process is\n // started, in which case the browser process re-sets the application context.\n assert mApplicationContext == null || mApplicationContext == appContext ||\n ((ContextWrapper)mApplicationContext).getBaseContext() == appContext;\n initJavaSideApplicationContext(appContext);\n }", "public TestGenericWebXmlContextLoader() {\r\n\t\tsuper(\"/src/main/wepapp\", false);\r\n\t}", "void setAppCtx(ApplicationContext appCtx);", "public static ApplicationContext getApplicationContext() {\n return appContext;\n }", "@Override\n public void onApplicationEvent(ContextRefreshedEvent event) {\n if(event.getApplicationContext().getDisplayName().equals(\"Root WebApplicationContext\")){\n System.out.println(\"避免spring-servlet.xml跟appicationContext.xml两次加载\");\n }\n if(event.getApplicationContext().getParent()==null){\n System.out.println(\"执行context上下文初始化\");\n ApplicationContextUtil.instance.init(event.getApplicationContext());\n }\n }", "public static void init(@NonNull final Context context) {\n BlankjUtils.sApplication = (Application) context.getApplicationContext();\n }", "@Override\n protected void configure() {\n bind(ApplicationContext.class).toInstance(ctxt);\n }", "protected void init() { \n ServletContext servletContext = getServletContext();\n applicationContext = WebApplicationContextUtils.getWebApplicationContext(servletContext);\n\n String names[] = applicationContext.getBeanDefinitionNames();\n\n for (String name : names) {\n System.out.println(\"name:\" + name);\n }\n }", "private static void assertContextInjected() {\n if (applicationContext == null) {\n throw new IllegalStateException(\"applicaitonContext attribute is not injected, please enter applicationContext\" +\n \"Define SpringContextHolder in .xml or register SpringContextHolder in SpringBoot startup class.\");\n }\n }", "@Override\n public void init() {\n ServletContext context = getServletContext();\n KeyLoader loader = new KeyLoader();\n\n context.setAttribute(\"translateKey\", loader.getKey(TRANSLATE));\n context.setAttribute(\"authKey\", loader.getKeyBytes(AUTH));\n context.setAttribute(\"servletRoles\", getServletRoles());\n }", "Map<String, Object> getContext();", "private AnnotationConfigWebApplicationContext getGlobalApplicationContext() {\r\n\t\tAnnotationConfigWebApplicationContext rootContext = new AnnotationConfigWebApplicationContext();\r\n\t\t//rootContext.register(ApplicationConfig.class);\r\n\t\trootContext.register(new Class[] {ApplicationConfig.class});\r\n\t\treturn rootContext;\r\n\t}", "@Override\n\tpublic void contextInitialized(ServletContextEvent ctx) {\n\t\tDBConnectionPool.init();\n//\t\tConfig.loadConfig();\n\t}", "private Context getApplicationContext() {\n\t\treturn this.cordova.getActivity().getApplicationContext();\n\t}", "private Context getApplicationContext() {\n\t\treturn this.cordova.getActivity().getApplicationContext();\n\t}", "public static Context getApplicationContext() { return mApplicationContext; }", "@DisplayName(\"Load context\")\n\t@Test\n\tvoid testContext() {\n\t\tLOGGER.info(\"Context loaded successfully\");\n\t\tAssertions.assertTrue(true);\n\t}", "void injectorClassLoader() {\n\t\t//To get the package name\n\t\tString pkgName = context.getPackageName();\n\t\t//To get the context\n\t\tContext contextImpl = ((ContextWrapper) context).getBaseContext();\n\t\t//Access to the Activity of the main thread\n\t\tObject activityThread = null;\n\t\ttry {\n\t\t\tactivityThread = Reflection.getField(contextImpl, \"mMainThread\");\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\t//Get package container\n\t\tMap mPackages = null;\n\t\ttry {\n\t\t\tmPackages = (Map) Reflection.getField(activityThread, \"mPackages\");\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\t//To obtain a weak reference object, the standard reflection\n\t\tWeakReference weakReference = (WeakReference) mPackages.get(pkgName);\n\t\tif (weakReference == null) {\n\t\t\tlog.e(\"loadedApk is null\");\n\t\t} else {\n\t\t\t//Get apk need to be loaded\n\t\t\tObject loadedApk = weakReference.get();\n\t\t\t\n\t\t\tif (loadedApk == null) {\n\t\t\t\tlog.e(\"loadedApk is null\");\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tif (appClassLoader == null) {\n\t\t\t\t//Access to the original class loader\n\t\t\t\tClassLoader old = null;\n\t\t\t\ttry {\n\t\t\t\t\told = (ClassLoader) Reflection.getField(loadedApk,\n\t\t\t\t\t\t\t\"mClassLoader\");\n\t\t\t\t} catch (Exception e) {\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t\t//According to the default class loader instantiate a plug-in class loader\n\t\t\t\tappClassLoader = new SyknetAppClassLoader(old, this);\n\t\t\t}\n\t\t\t//Replace the new plug-in loader loader by default\n\t\t\ttry {\n\t\t\t\tReflection.setField(loadedApk, \"mClassLoader\", appClassLoader);\n\t\t\t} catch (Exception e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t}", "public static ApplicationContext getApplicationContext() {\r\n\t\treturn applicationContext;\r\n\t}", "@Provides\n @Singleton\n @ApplicationScope\n public Context provideApplicationContext() {\n return mApp.getApplicationContext();\n }", "public void testContextManager() throws Exception {\n System.out.println(\"testContextManager\");\n \n // init the session information\n ThreadsPermissionContainer permissions = new ThreadsPermissionContainer();\n SessionManager.init(permissions);\n UserStoreManager userStoreManager = new UserStoreManager();\n UserSessionManager sessionManager = new UserSessionManager(permissions,\n userStoreManager);\n LoginManager.init(sessionManager,userStoreManager);\n // instanciate the thread manager\n CoadunationThreadGroup threadGroup = new CoadunationThreadGroup(sessionManager,\n userStoreManager);\n \n // add a user to the session for the current thread\n RoleManager.getInstance();\n \n InterceptorFactory.init(permissions,sessionManager,userStoreManager);\n \n // add a new user object and add to the permission\n Set set = new HashSet();\n set.add(\"test\");\n UserSession user = new UserSession(\"test1\", set);\n permissions.putSession(new Long(Thread.currentThread().getId()),\n new ThreadPermissionSession(\n new Long(Thread.currentThread().getId()),user));\n \n \n NamingDirector.init(threadGroup);\n \n Context context = new InitialContext();\n \n context.bind(\"java:comp/env/test\",\"fred\");\n context.bind(\"java:comp/env/test2\",\"fred2\");\n \n if (!context.lookup(\"java:comp/env/test\").equals(\"fred\")) {\n fail(\"Could not retrieve the value for test\");\n }\n if (!context.lookup(\"java:comp/env/test2\").equals(\"fred2\")) {\n fail(\"Could not retrieve the value for test2\");\n }\n System.out.println(\"Creating the sub context\");\n Context subContext = context.createSubcontext(\"java:comp/env/test3/test3\");\n System.out.println(\"Adding the binding for bob to the sub context\");\n subContext.bind(\"bob\",\"bob\");\n System.out.println(\"Looking up the binding for bob on the sub context.\");\n Object value = subContext.lookup(\"bob\");\n System.out.println(\"Object type is : \" + value.getClass().getName());\n if (!value.equals(\"bob\")) {\n fail(\"Could not retrieve the value bob\");\n }\n if (!context.lookup(\"java:comp/env/test3/test3/bob\").equals(\"bob\")) {\n fail(\"Could not retrieve the value bob\");\n }\n \n ClassLoader loader = new URLClassLoader(new URL[0]);\n ClassLoader original = Thread.currentThread().getContextClassLoader();\n Thread.currentThread().setContextClassLoader(loader);\n NamingDirector.getInstance().initContext();\n \n context.bind(\"java:comp/env/test5\",\"fred5\");\n if (!context.lookup(\"java:comp/env/test5\").equals(\"fred5\")) {\n fail(\"Could not retrieve the value fred5\");\n }\n \n Thread.currentThread().setContextClassLoader(original);\n \n try{\n context.lookup(\"java:comp/env/test5\");\n fail(\"Failed retrieve a value that should not exist\");\n } catch (NameNotFoundException ex) {\n // ignore\n }\n \n Thread.currentThread().setContextClassLoader(loader);\n \n NamingDirector.getInstance().releaseContext();\n \n try{\n context.lookup(\"java:comp/env/test5\");\n fail(\"Failed retrieve a value that should not exist\");\n } catch (NameNotFoundException ex) {\n // ignore\n }\n Thread.currentThread().setContextClassLoader(original);\n System.out.println(\"Add value 1\");\n context.bind(\"basic\",\"basic\");\n System.out.println(\"Add value 2\");\n context.bind(\"basic2/bob\",\"basic2\");\n if (context.lookup(\"basic\") != null) {\n fail(\"Could not retrieve the basic value from the [\" + \n context.lookup(\"basic\") + \"]\");\n }\n if (context.lookup(\"basic2/bob\") != null) {\n fail(\"Could not retrieve the basic value from the JNDI [\" +\n context.lookup(\"basic2/bob\") + \"]\");\n }\n \n try {\n context.bind(\"java:network/env/test\",\"fred\");\n fail(\"This should have thrown as only relative urls can be used \" +\n \"JNDI\");\n } catch (NamingException ex) {\n // ignore\n }\n \n try {\n context.unbind(\"java:network/env/test\");\n fail(\"This should have thrown as only relative urls can be used \" +\n \"JNDI\");\n } catch (NamingException ex) {\n // ignore\n }\n context.rebind(\"basic\",\"test1\");\n context.rebind(\"basic2/bob\",\"test2\");\n \n if (context.lookup(\"basic\") != null) {\n fail(\"Could not retrieve the basic value from the JNDI\");\n }\n if (context.lookup(\"basic2/bob\") != null) {\n fail(\"Could not retrieve the basic value from the JNDI\");\n }\n \n context.unbind(\"basic\");\n context.unbind(\"basic2/bob\");\n \n try{\n context.lookup(\"basic2/bob\");\n fail(\"The basic bob value could still be found\");\n } catch (NameNotFoundException ex) {\n // ignore\n }\n \n NamingDirector.getInstance().shutdown();\n }", "public CH340Application() {\n sContext = this;\n }", "public FetchingAllDataModel() {\n\n context = AppController.getInstance().getApplicationContext();\n }", "Context context();", "Context context();", "public interface BootLoaderManager {\n\n /**\n * 注入上下文\n * @param atlasWrapperApplicationContext\n */\n BootLoaderManager attachContext(AtlasWrapperApplicationContext atlasWrapperApplicationContext);\n\n /**\n * 获取上下文环境\n * @return\n */\n AtlasWrapperApplicationContext getContext();\n\n /**\n * 启动加载\n */\n void load();\n}", "private DatabaseContext() {\r\n datastore = createDatastore();\r\n init();\r\n }", "public void init(MailetContext context);", "@Override\n\tpublic void onCreate() {\n\t\tsuper.onCreate();\n\t\tcontext = getApplicationContext();\n\t\t\n\t\tApplicationContextUtils.init(context);\n\t}", "@Override\n public Context getApplicationContext() {\n return mView.get().getApplicationContext();\n }", "public void initRootAppVars(){\n\t \ttry{\n\t \t\tInputStream is = this.getResources().openRawResource(R.raw.config);\n\t\t\t\tbyte [] buffer = new byte[is.available()];\n\t\t\t\twhile (is.read(buffer) != -1);\n\t\t\t\tString json = new String(buffer);\n\t JSONObject obj = new JSONObject(json);\n\t \n\t //appData..\n\t JSONObject rootObj = obj.getJSONObject(\"appData\");\n \t\n \t//init current app\n\t \t currentApp = new Obj_App(rootObj.getString(\"appGuid\"));\n \tcurrentApp.setApiKey(rootObj.getString(\"appApiKey\"));\n\t \t currentApp.setDataUrl(rootObj.getString(\"appDataURL\"));\n \t\n \t }catch (Exception je){\n \t \tLog.i(\"ZZ\", \"AppDelegate:initAppVars: ERROR: \" + je.getMessage()); \n\t }\n\t\t}", "public void init(){\n\t\tcfg = new Configuration();\r\n\t\tcfg.setServletContextForTemplateLoading(getServletContext(), \"WEB-INF/templates\");\r\n }", "public void init()\n {\n context = getServletContext();\n parameters = (Siu_ContainerLabel)context.getAttribute(\"parameters\");\n }", "protected void initialize(ExternalContext context)\n {\n }", "static ClassLoader contextClassLoader() {\n return Thread.currentThread().getContextClassLoader();\n }", "public ApplicationContext getApplicationContext()\n {\n return this.applicationContext;\n }", "public ApplicationContext getApplicationContext() {\n return applicationContext;\n }", "public static void load(Params params) {\n\n\t\tGlobalContext.init(params);\n\n\t\t// Loads the test environment\n\t\tloadTestEnv();\n\n\t\t// Loads the object repository\n\t\tloadObjectRepository();\n\n\t\t// Loads the i18N\n\t\tloadInternationalization();\n\t}", "public abstract Context context();", "@Override\r\n\tpublic void onCreate() {\n\t\tsuper.onCreate();\r\n\t\tinstance = this;\r\n\t\tAppConfigMrg.load(getApplicationContext());\r\n\t}", "private AceContext()\n {\n //load from file\n File f = new File(ServerSettings.FILE_NAME);\n if (!f.exists())\n {\n ServerSettings.setDefaults();\n }\n\n// setWorkingParent( ServerSettings.getInstance().getProperty(ServerSettings.WORKING_PARENT));\n// setCommonDir( ServerSettings.getInstance().getProperty(ServerSettings.COMMON_DIR));\n// setApplicationPath( ServerSettings.getInstance().getProperty(ServerSettings.APP_EXE));\n }", "@Override\n public void onCreate(Bundle savedInstanceState) {\n super.onCreate(savedInstanceState);\n context=getContext();\n\n }", "public void contextInitialized(ServletContextEvent servletcontextevent) \n\t {\n\t\t JobContext.getInstance().setContext(servletcontextevent.getServletContext()); \n\t }", "public static void initialize(Context context) throws LogonCoreException {\n appContext = context;\n try {\n createOnlineManager(context);\n } catch (LogonCoreException e) {\n e.printStackTrace();\n }\n getTheData();\n }", "private void setupContext() throws PackageManager.NameNotFoundException {\n when(context.getPackageName()).thenReturn(\"com.owlr.test\");\n when(context.getPackageManager()).thenReturn(packageManager);\n when(packageManager.getApplicationInfo(\"com.owlr.test\",\n PackageManager.GET_META_DATA)).thenReturn(applicationInfo);\n applicationInfo.metaData = bundle;\n }", "@Override\n public Context getContext() {\n return this.getApplicationContext();\n }", "public static void setupContext(ServletContext context) {\n \t//I don't need this dropdown list. bguo.\n// ApplicationContext ctx = WebApplicationContextUtils.getRequiredWebApplicationContext(context);\n// LookupManager mgr = (LookupManager) ctx.getBean(\"lookupManager\");\n//\n// // get list of possible roles\n// context.setAttribute(RoleConstants.AVAILABLE_ROLES, mgr.getAllRoles());\n// log.debug(\"Drop-down initialization complete [OK]\");\n }", "Context createContext();", "Context createContext();", "public void initializeContext(Context context) {\n this.context = context;\n }", "@Override\n\tpublic void contextInitialized(ServletContextEvent arg0) {\n\t\tConnectionDB.getInstance();\n\t}", "public void initApplicationContext()\r\n/* 32: */ throws BeansException\r\n/* 33: */ {\r\n/* 34:103 */ super.initApplicationContext();\r\n/* 35:104 */ registerHandlers(this.urlMap);\r\n/* 36: */ }", "public static void setApplicationContext( ApplicationContext context ){\n\t\t\tctx = context;\n//\t\telse{\n//\t\t\tSystem.out.println(\"Error, ApplicationContext already has been set\");\n//\t\t}\n\t}", "public String getApplicationContext()\n {\n return configfile.getApplicationPath(getASPManager().getCurrentHostIndex());\n }", "@Override\n public void initialize(ConfigurableApplicationContext applicationContext) {\n\n System.out.println(\"========ApplicationContextInitializer===================\");\n\n ConfigurableEnvironment environment = applicationContext.getEnvironment();\n\n\n MutablePropertySources propertySources = environment.getPropertySources();\n\n // 模拟远程拉配置信息\n Map<String, Object> config = ConfigServer.getRemoteConfig();\n\n MapPropertySource propertySource = new MapPropertySource(\"test-config\", config);\n propertySources.addFirst(propertySource);\n }", "public static void load() {\n try {\n File confFile = SessionService.getConfFileByPath(Const.FILE_CONFIGURATION);\n UtilSystem.recoverFileIfRequired(confFile);\n // Conf file doesn't exist at first launch\n if (confFile.exists()) {\n // Now read the conf file\n InputStream str = new FileInputStream(confFile);\n try {\n properties.load(str);\n } finally {\n str.close();\n }\n }\n } catch (Exception e) {\n Log.error(e);\n Messages.showErrorMessage(114);\n }\n }", "public static synchronized void initialize(Context context) {\n instance.context = context;\n initInternal();\n }", "public static void load() {\n }", "private TestContext() {\n\t\tinitLog4j();\n\t\tloadConfig();\n\t}", "private LifecycleHolder get(Context context) {\n if (context == null) {\n throw new IllegalArgumentException(\"You cannot start a load on a null Context\");\n } else if (!isOnMainThread() && !(context instanceof Application)) {\n if (context instanceof FragmentActivity) {\n return get((FragmentActivity) context);\n } else if (context instanceof Activity) {\n return get((Activity) context);\n } else if (context instanceof ContextWrapper) {\n return get(((ContextWrapper) context).getBaseContext());\n }\n }\n\n return getApplicationLifecycle();\n }", "public static ApplicationContext getContext() {\n if (context == null) {\n CompilerExtensionRegistry.setActiveExtension( OTA2CompilerExtensionProvider.OTA2_COMPILER_EXTENSION_ID );\n }\n return context;\n }", "@Override\n\tpublic void onApplicationEvent(ContextRefreshedEvent arg0) {\n\t\tinitData();\n\t}", "@Override\n\tpublic void onApplicationEvent(ContextRefreshedEvent arg0) {\n\t\tinitData();\n\t}", "static void setActiveContext(ApplicationContext context) {\n SchemaCompilerApplicationContext.context = context;\n }", "@Override\r\n\tpublic void contextInitialized(ServletContextEvent arg0) {\n\t\tCptedController.getInstance();\r\n\t}", "EnvironmentLoader getEnvironmentLoader();", "@Test\n\tpublic void contextLoads() {\n\t\tSystem.out.println(redisService.get(\"91c72c29-cde5-4d09-8318-31b22880d1e9\"));\n\t\t//System.out.println(u);\n\t}", "@BeforeClass\n\tpublic static void init() {\n\t\tcontext = new AnnotationConfigApplicationContext();\n\t\tcontext.scan(\"com.shuler.shoppingbackend\");\n\t\tcontext.refresh();\n\t\tcategoryDAO = (CategoryDAO) context.getBean(\"categoryDAO\");\n\t}", "public void activate(BundleContext context) {\r\n\r\n // define the global ServiceRegistryAccessFactory for components and GUI code\r\n // TODO initialize from another location?\r\n ServiceRegistry.setAccessFactory(new OsgiServiceRegistryAccessFactory(context));\r\n\r\n bootstrapSettings = BootstrapConfiguration.getInstance();\r\n\r\n initializeProfileDirFromBootstrapSettings();\r\n initializeConfigurablePaths();\r\n loadRootConfiguration(false);\r\n initializeGeneralSettings();\r\n\r\n // initialize parent temp directory root\r\n initializeParentTempDirectoryRoot(generalSettings.getTempDirectoryOverride());\r\n\r\n initializeInstanceTempDirectoryRoot();\r\n\r\n if (PROPERTY_SUBSTITUTION_MECHANISM_ENABLED) {\r\n initializePropertySubstitution();\r\n }\r\n }", "@Override\n\tpublic void onStartup(ServletContext servletContext)\n\t\t\tthrows ServletException {\n\t\tsuper.onStartup(servletContext);//master line where whole framework works\n\t\t//configure global objects/tasks if required\n\t}", "protected void initApplicationContext() throws ApplicationContextException {\n try {\n if (log.isDebugEnabled()) {\n log.debug(\"Starting struts-menu initialization\");\n }\n ServletContext ctx = this.getServletContext();\n Config configForInit = new Config();\n \t\tconfigForInit.setConfigParam(ctx.getRealPath(menuConfig));\n \t\ttry {\n \t\t\tconfigForInit.init();\n \t\t} catch (LoadableResourceException e1) {\n \t\t\t// TODO Auto-generated catch block\n \t\t\te1.printStackTrace();\n \t\t} catch (IOException e1) {\n \t\t\t// TODO Auto-generated catch block\n \t\t\te1.printStackTrace();\n \t\t} catch (SAXException e1) {\n \t\t\t// TODO Auto-generated catch block\n \t\t\te1.printStackTrace();\n \t\t} catch (SQLException e1) {\n \t\t\t// TODO Auto-generated catch block\n \t\t\te1.printStackTrace();\n \t\t}\n \t\tParser parse = null;\n \t\ttry {\n \t\t\tparse = configForInit.getParser();\n \t\t} catch (Exception e) {\n \t\t\t// TODO Auto-generated catch block\n \t\t\te.printStackTrace();\n \t\t}\n\n \t\tMenuRepository repository = new MenuRepository();\n \t\trepository.setLoadParam(menuConfig);\n \t\trepository.setServletContext(ctx);\n \t\tparse.init(repository);\n\n \t\ttry {\n \t\t\tparse.load();\n ctx.setAttribute(MenuRepository.MENU_REPOSITORY_KEY, repository);\n\n if (log.isDebugEnabled()) {\n log.debug(\"struts-menu initialization successful\");\n }\n } catch (LoadableResourceException lre) {\n throw new ServletException(\"Failure initializing struts-menu: \" +\n lre.getMessage());\n }\n } catch (Exception ex) {\n throw new ApplicationContextException(\"Failed to initialize Struts Menu repository\",\n ex);\n }\n }", "@Test\n\tpublic void testContextShouldInitalizeChildContexts() {\n\t\tassertThat(Foo.getInstanceCount()).isEqualTo(1);\n\t\tApplicationContext ctx = springClientFactory.getContext(\"testspec\");\n\n\t\tassertThat(Foo.getInstanceCount()).isEqualTo(1);\n\t\tFoo foo = ctx.getBean(\"foo\", Foo.class);\n\t\tassertThat(foo).isNotNull();\n\t}", "protected Application getApplication() {\r\n\t\treturn application;\r\n\t}", "public synchronized static void init(Context ctx) {\n context = ctx;\n prefs = context.getSharedPreferences(APP, Context.MODE_PRIVATE);\n editor = prefs.edit();\n }", "private static void load(){\n }", "private void loadAppState(Context context) {\n SharedPreferences settings = PreferenceManager.getDefaultSharedPreferences(context);\n mTwoPane = settings.getBoolean(PREF_TWO_PANE, false);\n LogHelper.v(LOG_TAG, \"Loading state.\");\n }", "private void init(File contextXml) {\n //this.contextXml = contextXml;\n try {\n getContext();\n } catch (ConfigurationException e) {\n LOGGER.log(Level.INFO, null, e);\n }\n if (contextDataObject == null) {\n try {\n contextDataObject = DataObject.find(FileUtil.toFileObject(FileUtil.normalizeFile(contextXml)));\n contextDataObject.addPropertyChangeListener(this);\n } catch(DataObjectNotFoundException donfe) {\n LOGGER.log(Level.FINE, null, donfe);\n }\n }\n }", "public void initialize(Context context) {\n Validate.checkInternetPermissionAndThrow(context);\n this.applicationContext = context.getApplicationContext();\n Utility.getThreadPoolExecutor().execute(new Runnable() {\n public void run() {\n ExperimentationConfiguration ec = ExperimentationConfigurator.this.getExperimentationConfiguration();\n if (!ec.exists() || ec.isStale()) {\n ExperimentationConfigurator.this.downloadExperimentationConfiguration(ec.getUnitID());\n }\n }\n });\n }", "@Before\n public void init() throws IOException {\n ApplicationContext context = new ClassPathXmlApplicationContext(\"config/applicationContext.xml\");\n //this.test();\n bookMapper = context.getBean(BookMapper.class);\n }", "public synchronized static void load()\n throws Exception\n { \n if (!isBootstrap) {\n String basedir = System.getProperty(JVM_OPT_BOOTSTRAP);\n load(basedir);\n SystemProperties.initializeProperties(\"com.iplanet.am.naming.url\",\n SystemProperties.getServerInstanceName() + \"/namingservice\");\n }\n }", "public void init(PageContext context) {\n request = (HttpServletRequest) context.getRequest();\n response = (HttpServletResponse) context.getResponse();\n session = context.getSession();\n application = context.getServletContext();\n out = context.getOut();\n }" ]
[ "0.7425912", "0.70467246", "0.6720701", "0.66827977", "0.6622667", "0.6511458", "0.64990187", "0.6479813", "0.6346124", "0.63071865", "0.6281154", "0.6213119", "0.61935574", "0.6162307", "0.6151225", "0.6148328", "0.6143893", "0.61345196", "0.6029685", "0.6013023", "0.59699726", "0.59672624", "0.5951269", "0.59252286", "0.5913374", "0.59079945", "0.5892922", "0.58894646", "0.58785605", "0.5861712", "0.58349484", "0.5826292", "0.5816129", "0.5810083", "0.5810083", "0.58064634", "0.58051825", "0.57984406", "0.57841223", "0.5769245", "0.57640296", "0.57237667", "0.5722774", "0.5719283", "0.5719283", "0.5714548", "0.5707804", "0.57004356", "0.5691498", "0.56898874", "0.5688629", "0.5685961", "0.5677742", "0.5672076", "0.566419", "0.56632334", "0.5661743", "0.56552523", "0.55973125", "0.55946964", "0.5592196", "0.5583841", "0.55768925", "0.5575098", "0.5571835", "0.55706745", "0.557003", "0.55571806", "0.55571806", "0.5548367", "0.55160934", "0.5515183", "0.5512187", "0.55097264", "0.55058575", "0.55035365", "0.5501681", "0.55003583", "0.54990387", "0.5495939", "0.54954106", "0.54910624", "0.54910624", "0.5485431", "0.5482634", "0.5478908", "0.54647464", "0.5463793", "0.54621273", "0.54512334", "0.5444384", "0.54350275", "0.54323906", "0.54297274", "0.5422695", "0.541992", "0.54017586", "0.5393135", "0.5390387", "0.53882134", "0.53860044" ]
0.0
-1
Created by walter on 16/12/28.
public interface ICompanyInfo { void uploadFace(File file, String uid, String hashid, int type); void companyInfo(String uid, String company_name, String company_tel, String company_img, String company_year, String work_year, String work_money, String company_work); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void perish() {\n \n }", "protected boolean func_70814_o() { return true; }", "@Override\n public void func_104112_b() {\n \n }", "@Override\n\tpublic void sacrifier() {\n\t\t\n\t}", "@Override\n\tpublic void grabar() {\n\t\t\n\t}", "private stendhal() {\n\t}", "public final void mo51373a() {\n }", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "private void m50366E() {\n }", "public void method_4270() {}", "@Override\n\tprotected void interr() {\n\t}", "private void kk12() {\n\n\t}", "public void gored() {\n\t\t\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "private void poetries() {\n\n\t}", "public void mo38117a() {\n }", "@Override\n\tpublic void nadar() {\n\t\t\n\t}", "@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\n\tpublic void jugar() {\n\t\t\n\t}", "@Override\n public int describeContents() { return 0; }", "@Override\n\tpublic void anular() {\n\n\t}", "private static void cajas() {\n\t\t\n\t}", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}", "@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}", "private void strin() {\n\n\t}", "@Override\n public void init() {\n\n }", "@Override\n\tpublic void ligar() {\n\t\t\n\t}", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\n\tpublic void entrenar() {\n\t\t\n\t}", "public void mo4359a() {\n }", "public abstract void mo70713b();", "@Override\n\tpublic void one() {\n\t\t\n\t}", "private void init() {\n\n\t}", "@Override\n\tprotected void getExras() {\n\n\t}", "public void mo21877s() {\n }", "@Override\n public int retroceder() {\n return 0;\n }", "@Override\n\tpublic void nghe() {\n\n\t}", "@Override\n public void init() {\n }", "private void m50367F() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void m23075a() {\n }", "@Override\r\n\tpublic void rozmnozovat() {\n\t}", "@Override\r\n\tpublic void init() {}", "public abstract void mo56925d();", "public void mo12628c() {\n }", "@Override\n protected void init() {\n }", "@Override\r\n\tprotected void doF8() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\n public void init() {}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\r\n\tprotected void doF4() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "public void mo21779D() {\n }", "@Override\r\n\tpublic void init()\r\n\t{\n\t}", "@Override\n protected void initialize() {\n\n \n }", "@Override\n void init() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n\tprotected void initialize() {\n\n\t}", "@Override\n\tpublic void init() {\n\t}", "@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}", "@Override\n public void init() {\n\n }", "@Override\n public void init() {\n\n }", "protected boolean func_70041_e_() { return false; }", "public void mo6081a() {\n }", "public void mo21825b() {\n }", "protected void mo6255a() {\n }", "public final void mo91715d() {\n }", "@Override public int describeContents() { return 0; }", "public void mo21878t() {\n }", "static void feladat4() {\n\t}", "@Override\n\tpublic void einkaufen() {\n\t}", "public void mo115190b() {\n }", "public void skystonePos4() {\n }", "@Override\n\tpublic void gravarBd() {\n\t\t\n\t}" ]
[ "0.5755353", "0.56748384", "0.5673642", "0.5653242", "0.5631448", "0.5614804", "0.5607373", "0.56003034", "0.5586491", "0.5537385", "0.5533531", "0.55246556", "0.5489902", "0.5478518", "0.5478518", "0.54739124", "0.5462901", "0.5455239", "0.54417217", "0.54174465", "0.5406196", "0.5406196", "0.5406196", "0.5406196", "0.5406196", "0.54017794", "0.5397171", "0.53951454", "0.53842676", "0.5373575", "0.53725606", "0.5354369", "0.5329021", "0.53280056", "0.53238714", "0.5317726", "0.53146577", "0.53146577", "0.5307753", "0.5304788", "0.53044474", "0.5303668", "0.5296265", "0.52720565", "0.52682936", "0.52656615", "0.52644604", "0.52573836", "0.52483857", "0.5245143", "0.5245143", "0.5245143", "0.5245143", "0.5245143", "0.5245143", "0.5245143", "0.5244911", "0.52435803", "0.5241224", "0.5232285", "0.52272797", "0.52249193", "0.5219528", "0.5218442", "0.5218442", "0.5218442", "0.5218041", "0.52135074", "0.52135074", "0.52135074", "0.52070606", "0.52026564", "0.52026564", "0.52026564", "0.51844364", "0.5183877", "0.5183572", "0.51800674", "0.51798695", "0.51798695", "0.51798695", "0.51798695", "0.51798695", "0.51798695", "0.51791936", "0.5177291", "0.5174721", "0.5167577", "0.5167577", "0.5167203", "0.5164317", "0.5160416", "0.51585364", "0.515396", "0.51471674", "0.514644", "0.51442724", "0.5142329", "0.514184", "0.51407826", "0.5140052" ]
0.0
-1
TODO: for this test to run, update home to create session from new configuration...
public static void main(String[] args) { SectionHome sectionHome = new SectionHome(); Section section = new Section(); section.setSectionName("test_section"); sectionHome.persist(section); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void setupSession() {\n // TODO Retreived the cached Evernote AuthenticationResult if it exists\n// if (hasCachedEvernoteCredentials) {\n// AuthenticationResult result = new AuthenticationResult(authToken, noteStoreUrl, webApiUrlPrefix, userId);\n// session = new EvernoteSession(info, result, getTempDir());\n// }\n ConnectionUtils.connectFirstTime();\n updateUiForLoginState();\n }", "@Test\r\n public void testInitSession() {\r\n System.out.println(\"initSession\");\r\n assertNotNull(sm);\r\n \r\n boolean result = sm.initSession(\"test1\", programsHome, programsHome + \"files1/\", requester);\r\n assertFalse(result);\r\n \r\n result = sm.initSession(\"test2\", programsHome, programsHome + \"files2/\", requester);\r\n assertFalse(result);\r\n \r\n result = sm.initSession(\"test3\", programsHome, programsHome + \"files3/\", requester);\r\n assertFalse(result);\r\n \r\n result = sm.initSession(\"test4\", programsHome, programsHome + \"files4/\", requester);\r\n assertTrue(result);\r\n \r\n sm.removeSession(\"test4\");\r\n }", "public void startSession(){\n sessionID = client.startSession();\n \n //Get system temporary files path\n String temporaryPath = System.getProperty(\"java.io.tmpdir\").replaceAll(\"\\\\\\\\\",\"/\");\n \n //If temporary file path does not end with /, add it\n if(!temporaryPath.endsWith(\"/\"))\n temporaryPath = temporaryPath + \"/\";\n \n //Create session directory\n sessionDirectory = new File(temporaryPath+sessionID);\n sessionDirectory.mkdir();\n \n }", "private Session session(Properties props) {\n return Session.getInstance(props,\n new Authenticator() {\n protected PasswordAuthentication getPasswordAuthentication() {\n return new PasswordAuthentication(\"[email protected]\", \"happinessbarometer2014\");\n }\n }\n );\n }", "@Test\n public void testStartSession() {\n startSession();\n }", "private void doConfiguration(HttpServletRequest request, HttpSession session) {\r\n\t\tConfigurationManager configurationManager = (ConfigurationManager) getBean(\"configurationManager\");\r\n\r\n\t\tsession.setAttribute(\"showMenu\", configurationManager.isActive(\"show.menu\", false));\r\n\r\n\t\t// course\r\n\t\tsession.setAttribute(\"singleprice\", configurationManager.isActive(\"access.course.singleprice\", false));\r\n\t\tsession.setAttribute(\"usePayment\", configurationManager.isActive(\"access.course.usePayment\", true));\r\n\t\tsession.setAttribute(\"showDuration\", configurationManager.isActive(\"access.course.showDuration\", true));\r\n\t\tsession.setAttribute(\"showDescription\", configurationManager.isActive(\"access.course.showDescription\", true));\r\n\t\tsession.setAttribute(\"showDescriptionToPublic\", configurationManager.isActive(\"access.course.showDescriptionToPublic\", true));\r\n\t\tsession.setAttribute(\"showRole\", configurationManager.isActive(\"access.course.showRole\", true));\r\n\t\tsession.setAttribute(\"showType\", configurationManager.isActive(\"access.course.showType\", true));\r\n\t\tsession.setAttribute(\"showRestricted\", configurationManager.isActive(\"access.course.showRestricted\", true));\r\n\t\tsession.setAttribute(\"useServiceArea\", configurationManager.isActive(\"access.course.useServiceArea\", true));\r\n\t\tsession.setAttribute(\"showCourseName\", configurationManager.isActive(\"access.course.showCourseName\", true));\r\n\t\tsession.setAttribute(\"useAttendants\", configurationManager.isActive(\"access.course.useAttendants\", false));\r\n\t\tsession.setAttribute(\"useRegisterBy\", configurationManager.isActive(\"access.course.useRegisterBy\", true));\r\n\t\tsession.setAttribute(\"useOrganization2\", configurationManager.isActive(\"access.course.useOrganization2\", false));\r\n\t\tsession.setAttribute(\"showAttendantDetails\", configurationManager.isActive(\"access.course.showAttendantDetails\", true));\r\n\t\tsession.setAttribute(\"showAdditionalInfo\", configurationManager.isActive(\"access.course.showAdditionalInfo\", true));\r\n\t\tsession.setAttribute(\"filterlocation\", configurationManager.isActive(\"access.course.filterlocation\", false));\r\n\t\t\r\n\t\t// registration\r\n\t\tsession.setAttribute(\"canDelete\", configurationManager.isActive(\"access.registration.delete\", false));\r\n\t\tsession.setAttribute(\"userdefaults\", configurationManager.isActive(\"access.registration.userdefaults\", false));\r\n\t\tsession.setAttribute(\"emailrepeat\", configurationManager.isActive(\"access.registration.emailrepeat\", false));\r\n\t\tsession.setAttribute(\"showEmployeeFields\", configurationManager.isActive(\"access.registration.showEmployeeFields\", true));\r\n\t\tsession.setAttribute(\"showServiceArea\", configurationManager.isActive(\"access.registration.showServiceArea\", false));\r\n\t\tsession.setAttribute(\"showJobTitle\", configurationManager.isActive(\"access.registration.showJobTitle\", true));\r\n\t\tsession.setAttribute(\"showWorkplace\", configurationManager.isActive(\"access.registration.showWorkplace\", true));\r\n\t\tsession.setAttribute(\"showComment\", configurationManager.isActive(\"access.registration.showComment\", true));\r\n\t\tsession.setAttribute(\"useBirthdateForRegistration\", configurationManager.isActive(\"access.registration.useBirthdate\", false));\r\n\t\tsession.setAttribute(\"useWaitlists\", configurationManager.isActive(\"access.registration.useWaitlists\", true));\r\n\t\tsession.setAttribute(\"useParticipants\", configurationManager.isActive(\"access.registration.useParticipants\", false));\r\n\t\t\r\n\t\t// organization\r\n\t\tsession.setAttribute(\"useOrganizationType\", configurationManager.isActive(\"access.organization.useType\", false));\r\n\t\t\r\n\t\t// location\r\n\t\tsession.setAttribute(\"usePostalCode\", configurationManager.isActive(\"access.location.usePostalCode\", true));\r\n\t\t\r\n\t\t// user\r\n\t\tsession.setAttribute(\"useBirthdateForUser\", configurationManager.isActive(\"access.user.useBirthdate\", false));\r\n\t\tsession.setAttribute(\"useWebsiteForUser\", configurationManager.isActive(\"access.user.useWebsite\", false));\r\n\t\tsession.setAttribute(\"useCountryForUser\", configurationManager.isActive(\"access.user.useCountry\", false));\r\n\t\t\r\n\t\t\r\n\t\t// profile\r\n\t\tsession.setAttribute(\"showAddress\", configurationManager.isActive(\"access.profile.showAddress\", true));\r\n\t\tsession.setAttribute(\"showInvoiceaddress\", configurationManager.isActive(\"access.profile.showInvoiceaddress\", true));\r\n\r\n\t\t// lists\r\n\t\tsession.setAttribute(\"itemCount\", configurationManager.getValue(\"list.itemCount\", \"50\"));\r\n\t}", "@Before\n public void getTestSession() {\n if (sessionId == null) {\n sessionId = Util.getSessionID();\n }\n }", "static void beginNewSession() {\n SESSION_ID = null;\n Prefs.INSTANCE.setEventPlatformSessionId(null);\n\n // A session refresh implies a pageview refresh, so clear runtime value of PAGEVIEW_ID.\n PAGEVIEW_ID = null;\n }", "@Test\r\n void checkSession() {\n }", "private void refreshSession() {\n\t\ttry {\n\t\t\tAuthenticationUtils.endSession();\n\t\t\tAuthenticationUtils.startSession(endpointUser, endpointPassword);\n\t\t} catch(Throwable e) {\n\t\t\tLOG.error(\"Error refreshing session\", e);\n\t\t}\n\t}", "Session getCurrentSession();", "Session getCurrentSession();", "@Override\n\t\t\tpublic void handleNewSession() throws Exception {\n\t\t\t\t\n\t\t\t}", "public void makeSessionFile() {\n sessionData = new File(wnwData, \"session.dat\");\n try {\n sessionData.createNewFile();\n } catch (IOException e) {\n e.printStackTrace();\n }\n sessionData.setWritable(true);\n }", "@Override\n\tpublic SessionConfig getSessionConfig(String appkey) {\n\t\treturn sessionStore.getSessionConfig(appkey);\n\t}", "@Test\r\n public void testAddSimulatorToSession() {\r\n System.out.println(\"addSimulatorToSession\");\r\n assertNotNull(sm);\r\n sm.initSession(\"test4\", programsHome, programsHome + \"files4/\", requester);\r\n \r\n boolean result = sm.addSimulatorToSession(\"test4\", Simulators.NUATMOS, \"v1\", true);\r\n assertTrue(result);\r\n \r\n result = sm.addSimulatorToSession(\"test5\", Simulators.NUATMOS, \"v1\", true);\r\n assertFalse(result);\r\n \r\n sm.removeSession(\"test4\");\r\n \r\n }", "public abstract void setLocalSessionSpec(SessionSpec localSpec);", "public abstract SessionSpec generateSessionSpec() throws MsControlException;", "public void redirectToHomeSameSession() {\r\n\t\t\r\n\t\ttry{\r\n\t\twebAppDriver.get(baseUrl);\r\n\t\t}\r\n\t\tcatch(Exception e){\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t}", "private void startNewSession() {\n final FragmentTransaction ft = getFragmentManager().beginTransaction();\n Fragment sessionFragment = null;\n if (mCurrentExperiment.hasSAM()) {\n sessionFragment = new SAMSessionFragment();\n }\n // if there's not hte sam, we start directly with the NASA\n else if (mCurrentExperiment.hasNASATLX()) {\n sessionFragment = new NASATLXSessionFragment();\n }\n ft.replace(R.id.main_content_frame, sessionFragment);\n ft.commit();\n }", "Session begin();", "private static void sessionFromCurrentSession(final Context context) {\n\n \t// The session itself\n final Session newSession = Session.getInstance();\n \n // The service\n Service newService = new Service();\n newSession.setService(newService);\n\n // The shared preferences\n Preferences preferences = new Preferences(context);\n newSession.setPreferences(preferences);\n\n // The database\n RestaurantDBAdapter restaurantDBAdapter = new RestaurantDBAdapter(context);\n newSession.setRestaurantDBAdapter(restaurantDBAdapter);\n\n // The hashmap of all the restaurants\n HashMap<String, Restaurant> restaurants = restaurantDBAdapter.getAllRestaurants();\n newSession.setRestaurants(restaurants);\n\n //Save the current session\n Session.setCurrentSession(newSession);\n Session.currentSession.saveAsCurrentSession(context);\n }", "static void startSession() {\n /*if(ZeTarget.isDebuggingOn()){\n Log.d(TAG,\"startSession() called\");\n }*/\n if (!isContextAndApiKeySet(\"startSession()\")) {\n return;\n }\n final long now = System.currentTimeMillis();\n\n runOnLogWorker(new Runnable() {\n @Override\n public void run() {\n logWorker.removeCallbacks(endSessionRunnable);\n long previousEndSessionId = getEndSessionId();\n long lastEndSessionTime = getEndSessionTime();\n if (previousEndSessionId != -1\n && now - lastEndSessionTime < Constants.Z_MIN_TIME_BETWEEN_SESSIONS_MILLIS) {\n DbHelper dbHelper = DbHelper.getDatabaseHelper(context);\n dbHelper.removeEvent(previousEndSessionId);\n }\n //startSession() can be called in every activity by developer, hence upload events and sync datastore\n // only if it is a new session\n //syncToServerIfNeeded(now);\n startNewSessionIfNeeded(now);\n\n openSession();\n\n // Update last event time\n setLastEventTime(now);\n //syncDataStore();\n //uploadEvents();\n\n }\n });\n }", "public void initialiseSession() {\n LOGGER.info(\"Initialising session...\");\n if (this.mKsession == null) {\n for (String ruleFile : mRuleFiles) {\n mKbuilder.add(ResourceFactory.newClassPathResource(ruleFile,\n IronSyslogDrools.class), ResourceType.DRL);\n }\n if (mKbuilder.hasErrors()) {\n LOGGER.error(mKbuilder.getErrors().toString());\n throw new RuntimeException(\"Unable to compile drl\\\".\");\n }\n mPkgs = mKbuilder.getKnowledgePackages();\n\n KnowledgeBaseConfiguration config = KnowledgeBaseFactory\n .newKnowledgeBaseConfiguration();\n config.setOption(EventProcessingOption.STREAM);\n mKbase = KnowledgeBaseFactory.newKnowledgeBase(config);\n\n mKbase.addKnowledgePackages(mPkgs);\n\n // KnowledgeSessionConfiguration conf = KnowledgeBaseFactory\n // .newKnowledgeSessionConfiguration();\n // conf.setOption(ClockTypeOption.get(\"pseudo\"));\n // ksession = kbase.newStatefulKnowledgeSession(conf, null);\n mKsession = mKbase.newStatefulKnowledgeSession();\n // entryPoint1 = ksession.getWorkingMemoryEntryPoint(\"entryone\");\n\n Thread ruleFire = new Thread() {\n\n @Override\n public void run() {\n mKsession.fireUntilHalt();\n }\n };\n ruleFire.start();\n } else {\n retractAll();\n }\n }", "public void testModifyExternallyFragmentSession() throws Exception {\n // Retrieve the session and stock it\n session = loadSession();\n\n final String pluginFilePath = PATH_COPY + SESSION_RESOURCE_FRAGMENT;\n final String wksPath = TEMPORARY_PROJECT_NAME + \"/\" + SESSION_RESOURCE_FRAGMENT;\n // Modify externally session file (Copy the same file as existing in\n // project\n EclipseTestsSupportHelper.INSTANCE.copyFile(SiriusTestsPlugin.PLUGIN_ID, pluginFilePath, wksPath);\n TestsUtil.synchronizationWithUIThread();\n\n // Check the session is the same\n checkSessionIsCorrect(session);\n }", "@Override\n\tpublic void createSession(String customer) {\n\t\t\n\t}", "DefaultSession createSession(String id);", "@Test\n public void loginRegistersSessionRoutes_GlobalCanBeAdded() {\n getDriver().get(getTestURL()+\"global\");\n\n WebElement login = findElement(By.id(\"login-field\"));\n WebElement pwd = findElement(By.id(\"password-field\"));\n\n login.sendKeys(\"admin\");\n pwd.sendKeys(\"admin\");\n\n // Login as admin.\n findElement(By.id(\"submit\")).click();\n\n Assert.assertEquals(\"Should have now admin view visible.\", 3,\n findElements(By.tagName(\"vaadin-checkbox\")).size());\n\n // Time and Version views should have been registered to session on login.\n Assert.assertFalse(\"Time link should be available\",\n findElements(By.id(\"time-link\")).isEmpty());\n Assert.assertFalse(\"Version link should be available\",\n findElements(By.id(\"version-link\")).isEmpty());\n\n // Register Global to application scope\n findElement(By.id(\"global-checkbox\")).click();\n\n // Now global should be available\n getDriver().get(getTestURL()+\"global\");\n\n Assert.assertFalse(\"Global view should have been available\",\n findElements(By.id(\"remove-global\")).isEmpty());\n\n // as we are still in the session version and view should be available\n getDriver().get(getTestURL()+\"version\");\n Assert.assertFalse(\"Version view should have been available\",\n findElements(By.id(\"version-return\")).isEmpty());\n\n getDriver().get(getTestURL()+\"time\");\n Assert.assertFalse(\"Time view should have been available\",\n findElements(By.id(\"time-return\")).isEmpty());\n\n open();\n\n findElement(By.id(\"logout\")).click();\n\n // We should be at login view, but have a global view registered\n Assert.assertFalse(\"Global link should be available on login\",\n findElements(By.id(\"global-link\")).isEmpty());\n\n // now that the session was killed we should not get to time or version views\n\n getDriver().get(getTestURL()+\"version\");\n Assert.assertTrue(\"Version view shouldn't be available\",\n findElements(By.id(\"version-return\")).isEmpty());\n Assert.assertFalse(\"Login view should have been displayed\",\n findElements(By.id(\"global-link\")).isEmpty());\n\n getDriver().get(getTestURL()+\"time\");\n Assert.assertTrue(\"Time view shouldn't be available\",\n findElements(By.id(\"time-return\")).isEmpty());\n Assert.assertFalse(\"Login view should have been displayed\",\n findElements(By.id(\"global-link\")).isEmpty());\n }", "protected abstract SESSION newSessionObject() throws EX;", "IDAOSession createNewSession();", "DatabaseSession openSession();", "public abstract I_SessionInfo getSession(I_SessionName sessionName);", "protected void setSession(Session newSession) {\n sessionTracker.setSession(newSession);\n }", "@Test\r\n public void testGetSession() {\r\n System.out.println(\"getSession\");\r\n assertNotNull(sm);\r\n \r\n ISimulationSessionInfo result = sm.getSession(\"test1\");\r\n assertNotNull(result);\r\n assertEquals(result.getRequester(), \"junit\");\r\n }", "public abstract void initialize(ISession session);", "public void sessionCreated(IoSession session) {\r\n\t\tServerLogger.log(\"Session created...\" + session, Constants.DEBUG);\r\n\t\tsession.getConfig().setIdleTime(IdleStatus.BOTH_IDLE, 5);\r\n\t}", "public createsessions() {\n initComponents();\n loadlec();\n loadlec2();\n\n // subcode() ;\n loadsubname();\n loadsubname1();\n\n loadtag();\n loadtag2();\n\n loadgrpid();\n loadgrpid2();\n\n loadsubgrpid1();\n loadsubgrpid2();\n\n }", "protected Map<String, String> startSession() throws IOException {\n return startSession(null);\n }", "protected final void openSession() {\n openSessionForRead(null, null);\n }", "public void launchNewSession(){\r\n framework.launchNewMAV(getArrayMappedToData(), this.experiment, \"Multiple Experiment Viewer - Cluster Viewer\", Cluster.GENE_CLUSTER);\r\n }", "protected void setUp() \r\n {\n System.out.println(\"Setting up User Test !\");\r\n \t//lProps = new Properties();\t\r\n //lProps.put(Context.INITIAL_CONTEXT_FACTORY,lContextFactory);\r\n //lProps.put(Context.PROVIDER_URL,lURL);\r\n //lProps.put(Context.URL_PKG_PREFIXES,lPrefixes);\r\n try\r\n {\r\n lProps.list(System.out);\r\n lIC = new InitialContext(lProps);\r\n //sLog.debug(\"Created Initial Context\");\r\n System.out.println(\"Created Initial Context-looking for UserHome\");\r\n Object homeObj = lIC.lookup(lJndiName);\r\n System.out.println(\"got Object!\");\r\n lHome = (UserHome) PortableRemoteObject.narrow(homeObj,UserHome.class); \r\n \r\n //lSessionHome = (PJVTProducerSessionHome) lIC.lookup(lJndiName);\r\n \r\n System.out.println(\"User Home:\"+lHome.toString());\r\n \r\n }\r\n catch(Throwable t)\r\n {\r\n t.printStackTrace();\r\n }\r\n\t}", "public void sessionStarted() {\n\t\t\r\n\t}", "private void login() {\n setCredentials();\n setSysProperties();\n\n Properties sysProperties = System.getProperties();\n sysProperties.put(\"mail.store.protocol\", \"imaps\");\n this.session = Session.getInstance(sysProperties,\n new Authenticator() {\n @Override\n protected PasswordAuthentication getPasswordAuthentication() {\n return new PasswordAuthentication(username, password);\n }\n });\n }", "private void initSession(HttpServletRequest request, HttpServletResponse response) throws IOException {\n // create new seassion for user\n HttpSession session = request.getSession();\n if (session != null) {\n _sessionId = session.getId();\n }\n\n response.getWriter().write(_sessionId);\n }", "@Override\n\tpublic Session createSession(SessionBasicInfo sessionBasicInfo) {\n\t\tSession session = sessionStore.createSession( sessionBasicInfo);\n\t\tif(session == null)\n\t\t\treturn null;\n\t\tsession._setSessionStore(this);\n\t\tsession.putNewStatus();\n\t\t\n\t\treturn session;\n\t}", "@Override\n @Test(groups = {\"SessionContext access\"})\n public void testSessionContext01() throws Exception {\n super.testSessionContext01();\n }", "public abstract I_SessionInfo getSessionInfo(I_SessionName sessionName);", "void sessionCreated(SessionEvent se);", "@Test\n\tpublic void testIsSession() {\n\t\t\n\t\tclub.CreerSession();\n\t\tassertNotNull(\"Aucune session n'a été pas créée\", club.getSession());\n\t\t\n\t}", "public WebServiceConfig()\n {\n// session1 = new sessionmanager(getApplicationContext);\n\n }", "public StoredSession(Properties conf, String url, String username,\n\t\t\tString pass, int port) {\n\t\tjsch = new JSch();\n\t\tconfig = conf;\n\t\tserverUrl = url;\n\t\tuserName = username;\n\t\tpassword = pass;\n\t\tportNumber = port;\n\t}", "@Override\n public CreateSessionResponse createSession()\n throws EwalletException {\n return null;\n }", "public abstract void setRemoteSessionSpec(SessionSpec remote);", "Session getSession();", "Session getSession();", "RunningTasks getActiveHarvestingSessions() throws RepoxException;", "private static void startNewSession(final long timestamp) {\n openSession();\n\n sessionId = timestamp;\n //Log.i(\"sessionId\",\"updated at startNewSession()\");\n SharedPreferences preferences = CommonUtils.getSharedPreferences(context);\n preferences.edit().putLong(Constants.Z_PREFKEY_LAST_END_SESSION_ID, sessionId).apply();\n\n logEvent(START_SESSION_EVENT, null, null, timestamp, false);\n logWorker.post(new Runnable() {\n @Override\n public void run() {\n sendEventToServer(START_SESSION_EVENT, timestamp, Constants.Z_START_SESSION_EVENT_LOG_URL, true);\n }\n });\n\n }", "public void testGetSession() throws Exception {\n System.out.println(\"getSession\");\n Properties properties = new Properties();\n properties.put(OntologyConstants.ONTOLOGY_MANAGER_CLASS,\n \"com.rift.coad.rdf.semantic.ontology.jena.JenaOntologyManager\");\n File testFile = new File(\"./base.xml\");\n FileInputStream in = new FileInputStream(testFile);\n byte[] buffer = new byte[(int)testFile.length()];\n in.read(buffer);\n in.close();\n properties.put(OntologyConstants.ONTOLOGY_CONTENTS, new String(buffer));\n JenaOntologyManager instance =\n (JenaOntologyManager)OntologyManagerFactory.init(properties);\n OntologySession result = instance.getSession();\n assertEquals(result.getClass().getName(), \"com.rift.coad.rdf.semantic.ontology.jena.JenaOntologySession\");\n }", "@Override\n public void sessionCreated(IoSession session) {\n }", "protected static void storeParametersToSession(ViewLearningToolRequestParams parameters, HttpSession session,\n String applicationKey, String sharedSecret)\n {\n if (parameters.getApiSessionId() == null)\n {\n throw new RuntimeException(\"ApiSessionId is not specified in the querystring.\");\n }\n if (parameters.getLearningObjectId() == null)\n {\n throw new RuntimeException(\"LearningObjectId is not specified in the querystring.\");\n }\n if (parameters.getLearningObjectInstanceId() == null)\n {\n throw new RuntimeException(\"LearningObjectInstanceId is not specified in the querystring.\");\n }\n if (parameters.getVersion() == null)\n {\n throw new RuntimeException(\"Version is not specified in the querystring.\");\n }\n if (parameters.getPermissions() == null)\n {\n throw new RuntimeException(\"Permissions is not specified in the querystring.\");\n }\n\n UserInfo userInfo = new UserInfo();\n userInfo.setAccessibility(parameters.getAccessibility() != null ? parameters.getAccessibility() : false);\n userInfo.setFirstName(parameters.getFirstName());\n userInfo.setLastName(parameters.getLastName());\n userInfo.setEmail(parameters.getEmail());\n userInfo.setSyncKey(parameters.getSyncKey());\n userInfo.setMobile(parameters.getMobile());\n userInfo.setLanguage(parameters.getLanguage());\n userInfo.setLocale(parameters.getLocale());\n userInfo.setWindowsTimeZoneId(parameters.getWindowsTimeZoneId());\n userInfo.setOlsonTimeZoneId(parameters.getOlsonTimeZoneId());\n userInfo.setUser12HTimeFormat(parameters.getUse12HTimeFormat() != null ? parameters.getUse12HTimeFormat() : false);\n userInfo.setEncoding(parameters.getEncoding());\n userInfo.setCustom1Id(parameters.getCustom1Id());\n userInfo.setCustom2Id(parameters.getCustom2Id());\n userInfo.setCustom3Id(parameters.getCustom3Id());\n userInfo.setCustom4Id(parameters.getCustom4Id());\n userInfo.setCustom5Id(parameters.getCustom5Id());\n userInfo.setCustom1(parameters.getCustom1());\n userInfo.setCustom2(parameters.getCustom2());\n userInfo.setCustom3(parameters.getCustom3());\n userInfo.setCustom4(parameters.getCustom4());\n userInfo.setCustom5(parameters.getCustom5()); \n userInfo.setUserId(parameters.getUserId());\n if ( parameters.getCustomerId() != null )\n userInfo.setCustomerId(parameters.getCustomerId());\n\n // Default to guest if userRole is not sent (for backwardscompatibility)\n UserRole userRole = UserRole.Guest;\n if(parameters.getRole()!=null)\n {\n // Set the userRole that we get from it's learning parsed to enum\n userRole = UserRole.valueOf(parameters.getRole());\n }\n \n userInfo.setUserRole(userRole);\n\n try\n {\n userInfo.setSchools(buildSchoolInfoList(parameters.getSchoolId()));\n }\n\n catch(ParseException pe)\n {\n // Invalid format on the request parameter value 'SchoolId'.\n throw new RuntimeException(\"Invalid format on the request parameter value 'SchoolId': \"+parameters.getSchoolId(), pe);\n }\n\t\n\n ApiSession apiSession = constructApiSession(parameters.getApiSessionId(), applicationKey, sharedSecret);\n\n // Put data into session\n // API session and permissions vary for different documents within the same ASP.NET application session\n session.setAttribute(getSessionKey(parameters, Constants.SessionKeys.ApiSessionId), parameters.getApiSessionId());\n session.setAttribute(getSessionKey(parameters, Constants.SessionKeys.ApiSession), apiSession);\n session.setAttribute(getSessionKey(parameters, Constants.SessionKeys.Permissions), parameters.getPermissions());\n\n // UserInfo info is the same for all documents within the same ASP.NET application session\n session.setAttribute(Constants.SessionKeys.UserInfo, userInfo);\n\n }", "public void connect() throws IOException {\r\n \t\t \r\n \t\t \tClassLoader saved = Thread.currentThread().getContextClassLoader();\r\n\t\t\ttry {\r\n\t\t\t\t // Parse url (rsuite:/http://host/user/session/moId)\r\n\t\t\t\t log.println(\"INCOMING URL IS: \" + url);\r\n\t\t\t\t log.println(\"PARSING URL TO GET PARAMETERS...\");\r\n\t\t\t\t \r\n\t\t\t\t // url initially comes through with extension to avoid dialog window\r\n\t\t\t\t docURL = RSuiteProtocolUtils.parseRSuiteProtocolURL(url);\r\n\t\t\t\t host = docURL.getHost();\r\n\t\t\t\t protocol = docURL.getProtocol().concat(\"//\");\r\n\t\t\t\t username = docURL.getUserName();\r\n\t\t\t\t sessionKey = docURL.getSessionKey();\r\n\t\t\t\t moId = docURL.getMoId();\r\n\t\t\t\t // set the connection so we have it later\r\n\t\t\t\t _connection = this;\r\n\r\n\t\t\t\t log.println(\"HOST: \" + host);\r\n\t\t\t\t log.println(\"USERNAME: \" + username);\r\n\t\t\t\t log.println(\"SESSION KEY: \" + sessionKey);\r\n\t\t\t\t log.println(\"MOID: \" + moId);\r\n\t\t\t\t \r\n\t\t\t\t Thread.currentThread().setContextClassLoader(this.getClass().getClassLoader());\r\n\t\t\t\t \r\n\t\t\t\t // CONNECT TO RSUITE IF SESSION NOT PRESENT\t\t\t\t \r\n\t\t\t\t log.println(\"CONNECTION TO RSUITE...\");\r\n\t\t\t\t if(sessionKey == null){\r\n\t\t\t\t\t log.println(\"SESSION DOES NOT EXIST, PROMPT FOR LOGIN\");\r\n\t\t\t\t\t RSuiteLoginDialog login = new RSuiteLoginDialog();\r\n\t\t\t\t\t login.setLocationRelativeTo(null);\r\n\t\t\t\t\t login.setVisible(true);\r\n\t\t\t\t }\r\n\t\t\t\t \r\n\t\t\t\t // SESSION WAS PASSED IN, INITIALIZE REPOSITORY\r\n\t\t\t\t if(repository == null){\r\n\t\t\t\t\t log.println(\"SESSION PASSED IN BY URL, INITIALIZE REPOSITORY\");\r\n\t\t\t\t\t repository = new RsuiteRepositoryImpl(username, \"\", host);\r\n\t\t\t\t\t log.println(\"REPOSITORY INITIALIZED.\");\r\n\t\t\t\t\t \r\n\t\t\t\t\t // NO NEED TO LOGIN SINCE WE HAVE SESSION KEY ALREADY\r\n\t\t\t\t\t log.println(\"SETTING THE REPOSITORY SESSION KEY...\");\r\n\t\t\t\t\t repository.sessionKey = sessionKey;\r\n\t\t\t\t\t log.println(\"SESSION KEY SET. NO NEED FOR LOGIN\");\r\n\t\t\t\t }\t\t\t\t \r\n\t\t\t}\r\n\t\t\tcatch (Throwable t) {\r\n\t\t\t if (log != null) {\r\n\t\t\t t.printStackTrace(log);\r\n\t\t\t }\r\n\t\t\t}\r\n\t\t\tfinally{\r\n\t\t\t\tThread.currentThread().setContextClassLoader(saved);\r\n\t\t\t}\r\n\t\t}", "@Test\n public void testGetTasksForSession() {\n\n List<Task> tasks;\n\n tasks = Session.getTasks(Session.NAME.PRE, 1);\n\n assertNotNull(tasks);\n assertTrue(\"Pre should have two tasks.\", tasks.size() == 2);\n assertEquals(\"Unique name for the task should be DASS_21\", \"DASS21_AS\", tasks.get(0).getName());\n assertEquals(\"First task should be named Status Questionnaire\", \"Status Questionnaire\", tasks.get(0).getDisplayName());\n assertEquals(\"First task should point to the DASS21 questionniare\", Task.TYPE.questions, tasks.get(0).getType());\n assertEquals(\"First task should point to the DASS21 questionniare\",\"questions/DASS21_AS\", tasks.get(0).getRequestMapping());\n assertTrue(\"First task should be completed\",tasks.get(0).isComplete());\n assertFalse(\"First task should not be current\",tasks.get(0).isCurrent());\n assertFalse(\"Second task should not be completed\",tasks.get(1).isComplete());\n assertTrue(\"Second task should be current\",tasks.get(1).isCurrent());\n\n Session s = new Session();\n s.setTasks(tasks);\n assertEquals(\"Second task is returned when current requested\", tasks.get(1), s.getCurrentTask());\n\n }", "public void configureSession(URLConnection co) throws IOException {\n\t\tco.setRequestProperty(\"Authorization\", \"OreApi session=\\\"\" + this.sessionManager.getOrCreateSession() + \"\\\"\");\n\t}", "public static void initialise()\n\t{\n\t\tServerConfigurationManager theSCM = ServerConfigurationManager.getInstance();\n\t\tString timeoutMinutes = theSCM.getProperty(theSCM.MAUI_SESSION_TIMEOUT);\n\t\t\n\t\ttry\n\t\t{\n\t\t\tlong minutes = Long.parseLong(timeoutMinutes);\n\t\t\t\n\t\t\tHTTPSession.kDefaultSessionTimeout = minutes * 60 * 1000;\n\t\t}\n\t\tcatch (NumberFormatException e)\n\t\t{\n\t\t\tSystem.err.println(\"[HTTPSession] Bad value for session timeout : \" + timeoutMinutes + \" Defaulting to 5 minutes.\");\n\t\t}\n\t\t\n\t\ttry\n\t\t{\n\t\t\tsessionMaximum = Integer.parseInt (theSCM.getProperty (theSCM.MAUI_SESSION_MAXIMUM));\n\t\t}\n\t\tcatch (NumberFormatException e)\n\t\t{\n\t\t\tsessionMaximum = Integer.parseInt (theSCM.MAUI_SESSION_MAXIMUM_VALUE);\n\t\t}\n\t}", "public abstract Thread startSession();", "public SessionDao(Configuration configuration) {\n super(Session.SESSION, com.scratch.database.mysql.jv.tables.pojos.Session.class, configuration);\n }", "SessionManagerImpl() {\n }", "public void createSession(int uid);", "@Test\r\n public void testRemoveSession() {\r\n System.out.println(\"removeSession\");\r\n assertNotNull(sm);\r\n boolean res = sm.initSession(\"test4\", programsHome, programsHome + \"files4/\", requester);\r\n assertTrue(res);\r\n \r\n ISimulationSessionInfo result = sm.getSession(\"test4\");\r\n assertNotNull(result);\r\n assertEquals(result.getRequester(), \"junit\");\r\n \r\n res = sm.removeSession(\"test4\");\r\n assertTrue(res);\r\n \r\n result = sm.getSession(\"test4\");\r\n assertNull(result);\r\n }", "private void config() {\n\t}", "public void testCreateSession() throws Exception {\n assertNotNull(mSession.getSessionToken());\n assertFalse(\"New session should not be active\", mSession.isActive());\n\n // Verify by getting the controller and checking all its fields\n MediaController controller = mSession.getController();\n assertNotNull(controller);\n verifyNewSession(controller, TEST_SESSION_TAG);\n }", "@Test\r\n @SuppressWarnings(\"SleepWhileInLoop\")\r\n public void testStartSimulationSession() {\r\n System.out.println(\"startSimulationSession\");\r\n assertNotNull(sm);\r\n assertEquals(SimulationState.READY, sm.getSimulationSessionState(\"test3\"));\r\n \r\n sm.addSimulatorToSession(\"test3\", Simulators.NUATMOS, \"v1\", true);\r\n //sm.addSimulatorToSession(\"test3\", Simulators.DISPERFIRE, true);\r\n //sm.addSimulatorToSession(\"test3\", Simulators.MEB, true);\r\n \r\n boolean result = sm.startSimulationSession(\"test3\", false);\r\n assertTrue(result);\r\n \r\n result = sm.startSimulationSession(\"test5\", false);\r\n assertFalse(result);\r\n \r\n Iterator<? extends ISimulationJobInfo> jobs = sm.getSession(\"test3\").iterator();\r\n \r\n for(ISimulationJobInfo job; jobs.hasNext();) {\r\n job = jobs.next();\r\n assertEquals(job.getRetVal(), 0);\r\n }\r\n }", "void onOpenSession(Session session);", "private Session establishSession(String sessionid) throws AxisFault {\n Session s = sessionManager.getSession(sessionid);\n\n if (s == null) {\n throw new AxisFault(\"Session \\\"\" + sessionid + \"\\\" is not active\");\n }\n s.setActive();\n sessionManager.setCurrentSession(s);\n return s;\n }", "public void generateInstallSessionID() {\n// generateSessionID();\n// hasInstallSession = true;\n }", "protected Session buildOrObtainSession() {\r\n\t\tLOGGER.fine(\"Opening a new Session\");\r\n\t\tSession s = super.buildOrObtainSession();\r\n\r\n\t\tLOGGER.fine(\"Disabling automatic flushing of the Session\");\r\n\t\ts.setFlushMode(FlushMode.MANUAL);\r\n\r\n\t\treturn s;\r\n\t}", "com.weizhu.proto.WeizhuProtos.Session getSession();", "private void updateSessionDetailsInDB(GlusterGeoRepSession session) {\n for (GlusterGeoRepSessionDetails sessDetails : session.getSessionDetails()) {\n sessDetails.setSessionId(session.getId());\n }\n getGeoRepDao().saveOrUpdateDetailsInBatch(session.getSessionDetails());\n }", "void open(SessionParameters sessionParameters, AuthenticationParameters authenticationParameters);", "private void updateActiveSession(Session s)\r\n\t{\r\n\t\t\r\n\t\t/**\r\n\t\t * Part Two\r\n\t\t */\r\n\t\t//TODO: BMH\r\n\t\t\r\n\t\t/**\r\n\t\t * Part Three\r\n\t\t */\r\n\t\ttry\r\n\t\t{\r\n\t\t\ts.serverSock.setSoTimeout(1);\r\n\t\t\tSocket client = s.serverSock.accept();\r\n\t\t\t\r\n\t\t\t\r\n\t\t\tOutput.processMessage(\"Accepted a connection from: \"+\r\n\t\t \t\tclient.getInetAddress(), Constants.Message_Type.debug);\r\n\t\t\t\r\n\t\t\r\n\t\t\tif (client != null)\r\n\t\t\t{\r\n\t\t\t\tSessionUtils.acceptNewClient(client, s);\r\n\t\t\t}\r\n\t\t\t\r\n\t\t}\r\n\t\tcatch(Exception e)\r\n\t\t{\r\n\t\t\t\r\n\t\t}\r\n\r\n\t}", "public void getTestSessions(){\n TestSessionDAO sessionsManager = DAOFactory.getTestSessionDAO();\n //populate with values from the database\n if(!sessionsManager.readInactiveTestSessions(testSessions)){\n //close the window due to read failure\n JOptionPane.showMessageDialog(rootPanel, \"Failed to read test sessions from database. Please check your internet connection and try again.\");\n System.exit(-2);\n }\n }", "public McqOfficialSession(){\n\t\tsuper(); \n\t}", "public Session() {\n\t\tLogger.log(\"Creating application session\");\n\t}", "private void doLogin() {\n\t\tSharedPreferences.Editor prefEditor = mSP.edit();\n\t\tSession.FirstLogin = true;\n\t\tmUserPin = et_password.getText().toString();\n\t\t// Time to update the session\n\t\tif (inTruckMode) {\n\t\t\tSession.setVehicle(vehicle);\n\t\t\tSession.setDriver(userDao.getByPin(mUserPin));\n\n\t\t\tprefEditor.putString(Config.VEHICLE_ID_KEY, vehicle.getId());\n\t\t\tprefEditor.putString(Config.LAST_VEHICLE_KEY, vehicle.getId());\n\t\t\tprefEditor.putString(Config.SITE_ID_KEY, null);\n\n\t\t\tSession.setType(SessionType.VEHICLE_SESSION);\n\t\t} else {\n\t\t\tSession.setSite(site);\n\t\t\tSession.setDriver(userDao.getByPin(mUserPin));\n\n\t\t\tprefEditor.putString(Config.VEHICLE_ID_KEY, null);\n\t\t\tprefEditor.putString(Config.LAST_VEHICLE_KEY, null);\n\t\t\tprefEditor.putString(Config.SITE_ID_KEY, site.getId());\n\n\t\t\tSession.setType(SessionType.SITE_SESSION);\n\t\t}\n\n\t\tstartupSync();\n\t\tstartSync();\n\n\t\tprefEditor.putString(Config.USER_PIN_KEY, mUserPin);\n\t\tprefEditor.putString(Config.LAST_USER_PIN_KEY, mUserPin);\n\t\tprefEditor.putString(Config.SYNC_SERVICE_KEY, \"yes\");\n\t\tprefEditor.commit();\n\n\t\t// if no VIMEI associated with truck, starting GPSService on SB device\n\t\tif (!vehiclesDao.xergoEsn(getApplicationContext())) {\n\t\t\tvimei = vehiclesDao.getVimei(this);\n\n\t\t\tIntent intent = new Intent();\n\t\t\tintent.setAction(GPSService.UPDATE_IMEI_EVENT);\n\t\t\tintent.putExtra(\"Value\", vimei);\n\t\t\tsendBroadcast(intent);\n\n\t\t\tintent = new Intent();\n\t\t\tintent.setAction(GPSService.SEND_IGNITION_ON_EVENT);\n\t\t\tsendBroadcast(intent);\n\t\t}\n\n\t\tstartSession(mUserPin);\n\t\tIntent intent = new Intent(this, MapActivity.class);\n\t\tthis.startActivity(intent);\n\t\tfinish();\n\t}", "private void setupCustomerSession() {\n CustomerSession.initCustomerSession(\n new SampleStoreEphemeralKeyProvider(\n new SampleStoreEphemeralKeyProvider.ProgressListener() {\n @Override\n public void onStringResponse(String string) {\n if (string.startsWith(\"Error: \")) {\n new AlertDialog.Builder(StoreActivity.this).setMessage(string).show();\n }\n }\n }));\n }", "public interface Session {\n\n String API_KEY = \"kooloco\";\n String USER_SESSION = \"szg9wyUj6z0hbVDU6nM2vuEmbyigN3PgC5q8EksKTs25\";\n String USER_ID = \"24\";\n String DEVICE_TYPE = \"A\";\n\n String getApiKey();\n\n String getUserSession();\n\n String getUserId();\n\n void setApiKey(String apiKey);\n\n void setUserSession(String userSession);\n\n void setUserId(String userId);\n\n String getDeviceId();\n\n void setUser(User user);\n\n User getUser();\n\n void clearSession();\n\n String getLanguage();\n\n String getCurrency();\n\n String getAppLanguage();\n\n void setCurrency(String currency, String lCurrency);\n\n}", "protected Session newSession(URI serverUri) throws QueryException {\n try {\n // The factory won't be in the cache, as a corresponding session would have already been created.\n SessionFactory sessionFactory = SessionFactoryFinder.newSessionFactory(serverUri, true);\n factoryCache.add(sessionFactory);\n // now create the session\n Session session = sessionFactory.newSession();\n sessionCache.put(serverUri, session);\n return session;\n } catch (NonRemoteSessionException nrse) {\n throw new QueryException(\"State Error: non-local URI was mapped to a local session\", nrse);\n } catch (SessionFactoryFinderException sffe) {\n throw new QueryException(\"Unable to get a session to the server\", sffe);\n }\n }", "private DefaultSession createDefaultSession(CommandHandler commandHandler) {\n stubSocket = createTestSocket(COMMAND.getName());\n commandHandlerMap.put(commandToRegister, commandHandler);\n initializeConnectCommandHandler();\n return new DefaultSession(stubSocket, commandHandlerMap);\n }", "private Single<SessionEntity> newSession(UserEntity userEntity) {\n return this.authApi.getToken().flatMap(requestTokenEntity ->\n this.authApi.validateToken(\n new ValidateTokenEntity(\n userEntity.getTMDBUsername(),\n userEntity.getTMDBPassword(),\n requestTokenEntity.getRequestToken()\n )\n ).doOnError((e)-> {\n updateUser(new SessionEntity(false, \"\"), userEntity);\n createUserSession();\n })\n .flatMap(validatedRequestToken ->\n this.authApi.createSession(validatedRequestToken.getRequestToken()).doOnSuccess(sessionEntity -> {\n if (!sessionEntity.isSuccess()) {\n //TODO - refreshSession few times and return guest session.\n }\n\n updateUser(sessionEntity, userEntity);\n }\n )\n ));\n }", "@Test\n\tpublic void checkSessionInfoDisplayedCorrectly()\n\t{\n\t\tonView(withIndex(withText(R.string.timetable_tab), 1)).perform(click());\n\t\t//now click on the session\n\t\tonView(withText(\"Using ARKit with SpriteKit\")).perform(click());\n\n\t\tonView(withId(R.id.nav_host_fragment)).check((view, noViewFoundException) ->\n\t\t{\n\t\t\tTextView speakerName = view.findViewById(R.id.session_view_speaker_name);\n\t\t\tTextView sessionTitle = view.findViewById(R.id.session_view_title);\n\t\t\tTextView sessionType = view.findViewById(R.id.session_view_session_type);\n\t\t\tTextView sessionTime = view.findViewById(R.id.session_view_date_time);\n\t\t\tTextView sessionPlace = view.findViewById(R.id.session_view_location_name);\n\n\t\t\tassertEquals(speakerName.getText(), \"Janie Clayton @redqueencoder\");\n\t\t\tassertEquals(speakerName.getVisibility(), View.VISIBLE);\n\n\t\t\tassertEquals(sessionTitle.getText(), \"Using ARKit with SpriteKit\");\n\t\t\tassertEquals(sessionTitle.getVisibility(), View.VISIBLE);\n\n\t\t\tassertEquals(sessionType.getText(), \"Workshop\");\n\t\t\tassertEquals(sessionType.getVisibility(), View.VISIBLE);\n\n\t\t\tassertEquals(sessionTime.getText(), \"Tuesday 10th December, 16:00 - 18:00\");\n\t\t\tassertEquals(sessionTime.getVisibility(), View.VISIBLE);\n\n\t\t\tassertEquals(sessionPlace.getText(), \"Llandinam B23\");\n\t\t\tassertEquals(sessionPlace.getVisibility(), View.VISIBLE);\n\t\t});\n\t}", "@Override\n public void startNewSession(final IBrowser.BrowserType aBrowserType) {\n endSession();\n\n final WetatorConfiguration tmpConfiguration = wetatorEngine.getConfiguration();\n\n // reset the bookmarks\n bookmarks = new HashMap<>();\n\n final BrowserVersion tmpBrowserVersion = determineBrowserVersionFor(aBrowserType);\n\n DefaultCredentialsProvider tmpCredentialProvider = null;\n\n final String tmpHost = tmpConfiguration.getProxyHost();\n if (StringUtils.isNotEmpty(tmpHost)) {\n LOG.info(\"Proxy configured\");\n LOG.info(\"Proxy Host: '\" + tmpHost + \"'\");\n final int tmpPort = tmpConfiguration.getProxyPort();\n LOG.info(\"Proxy Port: '\" + tmpPort + \"'\");\n\n webClient = new WebClient(tmpBrowserVersion, tmpHost, tmpPort);\n\n final SecretString tmpProxyUser = tmpConfiguration.getProxyUser();\n if (null != tmpProxyUser && !tmpProxyUser.isEmpty()) {\n final String tmpUser = tmpProxyUser.getValue();\n LOG.info(\"Proxy User: '\" + tmpUser + \"'\");\n final String tmpPassword = tmpConfiguration.getProxyPassword().getValue();\n tmpCredentialProvider = new DefaultCredentialsProvider();\n webClient.setCredentialsProvider(tmpCredentialProvider);\n\n tmpCredentialProvider.addCredentials(tmpUser, tmpPassword, tmpHost, tmpPort, null);\n } else {\n LOG.info(\"Proxy no user defined\");\n }\n\n final Set<String> tmpNonProxyHosts = tmpConfiguration.getProxyHostsToBypass();\n\n for (final String tmpString : tmpNonProxyHosts) {\n String tmpHostsToProxyBypass = tmpString.trim();\n tmpHostsToProxyBypass = tmpHostsToProxyBypass.replaceAll(\"\\\\.\", \"\\\\\\\\.\");\n tmpHostsToProxyBypass = tmpHostsToProxyBypass.replaceAll(\"^\\\\*\", \".*\");\n\n webClient.getOptions().getProxyConfig().addHostsToProxyBypass(tmpHostsToProxyBypass);\n LOG.info(\"Proxy HostsToProxyBypass: '\" + tmpHostsToProxyBypass + \"'\");\n }\n } else {\n webClient = new WebClient(tmpBrowserVersion);\n }\n\n final SecretString tmpBasicAuthUser = tmpConfiguration.getBasicAuthUser();\n if (null != tmpBasicAuthUser && !tmpBasicAuthUser.isEmpty()) {\n final String tmpUser = tmpBasicAuthUser.getValue();\n final String tmpPassword = tmpConfiguration.getBasicAuthPassword().getValue();\n\n if (null == tmpCredentialProvider) {\n tmpCredentialProvider = new DefaultCredentialsProvider();\n webClient.setCredentialsProvider(tmpCredentialProvider);\n }\n\n tmpCredentialProvider.addCredentials(tmpUser, tmpPassword);\n webClient.setCredentialsProvider(tmpCredentialProvider);\n\n LOG.info(\"BasicAuth enabled user '\" + tmpUser + \"'.\");\n }\n\n final SecretString tmpNtlmUser = tmpConfiguration.getNtlmUser();\n if (null != tmpNtlmUser && !tmpNtlmUser.isEmpty()) {\n final String tmpUser = tmpNtlmUser.getValue();\n final String tmpPassword = tmpConfiguration.getNtlmPassword().getValue();\n final String tmpWorkstation = tmpConfiguration.getNtlmWorkstation().getValue();\n final String tmpDomain = tmpConfiguration.getNtlmDomain().getValue();\n\n if (null == tmpCredentialProvider) {\n tmpCredentialProvider = new DefaultCredentialsProvider();\n webClient.setCredentialsProvider(tmpCredentialProvider);\n }\n\n tmpCredentialProvider.addNTLMCredentials(tmpUser, tmpPassword, null, -1, tmpWorkstation, tmpDomain);\n\n LOG.info(\"NTLM enabled user '\" + tmpUser + \"' workstation '\" + tmpWorkstation + \"' domain '\" + tmpDomain + \"'.\");\n }\n\n // setup our listener\n webClient.addWebWindowListener(new WebWindowListener(this));\n webClient.setAttachmentHandler(new AttachmentHandler());\n webClient.setAlertHandler(new AlertHandler(wetatorEngine));\n webClient.getWebConsole().setLogger(new WebConsoleLogger(wetatorEngine));\n webClient.setIncorrectnessListener(new IncorrectnessListener(wetatorEngine));\n webClient.setConfirmHandler(new ConfirmHandler(wetatorEngine));\n\n // refresh handler - behave like the browser does\n webClient.setRefreshHandler(new WaitingRefreshHandler());\n\n // javascript\n webClient.getOptions().setJavaScriptEnabled(true);\n webClient.getOptions().setThrowExceptionOnScriptError(false);\n webClient.setJavaScriptErrorListener(new JavaScriptErrorListener(this));\n\n // webClient.getOptions().setThrowExceptionOnFailingStatusCode(false);\n // webClient.getOptions().setUseInsecureSSL(true);\n\n final Set<SearchPattern> tmpFilters = tmpConfiguration.getJsJobFilterPatterns();\n if (tmpFilters.isEmpty()) {\n jobFilter = null;\n } else {\n jobFilter = new JavaScriptJobFilter();\n for (final SearchPattern tmpSearchPattern : tmpFilters) {\n jobFilter.addPattern(tmpSearchPattern);\n }\n }\n\n // register activeX control mocker\n // should we do something like this?\n // webClient.getOptions().setActiveXNative(false);\n webClient.setActiveXObjectMap(tmpConfiguration.getBrowserActiveXObjects());\n\n // set Accept-Language header\n webClient.addRequestHeader(\"Accept-Language\", tmpConfiguration.getAcceptLanaguage());\n\n // trust all SSL-certificates\n webClient.getOptions().setUseInsecureSSL(true);\n\n // use client certificate key store\n final String tmpClientCertKeyStoreUrl = tmpConfiguration.getClientCertificateKeyStoreUrl();\n if (StringUtils.isNotEmpty(tmpClientCertKeyStoreUrl)) {\n final String tmpClientCertKeyStoreType = tmpConfiguration.getClientCertificateKeyStoreType();\n final SecretString tmpClientCertKeyStorePassword = tmpConfiguration.getClientCertificateKeyStorePassword();\n\n LOG.info(\"ClientCertificateKeyStore configured\");\n LOG.info(\" URL: \" + tmpClientCertKeyStoreUrl);\n LOG.info(\" Type: \" + tmpClientCertKeyStoreType);\n LOG.info(\" Password: \" + tmpClientCertKeyStorePassword);\n\n try {\n final URL tmpKeyStoreURL = new URL(tmpClientCertKeyStoreUrl);\n webClient.getOptions().setSSLClientCertificate(tmpKeyStoreURL, tmpClientCertKeyStorePassword.getValue(),\n tmpClientCertKeyStoreType);\n } catch (final Exception e) {\n LOG.error(\"Failed to use configured ClientCertificateKeyStore.\", e.getCause());\n }\n }\n\n // set the timeout\n webClient.getOptions().setTimeout(tmpConfiguration.getHttpTimeoutInSeconds() * 1000);\n\n // debug stuff\n if (tmpConfiguration.isDebugLoggingEnabled()) {\n final HtmlUnitContextFactory tmpContextFactory = ((JavaScriptEngine) webClient.getJavaScriptEngine())\n .getContextFactory();\n tmpContextFactory.setDebugger(new DebuggerImpl());\n }\n // webClient.setAjaxController(new NicelyResynchronizingAjaxController());\n if (tmpConfiguration.startJsDebugger()) {\n WebClientUtils.attachVisualDebugger(webClient);\n }\n }", "public void trackNewSession() {\n if(isTelemetryEnabled()){\n new CreateDataTask(CreateDataTask.DataType.NEW_SESSION).execute();\n }\n }", "DatastoreSession createSession();", "public void setSession(Session session) { this.session = session; }", "SessionManager get();", "@Override\r\n\t\tpublic Session newSession(Request request, Response response) {\n\t\t\tLoginSession session = new LoginSession(request);\r\n\t\t\tsession.authenticate(\"scott\", \"tiger\");\r\n\t\t\t\r\n\t\t\treturn session;\r\n\t\t}", "private Session setUpEmailSession() throws MessagingException {\n Authenticator auth = new SimpleAuthenticator(mailUsername, mailPassword);\r\n Properties props = System.getProperties();\r\n props.put(\"mail.smtp.host\", mailHost);\r\n Session session = Session.getDefaultInstance(props, auth);\r\n Store store = session.getStore(\"pop3\");\r\n store.connect(mailHost, mailUsername, mailPassword); \r\n return session;\r\n }", "@Override\r\n public void onModuleLoad() {\r\n //register auto refreshing timer\r\n// autoRefresh = new Timer() {\r\n// @Override\r\n// public void run() {\r\n// Shared.EVENT_BUS.fireEvent(new UIRefreshEvent());\r\n// }\r\n// };\r\n// autoRefresh.scheduleRepeating(AUTO_REFRESH_INTERVAL);\r\n \r\n \r\n //read cookies to recover previous session\r\n if (cookie.getSeesionID().isEmpty()) {\r\n //create new session\r\n newSession();\r\n }else{\r\n //try to rebind the old session\r\n Shared.RPC.getSession(cookie.getSeesionID(), new AsyncCallback<Session>() {\r\n @Override\r\n public void onSuccess(Session s) {\r\n if (s == null){\r\n //the session is absent on server\r\n Info.display(\"Expired\", \"Your session is expired, please sign in again\");\r\n newSession();\r\n }else{\r\n Shared.MY_SESSION = s; \r\n //try to auto sign in using saved accountKey\r\n if (cookie.getAccountKey(s).isEmpty() || s.getAccount() == null){\r\n //not to keep signed in / or not yet signed in\r\n //do nothing, wait for signing in\r\n }else{\r\n //try to sign in\r\n Shared.EVENT_BUS.fireEvent(new SignEvent(SignEvent.Action.SIGN_IN)); //didn't set the account key because setting it result in overwrite the cookies\r\n Shared.RPC.signInAndBindSession(s.getAccount(), s, cookie.getAccountKey(s), new AsyncCallback<Session>() {\r\n @Override\r\n public void onSuccess(Session s) {\r\n if (s != null) {\r\n //login successful\r\n Shared.MY_SESSION = s;\r\n //dispatch sign in event\r\n Shared.EVENT_BUS.fireEvent(new SignEvent(SignEvent.Action.SIGNED_IN));\r\n } else {\r\n Info.display(\"Incorrect\", \"Please check your password and try again\");\r\n }\r\n }\r\n\r\n @Override\r\n public void onFailure(Throwable caught) {\r\n Info.display(\"Error\", caught.getMessage());\r\n }\r\n }); \r\n }\r\n }\r\n }\r\n @Override\r\n public void onFailure(Throwable caught) {\r\n Info.display(\"Error\", caught.getMessage());\r\n }\r\n });\r\n }\r\n \r\n\r\n\r\n \r\n \r\n res.common_css().ensureInjected(); \r\n Widget loginpage = new LoginPage();\r\n RootPanel.get().add(loginpage);\r\n\r\n //add event handler for SignEvent event\r\n Shared.EVENT_BUS.addHandler(SignEvent.TYPE, new SignEvent.SignEventHandler(){\r\n @Override\r\n public void onSign(SignEvent event){\r\n //process sign_in\r\n //process signed_in\r\n if (event.getAction().equals(SignEvent.Action.SIGNED_IN)) {\r\n //write cookies if keep signed in\r\n if (event.getAccountKey() != null && !event.getAccountKey().isEmpty()) {\r\n cookie.setAccountKey(Shared.MY_SESSION, event.getAccountKey());\r\n }\r\n //already signed in, load workspace\r\n RootPanel.get().clear();\r\n Widget workspace = new Workspace().asWidget();\r\n RootPanel.get().add(workspace); \r\n Info.display(\"Welcome\", \"Signed in as \" + Shared.MY_SESSION.getAccount().getFullName());\r\n }\r\n //process sign_out\r\n if (event.getAction().equals(SignEvent.Action.SIGN_OUT)){\r\n String accountKey = cookie.getAccountKey(Shared.MY_SESSION);\r\n Shared.RPC.signOutAndDetachSession(Shared.MY_SESSION, accountKey, new AsyncCallback<Session>() {\r\n @Override\r\n public void onSuccess(Session s) {\r\n if (s != null) {\r\n Shared.MY_SESSION = s;\r\n //sign out seems OK on server side, dispatch SIGNED_OUT event\r\n Shared.EVENT_BUS.fireEvent(new SignEvent(SignEvent.Action.SIGNED_OUT)); //WARN: don't dispatch SIGN_OUT avoiding deadlock call\r\n } else {\r\n Info.display(\"Error\", \"Account is already signed out or database error\");\r\n }\r\n }\r\n\r\n @Override\r\n public void onFailure(Throwable caught) {\r\n Info.display(\"Error\", caught.getMessage());\r\n }\r\n });\r\n }\r\n //process signed_out\r\n if (event.getAction().equals(SignEvent.Action.SIGNED_OUT)){\r\n //delete cookies\r\n cookie.discardCookie(Shared.MY_SESSION); \r\n //return UI to welcome status\r\n RootPanel.get().clear();\r\n RootPanel.get().add(new LoginPage()); \r\n Info.display(\"See you\", \"You are now signed out!\");\r\n }\r\n }\r\n });\r\n \r\n \r\n }", "public static Session openSession() {\n \treturn sessionFactory.openSession();\n }", "public boolean onOpenSession() throws java.io.IOException {\n ForwardingClient fwd = manager.getForwardingClient();\r\n\r\n // Now lets setup the forwarding configurations from the profile if\r\n // they dont exist already\r\n pf.setClient(fwd);\r\n\r\n return true;\r\n }", "protected boolean shouldValidateSession ()\n {\n return false;\n }" ]
[ "0.72832626", "0.67375416", "0.62805355", "0.62419754", "0.6197816", "0.61688703", "0.6166349", "0.6123911", "0.6092598", "0.6088612", "0.60707444", "0.60707444", "0.60617423", "0.60551864", "0.59852475", "0.59519", "0.5918901", "0.5897668", "0.5847024", "0.5825814", "0.5806847", "0.5802801", "0.5784174", "0.578235", "0.5776916", "0.57451385", "0.57405955", "0.57387275", "0.57191247", "0.5707772", "0.5698363", "0.56979537", "0.5690153", "0.56874514", "0.5666561", "0.5666118", "0.56567925", "0.56432897", "0.56408846", "0.56299126", "0.56276906", "0.5623082", "0.55970734", "0.5577536", "0.55772907", "0.5571066", "0.5564059", "0.555193", "0.55513537", "0.55433905", "0.5541154", "0.5538648", "0.55352026", "0.5533136", "0.5533136", "0.5526056", "0.55225134", "0.55042636", "0.5495674", "0.5489986", "0.54883987", "0.54879653", "0.5486709", "0.5469257", "0.54605746", "0.54557127", "0.54548377", "0.54531413", "0.54516745", "0.5449408", "0.54429793", "0.54428315", "0.54394966", "0.5433242", "0.5431398", "0.54294276", "0.54271305", "0.54251826", "0.5422052", "0.5419361", "0.5418894", "0.5417556", "0.5410842", "0.54077387", "0.5405828", "0.54027325", "0.5400959", "0.53968894", "0.53963965", "0.5396016", "0.5392736", "0.53887284", "0.5388574", "0.5376936", "0.5375085", "0.5373465", "0.53707093", "0.53657204", "0.5359104", "0.5350364", "0.5349126" ]
0.0
-1
TODO Autogenerated method stub
@Override public View getView(int position, View convertView, ViewGroup parent) { ViewHolder viewHolder; if (convertView == null) { viewHolder = new ViewHolder(); convertView = InjectProcessor.injectListViewHolder(viewHolder); convertView.setTag(viewHolder); } else { viewHolder = (ViewHolder) convertView.getTag(); } minfo = models.get(position); viewHolder.image.setImageUrl(minfo.getImagesrc(), HttpRequest.getInstance().imageLoader); viewHolder.name.setText(minfo.getTitle()); return convertView; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\n public void perish() {\n \n }", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "@Override\n\tpublic void anular() {\n\n\t}", "@Override\n\tprotected void getExras() {\n\n\t}", "@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}", "@Override\n\tpublic void entrenar() {\n\t\t\n\t}", "@Override\n\tpublic void nadar() {\n\t\t\n\t}", "@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}", "@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}", "@Override\n\tprotected void interr() {\n\t}", "@Override\n\tpublic void emprestimo() {\n\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\n\tpublic void grabar() {\n\t\t\n\t}", "@Override\n\tpublic void gravarBd() {\n\t\t\n\t}", "@Override\r\n\tpublic void rozmnozovat() {\n\t}", "@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}", "@Override\n protected void getExras() {\n }", "@Override\r\n\tpublic void publierEnchere() {\n\t\t\r\n\t}", "@Override\n\tpublic void nefesAl() {\n\n\t}", "@Override\n\tpublic void ligar() {\n\t\t\n\t}", "@Override\n public void func_104112_b() {\n \n }", "@Override\n\tprotected void initdata() {\n\n\t}", "@Override\n\tpublic void nghe() {\n\n\t}", "@Override\n public void function()\n {\n }", "@Override\n public void function()\n {\n }", "public final void mo51373a() {\n }", "@Override\r\n\tpublic void stehReagieren() {\r\n\t\t//\r\n\t}", "@Override\n public void inizializza() {\n\n super.inizializza();\n }", "@Override\n\tprotected void initData() {\n\t\t\n\t}", "@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}", "@Override\n\tpublic void sacrifier() {\n\t\t\n\t}", "@Override\r\n\tprotected void InitData() {\n\t\t\r\n\t}", "public void designBasement() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}", "public void gored() {\n\t\t\n\t}", "@Override\r\n\tprotected void initData() {\n\r\n\t}", "@Override\n\tpublic void einkaufen() {\n\t}", "@Override\n protected void initialize() {\n\n \n }", "public void mo38117a() {\n }", "@Override\n\tprotected void getData() {\n\t\t\n\t}", "Constructor() {\r\n\t\t \r\n\t }", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "@Override\n\tpublic void one() {\n\t\t\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "private stendhal() {\n\t}", "@Override\n\tprotected void update() {\n\t\t\n\t}", "@Override\n\t\t\tpublic void ic() {\n\t\t\t\t\n\t\t\t}", "@Override\n\tprotected void initData() {\n\n\t}", "@Override\n\tprotected void initData() {\n\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n public void init() {\n\n }", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\n\tpublic void debite() {\n\t\t\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "public contrustor(){\r\n\t}", "@Override\n\tprotected void initialize() {\n\n\t}", "@Override\r\n\tpublic void dispase() {\n\r\n\t}", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "@Override\n\tpublic void dtd() {\n\t\t\n\t}", "@Override\n\tprotected void logic() {\n\n\t}", "@Override\n\tprotected void lazyLoad() {\n\t\t\n\t}", "public void mo4359a() {\n }", "@Override\r\n\tprotected void initialize() {\n\r\n\t}", "@Override\n public void memoria() {\n \n }", "@Override\n\t\tpublic void method() {\n\t\t\t\n\t\t}", "private RepositorioAtendimentoPublicoHBM() {\r\t}", "@Override\n protected void initialize() \n {\n \n }", "@Override\r\n\tpublic void getProposition() {\n\r\n\t}", "@Override\n\tpublic void particular1() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n protected void prot() {\n }", "@Override\r\n\tpublic void init()\r\n\t{\n\t}", "@Override\n\tprotected void initValue()\n\t{\n\n\t}", "public void mo55254a() {\n }" ]
[ "0.6671074", "0.6567672", "0.6523024", "0.6481211", "0.6477082", "0.64591026", "0.64127725", "0.63762105", "0.6276059", "0.6254286", "0.623686", "0.6223679", "0.6201336", "0.61950207", "0.61950207", "0.61922914", "0.6186996", "0.6173591", "0.61327106", "0.61285484", "0.6080161", "0.6077022", "0.6041561", "0.6024072", "0.6020252", "0.59984857", "0.59672105", "0.59672105", "0.5965777", "0.59485507", "0.5940904", "0.59239364", "0.5910017", "0.5902906", "0.58946234", "0.5886006", "0.58839184", "0.58691067", "0.5857751", "0.58503544", "0.5847024", "0.58239377", "0.5810564", "0.5810089", "0.5806823", "0.5806823", "0.5800025", "0.5792378", "0.5792378", "0.5792378", "0.5792378", "0.5792378", "0.5792378", "0.5790187", "0.5789414", "0.5787092", "0.57844025", "0.57844025", "0.5774479", "0.5774479", "0.5774479", "0.5774479", "0.5774479", "0.5761362", "0.57596046", "0.57596046", "0.575025", "0.575025", "0.575025", "0.5747959", "0.57337177", "0.57337177", "0.57337177", "0.5721452", "0.5715831", "0.57142824", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.5711723", "0.57041645", "0.56991017", "0.5696783", "0.56881124", "0.56774884", "0.56734604", "0.56728", "0.56696945", "0.5661323", "0.5657007", "0.5655942", "0.5655942", "0.5655942", "0.56549734", "0.5654792", "0.5652974", "0.5650185" ]
0.0
-1
Constructor Setting name of the animal and HomeType
public Tiger(String name) { setName(name); super.Home = "forest."; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "AnimalSpecific(String category,String name,String type){\n\t\tsuper(category);\n\t\tanimalName = name;\n\t\tanimalType = type;\n\t}", "public Animal(String name) {\r\n this.animalName = name;\r\n }", "public Animal(String tipo){\n\t\tthis.tipo = tipo;\n\t}", "public Animal(String name, String type, String color, String date, String email, String location,\n String latitude, String longitude, String phone, String token, String description,\n String thumbUrl, String key, String status) {\n this.name = name;\n this.type = type;\n this.color = color;\n this.date = date;\n this.email = email;\n this.location = location;\n this.latitude = latitude;\n this.longitude = longitude;\n this.phone = phone;\n this.token = token;\n this.description = description;\n this.thumbUrl = thumbUrl;\n this.key = key;\n this.status = status;\n }", "public ServiceProviderAnimalType() {\n super();\n animalSize = AnimalSize.SMALL;\n billingType = BillingType.PER_HOUR;\n }", "public void constructor() {\n setEdibleAnimals();\n }", "public DataSetAnimal(String breedOrType, String name, int yearOfBirth) {\n this.breedOrType = breedOrType;\n this.name = name;\n this.yearOfBirth = yearOfBirth;\n }", "public Animal(){\n System.out.println(\"An animal has been created...\");\n }", "public Animal(String hewan, int x, int y) {\n switch (hewan) {\n case \"Bekantan\": {\n name = \"Bekantan\";\n habitat = \"Land\";\n weight = 50;\n type = \"Herbivore\";\n tamed = true;\n diet = \"Fruit\";\n legs = 2;\n content = 'A';\n suara = \"Uuuuuuuu\";\n break;\n }\n case \"BurungHantu\": {\n name = \"Burung Hantu\";\n habitat = \"Air\";\n weight = 2;\n type = \"Carnivore\";\n tamed = true;\n diet = \"Meat\";\n legs = 2;\n content = 'B';\n suara = \"Kur kur kur\";\n break;\n }\n case \"Codot\": {\n name = \"Codot\";\n habitat = \"Air\";\n weight = (float) 0.5;\n type = \"Herbivore\";\n tamed = false;\n diet = \"Fruit\";\n legs = 2;\n content = 'C';\n suara = \"Cit cit cit\";\n break;\n }\n case \"Elang\": {\n name = \"Elang\";\n habitat = \"Air\";\n weight = 3;\n type = \"Carnivore\";\n tamed = false;\n diet = \"Meat\";\n legs = 2;\n content = 'D';\n suara = \"Koak koakk koakk\";\n break;\n }\n case \"Gajah\": {\n name = \"Gajah\";\n habitat = \"Land\";\n weight = 3500;\n type = \"Herbivore\";\n tamed = true;\n diet = \"Leaf\";\n legs = 4;\n content = 'E';\n suara = \"Ngoett\";\n break;\n }\n case \"Gorilla\": {\n name = \"Gorilla\";\n habitat = \"Land\";\n weight = 200;\n type = \"Herbivore\";\n tamed = false;\n diet = \"Fruit\";\n legs = 2;\n content = 'C';\n suara = \"Huhahuha\";\n break;\n }\n case \"Harimau\": {\n name = \"Harimau\";\n habitat = \"Land\";\n weight = 450;\n type = \"Carnivore\";\n tamed = false;\n diet = \"Meat\";\n legs = 4;\n content = 'G';\n suara = \"Roarrrr\";\n break;\n }\n case \"Hiu\": {\n name = \"Hiu\";\n habitat = \"Water\";\n weight = 100;\n type = \"Carnivore\";\n tamed = true;\n diet = \"Meat\";\n legs = 0;\n content = 'H';\n suara = \"Shush shush\";\n break;\n }\n case \"IkanTerbang\": {\n name = \"Ikan Terbang\";\n habitat = \"Water\";\n weight = 2;\n type = \"Carnivore\";\n tamed = true;\n diet = \"Insect\";\n legs = 0;\n content = 'I';\n suara = \"Cepok cepok cepok\";\n break;\n }\n case \"Jerapah\": {\n name = \"Jerapah\";\n habitat = \"Land\";\n weight = 500;\n type = \"Herbivore\";\n tamed = true;\n diet = \"Leaf\";\n legs = 4;\n content = 'J';\n suara = \"Ngoet ngoet\";\n break;\n }\n case \"Kancil\": {\n name = \"Kancil\";\n habitat = \"Land\";\n weight = 60;\n type = \"Herbivore\";\n tamed = true;\n diet = \"Leaf\";\n legs = 4;\n content = 'K';\n suara = \"Ngik ngik ngik\";\n break;\n }\n case \"Kepik\": {\n name = \"Kepik\";\n habitat = \"Air\";\n weight = (float) 0.01;\n type = \"Herbivore\";\n tamed = true;\n diet = \"Nectar\";\n legs = 6;\n content = 'L';\n suara = \"Krik krik krik\";\n break;\n }\n case \"Kepiting\": {\n name = \"Kepiting\";\n habitat = \"Water\";\n weight = 1;\n type = \"Omnivore\";\n tamed = true;\n diet = \"Plankton\";\n legs = 10;\n content = 'M';\n suara = \"Kuikk kuikk\";\n break;\n }\n case \"KumbangHutan\": {\n name = \"Kumbang Hutan\";\n habitat = \"Air\";\n weight = (float) 0.05;\n type = \"Herbivore\";\n tamed = true;\n diet = \"Nectar\";\n legs = 6;\n content = 'N';\n suara = \"Kruk kruk kruk\";\n break;\n }\n case \"KupuKupu\": {\n name = \"KupuKupu\";\n habitat = \"Air\";\n weight = (float) 0.03;\n type = \"Herbivore\";\n tamed = true;\n diet = \"Nectar\";\n legs = 6;\n content = 'O';\n suara = \"Wir wir\";\n break;\n }\n case \"Lobster\": {\n name = \"Lobster\";\n habitat = \"Water\";\n weight = (float) 0.5;\n type = \"Omnivore\";\n tamed = true;\n diet = \"Plankton\";\n legs = 10;\n content = 'P';\n suara = \"Crek crek crek\";\n break;\n }\n case \"LumbaLumba\": {\n name = \"Lumba lumba\";\n habitat = \"Water\";\n weight = 100;\n type = \"Omnivore\";\n tamed = true;\n diet = \"Plankton\";\n legs = 0;\n content = 'Q';\n suara = \"Cet cet cet\";\n break;\n }\n case \"MacanTutul\": {\n name = \"Macan Tutul\";\n habitat = \"Land\";\n weight = 350;\n type = \"Carnivore\";\n tamed = true;\n diet = \"Meat\";\n legs = 4;\n content = 'R';\n suara = \"Aummmm\";\n break;\n }\n case \"OwaOwa\": {\n name = \"OwaOwa\";\n habitat = \"Land\";\n weight = 70;\n type = \"Herbivore\";\n tamed = true;\n diet = \"Fruit\";\n legs = 2;\n content = 'S';\n suara = \"Huhuhuhu\";\n break;\n }\n case \"PausSperma\": {\n name = \"Paus Sperma\";\n habitat = \"Water\";\n weight = 7000;\n type = \"Omnivore\";\n tamed = true;\n diet = \"Plankton\";\n legs = 0;\n content = 'T';\n suara = \"Srosh srosh\";\n break;\n }\n case \"Piranha\": {\n name = \"Piranha\";\n habitat = \"Water\";\n weight = (float) 0.7;\n type = \"Carnivore\";\n tamed = false;\n diet = \"Meat\";\n legs = 0;\n content = 'U';\n suara = \"Kraus kraus\";\n break;\n }\n case \"Platypus\": {\n name = \"Platypus\";\n habitat = \"Land and Water\";\n weight = 5;\n type = \"Carnivore\";\n tamed = true;\n diet = \"Insect\";\n legs = 4;\n content = 'V';\n suara = \"Krr krr\";\n break;\n }\n case \"Singa\": {\n name = \"Singa\";\n habitat = \"Land\";\n weight = 400;\n type = \"Carnivore\";\n tamed = false;\n diet = \"Meat\";\n legs = 4;\n content = 'W';\n suara = \"Groarrr\";\n break;\n }\n case \"SingaLaut\": {\n name = \"Singa Laut\";\n habitat = \"Water\";\n weight = 70;\n type = \"Carnivore\";\n tamed = false;\n diet = \"Meat\";\n legs = 0;\n content = 'X';\n suara = \"Ou ou ou\";\n break;\n }\n default: {\n name = \"NULL\";\n habitat = \"NULL\";\n weight = 0;\n type = \"NULL\";\n tamed = false;\n diet = \"NULL\";\n legs = 0;\n content = '-';\n suara = \"NULL\";\n break;\n }\n }\n fodder = (float) 0.025 * weight;\n locX = x;\n locY = y;\n nAnimal++;\n consumerate += fodder;\n }", "protected Animal() {\t\r\n\t}", "public Dog(String Breed, String PrimaryColor, String Size, String name, int age){\r\n // setting the parent animal name\r\n super(name,age);\r\n // setting the parent animal age\r\n // System.out.println(\"Setting Breed...\");\r\n this.Breed = Breed ;\r\n // System.out.println(\"Setting PrimaryColor...\");\r\n this.PrimaryColor = PrimaryColor;\r\n //System.out.println(\"Setting Size...\");\r\n this.Size = Size;\r\n\r\n\r\n\r\n }", "public Appliance(String type, String brandName){\n this.type = type;\n this.brandName = brandName;\n System.out.println(\"Test hello\");\n }", "public Animal() {\n\t\tSystem.out.println(\"Animal constructor called\");\n\t}", "public void setAnimalName(java.lang.String param) {\n localAnimalNameTracker = true;\n\n this.localAnimalName = param;\n }", "public void createAnimals() {\n\t\tanimals = new Animal[noAnimals];\n\n\t\tfor (int i = 0; i < noAnimals; i++) {\n\t\t\tanimals[i] = new Animal(noAnimals);\n\t\t\tanimals[i].setDiffCo(diffCo[i]);\n\t\t\tanimals[i].setDiffusionRate(diffusionRate[i]);\n animals[i].initiateDensities(getIo().getNeighbours().length,getIo().getNeighbours()[0].length);\n\t\t}\n\t\n\t\t animals[0].setName(\"Hare\"); \n\t\t animals[1].setName(\"Puma\");\n\t}", "public static void main(String[] args) {\n AnimalBp turtle = new AnimalBp(); \n AnimalBp dog = new AnimalBp();\n AnimalBp cat = new AnimalBp();\n \n \n \n turtle .setType(\"Reptile\");\n String turtleType = turtle.getType();\n \n \n System.out.println(turtleType);\n \n turtle.setnumberOfFeet(4);\n int turtlenumberOfFeet = turtle.getnumberOfFeet();\n \n System.out.println(turtlenumberOfFeet);\n \n turtle.setColor(\"Green\");\n String turtleColor = turtle.getColor();\n \n System.out.println(turtleColor);\n \n turtle.setlaysAnEgg(true);\n boolean turtlelaysAnEgg = turtle.getLaysAnEgg();\n \n System.out.println(turtlelaysAnEgg);\n \n \n dog .setType(\"Mammal\");\n String dogType = dog.getType();\n \n System.out.println(dogType);\n \n dog.setnumberOfFeet(4);\n int dognumberOfFeet = dog.getnumberOfFeet();\n \n System.out.println(dognumberOfFeet);\n \n dog.setColor(\"Brown and White\");\n String dogColor = dog.getColor();\n \n System.out.println(dogColor);\n \n dog.setlaysAnEgg(false);\n boolean doglaysAnEgg = dog.getLaysAnEgg();\n \n System.out.println(doglaysAnEgg);\n \n cat .setType(\"Mammal\");\n String catType = cat.getType();\n \n \n System.out.println(catType);\n \n cat.setnumberOfFeet(4);\n int catnumberOfFeet = cat.getnumberOfFeet();\n \n System.out.println(catnumberOfFeet);\n \n cat.setColor(\"gray\");\n String catColor = cat.getColor();\n \n System.out.println(catColor);\n \n cat.setlaysAnEgg(false);\n boolean catlaysAnEgg = cat.getLaysAnEgg();\n \n System.out.println(catlaysAnEgg);\n }", "public Animal(int age){\n this.age = age;\n System.out.println(\"An animal has been created!\");\n }", "private AttributeTypeHome( )\n {\n }", "public Animal(String name){\n\n this.name = name;\n //array2.add(new String(name2));\n }", "@Override\n\tString getName(){\n\t\treturn animalName;\n\t}", "public BloodType(String name){\r\n bloodType=name;\r\n }", "public static void main(String[] args) {\n Animal myAnimal = new Animal();\n myAnimal.animalSound();\n\n myAnimal = new Dog();\n myAnimal.animalSound();\n\n myAnimal = new Cat();\n myAnimal.animalSound();\n\n }", "public Archer(String archerName) {\n\tname = archerName;\n\thealth = 100;\n\tstrength = 100;\n\tdefense = 20;\n\tattack = 2.5;\n }", "public static void main(String[] args) {\n llama coolAnimal = new llama();\n llama.giveName();\n llama.giveGender();\n llama.name = \"joe the llama papa\";\n llama.gender = \"male\";\n llama.giveName();\n llama.giveGender();\n unicorn.giveName();\n unicorn.giveGender();\n\n }", "public Animal(String type, int poundsOfFoodToEat) {\n\t\tif (type == null) {\n\t\t\tthrow new IllegalArgumentException(\"type must not be null\");\n\t\t}\n\t\tif (type.isEmpty()) {\n\t\t\tthrow new IllegalArgumentException(\"type must not be empty\");\n\t\t}\n\t\tif (poundsOfFoodToEat <= 0) {\n\t\t\tthrow new IllegalArgumentException(\"weight of food must be positive\");\n\t\t}\n\t\tthis.type = type;\n\t\tthis.poundsOfFoodNeeded = poundsOfFoodToEat;\n\t}", "public static void createArmy() {\n Unit unitOne = new Unit(\"Unit One\");\n Unit unitTwo = new Unit(\"Unit Two\");\n Unit unitThree = new Unit(\"Unit Three\");\n Unit unitFour = new Unit(\"Unit Four\");\n Unit unitFive = new Unit(\"Unit Five\");\n\n Knight knightOne = new Knight(\"Knight One\");\n Knight knightTwo = new Knight(\"Knight Two\");\n Knight knightThree = new Knight(\"Knight Three\");\n\n General general = new General(\"General\");\n Doctor doctor = new Doctor(\"Doctor\");\n }", "public MountainGoat(String owner, String age) {\n\t\t// TODO Auto-generated constructor stub \n\t\tsuper(owner, \"Mountain Goat\", age);\n\t \n\t}", "public Animal()\n {\n MOVE_RIGHT = 0;\n MOVE_LEFT = 0;\n MOVE_UP = 0;\n MOVE_DOWN = 0;\n }", "public static void main(String[] args) {\n\t\tMainAnimal mainAnimal = new MainAnimal();\r\n\t\tmainAnimal.init();\r\n\t}", "public Animal()\n\t{\t\n\t\tgender = rng.nextBoolean();\n\t\tstrength = rng.nextFloat() * 100;\n\t}", "public static void main(String... args) {\n Mammal mammal = new Mammal();\n mammal.getName();\n Bird bird = new Bird();\n bird.getName();\n\n System.out.println(\"showAnimal(AbstractAnimal abstractAnimal) \");\n showAnimal(mammal);\n showAnimal(bird);\n }", "public void setAnimal(Animal animal) {\n\t\tthis.animal = animal;\r\n\t}", "public Human(int theShipType){\n super(theShipType);\n }", "Animal(int age, String name, double weight){\n\t\tthis.age = age;\n\t\tthis.name = name;\n\t\tthis.weight = weight;\n\t\t\n\t\t//make objects:\n\t\tmyHeart = new Heart();\n\t\tmyLiver = new Liver();\n\t\tmyKidney = new Kidney();\n\t\tmyLungs = new Lungs();\n\t\t\n\t\tSystem.out.println(myHeart.bpm);\n\t\tSystem.out.println(myLiver.id);\n\t\tSystem.out.println(\"end of Animal constructor\");\n\t\t\n\t\tmyKidney.alive(); //accessing the alive method from the local Beghaviour interface that this implements.\n\t\tmyLungs.alive();\n\t\t\n\t}", "public static void main(String[] args) {\n\t\tString animalType = args[0];\n\t\t\n\t\t//Creating object of Animal Factory\n\t\tAnimalFactory animalFactory = new AnimalFactory();\n\t\t\n\t\t//Creating animal of type passed in command line\n\t\tAnimal animal = animalFactory.createAnimal(animalType);\n\t\tanimal.eat();\n\t}", "public Animal(String message){\n name=\"Bob the Animal\";\n System.out.println(message);\n }", "public static com.nowcoder.Animal getAnimal(int type) {\n return new com.nowcoder.Human(\"Lei\", 22, \"CN\");\n }", "public BasicSpecies() {\r\n\r\n\t}", "public Bird(String name,int age, double weight,String sound, int noOfLegs,boolean canFly,AnimalType type) {\n\t\t\n\t\tsuper(name,age,weight,sound,noOfLegs,AnimalCategory.BIRD,type);\n\t\tthis.canFly=canFly;\n\t}", "public Animal(int theAge) {\n\t\t// TODO Auto-generated constructor stub\n\t\tage = theAge;\n\t}", "public Animal(int row, int col, String sex, String type) {\n this.row = row;\n this.col = col;\n this.sex = sex;\n this.type = type;\n this.typeChar = type.charAt(0);\n }", "public Animal(String farmObjectType, int purchasePrice){\n\t\tthis.setFarmObjectType(farmObjectType); \n\t\tthis.setPurchasePrice(purchasePrice);\n\t\tthis.setHealth(100); \n\t\tthis.setHappiness(100); \n\t}", "Dog(){\n\t\t\n\t\t//I want to create a chemicals object. Inorder to do this, I have to first create a Cardiac obj, then a Cells obj, then a Chemicals object.\n\t\t//I have to create a Chemicals object, to get a chemicals constructor \n\t\tnew Cardiac().new Cells().new Chemicals();\n\t\t\n\t}", "public Dog(String name, int size, int weight, int eyes, int legs, int tail, int teeth, String coat) {\n //super means to call a constructor from the class we are extending\n //can set values or call in the above constructor, your choice\n super(name, 1, 1, size, weight);\n //these are for the strictly dog paramters\n this.eyes = eyes;\n this.legs = legs;\n this.tail = tail;\n this.teeth = teeth;\n this.coat = coat;\n }", "public static void main(String[] args) {\n\t\tAnimals an = new Animals();\r\n\t\tan.eat();\r\n\t\tan.similar();\r\n\t\tan.sound();\r\n\t\t\r\n\t\t//creating object for Dog class based on Animals class\r\n\t\tAnimals d = new Dog();\r\n\t\td.sound();\r\n\t\td.eat();\r\n\t\t\r\n\t\t//creating object for CAT class based on Animals class.\r\n\t\tAnimals c = new Cat();\r\n\t\tc.sound();\r\n\t\tc.eat();\r\n\t\t\r\n\t\t\r\n\t}", "@Override\n public Animal createAnimal() {\n return new Monkey();\n }", "private void seeAnimal() {\n\r\n\t}", "public void setAnimal(AnimalModel param) {\n localAnimalTracker = true;\n\n this.localAnimal = param;\n }", "public static void main(String[] args) {\n\n Animal dog = new Dog(\"Sunis\");\n Animal cat = new Cat(\"Kate\");\n\n showAnimalName(dog);\n showWalkingAction((IWalking) dog);\n showAnimalName(cat);\n showWalkingAction((IWalking) cat);\n\n }", "private static void ListAnimalByType() {\n\t\t\n\t\tshowMessage(\"Choose one type to list:\\n\");\n showMessage(\"1 - Dog\");\n showMessage(\"2 - Cat\");\n showMessage(\"3 - Bird\");\n showMessage(\"4 - Hamster\");\n showMessage(\"5 - Rabbit\");\n showMessage(\"6 - Back to previous menu.\");\n \n int option = getUserAnimalByType();\n /** switch case option start below */\n\t\tswitch (option){\n\n case 1 : ToScreen.listAnimal(animals.getDogList(), true); ListAnimalByType();\n break;\n case 2 : ToScreen.listAnimal(animals.getCatList(), true); ListAnimalByType();\n break;\n case 3 : ToScreen.listAnimal(animals.getBirdList(), true); ListAnimalByType();\n \tbreak;\n case 4 : ToScreen.listAnimal(animals.getHamsterList(), true); ListAnimalByType();\n \tbreak;\n case 5 : ToScreen.listAnimal(animals.getRabbitList(), true); ListAnimalByType();\n \tbreak;\n case 6 : main();\n \tbreak;\n \n default: ListAnimalByType();\n\n\t\t}\n\t\t\n\t}", "@Override\n\tpublic void tipoAnimal() {\n\t\tSystem.out.println(super.getNome() + \" é um gato.\");\n\t}", "public AddAnimalButton(String type, float x, float y, JunglePark park)\r\n {\r\n //put the button into the park system\r\n super(x, y, park);\r\n\r\n //make the type lowercase\r\n this.type = type.toLowerCase();\r\n\r\n //create the label\r\n this.label = \"Add \" + type;\r\n }", "public Fish(String species, String desc)\n {\n super(species, desc);\n toy = \"Jesus net\";\n }", "public Monster(String name, String type) {\r\n\t\tthis(name, new String[] { type });\r\n\t}", "public AbstractWand(String Name, String Type)\n {\n this.Name = Name;\n this.Type = Type;\n }", "Paranormal(String name, String origin, int dangerrating, String foodType, int foodAmt){\n super(name, origin, dangerrating);\n foodType = \"meat\";\n foodAmt = 5;\n }", "public Fish(String name, String gender){\n this.name = name;\n this.gender = gender;\n this.value = 10;\n this.eats = whatItEats(new fishFood());\n this.portionSize = 20;\n this.minimumOffspring = 1;\n this.maximumOffspring = 12;\n this.maxAge = 4;\n this.vetCost = 2;\n }", "public void setFoodType(String food);", "public Fish() {\r\n\t}", "public CibrSysAnimalExample() {\n oredCriteria = new ArrayList<Criteria>();\n }", "public BirdFoodTest()\r\n {\r\n }", "public Animal getRandomAnimal() {\n //Randomize all characteristics of an animal\n int spc = (int) Math.round(rd.nextDouble() * (Animal.enumSpecies.values().length - 1));\n boolean isPet = rd.nextBoolean();\n\n //Construct an animal with random characteristic\n //Animal(int age, Gender g, BodyType b, enumSpecies espec, boolean ispet)\n A = new Animal(Animal.enumSpecies.values()[spc], isPet);\n return A;\n }", "public void spawn(boolean type)\n\t{\n\t\tif (type)\n\t\t{\n\t\t\triver[findEmpty()] = new Bear();\n\t\t}\n\t\telse\n\t\t{\n\t\t\triver[findEmpty()] = new Fish();\n\t\t}\n\t}", "public CyberPet ( String str )\r\n {\r\n name = str;\r\n }", "public static void main(String[] args) {\n Animal zebra=new Animal(\"Pol\", \"Male\", 11, \"Zebra\");\n zebra.sleep();\n zebra.walk();\n zebra.eat();\n \n Animal giraffe=new Animal(\"Necky\",\"Female\",23,\"Giraffe\");\n giraffe.sleep();\n giraffe.walk();\n giraffe.eat();\n \n \n}", "Vehicle() \n {\n System.out.println(\"Constructor of the Super class called\");\n noOfTyres = 5;\n accessories = true;\n brand = \"X\";\n counter++;\n }", "public void setTypeOfFood(String foodType){\n typeOfFood = foodType;\n }", "public java.lang.String getAnimalName() {\n return localAnimalName;\n }", "public Perro() {\n// super(\"No define\", \"NN\", 0); en caso el constructor de animal tenga parametros\n this.pelaje = \"corto\";\n }", "public Harimau(String namaHarimau)\n\t{\n\t//mengisi pengubah yang diwarisi oleh kelas abstract\n\tHarimau.nama = namaHarimau;\n\t}", "public Troop() //make a overloaded constructor \n\t{\n\t\ttroopType = \"light\"; \n\t\tname = \"Default\";\n\t\thp = 50;\n\t\tatt = 20;\n\t}", "public static void main(String[] args) {\n\n\t\t\n\t\t\n\t\tAnimal animal=new Animal();\n\t\tanimal.makeNoice();\n\t\t\n\t\tHorse horse= new Horse();\n\t\thorse.makeNoice();\n\t\t\n\t\tDog dog= new Dog();\n\t\tdog.makeNoice();\n\t\t\n\t\t\n\t\t\n\t\t\n\t}", "public Bird(String name) {\n this.name = this.name+name;\n }", "public static void main(String[] args) {\n\t\t// TODO Auto-generated method stub\n\t\t\n\t\tAnimal a1 = new Animal(\"Köpek\", \"Kuçi\",\"boy\",2);\n\t\tAnimal a2 = new Animal();\n\t\t\n\t\ta2.setName(\"Badi\");\n\t\ta2.setAge(3);\n\t\ta2.setGender(\"by\");\n\t\ta2.setType(\"Köpek\");\n\t\t\n\t\tSystem.out.println(a2.getAge()+\" \"+ a2.getName()+\" \"+ a2.getType());\n\t\t\n\t\ta1.hunt();\n\t\ta1.eat();\n\n\t}", "public static void main(String[] args) {\n\t\tAnimal humanoid = AnimalFactory.getAnimal(new HumanFactory(\"Model MK23\", \"Artificial Intelligence\"));\r\n\t\tAnimal cutedog = AnimalFactory.getAnimal(new DogFactory(\"Cute Model MC3\", \"Life long friend\"));\r\n\t\tSystem.out.println(\"AbstractFactory Human Properties => \" + humanoid);\r\n\t\tSystem.out.println(\"AbstractFactory Dog Properties => \" + cutedog);\r\n\t}", "public VehicleType() { }", "public static void main (String[] args) \n\t {\n\t Animal an1 = new Animal(\"Bobby\", \"ocean\",120,\"medium\", 12);\n\t System.out.println(an1.getName());\n\t \t an1.setName(\"Tom\");\n\t System.out.println(\" changed to: \"+ an1.getName());\n\t System.out.println(\" Energy level after sleep changed to: \" + an1.sleep());\n\t \n\t Animal an2 = new Animal(\"Bobby\", \"ocean\",120,\"medium\", 12);\n\n\t \t \n}", "public Person(String victim, int aType, int lvl)\r\n {\r\n items = new ArrayList<Thing>();\r\n name = victim;\r\n type = aType;\r\n level = lvl;\r\n attack = 0;\r\n defense = 0;\r\n \r\n if (aType == HERO) makeHero();\r\n else if (aType>=1 && aType<=5) makeRobot(level);\r\n else if (aType>=6 && aType<=9) makeMonster(level);\r\n else makeBoss();\r\n }", "public tuna_Ep17(String name){ \t// Constructor added in Episode 17\r\n\t\tgirlName = name;\r\n\t}", "public static void main(String[] args) {\n Animal animal= new Animal(\"Animal\", 1,1,5,5);\n Dog dog= new Dog(\"Dingo\", 8,20,2,4,1,20, \"long silky\");\n \n }", "public static Animal getAnimal(AnimalType type){\n switch(type){\n case TIGER:\n return new Tiger();\n case DOG:\n return new Dog();\n case CAT:\n return new Cat();\n }\n return null;\n }", "public MountainBike() {\n super();\n }", "public AnimalBuilder setName(String name) {\n\t\tthis.name=name;\n\t\treturn this;\n\t}", "public Dog ()\n {\n super (\"Dog\", \"Hi! My name is Snoop Dawg\");\n this.x = \"A bone\";\n /*\n * This dog has many features to it\n * Do not provoke it or else it will bite!\n * Otherwise, It's a nice dog so have fun!\n */\n \n \n }", "public Cat(final String name){\n\t\tsuper(name);\n\t}", "public Food() {\n\t\tsuper(\"FOOD.png\");\n\t}", "public Drink(String name){\n this.name = name;\n }", "public String getName() {\r\n return this.animalName;\r\n }", "public BloodType(){\r\n\r\n }", "public PokemonTrainer(String name, ArrayList<AbstractPokemon> pokemonList, AbstractPokemon.Type type)\n {\n faveType = type;\n pokeball = new Pokeball();\n caughtPokemon = pokemonList;\n this.name = name;\n setColor(null);\n }", "public Mage(String name){\n this.name = name; //Set the name of the new mage to the supplied String parameter \"name\"\n this.className = \"Mage\"; //All mages are of the class Mage\n this.sex = \"F\"; //New mages are created as female by default\n this.health = 100; //New mages are created with 100 health\n this.mana = 100; //New mages are created with 100 mana\n this.spells = new ArrayList<Spell>(); //For now, an empty list of spells.\n this.fireball = new Spell(); //All spells are fireballs for now.\n }", "public Astromech(String name1, int hp) {\r\n\t\tsuper(name1, hp, 1);\r\n\r\n\t}", "public Item(String name, ItemType type)\n {\n\tthis.name = name;\n\tthis.type = type;\n }", "public Animal(boolean randomAge, Field field, Location location, int breeding_age, int max_age, double breeding_probability, int max_litter_size)\n {\n alive = true;\n age = 0;\n if(randomAge) {\n age = rand.nextInt(max_age);\n }\n this.field = field;\n setLocation(location);\n this.breeding_age = breeding_age;\n this.max_age = max_age;\n this.breeding_probability = breeding_probability;\n this.max_litter_size = max_litter_size;\n gender = Math.random() < 0.5;\n }", "public Pizza() {\n this(\"small\", 1, 1, 1);\n }", "private EnumCreatureType(Class<?> paramClass, int paramInt, Material parambof, boolean paramBoolean1, boolean isAnimal)\r\n/* 10: */ {\r\n/* 11:29 */ this.e = paramClass;\r\n/* 12:30 */ this.f = paramInt;\r\n/* 13:31 */ this.g = parambof;\r\n/* 14:32 */ this.isPeaceful = paramBoolean1;\r\n/* 15:33 */ this.isAnimal = isAnimal;\r\n/* 16: */ }", "public Food() {\n super(1, 0, 1, 100, 5, 5, Resources.RICHSOIL, Resources.POORSOIL, \"Food\");\n }", "private static void searchAnimalByName() {\n\t\tshowMessage(\"type in the animal's name: \\n\");\n\t\t\n\t\tString name = getUserTextTyped();\n\t\tToScreen.listAnimal(AnimalSearch.byName(name), true);\n\t\t\n\t\t//condition to do another search by name or go back to the main menu\n\t\t//if the user decide for doing another search the method is called again, otherwise it will go back to the main menu\n\t\tint tryAgain = askForGoMainMenu(\"Would you like to search for another name or go back to main menu?\\n Type 1 to search someone else \\n Type 0 to go to menu. \\n Choice: \");\n\t\tif(tryAgain == 1){\n\t\t\tsearchAnimalByName();\n\t\t} else {\n\t\t\tmain();\n\t\t}\n\t\t\n\t}", "ProductType(String name)\n {\n this.name = name;\n }", "public static void main(String[] args) {\n\t\tAnimal1 d=new Dog1();\n\t\td.eat();\n\t\td.makeSound();\n\t\tAnimal1 c=new Cat();\n\t\tc.eat();\n\t\tc.makeSound();\n\t}" ]
[ "0.7601574", "0.75213486", "0.7091622", "0.6929659", "0.68118167", "0.6429741", "0.62801254", "0.62775904", "0.62734705", "0.6270428", "0.62594366", "0.6245481", "0.6236093", "0.62197286", "0.61510605", "0.6057496", "0.60374546", "0.60086006", "0.6000283", "0.5943301", "0.59423435", "0.59319264", "0.5908576", "0.58879197", "0.5871903", "0.58463687", "0.58455366", "0.58277464", "0.5821899", "0.58074594", "0.5799803", "0.5796064", "0.57814026", "0.57513756", "0.574005", "0.57365173", "0.57075596", "0.5695612", "0.5685596", "0.56805325", "0.56718284", "0.563934", "0.56381714", "0.5630939", "0.562322", "0.561466", "0.5613385", "0.5611239", "0.5602662", "0.5586495", "0.5568202", "0.555832", "0.55546725", "0.55382043", "0.5508144", "0.5500472", "0.5496678", "0.54946315", "0.54937863", "0.54847825", "0.54751575", "0.54604185", "0.545313", "0.5452784", "0.54433936", "0.54370606", "0.543378", "0.541959", "0.5414737", "0.5413834", "0.5413658", "0.5409142", "0.5403147", "0.5394567", "0.53913057", "0.53850776", "0.5379509", "0.5375733", "0.5375455", "0.53731596", "0.5371677", "0.53690195", "0.5364442", "0.53407985", "0.53329074", "0.53305566", "0.5328818", "0.53256714", "0.53244525", "0.5322585", "0.5312311", "0.5301352", "0.5300446", "0.5290463", "0.52863795", "0.5284043", "0.5282982", "0.52816", "0.5280873", "0.5268999" ]
0.63116026
6
Generates Regression Test base on the current test.
public RegressionTest generateRegressionTest() { return getInstance().create().regressionTest(this); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n protected LearningPerformanceEvaluator<Example<Instance>> [] getRegressionEvaluatorSetups() {\n \tLearningPerformanceEvaluator<Example<Instance>> value = new BasicRegressionPerformanceEvaluator();\n \tLearningPerformanceEvaluator<Example<Instance>> [] ret = new BasicRegressionPerformanceEvaluator[this.numberTests];\n for (int i = 0; i < this.numberTests; i++) {\n ret[i] = (LearningPerformanceEvaluator<Example<Instance>> ) value.copy();\n }\n return ret;\n }", "@Test\n public void functionalityTest() {\n new TestBuilder()\n .setModel(MODEL_PATH)\n .setContext(new ModelImplementationGroup3())\n .setPathGenerator(new RandomPath(new EdgeCoverage(100)))\n .setStart(\"e_GoToPage\")\n .execute();\n }", "public void test25() throws Exception {\n runTestInDirectory(\"regression\");\n }", "@Test\n public void testLinearRegression() {\n pat1.save();\n\n // We need to create three HealthRecords for the patient with\n // different slopes and intercepts for each stat\n HealthRecordController.getInstance().addRecord(pat1.getPatientID(), new Date(2000, 1, 1), 50, 70, 100, 120);\n HealthRecordController.getInstance().addRecord(pat1.getPatientID(), new Date(2000, 1, 2), 60, 90, 130, 120);\n HealthRecordController.getInstance().addRecord(pat1.getPatientID(), new Date(2000, 1, 3), 70, 110, 160, 120);\n\n try {\n SimpleRegression reg = HealthRecordController.getInstance().linearRegression(pat1.getPatientID(),\n new Date(2000, 1, 1), new Date(2000, 1, 3), RegressionTypes.DIA);\n assert (reg.getIntercept() == 50.0 && reg.getSlope() == 10.0);\n reg = HealthRecordController.getInstance().linearRegression(pat1.getPatientID(),\n new Date(2000, 1, 1), new Date(2000, 1, 3), RegressionTypes.SYS);\n assert (reg.getIntercept() == 70.0 && reg.getSlope() == 20.0);\n reg = HealthRecordController.getInstance().linearRegression(pat1.getPatientID(),\n new Date(2000, 1, 1), new Date(2000, 1, 3), RegressionTypes.GLUCOSE);\n assert (reg.getIntercept() == 100.0 && reg.getSlope() == 30.0);\n } catch (NonexistentRecordException nre) {\n nre.printStackTrace();\n }\n }", "@Test\n public void testImprimirStatistics()\n {\n //this.linealRegressionCalculator.printStatistics();\n }", "TrainingTest createTrainingTest();", "@Test\n public void testTrain_RegressionDataSet() {\n System.out.println(\"train\");\n RegressionDataSet trainSet = FixedProblems.getSimpleRegression1(150, new Random(2));\n RegressionDataSet testSet = FixedProblems.getSimpleRegression1(50, new Random(3));\n\n for (boolean modification1 : new boolean[] { true, false })\n for (SupportVectorLearner.CacheMode cacheMode : SupportVectorLearner.CacheMode.values()) {\n PlattSMO smo = new PlattSMO(new RBFKernel(0.5));\n smo.setCacheMode(cacheMode);\n smo.setC(1);\n smo.setEpsilon(0.1);\n smo.setModificationOne(modification1);\n smo.train(trainSet);\n\n double errors = 0;\n for (int i = 0; i < testSet.size(); i++)\n errors += Math.pow(testSet.getTargetValue(i) - smo.regress(testSet.getDataPoint(i)), 2);\n assertTrue(errors / testSet.size() < 1);\n }\n }", "public void soaktest() {\n\t\ttry {\n\t\t\tint errCount = 0;\n\n\t\t\tfor (int i = 1; i <= 100; i++) {\n\t\t\t\tRegression test = new Regression();\n\t\t\t\ttest0();\n\t\t\t\ttest.test1(m1);\n\t\t\t\ttest.test2(m1);\n\t\t\t\ttest.test3(m1);\n\t\t\t\ttest.test4(m1);\n\t\t\t\ttest.test5(m1);\n\t\t\t\ttest.test6(m1);\n\t\t\t\ttest.test7(m1, m2);\n\t\t\t\ttest.test8(m1);\n\t\t\t\ttest.test9(m2);\n\t\t\t\ttest.test10(m3);\n\t\t\t\ttest.test11(m1, m2);\n\t\t\t\ttest.test12(m1);\n\t\t\t\ttest.test13(m1);\n\t\t\t\ttest.test14(m1);\n\t\t\t\ttest.test15(m1);\n\t\t\t\ttest.test16(m1);\n\t\t\t\ttest.test17(m1);\n\t\t\t\ttest.test18(m4);\n\t\t\t\ttest.test19(m2, m3);\n\t\t\t\ttest.test97(m1);\n\t\t\t\tif (test.getErrors())\n\t\t\t\t\terrCount++;\n\t\t\t\tif ((i % 10) == 0) {\n\t\t\t\t\tSystem.out.println(\n\t\t\t\t\t\t\"error count = \" + errCount + \" rounds = \" + i);\n\t\t\t\t}\n\t\t\t}\n\t\t} catch (Exception e) {\n\t\t\tSystem.out.println(e);\n\t\t\tassertTrue(false);\n\t\t}\n\t}", "private void generate_test_code()\n {\n int I;\n DataType[] ParamTypes = m_Problem.getParamTypes();\n DataType ReturnType = m_Problem.getReturnType();\n TestCase[] Cases = m_Problem.getTestCases();\n StringBuffer Code = new StringBuffer();\n\n Code.append(\"private:\\n\");\n\n // Generate the vector output function\n Code.append(\"\\ttemplate <typename T> string print_array(const vector<T> &V) { ostringstream os; os << \\\"{ \\\"; for (typename vector<T>::const_iterator iter = V.begin(); iter != V.end(); ++iter) os << \\'\\\\\\\"\\' << *iter << \\\"\\\\\\\",\\\"; os << \\\" }\\\"; return os.str(); }\\n\\n\");\n\n // Generate the verification function\n generate_verification_code(Code, ReturnType);\n\n // Generate the individual test cases\n Code.append(\"\\n\");\n\n /*\n * Generate the test wrapper function that can call\n * either all or individual test cases. (-1 for all)\n */\n Code.append(\"public:\\n\");\n Code.append(\"\\tvoid run_test(int Case) { \\n\");\n Code.append(\"\\t\\tint n = 0;\\n\\n\");\n for (I = 0; I < Cases.length; ++I)\n generate_test_case(I, Code, ParamTypes, ReturnType, Cases[I]);\n // next\n Code.append(\"\\t}\\n\");\n\n // Insert the cut tags\n Code.insert(0, k_BEGINCUT);\n Code.append(k_ENDCUT);\n\n m_Tags.put(k_TESTCODE, Code.toString());\n }", "@Test\n\tpublic void testDoGeneration() {\n\t}", "@Override\n protected String[] getRegressionInputFiles() {\n String value = \"regression.arff\";\n String[] ret = new String[this.numberTests];\n for (int i = 0; i < this.numberTests; i++) {\n ret[i] = value;\n }\n return ret;\n }", "private static void randomPlane(){\n\n\t\t// your code goes there\n LinearRegression linG;\n linG = new LinearRegression(2,5000);\n double la,lb,lc;\n la = generator.nextDouble();\n lb = generator.nextDouble();\n lc = generator.nextDouble();\n double a,b,c;\n a = (200.0*(la)) + -100.0;\n b = (200.0*(lb)) + -100.0;\n c = (200.0*(lc)) + -100.0;\n\n for (int i = 0; i < 5000; i++)\n {\n double lx,ly,lnoise;\n double x,y,noise;\n lx = generator.nextDouble();\n ly = generator.nextDouble();\n lnoise = generator.nextDouble();\n\n x = (3950.0*(lx)) + 50.0;\n y = (3950.0*(ly)) + 50.0;\n noise = (40.0*(lnoise)) + -20.0;\n\n double[] tmp;\n tmp = new double[2];\n tmp[0] = x;\n tmp[1] = y;\n\n linG.addSample(tmp,a*x + b*y + c + noise);\n\n }\n\n System.out.println(\"Current hypothesis :\" + linG.currentHypothesis());\n System.out.println(\"Current cost :\" + linG.currentCost());\n System.out.println(\"Aiming for : x_3 = \"+ a+\"x_1 + \"+b+\"x_2 + \"+c+\"\\n\");\n\n for(int i = 0; i < 10; i++)\n {\n linG.gradientDescent(0.00000004,666);\n\n System.out.println(\"Current hypothesis :\" + linG.currentHypothesis());\n System.out.println(\"Current cost :\" + linG.currentCost());\n System.out.println(\"Aiming for : x_3 = \"+ a+\"x_1 + \"+b+\"x_2 + \"+c+\"\\n\");\n }\n\n\t}", "@Test\n public void testCreateRegressionLearner()\n {\n int ensembleSize = 3 + random.nextInt(1000);\n double baggingFraction = random.nextDouble();\n double dimensionsFraction = random.nextDouble();\n int maxTreeDepth = 3 + random.nextInt(10);\n int minLeafSize = 4 + random.nextInt(10);\n Random random = new Random();\n BaggingRegressionLearner<Vector> result\n = RandomForestFactory.createRegressionLearner(ensembleSize,\n baggingFraction, dimensionsFraction, maxTreeDepth, minLeafSize,\n random);\n assertEquals(ensembleSize, result.getMaxIterations());\n assertEquals(baggingFraction, result.getPercentToSample(), 0.0);\n assertSame(random, result.getRandom());\n @SuppressWarnings(\"rawtypes\")\n RegressionTreeLearner treeLearner = \n (RegressionTreeLearner) result.getLearner();\n assertEquals(maxTreeDepth, treeLearner.getMaxDepth());\n assertTrue(treeLearner.getLeafCountThreshold() >= 2 * minLeafSize);\n assertNull(treeLearner.getRegressionLearner());\n RandomSubVectorThresholdLearner<?> randomSubspace = (RandomSubVectorThresholdLearner<?>)\n treeLearner.getDeciderLearner();\n assertEquals(dimensionsFraction, randomSubspace.getPercentToSample(), 0.0);\n assertSame(random, randomSubspace.getRandom());\n VectorThresholdVarianceLearner splitLearner = (VectorThresholdVarianceLearner)\n randomSubspace.getSubLearner();\n assertEquals(minLeafSize, splitLearner.getMinSplitSize());\n }", "private void generate_run_test_code()\n {\n StringBuffer Code = new StringBuffer();\n\n // Use a static variable to avoid infinite recursion\n Code.append(\"\\t\\tstatic bool s_FirstTime = true; if (s_FirstTime) { s_FirstTime = false; run_test(-1); }\");\n\n // Insert the cut tags\n Code.insert(0, k_BEGINCUT);\n Code.append(k_ENDCUT);\n\n m_Tags.put(k_RUNTEST, Code.toString());\n }", "@Test\n public void testGenererTempsTriangulaire() throws Exception {\n System.out.println(\"genererTempsTriangulaire\");\n double min = 0.0;\n double mode = 0.0;\n double max = 0.0;\n double expResult = 0.0;\n double result = Utils.genererTempsTriangulaire(min, mode, max);\n assertEquals(expResult, result, 0.0);\n // TODO review the generated test code and remove the default call to fail.\n fail(\"The test case is a prototype.\");\n }", "Testcase createTestcase();", "@Test\n\t public void testAdd() {\n\t\t TestSuite suite = new TestSuite(RecommendationModelTest.class, AnalysisModelTest.class);\n\t\t TestResult result = new TestResult();\n\t\t suite.run(result);\n\t\t System.out.println(\"Number of test cases = \" + result.runCount());\n\n\t }", "private String generateTestNGMainClass(ProductMaster product, String testExecutionEngine, String packageName, String destinationDirectory, int nameSource) {\n\t\tJCodeModel codeModel = new JCodeModel();\r\n\t\tString message = null;\r\n\t\ttry {\r\n\t\t\tif (testExecutionEngine == null)\r\n\t\t\t\ttestExecutionEngine = TAFConstants.TESTENGINE_SEETEST;\r\n\t\t\tlog.info(\"Test Execution Engine : \" + testExecutionEngine);\r\n\t\t\t\t\r\n\t\t\tJClass testNGAfterSuiteReference = null;\r\n\t\t\tJClass testNGBeforeSuiteReference = null;\r\n\t\t\ttestNGAfterSuiteReference = codeModel.ref(\"org.testng.annotations.AfterSuite\");\r\n\t\t\ttestNGBeforeSuiteReference = codeModel.ref(\"org.testng.annotations.BeforeSuite\");\r\n\r\n\r\n\t\t\t// 1. Create the class for the main class\r\n\t\t\tJDefinedClass mainClass = codeModel._class(packageName + \".\" + \"Main\");\r\n\t\t\tJDocComment classComment = mainClass.javadoc();\r\n\t\t\tString javadocCommentClass = \"Main driver class for integration of scripts with TAF\"\r\n\t\t\t\t\t\t+ \"\\n\" + \"Product : \" + product.getProductDescription()\r\n\t\t\t\t\t\t+ \"\\n\" + \"Script Type \t\t: \" + TAFConstants.TESTSCRIPT_TYPE_TESTNG\r\n\t\t\t\t\t\t+ \"\\n\" + \"Test Execution Engine \t: \" + testExecutionEngine\r\n\t\t\t\t\t\t+ \"\\n\" + \"Code generated by TAF on \t: \" + new Date(System.currentTimeMillis());\r\n\t\t\tclassComment.append(javadocCommentClass);\r\n\r\n\t\t\t//Add the class variables\r\n\t\t\tmainClass = addClassVariablesForMainClass(codeModel, mainClass, testExecutionEngine);\r\n\t\t\r\n\t\t\t//Add the setup method\r\n\t\t\tJMethod setUpMethod = mainClass.method(JMod.PUBLIC, void.class, \"setUp\");\r\n\t\t\tJDocComment methodComment1 = setUpMethod.javadoc();\r\n\t\t\tString commentString = \"Setup method for the TestSuite/TestRun\";\r\n\t\t\tmethodComment1.append(commentString);\r\n\t\t\tsetUpMethod = constructSetUpMethodForMain(setUpMethod, testExecutionEngine);\r\n\t\t\tsetUpMethod.annotate(testNGBeforeSuiteReference);\r\n\t\t\t\t\r\n\t\t\t//Add the SeeTest Initialization method\r\n\t\t\tif (testExecutionEngine.equals(TAFConstants.TESTENGINE_SEETEST)) {\r\n\t\t\t\tJMethod initSeeTestClientMethod = mainClass.method(JMod.PUBLIC, codeModel.ref(com.experitest.client.Client.class), \"initSeeTestClient\");\r\n\t\t\t\tinitSeeTestClientMethod = constructSeeTestInitMethodForMain(initSeeTestClientMethod, testExecutionEngine, product);\r\n\t\t\t}\r\n\r\n\t\t\t//Add the teardown method\r\n\t\t\tJMethod tearDownMethod = mainClass.method(JMod.PUBLIC, void.class, \"tearDown\");\r\n\t\t\tJDocComment methodComment2 = tearDownMethod.javadoc();\r\n\t\t\tcommentString = \"Teardown method for the TestSuite/TestRun\";\r\n\t\t\tmethodComment2.append(commentString);\r\n\t\t\ttearDownMethod = constructTearDownMethodForMain(tearDownMethod, testExecutionEngine, product);\r\n\t\t\ttearDownMethod.annotate(testNGAfterSuiteReference);\r\n\t\t\t\t\r\n\t\t\t// Add accessor methods\t\t\t\r\n\t\t\tmainClass = constructAccessorMethodsForMain(codeModel, mainClass, testExecutionEngine, product);\r\n\t\t\t\r\n\t\t\tFile sourceFile = new File(destinationDirectory);\r\n\t\t\tif (!sourceFile.exists()) {\r\n\t\t\t\tlog.info(\"Created Directory for source code generation : \" + destinationDirectory);\r\n\t\t\t\tsourceFile.mkdirs();\r\n\t\t\t}\r\n\t\t\tcodeModel.build(sourceFile);\r\n\t\t\tmessage = sourceFile.getAbsolutePath() + MAIN_PACKAGE_NAME_FOLDER + File.separator +\"Main.java\";\r\n\r\n\t\t} catch (JClassAlreadyExistsException e) {\r\n\t\t\tlog.error(\"Unable to generate testcase ref source code class\", e);\r\n\t\t\tmessage = \"Failed : Unable to generate testcase ref source code class\";\r\n\t\t} catch (IOException io) {\r\n\t\t\tlog.error(\"Unable to create file in file system\", io);\r\n\t\t\tmessage = \"Failed : Unable to create file in file system\";\r\n\t\t}\r\n\t\t\r\n\t\tlog.info(\"Success : Generated Main class source code\" + message);\r\n\t\treturn message;\r\n\t}", "@Test\n public void testGetByPassRegression() {\n\tSystem.out.println(\"getByPassRegression\");\n\tJenkinsBuild instance = new JenkinsBuild();\n\tBoolean expResult = null;\n\tBoolean result = instance.getByPassRegression();\n\tassertEquals(expResult, result);\n }", "@Override\n\tpublic Statement apply(final Statement test, final Description testClassDescription) {\n\t\treturn new Statement() {\n\t\t\t\n\t\t\tprivate ScenarioDocuWriter docuWriter = new ScenarioDocuWriter(DOCU_BUILD_DIRECTORY, EXAMPLE_BRANCH_NAME,\n\t\t\t\t\tEXAMPLE_BUILD_NAME);\n\t\t\t\n\t\t\t@Override\n\t\t\tpublic void evaluate() throws Throwable {\n\t\t\t\ttry {\n\t\t\t\t\t// Save use case description\n\t\t\t\t\tUseCase useCase = createUseCase(testClassDescription.getTestClass());\n\t\t\t\t\tLOGGER.info(\"Generating Scenarioo Docu for UseCase \" + useCase.getName() + \": \"\n\t\t\t\t\t\t\t+ useCase.getDescription());\n\t\t\t\t\tdocuWriter.saveUseCase(useCase);\n\t\t\t\t\t// Run tests\n\t\t\t\t\ttest.evaluate();\n\t\t\t\t} finally {\n\t\t\t\t\t// Wait until asynch writing has finished.\n\t\t\t\t\tdocuWriter.flush();\n\t\t\t\t}\n\t\t\t}\n\t\t};\n\t}", "public RandomSubVectorThresholdLearnerTest(\n String testName)\n {\n super(testName);\n\n this.random = new Random();\n }", "public RegonTest( String testName )\n {\n super( testName );\n }", "@Test\n public void trainWithMasterSplinterTest() {\n\n }", "public AbstractMultipleRegressorTestCase(String name) {\n super(name);\n }", "@Override\r\n\tpublic Test getModel() {\n\t\treturn this.test;\r\n\t}", "public C2BoogieRegressionTestSuite() {\r\n\t\tsuper();\r\n\t\tmTimeout = DEFAULT_TIMEOUT_MILLIS;\r\n\t\tmRootFolder = ROOT_FOLDER;\r\n\t\tmFiletypesToConsider = new String[] { \".c\" };\r\n\t}", "@Test(priority = 75)\r\n@Epic(\"BILLS PAYMENT\")\r\n@Features(value = { @Feature(value = \"BUY GOODS USING MPESA\") })\r\n@Step (\"END OF BUY GOODS USING MPESA TILL TESTCASES\")\r\n@Severity(SeverityLevel.TRIVIAL)\r\npublic void End_Buy_Goods_Using_MPESA_Test_cases() {\n\tSystem.out.println(\"*************************End of buy Goods Using Mpesa Test cases***********************************\");\r\n\r\n}", "public static Test suite() {\n return createModuleTest(WizardsTest.class);\n }", "@Test\n void scCreation() {\n StandardCalc sc = new StandardCalc();\n }", "private String generateTestNGTestCasesSkeletonCode(List<TestCaseList> testCases, ProductMaster product, String packageName, String refClassName, String destinationDirectory, int nameSource, String testExecutionEngine, String testStepOption) {\n\t\tJCodeModel codeModel = new JCodeModel();\r\n\t\tString message = null;\r\n\t\ttry {\r\n\t\t\tif (testExecutionEngine == null)\r\n\t\t\t\ttestExecutionEngine = TAFConstants.TESTENGINE_SEETEST;\r\n\t\t\tlog.info(\"Test Execution Engine : \" + testExecutionEngine);\r\n\t\t\t\t\r\n\t\t\tJClass testNGAfterMethodReference = null;\r\n\t\t\tJClass testNGBeforeMethodReference = null;\r\n\t\t\tJClass testNGTestReference = null;\r\n\t\t\ttestNGAfterMethodReference = codeModel.ref(\"org.testng.annotations.AfterMethod\");\r\n\t\t\ttestNGBeforeMethodReference = codeModel.ref(\"org.testng.annotations.BeforeMethod\");\r\n\t\t\ttestNGTestReference = codeModel.ref(\"org.testng.annotations.Test\");\r\n\r\n\t\t\tfor (TestCaseList testCase : testCases) {\r\n\r\n\t\t\t\t// 1. Create the class for the test case\r\n\t\t\t\t//String testCaseName = getTestCaseClassName(testCase, nameSource);\r\n\t\t\t\t//String testCaseName = null;\r\n\t\t\t\tString testCaseName = null;\r\n\t\t\t\tString classPackageName = null;\r\n\t\t\t\tif (testCase.getTestCaseScriptFileName() == null || testCase.getTestCaseScriptFileName().trim().isEmpty()) {\r\n\t\t\t\t\ttestCaseName = ScriptGeneratorUtilities.getTestCaseClassName(testCase.getTestCaseName(), testCase.getTestCaseId(), testCase.getTestCaseCode(), nameSource);\r\n\t\t\t\t} else {\r\n\t\t\t\t\ttestCaseName = testCase.getTestCaseScriptFileName();\r\n\t\t\t\t\tif(testCaseName.contains(\".java\")){\r\n\t\t\t\t\t\ttestCaseName = testCaseName.replace(testCaseName.substring(testCaseName.lastIndexOf(\".\")),\"\");\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\tif (testCase.getTestCaseScriptQualifiedName() == null || testCase.getTestCaseScriptQualifiedName().trim().isEmpty()) {\r\n\t\t\t\t\tclassPackageName = packageName;\r\n\t\t\t\t} else {\r\n\t\t\t\t\tclassPackageName = testCase.getTestCaseScriptQualifiedName();\r\n\t\t\t\t}\r\n\t\t\t\tJDefinedClass testCaseClass = codeModel._class(classPackageName + \".\" + testCaseName);\r\n\t\t\t\tJDocComment classComment = testCaseClass.javadoc();\r\n\t\t\t\tString javadocCommentClass = \"Automation Script for Testcase : \" + testCase.getTestCaseName()\r\n\t\t\t\t\t\t+ \"\\n\" + \"Product : \" + product.getProductDescription()\r\n\t\t\t\t\t\t+ \"\\n\" + \"Testcase ID \t\t: \" + testCase.getTestCaseId()\r\n\t\t\t\t\t\t+ \"\\n\" + \"Testcase Code\t\t: \" + testCase.getTestCaseCode()\r\n\t\t\t\t\t\t+ \"\\n\" + \"Description \t\t: \" + testCase.getTestCaseDescription()\r\n\t\t\t\t\t\t+ \"\\n\" + \"Test case type \t: \" + testCase.getTestCaseType()\r\n\t\t\t\t\t\t+ \"\\n\" + \"Script Type \t\t: \" + TAFConstants.TESTSCRIPT_TYPE_TESTNG\r\n\t\t\t\t\t\t+ \"\\n\" + \"Test Execution Engine \t: \" + testExecutionEngine\r\n\t\t\t\t\t\t+ \"\\n\" + \"Code generated by TAF on \t: \" + new Date(System.currentTimeMillis());\r\n\t\t\t\tclassComment.append(javadocCommentClass);\r\n\t\t\t\t\r\n\t\t\t\ttestCaseClass = addClassVariablesForTestCaseClass(codeModel, testCaseClass, testExecutionEngine);\r\n\t\t\t\t\r\n\t\t\t\t// 4.a Add the setup method\r\n\t\t\t\tJMethod setUpMethod = testCaseClass.method(JMod.PUBLIC, void.class, \"setUp\");\r\n\t\t\t\tJDocComment methodComment1 = setUpMethod.javadoc();\r\n\t\t\t\tString commentString = \"Setup method for testcase\";\r\n\t\t\t\tmethodComment1.append(commentString);\r\n\t\t\t\tsetUpMethod = constructSetUpMethodForTestCase(setUpMethod, testExecutionEngine, refClassName, testCaseName);\r\n\t\t\t\tsetUpMethod.annotate(testNGBeforeMethodReference);\r\n\t\t\t\t\r\n\t\t\t\tJMethod tearDownMethod = testCaseClass.method(JMod.PUBLIC, void.class, \"tearDown\");\r\n\t\t\t\tJDocComment methodComment2 = tearDownMethod.javadoc();\r\n\t\t\t\tcommentString = \"Teardown method for the testcase\";\r\n\t\t\t\tmethodComment2.append(commentString);\r\n\t\t\t\ttearDownMethod = constructTearDownMethodForTestCase(setUpMethod, testExecutionEngine);\r\n\t\t\t\ttearDownMethod.annotate(testNGAfterMethodReference);\r\n\t\t\t\t\r\n\t\t\t\tif (testStepOption == null)\r\n\t\t\t\t\ttestStepOption = \"SINGLE_METHOD\";\r\n\t\t\t\tList<TestCaseStepsList> testSteps = testCaseService.listTestCaseSteps(testCase.getTestCaseId());\r\n\t\t\t\tif (testSteps == null || testSteps.isEmpty()) {\r\n\t\t\t\t\tlog.debug(\"No steps in the testcase : \" + testCaseName);\r\n\t\t\t\t\tJMethod testCaseMethod = testCaseClass.method(JMod.PUBLIC, void.class, testCaseName + \"_Test\");\r\n\t\t\t\t\ttestCaseMethod.annotate(testNGTestReference);\r\n\t\t\t\t\ttestCaseMethod = constructDefaultTestCaseMethodForTestCase(testCaseMethod, testExecutionEngine, testCase);\r\n\t\t\t\t} else {\r\n\t\t\t\t\tif(testStepOption.contains(\"SEPARATE_METHOD\")) {\r\n\t\t\t\t\t\tfor (TestCaseStepsList testStep : testSteps) {\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\tString testStepName = ScriptGeneratorUtilities.getTestStepMethodName(testCaseName, testStep.getTestStepName(), testStep.getTestStepId(), testStep.getTestStepCode(), 1 );\r\n\t\t\t\t\t\t\tJMethod testStepMethod = testCaseClass.method(JMod.PUBLIC, void.class, testStepName);\r\n\t\t\t\t\t\t\ttestStepMethod.annotate(testNGTestReference);\r\n\t\t\t\t\t\t\ttestStepMethod = constructTestStepMethodForTestCase(testStepMethod, testExecutionEngine, refClassName, testCaseName, testStepName, testStep);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tJMethod singleTestStepMethod = testCaseClass.method(JMod.PUBLIC, void.class, testCaseName + \"_Test\");\r\n\t\t\t\t\t\tsingleTestStepMethod.annotate(testNGTestReference);\r\n\t\t\t\t\t\tfor (TestCaseStepsList testStep : testSteps) {\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\tString testStepName = ScriptGeneratorUtilities.getTestStepMethodName(testCaseName, testStep.getTestStepName(), testStep.getTestStepId(), testStep.getTestStepCode(), 1 );\r\n\t\t\t\t\t\t\tsingleTestStepMethod = addTestStepForSingleTestStepMethodForTestCase(singleTestStepMethod, testExecutionEngine, refClassName, testCaseName, testStepName, testStep);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\tFile sourceFile = new File(destinationDirectory);\r\n\t\t\t\tif (!sourceFile.exists()) {\r\n\t\t\t\t\tlog.info(\"Created Directory for source code generation : \" + destinationDirectory);\r\n\t\t\t\t\tsourceFile.mkdirs();\r\n\t\t\t\t}\r\n\t\t\t\tcodeModel.build(sourceFile);\r\n\t\t\t\tmessage = sourceFile.getAbsolutePath() + DEFAULT_PACKAGE_NAME_FOLDER + File.separator + testCaseName + \".java\";\r\n\t\t\t}\r\n\t\t} catch (JClassAlreadyExistsException e) {\r\n\t\t\tlog.error(\"Unable to generate testcase ref source code class\", e);\r\n\t\t\tmessage = \"Failed : Unable to generate testcase ref source code class\";\r\n\t\t} catch (IOException io) {\r\n\t\t\tlog.error(\"Unable to create file in file system\", io);\r\n\t\t\tmessage = \"Failed : Unable to create file in file system\";\r\n\t\t}\r\n\t\t\r\n\t\tlog.debug(\"Success : Generated Testcases source code framework.\" );\r\n\t\treturn message;\r\n\r\n\t}", "static public TestSuite suite() {\r\n return new TestIndividual( \"TestIndividual\" );\r\n }", "private static void testgen(String[] args) {\n JSONParser parser = new JSONParser();\n TestgenOptions options = parseTestgenOptions(args);\n CLI.setVerbosity(options);\n if (options.numTasks < 1) {\n API.throwCLIError(\"Invalid number of tasks provided (-n): \" + options.numTasks);\n }\n\n Map<String, Object> objects;\n if (!options.inFile.isEmpty()) {\n objects = parser.parse(options.inFile, true);\n } else if (!options.inString.isEmpty()) {\n objects = parser.parse(options.inString, false);\n } else {\n API.throwCLIError(\"No input JSON provided (-i)\");\n return;\n }\n\n if (objects.get(\"initialState\") == null || objects.get(\"goalState\") == null) {\n API.throwCLIError(\"Both an initial state and a goal state must be provided.\");\n }\n\n TestCaseGenerator generator = new TestCaseGenerator(\n (SystemState) objects.get(\"initialState\"),\n (GoalState) objects.get(\"goalState\"),\n options.numTasks,\n options.optimalPlan,\n options.output\n );\n\n ArrayList<Task> tasks = generator.generateTestCase();\n ArrayList<Optimization> ops = generator.generateOptimizations();\n try{\n generator.testCaseToJSON(tasks, ops, options.perturbations);\n } catch (IOException e){\n API.throwCLIError(\"Failed to write testCase to JSON\");\n }\n\n }", "private static void setPlane(){\n // your code goes there\n LinearRegression linG;\n linG = new LinearRegression(2,2000);\n\n for(double i = 0; i < 1000; i+=1)\n {\n double[] pt1, pt2;\n pt1 = new double[2];\n pt2 = new double[2];\n\n pt1[0] = i;\n pt2[0] = 2.0*i;\n\n pt1[1] = 2.0*i;\n pt2[1] = i;\n\n linG.addSample(pt1,5.0*i);\n linG.addSample(pt2,4.0*i);\n }\n \n\n System.out.println(\"Current hypothesis :\" + linG.currentHypothesis());\n System.out.println(\"Current cost :\" + linG.currentCost());\n\n for(int i = 1; i <= 10; i++)\n {\n linG.gradientDescent(0.000000003,1000);\n\n System.out.println(\"Current hypothesis :\" + linG.currentHypothesis());\n System.out.println(\"Current cost :\" + linG.currentCost());\n }\n\t}", "RegressionCurveType createRegressionCurveType();", "public RegressionModel(List<? extends DataEntry> dataSet) {\r\n this.regression = new OLSMultipleLinearRegression();\r\n processDataSet(dataSet);\r\n\r\n regression.newSampleData(regressandValues, regressorValues);\r\n }", "@Test(priority = 66)\r\n@Epic(\"BILLS PAYMENT\")\r\n@Features(value = { @Feature(value = \"BUY GOODS USING MPESA\") })\r\n@Step (\"BUY GOODS USING MPESA\")\r\n@Severity(SeverityLevel.TRIVIAL)\r\npublic void Buy_Goods_Using_MPESA_Test_cases() {\n\tSystem.out.println(\"BUY GOODS AND SERVICES\");\t\r\n\tSystem.out.println(\"*************************(1)Running Buy Goods Using MPESA Testcases***********************************\");\r\n\r\n}", "@Test(groups ={Slingshot,Regression,SubmitMeterRead})\npublic void verifySAPElectricCustomer_old()\t\n{\t\n\tReport.createTestLogHeader(\"Anonymous Submit meter read\", \"Verifies the SAP SMR page for Electric customer\");\nSMRAccountDetails smrProfile = new TestDataHelper().getAllSMRUserProfile(\"SAPSMRElectricityUserforsingleMeter\");\n\t\tnew SubmitMeterReadAction()\n\t\t.openSMRpage(\"Electricity\")\n\t\t//.verifyAnonymousSAPElecCustomersRewrite(smrProfile)\n\t\t.verifyAnonymousSAPElectricCustomers(smrProfile)\n\t\t.verifyLeadTable(smrProfile);\n\t\n}", "public void evaluate(String trainFile, double percentTrain, String testFile, String featureDefFile) {\n/* 799 */ List<RankList> train = new ArrayList<>();\n/* 800 */ List<RankList> validation = new ArrayList<>();\n/* 801 */ int[] features = prepareSplit(trainFile, featureDefFile, percentTrain, normalize, train, validation);\n/* 802 */ List<RankList> test = null;\n/* */ \n/* */ \n/* 805 */ if (!testFile.isEmpty()) {\n/* */ \n/* 807 */ test = readInput(testFile);\n/* 808 */ if (normalize) {\n/* 809 */ normalize(test, features);\n/* */ }\n/* */ } \n/* 812 */ RankerTrainer trainer = new RankerTrainer();\n/* 813 */ Ranker ranker = trainer.train(this.type, train, validation, features, this.trainScorer);\n/* */ \n/* 815 */ if (test != null) {\n/* */ \n/* 817 */ double rankScore = evaluate(ranker, test);\n/* 818 */ System.out.println(this.testScorer.name() + \" on test data: \" + SimpleMath.round(rankScore, 4));\n/* */ } \n/* 820 */ if (modelFile.compareTo(\"\") != 0) {\n/* */ \n/* 822 */ System.out.println(\"\");\n/* 823 */ ranker.save(modelFile);\n/* 824 */ System.out.println(\"Model saved to: \" + modelFile);\n/* */ } \n/* */ }", "public static Test suite() {\n \t\treturn new TestSuite(ModelObjectReaderWriterTest.class);\n \t}", "private String generateJUnitTestCasesSkeletonCode(List<TestCaseList> testCases, ProductMaster product, String packageName, String refClassName, String destinationDirectory, int nameSource, String testExecutionEngine, String testStepOption) {\n\t\tJCodeModel codeModel = new JCodeModel();\r\n\t\tString message = null;\r\n\t\ttry {\r\n\t\t\tif (testExecutionEngine == null)\r\n\t\t\t\ttestExecutionEngine = TAFConstants.TESTENGINE_SEETEST;\r\n\t\t\tlog.info(\"Test Execution Engine : \" + testExecutionEngine);\r\n\t\t\t\t\r\n\t\t\tJClass junitAfterReference = null;\r\n\t\t\tJClass junitBeforeReference = null;\r\n\t\t\tJClass junitTestReference = null;\r\n\t\t\tJClass junitFixMethodOrderReference = null;\r\n\t\t\tJClass junitMethodSortersReference = null;\r\n\t\t\tjunitAfterReference = codeModel.ref(\"org.junit.After\");\r\n\t\t\tjunitBeforeReference = codeModel.ref(\"org.junit.Before\");\r\n\t\t\tjunitTestReference = codeModel.ref(\"org.junit.Test\");\r\n\t\t\tjunitFixMethodOrderReference = codeModel.ref(\"org.junit.FixMethodOrder\");\r\n\t\t\tjunitMethodSortersReference = codeModel.ref(\"org.junit.runners.MethodSorters\");\r\n\r\n\t\t\tfor (TestCaseList testCase : testCases) {\r\n\r\n\t\t\t\t// 1. Create the class for the test case\r\n\t\t\t\tString testCaseName = null;\r\n\t\t\t\tString classPackageName = null;\r\n\t\t\t\tif (testCase.getTestCaseScriptFileName() == null || testCase.getTestCaseScriptFileName().trim().isEmpty()) {\r\n\t\t\t\t\ttestCaseName = ScriptGeneratorUtilities.getTestCaseClassName(testCase.getTestCaseName(), testCase.getTestCaseId(), testCase.getTestCaseCode(), nameSource);\r\n\t\t\t\t} else {\r\n\t\t\t\t\ttestCaseName = testCase.getTestCaseScriptFileName();\r\n\t\t\t\t\tif(testCaseName.contains(\".java\")){\r\n\t\t\t\t\t\ttestCaseName = testCaseName.replace(testCaseName.substring(testCaseName.lastIndexOf(\".\")),\"\");\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\tif (testCase.getTestCaseScriptQualifiedName() == null || testCase.getTestCaseScriptQualifiedName().trim().isEmpty()) {\r\n\t\t\t\t\tclassPackageName = packageName;\r\n\t\t\t\t} else {\r\n\t\t\t\t\tclassPackageName = testCase.getTestCaseScriptQualifiedName();\r\n\t\t\t\t}\r\n\t\t\t\tJDefinedClass testCaseClass = codeModel._class(classPackageName + \".\" + testCaseName);\r\n\t\t\t\tJDocComment classComment = testCaseClass.javadoc();\r\n\t\t\t\tString javadocCommentClass = \"Automation Script for Testcase : \" + testCase.getTestCaseName()\r\n\t\t\t\t\t\t+ \"\\n\" + \"Product \t\t\t: \" + product.getProductDescription()\r\n\t\t\t\t\t\t+ \"\\n\" + \"Testcase ID\t\t: \" + testCase.getTestCaseId()\r\n\t\t\t\t\t\t+ \"\\n\" + \"Testcase Code \t: \" + testCase.getTestCaseCode()\r\n\t\t\t\t\t\t+ \"\\n\" + \"Description \t\t: \" + testCase.getTestCaseDescription()\r\n\t\t\t\t\t\t+ \"\\n\" + \"Test case type \t: \" + testCase.getTestCaseType()\r\n\t\t\t\t\t\t+ \"\\n\" + \"Script Type \t\t: \" + TAFConstants.TESTSCRIPT_TYPE_JUNIT\r\n\t\t\t\t\t\t+ \"\\n\" + \"Test Execution Engine \t: \" + testExecutionEngine\r\n\t\t\t\t\t\t+ \"\\n\" + \"Code generated by TAF on \t: \" + new Date(System.currentTimeMillis());\r\n\t\t\t\tclassComment.append(javadocCommentClass);\r\n\t\t\t\ttestCaseClass.annotate(junitFixMethodOrderReference).param(\"value\", MethodSorters.NAME_ASCENDING);\r\n\r\n\t\t\t\ttestCaseClass = addClassVariablesForTestCaseClass(codeModel, testCaseClass, testExecutionEngine);\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\tif (testStepOption == null)\r\n\t\t\t\t\ttestStepOption = \"SINGLE_METHOD\";\r\n\t\t\t\t// 4. Add methods for the test steps of the test case\r\n\t\t\t\t// 4.a Add the setup and tear down methods\r\n\t\t\t\tJMethod setUpMethod = testCaseClass.method(JMod.PUBLIC, void.class, \"setUp\");\r\n\t\t\t\tJDocComment methodComment1 = setUpMethod.javadoc();\r\n\t\t\t\tString commentString = \"Setup method for testcase\";\r\n\t\t\t\tmethodComment1.append(commentString);\r\n\t\t\t\tsetUpMethod = constructSetUpMethodForTestCase(setUpMethod, testExecutionEngine, refClassName, testCaseName);\r\n\t\t\t\tsetUpMethod.annotate(junitBeforeReference);\r\n\t\t\t\t\r\n\t\t\t\tJMethod tearDownMethod = testCaseClass.method(JMod.PUBLIC, void.class, \"tearDown\");\r\n\t\t\t\tJDocComment methodComment2 = tearDownMethod.javadoc();\r\n\t\t\t\tcommentString = \"Teardown method for the testcase\";\r\n\t\t\t\tmethodComment2.append(commentString);\r\n\t\t\t\ttearDownMethod = constructTearDownMethodForTestCase(tearDownMethod, testExecutionEngine);\r\n\t\t\t\ttearDownMethod.annotate(junitAfterReference);\r\n\t\t\t\t\r\n\t\t\t\tList<TestCaseStepsList> testSteps = testCaseService.listTestCaseSteps(testCase.getTestCaseId());\r\n\t\t\t\tif (testSteps == null || testSteps.isEmpty()) {\r\n\t\t\t\t\tlog.debug(\"No steps in the testcase : \" + testCaseName);\r\n\t\t\t\t\tJMethod testCaseMethod = testCaseClass.method(JMod.PUBLIC, void.class, testCaseName + \"_Test\");\r\n\t\t\t\t\ttestCaseMethod.annotate(junitTestReference);\r\n\t\t\t\t\ttestCaseMethod = constructDefaultTestCaseMethodForTestCase(testCaseMethod, testExecutionEngine, testCase);\r\n\t\t\t\t} else {\r\n\t\t\t\t\tif(testStepOption.contains(\"SEPARATE_METHOD\")) {\r\n\t\t\t\t\t\tJMethod mainTestStepMethod = testCaseClass.method(JMod.PUBLIC, void.class, \"mainTest\");\r\n\t\t\t\t\t\tmainTestStepMethod.annotate(junitTestReference);\r\n\t\t\t\t\t\tString stepMethod = \"\";\r\n\t\t\t\t\t\tfor (TestCaseStepsList testStep : testSteps) {\t\t\t\t\t\t\r\n\t\t\t\t\t\t\tString testStepName = ScriptGeneratorUtilities.getTestStepMethodName(testCaseName, testStep.getTestStepName(), testStep.getTestStepId(), testStep.getTestStepCode(), 1 );\r\n\t\t\t\t\t\t\tJMethod testStepMethod = testCaseClass.method(JMod.PUBLIC, void.class, testStepName);\r\n\t\t\t\t\t\t\ttestStepMethod = constructTestStepMethodForTestCase(testStepMethod, testExecutionEngine, refClassName, testCaseName, testStepName, testStep);\r\n\t\t\t\t\t\t\tstepMethod = testStepName+\"();\";\r\n\t\t\t\t\t\t\tmainTestStepMethod.body().directStatement(stepMethod);\r\n\t\t\t\t\t\t\tstepMethod = \"\";\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tJMethod singleTestStepMethod = testCaseClass.method(JMod.PUBLIC, void.class, testCaseName + \"_Test\");\r\n\t\t\t\t\t\tsingleTestStepMethod.annotate(junitTestReference);\r\n\t\t\t\t\t\tfor (TestCaseStepsList testStep : testSteps) {\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\tString testStepName = ScriptGeneratorUtilities.getTestStepMethodName(testCaseName, testStep.getTestStepName(), testStep.getTestStepId(), testStep.getTestStepCode(), 1 );\r\n\t\t\t\t\t\t\tsingleTestStepMethod = addTestStepForSingleTestStepMethodForTestCase(singleTestStepMethod, testExecutionEngine, refClassName, testCaseName, testStepName, testStep);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\r\n\t\t\t\tFile sourceFile = new File(destinationDirectory);\r\n\t\t\t\tif (!sourceFile.exists()) {\r\n\t\t\t\t\tlog.info(\"Created Directory for source code generation : \" + destinationDirectory);\r\n\t\t\t\t\tsourceFile.mkdirs();\r\n\t\t\t\t}\r\n\t\t\t\tcodeModel.build(sourceFile);\r\n\t\t\t\tString CLASS_PACKAGE_NAME_FOLDER = classPackageName.replace(\".\", File.separator);\r\n\t\t\t\tlog.info(\"CLASS_PACKAGE_NAME_FOLDER : \" + CLASS_PACKAGE_NAME_FOLDER);\r\n\t\t\t\tmessage = sourceFile.getAbsolutePath() + File.separator + CLASS_PACKAGE_NAME_FOLDER + File.separator + testCaseName + \".java\";\r\n\t\t\t}\r\n\t\t} catch (JClassAlreadyExistsException e) {\r\n\t\t\tlog.error(\"Unable to generate testcase ref source code class\", e);\r\n\t\t\tmessage = \"Failed : Unable to generate testcase ref source code class\";\r\n\t\t} catch (IOException io) {\r\n\t\t\tlog.error(\"Unable to create file in file system\", io);\r\n\t\t\tmessage = \"Failed : Unable to create file in file system\";\r\n\t\t}\r\n\t\t\r\n\t\tlog.debug(\"Success : Generated Testcases source code framework.\" );\r\n\t\treturn message;\r\n\r\n\t}", "@Override\n\tpublic void onTestStart(ITestResult result) {\n\t\ttest=extent.createTest(result.getMethod().getMethodName());\n\t}", "protected Object createTest() throws Exception {\n Object test = super.createTest();\n dataPopulator.populate(test);\n return test;\n }", "private void generateTestExecution(ITestResult result) throws IOException{\r\n\t\t//create the html file with current running class and test name\r\n\t\tfout = createRequiredFile(result.getName());\r\n\t\t\r\n\t\t//Write initial html codes neccessary for report\r\n\t\tstartHtmlPage(fout,result);\r\n\t\t\r\n\t\t//get all the attributes set during the test execution\r\n\t\tObject[] array = result.getAttributeNames().toArray();\r\n\t\t\r\n\t\t//Above got values are not in sort. So, Sorting that based on time\r\n\t\tArrays.sort(array);\r\n\t\t\r\n\t\t//Iterating the array value to generate report\r\n \tfor(Object name : array){\r\n \t\t\t\r\n \t\t\t//Each and every array value contains, All the info about the particular action\r\n \t\t\t//And Values combined using deliminator. So, split using deliminator\r\n\t \t\tString temp[] = result.getAttribute((String) name).toString().split(\"####\");\r\n\t \t\t\r\n\t \t\t//After split up, If the third array value contains 'Fail' means that step failed \r\n\t \t\tif(temp[3].toLowerCase().contains(\"fail\")){\r\n\t \t\t\t//If Fail create '<tr>' tag with 'status_failed' class(Which is used for create 'red' background color for failed cases)\r\n\t \t\t\tfout.println(\"<tr class=\\\"status_failed\\\" title=\\\"\\\" alt=\\\"\\\">\");\r\n\t \t\t\t\r\n\t \t\t\t//create the screenshot path\r\n\t \t\t\tString pathToScreenshot = \"../Failure_Screenshot/\"+temp[5]+\".jpg\";\r\n\t \t\t\t\r\n\t \t\t\t//creating mapping for failed step(Link to screen shot and embed the screenshot in that step)\r\n\t \t\t\ttemp[4] = \"<a href=\\'\" + pathToScreenshot + \"\\'> <img src=\\'\" + pathToScreenshot + \"\\' height=\\\"100\\\" width=\\\"100\\\"> </a>\";\r\n\r\n\t \t\t}\r\n\t \t\t\r\n\t \t\t//After split up, If the third array value contains 'title' means that is title\r\n\t \t\telse if(temp[3].toLowerCase().contains(\"title\")){\r\n\t \t\t\t//So, If it is a title then create '<tr>' tag with class name 'title'\r\n\t \t\t\tfout.println(\"<tr class=\\\"title\\\" title=\\\"\\\" alt=\\\"\\\">\");\r\n\t \t\t\tfout.println(\"<td colspan=\\\"6\\\">\"+ temp[0] + \"</td>\");\r\n\t \t\t\tfout.println(\"</tr>\");\r\n\t \t\t\tcontinue;\r\n\t \t\t}\r\n\t \t\t\r\n\t \t\t//Else status is passed\r\n\t \t\telse{\r\n\t \t\t\tfout.println(\"<tr class=\\\"status_passed\\\" title=\\\"\\\" alt=\\\"\\\">\");\r\n\t \t\t}\r\n\t \t\t\r\n\t \t\t//this will create separate '<td>' for messages inside the action\r\n\t \t\tfor(String temp1 : temp){\r\n\t \t\t\t\tfout.println(\"<td>\"+ temp1 + \"</td>\");\r\n\r\n\t \t\t}\r\n\t \t//end up '<tr>' tag\t\r\n\t \tfout.println(\"</tr>\");\r\n \t}\r\n \t\r\n \t//this used for write some end up html tags\r\n \tonFinish();\r\n \t\r\n\t}", "public SimpleRegression() {\n this(new TDistributionImpl(1.0));\n }", "public void doRegressionAnalysis()\r\n {\n n = Y.getRowDimension();\r\n p = X.getColumnDimension(); \r\n k = p - 1; // k is number of explanatory variables\r\n Resids = new Matrix(n, 1);\r\n StandResids = new Matrix(n, 1);\r\n StudResids = new Matrix(n, 1);\r\n Cooks_D = new Matrix(n, 1);\r\n R_Student = new Matrix(n, 1);\r\n\r\n // MVP, p73\r\n X_Prime = X.transpose();\r\n X_Prime_X = X_Prime.times(X);\r\n X_Prime_X_Inv = X_Prime_X.inverse(); \r\n HatMatrix = X.times(X_Prime_X_Inv.times(X_Prime)); \r\n BetaHats = X_Prime_X_Inv.times(X_Prime.times(Y)); \r\n YHats = HatMatrix.times(Y);\r\n BXY = (BetaHats.transpose()).times(X_Prime.times(Y));\r\n Y_Prime_Y = (Y.transpose()).times(Y); \r\n ssRegression = BXY.get(0,0) - sumY_Squared_Over_n;\r\n SSRes = Y_Prime_Y.minus(BXY);\r\n ssResiduals = SSRes.get(0,0);\r\n ssTotal = Y_Prime_Y.get(0,0) - sumY_Squared_Over_n;\r\n \r\n r2 = ssRegression / ssTotal;\r\n s = Math.sqrt(ssResiduals / (n - k - 1));\r\n adj_r2 = 1.0 - (ssResiduals / (n - k - 1)) / (ssTotal / (n - 1));\r\n \r\n dfReg = k;\r\n dfResid = n - k - 1;\r\n dfTotal = n - 1;\r\n msReg = ssRegression / (double)k;\r\n msResid = ssResiduals / (double)(n - k - 1);\r\n fStatistic = msReg / msResid;\r\n fDist = new FDistribution(k, n - k - 1);\r\n pValue_F = fDist.getRightTailArea(fStatistic);\r\n Resids = Y.minus(YHats);\r\n\r\n tempDouble_01 = 1.0 / Math.sqrt(msResid);\r\n\r\n StandResids = Resids.times(tempDouble_01); \r\n for (int jj = 0; jj < n; jj++)\r\n { \r\n tempDouble_02 = HatMatrix.get(jj, jj);\r\n StudResids.set(jj, 0, Resids.get(jj, 0) * tempDouble_01 / Math.sqrt(1.0 - tempDouble_02));\r\n tempDouble_03 = StudResids.get(jj, 0) * StudResids.get(jj, 0) / (double)p;\r\n tempDouble_04 = tempDouble_02 / (1.0 - tempDouble_02);\r\n Cooks_D.set(jj, 0, tempDouble_03 * tempDouble_04);\r\n \r\n // Student-R calculations from 4.12, 4.13, p135\r\n jjResid = Resids.get(jj, 0);\r\n double e_i_sq = jjResid * jjResid; \r\n double oneMinus_hii = 1.0 - HatMatrix.get(jj, jj);\r\n double s_i_sq = ((n - p)*msResid - e_i_sq/oneMinus_hii) / (n - p - 1);\r\n R_Student.set(jj, 0, jjResid / Math.sqrt(s_i_sq * oneMinus_hii)); \r\n }\r\n\r\n StErrCoef = new Matrix(k + 1, 1); // Explanatory variables + intercept \r\n TStat = new Matrix(k + 1, 1); \r\n PValue_T = new Matrix(k + 1, 1); \r\n tDist = new TDistribution (n - k - 1);\r\n\r\n for (int preds = 0; preds <= k; preds++)\r\n {\r\n StErrCoef.set(preds, 0, Math.sqrt(msResid * X_Prime_X_Inv.get(preds, preds)));\r\n TStat.set(preds, 0, BetaHats.get(preds, 0) / StErrCoef.get(preds, 0));\r\n PValue_T.set(preds, 0, 2.0 * tDist.getRightTailArea(Math.abs(TStat.get(preds, 0))));\r\n }\r\n }", "@Test\n\tpublic void testUniformRWR() {\n\t\tlog.debug(\"Test logging\");\n\t\tint maxT = 10;\n\t\t\n\t\tAnnotatedGraph<String> g = brGraphs.get(0);\n\t\t\n\t\tTreeMap<String,Double> startVec = new TreeMap<String,Double>();\n\t\tstartVec.put(\"r0\",1.0);\n\t\tMap<String,Double> baseLineVec = myRWR(startVec,g,maxT);\n\t\tTreeMap<String,Double>uniformWeightVec = new TreeMap<String,Double>();\n\t\tuniformWeightVec.put(\"fromb\",1.0);\n\t\tuniformWeightVec.put(\"tob\",1.0);\n\t\tuniformWeightVec.put(\"fromr\",1.0);\n\t\tuniformWeightVec.put(\"tor\",1.0);\n\t\tuniformWeightVec.put(\"restart\",1.0);\n\t\tMap<String,Double> newVec = srw.rwrUsingFeatures(g, startVec, uniformWeightVec);\n\t\tequalScores(baseLineVec,newVec);\n\t}", "public static Test suite()\n {\n TestSuite ts = new TestSuite(\"TestAPI\") ;\n\t\t\t\n // This test should run first, in order to enable the optimizer for subsequent tests\n\t\tts.addTest(new TestAPI(\"testOptimizerDisable\")) ;\n\t\tts.addTest(new TestAPI(\"testOptimizerEnable\")) ;\n\t\tts.addTest(new TestAPI(\"testExplain\")) ;\n\t\tts.addTest(new TestAPI(\"testIndex\")) ;\n\t\tts.addTest(new TestAPI(\"testProbability1\")) ;\n\t\tts.addTest(new TestAPI(\"testProbability2\")) ;\n\t\t\n // Wrapper for the test suite including the test cases which executes the setup only once\n\t\tTestSetup wrapper = new TestSetup(ts) \n\t\t{\n\t\t\tprotected void setUp() \n\t\t\t{\n\t\t\t\toneTimeSetUp();\n\t\t\t}\n\n\t\t\tprotected void tearDown() \n\t\t\t{\n\t\t\t\toneTimeTearDown();\n\t\t\t}\n\t\t};\n\t\t\n\t\treturn wrapper ;\n }", "@BeforeGroups(\"regression\")\n\tpublic void bg2() {\n\t\tSystem.out.println(\"before group regression\");\n\t}", "@Override\n\tpublic TestDeValidation addTestValidation(TestDeValidation test) {\n\t\tthrow new RuntimeException(\"Méthode nom implémentée\");\n\t}", "public TestInfo runTest() throws Exception {\n\t\tMap<List<Integer>, String[]> pathMap = getImplementation().getSymbolicExecutionCost(cfg);\n\t\t//begin with random testing\n\t\tList<Integer> path = getImplementation().randomTesting(cfg); //start with a random testing\n\t\tremoveVisitedNode(path);\n\t\ttestInfo.rm_number++;\n\t\ttestInfo.totalCost = testInfo.totalCost + path.size() - 1;\n\t\tPath inputSeed = new Path(path, 0);\n\t\t\n\t\tList<Path> workList = new ArrayList<>();\n\t\tworkList.add(inputSeed);\n\t\t\n\t\t//if there is unvisited nodes\n\t\twhile(!workList.isEmpty() && !unvisited.isEmpty()){\n\t\t\tPath input = workList.get(0);\n\t\t\tworkList.remove(0);\n\t\t\tList<Path> childInputs = expandExecution(input);\n\t\t\tif(!childInputs.isEmpty()){\n\t\t\t\tfor(int i = 0; i < childInputs.size(); i++){\n\t\t\t\t\tPath newInput = childInputs.get(i);\n\t\t\t\t\tList<Integer> newPath = newInput.path;\n\t\t\t\t\t\n\t\t\t\t\t//update the test information\n\t\t\t\t\tnewPath = getImplementation().symbolicExecution(cfg, testInfo, newPath);\n\t\t\t\t\ttestInfo.totalCost = testInfo.totalCost + newPath.size() - 1;\n\t\t\t\t\t\n\t\t\t\t\t//remove nodes are visited in this testcase\n\t\t\t\t\tremoveVisitedNode(newPath);\n\t\t\t\t\tnewInput.path = newPath;\n\t\t\t\t\t\n\t\t\t\t\tworkList.add(newInput);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\ttestInfo.coverageRatio = 1 - (double)unvisited.size() / node_number;\n\t\t//print the test information\n\t\treturn testInfo;\n\t}", "private String generateJUnitMainClass(List<TestCaseList> allTestCases, ProductMaster product, String testExecutionEngine, String packageName, String destinationDirectory, int nameSource) {\n\t\tJCodeModel codeModel = new JCodeModel();\r\n\t\tString message = null;\r\n\t\ttry {\r\n\t\t\tif (testExecutionEngine == null)\r\n\t\t\t\ttestExecutionEngine = TAFConstants.TESTENGINE_SEETEST;\r\n\t\t\tlog.info(\"Test Execution Engine : \" + testExecutionEngine);\r\n\t\t\t\t\r\n\t\t\t// JUnit References\r\n\t\t\tJClass runWithReference = null;\r\n\t\t\tJClass suiteReference = null;\r\n\t\t\tJClass suiteClassesReference = null;\r\n\t\t\trunWithReference = codeModel.ref(\"org.junit.runner.RunWith\");\r\n\t\t\tsuiteReference = codeModel.ref(\"org.junit.runners.Suite\");\t\t\t\r\n\t\t\tsuiteClassesReference = codeModel.ref(\"org.junit.runners.Suite.SuiteClasses\");\r\n\t\t\t// 1. Create the class for the main class\r\n\t\t\tJDefinedClass mainClass = codeModel._class(packageName + \".\" + \"Main\");\r\n\t\t\tJDocComment classComment = mainClass.javadoc();\r\n\t\t\tString javadocCommentClass = \"Main driver class for integration of scripts with TAF\"\r\n\t\t\t\t\t\t+ \"\\n\" + \"Product : \" + product.getProductDescription()\r\n\t\t\t\t\t\t+ \"\\n\" + \"Script Type \t\t: \" + TAFConstants.TESTSCRIPT_TYPE_JUNIT\r\n\t\t\t\t\t\t+ \"\\n\" + \"Test Execution Engine \t: \" + testExecutionEngine\r\n\t\t\t\t\t\t+ \"\\n\" + \"Code generated by TAF on \t: \" + new Date(System.currentTimeMillis());\r\n\t\t\tclassComment.append(javadocCommentClass);\r\n\t\t\t// 2. Add the required import statements and the class variables\r\n\t\t\t// 2.a TAF Lib references for import\r\n\t\t\tmainClass = addClassVariablesForMainClass(codeModel, mainClass, testExecutionEngine);\r\n\t\t\t//Annotate for the Suite execution\r\n\t\t\tmainClass.annotate(runWithReference).param(\"value\", suiteReference);\r\n\t\t\t\r\n\r\n\t\t\t\r\n\t\t\tStringBuffer defaultSuiteClassesSB = new StringBuffer();\t\t\r\n\t\t\tdefaultSuiteClassesSB.append(\"{SetUp.class, \");\r\n\t\t\tfor (TestCaseList testCase : allTestCases) {\r\n\t\t\t\tdefaultSuiteClassesSB.append(ScriptGeneratorUtilities.getTestCaseClassName(testCase.getTestCaseName(), testCase.getTestCaseId(), testCase.getTestCaseCode(), nameSource).concat(\".class\"));\r\n\t\t\t\tdefaultSuiteClassesSB.append(\", \");\r\n\t\t\t}\r\n\t\t\tdefaultSuiteClassesSB.append(\"TearDown.class}\");\t\t\t\r\n\t\t\tmainClass.annotate(suiteClassesReference).param(\"value\", defaultSuiteClassesSB.toString());\r\n\t\t\t\r\n\t\t\t\r\n\t\t\tStringBuffer importClassStatements = new StringBuffer();\r\n\r\n\t\t\tStringBuffer suiteClassesSB = new StringBuffer();\r\n\t\t\tsuiteClassesSB.append(\"@SuiteClasses(\");\r\n\t\t\tsuiteClassesSB.append(\"{SetUp.class, \");\r\n\t\t\tfor (TestCaseList testCase : allTestCases) {\r\n\t\t\t\t\r\n\t\t\t\tString classPackageName;\r\n\t\t\t\r\n\t\t\t\tif (testCase.getTestCaseScriptQualifiedName() == null || testCase.getTestCaseScriptQualifiedName().trim().isEmpty()) {\r\n\t\t\t\t\tclassPackageName = packageName;\r\n\t\t\t\t} else {\r\n\t\t\t\t\tclassPackageName = testCase.getTestCaseScriptQualifiedName();\r\n\t\t\t\t}\r\n\r\n\t\t\t\timportClassStatements.append(\"import \" + classPackageName.trim() + \".\"+ ScriptGeneratorUtilities.getTestCaseClassName(testCase.getTestCaseName(), testCase.getTestCaseId(), testCase.getTestCaseCode(), nameSource) + \";\\n\");\r\n\t\t\t\tsuiteClassesSB.append(ScriptGeneratorUtilities.getTestCaseClassName(testCase.getTestCaseName(), testCase.getTestCaseId(), testCase.getTestCaseCode(), nameSource).concat(\".class\"));\r\n\t\t\t\tsuiteClassesSB.append(\", \");\r\n\t\t\t}\r\n\t\t\tsuiteClassesSB.append(\"TearDown.class})\");\t\t\t\r\n\t\t\tlog.info(importClassStatements.toString());\r\n\t\t\tlog.info(suiteClassesSB.toString());\r\n\r\n\t\t\t// Add the setup method\r\n\t\t\tJMethod setUpMethod = mainClass.method(JMod.PUBLIC, void.class, \"setUp\");\r\n\t\t\tJDocComment methodComment1 = setUpMethod.javadoc();\r\n\t\t\tString commentString = \"Setup method for the TestSuite/TestRun\";\r\n\t\t\tmethodComment1.append(commentString);\r\n\t\t\tsetUpMethod = constructSetUpMethodForMain(setUpMethod, testExecutionEngine);\r\n\r\n\t\t\t//Add seetest initialization method\r\n\t\t\tif (testExecutionEngine.equals(TAFConstants.TESTENGINE_SEETEST)) {\r\n\t\t\t\tJMethod initSeeTestClientMethod = mainClass.method(JMod.PUBLIC, codeModel.ref(com.experitest.client.Client.class), \"initSeeTestClient\");\r\n\t\t\t\tinitSeeTestClientMethod = constructSeeTestInitMethodForMain(initSeeTestClientMethod, testExecutionEngine, product);\r\n\t\t\t}\r\n\r\n\t\t\t//Add tear down method\r\n\t\t\tJMethod tearDownMethod = mainClass.method(JMod.PUBLIC, void.class, \"tearDown\");\r\n\t\t\tJDocComment methodComment2 = tearDownMethod.javadoc();\r\n\t\t\tcommentString = \"Teardown method for the TestSuite/TestRun\";\r\n\t\t\tmethodComment2.append(commentString);\r\n\t\t\ttearDownMethod = constructTearDownMethodForMain(tearDownMethod, testExecutionEngine, product);\r\n\t\t\t\r\n\t\t\tJMethod mainMethod = mainClass.method(JMod.PUBLIC | JMod.STATIC, mainClass, \"getMain\");\r\n\t\t\tmainMethod.body().directStatement(\" if(main==null)main=new Main(); \");\r\n\t\t\tmainMethod.body().directStatement(\"\t\treturn main;\");\r\n\t\t\t\r\n\t\t\t// Add accessor methods\t\t\t\r\n\t\t\tmainClass = constructAccessorMethodsForMain(codeModel, mainClass, testExecutionEngine, product);\r\n\t\t\t\r\n\t\t\tFile sourceFile = new File(destinationDirectory);\r\n\t\t\tif (!sourceFile.exists()) {\r\n\t\t\t\tlog.info(\"Created Directory for source code generation : \" + destinationDirectory);\r\n\t\t\t\tsourceFile.mkdirs();\r\n\t\t\t}\r\n\t\t\tcodeModel.build(sourceFile);\r\n\t\t\tmessage = sourceFile.getAbsolutePath() + MAIN_PACKAGE_NAME_FOLDER + File.separator +\"Main.java\";\r\n\t\t\tScriptGeneratorUtilities.insertTestCaseImportsForJavaScripts(message, importClassStatements.toString(), suiteClassesSB.toString(),\"\");\r\n\r\n\t\t} catch (JClassAlreadyExistsException e) {\r\n\t\t\tlog.error(\"Unable to generate testcase ref source code class\", e);\r\n\t\t\treturn \"Failed : Unable to generate testcase ref source code class\";\r\n\t\t} catch (IOException io) {\r\n\t\t\tlog.error(\"Unable to create file in file system\", io);\r\n\t\t\treturn \"Failed : Unable to create file in file system\";\r\n\t\t}\r\n\t\tlog.debug(\"Success : Generated Testcases source code framework.\" );\r\n\t\treturn message;\r\n\t}", "@Test\n\tpublic void generateGreen4LoyaltyReport(){\n\t\t\t\tWebDriver driver = new FirefoxDriver();\n\t\t\t\t// Alternatively the same thing can be done like this\n\t\t // driver.get(\"http://www.google.com\");\n\t\t\t\tdriver.navigate().to(determineUrl());\n\t\t\t\t// Find the text input element by its name\n\t\t\t\tWebElement user_name = driver.findElement(By.id(\"user_email\"));\n\t\t\t\tuser_name.sendKeys(user);\n\t\t\t\t\n\t\t\t\tWebElement password = driver.findElement(By.id(\"user_password\"));\n\t\t\t\tpassword.sendKeys(password_login);\n\t\t\t\tpassword.submit();\n\t\t\t\t\n\t\t\t\tWebElement select_venue = driver.findElement(By.id(\"change_venue\"));\n\t\t\t\tselect_venue.sendKeys(venue);\n\t\t\t\tselect_venue.submit();\n\t\t\t\t\n\t\t\t\t//Generate Batch report\n\t\t\t\tWebElement report = driver.findElement(By.linkText(\"Reporting\"));\n\t\t\t\treport.click();\n\t\t\t\t\n\t\t\t\tWebElement select_report = driver.findElement(By.id(\"report_type_chooser\"));\n\t\t\t\tselect_report.sendKeys(\"Green4 Loyalty Report\");\n\t\t\t\tWebElement select_event = driver.findElement(By.id(\"report_event\"));\n\t\t\t\tselect_event.sendKeys(event);\n\t\t\t\tselect_event.submit();\n\t\t\t\tdriver.close();\n\t\t\n\t}", "@Test\n public void costTest() {\n // TODO: test cost\n }", "public void wekaCalculate()\n\t{\n\t\tfor (int categoryStep = 0; categoryStep < 6; categoryStep++)\n\t\t{\n\t\t\tString trainString = \"Train\";\n\t\t\tString testString = \"Test\";\n\t\t\tString categoryString;\n\t\t\tString resultString = \"Results\";\n\t\t\tString textString;\n\t\t\tString eventString;\n\n\t\t\tswitch (categoryStep)\n\t\t\t{\n\t\t\tcase 0: categoryString = \"Cont.arff\"; break;\n\t\t\tcase 1: categoryString = \"Dona.arff\"; break;\n\t\t\tcase 2: categoryString = \"Offi.arff\"; break;\n\t\t\tcase 3: categoryString = \"Advi.arff\"; break;\n\t\t\tcase 4: categoryString = \"Mult.arff\"; break;\n\t\t\tdefault: categoryString = \"Good.arff\";\n\t\t\t}\n\t\t\t\n\t\t\tswitch (categoryStep)\n\t\t\t{\n\t\t\tcase 0: textString = \"Cont.txt\"; break;\n\t\t\tcase 1: textString = \"Dona.txt\"; break;\n\t\t\tcase 2: textString = \"Offi.txt\"; break;\n\t\t\tcase 3: textString = \"Advi.txt\"; break;\n\t\t\tcase 4: textString = \"Mult.txt\"; break;\n\t\t\tdefault: textString = \"Good.txt\";\n\t\t\t}\n\t\t\t\n\t\t\tfor (int eventStep = 0; eventStep < 15; eventStep++)\n\t\t\t{\n\t\t\t\tString trainingData;\n\t\t\t\tString testData;\n\t\t\t\tString resultText;\n\n\t\t\t\tswitch (eventStep)\n\t\t\t\t{\n\t\t\t\tcase 0: eventString = \"2011Joplin\"; break;\n\t\t\t\tcase 1: eventString = \"2012Guatemala\"; break; \n\t\t\t\tcase 2: eventString = \"2012Italy\"; break;\n\t\t\t\tcase 3: eventString = \"2012Philipinne\"; break;\n\t\t\t\tcase 4: eventString = \"2013Alberta\";\tbreak;\n\t\t\t\tcase 5: eventString = \"2013Australia\"; break;\n\t\t\t\tcase 6: eventString = \"2013Boston\"; break;\t\t\t\t\n\t\t\t\tcase 7: eventString = \"2013Manila\"; break;\n\t\t\t\tcase 8: eventString = \"2013Queens\"; break;\n\t\t\t\tcase 9: eventString = \"2013Yolanda\"; break;\n\t\t\t\tcase 10: eventString = \"2014Chile\"; break;\n\t\t\t\tcase 11: eventString = \"2014Hagupit\"; break;\n\t\t\t\tcase 12: eventString = \"2015Nepal\"; break;\n\t\t\t\tcase 13: eventString = \"2015Paris\"; break;\n\t\t\t\tdefault: eventString = \"2018Florida\"; \t\t\t\t\n\t\t\t\t}\n\n\t\t\t\ttrainingData = eventString;\n\t\t\t\ttrainingData += trainString;\n\t\t\t\ttrainingData += categoryString;\n\n\t\t\t\ttestData = eventString;\n\t\t\t\ttestData += testString;\n\t\t\t\ttestData += categoryString;\n\t\t\t\t\n\t\t\t\t\n\n\t\t\t\tresultText = eventString;\n\t\t\t\tresultText += resultString;\n\t\t\t\tresultText += textString;\n\t\t\t\t\n\n\t\t\t\ttry {\n\t\t\t\t\tConverterUtils.DataSource loader1 = new ConverterUtils.DataSource(trainingData);\n\t\t\t\t\tConverterUtils.DataSource loader2 = new ConverterUtils.DataSource(testData);\n\n\n\t\t\t\t\tBufferedWriter bw = new BufferedWriter(new FileWriter(resultText));\n\t\t\t\t\tInstances trainData = loader1.getDataSet();\n\t\t\t\t\ttrainData.setClassIndex(trainData.numAttributes() - 1);\n\n\t\t\t\t\tInstances testingData = loader2.getDataSet();\n\t\t\t\t\ttestingData.setClassIndex(testingData.numAttributes() - 1);\n\n\t\t\t\t\tClassifier cls1 = new NaiveBayes();\t\t\t\t\t\n\t\t\t\t\tcls1.buildClassifier(trainData);\t\t\t\n\t\t\t\t\tEvaluation eval1 = new Evaluation(trainData);\n\t\t\t\t\teval1.evaluateModel(cls1, testingData);\t\n\t\t\t\t\tbw.write(\"=== Summary of Naive Bayes ===\");\n\t\t\t\t\tbw.write(eval1.toSummaryString());\n\t\t\t\t\tbw.write(eval1.toClassDetailsString());\n\t\t\t\t\tbw.write(eval1.toMatrixString());\n\t\t\t\t\tbw.write(\"\\n\");\n\n\t\t\t\t\tthis.evalNaiveBayesList.add(eval1);\n\n\t\t\t\t\tClassifier cls2 = new SMO();\n\t\t\t\t\tcls2.buildClassifier(trainData);\n\t\t\t\t\tEvaluation eval2 = new Evaluation(trainData);\n\t\t\t\t\teval2.evaluateModel(cls2, testingData);\n\t\t\t\t\tbw.write(\"=== Summary of SMO ===\");\n\t\t\t\t\tbw.write(eval2.toSummaryString());\n\t\t\t\t\tbw.write(eval2.toClassDetailsString());\n\t\t\t\t\tbw.write(eval2.toMatrixString());\n\n\t\t\t\t\tthis.evalSMOList.add(eval2);\n\n\t\t\t\t\tbw.close();\n\t\t\t\t} catch (Exception e) {\t\t\t\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "public void TestMain(){\n SampleStatements();\n TestMyPow();\n }", "@Test // (groups={\"All\"}) //(groups={\"smoke\"})\r\n\tpublic void createLead() {\n\t\tSystem.out.println(\"create\");\r\n\t}", "@Test\n public void testTemplate(){\n }", "@Override\n\tpublic MedicalTest addTest(MedicalTest test) {\n\tString testId=generateTestId();\n\ttest.setTestId(testId);\n\tMedicalTestUtil.checkPresenceOfTest(test);\n\t\n\t\treturn testDao.save(test);\n\n\t}", "private JavaRuleContext buildTestJavaRuleContext() {\n Map<String, Object> ruleParameters = new HashMap<>();\n ruleParameters.put(SAMLCorrelationRule.ARG_ASSERTION_ATTRIBUTES,\n Collections.singletonMap(UUID.randomUUID().toString(), UUID.randomUUID()));\n return new JavaRuleContext(this.sailPointContext, ruleParameters);\n }", "@Test(groups ={Slingshot,Regression})\n\tpublic void allAcctsSuperUserCreation() {\n\t\t Report.createTestLogHeader(\"MuMv\", \"Verify the Super user creation and their Audit entry in DB\"); \t \t \t \t \t \t \n\t\tUserProfile userProfile = new TestDataHelper().getUserProfile(\"Switchtopaperlessacctspecifics\");\n\t\tSMRAccountDetails smrProfile = new TestDataHelper().getAllSMRUserProfile(\"SubmitMeterReadodb\");\n\t\tCrmUserProfile crmuserProfile = new TestDataHelper().getCrmUserProfile(\"SlingshotCrmDetailsSuperuser\"); \n\t\tnew LoginAction()\n\t\t.BgbnavigateToLogin()\n\t\t.BgbloginDetails(userProfile);\n\t\tnew MultiUserMultiViewAction()\n\t\t.ClickManageUserLink()\n\t\t.ClickAddNewUserLink()\n\t\t.AddUserRadioButton()\n\t\t.SuperUserCreation()\n\t\t.SuperUserOverlayyes();\n\t\tnew BgbRegistrationAction()\n\t\t.AddNewSuperUser(userProfile);\n\t\tnew MultiUserMultiViewAction()\n\t\t.verifyAuditTable(userProfile)\n\t\t.AdduserConfirmationPage();\n\t/*\t.confirmationPageVerificationLinks();\n\t\t/*.UserJourney_SuperUserAccessVerification(userProfile,smrProfile);\n\t\tnew SapCrmAction()\n\t\t.loginDetails(crmuserProfile)\n\t\t.searchCrmFieldsVerification(crmuserProfile, userProfile);\n*/\n\t}", "@Override\n public void runTest() {\n }", "@Test\n public void test00() throws Throwable {\n TestInstances testInstances0 = new TestInstances();\n Instances instances0 = testInstances0.generate((String) null);\n Evaluation evaluation0 = new Evaluation(instances0);\n evaluation0.addNumericTrainClass('u', 4.9E-324);\n assertEquals(0.0, evaluation0.SFEntropyGain(), 0.01D);\n }", "@Test\r\n public void testAddition() {\n }", "public static Test suite()\r\n {\r\n return suite(com.redknee.app.crm.TestPackage.createDefaultContext());\r\n }", "@Test\r\n public void testRent() {\r\n }", "@Test\n public void testTrain_RegressionDataSet_ExecutorService() {\n System.out.println(\"train\");\n RegressionDataSet trainSet = FixedProblems.getSimpleRegression1(150, new Random(2));\n RegressionDataSet testSet = FixedProblems.getSimpleRegression1(50, new Random(3));\n\n for (boolean modification1 : new boolean[] { true, false })\n for (SupportVectorLearner.CacheMode cacheMode : SupportVectorLearner.CacheMode.values()) {\n PlattSMO smo = new PlattSMO(new RBFKernel(0.5));\n smo.setCacheMode(cacheMode);\n smo.setC(1);\n smo.setEpsilon(0.1);\n smo.setModificationOne(modification1);\n smo.train(trainSet, true);\n\n double errors = 0;\n for (int i = 0; i < testSet.size(); i++)\n errors += Math.pow(testSet.getTargetValue(i) - smo.regress(testSet.getDataPoint(i)), 2);\n assertTrue(errors / testSet.size() < 1);\n }\n }", "public void evaluate(String trainFile, String validationFile, String testFile, String featureDefFile) {\n/* 710 */ List<RankList> train = readInput(trainFile);\n/* */ \n/* 712 */ List<RankList> validation = null;\n/* */ \n/* 714 */ if (!validationFile.isEmpty()) {\n/* 715 */ validation = readInput(validationFile);\n/* */ }\n/* 717 */ List<RankList> test = null;\n/* */ \n/* 719 */ if (!testFile.isEmpty()) {\n/* 720 */ test = readInput(testFile);\n/* */ }\n/* 722 */ int[] features = readFeature(featureDefFile);\n/* 723 */ if (features == null) {\n/* 724 */ features = FeatureManager.getFeatureFromSampleVector(train);\n/* */ }\n/* 726 */ if (normalize) {\n/* */ \n/* 728 */ normalize(train, features);\n/* 729 */ if (validation != null)\n/* 730 */ normalize(validation, features); \n/* 731 */ if (test != null) {\n/* 732 */ normalize(test, features);\n/* */ }\n/* */ } \n/* 735 */ RankerTrainer trainer = new RankerTrainer();\n/* 736 */ Ranker ranker = trainer.train(this.type, train, validation, features, this.trainScorer);\n/* */ \n/* 738 */ if (test != null) {\n/* */ \n/* 740 */ double rankScore = evaluate(ranker, test);\n/* 741 */ System.out.println(this.testScorer.name() + \" on test data: \" + SimpleMath.round(rankScore, 4));\n/* */ } \n/* 743 */ if (modelFile.compareTo(\"\") != 0) {\n/* */ \n/* 745 */ System.out.println(\"\");\n/* 746 */ ranker.save(modelFile);\n/* 747 */ System.out.println(\"Model saved to: \" + modelFile);\n/* */ } \n/* */ }", "@Test\n public void test01() throws Throwable {\n TestInstances testInstances0 = new TestInstances();\n Instances instances0 = testInstances0.generate((String) null);\n Evaluation evaluation0 = new Evaluation(instances0);\n evaluation0.addNumericTrainClass((-1459.149165489484), ',');\n assertEquals(0.0, evaluation0.SFPriorEntropy(), 0.01D);\n }", "@Test\n public void addition() {\n\n }", "@Override\n protected int[] getRegressionInputClassIndex() {\n int value = 8;\n int[] ret = new int[this.numberTests];\n for (int i = 0; i < this.numberTests; i++) {\n ret[i] = value;\n }\n return ret;\n }", "@Test(groups ={Slingshot,Regression,SubmitMeterRead})\npublic void smrConfirmationPageWithinMRGas(){\n\tReport.createTestLogHeader(\"SubmitMeterRead\", \"Validates meter read submission and Email to customer\");\n\t SMRAccountDetails smrProfile = new TestDataHelper().getAllSMRUserProfile(\"SMRLoggedin\");\n\t new SubmitMeterReadAction()\n\t \t .BgbnavigateToLogin()\n\t .BgbloginDetails(smrProfile)\n\t .clickManageAccountLinkWithAccNo(smrProfile)\n\t .submitMeterReadLink(smrProfile)\n\t .enterMultiDialReads(smrProfile)\n\t .overlay()\n\t .emailConfirmation()\n\t .verifyAuditLeadTable(smrProfile);\n}", "public UnitTestData() throws Exception {\n String[] runsData = {\n \"1,1,A,1,No,No,4\", // 0 (a No before first yes Security Violation)\n \"2,1,A,1,No,No,2\", // 0 (a No before first yes Compilation Error)\n \"3,1,A,1,No,No,1\", // 20 (a No before first yes)\n \"4,1,A,3,Yes,No,0\", // 3 (first yes counts Minute points but never Run Penalty points)\n \"5,1,A,5,No,No,1\", // zero -- after Yes\n \"6,1,A,7,Yes,No,0\", // zero -- after Yes\n \"7,1,A,9,No,No,1\", // zero -- after Yes\n \"8,1,B,11,No,No,1\", // zero -- not solved\n \"9,2,A,48,No,No,4\", // 0 (a No before first yes Security Violation)\n \"10,2,A,50,Yes,No,0\", // 50 (minute points; no Run points on first Yes)\n \"11,2,B,35,No,No,1\", // zero -- not solved\n \"12,2,B,40,No,No,1\", // zero -- not solved\n };\n\n // Assign half eams random team member names\n addTeamMembers(contest, getTeamAccounts(contest).length / 2, 5);\n\n assertEquals(\"Expectig team member names\", 5, getFirstAccount(contest, Type.TEAM).getMemberNames().length);\n\n assertEquals(\"team count\", 120, contest.getAccounts(Type.TEAM).size());\n\n for (String runInfoLine : runsData) {\n SampleContest.addRunFromInfo(contest, runInfoLine);\n }\n\n Problem problem = contest.getProblems()[0];\n Account judge = getFirstAccount(contest, Type.JUDGE);\n generateClarifications(contest, 20, problem, judge.getClientId(), false, false);\n generateClarifications(contest, 20, problem, judge.getClientId(), true, false);\n generateClarifications(contest, 20, problem, judge.getClientId(), true, true);\n\n sampleContest.assignSampleGroups(contest, \"North Group\", \"South Group\");\n\n assertEquals(\"Runs\", 12, contest.getRuns().length);\n\n }", "public void startTest() throws Throwable\n {\n ExcelFileUtil excel= new ExcelFileUtil();\n // iterate all row in masterTestCases sheet\n\n for(int i=1;i<=excel.rowCount(\"MasterTestCases\");i++)\n {\n String ModuleStatus=\"\";\n if(excel.getData(\"MasterTestCases\", i, 2).equalsIgnoreCase(\"Y\"))\n {\n //store module name to TCModule\n String TCModule =excel.getData(\"MasterTestCases\", i, 1);\n report=new ExtentReports(\"./Reports/\"+TCModule+Muvi_Functions.generateDate()+\".html\");\n //iterate all rows in TCModule\n for(int j=1;j<=excel.rowCount(TCModule);j++)\n {\n test=report.startTest(TCModule);\n //read al the columns from TCMocule\n String Description=excel.getData(TCModule, j, 0);\n String Object_Type=excel.getData(TCModule, j, 1);\n String Locator_Type=excel.getData(TCModule, j, 2);\n String Locator_Value=excel.getData(TCModule, j, 3);\n String Test_Data=excel.getData(TCModule, j, 4);\n //System.out.println(Description+\" \"+Object_Type);\n //calling the method from function library\n try{\n if(Object_Type.equalsIgnoreCase(\"startBrowser\"))\n {\n System.out.println(\"Executing startBroswer\");\n driver= Muvi_Functions.startBrowser(driver);\n System.out.println(\"Executing startBroswer\");\n }else if (Object_Type.equalsIgnoreCase(\"openApplication\"))\n {\n Muvi_Functions.openApplication(driver);\n test.log(LogStatus.INFO, Description);\n System.out.println(\"Executing openApplication\");\n }else if (Object_Type.equalsIgnoreCase(\"waitForElement\"))\n {\n Muvi_Functions.waitForElement(driver, Locator_Type, Locator_Value, Test_Data);\n test.log(LogStatus.INFO, Description);\n System.out.println(\"Executing waitForElement\");\n }else if (Object_Type.equalsIgnoreCase(\"typeAction\"))\n {\n Muvi_Functions.typeAction(driver, Locator_Type, Locator_Value, Test_Data);\n test.log(LogStatus.INFO, Description);\n System.out.println(\"Executing typeAction\");\n }else if (Object_Type.equalsIgnoreCase(\"clickAction\"))\n {\n Muvi_Functions.clickAction(driver, Locator_Type, Locator_Value);\n test.log(LogStatus.INFO, Description);\n System.out.println(\"Executing clickAction\");\n }else if (Object_Type.equalsIgnoreCase(\"selectAction\"))\n {\n Muvi_Functions.selectAction(driver, Locator_Type, Locator_Value);\n test.log(LogStatus.INFO, Description);\n System.out.println(\"Executing selectAction\");\n } else if (Object_Type.equalsIgnoreCase(\"selectStartDate\"))\n {\n Muvi_Functions.selectStartDate(driver, Locator_Type, Locator_Value);\n test.log(LogStatus.INFO, Description);\n System.out.println(\"Executing selectStartDate\");\n }\n else if (Object_Type.equalsIgnoreCase(\"switchWindow\"))\n {\n Muvi_Functions.switchWindow(driver);\n test.log(LogStatus.INFO, Description);\n System.out.println(\"Executing switchWindow\");\n }else if (Object_Type.equalsIgnoreCase(\"isElementVisible\"))\n {\n Muvi_Functions.isElementVisible(driver, Locator_Type, Locator_Value);\n test.log(LogStatus.INFO, Description);\n System.out.println(\"Executing isElementVisible\");\n }else if (Object_Type.equalsIgnoreCase(\"hoverOver\"))\n {\n Muvi_Functions.hoverOver(driver, Locator_Type, Locator_Value);\n test.log(LogStatus.INFO, Description);\n System.out.println(\"Executing hoverOver\");\n }else if (Object_Type.equalsIgnoreCase(\"uploadTopBanner\"))\n {\n Muvi_Functions.uploadTopBanner(driver);\n test.log(LogStatus.INFO, Description);\n System.out.println(\"Executing uploadTopBanner\");\n }\n else if (Object_Type.equalsIgnoreCase(\"uploadPoster\"))\n {\n Muvi_Functions.uploadPoster(driver);\n test.log(LogStatus.INFO, Description);\n System.out.println(\"Executing uploadPoster\");\n }\n else if (Object_Type.equalsIgnoreCase(\"profilePicture\"))\n {\n Muvi_Functions.profilePicture(driver);\n test.log(LogStatus.INFO, Description);\n System.out.println(\"Executing profilePicture\");\n }\n else if (Object_Type.equalsIgnoreCase(\"uploadVideo\"))\n {\n Muvi_Functions.uploadVideo(driver);\n test.log(LogStatus.INFO, Description);\n System.out.println(\"Executing uploadVideo\");\n }\n else if (Object_Type.equalsIgnoreCase(\"verifyUpload\"))\n {\n Muvi_Functions.verifyUpload(driver);\n test.log(LogStatus.INFO, Description);\n System.out.println(\"Executing verifyUpload\");\n }\n\n else if (Object_Type.equalsIgnoreCase(\"closeBrowser\"))\n {\n Muvi_Functions.closeBrowser(driver);\n test.log(LogStatus.INFO, Description);\n System.out.println(\"Executing closeBrowser\");\n }\n\n\n //write as pass into status column\n excel.setCellData(TCModule, j, 5, \"PASS\");\n test.log(LogStatus.PASS, Description);\n ScreenShot.Takescreen(driver,Description);\n ModuleStatus=\"TRUE\";\n\n }\n catch(Exception e)\n {\n excel.setCellData(TCModule, j, 5, \"FAIL\");\n ModuleStatus=\"FALSE\";\n if(ModuleStatus.equalsIgnoreCase(\"FALSE\"))\n {\n excel.setCellData(\"MasterTestCases\", i, 3, \"FAIL\");\n Thread.sleep(2000);\n test.log(LogStatus.FAIL, \"Test Fail\");\n ScreenShot.Takescreen(driver,Description);\n }\n System.out.println(e.getMessage());\n break;\n }\n if(ModuleStatus.equalsIgnoreCase(\"TRUE\"))\n {\n excel.setCellData(\"MasterTestCases\", i, 3, \"PASS\");\n }\n report.flush();//push reports to html\n report.endTest(test);\n }\n\n }\n else\n {\n //write as not executed in master testcases in status coulmn for flag N\n excel.setCellData(\"MasterTestCases\", i,3, \"Not Executed\");\n\n }\n }\n }", "LoadTest createLoadTest();", "public ResultatTest() {\n\t\tthis.nbTests = 0;\n\t\tthis.echecs = new ArrayList<TestExecute>();\n\t\tthis.erreurs = new ArrayList<TestExecute>();\n\t}", "public abstract int predict(double[] testingData);", "@Test(groups ={Slingshot,Regression})\n\tpublic void allAcctsStdUserCreation() {\n\t\tReport.createTestLogHeader(\"MuMv\", \"Verify whether the user can successfully enter details in Add new user page and registers it\"); \t \t \t \n\t\tUserProfile userProfile = new TestDataHelper().getUserProfile(\"MuMVTestDatas\");\n\t\tnew LoginAction()\n\t\t.BgbnavigateToLogin()\n\t\t.BgbloginDetails(userProfile);\n\t\tnew MultiUserMultiViewAction()\n\t\t.ClickManageUserLink()\n\t\t.ClickAddNewUserLink()\n\t\t.AddUserRadioButton()\n\t\t.StandardUserCreation();\n\t\tnew BgbRegistrationAction()\n\t\t.AddNewStdUser(userProfile);\n\t\tnew MultiUserMultiViewAction()\n\t\t.verifyAuditTable(userProfile)\n\t\t.AdduserConfirmationPage()\n\t\t.confirmationPageVerificationLinks();\n\t}", "public SalesFileTest( String testName )\n {\n super( testName );\n }", "private Test emptyTest() {\n return new TestSuite();\n }", "@Test\n void qureyInfoByStudentNum() {\n addInfoForGEIAS();\n }", "public static Test suite() {\n return new TestSuite(TestLearningAPI.class);\n }", "@Test\n public void autocreateLesson() throws Exception{\n\n }", "Test convert(TestData testData);", "@Test\n public void testGetRPMLow() {\n System.out.println(\"getRPMLow\");\n Regime instance = r1;\n double expResult = 1000.0;\n double result = instance.getRPMLow();\n assertEquals(expResult, result, 0.0);\n }", "public abstract double test(ClassifierData<U> testData);", "private RegressionPrior() { \n /* empty constructor */\n }", "private XmlSuite executeSubTest(String[] testClasses) throws IOException {\r\n\t\tXmlSuite suite = new XmlSuite();\r\n\t\tsuite.setName(\"TmpSuite\");\r\n\t\tsuite.setFileName(\"/home/test/seleniumRobot/data/core/testng/testLoggging.xml\");\r\n\t\tList<XmlSuite> suites = new ArrayList<XmlSuite>();\r\n\t\tsuites.add(suite);\r\n\t\t\r\n\t\tfor (String testClass: testClasses) {\r\n\t\t\tXmlTest test = new XmlTest(suite);\r\n\t\t\ttest.setName(testClass.substring(testClass.lastIndexOf(\".\") + 1));\r\n\t\t\tList<XmlClass> classes = new ArrayList<XmlClass>();\r\n\t\t\tclasses.add(new XmlClass(testClass));\r\n\t\t\ttest.setXmlClasses(classes) ;\r\n\t\t}\t\t\r\n\t\t\r\n\t\tTestNG tng = new TestNG(false);\r\n\t\ttng.setXmlSuites(suites);\r\n\t\ttng.addListener((IReporter)reporter);\r\n\t\ttng.addListener((IReporter)reporter2);\r\n\t\ttng.addListener((ITestListener)testListener);\r\n\t\ttng.addListener((IInvokedMethodListener)testListener);\r\n\t\ttng.addListener(retry);\r\n\t\ttng.setOutputDirectory(SeleniumTestsContextManager.getGlobalContext().getOutputDirectory());\r\n\t\ttng.run(); \r\n\t\tSeleniumRobotLogger.parseLogFile();\r\n\t\t\r\n\t\treturn suite;\r\n\t}", "@Override\n\tpublic void addTestReport(ConverterTester tester) throws Exception {\n\t\t\n\t}", "@Override\r\n\t\t\tpublic void test() {\n\t\t\t}", "@Test\n public void testFitnessProportionateSelection()\n {\n }", "@Test\n\tpublic void testNormalPuzzleGeneration() {\n\t}", "public static EvaluationResults generateEvaluationResults(String hyp_feature, String true_feature, FeatureSet fs)\n throws AuToBIException {\n Feature class_attribute = new Feature(true_feature);\n class_attribute.generateNominalValues(fs.getDataPoints());\n\n Feature hyp_attribute = new Feature(hyp_feature);\n hyp_attribute.generateNominalValues(fs.getDataPoints());\n\n Set<String> sorted_values = new LinkedHashSet<String>();\n sorted_values.addAll(class_attribute.getNominalValues());\n sorted_values.addAll(hyp_attribute.getNominalValues());\n\n EvaluationResults eval = new EvaluationResults(sorted_values);\n\n for (Word w : fs.getDataPoints()) {\n if (w.hasAttribute(\"__ignore__\") && ((Boolean) w.getAttribute(\"__ignore__\"))) {\n continue;\n }\n if (!w.hasAttribute(hyp_feature)) {\n AuToBIUtils.warn(\"Word, \" + w + \", has no hypothesized attribute: \" + hyp_feature);\n } else if (!w.hasAttribute(true_feature)) {\n AuToBIUtils.warn(\"Word, \" + w + \", has no true attribute: \" + hyp_feature);\n } else {\n eval.addInstance(w.getAttribute(hyp_feature).toString(), w.getAttribute(true_feature).toString());\n }\n }\n return eval;\n }", "private static void buildRegressionModel(Instances data, Instances itemsets, int[] items) throws Exception {\n\t\tif (data.numInstances() <= MAX_NB_LEAF) { //stop criterion possible needs to refined: data.variance(data.numAttributes()-1) < 10)\n\t\t\tdouble prediction = getPrediction(data,PREDICT_AVERAGE); \n\t\t\tdouble[] attributes = new double[data.numAttributes()];\n\t\t\tfor (int i : items) {\n\t\t\t\tattributes[i] = 1;\n\t\t\t}\n\t\t\tattributes[attributes.length-1] = prediction;\n\t\t\titemsets.add(new Instance(1, attributes ));\n\t\t}\n\t\telse{\n\t\t\tint[] items2 = findPattern(data);\n\t\t\tInstanceSelection data2 = select(data, items2);\n\t\t\titems2 = union(items2, items);\n\n\t\t\t// depth-first creation of the tree\n\t\t\tif (data2.getSelected().numInstances() != 0) {\n\t\t\t\tbuildRegressionModel(data2.getSelected(), itemsets, items2);\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\tif (data2.getNotSelected().numInstances() != 0) {\n\t\t\t\tbuildRegressionModel(data2.getNotSelected(), itemsets, items);\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t}\n\t\t\n\t}", "@Override\n\tpublic String toString() {\n\t\treturn name+\" : \"+test;\n\t}", "@Test(groups ={Slingshot,Regression,SubmitMeterRead})\npublic void verifySAPElecCustomer()\t\n{\t\n\tReport.createTestLogHeader(\"Anonymous Submit meter read\", \"Verifies the SAP SMR page for Electricity customer\");\n//SMRAccountDetails smrProfile = new TestDataHelper().getAllSMRUserProfile(\"SAPSMRGasUserforsingleMeter\");\n\tSMRAccountDetails smrProfile = new TestDataHelper().getAllSMRUserProfile(\"SAPSMRElectricityUserforsingleMeter\");\n\t\t new SubmitMeterReadAction()\n\t\t .openSMRpage(\"Electricity\")\n\t\t.verifyAnonymousSAPElecCustomersRewrite(smrProfile);\n}", "@Test\r\n public void testRentOut() {\r\n }", "public static void evaluate(final MLRegression network,\r\n \t\t\tfinal MLDataSet training) {\r\n \t\tint weekNo = ConfigLoto.HI_WEEKNO + 2;\r\n \r\n \t//\tfor (final MLDataPair pair : training) {\r\n \tfor (int i = 0; i < training.size(); i++) {\r\n \t\tfinal MLDataPair pair = training.get(i);\r\n \t\tMLData calculatedOutput = network.compute(pair.getInput());\r\n \t\t\t\r\n \t\t\tlog.debug(\"Predict WeekNo= \" + weekNo++);\r\n \t\t\tlog.debug(\"Input= \"\r\n \t\t\t\t\t+ ConfigLoto.formatData(pair.getInput(), PRECISION));\r\n \t\t\tlog.debug(\"Predict= \" // actual\r\n \t\t\t\t\t+ ConfigLoto.formatData(calculatedOutput, PRECISION + 2));\r\n \t\t\t\r\n \t\t\t// for set12 get the real output from next pair\r\n \t\t\tMLData nextWeekIdeal = null;\r\n \t\t\tif (i < (training.size()-1)){\r\n\t\t\t\t nextWeekIdeal = training.get(i+1).getIdeal();\r\n \t\t\t}\r\n \t\t\telse {\r\n \t\t\t\t nextWeekIdeal = pair.getIdeal();\r\n \t\t\t}\r\n \t\t\tlog.debug(\"RealOutput= \" // ideal\r\n \t\t\t\t\t+ ConfigLoto.formatData(nextWeekIdeal, PRECISION));\r\n \r\n \t\t\tlog.debug(\"Success Report ---------\");\r\n \t\t\tConfigLoto.calculateSuccess(weekNo - 1, calculatedOutput,\r\n \t\t\t\t\tnextWeekIdeal);\r\n \t\t\t\r\n \t\t\tINSERTSAYISALPREDICT = \"INSERT INTO SAYISALPREDICT (`algo`, `targeterr` , `populationsize` , `populationdensity` ,\"\r\n \t\t\t\t\t+ \"`weekid` , `realoutput` , `successfulpredictcount`, `successfulpredict` , `predict`) VALUES (\";\r\n \t\t\tINSERTSAYISALPREDICT = INSERTSAYISALPREDICT\r\n \t\t\t\t\t+ INSERTSAYISALPREDICTPART1 + weekNo + \",\\\"\"\r\n \t\t\t\t\t+ ConfigLoto.formatData(nextWeekIdeal, PRECISION) + \"\\\",\";\r\n \t\t\t\r\n \t\t}\r\n \t}", "@Test\n public void testCarregarTrimestre() {\n }", "@Test\n public void test23() throws Throwable {\n TextDirectoryLoader textDirectoryLoader0 = new TextDirectoryLoader();\n Instances instances0 = textDirectoryLoader0.getDataSet();\n Evaluation evaluation0 = new Evaluation(instances0);\n SerializedClassifier serializedClassifier0 = new SerializedClassifier();\n Object[] objectArray0 = new Object[25];\n double[] doubleArray0 = evaluation0.evaluateModel((Classifier) serializedClassifier0, instances0, objectArray0);\n assertEquals(0.0, evaluation0.SFEntropyGain(), 0.01D);\n }", "@Override\n public void generate(ToolContext context) throws ToolException {\n //Sorry but I needed to rewrite the code, doesn't have any point to override\n boolean initialized = getFieldValue(\"initialized\");\n if (!initialized) {\n initialize(context);\n }\n\n S2JJAXBModel rawJaxbModelGenCode = getFieldValue(\"rawJaxbModelGenCode\");\n if (rawJaxbModelGenCode == null) {\n return;\n }\n\n if (context.getErrorListener().getErrorCount() > 0) {\n return;\n }\n\n try {\n ByteArrayOutputStream stream = new ByteArrayOutputStream();\n\n CustomOutputStreamCodeWriter fileCodeWriter = new CustomOutputStreamCodeWriter(stream, \"utf-8\", results);\n ClassCollector classCollector = context.get(ClassCollector.class);\n for (JClass cls : rawJaxbModelGenCode.getAllObjectFactories()) {\n classCollector.getTypesPackages().add(cls._package().name());\n }\n JCodeModel jcodeModel = rawJaxbModelGenCode.generateCode(null, null);\n\n jcodeModel.build(fileCodeWriter);\n\n context.put(JCodeModel.class, jcodeModel);\n } catch (IOException e) {\n throw new RuntimeException(e);\n }\n }" ]
[ "0.601348", "0.5921491", "0.5870989", "0.58090156", "0.5781788", "0.5733605", "0.5711494", "0.5634968", "0.5613702", "0.5603351", "0.54225767", "0.5392295", "0.53014654", "0.521435", "0.52135545", "0.5185326", "0.5149574", "0.5142078", "0.51395816", "0.51358706", "0.51031655", "0.5097936", "0.5093598", "0.5089451", "0.50725806", "0.5071864", "0.5071778", "0.5063154", "0.50534844", "0.5048341", "0.5014205", "0.5010638", "0.50070506", "0.5004105", "0.5002639", "0.4982691", "0.4982031", "0.4947746", "0.4947418", "0.49328312", "0.49313024", "0.49245527", "0.49234268", "0.49221158", "0.4917491", "0.4912725", "0.49057624", "0.4903914", "0.48870373", "0.48852277", "0.48834538", "0.48804376", "0.48630983", "0.48522308", "0.48488858", "0.4847675", "0.48375395", "0.4837385", "0.48372856", "0.48363382", "0.48329943", "0.48231152", "0.48229438", "0.48109236", "0.48107374", "0.480965", "0.47993955", "0.47964907", "0.4782083", "0.4781121", "0.47772348", "0.47739878", "0.47682568", "0.47565705", "0.47527543", "0.47510862", "0.4749015", "0.47487667", "0.4745685", "0.47430354", "0.47375292", "0.4734273", "0.47300968", "0.47229925", "0.47201076", "0.4716168", "0.47144437", "0.47060308", "0.46998808", "0.46993843", "0.46985906", "0.46978626", "0.46963802", "0.46956667", "0.46955222", "0.4695177", "0.46944442", "0.46942672", "0.46926937", "0.46898842" ]
0.884113
0
Created by Administrator on 2017/5/25.
public interface MediaPlayer { public void play(String mediaType,String fileName); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private stendhal() {\n\t}", "@Override\n public void perish() {\n \n }", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\n\tpublic void entrenar() {\n\t\t\n\t}", "@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}", "@Override\n\tpublic void grabar() {\n\t\t\n\t}", "@Override\n public void inizializza() {\n\n super.inizializza();\n }", "@Override\n\tpublic void gravarBd() {\n\t\t\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "public final void mo51373a() {\n }", "public void mo38117a() {\n }", "@Override\n\tprotected void getExras() {\n\n\t}", "@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}", "@Override\n public void memoria() {\n \n }", "private static void cajas() {\n\t\t\n\t}", "@Override\n protected void initialize() {\n\n \n }", "@Override\n\tpublic void anular() {\n\n\t}", "public void mo4359a() {\n }", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "private Rekenhulp()\n\t{\n\t}", "Petunia() {\r\n\t\t}", "@Override\n protected void initialize() \n {\n \n }", "public contrustor(){\r\n\t}", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "@Override\r\n\tpublic void rozmnozovat() {\n\t}", "@Override\n public void settings() {\n // TODO Auto-generated method stub\n \n }", "private TMCourse() {\n\t}", "@Override\n public void init() {\n\n }", "@Override\r\n\tpublic void publierEnchere() {\n\t\t\r\n\t}", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n\tpublic void create () {\n\n\t}", "public Pitonyak_09_02() {\r\n }", "protected MetadataUGWD() {/* intentionally empty block */}", "public void mo55254a() {\n }", "private RepositorioAtendimentoPublicoHBM() {\r\t}", "@Override\n\tpublic void create() {\n\t\t\n\t}", "Constructor() {\r\n\t\t \r\n\t }", "public void designBasement() {\n\t\t\r\n\t}", "@Override\n protected void getExras() {\n }", "public void mo6081a() {\n }", "public void autoDetails() {\n\t\t\r\n\t}", "private void init() {\n\n\t}", "@Override\n void init() {\n }", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\n public void func_104112_b() {\n \n }", "@Override\n\tpublic void nadar() {\n\t\t\n\t}", "public void gored() {\n\t\t\n\t}", "@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}", "public void verarbeite() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}", "@Override\n\tpublic void einkaufen() {\n\t}", "@Override\n public void init() {\n }", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "public void create() {\n\t\t\n\t}", "@Override\n\tprotected void initialize() {\n\n\t}", "@Override\n\tpublic void nghe() {\n\n\t}", "@Override\n\tpublic void debite() {\n\t\t\n\t}", "private void poetries() {\n\n\t}", "@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}", "private UsineJoueur() {}", "public void mo12930a() {\n }", "private Singletion3() {}", "@SuppressWarnings(\"unused\")\n\tprivate void version() {\n\n\t}", "protected Doodler() {\n\t}", "@Override\n public void init() {\n\n }", "@Override\n public void init() {\n\n }", "@Override\n\tpublic void create() {\n\n\t}", "private ReportGenerationUtil() {\n\t\t\n\t}", "@Override\n\tprotected void interr() {\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "private static void oneUserExample()\t{\n\t}", "private void getStatus() {\n\t\t\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void create() {\n\r\n\t}", "@Override\n\tpublic void emprestimo() {\n\n\t}", "@Override\r\n\tprotected void initialize() {\n\r\n\t}" ]
[ "0.6291351", "0.61143273", "0.58851165", "0.58840513", "0.5849571", "0.5833249", "0.5821043", "0.5759452", "0.5758597", "0.5744525", "0.5744525", "0.57264096", "0.5725081", "0.5725081", "0.57208633", "0.5675805", "0.56750727", "0.5670423", "0.5668386", "0.5660013", "0.5659535", "0.565196", "0.5645848", "0.5643266", "0.562847", "0.559021", "0.5578287", "0.55771106", "0.55709696", "0.55709696", "0.55709696", "0.55709696", "0.55709696", "0.55709696", "0.55709696", "0.5562488", "0.55605227", "0.5555354", "0.55550194", "0.5519246", "0.5513858", "0.5513858", "0.5513858", "0.5513858", "0.5513858", "0.5513858", "0.5513417", "0.5505368", "0.547867", "0.5476232", "0.5475802", "0.5471311", "0.54706544", "0.54590106", "0.54491025", "0.5445278", "0.54399097", "0.54359275", "0.54283506", "0.54257256", "0.54257256", "0.5425445", "0.5424171", "0.5423091", "0.54179", "0.5414309", "0.5413727", "0.5399325", "0.5396978", "0.5396059", "0.5396059", "0.5396059", "0.5396059", "0.5396059", "0.5391855", "0.5389068", "0.53837126", "0.53813666", "0.5377854", "0.5369685", "0.5367293", "0.53607786", "0.5360645", "0.53597856", "0.5358552", "0.5358087", "0.5358087", "0.5356884", "0.53503656", "0.5349873", "0.5348465", "0.5348465", "0.5348465", "0.53423166", "0.53382075", "0.53347856", "0.53347856", "0.53347856", "0.533217", "0.533012", "0.5328129" ]
0.0
-1
/ 2^15 = 32768 and the sum of its digits is 26. What is the sum of the digits of the number 2^1000? BigInteger and bit manipulation: 2^1000 is a huge number, so we can use BigInteger to store it. shiftLeft will essentially shift the number n times, the number passed into the function. This means we're multiplying the current number by 2 n times, so we can start with 1 and shiftLeft 1000 times. Next, we convert it to a string so we can parse each digit at a time, then add it to an accumulator and return it.
public static int digitSumPowerTwo(int n) { String num = BigInteger.ONE.shiftLeft(1000).toString(); int sum = 0; for (int i = 0; i < num.length(); i++) sum += num.charAt(i) - '0'; return sum; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "void shiftLeft(int numberToShift);", "int left(int i) { return i<<1; }", "public static long sumOfDigitsByStream(BigInteger integer) {\n return integer.toString().chars()\n .map(x -> x & 0xF)\n .sum();\n }", "void shiftRight(int numberToShift);", "short digits();", "@Test\n public void test2(){\n\n String s =\"1000000000000001\";\n //s = BinaryCalculate.BinaryArithmeticalRightShift(s,1);\n s = BinaryCalculate.BinaryLogicRightShift(s,1);\n int a = BitConversion.fromBinaryStringToInt(s);\n System.out.println(a);\n }", "private static void testShift() {\n for (int a:new int[]{96754441, -206107026, 803362655, Integer.MIN_VALUE+1}) {\n System.out.println(\"<<\");\n for (int i=0;i<=32;i++) {\n System.out.println(intToBin(a<<i) + \" \" + (a<<i));\n }\n System.out.println();\n System.out.println(\">>\");\n for (int i=0;i<=32;i++) {\n System.out.println(intToBin(a>>i) + \" \" + (a>>i));\n }\n System.out.println();\n System.out.println(\">>>\");\n for (int i=0;i<=32;i++) {\n System.out.println(intToBin(a>>>i) + \" \" + (a>>>i));\n }\n System.out.println();\n }\n }", "public static Object shiftLeft(Object val1, Object val2) {\n\t\tif (isInt(val1) && isInt(val2)) {\n\t\t\tint n = ((BigInteger) val2).intValue();\n\t\t\treturn ((BigInteger) val1).shiftLeft(n);\n\t\t}\n\t\tthrow new OrccRuntimeException(\"type mismatch in shiftLeft\");\n\t}", "private static String digits(long val, int digits) {\n\tlong hi = 1L << (digits * 4);\n\treturn Long.toHexString(hi | (val & (hi - 1))).substring(1);\n }", "public static void main(String[] args) {\n int a = 0b10011;\n int res = Integer.rotateRight( a,2 );\n System.out.println(toBinaryString( a ) + \" RCIRC-2 ->\" + toBinaryString( res ) );\n System.out.println(toBinaryString( a ) + \" RCIRC-2 ->\" + toBinaryString( RCIRC( a,2 ) ) );\n\n //LCIRC-3(01101) = 01011\n //01000 <<3\n // 011 >>>2\n //01011 OR\n a = 0b01101;\n System.out.println(toBinaryString( a ) + \" LCIRC-3 ->\" + toBinaryString( LCIRC( a,3 ) ));\n\n\n String e1 = \"LSHIFT-2(10011 XOR 00110) OR (LCIRC-2(RCIRC-2(10001)))\";\n int res1 = ((0b10011 ^ 0b00110)>>>2) | LCIRC( RCIRC(0b10001 ,2 ), 2);\n System.out.println(e1 + \" = \" + toBinaryString( res1 ) + \", manual = 10101\");\n\n String e2 = \"( (RSHIFT-3(01000) XOR NOT(00110) ) AND (01101 OR RCIRC-2(10011))\";\n int res2 = ((0b01000>>>3) ^ (~0b00110)) & (0b01101 | RCIRC(0b10011, 2 ));\n\n System.out.println(e2 + \" = \" + toBinaryString( res2 ) + \", manual = ?????\");\n\n\n System.out.println(\"X AND 11010 = 01000, find all X\");\n for (byte i = 0; i <= 0b11111; i++) {\n if ((i & 0b11010)== 0b01000) {\n System.out.println(toBinaryString( i ));\n }\n }\n }", "private static int[] add(int[] x, long val) {\n int[] y;\n long sum = 0;\n int xIndex = x.length;\n int[] result;\n int highWord = (int)(val >>> 32);\n if (highWord == 0) {\n result = new int[xIndex];\n sum = (x[--xIndex] & LONG_MASK) + val;\n result[xIndex] = (int)sum;\n } else {\n if (xIndex == 1) {\n result = new int[2];\n sum = val + (x[0] & LONG_MASK);\n result[1] = (int)sum;\n result[0] = (int)(sum >>> 32);\n return result;\n } else {\n result = new int[xIndex];\n sum = (x[--xIndex] & LONG_MASK) + (val & LONG_MASK);\n result[xIndex] = (int)sum;\n sum = (x[--xIndex] & LONG_MASK) + (highWord & LONG_MASK) + (sum >>> 32);\n result[xIndex] = (int)sum;\n }\n }\n // Copy remainder of longer number while carry propagation is required\n boolean carry = (sum >>> 32 != 0);\n while (xIndex > 0 && carry)\n carry = ((result[--xIndex] = x[xIndex] + 1) == 0);\n // Copy remainder of longer number\n while (xIndex > 0)\n result[--xIndex] = x[xIndex];\n // Grow result if necessary\n if (carry) {\n int bigger[] = new int[result.length + 1];\n System.arraycopy(result, 0, bigger, 1, result.length);\n bigger[0] = 0x01;\n return bigger;\n }\n return result;\n }", "public static long sumOfDigitsByLooping(BigInteger integer) {\n String data = integer.toString();\n long sum = 0;\n for (int i = 0; i < data.length(); i++) {\n sum += data.charAt(i) & 0xF;\n }\n return sum;\n }", "public int[] plusOne(int[] digits) {\n\n if(digits==null || digits.length==0){\n return digits;\n }\n\n int carry =1;\n\n for(int i= digits.length-1;i>=0;i--){\n int sum = digits[i]+ carry;\n if(sum>=10){\n carry =1;\n }else\n carry =0;\n digits[i]= sum%10;\n }\n\n if(carry ==1){\n int [] newResult = new int[digits.length+1];\n newResult[0]=1;\n for(int i=0;i<digits.length;i++){\n newResult[i+1] =digits[i];\n }\n return newResult;\n }\n\n return digits;\n\n\n\n\n /*2nd Method\n int len = digits.length-1;\n\n if(digits[len] !=9)\n digits[len] = digits[len] +1;\n else{\n while(digits[len] == 9 && len!=0){\n digits[len] = 0;\n len--;\n }\n\n if(len==0 && digits[len]==9){\n digits[len] = 0;\n int newArray [] = new int[digits.length+1];\n newArray[0] = 1;\n for(int i=0;i<digits.length;i++){\n newArray[i+1] = digits[i];\n }\n return newArray;\n\n }else{\n digits[len] = digits[len] +1;\n }\n\n }\n return digits;*/\n\n }", "public static int sumSqure(int x){\n int sum=0;\n do{\n sum+=(x%10)*(x%10);\n x=x/10;\n }while(x!=0);\n return sum;\n }", "public static void main(String[] args) {\nint t = 101010101;\n// koden begynner her\nString s = \"\";\nwhile ( t % 10 > 0 ) {\ns = t % 10 + s;\nt = t / 10;\n}\ns = \"s = \" + s;\nout.println(s);\n\n }", "public static void main(String[] args) {\r\n\t\t// TODO Auto-generated method stub\r\n\t\tBigInteger num = new BigInteger(\"2\");\r\n\t\tnum = num.pow(1000);\r\n\t\tString str = num.toString();\r\n\t\tint sum = 0;\r\n\t\tfor(int i = 0; i < str.length(); i++) {\r\n\t\t\tString sub = str.substring(i,i+1);\r\n\t\t\tsum = sum + Integer.parseInt(sub);\r\n\t\t}\r\n\t\tSystem.out.println(sum);\r\n\t}", "private static String mod10(String code) {\n if (!code.matches(\"\\\\d+\")) {\n return null;\n }\n if (code.length() > 5) {\n return null;\n }\n // if length < 5, add leading \"0\"\n StringBuffer input = new StringBuffer(code);\n while (input.length() < 5) {\n input.insert(0, \"0\");\n }\n\n // 1. Using the number 12345, assign positions to the digits, from right\n // to left.\n\n // 2. Take the odd digit positions counting from the right (1st, 3rd,\n // 5th, etc.)\n StringBuffer odd = new StringBuffer();\n for (int i = 0; 2 * i < input.length(); i++) {\n odd.insert(0, input.charAt(2 * i));\n }\n\n // 3.Multiply by 2.\n int odd2 = Integer.parseInt(odd.toString()) * 2;\n\n // 4. Take the even digit positions starting from the right (2nd, 4th,\n // etc.).\n StringBuffer even = new StringBuffer();\n for (int i = 0; 2 * i + 1 < input.length(); i++) {\n even.insert(0, input.charAt(2 * i + 1));\n }\n\n // 5.Append (4) to the front of the results of (3).\n even.append(odd2);\n\n // 6. Add the digits of (5) together.\n double add = 0;\n for (int i = 0; i < even.length(); i++) {\n add = add + Integer.parseInt(even.substring(i, i + 1));\n }\n\n // 7. Find the next highest multiple of 10.\n double multiple = Math.ceil(add / 10) * 10;\n\n // 8. Subtract (6) from (7).\n Long result = Math.round(multiple - add);\n\n return result.toString();\n }", "private static int shiftLeftOneInPlace(int[] x, int carry)\n {\n int pos = x.length;\n while (--pos >= 0)\n {\n int val = x[pos];\n x[pos] = (val << 1) | carry;\n carry = val >>> 31;\n }\n return carry;\n }", "public static int getSum(int b, int n1, int n2) {\n int carry = 0;\r\n int pos = 1;\r\n int num = 0;\r\n while (n1 != 0 || n2 != 0 || carry != 0) {\r\n int a = n1 % 10;\r\n int d = n2 % 10;\r\n int c = a + d + carry;\r\n \r\n // if (c >= b)\r\n // c = c % b;\r\n carry = c/ b;\r\n c=c%b;\r\n num = num + pos * (c);\r\n \r\n pos *= 10;\r\n n1 /= 10;\r\n n2 /= 10;\r\n }\r\n\r\n return num;\r\n }", "public static void main(String[] args) {\n\t\tint n=345;\r\n\t\tint s=0;\r\n\t\twhile(n!=0)\r\n\t\t{\r\n\t\tint last=n%10;\r\n\t\ts =s+last;\r\n\t\tn= n/10;\t\r\n\t\t\t\r\n\t\t\t}\r\n\r\nSystem.out.println(s);\r\n\t}", "private static String digits(long val, int digits) {\n long hi = 1L << (digits * 4);\n return Long.toHexString(hi | (val & (hi - 1))).substring(1);\n }", "public static void main(String[] args) {\n\tString NUM = \"73167176531330624919225119674426574742355349194934\" +\n \"96983520312774506326239578318016984801869478851843\" +\n \"85861560789112949495459501737958331952853208805511\" +\n \"12540698747158523863050715693290963295227443043557\" +\n \"66896648950445244523161731856403098711121722383113\" +\n \"62229893423380308135336276614282806444486645238749\" +\n \"30358907296290491560440772390713810515859307960866\" +\n \"70172427121883998797908792274921901699720888093776\" +\n \"65727333001053367881220235421809751254540594752243\" +\n \"52584907711670556013604839586446706324415722155397\" +\n \"53697817977846174064955149290862569321978468622482\" +\n \"83972241375657056057490261407972968652414535100474\" +\n \"82166370484403199890008895243450658541227588666881\" +\n \"16427171479924442928230863465674813919123162824586\" +\n \"17866458359124566529476545682848912883142607690042\" +\n \"24219022671055626321111109370544217506941658960408\" +\n \"07198403850962455444362981230987879927244284909188\" +\n \"84580156166097919133875499200524063689912560717606\" +\n \"05886116467109405077541002256983155200055935729725\" +\n \"71636269561882670428252483600823257530420752963450\";\n\n //greatest combo array\n int[] greatestCombo = new int[13];\n //array to iterate through NUMS\n int[] combos = new int[13];\n //adjacency\n boolean adjacent = true;\n //product\n long product = 1;\n //maxProduct\n long maxProduct = 0;\n\n\t//iterating through the entire NUM string\n\tfor(int i = 0 ; i < NUM.length()-13; i++){\n\t //make a temporary array with the combination of the three numbers\n\t for(int c = 0; c < 13; c++){\n\t combos[c] = NUM.charAt(i+c);\n }\n\n\t //loop to determine if the numbers are adjacent\n for(int k = 1; k < 13; k++){\n if(abs(combos[k-1]-combos[k])>1){\n adjacent = false;\n break;\n }\n }\n\n //now that we have an adjacent 13-number array\n if(adjacent){\n //find the product\n for(int r = 0; r < 13; r++){\n product *= combos[r];\n }\n\n if(product > maxProduct){\n maxProduct = product;\n for(int p = 0; p < 13; p++){\n greatestCombo[p]=combos[p];\n }\n }\n }\n\n }\n System.out.println(maxProduct);\n\n }", "long mo107678c(Integer num);", "public int sumFirstAndLastDigit(int num) {\n\t\t// TODO Write an implementation for this method declaration\n\t\tint sum;\n\t\tint firstDigit = 0;\n\t\tint lastDigit = 0;\n\t\tint size;\n\t\tint num2;\n\t\tString num_string;\n\t\tif(num < 0) {\n\t\t\tsum = -1;\n\t\t}\n\t\telse {\n\t\t\tnum_string = Integer.toString(num);\n\t\t\tsize = num_string.length()-1;\n\t\t\tfirstDigit = (int)(num / (Math.pow(10, size)));\n\t\t\twhile(num > 10) {\n\t\t\t\tnum2 = (int)(num / (Math.pow(10, size)));\n\t\t\t\tnum = num % (int)(num2 * (Math.pow(10, size)));;\n\t\t\t\t//System.out.println(num);\n\t\t\t\tsize--;\n\t\t\t\t\n\t\t\t}\n\t\t\tlastDigit = num;\n\t\t\t//System.out.println(firstDigit);\n\t\t\t//System.out.println(lastDigit);\n\t\t\tsum = firstDigit+lastDigit;\n\t\t\t//System.out.println(sum);\n\t\t}\n\t\t\n\n\n\n//\t\tfirstDigit = (int) (num / (Math.pow(10, size)));\n//\t\tnum = (int)(num / (Math.pow(10, size)));\n//\t\tfirstDigit = num;\n\n\n\t\t\n\t\treturn sum;\n\t}", "private void addition()\n {\n\tint tempSum = 0;\n\tint carryBit = 0;\n\tsum = new Stack<String>();\n\tStack<String> longerStack = pickLongerStack(number, otherNumber);\n\twhile(!longerStack.isEmpty())\n\t{\n\t tempSum = digitOf(number) + digitOf(otherNumber) + carryBit; //adding\n\t carryBit = tempSum / 10;\n\t sum.push((tempSum % 10) + \"\"); //store the digit which is not carryBit\n\t}\n\tif(carryBit == 1) sum.push(\"1\"); //the last carry bit need to be add as very first digit of sum if there is carry bit\n }", "public static long nextPowerOfTwo(long x) {\n if (x == 0) return 1;\n x--;\n x |= x >> 1;\n x |= x >> 2;\n x |= x >> 4;\n x |= x >> 8;\n x |= x >> 16;\n return (x | x >> 32) + 1;\n }", "private static long tenToThePowerOfInt(int number) {\n\n\t\tlong result = 1; // default case (10 power 0)\n\n\t\t// checking for out of long range\n\t\tif (number > 18) {\n\t\t\treturn -1;\n\t\t}\n\n\t\tfor (int i = 0; i < number; i++) {\n\t\t\tresult = result * 10;\n\t\t}\n\n\t\treturn result;\n\n\t}", "public int step() {\n int lastBit = bitAt(0) ^ bitAt(currentIndex);\n char[] ch = lfsr1.toCharArray();\n for (int i = 0; i < lfsr1.length() - 2; i++) {\n ch[i] = ch[i + 1];\n }\n\n ch[lfsr1.length() - 2] = (char) (lastBit + '0');\n int temporary = lfsr1.length();\n lfsr1 = \"\";\n for (int i = 0; i < temporary; i++) {\n lfsr1 = lfsr1 + ch[i];\n }\n\n return lastBit;\n }", "public static void main(String[] args) throws IOException {\r\n\t long a = 1182312000;\r\n\t System.out.println((a<<1) + 57596000);\r\n\t System.out.println(Long.MAX_VALUE);\r\n }", "public static int addDigits(int x)\n\t{\n\t\t//Method variable\n\t\tint sum = 0;\n\t\t//Assign while loop and return a value.\n\t\twhile(x>0)\n\t\t{\n\t\t\t sum = x%10+sum;\n\t\t\t x=x/10;\n\t\t}\n\t\treturn(sum);\n\t}", "int main()\n{\n int num,rem;\n cin>>num;\n rem=num%10;\n cout<<rem+(num/1000);\n}", "private static long value(long x) {\n return (x<<1) >> 1; // 1\n }", "private static int calcDigitsSum(long number) {\r\n\t\tint sum = 0;\r\n\t\t\r\n\t\twhile (number != 0) {\r\n\t\t\tint value = (int) (number % 10);\r\n\t\t\tsum += value;\r\n\t\t\tnumber /= 10;\r\n\t\t}\r\n\t\t\r\n\t\treturn sum;\r\n\t}", "int nextBits(int bits);", "public long encode(long value) {\n\n return value ^ (value >> 1);\n }", "int main()\n{\n int a;\n std::cin>>a;\n int b=(a%10)+(a/1000);\n std::cout<<b;\n}", "public static void main(String args[] ) throws Exception {\n Scanner in = new Scanner(System.in);\n \n String original = in.next();\n int n = original.length();\n long moda = 1000000007;\n long ones = 1;\n long sum=0; \n for (int s=original.length()-1; s>=0; s--) {\n sum = (sum + (s+1) * (original.charAt(s) - '0') * ones) %moda; \n ones = (ones * 10 + 1) % moda;\n \n }\n \n System.out.println(sum);\n \n }", "private static long rl(long a, String b) {\r\n long res = a;\r\n for (int c = 0; c < b.length() - 2; c += 3) {\r\n char dChar = b.charAt(c + 2);\r\n long dInt = dChar >= 'a' ? (int) dChar - 87 : Long.valueOf(String.valueOf(dChar));\r\n char char2 = b.charAt(c + 1);\r\n long dInt2 = char2 == '+' ? res >>> dInt : res << dInt;\r\n res = b.charAt(c) == '+' ? res + dInt2 & 4294967295l : res ^ dInt2;\r\n }\r\n return res;\r\n }", "public static BigInteger bigIntEncrypt(String txt){\n\n\t String res = \"\"; //empty result string\n\n\t for(int i = 0; i < txt.length(); i++){ // for loop to get value of each char and adds to result\n\n\t res += (int)txt.charAt(i) + shift; // adds the num value of ascii to res string\n\n\t }\n\t\t\tSystem.out.println(\"------------------------------------------------\");\n\t System.out.println(\" String of char value + shift: \" + res); // shows the txt in big string format\n\t\t\tSystem.out.println(\"------------------------------------------------\\n\\n\");\n\n\t BigInteger bg = new BigInteger(res); // makes bigint out of res\n\n\n\t BigInteger newBg = bg.multiply(key); // math done to bigint\n\t\t\tSystem.out.println(\"--------------------------------------------------------------------------------------------------------------------------\");\n\t System.out.println(\" String of char values * speical prime: \" + newBg);\n\t\t\tSystem.out.println(\"--------------------------------------------------------------------------------------------------------------------------\\n\\n\");\n\n\t return newBg; // returns bigint, a very very big int\n\t }", "public static void main(String[] args) {\n System.out.println(\"Enter the number\");\n try (Scanner scanner = new Scanner(System.in)) {\n long theNumber = scanner.nextLong();\n\n //Using inBuilt method from the Integer class\n String x = Long.toBinaryString(theNumber);\n System.out.println(x);\n\n System.out.println(x.concat(\"0\".repeat(5)));\n new String(new char[10]);\n\n\n }\n }", "public int countDigitOne(int n) {\n long res = 0;\n for(int i = 1; i < n ; i *= 10){\n res += (long)n/i + n%(i*10);\n }\n return (int)res;\n }", "public static void main(String[] args) {\nScanner sc=new Scanner(System.in);\nint n=sc.nextInt();\nint temp=n;\nint sum=0;\nwhile(temp>0){\n\tint lastDigit=temp%10;\n\ttemp /= 10;\n\tsum += lastDigit;\n\tSystem.out.println(lastDigit+\" \"+temp+\" \"+sum);\n}\nSystem.out.println(\"Sum of the digits of \" + n +\" is \"+sum);\n//int numberofDigits=(int)Math.log10(n)+1;\n//System.out.println(numberofDigits);\n\t}", "private static long getResult(Triplet... triplets) {\n\t\tlong result = triplets[0].value;\n\t\tfor (int i = 1; i < triplets.length; i++) {\n\t\t\tresult = result*10 + triplets[i].value % 10;\n\t\t}\n\t\t//now discover first digit.\n\t\tString value = String.valueOf(result);\n\t\tfor (char c = '0'; c <= '9'; c++) {\n\t\t\tif (value.indexOf(c) < 0) {\n\t\t\t\tresult = result + (c - '0') * 1000000000L;\n\t\t\t}\n\t\t}\n\t\treturn result;\n\t}", "public static int nextPowerOfTwo(int x) {\n if (x == 0) return 1;\n x--;\n x |= x >> 1;\n x |= x >> 2;\n x |= x >> 4;\n x |= x >> 8;\n return (x | x >> 16) + 1;\n }", "private static String bigIntDecode(String in){\n\n\t BigInteger largeNum = new BigInteger(in); // declare and initialize the largenum\n\t\t//\n\t BigInteger smallNum = largeNum.divide(key); // reverse math done in encryption\n\tSystem.out.println(\"--------------------------------------------------------------------------------------------------------------------------\");\n\tSystem.out.println( \"Char Value *Must subtract shift now*: \" + smallNum.toString());\n\t\tSystem.out.println(\"--------------------------------------------------------------------------------------------------------------------------\\n\\n\");\n\t in = smallNum.toString(); //updates in to the small original big int\n\n\n\t String r = \"\"; // empty result string\n\n\t for(int i = 0; i < in.length();i += 3){ // for loop to extract each 3 nums and get ascii value\n\n\t char add; // declars the char to be added\n\n\t if(in.length() < 2){ //if to determine and handle short encryption\n\t add = (char)(Integer.parseInt(in.substring(i, i + 3)) - shift);\n\n\t }else{ // else, countine as normal, substring each 2 numbers and convert to ascii letter\n\t add = (char)(Integer.parseInt(in.substring(i, i + 3)) - shift );\n\n\t }\n\n\t r+= add; // updates result string\n\t }\n\t\t\t\t\t\tSystem.out.println(\"--------------------------------------------------------------------------------------------------------------------------\");\n\t\t\t\t\tSystem.out.println(\" Decrypted Message Found: \" + r);\n\t\t\t\t\t\tSystem.out.println(\"--------------------------------------------------------------------------------------------------------------------------\\n\\n\");\n\t return r; // returns result string\n\t }", "static int add(int a, int b){\n int carry = 0;\n int result = 0;\n int i;\n for(i=0; a>0||b>0; i++){\n int ba = a&1;\n int bb = b&1;\n result = result|((carry^ba^bb)<<i);\n carry = (ba&bb) | (bb&carry) | (carry&ba);\n a = a>>1;\n b = b>>1;\n }\n return result|(carry<<i);\n }", "protected int left(int i ) { return 2 * i + 1; }", "public int[] plusOne(int[] digits) {\n\t\tint carry = 0;\n\t\tdigits[digits.length - 1] += 1;\n\t\tfor (int i = digits.length - 1; i >= 0; i--) {\n\t\t\tdigits[i] = digits[i] + carry;\n\t\t\tcarry = digits[i] / 10;\n\t\t\tdigits[i] %= 10;\n\t\t}\n\t\tif (carry == 0) {\n\t\t\treturn digits;\n\t\t} else {\n\t\t\tint[] newDigits = new int[digits.length + 1];\n\t\t\tfor (int i = 0; i < digits.length; i++) {\n\t\t\t\tnewDigits[i + 1] = digits[i];\n\t\t\t\tnewDigits[0] = carry;\n\t\t\t}\n\t\t\treturn newDigits;\n\t\t}\n\t}", "private static int sumDigits(int number)\n {\n if (number < 10)\n return -1;\n int sum = 0, leastSignificantBit = 0;\n\n while (number > 0)\n {\n //extract the least significant bit\n leastSignificantBit = number % 10;\n sum += leastSignificantBit;\n\n //drop the least significant digit\n number /= 10;\n }\n return sum;\n }", "private static int LEFT(int i) {\n return (2 * i + 1);\n }", "public static Object shiftRight(Object val1, Object val2) {\n\t\tif (isInt(val1) && isInt(val2)) {\n\t\t\tint n = ((BigInteger) val2).intValue();\n\t\t\treturn ((BigInteger) val1).shiftRight(n);\n\t\t}\n\t\tthrow new OrccRuntimeException(\"type mismatch in shiftRight\");\n\t}", "public StringBuilder add(StringBuilder m, StringBuilder n)\n {\n \n int carryover=0 , sum=0;\n StringBuilder result=new StringBuilder();\n if(m.length()>=n.length())\n {\n n=align(n,m.length());\n }\n else{\n m=align(m,n.length());\n }\n \n String temp1=new String();\n String temp2=new String();\n for (int i=m.length()-1;i>=0;i--) {\n \n \n temp1=temp1+m.charAt(i);\n temp2=temp2+n.charAt(i);\n sum=Integer.parseInt(temp1)+Integer.parseInt(temp2)+carryover;\n //sum=(int) m.charAt(i)+(int)n.charAt(i)+carryover;\n if (sum>=10)\n {\n carryover=1;\n sum=sum-10;\n result.insert(0,sum);\n temp1=\"\";\n temp2=\"\";\n }\n else{\n carryover=0;\n result.insert(0,sum);\n temp1=\"\";\n temp2=\"\";\n } \n }\n if (carryover==1) {\n result.insert(0,carryover);\n }\n //int value=Integer.parseInt(result.toString());\n //result.delete(0,result.length());\n //result.append(value);\n //if (result.length()<m.length())\n // result=align(result,m);\n \n return result;\n \n }", "public BinaryNumber shiftR(int amount) {\n \tint[] data1 = new int[amount+data.length];\n \tfor (int i = 0; i < amount; i++) {\n \t\tdata1[i] = 0;\n \t}\n \tfor (int i = 0; i <data.length; i++) {\n \t\tdata1[amount] = data[i];\n \t\tamount++;\n \t}\n \tdata = data1;\n\t\tString s = new String();\n\t\tfor (int i = 0; i < data.length; i++) {\n\t\t\ts = s.concat(Integer.toString(data[i]));\n\t\t}\n\t\treturn new BinaryNumber(s);\n }", "public static long digitSum(long n){\n if (String.valueOf(n).contains(\"-\")) return 0;\n long sum = 0;\n char[] chs = String.valueOf(n).toCharArray();\n for (char ch : chs){\n sum += Long.parseLong(String.valueOf(ch));\n }\n return sum;\n }", "protected static int left(int i){\n return 2*i+1;\n }", "static long mpow(long x, int k) {\n\t long result = 1;\n\t for(; k > 0; k >>= 1) {\n\t if(k % 2 == 1) {\n\t result = mod(result * x ,511);\n\t }\n\t x = mod(x * x , 511);\n\t }\n\t return result;\n\t}", "public String shiftLeft(String text, int x) {\n\t\tString toShift = text.substring(text.length() - x , text.length());\n\t\tString newCipher = toShift += text;\n\t\tString result = newCipher.substring(0, toShift.length() - x);\n\t\t\n\t\treturn result;\n\t}", "public static int getSumOfDigitsinInt(int val) {\n\t\t// if we have just on digit, stop it\n\t\tif (val < 10) {\n\t\t\treturn val;\n\t\t} else {\n\t\t\t//we find the last digit in the int value, if 123, the last is 3\n\t\t\tint theLastDigit = val % 10;\n\t\t\t//we find another part of int, to divide it, until we don't come to 1 digit\n\t\t\tint beforeTheLastDigit = val / 10;\n\t\t\treturn theLastDigit + getSumOfDigitsinInt(beforeTheLastDigit);\n\t\t}\n\t}", "private static String subProcess(int[] n1, int[] n2) {\n\n\t\t// if n1.length is smaller than n2.length, we are going to be too small.\n\t\tif (n1.length < n2.length) {\n\t\t\treturn \"+\" + toString (n1);\n\t\t}\n\t\t\n\t\t// we have to extend, and reduce length. Note that this WILL terminate because\n\t\t// we would have left earlier if n2 were greater than n1.\n\t\tint off = 0;\n\t\tint length = n2.length;\n\t\twhile (compareTo(n2,0,length,n1,off) > 0) {\n\t\t\tn2 = expand(n2);\n\t\t\tlength = n2.length;\n\t\t\t\n\t\t\tif (length > n1.length) {\n\t\t\t\t// gone too far! We at last have our remainder! Return as \"+remainder\".\n\t\t\t\treturn \"+\" + toString(n1);\n\t\t\t}\n\t\t}\n\t\t\n\t\t\n\t\tint []innerSum = new int[n1.length+1]; // add 1 just in case we get too high\n\t\tint []result = new int[length]; \n\t\tint start;\n\t\t\n\t\t// initial set.\n\t\tif (n2[0] == 0) { start = 9; } else { start = n1[0]/n2[0]; }\n\t\t\n\t\tmultiply(n2, start, innerSum);\n\t\tinnerSum = reduce(innerSum);\n\t\t\n\t\tif (innerSum.length < n2.length) {\n\t\t\t// perfect fit. Expand back out to work with subtractDown. REALLY UGLY CODE\n\t\t\tinnerSum = expand(innerSum);\n\t\t} else {\n\t\t\t// must reduce and continue....\n\t\t\twhile (n2.length < innerSum.length) {\n\t\t\t\tstart--; // had gone too far! Back down.\n\t\t\t\tinnerSum = new int[n1.length+1];\n\t\t\t\tmultiply (n2, start, innerSum);\n\t\t\t\tinnerSum = reduce(innerSum);\n\t\t\t}\n\t\t}\n\t\t\n\t\tboolean subtractDown = compareTo(innerSum, n1, innerSum.length) > 0; // if false, we have to add up\n\t\twhile (true) {\n\t\t\tif (subtractDown) {\n\t\t\t\tstart--;\n\t\t\t\tsubtract(innerSum, n2, result, subProcessSign);\n\t\t\t\tassign(innerSum, result);\n\t\t\t\t\n\t\t\t\tsubtractDown = compareTo(innerSum, n1, innerSum.length) > 0;\n\t\t\t} else {\n\t\t\t\t// found. Note that 'start' is the digit in the quotient. Subtract from and replace.\n\t\t\t\tint []newTop = new int[innerSum.length];\n\t\t\t\textract(newTop,0,n1,0,innerSum.length);\n\t\t\t\t\n\t\t\t\tresult = new int[innerSum.length];\n\t\t\t\tsubtract(newTop, innerSum, result, subProcessSign); \n\t\t\t\textract(n1,0,result,0,result.length); // copy back in\n\t\t\t\t\n\t\t\t\tint[]normalized_n1 = reduce(n1);\n\t\t\t\tint[]normalized_n2 = reduce(n2);\n\t\t\t\tString s = start + subProcess(normalized_n1, normalized_n2);\n\t\t\t\treturn s;\n\t\t\t}\n\t\t}\n\t\t\n\t}", "public int countDigitOne(int n) {\n int res = 0;\n for(long i = 1 ; i <= n; i *= 10){\n long k = n/i, r = n % i;\n res += (k + 8) / 10 * i + ((k%10 == 1)?(r+1):0);\n }\n return res;\n }", "private static int getDigit(int position, int value, int radix) {\n return value / (int) Math.pow(radix,position) % radix;\n }", "static int left(int i)\n {\n return (2*i+1);\n }", "public static int getProduct(int b, int n1, int n2){\n int r1=0,pow=1,res1=0,res=0,carry=0,sum=0;\n while(n1 !=0)\n {\n r1=n1%10;\n n1/=10;\n res1=multiply(r1,n2,b,pow);\n res=SumAnybase(res1,res,b);\n pow=pow*10;\n }\n return res;\n }", "private int Sum1(int x) {\n int a = ROTR(6, x);\n int b = ROTR(11, x);\n int c = ROTR(25, x);\n int ret = a ^ b ^ c;\n return ret;\n }", "private int nextPowerOf2(int n)\n {\n if (n > 0 && (n & (n - 1)) == 0)\n return n;\n \n int count = 0;\n for (;n != 0; n = n >> 1)\n count += 1;\n \n return 1 << count;\n }", "private int xtimes(int x){\r\n\t\tx = x << 1;\r\n\t\tif(x >= 0x100)\r\n\t\t\tx = x ^ 0x14d;\r\n\t\treturn x;\r\n\t}", "public static String addBinaryNumbers(String num1, String num2) {\r\n\t\tif (num1 == null || num2 == null)\r\n\t\t\treturn null;\r\n\t\t\r\n\t\tint index1 = num1.length() - 1;\r\n\t\tint index2 = num2.length() - 1;\r\n\t\tboolean carry = false;\r\n\t\tString result = \"\";\r\n\t\t\r\n\t\twhile(index1 >= 0 && index2 >= 0) {\r\n\t\t\tint sum = Integer.parseInt(num1.substring(index1, index1 + 1)) + Integer.parseInt(num2.substring(index2, index2 + 1));\r\n\t\t\tif (sum == 0) {\r\n\t\t\t\tif (carry) {\r\n\t\t\t\t\tresult += '1';\r\n\t\t\t\t\tcarry = false;\r\n\t\t\t\t} else\r\n\t\t\t\t\tresult += '0';\r\n\t\t\t} else if (sum == 1) {\r\n\t\t\t\tif (carry)\r\n\t\t\t\t\tresult += '0';\r\n\t\t\t\telse\r\n\t\t\t\t\tresult += '1';\r\n\t\t\t} else { // sum == 2\r\n\t\t\t\tif (carry)\r\n\t\t\t\t\tresult += '1';\r\n\t\t\t\telse {\r\n\t\t\t\t\tresult += '0';\r\n\t\t\t\t\tcarry = true;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tindex1--;\r\n\t\t\tindex2--;\r\n\t\t}\r\n\t\t\r\n\t\twhile(index1 >= 0) {\r\n\t\t\tif (num1.charAt(index1) == '0') {\r\n\t\t\t\tif (carry) {\r\n\t\t\t\t\tresult += '1';\r\n\t\t\t\t\tcarry = false;\r\n\t\t\t\t} else\r\n\t\t\t\t\tresult += '0';\r\n\t\t\t} else { // num1.charAt(index1) == '1'\r\n\t\t\t\tif (carry)\r\n\t\t\t\t\tresult += '0';\r\n\t\t\t\telse\r\n\t\t\t\t\tresult += '1';\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tindex1--;\r\n\t\t}\r\n\t\t\r\n\t\twhile(index2 >= 0) {\r\n\t\t\tif (num2.charAt(index2) == '0') {\r\n\t\t\t\tif (carry) {\r\n\t\t\t\t\tresult += '1';\r\n\t\t\t\t\tcarry = false;\r\n\t\t\t\t} else\r\n\t\t\t\t\tresult += '0';\r\n\t\t\t} else { // num2.charAt(index2) == '1'\r\n\t\t\t\tif (carry)\r\n\t\t\t\t\tresult += '0';\r\n\t\t\t\telse\r\n\t\t\t\t\tresult += '1';\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tindex2--;\r\n\t\t}\r\n\t\t\r\n\t\tif (carry)\r\n\t\t\tresult += '1';\r\n\t\t\r\n\t\t// reverse result string\r\n\t\tString reverseResult = \"\";\r\n\t\tfor (int i = result.length() - 1; i >= 0; i--)\r\n\t\t\treverseResult += result.charAt(i);\r\n\t\t\r\n\t\treturn reverseResult;\r\n\t}", "public static Node addStraightNumbersHelper(Node num1,Node num2){\n if(num1 == null){\n return null;\n }\n int carry = 0;\n Node result = addStraightNumbersHelper(num1.next,num2.next);\n if(result!=null) {\n carry = result.value / 10;\n result.value = result.value % 10;\n }\n Node superResult = new Node(num1.value+num2.value+carry);\n superResult.next=result;\n return superResult;\n\n }", "private static String wrapAdd(String lhsString, int rhs) {\n int lhs = Integer.parseInt(lhsString, 2);\n int result = lhs + rhs;\n String bitString = zeroPaddedBitString(result);\n return bitString.substring(BITS_IN_INTEGER - lhsString.length());\n }", "static int digitSum(String n, int k) {\n int sum = findSum(convertToList(n));\n // Finding the initial super digit where k=1\n sum = findSuperDigit(convertToList(sum));\n // Calculating k times the super digit to find actual result\n return findSuperDigit(convertToList(sum*k));\n }", "public static long sumOfDigits(long n) {\n int sum = 0;\n // Checks the integer and adds up its variables\n while (n > 0) {\n sum += n % 10;\n n /= 10;\n }\n // returns the sum of digits back\n return sum;\n }", "void shiftR(int amount) {\n\t\tint newlength = data.length + amount;\n\t\tint newdata[] = Arrays.copyOf(data, newlength);\n\t\tfor(int i = newdata.length - 1;i >= amount;i--) {\n\t\t\tnewdata[i] = data[i - amount];\n\t\t}\n\t\tfor(int i = 0;i < amount;i++) {\n\t\t\tnewdata[i] = 0;\n\t\t\t\n\t\t}\n\t\tString str = \"\";\n\t\tfor(int i = 0 ;i < newlength;i++) {\n\t\t\tstr = str + newdata[i];\n\t\t}\n\t\tSystem.out.println(\"the result of shifting:\" + str);\n\t}", "private static int getRightShiftedNumberBufAsInt(int numberBuf,\n long bitPos, int nrBits, ByteOrder byteOrder) throws BitBufferException {\n\n // number of bits integer buffer needs to be shifted to the right in\n // order to reach the last bit in last byte\n long shiftBits;\n if (byteOrder == ByteOrder.BigEndian)\n shiftBits = 7 - ((nrBits + bitPos + 7) % 8);\n else\n shiftBits = bitPos % 8;\n\n return numberBuf >> shiftBits;\n }", "public TribitByte shiftLeft(int shift){\n return shiftRight(-shift);\n }", "public final PythonParser.shift_expr_return shift_expr() throws RecognitionException {\n PythonParser.shift_expr_return retval = new PythonParser.shift_expr_return();\n retval.start = input.LT(1);\n\n PythonTree root_0 = null;\n\n List list_right=null;\n PythonParser.arith_expr_return left = null;\n\n PythonParser.shift_op_return shift_op202 = null;\n\n PythonParser.arith_expr_return right = null;\n right = null;\n RewriteRuleSubtreeStream stream_arith_expr=new RewriteRuleSubtreeStream(adaptor,\"rule arith_expr\");\n RewriteRuleSubtreeStream stream_shift_op=new RewriteRuleSubtreeStream(adaptor,\"rule shift_op\");\n\n List ops = new ArrayList();\n\n try {\n // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:1188:5: (left= arith_expr ( ( shift_op right+= arith_expr )+ | -> $left) )\n // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:1188:7: left= arith_expr ( ( shift_op right+= arith_expr )+ | -> $left)\n {\n pushFollow(FOLLOW_arith_expr_in_shift_expr5124);\n left=arith_expr();\n\n state._fsp--;\n if (state.failed) return retval;\n if ( state.backtracking==0 ) stream_arith_expr.add(left.getTree());\n // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:1189:9: ( ( shift_op right+= arith_expr )+ | -> $left)\n int alt95=2;\n int LA95_0 = input.LA(1);\n\n if ( (LA95_0==RIGHTSHIFT||LA95_0==LEFTSHIFT) ) {\n alt95=1;\n }\n else if ( (LA95_0==EOF||LA95_0==NEWLINE||LA95_0==NAME||(LA95_0>=AND && LA95_0<=AS)||LA95_0==FOR||LA95_0==IF||(LA95_0>=IN && LA95_0<=IS)||(LA95_0>=NOT && LA95_0<=ORELSE)||(LA95_0>=RPAREN && LA95_0<=COMMA)||(LA95_0>=SEMI && LA95_0<=DOUBLESLASHEQUAL)||(LA95_0>=LESS && LA95_0<=AMPER)||LA95_0==RBRACK||(LA95_0>=RCURLY && LA95_0<=BACKQUOTE)) ) {\n alt95=2;\n }\n else {\n if (state.backtracking>0) {state.failed=true; return retval;}\n NoViableAltException nvae =\n new NoViableAltException(\"\", 95, 0, input);\n\n throw nvae;\n }\n switch (alt95) {\n case 1 :\n // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:1189:11: ( shift_op right+= arith_expr )+\n {\n // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:1189:11: ( shift_op right+= arith_expr )+\n int cnt94=0;\n loop94:\n do {\n int alt94=2;\n int LA94_0 = input.LA(1);\n\n if ( (LA94_0==RIGHTSHIFT||LA94_0==LEFTSHIFT) ) {\n alt94=1;\n }\n\n\n switch (alt94) {\n \tcase 1 :\n \t // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:1189:13: shift_op right+= arith_expr\n \t {\n \t pushFollow(FOLLOW_shift_op_in_shift_expr5138);\n \t shift_op202=shift_op();\n\n \t state._fsp--;\n \t if (state.failed) return retval;\n \t if ( state.backtracking==0 ) stream_shift_op.add(shift_op202.getTree());\n \t pushFollow(FOLLOW_arith_expr_in_shift_expr5142);\n \t right=arith_expr();\n\n \t state._fsp--;\n \t if (state.failed) return retval;\n \t if ( state.backtracking==0 ) stream_arith_expr.add(right.getTree());\n \t if (list_right==null) list_right=new ArrayList();\n \t list_right.add(right.getTree());\n\n \t if ( state.backtracking==0 ) {\n\n \t ops.add((shift_op202!=null?shift_op202.op:null));\n \t \n \t }\n\n \t }\n \t break;\n\n \tdefault :\n \t if ( cnt94 >= 1 ) break loop94;\n \t if (state.backtracking>0) {state.failed=true; return retval;}\n EarlyExitException eee =\n new EarlyExitException(94, input);\n throw eee;\n }\n cnt94++;\n } while (true);\n\n\n }\n break;\n case 2 :\n // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:1195:8: \n {\n\n // AST REWRITE\n // elements: left\n // token labels: \n // rule labels: retval, left\n // token list labels: \n // rule list labels: \n // wildcard labels: \n if ( state.backtracking==0 ) {\n retval.tree = root_0;\n RewriteRuleSubtreeStream stream_retval=new RewriteRuleSubtreeStream(adaptor,\"rule retval\",retval!=null?retval.tree:null);\n RewriteRuleSubtreeStream stream_left=new RewriteRuleSubtreeStream(adaptor,\"rule left\",left!=null?left.tree:null);\n\n root_0 = (PythonTree)adaptor.nil();\n // 1195:8: -> $left\n {\n adaptor.addChild(root_0, stream_left.nextTree());\n\n }\n\n retval.tree = root_0;}\n }\n break;\n\n }\n\n\n }\n\n retval.stop = input.LT(-1);\n\n if ( state.backtracking==0 ) {\n\n retval.tree = (PythonTree)adaptor.rulePostProcessing(root_0);\n adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop);\n }\n if ( state.backtracking==0 ) {\n\n if (!ops.isEmpty()) {\n retval.tree = actions.makeBinOp((left!=null?((PythonTree)left.tree):null), ops, list_right);\n }\n\n }\n }\n\n catch (RecognitionException re) {\n errorHandler.reportError(this, re);\n errorHandler.recover(this, input,re);\n retval.tree = (PythonTree)adaptor.errorNode(input, retval.start, input.LT(-1), re);\n }\n finally {\n }\n return retval;\n }", "@Override\n public String run() {\n long sum = 0;\n int limit = 2000000;\n for (int num = 2; num < limit; num++){\n if(isPrime(num)){\n sum += num;\n }\n }\n return Long.toString(sum);\n }", "public static void main(String[] args) {\n System.out.println(32>>2);// 0010 0000>>2= 0000 1000=8\n\n System.out.println(32/4);//32除以2的2次幂\n\n System.out.println(8<<2);// 0000 1000<<2=0010 0000=32\n System.out.println(8*4);//8 乘以2的2次幂\n\n System.out.println(2<<2);//2*2(2)=8\n\n System.out.println(-32>>>2);//32除以2的2次幂\n\n\n }", "BigInteger getPower_consumption();", "private static long getRightShiftedNumberBufAsLong(long numberBuf,\n long bitPos, int nrBits, ByteOrder byteOrder) throws BitBufferException {\n\n // number of bits integer buffer needs to be shifted to the right in\n // order to reach the last bit in last byte\n long shiftBits;\n if (byteOrder == ByteOrder.BigEndian)\n shiftBits = 7 - ((nrBits + bitPos + 7) % 8);\n else\n shiftBits = bitPos % 8;\n\n return numberBuf >> shiftBits;\n }", "public List<Integer> selfDividingNumbers(int left, int right) {\n List<Integer> list = new ArrayList<>();\n for (int i=left; i<= right; i++) {\n int n = i;\n boolean selfDividing = true;\n while (n != 0) {\n int digit = n % 10;\n if (digit == 0 || i % digit != 0) {\n selfDividing = false;\n break;\n }\n n = n/10;\n }\n if (selfDividing) {\n list.add(i);\n }\n }\n return list;\n }", "public BigInteger shiftLeftOneBit() {\n return signum() == 0 ? this : BitLevel.shiftLeftOneBit(this);\n }", "int next(int bits);", "private long getNumber(String num, int l, int r) {\n if (num.charAt(l) == '0' && r > l)\n return -1;\n int i = l;\n long sum = 0;\n while (i <= r) {\n sum = sum * 10 + num.charAt(i) - '0';\n i++;\n }\n return sum;\n }", "public static int convertToBinary(int input)\n {\n /*create a variable for remainder of input divided by 2 (will be either 0 or 1);\n this is the least significant digit of the binary string\n */\n int remainder = input % 2; \n \n //base case, return input if input is 0 or 1 (smallest two possibilities)\n if (input == 0 || input == 1) \n return input; \n \n /* if input is not 0 or 1, then return remainder + (value returned by \n convertToBinary(input/2) multiplied by ten); note that if there are n \n recursive method calls, then the return value of the final recursive \n method call is the value of the bit in the 2^ns place; when the stack is \n popped, that value is then multiplied by ten in order to move it one position\n leftward (because this method technically returns a base ten integer, and we\n are simply interpreting it as a binary string), and then the remainder is added to \n give the value of the least significant bit, and this process repeats until\n the initial method call is reached, at which point the remainder is the \n least significant bit\n */\n \n else\n { \n //System.out.println(\"\\nreturn \" + remainder + \" + convert(\"+input/2+\") * 10\");\n return remainder + (convertToBinary(input/2)*10);\n }\n \n }", "private static int numBytesFromBits(int bits) {\n \t\treturn (bits + 7) >> 3;\n \t}", "static void resta(){\n Scanner scanner = new Scanner(System.in);\n\n System.out.print(\"Ingrese el primer numero binario: \");\n String bin1 = scanner.nextLine();\n\n System.out.print(\"Ingrese el segundo numero binario: \");\n String bin2 = scanner.nextLine();\n\n int A = Integer.parseInt(bin1,2);\n int B = Integer.parseInt(bin2,2);\n\n Long suma = (long) A + (~B + 1);\n\n System.out.println(\"\\nLa resta es: \" + Long.toBinaryString(suma)); \n \n scanner.close();\n }", "public static String add(String num1,String num2)\n\t{\n\t\t\n\t\tString num3=\"\";\n\t\tint res, carry=0;\n\t\t\n\t\t\n\t\t//appending zeros to num1 if length of num1 is less\n\t\tif(num1.length()<num2.length())\n\t\t{\n\t\t\tint n=num2.length()-num1.length();\n\t\t\twhile(n!=0)\n\t\t\t{\n\t\t\t\tnum1=\"0\"+num1;\n\t\t\t\tn--;\n\t\t\t}\n\t\t}\n\t\t\n\t\t//appending zeros to num2 if length of num2 is less\n\t\telse if(num2.length()<num1.length())\n\t\t{\n\t\t\tint n=num1.length()-num2.length();\n\t\t\twhile(n!=0)\n\t\t\t{\n\t\t\t\tnum2=\"0\"+num2;\n\t\t\t\tn--;\n\t\t\t}\n\t\t}\n\t\t\n\t\t//running the loop till strings are not null\n\t\twhile(num1.length()!=0)\n\t\t{\n\t\t\t\n\t\t\tchar c1=num1.charAt(num1.length()-1);\n\t\t\tchar c2=num2.charAt(num2.length()-1);\n\t\t\t\n\t\t\t//convert c1 and c2 into integer and then add\n\t\t\tres=Integer.parseInt(\"\"+c1)+ Integer.parseInt(\"\"+c2)+carry;\t\t\n\t\t\t\n\t\t\t//if we get a 2 digit number after addition then breaking the carry and storing the units part\n\t\t\tif(res/10!=0)\n\t\t\t{\n\t\t\t\tnum3=(res%10)+num3;\n\t\t\t\tcarry=res/10;\n\t\t\t}\n\t\t\t\n\t\t\telse\t\n\t\t\t{\n\t\t\t\tnum3=res+num3;\t\n\t\t\t\tcarry=0;\n\t\t\t}\n\t\t\n\t\t\t//truncating the last digit of num1 and num2\n\t\t\tnum1=num1.substring(0,num1.length()-1);\n\t\t\tnum2=num2.substring(0,num2.length()-1);\n\t\t}\n\t\t\n\t\tif(carry!=0)\n\t\tnum3=carry+num3;\n\t\t//System.out.println(\"num3= \"+num3);\n\t\treturn num3;\n\t}", "public long bits() {\n\t\tlong x = n;\n\t\tif (x > 0) {\n\t\t\tlong msw = get(x - 1) & 0xffffffffL;\n\t\t\tx = (x - 1) * BPU;\n\t\t\tx = x & 0xffffffffL;\n\t\t\tlong w = BPU;\n\t\t\tdo {\n\t\t\t\tw >>= 1;\n\t\t\t\tif (msw >= ((1 << w) & 0xffffffffL)) {\n\t\t\t\t\tx += w;\n\t\t\t\t\tx = x & 0xffffffffL;\n\t\t\t\t\tmsw >>= w;\n\t\t\t\t}\n\t\t\t} while (w > 8);\n\t\t\tx += bittab[(int) msw];\n\t\t\tx = x & 0xffffffffL;\n\t\t}\n\t\treturn x;\n\t}", "private int combineDigits(int acc, char digit) {\n return acc * 10 + Character.getNumericValue(digit);\n }", "public String base10to2(int n) throws Exception {\r\n\r\n\t\t // int n = Integer.valueOf(base10);\r\n\t\t \r\n\t\t if (n < 0 || n > maxValue)\r\n\t\t\t throw new Exception (\"the input number exceeds the allowable limits\");\r\n\t \r\n\t\t String binaryStr = Integer.toBinaryString(n);\r\n\t \r\n\t //pad the above string to make it to 8 bits representation\r\n\t //if positive number, the most significant bit is 0, else 1\r\n\t if (n>0)\r\n\t \tbinaryStr= String.format(\"%8s\", binaryStr).replace(' ', '0');\r\n\t else{\r\n\t \tbinaryStr = Integer.toBinaryString((-1)*n);\r\n\t \t\r\n\t \tbinaryStr= String.format(\"%8s\", binaryStr).replace(' ', '0');\r\n\t \tbinaryStr = get2sComplement(binaryStr);\r\n\t }\r\n\t return binaryStr;\r\n\t }", "private int shift(int x) {\n\tif (x >= upperBound) \n\t return (x%upperBound); \n\telse if (x < 0)\n\t return ((-x)%upperBound);\n\telse\n\t return x; \n }", "public static BinaryExpression leftShift(Expression expression0, Expression expression1, Method method) { throw Extensions.todo(); }", "private int getLowTenBitNumber(int num) {\n return num & 1023;\n }", "public static int maximumPower(String s) {\n int power = 1,maxpower=1;\n for (int i = 0; i < s.length()-1; i++) {\n System.out.println(\"i \" + i);\n System.err.println(s + \" \" + Integer.parseInt(s, 2));\n int decimal = Integer.parseInt(s, 2);\n power = 1;\n System.out.println(\"result \" + decimal / Math.pow(2, power));\n if (decimal % Math.pow(2, power) == 0)\n {\n maxpower = max(maxpower,power);\n while(decimal % Math.pow(2, ++power) == 0){}\n maxpower = max(maxpower,power);\n\n } \n else if (decimal % Math.pow(2, power) < 0) {\n System.out.println(\"inside \" + decimal / Math.pow(2, power));\n s = leftrotate(s) + \"\";\n continue;\n } else {\n\n while (decimal >= Math.pow(2, ++power) / 2) {\n System.out.println(\"inside while \" + decimal / Math.pow(2, power));\n if (decimal % Math.pow(2, power) == 0)\n maxpower = max(maxpower, power);\n else if (decimal % Math.pow(2, power) < 0)\n break;\n }\n }\n System.out.println(\"End \");\n s = leftrotate(s) + \"\";\n\n }\n\n return maxpower;\n\n }", "public static int[] plusOne(int[] digits) {\n\n int last = digits.length - 1;\n\n // check if last element less than 9, if so add 1 and return array\n if (digits[last] < 9){\n digits[last] = digits[last] + 1;\n return digits;\n }\n\n //declare variable increment\n int increment = 0;\n for (int i = last; i > -1; i--) {\n if (i == last) {\n digits[i] = digits[i] + 1;\n }\n \n digits[i] = digits[i] + increment;\n increment = 0;\n if (digits[i] > 9) {\n increment++;\n digits[i] = digits[i] % 10;\n }\n }\n\n if (increment > 0) {\n int[] moreDigits = new int[digits.length + 1];\n moreDigits[0] = increment;\n for (int j = 1; j < moreDigits.length; j++) {\n moreDigits[j] = digits[j-1];\n }\n return moreDigits;\n }\n\n return digits;\n }", "private int getSumOfSquares(int n) {\n\t\tint sum = 0;\n\t\tint number = n;\n\t\tint current;\n\t\t\n\t\twhile(number != 0) {\n\t\t\tcurrent = number % 10;\n\t\t\tsum += Math.pow(current, 2);\n\t\t\tnumber /= 10;\n\t\t}\n\t\treturn sum;\n\t}", "public static int sumDigits(int number){\n if(number < 10){\r\n return -1;\r\n }\r\n\r\n\r\n //need to assign the digit to an empty variable\r\n int sum = 0;\r\n\r\n while(number > 0){\r\n\r\n //assign last digit in number to variable\r\n int last_digit = number%10;\r\n\r\n //add last_digit to sum\r\n sum += last_digit;\r\n\r\n //drop the least significant digit\r\n number = number/10;\r\n\r\n //number is now the digits without the last digit and this new number is used to test the loop\r\n }\r\n\r\n return sum;\r\n\r\n\r\n\r\n }", "private static int calculate(int limit) {\n\t\tPrimeGenerator primeGenerator = new PrimeGenerator((int) Math.floor(Math.sqrt(limit)) + 10);\n\n\t\t// BitSet is used to set a given number/index if it can be produced as p1^2 + p2^3 + p4^4\n\t\t// because there are numbers that can be produced more than once\n\t\tBitSet numbers = new BitSet(limit);\n\t\tnumbers.set(0, limit, false);\n\n\t\tList<Integer> list = primeGenerator.getPrimeList();\n\n\t\tfor (int a : list) {\n\t\t\tint powera = a * a;\n\t\t\tsearchB: for (int b : list) {\n\t\t\t\tint powerb = b * b * b;\n\t\t\t\tif (powera + powerb > limit) {\n\t\t\t\t\tbreak searchB;\n\t\t\t\t}\n\n\t\t\t\tsearchC: for (int c : list) {\n\t\t\t\t\tint powerc = c * c * c * c;\n\t\t\t\t\tint sum = powera + powerb + powerc;\n\t\t\t\t\tif (sum > limit) {\n\t\t\t\t\t\tbreak searchC;\n\t\t\t\t\t}\n\t\t\t\t\t// Set the index - the number is passed\n\t\t\t\t\tnumbers.set(sum);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// Set the number of set bit - the solution\n\t\treturn numbers.cardinality();\n\t}", "public static BinaryExpression leftShift(Expression expression0, Expression expression1) { throw Extensions.todo(); }", "public static ListAdd.ListNode addTwoNumbers(ListAdd.ListNode l1, ListAdd.ListNode l2) {\n if (l1 == null)\n return l2;\n if (l2 == null)\n return l1;\n ListAdd.ListNode res = null, head = null;\n int total = 0;\n int carry = 0;\n while (l1 != null && l2 != null) {\n if (res == null) {\n total = (l1.val + l2.val);\n carry = total / 10;\n res = new ListAdd.ListNode(total % 10); //13 % 10 = 3\n head = res;\n } else {\n total = (l1.val + l2.val + carry);\n carry = total / 10;\n\n res.next = new ListAdd.ListNode(total % 10);\n res = res.next;\n }\n l1 = l1.next;\n l2 = l2.next;\n }\n while (l1 != null) {\n total = (l1.val + carry);\n carry = total / 10;\n res.next = new ListAdd.ListNode(total % 10);\n res = res.next;\n l1 = l1.next;\n }\n while (l2 != null) {\n total = (l2.val + carry);\n carry = total / 10;\n res.next = new ListAdd.ListNode(total % 10);\n res = res.next;\n l2 = l2.next;\n }\n if (carry > 0) {\n res.next = new ListAdd.ListNode(carry);\n }\n return head;\n }" ]
[ "0.6082635", "0.55755556", "0.5494899", "0.54630196", "0.54583526", "0.54381907", "0.54270583", "0.5420644", "0.54101497", "0.53817993", "0.5356335", "0.53500235", "0.5331985", "0.5318995", "0.5315217", "0.5302749", "0.52752966", "0.52604944", "0.52399176", "0.52149737", "0.5199651", "0.51508594", "0.51487505", "0.51346874", "0.5129814", "0.5121795", "0.51192", "0.51103824", "0.50927734", "0.5090458", "0.50775176", "0.50750697", "0.5053025", "0.5035627", "0.5030635", "0.50245434", "0.50189835", "0.5002956", "0.49840584", "0.49622506", "0.49535626", "0.49533987", "0.495025", "0.49393845", "0.49374297", "0.4926566", "0.49242526", "0.49238", "0.4919915", "0.49173647", "0.49066857", "0.48899937", "0.48868316", "0.4877334", "0.4855906", "0.48540983", "0.4848599", "0.48328415", "0.48265323", "0.48262504", "0.48162466", "0.48106351", "0.48052508", "0.47941774", "0.4790166", "0.47858086", "0.47856432", "0.47847798", "0.4783702", "0.4780832", "0.47650248", "0.47593525", "0.47575676", "0.47553423", "0.47484684", "0.4747133", "0.47406936", "0.4738589", "0.47295976", "0.47258398", "0.47196186", "0.47186798", "0.47166765", "0.471267", "0.47125828", "0.47035205", "0.4700909", "0.47000667", "0.46958986", "0.46903872", "0.46897686", "0.4688341", "0.4686364", "0.4682994", "0.46762323", "0.4674984", "0.4674551", "0.4673007", "0.4672353", "0.46705416" ]
0.5617054
1
Created by asham_000 on 7/16/2015.
public interface MoveTreeGeneratorInterface { public List getNextMoves(CheckersBoard board) throws BadMoveException; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void perish() {\n \n }", "public final void mo51373a() {\n }", "private stendhal() {\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\n\tpublic void grabar() {\n\t\t\n\t}", "@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\n\tpublic void entrenar() {\n\t\t\n\t}", "public void mo38117a() {\n }", "@Override\n public void func_104112_b() {\n \n }", "@Override\n\tpublic void sacrifier() {\n\t\t\n\t}", "@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}", "@Override\n\tpublic void anular() {\n\n\t}", "@Override\n\tpublic void nadar() {\n\t\t\n\t}", "@Override\n\tprotected void interr() {\n\t}", "public void mo4359a() {\n }", "public void gored() {\n\t\t\n\t}", "@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}", "@Override\n\tpublic void gravarBd() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "protected boolean func_70814_o() { return true; }", "@Override\n\tprotected void getExras() {\n\n\t}", "@Override\n public void init() {\n\n }", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "private void poetries() {\n\n\t}", "@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}", "private void m50366E() {\n }", "@Override\n\tpublic void jugar() {\n\t\t\n\t}", "private static void cajas() {\n\t\t\n\t}", "private void kk12() {\n\n\t}", "@Override\n\tpublic void ligar() {\n\t\t\n\t}", "@Override\r\n\tpublic void rozmnozovat() {\n\t}", "@Override\n protected void initialize() {\n\n \n }", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "@Override\n\tpublic void nghe() {\n\n\t}", "private void init() {\n\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\n protected void init() {\n }", "@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}", "@Override\n\tprotected void initialize() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n public void init() {\n }", "protected void mo6255a() {\n }", "@Override\r\n\tpublic void init() {}", "@Override\r\n\tprotected void doF4() {\n\t\t\r\n\t}", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n public void init() {}", "@Override\n public void init() {\n\n }", "@Override\n public void init() {\n\n }", "@Override\r\n\tpublic void init()\r\n\t{\n\t}", "@Override\n protected void initialize() \n {\n \n }", "public void mo12930a() {\n }", "private Rekenhulp()\n\t{\n\t}", "@Override\n\tprotected void initdata() {\n\n\t}", "@Override\n void init() {\n }", "@Override\n\tpublic void einkaufen() {\n\t}", "public final void mo91715d() {\n }", "public void mo6081a() {\n }", "public void mo12628c() {\n }", "@Override\n\tpublic void debite() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t}", "protected MetadataUGWD() {/* intentionally empty block */}", "@Override\n\tpublic void one() {\n\t\t\n\t}", "@Override\n public int describeContents() { return 0; }", "@Override\r\n\tprotected void initialize() {\n\r\n\t}", "@Override\n\tpublic void init()\n\t{\n\n\t}", "@Override\n public void inizializza() {\n\n super.inizializza();\n }", "public void mo21877s() {\n }", "public void mo55254a() {\n }", "@Override\n\tprotected void initData() {\n\t\t\n\t}", "Constructor() {\r\n\t\t \r\n\t }", "@Override\n protected void getExras() {\n }" ]
[ "0.6066946", "0.5962797", "0.590852", "0.5893548", "0.5888851", "0.5837117", "0.58071154", "0.58029366", "0.57879007", "0.57879007", "0.5773754", "0.57491237", "0.5732619", "0.5695021", "0.5693275", "0.5682265", "0.56783164", "0.56719255", "0.5660676", "0.56579393", "0.56575865", "0.5643307", "0.5636467", "0.5636467", "0.5636467", "0.5636467", "0.5636467", "0.5629374", "0.56223255", "0.5581601", "0.5577574", "0.5577574", "0.55773515", "0.5572151", "0.55714273", "0.5563118", "0.5559414", "0.5558819", "0.5557573", "0.5552465", "0.5528904", "0.55189925", "0.55189925", "0.5517175", "0.5517175", "0.5517175", "0.5517175", "0.5517175", "0.5517175", "0.5517175", "0.5507874", "0.55072755", "0.55024743", "0.55024743", "0.55024743", "0.5502054", "0.5499767", "0.5499767", "0.5499767", "0.549936", "0.5488997", "0.54877144", "0.5485596", "0.5485596", "0.5485596", "0.5481258", "0.54745936", "0.54565436", "0.54541284", "0.54490995", "0.54490995", "0.54490995", "0.54490995", "0.54490995", "0.54490995", "0.54478806", "0.54397964", "0.54397964", "0.54325813", "0.543066", "0.5429714", "0.54293305", "0.5423131", "0.541858", "0.54156256", "0.5415519", "0.541425", "0.5413342", "0.5406161", "0.5404935", "0.5398768", "0.5395031", "0.5394497", "0.53934425", "0.5393417", "0.5392338", "0.5385396", "0.5376463", "0.5370719", "0.53679585", "0.5358167" ]
0.0
-1
write your code in Java SE 8
public static int[] solution(int[] A, int K) { for (int counter = 1; counter <= K; counter++) { int n = A.length - 1; int temp = A[n]; for (int i = 0; i < n; i++) { A[n - i] = A[n - i - 1]; } A[0] = temp; } return A; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static void main(String[] args) {\n\t\tnew Action() {\r\n\r\n\t\t\t@Override\r\n\t\t\tpublic void execute(String content) {\r\n\t\t\t\t// TODO Auto-generated method stub\r\n\t\t\t\tSystem.out.println(content);\r\n\t\t\t}\r\n\t\t\t\r\n\t\t}.execute(\"jdk1.8之前匿名内部类实现方式\");\r\n\t\t\r\n\t\t\r\n\t\t//lambda\r\n\t\tAction login=(String content)->{\r\n\t\t\tSystem.out.println(\"jdk1.8的lambda语法实现\");\r\n\t\t};\r\n\t\tlogin.execute(\"jdk1.8的lambda语法实现\");\r\n\t\t\r\n\t}", "public static void main(String[] args) {\n\t\t\r\n\t\tnew Thread(new Runnable() {\r\n\t\t\tpublic void run() {\r\n\t\t\t\tSystem.out.println(\"Before JAVA 8, too much code for too little to do\");\r\n\t\t\t}\r\n\t\t}).start();\r\n\t\t\r\n\t\t// Java 8 way:\r\n\t\t\r\n\t\tnew Thread( () -> System.out.println(\"In Java 8, Lambda Expression rocks !!\") ).start();\r\n\t\t\r\n\t\tSystem.out.println(\"-----------*************************-------------\");\r\n\t\t\r\n\t\t// Iterating Over List Using Lambda Expressions\r\n\t\t\r\n\t\tList features = Arrays.asList(\"Lambdas\",\"Default Method\",\"Stream API\",\"DAte and Time API\");\r\n\t\t\r\n\t\tfeatures.forEach(n -> System.out.println(n));\r\n\r\n\t\tSystem.out.println(\"-----------*************************-------------\");\r\n\t\t\t\t\r\n\t\t// Even better use method reference feature of Java 8\r\n\t\t// method reference is denoted by :: ****double colon***** operator\r\n\t\t// looks similar to scope resolution operator of C++\r\n\t\t\r\n\t\tfeatures.forEach(System.out::println);\r\n\r\n\t}", "public static void main(String[] args) {\r\n\t\tSomeJava8Features obj = new SomeJava8Features();\r\n\r\n\t\t// StringJoiner\r\n\t\texampleStringJoiner();\r\n\t\t\r\n\t\t// Default\r\n\t\tint ary[] = {3,6,8,9,0};\r\n\t\tSystem.out.println(\"\\nsumOfGivenIntArray ... \" + obj.sumOfGivenIntArray(ary));\r\n\t\tobj.sayMore(\"Hello Rohini\");\r\n\t\t\r\n\t\t// ForEach & Lambda Expression\r\n\t\texampleForEach_FindMaximum(ary);\r\n\t\t\r\n\r\n\t}", "@Deprecated\n\tprivate void oldCode()\n\t{\n\t}", "@Override\r\n\tprotected void doF8() {\n\t\t\r\n\t}", "private void level7() {\n }", "Compatibility compatibility();", "@SuppressWarnings(\"unused\")\n\tprivate void version() {\n\n\t}", "public static void main(String[] args) {\n throw new NotImplementedException();\n }", "public static void main(String[] args) {\n Foo foo = new Java8Default();\n foo.sumDefault(2,4);\n\n }", "@Test\n public void source8() throws Exception {\n ImmutableList<String> options = (GeneratedAnnotationsTest.isJdk9OrLater()) ? ImmutableList.of(\"--release\", \"8\") : ImmutableList.of(\"-source\", \"8\", \"-target\", \"8\");\n String generated = runProcessor(options, null);\n assertThat(generated).contains(GeneratedAnnotationsTest.JAVAX_ANNOTATION_GENERATED);\n assertThat(generated).doesNotContain(GeneratedAnnotationsTest.JAVAX_ANNOTATION_PROCESSING_GENERATED);\n }", "void compileToJava();", "public static void main(String args[]) throws Exception\n {\n \n \n \n }", "public final void mo8775b() {\n }", "public static void main(String[] args) {\n\t\t//Até o java 7\n\t\tnew Thread(new Runnable() {\n\n\t\t @Override\n\t\t public void run() {\n\t\t System.out.println(\"Executando um Runnable\");\n\t\t }\n\n\t\t}).start();\n\t\t//A partir do java 8\n\t\tnew Thread(() -> System.out.println(\"Executando um Runnable\")).start();\n\t\t\n\t\t//iterando com java 8: classe anonima\n\t\ttexto.forEach(new Consumer<String>() {\n\t\t public void accept(String s) {\n\t\t System.out.println(s);\n\t\t }\n\t\t});\n\t\t//iterando com java 8: lambda\n\t\t//Essa sintaxe funciona para qualquer interface \n\t\t//que tenha apenas um método abstrato\n\t\ttexto.forEach((String s) -> {\n\t\t System.out.println(s);\n\t\t});\n\t\t//ou\n\t\ttexto.forEach((s) -> {\n\t\t System.out.println(s);\n\t\t});\n\t\t//ou\n\t\ttexto.forEach(s -> {\n\t\t System.out.println(s);\n\t\t});\n\t\t//ou\n\t\ttexto.forEach(s -> System.out.println(s));\n\t\t// Uma interface que possui apenas um método abstrato \n\t\t//é agora conhecida como interface funcional e pode ser utilizada dessa forma\n\t\t\n\t\t//Outro exemplo é o próprio Comparator. Se utilizarmos a forma \n\t\t//de classe anônima, teremos essa situação: \n\t\ttexto.sort(new Comparator<String>() {\n\t\t public int compare(String s1, String s2) {\n\t\t if (s1.length() < s2.length())\n\t\t return -1;\n\t\t if (s1.length() > s2.length())\n\t\t return 1;\n\t\t return 0;\n\t\t }\n\t\t});\n\t\t//ou com lambda\n\t\ttexto.sort((s1, s2) -> {\n\t\t if (s1.length() < s2.length())\n\t\t return -1;\n\t\t if (s1.length() > s2.length())\n\t\t return 1;\n\t\t return 0;\n\t\t});\n\t\t//ou\n\t\ttexto.sort((s1, s2) -> {\n\t\t return Integer.compare(s1.length(), s2.length());\n\t\t});\n\t\t//ou como há apenas um único statement, podemos remover as chaves\n\t\ttexto.sort((s1, s2) -> Integer.compare(s1.length(), s2.length()));\n\t}", "public void mo38117a() {\n }", "void mo57277b();", "public static void main(String[] args) {\n version1WhileLoop();\n version1DoWhileLoop();\n version1ForLoop();\n version2ForLoop();\n version3ForLoop();\n }", "public abstract boolean mo2163j();", "public static void main(String[] args) throws Exception {\n\t\t\t\t\t\t\n\t\t\t\t\n\t\t\t}", "private NativeSupport() {\n\t}", "private static IRIProvider makeProviderJDK() { return new IRIProviderJDK(); }", "public void mo21785J() {\n }", "@Override\n public void func_104112_b() {\n \n }", "public static void generateCode()\n {\n \n }", "private UsingSwig() {\n\t}", "public static void main(String[] args) {\n\t\tlanceur8();\n\t}", "void mo1941j();", "public abstract void mo2624j();", "private final boolean updateState(java.lang.Object r7, java.lang.Object r8) {\n /*\n // Method dump skipped, instructions count: 101\n */\n throw new UnsupportedOperationException(\"Method not decompiled: kotlinx.coroutines.flow.StateFlowImpl.updateState(java.lang.Object, java.lang.Object):boolean\");\n }", "void mo72113b();", "static void feladat7() {\n\t}", "void mo28306a();", "private static void cajas() {\n\t\t\n\t}", "private void habilitar() {\n throw new UnsupportedOperationException(\"Not supported yet.\"); //To change body of generated methods, choose Tools | Templates.\n }", "public static void main(String[] args) {\n\n\t\tUnaryOperator<Integer> func=x->x*7;\t\t\n\t\tint num=func.apply(10);\n\t\tSystem.out.println(num);\n\t\t\n\t\tFunction<Integer, Integer> func1=x->x*10;\n\t\tSystem.out.println(func1.apply(10));\n\t\t\n\t\tList<String> langList=new ArrayList<String>();\n\t\tlangList.add(\"Java\");\n\t\tlangList.add(\"Ruby\");\n\t\tlangList.add(\"Python\");\n\t\t\n\t\tSystem.out.println(langList);\n\t\t\n\t\tlangList.replaceAll(ele -> ele +\" Deeps\");\n\t\tSystem.out.println(langList);\n\t}", "void mo57278c();", "interface DefaultMethod extends SingleMethod {\r\n\tdefault public void myMethod() {\r\n\t\tSystem.out.println(\"from Java 1.8 version can have method with a body\");\r\n}\r\n}", "void mo80457c();", "public void mo21792Q() {\n }", "public static void main(String[] args) {\n \n }", "public static void main(String[] args) {\n \n }", "public static void main(String[] args) {\n \n }", "public static void main(String[] args) {\n \n }", "public static void main(String[] args) {\n \n }", "public static void main(String[] args) {\n \n }", "public void mo21787L() {\n }", "public void method_4270() {}", "static void feladat8() {\n\t}", "public static void main() {\n \n }", "private void level6() {\n }", "void mo57275a();", "void mo80452a();", "private Quantify()\n {\n throw new UnsupportedOperationException(\"Instantiation of utility classes is not supported.\");\n }", "public void m9741j() throws cf {\r\n }", "@Before\n public void setUp() {\n Assume.assumeThat(JavaVersion.getMajorVersion(), Matchers.lessThanOrEqualTo(8));\n }", "private stendhal() {\n\t}", "void mo41083a();", "public static void main(String[] args) {\n\t\tisPolindrom(\"abcd\");\r\n\t\tfibJava8(2);\r\n\t\tfactJava8(5);\r\n\t}", "void m8368b();", "@Override\n\tpublic void implementionSeven(String[] args) throws Exception {\n\n\t}", "public void mo6081a() {\n }", "java.lang.String getS8();", "public void mo21879u() {\n }", "void mo119582b();", "public abstract void mo27385c();", "public abstract void mo70713b();", "public void mo21781F() {\n }", "public interface AnonymousClass1lE {\n void A7X(String str, String str2, String str3);\n\n void A7Z(String str, String str2, @Nullable Map<String, String> map);\n\n void A7b(String str, String str2, Throwable th, @Nullable Map<String, String> map);\n\n void A7d(String str, String str2, @Nullable Map<String, String> map);\n\n void A7f(String str, String str2);\n\n void A8G(String str, String str2, boolean z);\n\n boolean A9J(String str);\n}", "void mo41086b();", "public static void main(String[] args) {\n\n // Creating object of class in main() method\n JEP306_StritfpSample t = new JEP306_StritfpSample();\n\n // Here we have error of putting strictfp and\n // error is not found public static void main method\n System.out.println(t.sum());\n }", "public static void main(String[] args) {\n \n \n }", "public static void main(String[] args) {\n \n \n }", "private void kk12() {\n\n\t}", "public static void main(String[] args) {\n //Ersetzt jetzt mal unseren Parser, Stell Dir vor\n // das Ding liest das Beispiel da oben ^^.\n final StatementNode[] statementNodes = readStatements();\n \n //Zustände:\n // - FillSymbolTable (was für Symbole [variablen, ...] gibt es)\n // - TypInferenz (Was für Typen haben die Expressions und sind die eingaben semantisch korrekt)\n // - CodeGenerierung oder Ausführung (ersetzen wir mit \"schreibe die Werte aller Variablen nach Ende der Ausführung\")\n \n \n final SymbolTabelle symbolTabelle = new SymbolTabelle();\n //IDEE 2:\n //Ich gebe Statements und Expressions nur eine Methode mit Visitor als Callback\n final StatementVisitorSymbolTabelle statementVisitorSymbolTabelle = new StatementVisitorSymbolTabelle(symbolTabelle);\n for(StatementNode statementNode : statementNodes) {\n statementNode.accept(statementVisitorSymbolTabelle);\n }\n \n final StatementVisitorTypInferenz statementVisitorTypInferenz = new StatementVisitorTypInferenz(symbolTabelle);\n for(StatementNode statementNode : statementNodes) {\n statementNode.accept(statementVisitorTypInferenz);\n }\n \n PseudoLaufContext laufContext = new PseudoLaufContext();\n final StatementVisitorCodeGen statementVisitorCodeGen = new StatementVisitorCodeGen(laufContext);\n for(StatementNode statementNode : statementNodes) {\n statementNode.accept(statementVisitorCodeGen);\n }\n \n laufContext.druckeVariablen();\n \n //Zusammenfassung:\n //Reduktion des Problems darauf, den Code nur noch von einem Abhängig zu machen\n //Jetzt nur noch abhängig vom Typ des Statements\n \n \n //Problem hierbei:\n //Ich muss selbst angeben, in welchem Zustand ich bin\n //Code-Duplizierung\n }", "public static void main(String[] args) {\n \n \n \n\t}", "private void someUtilityMethod() {\n }", "private void someUtilityMethod() {\n }", "void mo80455b();", "interface C15937b {\n /* renamed from: a */\n void mo13368a();\n\n /* renamed from: a */\n void mo13369a(int i, int i2, int i3, boolean z);\n\n /* renamed from: a */\n void mo13370a(int i, int i2, List<C15929a> list) throws IOException;\n\n /* renamed from: a */\n void mo13371a(int i, long j);\n\n /* renamed from: a */\n void mo13372a(int i, ErrorCode errorCode);\n\n /* renamed from: a */\n void mo13373a(int i, ErrorCode errorCode, ByteString byteString);\n\n /* renamed from: a */\n void mo13374a(boolean z, int i, int i2);\n\n /* renamed from: a */\n void mo13375a(boolean z, int i, int i2, List<C15929a> list);\n\n /* renamed from: a */\n void mo13376a(boolean z, int i, BufferedSource bufferedSource, int i2) throws IOException;\n\n /* renamed from: a */\n void mo13377a(boolean z, C15943j c15943j);\n }", "void mo88521a();", "void mo20141a();", "public static void main(String[] args) {\n \n \n \n \n }", "public final void mo51373a() {\n }", "private final boolean shouldProposeGenerics(IJavaProject project) {\n\t\treturn true;\n\t\t/*\n\t\tString sourceVersion;\n\t\tif (project != null)\n\t\t\tsourceVersion= project.getOption(JavaCore.COMPILER_SOURCE, true);\n\t\telse\n\t\t\tsourceVersion= JavaCore.getOption(JavaCore.COMPILER_SOURCE);\n\n\t\treturn sourceVersion != null && JavaCore.VERSION_1_5.compareTo(sourceVersion) <= 0;\n\t\t*/\n\t}", "public static void main(String[] args) {\n way8();\n }", "private JacobUtils() {}", "void mo60893b();", "public interface JavaCode {\n\n /**\n * Get an unique identification code for an object\n * TODO: This method is not reliable as hash codes are not unique, should use an UUID generator singleton instead.\n *\n * @param obj the object\n * @return the unique identification code\n */\n static int getUniqueID(Object obj) {\n return obj.hashCode();\n }\n\n /**\n * Compiles this code. If an object implements both {@link JavaCode}\n * and {@link JavaExpression}, only one of this method and\n * {@link JavaExpression#compileExpression(Subroutine, JavaScope)} should be called.\n *\n * @param subroutine the subroutine which this code belongs to\n * @param parent the parent scope of this code\n * @throws JTAException if an error occurs\n */\n void compileCode(Subroutine subroutine, JavaScope parent) throws JTAException;\n}", "public void mo8738a() {\n }", "public void mo1972o() throws cf {\r\n }", "public static void main (String[] args) {import java.util.*;%>\n//&&&staticSymbol&&&<%import org.eclipse.emf.codegen.ecore.genmodel.*;%>\n//&&&staticSymbol&&&<%\n\n/**\n * Copyright (c) 2002-2010 IBM Corporation and others.\n * All rights reserved. This program and the accompanying materials\n * are made available under the terms of the Eclipse Public License v1.0\n * which accompanies this distribution, and is available at\n * http://www.eclipse.org/legal/epl-v10.html\n *\n * Contributors:\n * IBM - Initial API and implementation\n */\n\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nGenPackage genPackage = (GenPackage)((Object[])argument)[0]; GenModel genModel=genPackage.getGenModel(); /* Trick to import java.util.* without warnings */Iterator.class.getName();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nboolean isInterface = Boolean.TRUE.equals(((Object[])argument)[1]); boolean isImplementation = Boolean.TRUE.equals(((Object[])argument)[2]);\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nString publicStaticFinalFlag = isImplementation ? \"public static final \" : \"\";\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%include(\"../Header.javajetinc\");%>\n//&&&staticSymbol&&&<%\nif (isInterface || genModel.isSuppressInterfaces()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&package <%\n//&&&staticSymbol&&&=genPackage.getReflectionPackageName()\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&<%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&package <%\n//&&&staticSymbol&&&=genPackage.getClassPackageName()\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\nif (isImplementation) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.addPseudoImport(\"org.eclipse.emf.ecore.impl.MinimalEObjectImpl.Container\");\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.addPseudoImport(\"org.eclipse.emf.ecore.impl.MinimalEObjectImpl.Container.Dynamic\");\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.addImport(\"org.eclipse.emf.ecore.EClass\");\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.addImport(\"org.eclipse.emf.ecore.EObject\");\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (!genPackage.hasJavaLangConflict() && !genPackage.hasInterfaceImplConflict() && !genPackage.getClassPackageName().equals(genPackage.getInterfacePackageName())) genModel.addImport(genPackage.getInterfacePackageName() + \".*\");\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.markImportLocation(stringBuffer);\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\nif (isInterface) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&/**\n//&&&staticSymbol&&& * <!-- begin-user-doc -->\n//&&&staticSymbol&&& * The <b>Factory</b> for the model.\n//&&&staticSymbol&&& * It provides a create method for each non-abstract class of the model.\n//&&&staticSymbol&&& * <!-- end-user-doc -->\n//&&&staticSymbol&&&<%\nif (!genModel.isSuppressEMFMetaData()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& * @see <%\n//&&&staticSymbol&&&=genPackage.getQualifiedPackageInterfaceName()\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& * @generated\n//&&&staticSymbol&&& */\n//&&&staticSymbol&&&<%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&/**\n//&&&staticSymbol&&& * <!-- begin-user-doc -->\n//&&&staticSymbol&&& * An implementation of the model <b>Factory</b>.\n//&&&staticSymbol&&& * <!-- end-user-doc -->\n//&&&staticSymbol&&& * @generated\n//&&&staticSymbol&&& */\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (isImplementation) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&public class <%\n//&&&staticSymbol&&&=genPackage.getFactoryClassName()\n//&&&staticSymbol&&&%> extends <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.impl.EFactoryImpl\")\n//&&&staticSymbol&&&%><%\nif (!genModel.isSuppressInterfaces()) {\n//&&&staticSymbol&&&%> implements <%\n//&&&staticSymbol&&&=genPackage.getImportedFactoryInterfaceName()\n//&&&staticSymbol&&&%><%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&public interface <%\n//&&&staticSymbol&&&=genPackage.getFactoryInterfaceName()\n//&&&staticSymbol&&&%><%\nif (!genModel.isSuppressEMFMetaData()) {\n//&&&staticSymbol&&&%> extends <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EFactory\")\n//&&&staticSymbol&&&%><%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&{\n//&&&staticSymbol&&&<%\nif (genModel.hasCopyrightField()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=publicStaticFinalFlag\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.String\")\n//&&&staticSymbol&&&%> copyright = <%\n//&&&staticSymbol&&&=genModel.getCopyrightFieldLiteral()\n//&&&staticSymbol&&&%>;<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (isImplementation && (genModel.isSuppressEMFMetaData() || genModel.isSuppressInterfaces())) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * The singleton instance of the factory.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=publicStaticFinalFlag\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genPackage.getFactoryClassName()\n//&&&staticSymbol&&&%> eINSTANCE = init();\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (isInterface && genModel.isSuppressEMFMetaData()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * The singleton instance of the factory.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=publicStaticFinalFlag\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genPackage.getFactoryInterfaceName()\n//&&&staticSymbol&&&%> INSTANCE = <%\n//&&&staticSymbol&&&=genPackage.getQualifiedFactoryClassName()\n//&&&staticSymbol&&&%>.eINSTANCE;\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n} else if (isInterface && !genModel.isSuppressInterfaces()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * The singleton instance of the factory.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=publicStaticFinalFlag\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genPackage.getFactoryInterfaceName()\n//&&&staticSymbol&&&%> eINSTANCE = <%\n//&&&staticSymbol&&&=genPackage.getQualifiedFactoryClassName()\n//&&&staticSymbol&&&%>.init();\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (isImplementation) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Creates the default factory implementation.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&<%\nString factoryType = genModel.isSuppressEMFMetaData() ? genPackage.getFactoryClassName() : genPackage.getImportedFactoryInterfaceName();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic static <%\n//&&&staticSymbol&&&=factoryType\n//&&&staticSymbol&&&%> init()\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\ttry\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\t<%\n//&&&staticSymbol&&&=factoryType\n//&&&staticSymbol&&&%> the<%\n//&&&staticSymbol&&&=genPackage.getFactoryName()\n//&&&staticSymbol&&&%> = (<%\n//&&&staticSymbol&&&=factoryType\n//&&&staticSymbol&&&%>)<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EPackage\")\n//&&&staticSymbol&&&%>.Registry.INSTANCE.getEFactory(<%\n//&&&staticSymbol&&&=genPackage.getPackageInterfaceName()\n//&&&staticSymbol&&&%>.eNS_URI);\n//&&&staticSymbol&&&\t\t\tif (the<%\n//&&&staticSymbol&&&=genPackage.getFactoryName()\n//&&&staticSymbol&&&%> != null)\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&&\t\t\t\treturn the<%\n//&&&staticSymbol&&&=genPackage.getFactoryName()\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\tcatch (Exception exception)\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\t<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.plugin.EcorePlugin\")\n//&&&staticSymbol&&&%>.INSTANCE.log(exception);\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\treturn new <%\n//&&&staticSymbol&&&=genPackage.getImportedFactoryClassName()\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Creates an instance of the factory.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\tpublic <%\n//&&&staticSymbol&&&=genPackage.getFactoryClassName()\n//&&&staticSymbol&&&%>()\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\tsuper();\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useClassOverrideAnnotation()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@Override\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic EObject create(EClass eClass)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\tswitch (eClass.getClassifierID())\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&<%\nfor (GenClass genClass : genPackage.getGenClasses()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (!genClass.isAbstract()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tcase <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%>.<%\n//&&&staticSymbol&&&=genClass.getClassifierID()\n//&&&staticSymbol&&&%>: return <%\n//&&&staticSymbol&&&*%%storeSymbol%%*0\n//&&&staticSymbol&&&%>create<%\n//&&&staticSymbol&&&=genClass.getName()\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tdefault:\n//&&&staticSymbol&&&\t\t\t\tthrow new IllegalArgumentException(\"The class '\" + eClass.getName() + \"' is not a valid classifier\");<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(2)\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\nif (!genPackage.getAllGenDataTypes().isEmpty()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useClassOverrideAnnotation()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@Override\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic Object createFromString(<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EDataType\")\n//&&&staticSymbol&&&%> eDataType, String initialValue)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\tswitch (eDataType.getClassifierID())\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&<%\nfor (GenDataType genDataType : genPackage.getAllGenDataTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isSerializable()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tcase <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%>.<%\n//&&&staticSymbol&&&=genDataType.getClassifierID()\n//&&&staticSymbol&&&%>:\n//&&&staticSymbol&&&\t\t\t\treturn create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>FromString(eDataType, initialValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tdefault:\n//&&&staticSymbol&&&\t\t\t\tthrow new IllegalArgumentException(\"The datatype '\" + eDataType.getName() + \"' is not a valid classifier\");<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(2)\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useClassOverrideAnnotation()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@Override\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic String convertToString(<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EDataType\")\n//&&&staticSymbol&&&%> eDataType, Object instanceValue)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\tswitch (eDataType.getClassifierID())\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&<%\nfor (GenDataType genDataType : genPackage.getAllGenDataTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isSerializable()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tcase <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%>.<%\n//&&&staticSymbol&&&=genDataType.getClassifierID()\n//&&&staticSymbol&&&%>:\n//&&&staticSymbol&&&\t\t\t\treturn convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>ToString(eDataType, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tdefault:\n//&&&staticSymbol&&&\t\t\t\tthrow new IllegalArgumentException(\"The datatype '\" + eDataType.getName() + \"' is not a valid classifier\");<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(2)\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nfor (GenClass genClass : genPackage.getGenClasses()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (!genClass.isAbstract()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\tpublic <%\n//&&&staticSymbol&&&=genClass.getTypeParameters()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getImportedInterfaceName()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getInterfaceTypeArguments()\n//&&&staticSymbol&&&%> create<%\n//&&&staticSymbol&&&=genClass.getName()\n//&&&staticSymbol&&&%>()\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&& <%\nif (genClass.isDynamic()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genClass.getImportedInterfaceName()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getInterfaceTypeArguments()\n//&&&staticSymbol&&&%> <%\n//&&&staticSymbol&&&=genClass.getSafeUncapName()\n//&&&staticSymbol&&&%> = <%\n//&&&staticSymbol&&&=genClass.getCastFromEObject()\n//&&&staticSymbol&&&%>super.create(<%\n//&&&staticSymbol&&&=genClass.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genClass.getImportedClassName()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getClassTypeArguments()\n//&&&staticSymbol&&&%> <%\n//&&&staticSymbol&&&=genClass.getSafeUncapName()\n//&&&staticSymbol&&&%> = new <%\n//&&&staticSymbol&&&=genClass.getImportedClassName()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getClassTypeArguments()\n//&&&staticSymbol&&&%>()<%\nif (genModel.isSuppressInterfaces() && !genPackage.getReflectionPackageName().equals(genPackage.getInterfacePackageName())) {\n//&&&staticSymbol&&&%>{}<%\n}\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genClass.getSafeUncapName()\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nfor (GenDataType genDataType : genPackage.getAllGenDataTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isSerializable()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (genPackage.isDataTypeConverters() || genDataType.hasCreatorBody()) { String eDataType = genDataType.getQualifiedClassifierAccessor();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useGenerics() && genDataType.isUncheckedCast() && !genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@SuppressWarnings(\"unchecked\")\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic <%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedInstanceClassName()\n//&&&staticSymbol&&&%> create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(<%\nif (genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>final <%\n}\n//&&&staticSymbol&&&%>String <%\nif (genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>it<%\n} else {\n//&&&staticSymbol&&&%>literal<%\n}\n//&&&staticSymbol&&&%>)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&& <%\nif (genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getCreatorBody(genModel.getIndentation(stringBuffer))\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType instanceof GenEnum) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getImportedInstanceClassName()\n//&&&staticSymbol&&&%> result = <%\n//&&&staticSymbol&&&=genDataType.getImportedInstanceClassName()\n//&&&staticSymbol&&&%>.get(literal);\n//&&&staticSymbol&&&\t\tif (result == null) throw new IllegalArgumentException(\"The value '\" + literal + \"' is not a valid enumerator of '\" + <%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>.getName() + \"'\");<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(2)\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(3)\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn result;\n//&&&staticSymbol&&& <%\n} else if (genDataType.getBaseType() != null) { GenDataType genBaseType = genDataType.getBaseType(); boolean isPrimitiveConversion = !genDataType.isPrimitiveType() && genBaseType.isPrimitiveType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genBaseType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (isPrimitiveConversion && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn new <%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(create<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(literal));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn create<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genBaseType.getGenPackage().isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (isPrimitiveConversion && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn new <%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.create<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(literal));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.create<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getItemType() != null) { GenDataType genItemType = genDataType.getItemType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (literal == null) return null;\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedInstanceClassName()\n//&&&staticSymbol&&&%> result = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.ArrayList\")\n//&&&staticSymbol&&&%><%\nif (genModel.useGenerics()) {\n//&&&staticSymbol&&&%><<%=genItemType.getObjectType().getImportedParameterizedInstanceClassName()%>><%\n}\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\nif (genModel.getRuntimeVersion().getValue() < GenRuntimeVersion.EMF26_VALUE) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.StringTokenizer\")\n//&&&staticSymbol&&&%> stringTokenizer = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.StringTokenizer\")\n//&&&staticSymbol&&&%>(literal); stringTokenizer.hasMoreTokens(); )\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (String item : split(literal))\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genModel.getRuntimeVersion().getValue() < GenRuntimeVersion.EMF26_VALUE) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString item = stringTokenizer.nextToken();\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) { genItemType = genItemType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(create<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>(item));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(create<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, item));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage().isDataTypeConverters()) { genItemType = genItemType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(<%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.create<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>(item));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(<%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, item));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\treturn result;\n//&&&staticSymbol&&& <%\n} else if (!genDataType.getMemberTypes().isEmpty()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (literal == null) return <%\n//&&&staticSymbol&&&=genDataType.getStaticValue(null)\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getImportedInstanceClassName()\n//&&&staticSymbol&&&%> result = <%\n//&&&staticSymbol&&&=genDataType.getStaticValue(null)\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&\t\tRuntimeException exception = null;\n//&&&staticSymbol&&& <%\nfor (GenDataType genMemberType : genDataType.getMemberTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\ttry\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) { if (!genDataType.isPrimitiveType()) genMemberType = genMemberType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = create<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(literal);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = (<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)create<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) { if (!genDataType.isPrimitiveType()) genMemberType = genMemberType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.create<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(literal);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = (<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tif (<%\nif (!genDataType.isPrimitiveType()) {\n//&&&staticSymbol&&&%>result != null && <%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.util.Diagnostician\")\n//&&&staticSymbol&&&%>.INSTANCE.validate(<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>, <%\nif (genDataType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>new <%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(result)<%\n} else {\n//&&&staticSymbol&&&%>result<%\n}\n//&&&staticSymbol&&&%>, null, null))\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&&\t\t\t\treturn result;\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\tcatch (RuntimeException e)\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\texception = e;\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (<%\nif (!genDataType.isPrimitiveType()) {\n//&&&staticSymbol&&&%>result != null || <%\n}\n//&&&staticSymbol&&&%>exception == null) return result;\n//&&&staticSymbol&&& \n//&&&staticSymbol&&&\t\tthrow exception;\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genModel.useGenerics() && (genDataType.isArrayType() || !genDataType.getEcoreDataType().getETypeParameters().isEmpty() || genDataType.getEcoreDataType().getInstanceTypeName().contains(\"<\"))) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn (<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%>)super.createFromString(literal);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genDataType.isArrayType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t// TODO: implement this method\n//&&&staticSymbol&&&\t\t// Ensure that you remove @generated or mark it @generated NOT\n//&&&staticSymbol&&&\t\tthrow new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.UnsupportedOperationException\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\n} else if (genDataType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn ((<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)super.createFromString(<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>, literal)).<%\n//&&&staticSymbol&&&=genDataType.getPrimitiveValueFunction()\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%>super.createFromString(<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>, literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (!genPackage.isDataTypeConverters() && genModel.useGenerics() && genDataType.isUncheckedCast() && !genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@SuppressWarnings(\"unchecked\")\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic <%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%> create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EDataType\")\n//&&&staticSymbol&&&%> eDataType, String initialValue)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&& <%\nif (genDataType instanceof GenEnum) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters() || genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(initialValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=((GenEnum)genDataType).getImportedInstanceClassName()\n//&&&staticSymbol&&&%> result = <%\n//&&&staticSymbol&&&=((GenEnum)genDataType).getImportedInstanceClassName()\n//&&&staticSymbol&&&%>.get(initialValue);\n//&&&staticSymbol&&&\t\tif (result == null) throw new IllegalArgumentException(\"The value '\" + initialValue + \"' is not a valid enumerator of '\" + eDataType.getName() + \"'\");<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(2)\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(3)\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn result;\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getBaseType() != null) { GenDataType genBaseType = genDataType.getBaseType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genBaseType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.getObjectInstanceClassName().equals(genBaseType.getObjectInstanceClassName())) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%>create<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, initialValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, initialValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getItemType() != null) { GenDataType genItemType = genDataType.getItemType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(initialValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (initialValue == null) return null;\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%> result = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.ArrayList\")\n//&&&staticSymbol&&&%><%\nif (genModel.useGenerics()) {\n//&&&staticSymbol&&&%><<%=genItemType.getObjectType().getImportedParameterizedInstanceClassName()%>><%\n}\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\nif (genModel.getRuntimeVersion().getValue() < GenRuntimeVersion.EMF26_VALUE) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.StringTokenizer\")\n//&&&staticSymbol&&&%> stringTokenizer = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.StringTokenizer\")\n//&&&staticSymbol&&&%>(initialValue); stringTokenizer.hasMoreTokens(); )\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (String item : split(initialValue))\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genModel.getRuntimeVersion().getValue() < GenRuntimeVersion.EMF26_VALUE) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString item = stringTokenizer.nextToken();\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(create<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, item));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(<%\nif (!genItemType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genItemType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, item));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\treturn result;\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (!genDataType.getMemberTypes().isEmpty()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn new <%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(initialValue));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(initialValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (initialValue == null) return null;\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%> result = null;\n//&&&staticSymbol&&&\t\tRuntimeException exception = null;\n//&&&staticSymbol&&& <%\nfor (GenDataType genMemberType : genDataType.getMemberTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\ttry\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = <%\nif (!genDataType.isObjectType() && !genDataType.getObjectInstanceClassName().equals(genMemberType.getObjectInstanceClassName())) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%>create<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, initialValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, initialValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tif (result != null && <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.util.Diagnostician\")\n//&&&staticSymbol&&&%>.INSTANCE.validate(eDataType, result, null, null))\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&&\t\t\t\treturn result;\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\tcatch (RuntimeException e)\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\texception = e;\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (result != null || exception == null) return result;\n//&&&staticSymbol&&& \n//&&&staticSymbol&&&\t\tthrow exception;\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genPackage.isDataTypeConverters() || genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(initialValue);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genModel.useGenerics() && (genDataType.isArrayType() || !genDataType.getEcoreDataType().getETypeParameters().isEmpty() || genDataType.getEcoreDataType().getInstanceTypeName().contains(\"<\"))) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%>super.createFromString(initialValue);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genDataType.isArrayType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t// TODO: implement this method\n//&&&staticSymbol&&&\t\t// Ensure that you remove @generated or mark it @generated NOT\n//&&&staticSymbol&&&\t\tthrow new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.UnsupportedOperationException\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%>super.createFromString(eDataType, initialValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\nif (genPackage.isDataTypeConverters() || genDataType.hasConverterBody()) { String eDataType = genDataType.getQualifiedClassifierAccessor();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\tpublic String convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(<%\nif (genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>final <%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genDataType.getImportedBoundedWildcardInstanceClassName()\n//&&&staticSymbol&&&%> <%\nif (genDataType.hasConverterBody()) {\n//&&&staticSymbol&&&%>it<%\n} else {\n//&&&staticSymbol&&&%>instanceValue<%\n}\n//&&&staticSymbol&&&%>)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&& <%\nif (genDataType.hasConverterBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getConverterBody(genModel.getIndentation(stringBuffer))\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType instanceof GenEnum) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn instanceValue == null ? null : instanceValue.toString();\n//&&&staticSymbol&&& <%\n} else if (genDataType.getBaseType() != null) { GenDataType genBaseType = genDataType.getBaseType(); boolean isPrimitiveConversion = !genDataType.isPrimitiveType() && genBaseType.isPrimitiveType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genBaseType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (isPrimitiveConversion) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn instanceValue == null ? null : convert<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(instanceValue<%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>.<%\n//&&&staticSymbol&&&=genBaseType.getPrimitiveValueFunction()\n//&&&staticSymbol&&&%>()<%\n}\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genBaseType.getGenPackage().isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedFactoryInstanceAccessor()\n//&&&staticSymbol&&&%>.convert<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getItemType() != null) { GenDataType genItemType = genDataType.getItemType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (instanceValue == null) return null;\n//&&&staticSymbol&&&\t\tif (instanceValue.isEmpty()) return \"\";\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.StringBuffer\")\n//&&&staticSymbol&&&%> result = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.StringBuffer\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\nString item; if (!genModel.useGenerics()) { item = \"i.next()\"; \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.Iterator\")\n//&&&staticSymbol&&&%> i = instanceValue.iterator(); i.hasNext(); )\n//&&&staticSymbol&&& <%\n} else { item = \"item\";\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.Object\")\n//&&&staticSymbol&&&%> item : instanceValue)\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) { genItemType = genItemType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(convert<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genItemType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(convert<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage().isDataTypeConverters()) { genItemType = genItemType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(<%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convert<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genItemType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(<%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(' ');\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\treturn result.substring(0, result.length() - 1);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.getMemberTypes().isEmpty()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (!genDataType.isPrimitiveType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (instanceValue == null) return null;\n//&&&staticSymbol&&& <%\nfor (GenDataType genMemberType : genDataType.getMemberTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>.isInstance(instanceValue))\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\ttry\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genMemberType.getQualifiedInstanceClassName().equals(genDataType.getQualifiedInstanceClassName())) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n} else if (genMemberType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(((<%\n//&&&staticSymbol&&&=genMemberType.getObjectType().getImportedInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue).<%\n//&&&staticSymbol&&&=genMemberType.getPrimitiveValueFunction()\n//&&&staticSymbol&&&%>());\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genMemberType.getObjectType().getImportedBoundedWildcardInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage().isDataTypeConverters()) { genMemberType = genMemberType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genMemberType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tif (value != null) return value;\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t\tcatch (Exception e)\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&&\t\t\t\t// Keep trying other member types until all have failed.\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nfor (GenDataType genMemberType : genDataType.getMemberTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\ttry\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>new <%\n//&&&staticSymbol&&&=genMemberType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(instanceValue)<%\n} else {\n//&&&staticSymbol&&&%>instanceValue<%\n}\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage().isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString value = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString value = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>new <%\n//&&&staticSymbol&&&=genMemberType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(instanceValue)<%\n} else {\n//&&&staticSymbol&&&%>instanceValue<%\n}\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tif (value != null) return value;\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\tcatch (Exception e)\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\t// Keep trying other member types until all have failed.\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tthrow new IllegalArgumentException(\"Invalid value: '\"+instanceValue+\"' for datatype :\"+<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>.getName());\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genModel.useGenerics() && (genDataType.isArrayType() || !genDataType.getEcoreDataType().getETypeParameters().isEmpty() || genDataType.getEcoreDataType().getInstanceTypeName().contains(\"<\"))) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn super.convertToString(instanceValue);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genDataType.isArrayType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t// TODO: implement this method\n//&&&staticSymbol&&&\t\t// Ensure that you remove @generated or mark it @generated NOT\n//&&&staticSymbol&&&\t\tthrow new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.UnsupportedOperationException\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\n} else if (genDataType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn super.convertToString(<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>, new <%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(instanceValue));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn super.convertToString(<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useGenerics() && (genDataType.getItemType() != null || genDataType.isUncheckedCast()) && (genPackage.isDataTypeConverters() || genDataType.hasCreatorBody())) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@SuppressWarnings(\"unchecked\")\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic String convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EDataType\")\n//&&&staticSymbol&&&%> eDataType, Object instanceValue)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&& <%\nif (genDataType instanceof GenEnum) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters() || genDataType.hasConverterBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genDataType.getImportedInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn instanceValue == null ? null : instanceValue.toString();\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getBaseType() != null) { GenDataType genBaseType = genDataType.getBaseType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genBaseType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getItemType() != null) { GenDataType genItemType = genDataType.getItemType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters() || genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genDataType.getImportedBoundedWildcardInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue);\n//&&&staticSymbol&&& <%\n} else { final String singleWildcard = genModel.useGenerics() ? \"<?>\" : \"\";\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (instanceValue == null) return null;\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.List\")\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=singleWildcard\n//&&&staticSymbol&&&%> list = (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.List\")\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=singleWildcard\n//&&&staticSymbol&&&%>)instanceValue;\n//&&&staticSymbol&&&\t\tif (list.isEmpty()) return \"\";\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.StringBuffer\")\n//&&&staticSymbol&&&%> result = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.StringBuffer\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\nString item; if (!genModel.useGenerics()) { item = \"i.next()\"; \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.Iterator\")\n//&&&staticSymbol&&&%> i = list.iterator(); i.hasNext(); )\n//&&&staticSymbol&&& <%\n} else { item = \"item\";\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.Object\")\n//&&&staticSymbol&&&%> item : list)\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(convert<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(<%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(' ');\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\treturn result.substring(0, result.length() - 1);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (!genDataType.getMemberTypes().isEmpty()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters() || genDataType.hasConverterBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isPrimitiveType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn instanceValue == null ? null : convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(((<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue)<%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>.<%\n//&&&staticSymbol&&&=genDataType.getPrimitiveValueFunction()\n//&&&staticSymbol&&&%>()<%\n}\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (instanceValue == null) return null;\n//&&&staticSymbol&&& <%\nfor (GenDataType genMemberType : genDataType.getMemberTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>.isInstance(instanceValue))\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\ttry\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tif (value != null) return value;\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t\tcatch (Exception e)\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&&\t\t\t\t// Keep trying other member types until all have failed.\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tthrow new IllegalArgumentException(\"Invalid value: '\"+instanceValue+\"' for datatype :\"+eDataType.getName());\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genPackage.isDataTypeConverters() || genDataType.hasConverterBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isPrimitiveType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn instanceValue == null ? null : convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(<%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>(<%\n}\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue<%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>).<%\n//&&&staticSymbol&&&=genDataType.getPrimitiveValueFunction()\n//&&&staticSymbol&&&%>()<%\n}\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genDataType.getImportedBoundedWildcardInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genModel.useGenerics() && (genDataType.isArrayType() || !genDataType.getEcoreDataType().getETypeParameters().isEmpty() || genDataType.getEcoreDataType().getInstanceTypeName().contains(\"<\"))) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn super.convertToString(instanceValue);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genDataType.isArrayType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t// TODO: implement this method\n//&&&staticSymbol&&&\t\t// Ensure that you remove @generated or mark it @generated NOT\n//&&&staticSymbol&&&\t\tthrow new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.UnsupportedOperationException\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn super.convertToString(eDataType, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nfor (GenClass genClass : genPackage.getGenClasses()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genClass.hasFactoryInterfaceCreateMethod()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Returns a new object of class '<em><%\n//&&&staticSymbol&&&=genClass.getFormattedName()\n//&&&staticSymbol&&&%></em>'.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @return a new object of class '<em><%\n//&&&staticSymbol&&&=genClass.getFormattedName()\n//&&&staticSymbol&&&%></em>'.\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=genClass.getTypeParameters()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getImportedInterfaceName()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getInterfaceTypeArguments()\n//&&&staticSymbol&&&%> create<%\n//&&&staticSymbol&&&=genClass.getName()\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&&\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nfor (GenDataType genDataType : genPackage.getAllGenDataTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isSerializable()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Returns an instance of data type '<em><%\n//&&&staticSymbol&&&=genDataType.getFormattedName()\n//&&&staticSymbol&&&%></em>' corresponding the given literal.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @param literal a literal of the data type.\n//&&&staticSymbol&&&\t * @return a new instance value of the data type.\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedInstanceClassName()\n//&&&staticSymbol&&&%> create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(String literal);\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Returns a literal representation of an instance of data type '<em><%\n//&&&staticSymbol&&&=genDataType.getFormattedName()\n//&&&staticSymbol&&&%></em>'.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @param instanceValue an instance value of the data type.\n//&&&staticSymbol&&&\t * @return a literal representation of the instance value.\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\tString convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getImportedBoundedWildcardInstanceClassName()\n//&&&staticSymbol&&&%> instanceValue);\n//&&&staticSymbol&&&\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (!isImplementation && !genModel.isSuppressEMFMetaData()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Returns the package supported by this factory.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @return the package supported by this factory.\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=genPackage.getPackageInterfaceName()\n//&&&staticSymbol&&&%> get<%\n//&&&staticSymbol&&&=genPackage.getBasicPackageName()\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n} else if (isImplementation) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\tpublic <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%> get<%\n//&&&staticSymbol&&&=genPackage.getBasicPackageName()\n//&&&staticSymbol&&&%>()\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\treturn (<%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%>)getEPackage();\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @deprecated\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useClassOverrideAnnotation()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@Deprecated\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic static <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%> getPackage()\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%>.eINSTANCE;\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&} //<%\n//&&&staticSymbol&&&*%%storeSymbol%%*1\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.emitSortedImports();\n//&&&staticSymbol&&&%>\n\n}", "static void feladat9() {\n\t}", "@Override\n public boolean isVersionCodeCompatible(int version) {\n return true;\n }", "public void mo4359a() {\n }", "private static List<String> getJavasSourceCodeFiels(Map<String,Object> map){\r\n \t\t\r\n \t\t\r\n \t\tSystem.out.println(\"............\");\r\n \t\tLinkedList<String> list = new LinkedList<String>();\r\n \t\tfor(String key : map.keySet()){\r\n \t\t\tObject o = map.get(key);\r\n \r\n \t\t\t//package...\r\n \t\t\tif(o instanceof IPackageFragment){\r\n \t\t\t\t//System.out.println(\"Package --> \" + key);\r\n \t\t\t\tkey = key.substring(0,key.indexOf('[')).trim();\r\n \t\t\t\tkey = PACKAGE + \"(\" + key + \")\";\r\n \t\t\t\tlist.add(key);\r\n \t\t\t}\r\n \t\t\t//class...\r\n \t\t\tif(o instanceof ICompilationUnit){\r\n \t\t\t\t//System.out.println(\"Class --> \" + key);\r\n \t\t\t\tString classname = key.substring(0,key.indexOf('[')).trim();\r\n \t\t\t\tString packagename = key.substring(key.indexOf(PACKAGE),key.indexOf('\\n',key.indexOf(PACKAGE)));\r\n \t\t\t\tkey = CLASS_WITH_MEMBERS + \"(\" + packagename + \",\" + classname + \")\";\r\n \t\t\t\tlist.add(key);\r\n \t\t\t}//method\r\n \t\t\tif(o instanceof IMethod){\r\n \t\t\t\tSystem.out.println(\"Methode --> \" + key);\r\n \t\t\t\tkey = METHOD + \"(\" + getQueryFromMethod((IMethod)o) + \")\";\r\n \t\t\t\tlist.add(key);\r\n \t\t\t}\r\n \t\t\t\r\n \t\t\tif(o instanceof IField){\r\n \t\t\t\tSystem.out.println(\"Attribut --> \" + key);\r\n \t\t\t\tkey = FIELD + \"(\" + getQueryFromField((IField)o) + \")\";\r\n \t\t\t\tlist.add(key);\r\n \t\t\t}\r\n \t\t}\r\n \t\treturn list;\r\n \t\t\r\n \t\t\r\n \t\t/*\r\n \t\tfor(String key : map.keySet()){\r\n \t\t\tObject o = map.get(key);\r\n \t\t\t//if(o instanceof ISourceAttribute)\r\n \t\t\t\t//System.out.println(\"attribute\");\r\n \t\t\t//if(o instanceof ISourceMethod)\r\n \t\t\t\t//System.out.println(\"methode\");\r\n \t\t\tif(o instanceof IPackageFragment) \r\n \t\t\t\tSystem.out.println(\"Package\");\r\n \t\t\tif(o instanceof ICompilationUnit)\r\n \t\t\t\tSystem.out.println(\"sour code file\");\r\n \t\t\t\t\r\n \t\t\t//\"oldquery or class('voller packagename', klassenname)\"\r\n \t\t\t\t\r\n \t\t\t\t\r\n \t\t\tif(o instanceof IField)\r\n \t\t\t\tSystem.out.println(\"Attribut\");\r\n \t\t\tif(o instanceof IType)\r\n \t\t\t\tSystem.out.println(\"classe also class ... in einem file\");\r\n \t\t\tif(o instanceof IMethod)\r\n \t\t\t\tSystem.out.println(\"Methode\");\r\n \t\t\tif(o instanceof IPackageFragmentRoot) \r\n \t\t\t\tSystem.out.println(\"jar package / src Ordner\");\r\n \t\t\tif(o instanceof IProject)\r\n \t\t\t\tSystem.out.println(\"Projekt Ordner\");\r\n \t\t\tif(o instanceof IClassFile)\r\n \t\t\t\tSystem.out.println(\"ClassFile\");\r\n \t\t\tif(o instanceof IAdaptable) //trieft auch auf viele ander sachen zu\r\n \t\t\t\tSystem.out.println(\"Libaraycontainer\");\r\n \t\t\tif(o instanceof IFile)\r\n \t\t\t\tSystem.out.println(\"file\"); //je nach ausgewlter ansicht knnen file auch *.java datein sein\r\n \t\t\tif(o instanceof IFolder)\r\n \t\t\t\tSystem.out.println(\"folder\");\r\n \t\t\tSystem.out.println(o.getClass());\r\n \t\t\t\r\n \t\r\n \t\t}\r\n \t\treturn null;\r\n \t\t*/\r\n \t}", "public void mo1531a() {\n }", "public void mo1976s() throws cf {\r\n }", "void mo119581a();", "static void feladat6() {\n\t}", "private void generateSolution() {\n\t\t// TODO\n\n\t}" ]
[ "0.5890391", "0.58054996", "0.57008785", "0.56167847", "0.54946315", "0.54761344", "0.524263", "0.52340496", "0.5233149", "0.52029705", "0.5160466", "0.51574665", "0.5143396", "0.5094738", "0.5084682", "0.5069909", "0.50661004", "0.50645214", "0.5064437", "0.50475377", "0.5041245", "0.5039573", "0.5037435", "0.50317824", "0.5007829", "0.500209", "0.49986184", "0.4996393", "0.49733046", "0.49654463", "0.49482828", "0.49374196", "0.49367213", "0.49362347", "0.4931423", "0.49300268", "0.49164099", "0.49096605", "0.4893169", "0.48904118", "0.4883474", "0.4883474", "0.4883474", "0.4883474", "0.4883474", "0.4883474", "0.4869394", "0.48675945", "0.4863796", "0.4849808", "0.48444158", "0.48439786", "0.48421556", "0.4838581", "0.48383453", "0.4837389", "0.4833218", "0.48310906", "0.4830076", "0.4827487", "0.481306", "0.48097232", "0.4807137", "0.48028547", "0.4801506", "0.47964317", "0.47952133", "0.479351", "0.4792214", "0.4791279", "0.47875714", "0.47851777", "0.47851777", "0.47834784", "0.47784257", "0.47747812", "0.47722042", "0.47722042", "0.47719148", "0.47705945", "0.47705132", "0.47681588", "0.47653475", "0.47629744", "0.47611335", "0.47570732", "0.47566834", "0.47548115", "0.4751401", "0.47484854", "0.47464594", "0.47460574", "0.47457317", "0.4742769", "0.47399607", "0.47344413", "0.47313395", "0.47252822", "0.47233605", "0.4721698", "0.47122636" ]
0.0
-1
write your code in Java SE 8
public static int borderSolution(int[] A) { int bordersNum = 0; for (int i = 0; i < A.length - 1; i++) { if (bordersNum > 10000000) return -1; for (int j = i + 1; j < A.length; j++) { int min1 = i - A[i]; int max1 = i + A[i]; int max2 = j + A[j]; int min2 = j - A[j]; if (!(min2 > max1)) { if (min1 >= min2 || max1 <= max2) { bordersNum++; continue; } } if (!(min2 > max1)) { if (min2 >= min1 || max2 <= max1) { bordersNum++; continue; } } } } return bordersNum; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static void main(String[] args) {\n\t\tnew Action() {\r\n\r\n\t\t\t@Override\r\n\t\t\tpublic void execute(String content) {\r\n\t\t\t\t// TODO Auto-generated method stub\r\n\t\t\t\tSystem.out.println(content);\r\n\t\t\t}\r\n\t\t\t\r\n\t\t}.execute(\"jdk1.8之前匿名内部类实现方式\");\r\n\t\t\r\n\t\t\r\n\t\t//lambda\r\n\t\tAction login=(String content)->{\r\n\t\t\tSystem.out.println(\"jdk1.8的lambda语法实现\");\r\n\t\t};\r\n\t\tlogin.execute(\"jdk1.8的lambda语法实现\");\r\n\t\t\r\n\t}", "public static void main(String[] args) {\n\t\t\r\n\t\tnew Thread(new Runnable() {\r\n\t\t\tpublic void run() {\r\n\t\t\t\tSystem.out.println(\"Before JAVA 8, too much code for too little to do\");\r\n\t\t\t}\r\n\t\t}).start();\r\n\t\t\r\n\t\t// Java 8 way:\r\n\t\t\r\n\t\tnew Thread( () -> System.out.println(\"In Java 8, Lambda Expression rocks !!\") ).start();\r\n\t\t\r\n\t\tSystem.out.println(\"-----------*************************-------------\");\r\n\t\t\r\n\t\t// Iterating Over List Using Lambda Expressions\r\n\t\t\r\n\t\tList features = Arrays.asList(\"Lambdas\",\"Default Method\",\"Stream API\",\"DAte and Time API\");\r\n\t\t\r\n\t\tfeatures.forEach(n -> System.out.println(n));\r\n\r\n\t\tSystem.out.println(\"-----------*************************-------------\");\r\n\t\t\t\t\r\n\t\t// Even better use method reference feature of Java 8\r\n\t\t// method reference is denoted by :: ****double colon***** operator\r\n\t\t// looks similar to scope resolution operator of C++\r\n\t\t\r\n\t\tfeatures.forEach(System.out::println);\r\n\r\n\t}", "public static void main(String[] args) {\r\n\t\tSomeJava8Features obj = new SomeJava8Features();\r\n\r\n\t\t// StringJoiner\r\n\t\texampleStringJoiner();\r\n\t\t\r\n\t\t// Default\r\n\t\tint ary[] = {3,6,8,9,0};\r\n\t\tSystem.out.println(\"\\nsumOfGivenIntArray ... \" + obj.sumOfGivenIntArray(ary));\r\n\t\tobj.sayMore(\"Hello Rohini\");\r\n\t\t\r\n\t\t// ForEach & Lambda Expression\r\n\t\texampleForEach_FindMaximum(ary);\r\n\t\t\r\n\r\n\t}", "@Deprecated\n\tprivate void oldCode()\n\t{\n\t}", "@Override\r\n\tprotected void doF8() {\n\t\t\r\n\t}", "private void level7() {\n }", "Compatibility compatibility();", "@SuppressWarnings(\"unused\")\n\tprivate void version() {\n\n\t}", "public static void main(String[] args) {\n throw new NotImplementedException();\n }", "public static void main(String[] args) {\n Foo foo = new Java8Default();\n foo.sumDefault(2,4);\n\n }", "@Test\n public void source8() throws Exception {\n ImmutableList<String> options = (GeneratedAnnotationsTest.isJdk9OrLater()) ? ImmutableList.of(\"--release\", \"8\") : ImmutableList.of(\"-source\", \"8\", \"-target\", \"8\");\n String generated = runProcessor(options, null);\n assertThat(generated).contains(GeneratedAnnotationsTest.JAVAX_ANNOTATION_GENERATED);\n assertThat(generated).doesNotContain(GeneratedAnnotationsTest.JAVAX_ANNOTATION_PROCESSING_GENERATED);\n }", "void compileToJava();", "public static void main(String args[]) throws Exception\n {\n \n \n \n }", "public final void mo8775b() {\n }", "public static void main(String[] args) {\n\t\t//Até o java 7\n\t\tnew Thread(new Runnable() {\n\n\t\t @Override\n\t\t public void run() {\n\t\t System.out.println(\"Executando um Runnable\");\n\t\t }\n\n\t\t}).start();\n\t\t//A partir do java 8\n\t\tnew Thread(() -> System.out.println(\"Executando um Runnable\")).start();\n\t\t\n\t\t//iterando com java 8: classe anonima\n\t\ttexto.forEach(new Consumer<String>() {\n\t\t public void accept(String s) {\n\t\t System.out.println(s);\n\t\t }\n\t\t});\n\t\t//iterando com java 8: lambda\n\t\t//Essa sintaxe funciona para qualquer interface \n\t\t//que tenha apenas um método abstrato\n\t\ttexto.forEach((String s) -> {\n\t\t System.out.println(s);\n\t\t});\n\t\t//ou\n\t\ttexto.forEach((s) -> {\n\t\t System.out.println(s);\n\t\t});\n\t\t//ou\n\t\ttexto.forEach(s -> {\n\t\t System.out.println(s);\n\t\t});\n\t\t//ou\n\t\ttexto.forEach(s -> System.out.println(s));\n\t\t// Uma interface que possui apenas um método abstrato \n\t\t//é agora conhecida como interface funcional e pode ser utilizada dessa forma\n\t\t\n\t\t//Outro exemplo é o próprio Comparator. Se utilizarmos a forma \n\t\t//de classe anônima, teremos essa situação: \n\t\ttexto.sort(new Comparator<String>() {\n\t\t public int compare(String s1, String s2) {\n\t\t if (s1.length() < s2.length())\n\t\t return -1;\n\t\t if (s1.length() > s2.length())\n\t\t return 1;\n\t\t return 0;\n\t\t }\n\t\t});\n\t\t//ou com lambda\n\t\ttexto.sort((s1, s2) -> {\n\t\t if (s1.length() < s2.length())\n\t\t return -1;\n\t\t if (s1.length() > s2.length())\n\t\t return 1;\n\t\t return 0;\n\t\t});\n\t\t//ou\n\t\ttexto.sort((s1, s2) -> {\n\t\t return Integer.compare(s1.length(), s2.length());\n\t\t});\n\t\t//ou como há apenas um único statement, podemos remover as chaves\n\t\ttexto.sort((s1, s2) -> Integer.compare(s1.length(), s2.length()));\n\t}", "public void mo38117a() {\n }", "void mo57277b();", "public static void main(String[] args) {\n version1WhileLoop();\n version1DoWhileLoop();\n version1ForLoop();\n version2ForLoop();\n version3ForLoop();\n }", "public abstract boolean mo2163j();", "public static void main(String[] args) throws Exception {\n\t\t\t\t\t\t\n\t\t\t\t\n\t\t\t}", "private NativeSupport() {\n\t}", "private static IRIProvider makeProviderJDK() { return new IRIProviderJDK(); }", "public void mo21785J() {\n }", "@Override\n public void func_104112_b() {\n \n }", "public static void generateCode()\n {\n \n }", "private UsingSwig() {\n\t}", "public static void main(String[] args) {\n\t\tlanceur8();\n\t}", "void mo1941j();", "public abstract void mo2624j();", "private final boolean updateState(java.lang.Object r7, java.lang.Object r8) {\n /*\n // Method dump skipped, instructions count: 101\n */\n throw new UnsupportedOperationException(\"Method not decompiled: kotlinx.coroutines.flow.StateFlowImpl.updateState(java.lang.Object, java.lang.Object):boolean\");\n }", "void mo72113b();", "static void feladat7() {\n\t}", "void mo28306a();", "private static void cajas() {\n\t\t\n\t}", "private void habilitar() {\n throw new UnsupportedOperationException(\"Not supported yet.\"); //To change body of generated methods, choose Tools | Templates.\n }", "public static void main(String[] args) {\n\n\t\tUnaryOperator<Integer> func=x->x*7;\t\t\n\t\tint num=func.apply(10);\n\t\tSystem.out.println(num);\n\t\t\n\t\tFunction<Integer, Integer> func1=x->x*10;\n\t\tSystem.out.println(func1.apply(10));\n\t\t\n\t\tList<String> langList=new ArrayList<String>();\n\t\tlangList.add(\"Java\");\n\t\tlangList.add(\"Ruby\");\n\t\tlangList.add(\"Python\");\n\t\t\n\t\tSystem.out.println(langList);\n\t\t\n\t\tlangList.replaceAll(ele -> ele +\" Deeps\");\n\t\tSystem.out.println(langList);\n\t}", "void mo57278c();", "interface DefaultMethod extends SingleMethod {\r\n\tdefault public void myMethod() {\r\n\t\tSystem.out.println(\"from Java 1.8 version can have method with a body\");\r\n}\r\n}", "void mo80457c();", "public void mo21792Q() {\n }", "public static void main(String[] args) {\n \n }", "public static void main(String[] args) {\n \n }", "public static void main(String[] args) {\n \n }", "public static void main(String[] args) {\n \n }", "public static void main(String[] args) {\n \n }", "public static void main(String[] args) {\n \n }", "public void mo21787L() {\n }", "public void method_4270() {}", "static void feladat8() {\n\t}", "public static void main() {\n \n }", "private void level6() {\n }", "void mo57275a();", "void mo80452a();", "private Quantify()\n {\n throw new UnsupportedOperationException(\"Instantiation of utility classes is not supported.\");\n }", "public void m9741j() throws cf {\r\n }", "@Before\n public void setUp() {\n Assume.assumeThat(JavaVersion.getMajorVersion(), Matchers.lessThanOrEqualTo(8));\n }", "private stendhal() {\n\t}", "void mo41083a();", "public static void main(String[] args) {\n\t\tisPolindrom(\"abcd\");\r\n\t\tfibJava8(2);\r\n\t\tfactJava8(5);\r\n\t}", "void m8368b();", "@Override\n\tpublic void implementionSeven(String[] args) throws Exception {\n\n\t}", "public void mo6081a() {\n }", "java.lang.String getS8();", "public void mo21879u() {\n }", "void mo119582b();", "public abstract void mo27385c();", "public abstract void mo70713b();", "public void mo21781F() {\n }", "public interface AnonymousClass1lE {\n void A7X(String str, String str2, String str3);\n\n void A7Z(String str, String str2, @Nullable Map<String, String> map);\n\n void A7b(String str, String str2, Throwable th, @Nullable Map<String, String> map);\n\n void A7d(String str, String str2, @Nullable Map<String, String> map);\n\n void A7f(String str, String str2);\n\n void A8G(String str, String str2, boolean z);\n\n boolean A9J(String str);\n}", "void mo41086b();", "public static void main(String[] args) {\n\n // Creating object of class in main() method\n JEP306_StritfpSample t = new JEP306_StritfpSample();\n\n // Here we have error of putting strictfp and\n // error is not found public static void main method\n System.out.println(t.sum());\n }", "public static void main(String[] args) {\n \n \n }", "public static void main(String[] args) {\n \n \n }", "private void kk12() {\n\n\t}", "public static void main(String[] args) {\n //Ersetzt jetzt mal unseren Parser, Stell Dir vor\n // das Ding liest das Beispiel da oben ^^.\n final StatementNode[] statementNodes = readStatements();\n \n //Zustände:\n // - FillSymbolTable (was für Symbole [variablen, ...] gibt es)\n // - TypInferenz (Was für Typen haben die Expressions und sind die eingaben semantisch korrekt)\n // - CodeGenerierung oder Ausführung (ersetzen wir mit \"schreibe die Werte aller Variablen nach Ende der Ausführung\")\n \n \n final SymbolTabelle symbolTabelle = new SymbolTabelle();\n //IDEE 2:\n //Ich gebe Statements und Expressions nur eine Methode mit Visitor als Callback\n final StatementVisitorSymbolTabelle statementVisitorSymbolTabelle = new StatementVisitorSymbolTabelle(symbolTabelle);\n for(StatementNode statementNode : statementNodes) {\n statementNode.accept(statementVisitorSymbolTabelle);\n }\n \n final StatementVisitorTypInferenz statementVisitorTypInferenz = new StatementVisitorTypInferenz(symbolTabelle);\n for(StatementNode statementNode : statementNodes) {\n statementNode.accept(statementVisitorTypInferenz);\n }\n \n PseudoLaufContext laufContext = new PseudoLaufContext();\n final StatementVisitorCodeGen statementVisitorCodeGen = new StatementVisitorCodeGen(laufContext);\n for(StatementNode statementNode : statementNodes) {\n statementNode.accept(statementVisitorCodeGen);\n }\n \n laufContext.druckeVariablen();\n \n //Zusammenfassung:\n //Reduktion des Problems darauf, den Code nur noch von einem Abhängig zu machen\n //Jetzt nur noch abhängig vom Typ des Statements\n \n \n //Problem hierbei:\n //Ich muss selbst angeben, in welchem Zustand ich bin\n //Code-Duplizierung\n }", "public static void main(String[] args) {\n \n \n \n\t}", "private void someUtilityMethod() {\n }", "private void someUtilityMethod() {\n }", "void mo80455b();", "interface C15937b {\n /* renamed from: a */\n void mo13368a();\n\n /* renamed from: a */\n void mo13369a(int i, int i2, int i3, boolean z);\n\n /* renamed from: a */\n void mo13370a(int i, int i2, List<C15929a> list) throws IOException;\n\n /* renamed from: a */\n void mo13371a(int i, long j);\n\n /* renamed from: a */\n void mo13372a(int i, ErrorCode errorCode);\n\n /* renamed from: a */\n void mo13373a(int i, ErrorCode errorCode, ByteString byteString);\n\n /* renamed from: a */\n void mo13374a(boolean z, int i, int i2);\n\n /* renamed from: a */\n void mo13375a(boolean z, int i, int i2, List<C15929a> list);\n\n /* renamed from: a */\n void mo13376a(boolean z, int i, BufferedSource bufferedSource, int i2) throws IOException;\n\n /* renamed from: a */\n void mo13377a(boolean z, C15943j c15943j);\n }", "void mo88521a();", "void mo20141a();", "public static void main(String[] args) {\n \n \n \n \n }", "public final void mo51373a() {\n }", "private final boolean shouldProposeGenerics(IJavaProject project) {\n\t\treturn true;\n\t\t/*\n\t\tString sourceVersion;\n\t\tif (project != null)\n\t\t\tsourceVersion= project.getOption(JavaCore.COMPILER_SOURCE, true);\n\t\telse\n\t\t\tsourceVersion= JavaCore.getOption(JavaCore.COMPILER_SOURCE);\n\n\t\treturn sourceVersion != null && JavaCore.VERSION_1_5.compareTo(sourceVersion) <= 0;\n\t\t*/\n\t}", "public static void main(String[] args) {\n way8();\n }", "private JacobUtils() {}", "void mo60893b();", "public interface JavaCode {\n\n /**\n * Get an unique identification code for an object\n * TODO: This method is not reliable as hash codes are not unique, should use an UUID generator singleton instead.\n *\n * @param obj the object\n * @return the unique identification code\n */\n static int getUniqueID(Object obj) {\n return obj.hashCode();\n }\n\n /**\n * Compiles this code. If an object implements both {@link JavaCode}\n * and {@link JavaExpression}, only one of this method and\n * {@link JavaExpression#compileExpression(Subroutine, JavaScope)} should be called.\n *\n * @param subroutine the subroutine which this code belongs to\n * @param parent the parent scope of this code\n * @throws JTAException if an error occurs\n */\n void compileCode(Subroutine subroutine, JavaScope parent) throws JTAException;\n}", "public void mo8738a() {\n }", "public void mo1972o() throws cf {\r\n }", "public static void main (String[] args) {import java.util.*;%>\n//&&&staticSymbol&&&<%import org.eclipse.emf.codegen.ecore.genmodel.*;%>\n//&&&staticSymbol&&&<%\n\n/**\n * Copyright (c) 2002-2010 IBM Corporation and others.\n * All rights reserved. This program and the accompanying materials\n * are made available under the terms of the Eclipse Public License v1.0\n * which accompanies this distribution, and is available at\n * http://www.eclipse.org/legal/epl-v10.html\n *\n * Contributors:\n * IBM - Initial API and implementation\n */\n\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nGenPackage genPackage = (GenPackage)((Object[])argument)[0]; GenModel genModel=genPackage.getGenModel(); /* Trick to import java.util.* without warnings */Iterator.class.getName();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nboolean isInterface = Boolean.TRUE.equals(((Object[])argument)[1]); boolean isImplementation = Boolean.TRUE.equals(((Object[])argument)[2]);\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nString publicStaticFinalFlag = isImplementation ? \"public static final \" : \"\";\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%include(\"../Header.javajetinc\");%>\n//&&&staticSymbol&&&<%\nif (isInterface || genModel.isSuppressInterfaces()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&package <%\n//&&&staticSymbol&&&=genPackage.getReflectionPackageName()\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&<%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&package <%\n//&&&staticSymbol&&&=genPackage.getClassPackageName()\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\nif (isImplementation) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.addPseudoImport(\"org.eclipse.emf.ecore.impl.MinimalEObjectImpl.Container\");\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.addPseudoImport(\"org.eclipse.emf.ecore.impl.MinimalEObjectImpl.Container.Dynamic\");\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.addImport(\"org.eclipse.emf.ecore.EClass\");\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.addImport(\"org.eclipse.emf.ecore.EObject\");\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (!genPackage.hasJavaLangConflict() && !genPackage.hasInterfaceImplConflict() && !genPackage.getClassPackageName().equals(genPackage.getInterfacePackageName())) genModel.addImport(genPackage.getInterfacePackageName() + \".*\");\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.markImportLocation(stringBuffer);\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\nif (isInterface) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&/**\n//&&&staticSymbol&&& * <!-- begin-user-doc -->\n//&&&staticSymbol&&& * The <b>Factory</b> for the model.\n//&&&staticSymbol&&& * It provides a create method for each non-abstract class of the model.\n//&&&staticSymbol&&& * <!-- end-user-doc -->\n//&&&staticSymbol&&&<%\nif (!genModel.isSuppressEMFMetaData()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& * @see <%\n//&&&staticSymbol&&&=genPackage.getQualifiedPackageInterfaceName()\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& * @generated\n//&&&staticSymbol&&& */\n//&&&staticSymbol&&&<%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&/**\n//&&&staticSymbol&&& * <!-- begin-user-doc -->\n//&&&staticSymbol&&& * An implementation of the model <b>Factory</b>.\n//&&&staticSymbol&&& * <!-- end-user-doc -->\n//&&&staticSymbol&&& * @generated\n//&&&staticSymbol&&& */\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (isImplementation) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&public class <%\n//&&&staticSymbol&&&=genPackage.getFactoryClassName()\n//&&&staticSymbol&&&%> extends <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.impl.EFactoryImpl\")\n//&&&staticSymbol&&&%><%\nif (!genModel.isSuppressInterfaces()) {\n//&&&staticSymbol&&&%> implements <%\n//&&&staticSymbol&&&=genPackage.getImportedFactoryInterfaceName()\n//&&&staticSymbol&&&%><%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&public interface <%\n//&&&staticSymbol&&&=genPackage.getFactoryInterfaceName()\n//&&&staticSymbol&&&%><%\nif (!genModel.isSuppressEMFMetaData()) {\n//&&&staticSymbol&&&%> extends <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EFactory\")\n//&&&staticSymbol&&&%><%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&{\n//&&&staticSymbol&&&<%\nif (genModel.hasCopyrightField()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=publicStaticFinalFlag\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.String\")\n//&&&staticSymbol&&&%> copyright = <%\n//&&&staticSymbol&&&=genModel.getCopyrightFieldLiteral()\n//&&&staticSymbol&&&%>;<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (isImplementation && (genModel.isSuppressEMFMetaData() || genModel.isSuppressInterfaces())) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * The singleton instance of the factory.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=publicStaticFinalFlag\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genPackage.getFactoryClassName()\n//&&&staticSymbol&&&%> eINSTANCE = init();\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (isInterface && genModel.isSuppressEMFMetaData()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * The singleton instance of the factory.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=publicStaticFinalFlag\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genPackage.getFactoryInterfaceName()\n//&&&staticSymbol&&&%> INSTANCE = <%\n//&&&staticSymbol&&&=genPackage.getQualifiedFactoryClassName()\n//&&&staticSymbol&&&%>.eINSTANCE;\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n} else if (isInterface && !genModel.isSuppressInterfaces()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * The singleton instance of the factory.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=publicStaticFinalFlag\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genPackage.getFactoryInterfaceName()\n//&&&staticSymbol&&&%> eINSTANCE = <%\n//&&&staticSymbol&&&=genPackage.getQualifiedFactoryClassName()\n//&&&staticSymbol&&&%>.init();\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (isImplementation) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Creates the default factory implementation.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&<%\nString factoryType = genModel.isSuppressEMFMetaData() ? genPackage.getFactoryClassName() : genPackage.getImportedFactoryInterfaceName();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic static <%\n//&&&staticSymbol&&&=factoryType\n//&&&staticSymbol&&&%> init()\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\ttry\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\t<%\n//&&&staticSymbol&&&=factoryType\n//&&&staticSymbol&&&%> the<%\n//&&&staticSymbol&&&=genPackage.getFactoryName()\n//&&&staticSymbol&&&%> = (<%\n//&&&staticSymbol&&&=factoryType\n//&&&staticSymbol&&&%>)<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EPackage\")\n//&&&staticSymbol&&&%>.Registry.INSTANCE.getEFactory(<%\n//&&&staticSymbol&&&=genPackage.getPackageInterfaceName()\n//&&&staticSymbol&&&%>.eNS_URI);\n//&&&staticSymbol&&&\t\t\tif (the<%\n//&&&staticSymbol&&&=genPackage.getFactoryName()\n//&&&staticSymbol&&&%> != null)\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&&\t\t\t\treturn the<%\n//&&&staticSymbol&&&=genPackage.getFactoryName()\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\tcatch (Exception exception)\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\t<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.plugin.EcorePlugin\")\n//&&&staticSymbol&&&%>.INSTANCE.log(exception);\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\treturn new <%\n//&&&staticSymbol&&&=genPackage.getImportedFactoryClassName()\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Creates an instance of the factory.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\tpublic <%\n//&&&staticSymbol&&&=genPackage.getFactoryClassName()\n//&&&staticSymbol&&&%>()\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\tsuper();\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useClassOverrideAnnotation()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@Override\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic EObject create(EClass eClass)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\tswitch (eClass.getClassifierID())\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&<%\nfor (GenClass genClass : genPackage.getGenClasses()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (!genClass.isAbstract()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tcase <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%>.<%\n//&&&staticSymbol&&&=genClass.getClassifierID()\n//&&&staticSymbol&&&%>: return <%\n//&&&staticSymbol&&&*%%storeSymbol%%*0\n//&&&staticSymbol&&&%>create<%\n//&&&staticSymbol&&&=genClass.getName()\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tdefault:\n//&&&staticSymbol&&&\t\t\t\tthrow new IllegalArgumentException(\"The class '\" + eClass.getName() + \"' is not a valid classifier\");<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(2)\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\nif (!genPackage.getAllGenDataTypes().isEmpty()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useClassOverrideAnnotation()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@Override\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic Object createFromString(<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EDataType\")\n//&&&staticSymbol&&&%> eDataType, String initialValue)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\tswitch (eDataType.getClassifierID())\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&<%\nfor (GenDataType genDataType : genPackage.getAllGenDataTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isSerializable()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tcase <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%>.<%\n//&&&staticSymbol&&&=genDataType.getClassifierID()\n//&&&staticSymbol&&&%>:\n//&&&staticSymbol&&&\t\t\t\treturn create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>FromString(eDataType, initialValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tdefault:\n//&&&staticSymbol&&&\t\t\t\tthrow new IllegalArgumentException(\"The datatype '\" + eDataType.getName() + \"' is not a valid classifier\");<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(2)\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useClassOverrideAnnotation()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@Override\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic String convertToString(<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EDataType\")\n//&&&staticSymbol&&&%> eDataType, Object instanceValue)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\tswitch (eDataType.getClassifierID())\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&<%\nfor (GenDataType genDataType : genPackage.getAllGenDataTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isSerializable()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tcase <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%>.<%\n//&&&staticSymbol&&&=genDataType.getClassifierID()\n//&&&staticSymbol&&&%>:\n//&&&staticSymbol&&&\t\t\t\treturn convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>ToString(eDataType, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tdefault:\n//&&&staticSymbol&&&\t\t\t\tthrow new IllegalArgumentException(\"The datatype '\" + eDataType.getName() + \"' is not a valid classifier\");<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(2)\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nfor (GenClass genClass : genPackage.getGenClasses()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (!genClass.isAbstract()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\tpublic <%\n//&&&staticSymbol&&&=genClass.getTypeParameters()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getImportedInterfaceName()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getInterfaceTypeArguments()\n//&&&staticSymbol&&&%> create<%\n//&&&staticSymbol&&&=genClass.getName()\n//&&&staticSymbol&&&%>()\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&& <%\nif (genClass.isDynamic()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genClass.getImportedInterfaceName()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getInterfaceTypeArguments()\n//&&&staticSymbol&&&%> <%\n//&&&staticSymbol&&&=genClass.getSafeUncapName()\n//&&&staticSymbol&&&%> = <%\n//&&&staticSymbol&&&=genClass.getCastFromEObject()\n//&&&staticSymbol&&&%>super.create(<%\n//&&&staticSymbol&&&=genClass.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genClass.getImportedClassName()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getClassTypeArguments()\n//&&&staticSymbol&&&%> <%\n//&&&staticSymbol&&&=genClass.getSafeUncapName()\n//&&&staticSymbol&&&%> = new <%\n//&&&staticSymbol&&&=genClass.getImportedClassName()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getClassTypeArguments()\n//&&&staticSymbol&&&%>()<%\nif (genModel.isSuppressInterfaces() && !genPackage.getReflectionPackageName().equals(genPackage.getInterfacePackageName())) {\n//&&&staticSymbol&&&%>{}<%\n}\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genClass.getSafeUncapName()\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nfor (GenDataType genDataType : genPackage.getAllGenDataTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isSerializable()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (genPackage.isDataTypeConverters() || genDataType.hasCreatorBody()) { String eDataType = genDataType.getQualifiedClassifierAccessor();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useGenerics() && genDataType.isUncheckedCast() && !genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@SuppressWarnings(\"unchecked\")\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic <%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedInstanceClassName()\n//&&&staticSymbol&&&%> create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(<%\nif (genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>final <%\n}\n//&&&staticSymbol&&&%>String <%\nif (genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>it<%\n} else {\n//&&&staticSymbol&&&%>literal<%\n}\n//&&&staticSymbol&&&%>)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&& <%\nif (genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getCreatorBody(genModel.getIndentation(stringBuffer))\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType instanceof GenEnum) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getImportedInstanceClassName()\n//&&&staticSymbol&&&%> result = <%\n//&&&staticSymbol&&&=genDataType.getImportedInstanceClassName()\n//&&&staticSymbol&&&%>.get(literal);\n//&&&staticSymbol&&&\t\tif (result == null) throw new IllegalArgumentException(\"The value '\" + literal + \"' is not a valid enumerator of '\" + <%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>.getName() + \"'\");<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(2)\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(3)\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn result;\n//&&&staticSymbol&&& <%\n} else if (genDataType.getBaseType() != null) { GenDataType genBaseType = genDataType.getBaseType(); boolean isPrimitiveConversion = !genDataType.isPrimitiveType() && genBaseType.isPrimitiveType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genBaseType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (isPrimitiveConversion && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn new <%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(create<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(literal));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn create<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genBaseType.getGenPackage().isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (isPrimitiveConversion && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn new <%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.create<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(literal));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.create<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getItemType() != null) { GenDataType genItemType = genDataType.getItemType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (literal == null) return null;\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedInstanceClassName()\n//&&&staticSymbol&&&%> result = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.ArrayList\")\n//&&&staticSymbol&&&%><%\nif (genModel.useGenerics()) {\n//&&&staticSymbol&&&%><<%=genItemType.getObjectType().getImportedParameterizedInstanceClassName()%>><%\n}\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\nif (genModel.getRuntimeVersion().getValue() < GenRuntimeVersion.EMF26_VALUE) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.StringTokenizer\")\n//&&&staticSymbol&&&%> stringTokenizer = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.StringTokenizer\")\n//&&&staticSymbol&&&%>(literal); stringTokenizer.hasMoreTokens(); )\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (String item : split(literal))\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genModel.getRuntimeVersion().getValue() < GenRuntimeVersion.EMF26_VALUE) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString item = stringTokenizer.nextToken();\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) { genItemType = genItemType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(create<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>(item));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(create<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, item));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage().isDataTypeConverters()) { genItemType = genItemType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(<%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.create<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>(item));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(<%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, item));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\treturn result;\n//&&&staticSymbol&&& <%\n} else if (!genDataType.getMemberTypes().isEmpty()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (literal == null) return <%\n//&&&staticSymbol&&&=genDataType.getStaticValue(null)\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getImportedInstanceClassName()\n//&&&staticSymbol&&&%> result = <%\n//&&&staticSymbol&&&=genDataType.getStaticValue(null)\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&\t\tRuntimeException exception = null;\n//&&&staticSymbol&&& <%\nfor (GenDataType genMemberType : genDataType.getMemberTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\ttry\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) { if (!genDataType.isPrimitiveType()) genMemberType = genMemberType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = create<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(literal);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = (<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)create<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) { if (!genDataType.isPrimitiveType()) genMemberType = genMemberType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.create<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(literal);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = (<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tif (<%\nif (!genDataType.isPrimitiveType()) {\n//&&&staticSymbol&&&%>result != null && <%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.util.Diagnostician\")\n//&&&staticSymbol&&&%>.INSTANCE.validate(<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>, <%\nif (genDataType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>new <%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(result)<%\n} else {\n//&&&staticSymbol&&&%>result<%\n}\n//&&&staticSymbol&&&%>, null, null))\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&&\t\t\t\treturn result;\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\tcatch (RuntimeException e)\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\texception = e;\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (<%\nif (!genDataType.isPrimitiveType()) {\n//&&&staticSymbol&&&%>result != null || <%\n}\n//&&&staticSymbol&&&%>exception == null) return result;\n//&&&staticSymbol&&& \n//&&&staticSymbol&&&\t\tthrow exception;\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genModel.useGenerics() && (genDataType.isArrayType() || !genDataType.getEcoreDataType().getETypeParameters().isEmpty() || genDataType.getEcoreDataType().getInstanceTypeName().contains(\"<\"))) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn (<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%>)super.createFromString(literal);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genDataType.isArrayType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t// TODO: implement this method\n//&&&staticSymbol&&&\t\t// Ensure that you remove @generated or mark it @generated NOT\n//&&&staticSymbol&&&\t\tthrow new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.UnsupportedOperationException\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\n} else if (genDataType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn ((<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)super.createFromString(<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>, literal)).<%\n//&&&staticSymbol&&&=genDataType.getPrimitiveValueFunction()\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%>super.createFromString(<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>, literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (!genPackage.isDataTypeConverters() && genModel.useGenerics() && genDataType.isUncheckedCast() && !genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@SuppressWarnings(\"unchecked\")\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic <%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%> create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EDataType\")\n//&&&staticSymbol&&&%> eDataType, String initialValue)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&& <%\nif (genDataType instanceof GenEnum) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters() || genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(initialValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=((GenEnum)genDataType).getImportedInstanceClassName()\n//&&&staticSymbol&&&%> result = <%\n//&&&staticSymbol&&&=((GenEnum)genDataType).getImportedInstanceClassName()\n//&&&staticSymbol&&&%>.get(initialValue);\n//&&&staticSymbol&&&\t\tif (result == null) throw new IllegalArgumentException(\"The value '\" + initialValue + \"' is not a valid enumerator of '\" + eDataType.getName() + \"'\");<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(2)\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(3)\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn result;\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getBaseType() != null) { GenDataType genBaseType = genDataType.getBaseType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genBaseType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.getObjectInstanceClassName().equals(genBaseType.getObjectInstanceClassName())) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%>create<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, initialValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, initialValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getItemType() != null) { GenDataType genItemType = genDataType.getItemType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(initialValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (initialValue == null) return null;\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%> result = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.ArrayList\")\n//&&&staticSymbol&&&%><%\nif (genModel.useGenerics()) {\n//&&&staticSymbol&&&%><<%=genItemType.getObjectType().getImportedParameterizedInstanceClassName()%>><%\n}\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\nif (genModel.getRuntimeVersion().getValue() < GenRuntimeVersion.EMF26_VALUE) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.StringTokenizer\")\n//&&&staticSymbol&&&%> stringTokenizer = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.StringTokenizer\")\n//&&&staticSymbol&&&%>(initialValue); stringTokenizer.hasMoreTokens(); )\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (String item : split(initialValue))\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genModel.getRuntimeVersion().getValue() < GenRuntimeVersion.EMF26_VALUE) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString item = stringTokenizer.nextToken();\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(create<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, item));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(<%\nif (!genItemType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genItemType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, item));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\treturn result;\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (!genDataType.getMemberTypes().isEmpty()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn new <%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(initialValue));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(initialValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (initialValue == null) return null;\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%> result = null;\n//&&&staticSymbol&&&\t\tRuntimeException exception = null;\n//&&&staticSymbol&&& <%\nfor (GenDataType genMemberType : genDataType.getMemberTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\ttry\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = <%\nif (!genDataType.isObjectType() && !genDataType.getObjectInstanceClassName().equals(genMemberType.getObjectInstanceClassName())) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%>create<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, initialValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, initialValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tif (result != null && <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.util.Diagnostician\")\n//&&&staticSymbol&&&%>.INSTANCE.validate(eDataType, result, null, null))\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&&\t\t\t\treturn result;\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\tcatch (RuntimeException e)\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\texception = e;\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (result != null || exception == null) return result;\n//&&&staticSymbol&&& \n//&&&staticSymbol&&&\t\tthrow exception;\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genPackage.isDataTypeConverters() || genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(initialValue);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genModel.useGenerics() && (genDataType.isArrayType() || !genDataType.getEcoreDataType().getETypeParameters().isEmpty() || genDataType.getEcoreDataType().getInstanceTypeName().contains(\"<\"))) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%>super.createFromString(initialValue);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genDataType.isArrayType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t// TODO: implement this method\n//&&&staticSymbol&&&\t\t// Ensure that you remove @generated or mark it @generated NOT\n//&&&staticSymbol&&&\t\tthrow new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.UnsupportedOperationException\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%>super.createFromString(eDataType, initialValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\nif (genPackage.isDataTypeConverters() || genDataType.hasConverterBody()) { String eDataType = genDataType.getQualifiedClassifierAccessor();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\tpublic String convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(<%\nif (genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>final <%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genDataType.getImportedBoundedWildcardInstanceClassName()\n//&&&staticSymbol&&&%> <%\nif (genDataType.hasConverterBody()) {\n//&&&staticSymbol&&&%>it<%\n} else {\n//&&&staticSymbol&&&%>instanceValue<%\n}\n//&&&staticSymbol&&&%>)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&& <%\nif (genDataType.hasConverterBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getConverterBody(genModel.getIndentation(stringBuffer))\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType instanceof GenEnum) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn instanceValue == null ? null : instanceValue.toString();\n//&&&staticSymbol&&& <%\n} else if (genDataType.getBaseType() != null) { GenDataType genBaseType = genDataType.getBaseType(); boolean isPrimitiveConversion = !genDataType.isPrimitiveType() && genBaseType.isPrimitiveType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genBaseType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (isPrimitiveConversion) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn instanceValue == null ? null : convert<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(instanceValue<%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>.<%\n//&&&staticSymbol&&&=genBaseType.getPrimitiveValueFunction()\n//&&&staticSymbol&&&%>()<%\n}\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genBaseType.getGenPackage().isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedFactoryInstanceAccessor()\n//&&&staticSymbol&&&%>.convert<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getItemType() != null) { GenDataType genItemType = genDataType.getItemType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (instanceValue == null) return null;\n//&&&staticSymbol&&&\t\tif (instanceValue.isEmpty()) return \"\";\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.StringBuffer\")\n//&&&staticSymbol&&&%> result = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.StringBuffer\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\nString item; if (!genModel.useGenerics()) { item = \"i.next()\"; \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.Iterator\")\n//&&&staticSymbol&&&%> i = instanceValue.iterator(); i.hasNext(); )\n//&&&staticSymbol&&& <%\n} else { item = \"item\";\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.Object\")\n//&&&staticSymbol&&&%> item : instanceValue)\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) { genItemType = genItemType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(convert<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genItemType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(convert<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage().isDataTypeConverters()) { genItemType = genItemType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(<%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convert<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genItemType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(<%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(' ');\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\treturn result.substring(0, result.length() - 1);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.getMemberTypes().isEmpty()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (!genDataType.isPrimitiveType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (instanceValue == null) return null;\n//&&&staticSymbol&&& <%\nfor (GenDataType genMemberType : genDataType.getMemberTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>.isInstance(instanceValue))\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\ttry\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genMemberType.getQualifiedInstanceClassName().equals(genDataType.getQualifiedInstanceClassName())) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n} else if (genMemberType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(((<%\n//&&&staticSymbol&&&=genMemberType.getObjectType().getImportedInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue).<%\n//&&&staticSymbol&&&=genMemberType.getPrimitiveValueFunction()\n//&&&staticSymbol&&&%>());\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genMemberType.getObjectType().getImportedBoundedWildcardInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage().isDataTypeConverters()) { genMemberType = genMemberType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genMemberType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tif (value != null) return value;\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t\tcatch (Exception e)\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&&\t\t\t\t// Keep trying other member types until all have failed.\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nfor (GenDataType genMemberType : genDataType.getMemberTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\ttry\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>new <%\n//&&&staticSymbol&&&=genMemberType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(instanceValue)<%\n} else {\n//&&&staticSymbol&&&%>instanceValue<%\n}\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage().isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString value = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString value = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>new <%\n//&&&staticSymbol&&&=genMemberType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(instanceValue)<%\n} else {\n//&&&staticSymbol&&&%>instanceValue<%\n}\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tif (value != null) return value;\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\tcatch (Exception e)\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\t// Keep trying other member types until all have failed.\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tthrow new IllegalArgumentException(\"Invalid value: '\"+instanceValue+\"' for datatype :\"+<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>.getName());\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genModel.useGenerics() && (genDataType.isArrayType() || !genDataType.getEcoreDataType().getETypeParameters().isEmpty() || genDataType.getEcoreDataType().getInstanceTypeName().contains(\"<\"))) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn super.convertToString(instanceValue);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genDataType.isArrayType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t// TODO: implement this method\n//&&&staticSymbol&&&\t\t// Ensure that you remove @generated or mark it @generated NOT\n//&&&staticSymbol&&&\t\tthrow new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.UnsupportedOperationException\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\n} else if (genDataType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn super.convertToString(<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>, new <%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(instanceValue));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn super.convertToString(<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useGenerics() && (genDataType.getItemType() != null || genDataType.isUncheckedCast()) && (genPackage.isDataTypeConverters() || genDataType.hasCreatorBody())) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@SuppressWarnings(\"unchecked\")\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic String convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EDataType\")\n//&&&staticSymbol&&&%> eDataType, Object instanceValue)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&& <%\nif (genDataType instanceof GenEnum) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters() || genDataType.hasConverterBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genDataType.getImportedInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn instanceValue == null ? null : instanceValue.toString();\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getBaseType() != null) { GenDataType genBaseType = genDataType.getBaseType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genBaseType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getItemType() != null) { GenDataType genItemType = genDataType.getItemType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters() || genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genDataType.getImportedBoundedWildcardInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue);\n//&&&staticSymbol&&& <%\n} else { final String singleWildcard = genModel.useGenerics() ? \"<?>\" : \"\";\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (instanceValue == null) return null;\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.List\")\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=singleWildcard\n//&&&staticSymbol&&&%> list = (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.List\")\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=singleWildcard\n//&&&staticSymbol&&&%>)instanceValue;\n//&&&staticSymbol&&&\t\tif (list.isEmpty()) return \"\";\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.StringBuffer\")\n//&&&staticSymbol&&&%> result = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.StringBuffer\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\nString item; if (!genModel.useGenerics()) { item = \"i.next()\"; \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.Iterator\")\n//&&&staticSymbol&&&%> i = list.iterator(); i.hasNext(); )\n//&&&staticSymbol&&& <%\n} else { item = \"item\";\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.Object\")\n//&&&staticSymbol&&&%> item : list)\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(convert<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(<%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(' ');\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\treturn result.substring(0, result.length() - 1);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (!genDataType.getMemberTypes().isEmpty()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters() || genDataType.hasConverterBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isPrimitiveType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn instanceValue == null ? null : convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(((<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue)<%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>.<%\n//&&&staticSymbol&&&=genDataType.getPrimitiveValueFunction()\n//&&&staticSymbol&&&%>()<%\n}\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (instanceValue == null) return null;\n//&&&staticSymbol&&& <%\nfor (GenDataType genMemberType : genDataType.getMemberTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>.isInstance(instanceValue))\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\ttry\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tif (value != null) return value;\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t\tcatch (Exception e)\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&&\t\t\t\t// Keep trying other member types until all have failed.\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tthrow new IllegalArgumentException(\"Invalid value: '\"+instanceValue+\"' for datatype :\"+eDataType.getName());\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genPackage.isDataTypeConverters() || genDataType.hasConverterBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isPrimitiveType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn instanceValue == null ? null : convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(<%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>(<%\n}\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue<%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>).<%\n//&&&staticSymbol&&&=genDataType.getPrimitiveValueFunction()\n//&&&staticSymbol&&&%>()<%\n}\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genDataType.getImportedBoundedWildcardInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genModel.useGenerics() && (genDataType.isArrayType() || !genDataType.getEcoreDataType().getETypeParameters().isEmpty() || genDataType.getEcoreDataType().getInstanceTypeName().contains(\"<\"))) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn super.convertToString(instanceValue);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genDataType.isArrayType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t// TODO: implement this method\n//&&&staticSymbol&&&\t\t// Ensure that you remove @generated or mark it @generated NOT\n//&&&staticSymbol&&&\t\tthrow new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.UnsupportedOperationException\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn super.convertToString(eDataType, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nfor (GenClass genClass : genPackage.getGenClasses()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genClass.hasFactoryInterfaceCreateMethod()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Returns a new object of class '<em><%\n//&&&staticSymbol&&&=genClass.getFormattedName()\n//&&&staticSymbol&&&%></em>'.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @return a new object of class '<em><%\n//&&&staticSymbol&&&=genClass.getFormattedName()\n//&&&staticSymbol&&&%></em>'.\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=genClass.getTypeParameters()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getImportedInterfaceName()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getInterfaceTypeArguments()\n//&&&staticSymbol&&&%> create<%\n//&&&staticSymbol&&&=genClass.getName()\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&&\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nfor (GenDataType genDataType : genPackage.getAllGenDataTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isSerializable()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Returns an instance of data type '<em><%\n//&&&staticSymbol&&&=genDataType.getFormattedName()\n//&&&staticSymbol&&&%></em>' corresponding the given literal.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @param literal a literal of the data type.\n//&&&staticSymbol&&&\t * @return a new instance value of the data type.\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedInstanceClassName()\n//&&&staticSymbol&&&%> create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(String literal);\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Returns a literal representation of an instance of data type '<em><%\n//&&&staticSymbol&&&=genDataType.getFormattedName()\n//&&&staticSymbol&&&%></em>'.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @param instanceValue an instance value of the data type.\n//&&&staticSymbol&&&\t * @return a literal representation of the instance value.\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\tString convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getImportedBoundedWildcardInstanceClassName()\n//&&&staticSymbol&&&%> instanceValue);\n//&&&staticSymbol&&&\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (!isImplementation && !genModel.isSuppressEMFMetaData()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Returns the package supported by this factory.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @return the package supported by this factory.\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=genPackage.getPackageInterfaceName()\n//&&&staticSymbol&&&%> get<%\n//&&&staticSymbol&&&=genPackage.getBasicPackageName()\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n} else if (isImplementation) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\tpublic <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%> get<%\n//&&&staticSymbol&&&=genPackage.getBasicPackageName()\n//&&&staticSymbol&&&%>()\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\treturn (<%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%>)getEPackage();\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @deprecated\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useClassOverrideAnnotation()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@Deprecated\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic static <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%> getPackage()\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%>.eINSTANCE;\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&} //<%\n//&&&staticSymbol&&&*%%storeSymbol%%*1\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.emitSortedImports();\n//&&&staticSymbol&&&%>\n\n}", "static void feladat9() {\n\t}", "@Override\n public boolean isVersionCodeCompatible(int version) {\n return true;\n }", "public void mo4359a() {\n }", "private static List<String> getJavasSourceCodeFiels(Map<String,Object> map){\r\n \t\t\r\n \t\t\r\n \t\tSystem.out.println(\"............\");\r\n \t\tLinkedList<String> list = new LinkedList<String>();\r\n \t\tfor(String key : map.keySet()){\r\n \t\t\tObject o = map.get(key);\r\n \r\n \t\t\t//package...\r\n \t\t\tif(o instanceof IPackageFragment){\r\n \t\t\t\t//System.out.println(\"Package --> \" + key);\r\n \t\t\t\tkey = key.substring(0,key.indexOf('[')).trim();\r\n \t\t\t\tkey = PACKAGE + \"(\" + key + \")\";\r\n \t\t\t\tlist.add(key);\r\n \t\t\t}\r\n \t\t\t//class...\r\n \t\t\tif(o instanceof ICompilationUnit){\r\n \t\t\t\t//System.out.println(\"Class --> \" + key);\r\n \t\t\t\tString classname = key.substring(0,key.indexOf('[')).trim();\r\n \t\t\t\tString packagename = key.substring(key.indexOf(PACKAGE),key.indexOf('\\n',key.indexOf(PACKAGE)));\r\n \t\t\t\tkey = CLASS_WITH_MEMBERS + \"(\" + packagename + \",\" + classname + \")\";\r\n \t\t\t\tlist.add(key);\r\n \t\t\t}//method\r\n \t\t\tif(o instanceof IMethod){\r\n \t\t\t\tSystem.out.println(\"Methode --> \" + key);\r\n \t\t\t\tkey = METHOD + \"(\" + getQueryFromMethod((IMethod)o) + \")\";\r\n \t\t\t\tlist.add(key);\r\n \t\t\t}\r\n \t\t\t\r\n \t\t\tif(o instanceof IField){\r\n \t\t\t\tSystem.out.println(\"Attribut --> \" + key);\r\n \t\t\t\tkey = FIELD + \"(\" + getQueryFromField((IField)o) + \")\";\r\n \t\t\t\tlist.add(key);\r\n \t\t\t}\r\n \t\t}\r\n \t\treturn list;\r\n \t\t\r\n \t\t\r\n \t\t/*\r\n \t\tfor(String key : map.keySet()){\r\n \t\t\tObject o = map.get(key);\r\n \t\t\t//if(o instanceof ISourceAttribute)\r\n \t\t\t\t//System.out.println(\"attribute\");\r\n \t\t\t//if(o instanceof ISourceMethod)\r\n \t\t\t\t//System.out.println(\"methode\");\r\n \t\t\tif(o instanceof IPackageFragment) \r\n \t\t\t\tSystem.out.println(\"Package\");\r\n \t\t\tif(o instanceof ICompilationUnit)\r\n \t\t\t\tSystem.out.println(\"sour code file\");\r\n \t\t\t\t\r\n \t\t\t//\"oldquery or class('voller packagename', klassenname)\"\r\n \t\t\t\t\r\n \t\t\t\t\r\n \t\t\tif(o instanceof IField)\r\n \t\t\t\tSystem.out.println(\"Attribut\");\r\n \t\t\tif(o instanceof IType)\r\n \t\t\t\tSystem.out.println(\"classe also class ... in einem file\");\r\n \t\t\tif(o instanceof IMethod)\r\n \t\t\t\tSystem.out.println(\"Methode\");\r\n \t\t\tif(o instanceof IPackageFragmentRoot) \r\n \t\t\t\tSystem.out.println(\"jar package / src Ordner\");\r\n \t\t\tif(o instanceof IProject)\r\n \t\t\t\tSystem.out.println(\"Projekt Ordner\");\r\n \t\t\tif(o instanceof IClassFile)\r\n \t\t\t\tSystem.out.println(\"ClassFile\");\r\n \t\t\tif(o instanceof IAdaptable) //trieft auch auf viele ander sachen zu\r\n \t\t\t\tSystem.out.println(\"Libaraycontainer\");\r\n \t\t\tif(o instanceof IFile)\r\n \t\t\t\tSystem.out.println(\"file\"); //je nach ausgewlter ansicht knnen file auch *.java datein sein\r\n \t\t\tif(o instanceof IFolder)\r\n \t\t\t\tSystem.out.println(\"folder\");\r\n \t\t\tSystem.out.println(o.getClass());\r\n \t\t\t\r\n \t\r\n \t\t}\r\n \t\treturn null;\r\n \t\t*/\r\n \t}", "public void mo1531a() {\n }", "public void mo1976s() throws cf {\r\n }", "void mo119581a();", "static void feladat6() {\n\t}", "private void generateSolution() {\n\t\t// TODO\n\n\t}" ]
[ "0.5890391", "0.58054996", "0.57008785", "0.56167847", "0.54946315", "0.54761344", "0.524263", "0.52340496", "0.5233149", "0.52029705", "0.5160466", "0.51574665", "0.5143396", "0.5094738", "0.5084682", "0.5069909", "0.50661004", "0.50645214", "0.5064437", "0.50475377", "0.5041245", "0.5039573", "0.5037435", "0.50317824", "0.5007829", "0.500209", "0.49986184", "0.4996393", "0.49733046", "0.49654463", "0.49482828", "0.49374196", "0.49367213", "0.49362347", "0.4931423", "0.49300268", "0.49164099", "0.49096605", "0.4893169", "0.48904118", "0.4883474", "0.4883474", "0.4883474", "0.4883474", "0.4883474", "0.4883474", "0.4869394", "0.48675945", "0.4863796", "0.4849808", "0.48444158", "0.48439786", "0.48421556", "0.4838581", "0.48383453", "0.4837389", "0.4833218", "0.48310906", "0.4830076", "0.4827487", "0.481306", "0.48097232", "0.4807137", "0.48028547", "0.4801506", "0.47964317", "0.47952133", "0.479351", "0.4792214", "0.4791279", "0.47875714", "0.47851777", "0.47851777", "0.47834784", "0.47784257", "0.47747812", "0.47722042", "0.47722042", "0.47719148", "0.47705945", "0.47705132", "0.47681588", "0.47653475", "0.47629744", "0.47611335", "0.47570732", "0.47566834", "0.47548115", "0.4751401", "0.47484854", "0.47464594", "0.47460574", "0.47457317", "0.4742769", "0.47399607", "0.47344413", "0.47313395", "0.47252822", "0.47233605", "0.4721698", "0.47122636" ]
0.0
-1
write your code in Java SE 8
public static int bestSolution(int[] A) { int counter = 0, j = 0; long[] upper = new long[A.length]; long[] lower = new long[A.length]; for (int i = 0; i < A.length; i++) { lower[i] = (long) i - A[i]; upper[i] = (long) i + A[i]; } Arrays.sort(lower); Arrays.sort(upper); for (int i = 0; i < A.length; i++) { while (j < A.length && upper[i] >= lower[j]) { counter += j - i; j++; } if (counter > 10000000) return -1; } return counter; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static void main(String[] args) {\n\t\tnew Action() {\r\n\r\n\t\t\t@Override\r\n\t\t\tpublic void execute(String content) {\r\n\t\t\t\t// TODO Auto-generated method stub\r\n\t\t\t\tSystem.out.println(content);\r\n\t\t\t}\r\n\t\t\t\r\n\t\t}.execute(\"jdk1.8之前匿名内部类实现方式\");\r\n\t\t\r\n\t\t\r\n\t\t//lambda\r\n\t\tAction login=(String content)->{\r\n\t\t\tSystem.out.println(\"jdk1.8的lambda语法实现\");\r\n\t\t};\r\n\t\tlogin.execute(\"jdk1.8的lambda语法实现\");\r\n\t\t\r\n\t}", "public static void main(String[] args) {\n\t\t\r\n\t\tnew Thread(new Runnable() {\r\n\t\t\tpublic void run() {\r\n\t\t\t\tSystem.out.println(\"Before JAVA 8, too much code for too little to do\");\r\n\t\t\t}\r\n\t\t}).start();\r\n\t\t\r\n\t\t// Java 8 way:\r\n\t\t\r\n\t\tnew Thread( () -> System.out.println(\"In Java 8, Lambda Expression rocks !!\") ).start();\r\n\t\t\r\n\t\tSystem.out.println(\"-----------*************************-------------\");\r\n\t\t\r\n\t\t// Iterating Over List Using Lambda Expressions\r\n\t\t\r\n\t\tList features = Arrays.asList(\"Lambdas\",\"Default Method\",\"Stream API\",\"DAte and Time API\");\r\n\t\t\r\n\t\tfeatures.forEach(n -> System.out.println(n));\r\n\r\n\t\tSystem.out.println(\"-----------*************************-------------\");\r\n\t\t\t\t\r\n\t\t// Even better use method reference feature of Java 8\r\n\t\t// method reference is denoted by :: ****double colon***** operator\r\n\t\t// looks similar to scope resolution operator of C++\r\n\t\t\r\n\t\tfeatures.forEach(System.out::println);\r\n\r\n\t}", "public static void main(String[] args) {\r\n\t\tSomeJava8Features obj = new SomeJava8Features();\r\n\r\n\t\t// StringJoiner\r\n\t\texampleStringJoiner();\r\n\t\t\r\n\t\t// Default\r\n\t\tint ary[] = {3,6,8,9,0};\r\n\t\tSystem.out.println(\"\\nsumOfGivenIntArray ... \" + obj.sumOfGivenIntArray(ary));\r\n\t\tobj.sayMore(\"Hello Rohini\");\r\n\t\t\r\n\t\t// ForEach & Lambda Expression\r\n\t\texampleForEach_FindMaximum(ary);\r\n\t\t\r\n\r\n\t}", "@Deprecated\n\tprivate void oldCode()\n\t{\n\t}", "@Override\r\n\tprotected void doF8() {\n\t\t\r\n\t}", "private void level7() {\n }", "Compatibility compatibility();", "@SuppressWarnings(\"unused\")\n\tprivate void version() {\n\n\t}", "public static void main(String[] args) {\n throw new NotImplementedException();\n }", "public static void main(String[] args) {\n Foo foo = new Java8Default();\n foo.sumDefault(2,4);\n\n }", "@Test\n public void source8() throws Exception {\n ImmutableList<String> options = (GeneratedAnnotationsTest.isJdk9OrLater()) ? ImmutableList.of(\"--release\", \"8\") : ImmutableList.of(\"-source\", \"8\", \"-target\", \"8\");\n String generated = runProcessor(options, null);\n assertThat(generated).contains(GeneratedAnnotationsTest.JAVAX_ANNOTATION_GENERATED);\n assertThat(generated).doesNotContain(GeneratedAnnotationsTest.JAVAX_ANNOTATION_PROCESSING_GENERATED);\n }", "void compileToJava();", "public static void main(String args[]) throws Exception\n {\n \n \n \n }", "public final void mo8775b() {\n }", "public static void main(String[] args) {\n\t\t//Até o java 7\n\t\tnew Thread(new Runnable() {\n\n\t\t @Override\n\t\t public void run() {\n\t\t System.out.println(\"Executando um Runnable\");\n\t\t }\n\n\t\t}).start();\n\t\t//A partir do java 8\n\t\tnew Thread(() -> System.out.println(\"Executando um Runnable\")).start();\n\t\t\n\t\t//iterando com java 8: classe anonima\n\t\ttexto.forEach(new Consumer<String>() {\n\t\t public void accept(String s) {\n\t\t System.out.println(s);\n\t\t }\n\t\t});\n\t\t//iterando com java 8: lambda\n\t\t//Essa sintaxe funciona para qualquer interface \n\t\t//que tenha apenas um método abstrato\n\t\ttexto.forEach((String s) -> {\n\t\t System.out.println(s);\n\t\t});\n\t\t//ou\n\t\ttexto.forEach((s) -> {\n\t\t System.out.println(s);\n\t\t});\n\t\t//ou\n\t\ttexto.forEach(s -> {\n\t\t System.out.println(s);\n\t\t});\n\t\t//ou\n\t\ttexto.forEach(s -> System.out.println(s));\n\t\t// Uma interface que possui apenas um método abstrato \n\t\t//é agora conhecida como interface funcional e pode ser utilizada dessa forma\n\t\t\n\t\t//Outro exemplo é o próprio Comparator. Se utilizarmos a forma \n\t\t//de classe anônima, teremos essa situação: \n\t\ttexto.sort(new Comparator<String>() {\n\t\t public int compare(String s1, String s2) {\n\t\t if (s1.length() < s2.length())\n\t\t return -1;\n\t\t if (s1.length() > s2.length())\n\t\t return 1;\n\t\t return 0;\n\t\t }\n\t\t});\n\t\t//ou com lambda\n\t\ttexto.sort((s1, s2) -> {\n\t\t if (s1.length() < s2.length())\n\t\t return -1;\n\t\t if (s1.length() > s2.length())\n\t\t return 1;\n\t\t return 0;\n\t\t});\n\t\t//ou\n\t\ttexto.sort((s1, s2) -> {\n\t\t return Integer.compare(s1.length(), s2.length());\n\t\t});\n\t\t//ou como há apenas um único statement, podemos remover as chaves\n\t\ttexto.sort((s1, s2) -> Integer.compare(s1.length(), s2.length()));\n\t}", "public void mo38117a() {\n }", "void mo57277b();", "public static void main(String[] args) {\n version1WhileLoop();\n version1DoWhileLoop();\n version1ForLoop();\n version2ForLoop();\n version3ForLoop();\n }", "public abstract boolean mo2163j();", "public static void main(String[] args) throws Exception {\n\t\t\t\t\t\t\n\t\t\t\t\n\t\t\t}", "private NativeSupport() {\n\t}", "private static IRIProvider makeProviderJDK() { return new IRIProviderJDK(); }", "public void mo21785J() {\n }", "@Override\n public void func_104112_b() {\n \n }", "public static void generateCode()\n {\n \n }", "private UsingSwig() {\n\t}", "public static void main(String[] args) {\n\t\tlanceur8();\n\t}", "void mo1941j();", "public abstract void mo2624j();", "private final boolean updateState(java.lang.Object r7, java.lang.Object r8) {\n /*\n // Method dump skipped, instructions count: 101\n */\n throw new UnsupportedOperationException(\"Method not decompiled: kotlinx.coroutines.flow.StateFlowImpl.updateState(java.lang.Object, java.lang.Object):boolean\");\n }", "void mo72113b();", "static void feladat7() {\n\t}", "void mo28306a();", "private static void cajas() {\n\t\t\n\t}", "private void habilitar() {\n throw new UnsupportedOperationException(\"Not supported yet.\"); //To change body of generated methods, choose Tools | Templates.\n }", "public static void main(String[] args) {\n\n\t\tUnaryOperator<Integer> func=x->x*7;\t\t\n\t\tint num=func.apply(10);\n\t\tSystem.out.println(num);\n\t\t\n\t\tFunction<Integer, Integer> func1=x->x*10;\n\t\tSystem.out.println(func1.apply(10));\n\t\t\n\t\tList<String> langList=new ArrayList<String>();\n\t\tlangList.add(\"Java\");\n\t\tlangList.add(\"Ruby\");\n\t\tlangList.add(\"Python\");\n\t\t\n\t\tSystem.out.println(langList);\n\t\t\n\t\tlangList.replaceAll(ele -> ele +\" Deeps\");\n\t\tSystem.out.println(langList);\n\t}", "void mo57278c();", "interface DefaultMethod extends SingleMethod {\r\n\tdefault public void myMethod() {\r\n\t\tSystem.out.println(\"from Java 1.8 version can have method with a body\");\r\n}\r\n}", "void mo80457c();", "public void mo21792Q() {\n }", "public static void main(String[] args) {\n \n }", "public static void main(String[] args) {\n \n }", "public static void main(String[] args) {\n \n }", "public static void main(String[] args) {\n \n }", "public static void main(String[] args) {\n \n }", "public static void main(String[] args) {\n \n }", "public void mo21787L() {\n }", "public void method_4270() {}", "static void feladat8() {\n\t}", "public static void main() {\n \n }", "private void level6() {\n }", "void mo57275a();", "void mo80452a();", "private Quantify()\n {\n throw new UnsupportedOperationException(\"Instantiation of utility classes is not supported.\");\n }", "public void m9741j() throws cf {\r\n }", "@Before\n public void setUp() {\n Assume.assumeThat(JavaVersion.getMajorVersion(), Matchers.lessThanOrEqualTo(8));\n }", "private stendhal() {\n\t}", "void mo41083a();", "public static void main(String[] args) {\n\t\tisPolindrom(\"abcd\");\r\n\t\tfibJava8(2);\r\n\t\tfactJava8(5);\r\n\t}", "void m8368b();", "@Override\n\tpublic void implementionSeven(String[] args) throws Exception {\n\n\t}", "public void mo6081a() {\n }", "java.lang.String getS8();", "public void mo21879u() {\n }", "void mo119582b();", "public abstract void mo27385c();", "public abstract void mo70713b();", "public void mo21781F() {\n }", "public interface AnonymousClass1lE {\n void A7X(String str, String str2, String str3);\n\n void A7Z(String str, String str2, @Nullable Map<String, String> map);\n\n void A7b(String str, String str2, Throwable th, @Nullable Map<String, String> map);\n\n void A7d(String str, String str2, @Nullable Map<String, String> map);\n\n void A7f(String str, String str2);\n\n void A8G(String str, String str2, boolean z);\n\n boolean A9J(String str);\n}", "void mo41086b();", "public static void main(String[] args) {\n\n // Creating object of class in main() method\n JEP306_StritfpSample t = new JEP306_StritfpSample();\n\n // Here we have error of putting strictfp and\n // error is not found public static void main method\n System.out.println(t.sum());\n }", "public static void main(String[] args) {\n \n \n }", "public static void main(String[] args) {\n \n \n }", "private void kk12() {\n\n\t}", "public static void main(String[] args) {\n //Ersetzt jetzt mal unseren Parser, Stell Dir vor\n // das Ding liest das Beispiel da oben ^^.\n final StatementNode[] statementNodes = readStatements();\n \n //Zustände:\n // - FillSymbolTable (was für Symbole [variablen, ...] gibt es)\n // - TypInferenz (Was für Typen haben die Expressions und sind die eingaben semantisch korrekt)\n // - CodeGenerierung oder Ausführung (ersetzen wir mit \"schreibe die Werte aller Variablen nach Ende der Ausführung\")\n \n \n final SymbolTabelle symbolTabelle = new SymbolTabelle();\n //IDEE 2:\n //Ich gebe Statements und Expressions nur eine Methode mit Visitor als Callback\n final StatementVisitorSymbolTabelle statementVisitorSymbolTabelle = new StatementVisitorSymbolTabelle(symbolTabelle);\n for(StatementNode statementNode : statementNodes) {\n statementNode.accept(statementVisitorSymbolTabelle);\n }\n \n final StatementVisitorTypInferenz statementVisitorTypInferenz = new StatementVisitorTypInferenz(symbolTabelle);\n for(StatementNode statementNode : statementNodes) {\n statementNode.accept(statementVisitorTypInferenz);\n }\n \n PseudoLaufContext laufContext = new PseudoLaufContext();\n final StatementVisitorCodeGen statementVisitorCodeGen = new StatementVisitorCodeGen(laufContext);\n for(StatementNode statementNode : statementNodes) {\n statementNode.accept(statementVisitorCodeGen);\n }\n \n laufContext.druckeVariablen();\n \n //Zusammenfassung:\n //Reduktion des Problems darauf, den Code nur noch von einem Abhängig zu machen\n //Jetzt nur noch abhängig vom Typ des Statements\n \n \n //Problem hierbei:\n //Ich muss selbst angeben, in welchem Zustand ich bin\n //Code-Duplizierung\n }", "public static void main(String[] args) {\n \n \n \n\t}", "private void someUtilityMethod() {\n }", "private void someUtilityMethod() {\n }", "void mo80455b();", "interface C15937b {\n /* renamed from: a */\n void mo13368a();\n\n /* renamed from: a */\n void mo13369a(int i, int i2, int i3, boolean z);\n\n /* renamed from: a */\n void mo13370a(int i, int i2, List<C15929a> list) throws IOException;\n\n /* renamed from: a */\n void mo13371a(int i, long j);\n\n /* renamed from: a */\n void mo13372a(int i, ErrorCode errorCode);\n\n /* renamed from: a */\n void mo13373a(int i, ErrorCode errorCode, ByteString byteString);\n\n /* renamed from: a */\n void mo13374a(boolean z, int i, int i2);\n\n /* renamed from: a */\n void mo13375a(boolean z, int i, int i2, List<C15929a> list);\n\n /* renamed from: a */\n void mo13376a(boolean z, int i, BufferedSource bufferedSource, int i2) throws IOException;\n\n /* renamed from: a */\n void mo13377a(boolean z, C15943j c15943j);\n }", "void mo88521a();", "void mo20141a();", "public static void main(String[] args) {\n \n \n \n \n }", "public final void mo51373a() {\n }", "private final boolean shouldProposeGenerics(IJavaProject project) {\n\t\treturn true;\n\t\t/*\n\t\tString sourceVersion;\n\t\tif (project != null)\n\t\t\tsourceVersion= project.getOption(JavaCore.COMPILER_SOURCE, true);\n\t\telse\n\t\t\tsourceVersion= JavaCore.getOption(JavaCore.COMPILER_SOURCE);\n\n\t\treturn sourceVersion != null && JavaCore.VERSION_1_5.compareTo(sourceVersion) <= 0;\n\t\t*/\n\t}", "public static void main(String[] args) {\n way8();\n }", "private JacobUtils() {}", "void mo60893b();", "public interface JavaCode {\n\n /**\n * Get an unique identification code for an object\n * TODO: This method is not reliable as hash codes are not unique, should use an UUID generator singleton instead.\n *\n * @param obj the object\n * @return the unique identification code\n */\n static int getUniqueID(Object obj) {\n return obj.hashCode();\n }\n\n /**\n * Compiles this code. If an object implements both {@link JavaCode}\n * and {@link JavaExpression}, only one of this method and\n * {@link JavaExpression#compileExpression(Subroutine, JavaScope)} should be called.\n *\n * @param subroutine the subroutine which this code belongs to\n * @param parent the parent scope of this code\n * @throws JTAException if an error occurs\n */\n void compileCode(Subroutine subroutine, JavaScope parent) throws JTAException;\n}", "public void mo8738a() {\n }", "public void mo1972o() throws cf {\r\n }", "public static void main (String[] args) {import java.util.*;%>\n//&&&staticSymbol&&&<%import org.eclipse.emf.codegen.ecore.genmodel.*;%>\n//&&&staticSymbol&&&<%\n\n/**\n * Copyright (c) 2002-2010 IBM Corporation and others.\n * All rights reserved. This program and the accompanying materials\n * are made available under the terms of the Eclipse Public License v1.0\n * which accompanies this distribution, and is available at\n * http://www.eclipse.org/legal/epl-v10.html\n *\n * Contributors:\n * IBM - Initial API and implementation\n */\n\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nGenPackage genPackage = (GenPackage)((Object[])argument)[0]; GenModel genModel=genPackage.getGenModel(); /* Trick to import java.util.* without warnings */Iterator.class.getName();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nboolean isInterface = Boolean.TRUE.equals(((Object[])argument)[1]); boolean isImplementation = Boolean.TRUE.equals(((Object[])argument)[2]);\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nString publicStaticFinalFlag = isImplementation ? \"public static final \" : \"\";\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%include(\"../Header.javajetinc\");%>\n//&&&staticSymbol&&&<%\nif (isInterface || genModel.isSuppressInterfaces()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&package <%\n//&&&staticSymbol&&&=genPackage.getReflectionPackageName()\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&<%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&package <%\n//&&&staticSymbol&&&=genPackage.getClassPackageName()\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\nif (isImplementation) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.addPseudoImport(\"org.eclipse.emf.ecore.impl.MinimalEObjectImpl.Container\");\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.addPseudoImport(\"org.eclipse.emf.ecore.impl.MinimalEObjectImpl.Container.Dynamic\");\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.addImport(\"org.eclipse.emf.ecore.EClass\");\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.addImport(\"org.eclipse.emf.ecore.EObject\");\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (!genPackage.hasJavaLangConflict() && !genPackage.hasInterfaceImplConflict() && !genPackage.getClassPackageName().equals(genPackage.getInterfacePackageName())) genModel.addImport(genPackage.getInterfacePackageName() + \".*\");\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.markImportLocation(stringBuffer);\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\nif (isInterface) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&/**\n//&&&staticSymbol&&& * <!-- begin-user-doc -->\n//&&&staticSymbol&&& * The <b>Factory</b> for the model.\n//&&&staticSymbol&&& * It provides a create method for each non-abstract class of the model.\n//&&&staticSymbol&&& * <!-- end-user-doc -->\n//&&&staticSymbol&&&<%\nif (!genModel.isSuppressEMFMetaData()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& * @see <%\n//&&&staticSymbol&&&=genPackage.getQualifiedPackageInterfaceName()\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& * @generated\n//&&&staticSymbol&&& */\n//&&&staticSymbol&&&<%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&/**\n//&&&staticSymbol&&& * <!-- begin-user-doc -->\n//&&&staticSymbol&&& * An implementation of the model <b>Factory</b>.\n//&&&staticSymbol&&& * <!-- end-user-doc -->\n//&&&staticSymbol&&& * @generated\n//&&&staticSymbol&&& */\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (isImplementation) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&public class <%\n//&&&staticSymbol&&&=genPackage.getFactoryClassName()\n//&&&staticSymbol&&&%> extends <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.impl.EFactoryImpl\")\n//&&&staticSymbol&&&%><%\nif (!genModel.isSuppressInterfaces()) {\n//&&&staticSymbol&&&%> implements <%\n//&&&staticSymbol&&&=genPackage.getImportedFactoryInterfaceName()\n//&&&staticSymbol&&&%><%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&public interface <%\n//&&&staticSymbol&&&=genPackage.getFactoryInterfaceName()\n//&&&staticSymbol&&&%><%\nif (!genModel.isSuppressEMFMetaData()) {\n//&&&staticSymbol&&&%> extends <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EFactory\")\n//&&&staticSymbol&&&%><%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&{\n//&&&staticSymbol&&&<%\nif (genModel.hasCopyrightField()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=publicStaticFinalFlag\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.String\")\n//&&&staticSymbol&&&%> copyright = <%\n//&&&staticSymbol&&&=genModel.getCopyrightFieldLiteral()\n//&&&staticSymbol&&&%>;<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (isImplementation && (genModel.isSuppressEMFMetaData() || genModel.isSuppressInterfaces())) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * The singleton instance of the factory.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=publicStaticFinalFlag\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genPackage.getFactoryClassName()\n//&&&staticSymbol&&&%> eINSTANCE = init();\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (isInterface && genModel.isSuppressEMFMetaData()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * The singleton instance of the factory.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=publicStaticFinalFlag\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genPackage.getFactoryInterfaceName()\n//&&&staticSymbol&&&%> INSTANCE = <%\n//&&&staticSymbol&&&=genPackage.getQualifiedFactoryClassName()\n//&&&staticSymbol&&&%>.eINSTANCE;\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n} else if (isInterface && !genModel.isSuppressInterfaces()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * The singleton instance of the factory.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=publicStaticFinalFlag\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genPackage.getFactoryInterfaceName()\n//&&&staticSymbol&&&%> eINSTANCE = <%\n//&&&staticSymbol&&&=genPackage.getQualifiedFactoryClassName()\n//&&&staticSymbol&&&%>.init();\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (isImplementation) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Creates the default factory implementation.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&<%\nString factoryType = genModel.isSuppressEMFMetaData() ? genPackage.getFactoryClassName() : genPackage.getImportedFactoryInterfaceName();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic static <%\n//&&&staticSymbol&&&=factoryType\n//&&&staticSymbol&&&%> init()\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\ttry\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\t<%\n//&&&staticSymbol&&&=factoryType\n//&&&staticSymbol&&&%> the<%\n//&&&staticSymbol&&&=genPackage.getFactoryName()\n//&&&staticSymbol&&&%> = (<%\n//&&&staticSymbol&&&=factoryType\n//&&&staticSymbol&&&%>)<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EPackage\")\n//&&&staticSymbol&&&%>.Registry.INSTANCE.getEFactory(<%\n//&&&staticSymbol&&&=genPackage.getPackageInterfaceName()\n//&&&staticSymbol&&&%>.eNS_URI);\n//&&&staticSymbol&&&\t\t\tif (the<%\n//&&&staticSymbol&&&=genPackage.getFactoryName()\n//&&&staticSymbol&&&%> != null)\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&&\t\t\t\treturn the<%\n//&&&staticSymbol&&&=genPackage.getFactoryName()\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\tcatch (Exception exception)\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\t<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.plugin.EcorePlugin\")\n//&&&staticSymbol&&&%>.INSTANCE.log(exception);\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\treturn new <%\n//&&&staticSymbol&&&=genPackage.getImportedFactoryClassName()\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Creates an instance of the factory.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\tpublic <%\n//&&&staticSymbol&&&=genPackage.getFactoryClassName()\n//&&&staticSymbol&&&%>()\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\tsuper();\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useClassOverrideAnnotation()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@Override\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic EObject create(EClass eClass)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\tswitch (eClass.getClassifierID())\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&<%\nfor (GenClass genClass : genPackage.getGenClasses()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (!genClass.isAbstract()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tcase <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%>.<%\n//&&&staticSymbol&&&=genClass.getClassifierID()\n//&&&staticSymbol&&&%>: return <%\n//&&&staticSymbol&&&*%%storeSymbol%%*0\n//&&&staticSymbol&&&%>create<%\n//&&&staticSymbol&&&=genClass.getName()\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tdefault:\n//&&&staticSymbol&&&\t\t\t\tthrow new IllegalArgumentException(\"The class '\" + eClass.getName() + \"' is not a valid classifier\");<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(2)\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\nif (!genPackage.getAllGenDataTypes().isEmpty()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useClassOverrideAnnotation()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@Override\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic Object createFromString(<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EDataType\")\n//&&&staticSymbol&&&%> eDataType, String initialValue)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\tswitch (eDataType.getClassifierID())\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&<%\nfor (GenDataType genDataType : genPackage.getAllGenDataTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isSerializable()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tcase <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%>.<%\n//&&&staticSymbol&&&=genDataType.getClassifierID()\n//&&&staticSymbol&&&%>:\n//&&&staticSymbol&&&\t\t\t\treturn create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>FromString(eDataType, initialValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tdefault:\n//&&&staticSymbol&&&\t\t\t\tthrow new IllegalArgumentException(\"The datatype '\" + eDataType.getName() + \"' is not a valid classifier\");<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(2)\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useClassOverrideAnnotation()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@Override\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic String convertToString(<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EDataType\")\n//&&&staticSymbol&&&%> eDataType, Object instanceValue)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\tswitch (eDataType.getClassifierID())\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&<%\nfor (GenDataType genDataType : genPackage.getAllGenDataTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isSerializable()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tcase <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%>.<%\n//&&&staticSymbol&&&=genDataType.getClassifierID()\n//&&&staticSymbol&&&%>:\n//&&&staticSymbol&&&\t\t\t\treturn convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>ToString(eDataType, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tdefault:\n//&&&staticSymbol&&&\t\t\t\tthrow new IllegalArgumentException(\"The datatype '\" + eDataType.getName() + \"' is not a valid classifier\");<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(2)\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nfor (GenClass genClass : genPackage.getGenClasses()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (!genClass.isAbstract()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\tpublic <%\n//&&&staticSymbol&&&=genClass.getTypeParameters()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getImportedInterfaceName()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getInterfaceTypeArguments()\n//&&&staticSymbol&&&%> create<%\n//&&&staticSymbol&&&=genClass.getName()\n//&&&staticSymbol&&&%>()\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&& <%\nif (genClass.isDynamic()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genClass.getImportedInterfaceName()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getInterfaceTypeArguments()\n//&&&staticSymbol&&&%> <%\n//&&&staticSymbol&&&=genClass.getSafeUncapName()\n//&&&staticSymbol&&&%> = <%\n//&&&staticSymbol&&&=genClass.getCastFromEObject()\n//&&&staticSymbol&&&%>super.create(<%\n//&&&staticSymbol&&&=genClass.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genClass.getImportedClassName()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getClassTypeArguments()\n//&&&staticSymbol&&&%> <%\n//&&&staticSymbol&&&=genClass.getSafeUncapName()\n//&&&staticSymbol&&&%> = new <%\n//&&&staticSymbol&&&=genClass.getImportedClassName()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getClassTypeArguments()\n//&&&staticSymbol&&&%>()<%\nif (genModel.isSuppressInterfaces() && !genPackage.getReflectionPackageName().equals(genPackage.getInterfacePackageName())) {\n//&&&staticSymbol&&&%>{}<%\n}\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genClass.getSafeUncapName()\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nfor (GenDataType genDataType : genPackage.getAllGenDataTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isSerializable()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (genPackage.isDataTypeConverters() || genDataType.hasCreatorBody()) { String eDataType = genDataType.getQualifiedClassifierAccessor();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useGenerics() && genDataType.isUncheckedCast() && !genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@SuppressWarnings(\"unchecked\")\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic <%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedInstanceClassName()\n//&&&staticSymbol&&&%> create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(<%\nif (genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>final <%\n}\n//&&&staticSymbol&&&%>String <%\nif (genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>it<%\n} else {\n//&&&staticSymbol&&&%>literal<%\n}\n//&&&staticSymbol&&&%>)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&& <%\nif (genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getCreatorBody(genModel.getIndentation(stringBuffer))\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType instanceof GenEnum) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getImportedInstanceClassName()\n//&&&staticSymbol&&&%> result = <%\n//&&&staticSymbol&&&=genDataType.getImportedInstanceClassName()\n//&&&staticSymbol&&&%>.get(literal);\n//&&&staticSymbol&&&\t\tif (result == null) throw new IllegalArgumentException(\"The value '\" + literal + \"' is not a valid enumerator of '\" + <%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>.getName() + \"'\");<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(2)\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(3)\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn result;\n//&&&staticSymbol&&& <%\n} else if (genDataType.getBaseType() != null) { GenDataType genBaseType = genDataType.getBaseType(); boolean isPrimitiveConversion = !genDataType.isPrimitiveType() && genBaseType.isPrimitiveType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genBaseType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (isPrimitiveConversion && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn new <%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(create<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(literal));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn create<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genBaseType.getGenPackage().isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (isPrimitiveConversion && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn new <%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.create<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(literal));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.create<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getItemType() != null) { GenDataType genItemType = genDataType.getItemType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (literal == null) return null;\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedInstanceClassName()\n//&&&staticSymbol&&&%> result = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.ArrayList\")\n//&&&staticSymbol&&&%><%\nif (genModel.useGenerics()) {\n//&&&staticSymbol&&&%><<%=genItemType.getObjectType().getImportedParameterizedInstanceClassName()%>><%\n}\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\nif (genModel.getRuntimeVersion().getValue() < GenRuntimeVersion.EMF26_VALUE) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.StringTokenizer\")\n//&&&staticSymbol&&&%> stringTokenizer = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.StringTokenizer\")\n//&&&staticSymbol&&&%>(literal); stringTokenizer.hasMoreTokens(); )\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (String item : split(literal))\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genModel.getRuntimeVersion().getValue() < GenRuntimeVersion.EMF26_VALUE) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString item = stringTokenizer.nextToken();\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) { genItemType = genItemType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(create<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>(item));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(create<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, item));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage().isDataTypeConverters()) { genItemType = genItemType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(<%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.create<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>(item));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(<%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, item));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\treturn result;\n//&&&staticSymbol&&& <%\n} else if (!genDataType.getMemberTypes().isEmpty()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (literal == null) return <%\n//&&&staticSymbol&&&=genDataType.getStaticValue(null)\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getImportedInstanceClassName()\n//&&&staticSymbol&&&%> result = <%\n//&&&staticSymbol&&&=genDataType.getStaticValue(null)\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&\t\tRuntimeException exception = null;\n//&&&staticSymbol&&& <%\nfor (GenDataType genMemberType : genDataType.getMemberTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\ttry\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) { if (!genDataType.isPrimitiveType()) genMemberType = genMemberType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = create<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(literal);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = (<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)create<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) { if (!genDataType.isPrimitiveType()) genMemberType = genMemberType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.create<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(literal);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = (<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tif (<%\nif (!genDataType.isPrimitiveType()) {\n//&&&staticSymbol&&&%>result != null && <%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.util.Diagnostician\")\n//&&&staticSymbol&&&%>.INSTANCE.validate(<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>, <%\nif (genDataType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>new <%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(result)<%\n} else {\n//&&&staticSymbol&&&%>result<%\n}\n//&&&staticSymbol&&&%>, null, null))\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&&\t\t\t\treturn result;\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\tcatch (RuntimeException e)\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\texception = e;\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (<%\nif (!genDataType.isPrimitiveType()) {\n//&&&staticSymbol&&&%>result != null || <%\n}\n//&&&staticSymbol&&&%>exception == null) return result;\n//&&&staticSymbol&&& \n//&&&staticSymbol&&&\t\tthrow exception;\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genModel.useGenerics() && (genDataType.isArrayType() || !genDataType.getEcoreDataType().getETypeParameters().isEmpty() || genDataType.getEcoreDataType().getInstanceTypeName().contains(\"<\"))) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn (<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%>)super.createFromString(literal);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genDataType.isArrayType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t// TODO: implement this method\n//&&&staticSymbol&&&\t\t// Ensure that you remove @generated or mark it @generated NOT\n//&&&staticSymbol&&&\t\tthrow new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.UnsupportedOperationException\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\n} else if (genDataType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn ((<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)super.createFromString(<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>, literal)).<%\n//&&&staticSymbol&&&=genDataType.getPrimitiveValueFunction()\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%>super.createFromString(<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>, literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (!genPackage.isDataTypeConverters() && genModel.useGenerics() && genDataType.isUncheckedCast() && !genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@SuppressWarnings(\"unchecked\")\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic <%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%> create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EDataType\")\n//&&&staticSymbol&&&%> eDataType, String initialValue)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&& <%\nif (genDataType instanceof GenEnum) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters() || genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(initialValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=((GenEnum)genDataType).getImportedInstanceClassName()\n//&&&staticSymbol&&&%> result = <%\n//&&&staticSymbol&&&=((GenEnum)genDataType).getImportedInstanceClassName()\n//&&&staticSymbol&&&%>.get(initialValue);\n//&&&staticSymbol&&&\t\tif (result == null) throw new IllegalArgumentException(\"The value '\" + initialValue + \"' is not a valid enumerator of '\" + eDataType.getName() + \"'\");<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(2)\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(3)\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn result;\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getBaseType() != null) { GenDataType genBaseType = genDataType.getBaseType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genBaseType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.getObjectInstanceClassName().equals(genBaseType.getObjectInstanceClassName())) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%>create<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, initialValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, initialValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getItemType() != null) { GenDataType genItemType = genDataType.getItemType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(initialValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (initialValue == null) return null;\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%> result = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.ArrayList\")\n//&&&staticSymbol&&&%><%\nif (genModel.useGenerics()) {\n//&&&staticSymbol&&&%><<%=genItemType.getObjectType().getImportedParameterizedInstanceClassName()%>><%\n}\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\nif (genModel.getRuntimeVersion().getValue() < GenRuntimeVersion.EMF26_VALUE) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.StringTokenizer\")\n//&&&staticSymbol&&&%> stringTokenizer = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.StringTokenizer\")\n//&&&staticSymbol&&&%>(initialValue); stringTokenizer.hasMoreTokens(); )\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (String item : split(initialValue))\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genModel.getRuntimeVersion().getValue() < GenRuntimeVersion.EMF26_VALUE) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString item = stringTokenizer.nextToken();\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(create<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, item));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(<%\nif (!genItemType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genItemType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, item));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\treturn result;\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (!genDataType.getMemberTypes().isEmpty()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn new <%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(initialValue));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(initialValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (initialValue == null) return null;\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%> result = null;\n//&&&staticSymbol&&&\t\tRuntimeException exception = null;\n//&&&staticSymbol&&& <%\nfor (GenDataType genMemberType : genDataType.getMemberTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\ttry\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = <%\nif (!genDataType.isObjectType() && !genDataType.getObjectInstanceClassName().equals(genMemberType.getObjectInstanceClassName())) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%>create<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, initialValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, initialValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tif (result != null && <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.util.Diagnostician\")\n//&&&staticSymbol&&&%>.INSTANCE.validate(eDataType, result, null, null))\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&&\t\t\t\treturn result;\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\tcatch (RuntimeException e)\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\texception = e;\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (result != null || exception == null) return result;\n//&&&staticSymbol&&& \n//&&&staticSymbol&&&\t\tthrow exception;\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genPackage.isDataTypeConverters() || genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(initialValue);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genModel.useGenerics() && (genDataType.isArrayType() || !genDataType.getEcoreDataType().getETypeParameters().isEmpty() || genDataType.getEcoreDataType().getInstanceTypeName().contains(\"<\"))) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%>super.createFromString(initialValue);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genDataType.isArrayType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t// TODO: implement this method\n//&&&staticSymbol&&&\t\t// Ensure that you remove @generated or mark it @generated NOT\n//&&&staticSymbol&&&\t\tthrow new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.UnsupportedOperationException\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%>super.createFromString(eDataType, initialValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\nif (genPackage.isDataTypeConverters() || genDataType.hasConverterBody()) { String eDataType = genDataType.getQualifiedClassifierAccessor();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\tpublic String convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(<%\nif (genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>final <%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genDataType.getImportedBoundedWildcardInstanceClassName()\n//&&&staticSymbol&&&%> <%\nif (genDataType.hasConverterBody()) {\n//&&&staticSymbol&&&%>it<%\n} else {\n//&&&staticSymbol&&&%>instanceValue<%\n}\n//&&&staticSymbol&&&%>)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&& <%\nif (genDataType.hasConverterBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getConverterBody(genModel.getIndentation(stringBuffer))\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType instanceof GenEnum) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn instanceValue == null ? null : instanceValue.toString();\n//&&&staticSymbol&&& <%\n} else if (genDataType.getBaseType() != null) { GenDataType genBaseType = genDataType.getBaseType(); boolean isPrimitiveConversion = !genDataType.isPrimitiveType() && genBaseType.isPrimitiveType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genBaseType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (isPrimitiveConversion) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn instanceValue == null ? null : convert<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(instanceValue<%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>.<%\n//&&&staticSymbol&&&=genBaseType.getPrimitiveValueFunction()\n//&&&staticSymbol&&&%>()<%\n}\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genBaseType.getGenPackage().isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedFactoryInstanceAccessor()\n//&&&staticSymbol&&&%>.convert<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getItemType() != null) { GenDataType genItemType = genDataType.getItemType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (instanceValue == null) return null;\n//&&&staticSymbol&&&\t\tif (instanceValue.isEmpty()) return \"\";\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.StringBuffer\")\n//&&&staticSymbol&&&%> result = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.StringBuffer\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\nString item; if (!genModel.useGenerics()) { item = \"i.next()\"; \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.Iterator\")\n//&&&staticSymbol&&&%> i = instanceValue.iterator(); i.hasNext(); )\n//&&&staticSymbol&&& <%\n} else { item = \"item\";\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.Object\")\n//&&&staticSymbol&&&%> item : instanceValue)\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) { genItemType = genItemType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(convert<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genItemType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(convert<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage().isDataTypeConverters()) { genItemType = genItemType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(<%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convert<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genItemType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(<%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(' ');\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\treturn result.substring(0, result.length() - 1);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.getMemberTypes().isEmpty()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (!genDataType.isPrimitiveType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (instanceValue == null) return null;\n//&&&staticSymbol&&& <%\nfor (GenDataType genMemberType : genDataType.getMemberTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>.isInstance(instanceValue))\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\ttry\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genMemberType.getQualifiedInstanceClassName().equals(genDataType.getQualifiedInstanceClassName())) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n} else if (genMemberType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(((<%\n//&&&staticSymbol&&&=genMemberType.getObjectType().getImportedInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue).<%\n//&&&staticSymbol&&&=genMemberType.getPrimitiveValueFunction()\n//&&&staticSymbol&&&%>());\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genMemberType.getObjectType().getImportedBoundedWildcardInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage().isDataTypeConverters()) { genMemberType = genMemberType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genMemberType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tif (value != null) return value;\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t\tcatch (Exception e)\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&&\t\t\t\t// Keep trying other member types until all have failed.\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nfor (GenDataType genMemberType : genDataType.getMemberTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\ttry\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>new <%\n//&&&staticSymbol&&&=genMemberType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(instanceValue)<%\n} else {\n//&&&staticSymbol&&&%>instanceValue<%\n}\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage().isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString value = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString value = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>new <%\n//&&&staticSymbol&&&=genMemberType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(instanceValue)<%\n} else {\n//&&&staticSymbol&&&%>instanceValue<%\n}\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tif (value != null) return value;\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\tcatch (Exception e)\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\t// Keep trying other member types until all have failed.\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tthrow new IllegalArgumentException(\"Invalid value: '\"+instanceValue+\"' for datatype :\"+<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>.getName());\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genModel.useGenerics() && (genDataType.isArrayType() || !genDataType.getEcoreDataType().getETypeParameters().isEmpty() || genDataType.getEcoreDataType().getInstanceTypeName().contains(\"<\"))) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn super.convertToString(instanceValue);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genDataType.isArrayType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t// TODO: implement this method\n//&&&staticSymbol&&&\t\t// Ensure that you remove @generated or mark it @generated NOT\n//&&&staticSymbol&&&\t\tthrow new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.UnsupportedOperationException\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\n} else if (genDataType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn super.convertToString(<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>, new <%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(instanceValue));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn super.convertToString(<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useGenerics() && (genDataType.getItemType() != null || genDataType.isUncheckedCast()) && (genPackage.isDataTypeConverters() || genDataType.hasCreatorBody())) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@SuppressWarnings(\"unchecked\")\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic String convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EDataType\")\n//&&&staticSymbol&&&%> eDataType, Object instanceValue)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&& <%\nif (genDataType instanceof GenEnum) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters() || genDataType.hasConverterBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genDataType.getImportedInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn instanceValue == null ? null : instanceValue.toString();\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getBaseType() != null) { GenDataType genBaseType = genDataType.getBaseType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genBaseType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getItemType() != null) { GenDataType genItemType = genDataType.getItemType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters() || genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genDataType.getImportedBoundedWildcardInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue);\n//&&&staticSymbol&&& <%\n} else { final String singleWildcard = genModel.useGenerics() ? \"<?>\" : \"\";\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (instanceValue == null) return null;\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.List\")\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=singleWildcard\n//&&&staticSymbol&&&%> list = (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.List\")\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=singleWildcard\n//&&&staticSymbol&&&%>)instanceValue;\n//&&&staticSymbol&&&\t\tif (list.isEmpty()) return \"\";\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.StringBuffer\")\n//&&&staticSymbol&&&%> result = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.StringBuffer\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\nString item; if (!genModel.useGenerics()) { item = \"i.next()\"; \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.Iterator\")\n//&&&staticSymbol&&&%> i = list.iterator(); i.hasNext(); )\n//&&&staticSymbol&&& <%\n} else { item = \"item\";\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.Object\")\n//&&&staticSymbol&&&%> item : list)\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(convert<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(<%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(' ');\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\treturn result.substring(0, result.length() - 1);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (!genDataType.getMemberTypes().isEmpty()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters() || genDataType.hasConverterBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isPrimitiveType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn instanceValue == null ? null : convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(((<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue)<%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>.<%\n//&&&staticSymbol&&&=genDataType.getPrimitiveValueFunction()\n//&&&staticSymbol&&&%>()<%\n}\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (instanceValue == null) return null;\n//&&&staticSymbol&&& <%\nfor (GenDataType genMemberType : genDataType.getMemberTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>.isInstance(instanceValue))\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\ttry\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tif (value != null) return value;\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t\tcatch (Exception e)\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&&\t\t\t\t// Keep trying other member types until all have failed.\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tthrow new IllegalArgumentException(\"Invalid value: '\"+instanceValue+\"' for datatype :\"+eDataType.getName());\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genPackage.isDataTypeConverters() || genDataType.hasConverterBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isPrimitiveType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn instanceValue == null ? null : convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(<%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>(<%\n}\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue<%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>).<%\n//&&&staticSymbol&&&=genDataType.getPrimitiveValueFunction()\n//&&&staticSymbol&&&%>()<%\n}\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genDataType.getImportedBoundedWildcardInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genModel.useGenerics() && (genDataType.isArrayType() || !genDataType.getEcoreDataType().getETypeParameters().isEmpty() || genDataType.getEcoreDataType().getInstanceTypeName().contains(\"<\"))) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn super.convertToString(instanceValue);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genDataType.isArrayType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t// TODO: implement this method\n//&&&staticSymbol&&&\t\t// Ensure that you remove @generated or mark it @generated NOT\n//&&&staticSymbol&&&\t\tthrow new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.UnsupportedOperationException\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn super.convertToString(eDataType, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nfor (GenClass genClass : genPackage.getGenClasses()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genClass.hasFactoryInterfaceCreateMethod()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Returns a new object of class '<em><%\n//&&&staticSymbol&&&=genClass.getFormattedName()\n//&&&staticSymbol&&&%></em>'.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @return a new object of class '<em><%\n//&&&staticSymbol&&&=genClass.getFormattedName()\n//&&&staticSymbol&&&%></em>'.\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=genClass.getTypeParameters()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getImportedInterfaceName()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getInterfaceTypeArguments()\n//&&&staticSymbol&&&%> create<%\n//&&&staticSymbol&&&=genClass.getName()\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&&\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nfor (GenDataType genDataType : genPackage.getAllGenDataTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isSerializable()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Returns an instance of data type '<em><%\n//&&&staticSymbol&&&=genDataType.getFormattedName()\n//&&&staticSymbol&&&%></em>' corresponding the given literal.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @param literal a literal of the data type.\n//&&&staticSymbol&&&\t * @return a new instance value of the data type.\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedInstanceClassName()\n//&&&staticSymbol&&&%> create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(String literal);\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Returns a literal representation of an instance of data type '<em><%\n//&&&staticSymbol&&&=genDataType.getFormattedName()\n//&&&staticSymbol&&&%></em>'.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @param instanceValue an instance value of the data type.\n//&&&staticSymbol&&&\t * @return a literal representation of the instance value.\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\tString convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getImportedBoundedWildcardInstanceClassName()\n//&&&staticSymbol&&&%> instanceValue);\n//&&&staticSymbol&&&\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (!isImplementation && !genModel.isSuppressEMFMetaData()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Returns the package supported by this factory.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @return the package supported by this factory.\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=genPackage.getPackageInterfaceName()\n//&&&staticSymbol&&&%> get<%\n//&&&staticSymbol&&&=genPackage.getBasicPackageName()\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n} else if (isImplementation) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\tpublic <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%> get<%\n//&&&staticSymbol&&&=genPackage.getBasicPackageName()\n//&&&staticSymbol&&&%>()\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\treturn (<%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%>)getEPackage();\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @deprecated\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useClassOverrideAnnotation()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@Deprecated\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic static <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%> getPackage()\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%>.eINSTANCE;\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&} //<%\n//&&&staticSymbol&&&*%%storeSymbol%%*1\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.emitSortedImports();\n//&&&staticSymbol&&&%>\n\n}", "static void feladat9() {\n\t}", "@Override\n public boolean isVersionCodeCompatible(int version) {\n return true;\n }", "public void mo4359a() {\n }", "private static List<String> getJavasSourceCodeFiels(Map<String,Object> map){\r\n \t\t\r\n \t\t\r\n \t\tSystem.out.println(\"............\");\r\n \t\tLinkedList<String> list = new LinkedList<String>();\r\n \t\tfor(String key : map.keySet()){\r\n \t\t\tObject o = map.get(key);\r\n \r\n \t\t\t//package...\r\n \t\t\tif(o instanceof IPackageFragment){\r\n \t\t\t\t//System.out.println(\"Package --> \" + key);\r\n \t\t\t\tkey = key.substring(0,key.indexOf('[')).trim();\r\n \t\t\t\tkey = PACKAGE + \"(\" + key + \")\";\r\n \t\t\t\tlist.add(key);\r\n \t\t\t}\r\n \t\t\t//class...\r\n \t\t\tif(o instanceof ICompilationUnit){\r\n \t\t\t\t//System.out.println(\"Class --> \" + key);\r\n \t\t\t\tString classname = key.substring(0,key.indexOf('[')).trim();\r\n \t\t\t\tString packagename = key.substring(key.indexOf(PACKAGE),key.indexOf('\\n',key.indexOf(PACKAGE)));\r\n \t\t\t\tkey = CLASS_WITH_MEMBERS + \"(\" + packagename + \",\" + classname + \")\";\r\n \t\t\t\tlist.add(key);\r\n \t\t\t}//method\r\n \t\t\tif(o instanceof IMethod){\r\n \t\t\t\tSystem.out.println(\"Methode --> \" + key);\r\n \t\t\t\tkey = METHOD + \"(\" + getQueryFromMethod((IMethod)o) + \")\";\r\n \t\t\t\tlist.add(key);\r\n \t\t\t}\r\n \t\t\t\r\n \t\t\tif(o instanceof IField){\r\n \t\t\t\tSystem.out.println(\"Attribut --> \" + key);\r\n \t\t\t\tkey = FIELD + \"(\" + getQueryFromField((IField)o) + \")\";\r\n \t\t\t\tlist.add(key);\r\n \t\t\t}\r\n \t\t}\r\n \t\treturn list;\r\n \t\t\r\n \t\t\r\n \t\t/*\r\n \t\tfor(String key : map.keySet()){\r\n \t\t\tObject o = map.get(key);\r\n \t\t\t//if(o instanceof ISourceAttribute)\r\n \t\t\t\t//System.out.println(\"attribute\");\r\n \t\t\t//if(o instanceof ISourceMethod)\r\n \t\t\t\t//System.out.println(\"methode\");\r\n \t\t\tif(o instanceof IPackageFragment) \r\n \t\t\t\tSystem.out.println(\"Package\");\r\n \t\t\tif(o instanceof ICompilationUnit)\r\n \t\t\t\tSystem.out.println(\"sour code file\");\r\n \t\t\t\t\r\n \t\t\t//\"oldquery or class('voller packagename', klassenname)\"\r\n \t\t\t\t\r\n \t\t\t\t\r\n \t\t\tif(o instanceof IField)\r\n \t\t\t\tSystem.out.println(\"Attribut\");\r\n \t\t\tif(o instanceof IType)\r\n \t\t\t\tSystem.out.println(\"classe also class ... in einem file\");\r\n \t\t\tif(o instanceof IMethod)\r\n \t\t\t\tSystem.out.println(\"Methode\");\r\n \t\t\tif(o instanceof IPackageFragmentRoot) \r\n \t\t\t\tSystem.out.println(\"jar package / src Ordner\");\r\n \t\t\tif(o instanceof IProject)\r\n \t\t\t\tSystem.out.println(\"Projekt Ordner\");\r\n \t\t\tif(o instanceof IClassFile)\r\n \t\t\t\tSystem.out.println(\"ClassFile\");\r\n \t\t\tif(o instanceof IAdaptable) //trieft auch auf viele ander sachen zu\r\n \t\t\t\tSystem.out.println(\"Libaraycontainer\");\r\n \t\t\tif(o instanceof IFile)\r\n \t\t\t\tSystem.out.println(\"file\"); //je nach ausgewlter ansicht knnen file auch *.java datein sein\r\n \t\t\tif(o instanceof IFolder)\r\n \t\t\t\tSystem.out.println(\"folder\");\r\n \t\t\tSystem.out.println(o.getClass());\r\n \t\t\t\r\n \t\r\n \t\t}\r\n \t\treturn null;\r\n \t\t*/\r\n \t}", "public void mo1531a() {\n }", "public void mo1976s() throws cf {\r\n }", "void mo119581a();", "static void feladat6() {\n\t}", "private void generateSolution() {\n\t\t// TODO\n\n\t}" ]
[ "0.5890391", "0.58054996", "0.57008785", "0.56167847", "0.54946315", "0.54761344", "0.524263", "0.52340496", "0.5233149", "0.52029705", "0.5160466", "0.51574665", "0.5143396", "0.5094738", "0.5084682", "0.5069909", "0.50661004", "0.50645214", "0.5064437", "0.50475377", "0.5041245", "0.5039573", "0.5037435", "0.50317824", "0.5007829", "0.500209", "0.49986184", "0.4996393", "0.49733046", "0.49654463", "0.49482828", "0.49374196", "0.49367213", "0.49362347", "0.4931423", "0.49300268", "0.49164099", "0.49096605", "0.4893169", "0.48904118", "0.4883474", "0.4883474", "0.4883474", "0.4883474", "0.4883474", "0.4883474", "0.4869394", "0.48675945", "0.4863796", "0.4849808", "0.48444158", "0.48439786", "0.48421556", "0.4838581", "0.48383453", "0.4837389", "0.4833218", "0.48310906", "0.4830076", "0.4827487", "0.481306", "0.48097232", "0.4807137", "0.48028547", "0.4801506", "0.47964317", "0.47952133", "0.479351", "0.4792214", "0.4791279", "0.47875714", "0.47851777", "0.47851777", "0.47834784", "0.47784257", "0.47747812", "0.47722042", "0.47722042", "0.47719148", "0.47705945", "0.47705132", "0.47681588", "0.47653475", "0.47629744", "0.47611335", "0.47570732", "0.47566834", "0.47548115", "0.4751401", "0.47484854", "0.47464594", "0.47460574", "0.47457317", "0.4742769", "0.47399607", "0.47344413", "0.47313395", "0.47252822", "0.47233605", "0.4721698", "0.47122636" ]
0.0
-1
write your code in Java SE 8
public static int Bricksolution(int[] H) { int i = 0; int index = 0; ArrayList indexes = new ArrayList(); do { if (H[i] <= H[i + 1]) { i++; } else { indexes.add(i); i++; } } while (i < H.length); return 0; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static void main(String[] args) {\n\t\tnew Action() {\r\n\r\n\t\t\t@Override\r\n\t\t\tpublic void execute(String content) {\r\n\t\t\t\t// TODO Auto-generated method stub\r\n\t\t\t\tSystem.out.println(content);\r\n\t\t\t}\r\n\t\t\t\r\n\t\t}.execute(\"jdk1.8之前匿名内部类实现方式\");\r\n\t\t\r\n\t\t\r\n\t\t//lambda\r\n\t\tAction login=(String content)->{\r\n\t\t\tSystem.out.println(\"jdk1.8的lambda语法实现\");\r\n\t\t};\r\n\t\tlogin.execute(\"jdk1.8的lambda语法实现\");\r\n\t\t\r\n\t}", "public static void main(String[] args) {\n\t\t\r\n\t\tnew Thread(new Runnable() {\r\n\t\t\tpublic void run() {\r\n\t\t\t\tSystem.out.println(\"Before JAVA 8, too much code for too little to do\");\r\n\t\t\t}\r\n\t\t}).start();\r\n\t\t\r\n\t\t// Java 8 way:\r\n\t\t\r\n\t\tnew Thread( () -> System.out.println(\"In Java 8, Lambda Expression rocks !!\") ).start();\r\n\t\t\r\n\t\tSystem.out.println(\"-----------*************************-------------\");\r\n\t\t\r\n\t\t// Iterating Over List Using Lambda Expressions\r\n\t\t\r\n\t\tList features = Arrays.asList(\"Lambdas\",\"Default Method\",\"Stream API\",\"DAte and Time API\");\r\n\t\t\r\n\t\tfeatures.forEach(n -> System.out.println(n));\r\n\r\n\t\tSystem.out.println(\"-----------*************************-------------\");\r\n\t\t\t\t\r\n\t\t// Even better use method reference feature of Java 8\r\n\t\t// method reference is denoted by :: ****double colon***** operator\r\n\t\t// looks similar to scope resolution operator of C++\r\n\t\t\r\n\t\tfeatures.forEach(System.out::println);\r\n\r\n\t}", "public static void main(String[] args) {\r\n\t\tSomeJava8Features obj = new SomeJava8Features();\r\n\r\n\t\t// StringJoiner\r\n\t\texampleStringJoiner();\r\n\t\t\r\n\t\t// Default\r\n\t\tint ary[] = {3,6,8,9,0};\r\n\t\tSystem.out.println(\"\\nsumOfGivenIntArray ... \" + obj.sumOfGivenIntArray(ary));\r\n\t\tobj.sayMore(\"Hello Rohini\");\r\n\t\t\r\n\t\t// ForEach & Lambda Expression\r\n\t\texampleForEach_FindMaximum(ary);\r\n\t\t\r\n\r\n\t}", "@Deprecated\n\tprivate void oldCode()\n\t{\n\t}", "@Override\r\n\tprotected void doF8() {\n\t\t\r\n\t}", "private void level7() {\n }", "Compatibility compatibility();", "@SuppressWarnings(\"unused\")\n\tprivate void version() {\n\n\t}", "public static void main(String[] args) {\n throw new NotImplementedException();\n }", "public static void main(String[] args) {\n Foo foo = new Java8Default();\n foo.sumDefault(2,4);\n\n }", "@Test\n public void source8() throws Exception {\n ImmutableList<String> options = (GeneratedAnnotationsTest.isJdk9OrLater()) ? ImmutableList.of(\"--release\", \"8\") : ImmutableList.of(\"-source\", \"8\", \"-target\", \"8\");\n String generated = runProcessor(options, null);\n assertThat(generated).contains(GeneratedAnnotationsTest.JAVAX_ANNOTATION_GENERATED);\n assertThat(generated).doesNotContain(GeneratedAnnotationsTest.JAVAX_ANNOTATION_PROCESSING_GENERATED);\n }", "void compileToJava();", "public static void main(String args[]) throws Exception\n {\n \n \n \n }", "public final void mo8775b() {\n }", "public static void main(String[] args) {\n\t\t//Até o java 7\n\t\tnew Thread(new Runnable() {\n\n\t\t @Override\n\t\t public void run() {\n\t\t System.out.println(\"Executando um Runnable\");\n\t\t }\n\n\t\t}).start();\n\t\t//A partir do java 8\n\t\tnew Thread(() -> System.out.println(\"Executando um Runnable\")).start();\n\t\t\n\t\t//iterando com java 8: classe anonima\n\t\ttexto.forEach(new Consumer<String>() {\n\t\t public void accept(String s) {\n\t\t System.out.println(s);\n\t\t }\n\t\t});\n\t\t//iterando com java 8: lambda\n\t\t//Essa sintaxe funciona para qualquer interface \n\t\t//que tenha apenas um método abstrato\n\t\ttexto.forEach((String s) -> {\n\t\t System.out.println(s);\n\t\t});\n\t\t//ou\n\t\ttexto.forEach((s) -> {\n\t\t System.out.println(s);\n\t\t});\n\t\t//ou\n\t\ttexto.forEach(s -> {\n\t\t System.out.println(s);\n\t\t});\n\t\t//ou\n\t\ttexto.forEach(s -> System.out.println(s));\n\t\t// Uma interface que possui apenas um método abstrato \n\t\t//é agora conhecida como interface funcional e pode ser utilizada dessa forma\n\t\t\n\t\t//Outro exemplo é o próprio Comparator. Se utilizarmos a forma \n\t\t//de classe anônima, teremos essa situação: \n\t\ttexto.sort(new Comparator<String>() {\n\t\t public int compare(String s1, String s2) {\n\t\t if (s1.length() < s2.length())\n\t\t return -1;\n\t\t if (s1.length() > s2.length())\n\t\t return 1;\n\t\t return 0;\n\t\t }\n\t\t});\n\t\t//ou com lambda\n\t\ttexto.sort((s1, s2) -> {\n\t\t if (s1.length() < s2.length())\n\t\t return -1;\n\t\t if (s1.length() > s2.length())\n\t\t return 1;\n\t\t return 0;\n\t\t});\n\t\t//ou\n\t\ttexto.sort((s1, s2) -> {\n\t\t return Integer.compare(s1.length(), s2.length());\n\t\t});\n\t\t//ou como há apenas um único statement, podemos remover as chaves\n\t\ttexto.sort((s1, s2) -> Integer.compare(s1.length(), s2.length()));\n\t}", "public void mo38117a() {\n }", "void mo57277b();", "public static void main(String[] args) {\n version1WhileLoop();\n version1DoWhileLoop();\n version1ForLoop();\n version2ForLoop();\n version3ForLoop();\n }", "public abstract boolean mo2163j();", "public static void main(String[] args) throws Exception {\n\t\t\t\t\t\t\n\t\t\t\t\n\t\t\t}", "private NativeSupport() {\n\t}", "private static IRIProvider makeProviderJDK() { return new IRIProviderJDK(); }", "public void mo21785J() {\n }", "@Override\n public void func_104112_b() {\n \n }", "public static void generateCode()\n {\n \n }", "private UsingSwig() {\n\t}", "public static void main(String[] args) {\n\t\tlanceur8();\n\t}", "void mo1941j();", "public abstract void mo2624j();", "private final boolean updateState(java.lang.Object r7, java.lang.Object r8) {\n /*\n // Method dump skipped, instructions count: 101\n */\n throw new UnsupportedOperationException(\"Method not decompiled: kotlinx.coroutines.flow.StateFlowImpl.updateState(java.lang.Object, java.lang.Object):boolean\");\n }", "void mo72113b();", "static void feladat7() {\n\t}", "void mo28306a();", "private static void cajas() {\n\t\t\n\t}", "private void habilitar() {\n throw new UnsupportedOperationException(\"Not supported yet.\"); //To change body of generated methods, choose Tools | Templates.\n }", "public static void main(String[] args) {\n\n\t\tUnaryOperator<Integer> func=x->x*7;\t\t\n\t\tint num=func.apply(10);\n\t\tSystem.out.println(num);\n\t\t\n\t\tFunction<Integer, Integer> func1=x->x*10;\n\t\tSystem.out.println(func1.apply(10));\n\t\t\n\t\tList<String> langList=new ArrayList<String>();\n\t\tlangList.add(\"Java\");\n\t\tlangList.add(\"Ruby\");\n\t\tlangList.add(\"Python\");\n\t\t\n\t\tSystem.out.println(langList);\n\t\t\n\t\tlangList.replaceAll(ele -> ele +\" Deeps\");\n\t\tSystem.out.println(langList);\n\t}", "void mo57278c();", "interface DefaultMethod extends SingleMethod {\r\n\tdefault public void myMethod() {\r\n\t\tSystem.out.println(\"from Java 1.8 version can have method with a body\");\r\n}\r\n}", "void mo80457c();", "public void mo21792Q() {\n }", "public static void main(String[] args) {\n \n }", "public static void main(String[] args) {\n \n }", "public static void main(String[] args) {\n \n }", "public static void main(String[] args) {\n \n }", "public static void main(String[] args) {\n \n }", "public static void main(String[] args) {\n \n }", "public void mo21787L() {\n }", "public void method_4270() {}", "static void feladat8() {\n\t}", "public static void main() {\n \n }", "private void level6() {\n }", "void mo57275a();", "void mo80452a();", "private Quantify()\n {\n throw new UnsupportedOperationException(\"Instantiation of utility classes is not supported.\");\n }", "public void m9741j() throws cf {\r\n }", "@Before\n public void setUp() {\n Assume.assumeThat(JavaVersion.getMajorVersion(), Matchers.lessThanOrEqualTo(8));\n }", "private stendhal() {\n\t}", "void mo41083a();", "public static void main(String[] args) {\n\t\tisPolindrom(\"abcd\");\r\n\t\tfibJava8(2);\r\n\t\tfactJava8(5);\r\n\t}", "void m8368b();", "@Override\n\tpublic void implementionSeven(String[] args) throws Exception {\n\n\t}", "public void mo6081a() {\n }", "java.lang.String getS8();", "public void mo21879u() {\n }", "void mo119582b();", "public abstract void mo27385c();", "public abstract void mo70713b();", "public void mo21781F() {\n }", "public interface AnonymousClass1lE {\n void A7X(String str, String str2, String str3);\n\n void A7Z(String str, String str2, @Nullable Map<String, String> map);\n\n void A7b(String str, String str2, Throwable th, @Nullable Map<String, String> map);\n\n void A7d(String str, String str2, @Nullable Map<String, String> map);\n\n void A7f(String str, String str2);\n\n void A8G(String str, String str2, boolean z);\n\n boolean A9J(String str);\n}", "void mo41086b();", "public static void main(String[] args) {\n\n // Creating object of class in main() method\n JEP306_StritfpSample t = new JEP306_StritfpSample();\n\n // Here we have error of putting strictfp and\n // error is not found public static void main method\n System.out.println(t.sum());\n }", "public static void main(String[] args) {\n \n \n }", "public static void main(String[] args) {\n \n \n }", "private void kk12() {\n\n\t}", "public static void main(String[] args) {\n //Ersetzt jetzt mal unseren Parser, Stell Dir vor\n // das Ding liest das Beispiel da oben ^^.\n final StatementNode[] statementNodes = readStatements();\n \n //Zustände:\n // - FillSymbolTable (was für Symbole [variablen, ...] gibt es)\n // - TypInferenz (Was für Typen haben die Expressions und sind die eingaben semantisch korrekt)\n // - CodeGenerierung oder Ausführung (ersetzen wir mit \"schreibe die Werte aller Variablen nach Ende der Ausführung\")\n \n \n final SymbolTabelle symbolTabelle = new SymbolTabelle();\n //IDEE 2:\n //Ich gebe Statements und Expressions nur eine Methode mit Visitor als Callback\n final StatementVisitorSymbolTabelle statementVisitorSymbolTabelle = new StatementVisitorSymbolTabelle(symbolTabelle);\n for(StatementNode statementNode : statementNodes) {\n statementNode.accept(statementVisitorSymbolTabelle);\n }\n \n final StatementVisitorTypInferenz statementVisitorTypInferenz = new StatementVisitorTypInferenz(symbolTabelle);\n for(StatementNode statementNode : statementNodes) {\n statementNode.accept(statementVisitorTypInferenz);\n }\n \n PseudoLaufContext laufContext = new PseudoLaufContext();\n final StatementVisitorCodeGen statementVisitorCodeGen = new StatementVisitorCodeGen(laufContext);\n for(StatementNode statementNode : statementNodes) {\n statementNode.accept(statementVisitorCodeGen);\n }\n \n laufContext.druckeVariablen();\n \n //Zusammenfassung:\n //Reduktion des Problems darauf, den Code nur noch von einem Abhängig zu machen\n //Jetzt nur noch abhängig vom Typ des Statements\n \n \n //Problem hierbei:\n //Ich muss selbst angeben, in welchem Zustand ich bin\n //Code-Duplizierung\n }", "public static void main(String[] args) {\n \n \n \n\t}", "private void someUtilityMethod() {\n }", "private void someUtilityMethod() {\n }", "void mo80455b();", "interface C15937b {\n /* renamed from: a */\n void mo13368a();\n\n /* renamed from: a */\n void mo13369a(int i, int i2, int i3, boolean z);\n\n /* renamed from: a */\n void mo13370a(int i, int i2, List<C15929a> list) throws IOException;\n\n /* renamed from: a */\n void mo13371a(int i, long j);\n\n /* renamed from: a */\n void mo13372a(int i, ErrorCode errorCode);\n\n /* renamed from: a */\n void mo13373a(int i, ErrorCode errorCode, ByteString byteString);\n\n /* renamed from: a */\n void mo13374a(boolean z, int i, int i2);\n\n /* renamed from: a */\n void mo13375a(boolean z, int i, int i2, List<C15929a> list);\n\n /* renamed from: a */\n void mo13376a(boolean z, int i, BufferedSource bufferedSource, int i2) throws IOException;\n\n /* renamed from: a */\n void mo13377a(boolean z, C15943j c15943j);\n }", "void mo88521a();", "void mo20141a();", "public static void main(String[] args) {\n \n \n \n \n }", "public final void mo51373a() {\n }", "private final boolean shouldProposeGenerics(IJavaProject project) {\n\t\treturn true;\n\t\t/*\n\t\tString sourceVersion;\n\t\tif (project != null)\n\t\t\tsourceVersion= project.getOption(JavaCore.COMPILER_SOURCE, true);\n\t\telse\n\t\t\tsourceVersion= JavaCore.getOption(JavaCore.COMPILER_SOURCE);\n\n\t\treturn sourceVersion != null && JavaCore.VERSION_1_5.compareTo(sourceVersion) <= 0;\n\t\t*/\n\t}", "public static void main(String[] args) {\n way8();\n }", "private JacobUtils() {}", "void mo60893b();", "public interface JavaCode {\n\n /**\n * Get an unique identification code for an object\n * TODO: This method is not reliable as hash codes are not unique, should use an UUID generator singleton instead.\n *\n * @param obj the object\n * @return the unique identification code\n */\n static int getUniqueID(Object obj) {\n return obj.hashCode();\n }\n\n /**\n * Compiles this code. If an object implements both {@link JavaCode}\n * and {@link JavaExpression}, only one of this method and\n * {@link JavaExpression#compileExpression(Subroutine, JavaScope)} should be called.\n *\n * @param subroutine the subroutine which this code belongs to\n * @param parent the parent scope of this code\n * @throws JTAException if an error occurs\n */\n void compileCode(Subroutine subroutine, JavaScope parent) throws JTAException;\n}", "public void mo8738a() {\n }", "public void mo1972o() throws cf {\r\n }", "public static void main (String[] args) {import java.util.*;%>\n//&&&staticSymbol&&&<%import org.eclipse.emf.codegen.ecore.genmodel.*;%>\n//&&&staticSymbol&&&<%\n\n/**\n * Copyright (c) 2002-2010 IBM Corporation and others.\n * All rights reserved. This program and the accompanying materials\n * are made available under the terms of the Eclipse Public License v1.0\n * which accompanies this distribution, and is available at\n * http://www.eclipse.org/legal/epl-v10.html\n *\n * Contributors:\n * IBM - Initial API and implementation\n */\n\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nGenPackage genPackage = (GenPackage)((Object[])argument)[0]; GenModel genModel=genPackage.getGenModel(); /* Trick to import java.util.* without warnings */Iterator.class.getName();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nboolean isInterface = Boolean.TRUE.equals(((Object[])argument)[1]); boolean isImplementation = Boolean.TRUE.equals(((Object[])argument)[2]);\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nString publicStaticFinalFlag = isImplementation ? \"public static final \" : \"\";\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%include(\"../Header.javajetinc\");%>\n//&&&staticSymbol&&&<%\nif (isInterface || genModel.isSuppressInterfaces()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&package <%\n//&&&staticSymbol&&&=genPackage.getReflectionPackageName()\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&<%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&package <%\n//&&&staticSymbol&&&=genPackage.getClassPackageName()\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\nif (isImplementation) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.addPseudoImport(\"org.eclipse.emf.ecore.impl.MinimalEObjectImpl.Container\");\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.addPseudoImport(\"org.eclipse.emf.ecore.impl.MinimalEObjectImpl.Container.Dynamic\");\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.addImport(\"org.eclipse.emf.ecore.EClass\");\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.addImport(\"org.eclipse.emf.ecore.EObject\");\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (!genPackage.hasJavaLangConflict() && !genPackage.hasInterfaceImplConflict() && !genPackage.getClassPackageName().equals(genPackage.getInterfacePackageName())) genModel.addImport(genPackage.getInterfacePackageName() + \".*\");\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.markImportLocation(stringBuffer);\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\nif (isInterface) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&/**\n//&&&staticSymbol&&& * <!-- begin-user-doc -->\n//&&&staticSymbol&&& * The <b>Factory</b> for the model.\n//&&&staticSymbol&&& * It provides a create method for each non-abstract class of the model.\n//&&&staticSymbol&&& * <!-- end-user-doc -->\n//&&&staticSymbol&&&<%\nif (!genModel.isSuppressEMFMetaData()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& * @see <%\n//&&&staticSymbol&&&=genPackage.getQualifiedPackageInterfaceName()\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& * @generated\n//&&&staticSymbol&&& */\n//&&&staticSymbol&&&<%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&/**\n//&&&staticSymbol&&& * <!-- begin-user-doc -->\n//&&&staticSymbol&&& * An implementation of the model <b>Factory</b>.\n//&&&staticSymbol&&& * <!-- end-user-doc -->\n//&&&staticSymbol&&& * @generated\n//&&&staticSymbol&&& */\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (isImplementation) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&public class <%\n//&&&staticSymbol&&&=genPackage.getFactoryClassName()\n//&&&staticSymbol&&&%> extends <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.impl.EFactoryImpl\")\n//&&&staticSymbol&&&%><%\nif (!genModel.isSuppressInterfaces()) {\n//&&&staticSymbol&&&%> implements <%\n//&&&staticSymbol&&&=genPackage.getImportedFactoryInterfaceName()\n//&&&staticSymbol&&&%><%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&public interface <%\n//&&&staticSymbol&&&=genPackage.getFactoryInterfaceName()\n//&&&staticSymbol&&&%><%\nif (!genModel.isSuppressEMFMetaData()) {\n//&&&staticSymbol&&&%> extends <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EFactory\")\n//&&&staticSymbol&&&%><%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&{\n//&&&staticSymbol&&&<%\nif (genModel.hasCopyrightField()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=publicStaticFinalFlag\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.String\")\n//&&&staticSymbol&&&%> copyright = <%\n//&&&staticSymbol&&&=genModel.getCopyrightFieldLiteral()\n//&&&staticSymbol&&&%>;<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (isImplementation && (genModel.isSuppressEMFMetaData() || genModel.isSuppressInterfaces())) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * The singleton instance of the factory.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=publicStaticFinalFlag\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genPackage.getFactoryClassName()\n//&&&staticSymbol&&&%> eINSTANCE = init();\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (isInterface && genModel.isSuppressEMFMetaData()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * The singleton instance of the factory.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=publicStaticFinalFlag\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genPackage.getFactoryInterfaceName()\n//&&&staticSymbol&&&%> INSTANCE = <%\n//&&&staticSymbol&&&=genPackage.getQualifiedFactoryClassName()\n//&&&staticSymbol&&&%>.eINSTANCE;\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n} else if (isInterface && !genModel.isSuppressInterfaces()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * The singleton instance of the factory.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=publicStaticFinalFlag\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genPackage.getFactoryInterfaceName()\n//&&&staticSymbol&&&%> eINSTANCE = <%\n//&&&staticSymbol&&&=genPackage.getQualifiedFactoryClassName()\n//&&&staticSymbol&&&%>.init();\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (isImplementation) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Creates the default factory implementation.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&<%\nString factoryType = genModel.isSuppressEMFMetaData() ? genPackage.getFactoryClassName() : genPackage.getImportedFactoryInterfaceName();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic static <%\n//&&&staticSymbol&&&=factoryType\n//&&&staticSymbol&&&%> init()\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\ttry\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\t<%\n//&&&staticSymbol&&&=factoryType\n//&&&staticSymbol&&&%> the<%\n//&&&staticSymbol&&&=genPackage.getFactoryName()\n//&&&staticSymbol&&&%> = (<%\n//&&&staticSymbol&&&=factoryType\n//&&&staticSymbol&&&%>)<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EPackage\")\n//&&&staticSymbol&&&%>.Registry.INSTANCE.getEFactory(<%\n//&&&staticSymbol&&&=genPackage.getPackageInterfaceName()\n//&&&staticSymbol&&&%>.eNS_URI);\n//&&&staticSymbol&&&\t\t\tif (the<%\n//&&&staticSymbol&&&=genPackage.getFactoryName()\n//&&&staticSymbol&&&%> != null)\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&&\t\t\t\treturn the<%\n//&&&staticSymbol&&&=genPackage.getFactoryName()\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\tcatch (Exception exception)\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\t<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.plugin.EcorePlugin\")\n//&&&staticSymbol&&&%>.INSTANCE.log(exception);\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\treturn new <%\n//&&&staticSymbol&&&=genPackage.getImportedFactoryClassName()\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Creates an instance of the factory.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\tpublic <%\n//&&&staticSymbol&&&=genPackage.getFactoryClassName()\n//&&&staticSymbol&&&%>()\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\tsuper();\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useClassOverrideAnnotation()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@Override\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic EObject create(EClass eClass)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\tswitch (eClass.getClassifierID())\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&<%\nfor (GenClass genClass : genPackage.getGenClasses()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (!genClass.isAbstract()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tcase <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%>.<%\n//&&&staticSymbol&&&=genClass.getClassifierID()\n//&&&staticSymbol&&&%>: return <%\n//&&&staticSymbol&&&*%%storeSymbol%%*0\n//&&&staticSymbol&&&%>create<%\n//&&&staticSymbol&&&=genClass.getName()\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tdefault:\n//&&&staticSymbol&&&\t\t\t\tthrow new IllegalArgumentException(\"The class '\" + eClass.getName() + \"' is not a valid classifier\");<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(2)\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\nif (!genPackage.getAllGenDataTypes().isEmpty()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useClassOverrideAnnotation()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@Override\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic Object createFromString(<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EDataType\")\n//&&&staticSymbol&&&%> eDataType, String initialValue)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\tswitch (eDataType.getClassifierID())\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&<%\nfor (GenDataType genDataType : genPackage.getAllGenDataTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isSerializable()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tcase <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%>.<%\n//&&&staticSymbol&&&=genDataType.getClassifierID()\n//&&&staticSymbol&&&%>:\n//&&&staticSymbol&&&\t\t\t\treturn create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>FromString(eDataType, initialValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tdefault:\n//&&&staticSymbol&&&\t\t\t\tthrow new IllegalArgumentException(\"The datatype '\" + eDataType.getName() + \"' is not a valid classifier\");<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(2)\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useClassOverrideAnnotation()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@Override\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic String convertToString(<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EDataType\")\n//&&&staticSymbol&&&%> eDataType, Object instanceValue)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\tswitch (eDataType.getClassifierID())\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&<%\nfor (GenDataType genDataType : genPackage.getAllGenDataTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isSerializable()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tcase <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%>.<%\n//&&&staticSymbol&&&=genDataType.getClassifierID()\n//&&&staticSymbol&&&%>:\n//&&&staticSymbol&&&\t\t\t\treturn convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>ToString(eDataType, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tdefault:\n//&&&staticSymbol&&&\t\t\t\tthrow new IllegalArgumentException(\"The datatype '\" + eDataType.getName() + \"' is not a valid classifier\");<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(2)\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nfor (GenClass genClass : genPackage.getGenClasses()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (!genClass.isAbstract()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\tpublic <%\n//&&&staticSymbol&&&=genClass.getTypeParameters()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getImportedInterfaceName()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getInterfaceTypeArguments()\n//&&&staticSymbol&&&%> create<%\n//&&&staticSymbol&&&=genClass.getName()\n//&&&staticSymbol&&&%>()\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&& <%\nif (genClass.isDynamic()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genClass.getImportedInterfaceName()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getInterfaceTypeArguments()\n//&&&staticSymbol&&&%> <%\n//&&&staticSymbol&&&=genClass.getSafeUncapName()\n//&&&staticSymbol&&&%> = <%\n//&&&staticSymbol&&&=genClass.getCastFromEObject()\n//&&&staticSymbol&&&%>super.create(<%\n//&&&staticSymbol&&&=genClass.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genClass.getImportedClassName()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getClassTypeArguments()\n//&&&staticSymbol&&&%> <%\n//&&&staticSymbol&&&=genClass.getSafeUncapName()\n//&&&staticSymbol&&&%> = new <%\n//&&&staticSymbol&&&=genClass.getImportedClassName()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getClassTypeArguments()\n//&&&staticSymbol&&&%>()<%\nif (genModel.isSuppressInterfaces() && !genPackage.getReflectionPackageName().equals(genPackage.getInterfacePackageName())) {\n//&&&staticSymbol&&&%>{}<%\n}\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genClass.getSafeUncapName()\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nfor (GenDataType genDataType : genPackage.getAllGenDataTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isSerializable()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (genPackage.isDataTypeConverters() || genDataType.hasCreatorBody()) { String eDataType = genDataType.getQualifiedClassifierAccessor();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useGenerics() && genDataType.isUncheckedCast() && !genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@SuppressWarnings(\"unchecked\")\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic <%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedInstanceClassName()\n//&&&staticSymbol&&&%> create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(<%\nif (genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>final <%\n}\n//&&&staticSymbol&&&%>String <%\nif (genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>it<%\n} else {\n//&&&staticSymbol&&&%>literal<%\n}\n//&&&staticSymbol&&&%>)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&& <%\nif (genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getCreatorBody(genModel.getIndentation(stringBuffer))\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType instanceof GenEnum) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getImportedInstanceClassName()\n//&&&staticSymbol&&&%> result = <%\n//&&&staticSymbol&&&=genDataType.getImportedInstanceClassName()\n//&&&staticSymbol&&&%>.get(literal);\n//&&&staticSymbol&&&\t\tif (result == null) throw new IllegalArgumentException(\"The value '\" + literal + \"' is not a valid enumerator of '\" + <%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>.getName() + \"'\");<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(2)\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(3)\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn result;\n//&&&staticSymbol&&& <%\n} else if (genDataType.getBaseType() != null) { GenDataType genBaseType = genDataType.getBaseType(); boolean isPrimitiveConversion = !genDataType.isPrimitiveType() && genBaseType.isPrimitiveType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genBaseType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (isPrimitiveConversion && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn new <%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(create<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(literal));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn create<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genBaseType.getGenPackage().isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (isPrimitiveConversion && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn new <%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.create<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(literal));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.create<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getItemType() != null) { GenDataType genItemType = genDataType.getItemType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (literal == null) return null;\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedInstanceClassName()\n//&&&staticSymbol&&&%> result = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.ArrayList\")\n//&&&staticSymbol&&&%><%\nif (genModel.useGenerics()) {\n//&&&staticSymbol&&&%><<%=genItemType.getObjectType().getImportedParameterizedInstanceClassName()%>><%\n}\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\nif (genModel.getRuntimeVersion().getValue() < GenRuntimeVersion.EMF26_VALUE) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.StringTokenizer\")\n//&&&staticSymbol&&&%> stringTokenizer = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.StringTokenizer\")\n//&&&staticSymbol&&&%>(literal); stringTokenizer.hasMoreTokens(); )\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (String item : split(literal))\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genModel.getRuntimeVersion().getValue() < GenRuntimeVersion.EMF26_VALUE) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString item = stringTokenizer.nextToken();\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) { genItemType = genItemType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(create<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>(item));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(create<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, item));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage().isDataTypeConverters()) { genItemType = genItemType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(<%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.create<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>(item));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(<%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, item));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\treturn result;\n//&&&staticSymbol&&& <%\n} else if (!genDataType.getMemberTypes().isEmpty()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (literal == null) return <%\n//&&&staticSymbol&&&=genDataType.getStaticValue(null)\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getImportedInstanceClassName()\n//&&&staticSymbol&&&%> result = <%\n//&&&staticSymbol&&&=genDataType.getStaticValue(null)\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&\t\tRuntimeException exception = null;\n//&&&staticSymbol&&& <%\nfor (GenDataType genMemberType : genDataType.getMemberTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\ttry\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) { if (!genDataType.isPrimitiveType()) genMemberType = genMemberType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = create<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(literal);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = (<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)create<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) { if (!genDataType.isPrimitiveType()) genMemberType = genMemberType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.create<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(literal);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = (<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tif (<%\nif (!genDataType.isPrimitiveType()) {\n//&&&staticSymbol&&&%>result != null && <%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.util.Diagnostician\")\n//&&&staticSymbol&&&%>.INSTANCE.validate(<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>, <%\nif (genDataType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>new <%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(result)<%\n} else {\n//&&&staticSymbol&&&%>result<%\n}\n//&&&staticSymbol&&&%>, null, null))\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&&\t\t\t\treturn result;\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\tcatch (RuntimeException e)\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\texception = e;\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (<%\nif (!genDataType.isPrimitiveType()) {\n//&&&staticSymbol&&&%>result != null || <%\n}\n//&&&staticSymbol&&&%>exception == null) return result;\n//&&&staticSymbol&&& \n//&&&staticSymbol&&&\t\tthrow exception;\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genModel.useGenerics() && (genDataType.isArrayType() || !genDataType.getEcoreDataType().getETypeParameters().isEmpty() || genDataType.getEcoreDataType().getInstanceTypeName().contains(\"<\"))) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn (<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%>)super.createFromString(literal);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genDataType.isArrayType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t// TODO: implement this method\n//&&&staticSymbol&&&\t\t// Ensure that you remove @generated or mark it @generated NOT\n//&&&staticSymbol&&&\t\tthrow new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.UnsupportedOperationException\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\n} else if (genDataType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn ((<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)super.createFromString(<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>, literal)).<%\n//&&&staticSymbol&&&=genDataType.getPrimitiveValueFunction()\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%>super.createFromString(<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>, literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (!genPackage.isDataTypeConverters() && genModel.useGenerics() && genDataType.isUncheckedCast() && !genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@SuppressWarnings(\"unchecked\")\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic <%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%> create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EDataType\")\n//&&&staticSymbol&&&%> eDataType, String initialValue)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&& <%\nif (genDataType instanceof GenEnum) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters() || genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(initialValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=((GenEnum)genDataType).getImportedInstanceClassName()\n//&&&staticSymbol&&&%> result = <%\n//&&&staticSymbol&&&=((GenEnum)genDataType).getImportedInstanceClassName()\n//&&&staticSymbol&&&%>.get(initialValue);\n//&&&staticSymbol&&&\t\tif (result == null) throw new IllegalArgumentException(\"The value '\" + initialValue + \"' is not a valid enumerator of '\" + eDataType.getName() + \"'\");<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(2)\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(3)\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn result;\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getBaseType() != null) { GenDataType genBaseType = genDataType.getBaseType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genBaseType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.getObjectInstanceClassName().equals(genBaseType.getObjectInstanceClassName())) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%>create<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, initialValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, initialValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getItemType() != null) { GenDataType genItemType = genDataType.getItemType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(initialValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (initialValue == null) return null;\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%> result = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.ArrayList\")\n//&&&staticSymbol&&&%><%\nif (genModel.useGenerics()) {\n//&&&staticSymbol&&&%><<%=genItemType.getObjectType().getImportedParameterizedInstanceClassName()%>><%\n}\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\nif (genModel.getRuntimeVersion().getValue() < GenRuntimeVersion.EMF26_VALUE) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.StringTokenizer\")\n//&&&staticSymbol&&&%> stringTokenizer = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.StringTokenizer\")\n//&&&staticSymbol&&&%>(initialValue); stringTokenizer.hasMoreTokens(); )\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (String item : split(initialValue))\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genModel.getRuntimeVersion().getValue() < GenRuntimeVersion.EMF26_VALUE) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString item = stringTokenizer.nextToken();\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(create<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, item));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(<%\nif (!genItemType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genItemType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, item));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\treturn result;\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (!genDataType.getMemberTypes().isEmpty()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn new <%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(initialValue));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(initialValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (initialValue == null) return null;\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%> result = null;\n//&&&staticSymbol&&&\t\tRuntimeException exception = null;\n//&&&staticSymbol&&& <%\nfor (GenDataType genMemberType : genDataType.getMemberTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\ttry\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = <%\nif (!genDataType.isObjectType() && !genDataType.getObjectInstanceClassName().equals(genMemberType.getObjectInstanceClassName())) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%>create<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, initialValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, initialValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tif (result != null && <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.util.Diagnostician\")\n//&&&staticSymbol&&&%>.INSTANCE.validate(eDataType, result, null, null))\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&&\t\t\t\treturn result;\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\tcatch (RuntimeException e)\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\texception = e;\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (result != null || exception == null) return result;\n//&&&staticSymbol&&& \n//&&&staticSymbol&&&\t\tthrow exception;\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genPackage.isDataTypeConverters() || genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(initialValue);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genModel.useGenerics() && (genDataType.isArrayType() || !genDataType.getEcoreDataType().getETypeParameters().isEmpty() || genDataType.getEcoreDataType().getInstanceTypeName().contains(\"<\"))) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%>super.createFromString(initialValue);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genDataType.isArrayType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t// TODO: implement this method\n//&&&staticSymbol&&&\t\t// Ensure that you remove @generated or mark it @generated NOT\n//&&&staticSymbol&&&\t\tthrow new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.UnsupportedOperationException\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%>super.createFromString(eDataType, initialValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\nif (genPackage.isDataTypeConverters() || genDataType.hasConverterBody()) { String eDataType = genDataType.getQualifiedClassifierAccessor();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\tpublic String convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(<%\nif (genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>final <%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genDataType.getImportedBoundedWildcardInstanceClassName()\n//&&&staticSymbol&&&%> <%\nif (genDataType.hasConverterBody()) {\n//&&&staticSymbol&&&%>it<%\n} else {\n//&&&staticSymbol&&&%>instanceValue<%\n}\n//&&&staticSymbol&&&%>)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&& <%\nif (genDataType.hasConverterBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getConverterBody(genModel.getIndentation(stringBuffer))\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType instanceof GenEnum) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn instanceValue == null ? null : instanceValue.toString();\n//&&&staticSymbol&&& <%\n} else if (genDataType.getBaseType() != null) { GenDataType genBaseType = genDataType.getBaseType(); boolean isPrimitiveConversion = !genDataType.isPrimitiveType() && genBaseType.isPrimitiveType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genBaseType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (isPrimitiveConversion) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn instanceValue == null ? null : convert<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(instanceValue<%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>.<%\n//&&&staticSymbol&&&=genBaseType.getPrimitiveValueFunction()\n//&&&staticSymbol&&&%>()<%\n}\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genBaseType.getGenPackage().isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedFactoryInstanceAccessor()\n//&&&staticSymbol&&&%>.convert<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getItemType() != null) { GenDataType genItemType = genDataType.getItemType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (instanceValue == null) return null;\n//&&&staticSymbol&&&\t\tif (instanceValue.isEmpty()) return \"\";\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.StringBuffer\")\n//&&&staticSymbol&&&%> result = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.StringBuffer\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\nString item; if (!genModel.useGenerics()) { item = \"i.next()\"; \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.Iterator\")\n//&&&staticSymbol&&&%> i = instanceValue.iterator(); i.hasNext(); )\n//&&&staticSymbol&&& <%\n} else { item = \"item\";\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.Object\")\n//&&&staticSymbol&&&%> item : instanceValue)\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) { genItemType = genItemType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(convert<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genItemType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(convert<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage().isDataTypeConverters()) { genItemType = genItemType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(<%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convert<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genItemType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(<%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(' ');\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\treturn result.substring(0, result.length() - 1);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.getMemberTypes().isEmpty()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (!genDataType.isPrimitiveType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (instanceValue == null) return null;\n//&&&staticSymbol&&& <%\nfor (GenDataType genMemberType : genDataType.getMemberTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>.isInstance(instanceValue))\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\ttry\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genMemberType.getQualifiedInstanceClassName().equals(genDataType.getQualifiedInstanceClassName())) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n} else if (genMemberType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(((<%\n//&&&staticSymbol&&&=genMemberType.getObjectType().getImportedInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue).<%\n//&&&staticSymbol&&&=genMemberType.getPrimitiveValueFunction()\n//&&&staticSymbol&&&%>());\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genMemberType.getObjectType().getImportedBoundedWildcardInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage().isDataTypeConverters()) { genMemberType = genMemberType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genMemberType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tif (value != null) return value;\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t\tcatch (Exception e)\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&&\t\t\t\t// Keep trying other member types until all have failed.\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nfor (GenDataType genMemberType : genDataType.getMemberTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\ttry\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>new <%\n//&&&staticSymbol&&&=genMemberType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(instanceValue)<%\n} else {\n//&&&staticSymbol&&&%>instanceValue<%\n}\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage().isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString value = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString value = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>new <%\n//&&&staticSymbol&&&=genMemberType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(instanceValue)<%\n} else {\n//&&&staticSymbol&&&%>instanceValue<%\n}\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tif (value != null) return value;\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\tcatch (Exception e)\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\t// Keep trying other member types until all have failed.\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tthrow new IllegalArgumentException(\"Invalid value: '\"+instanceValue+\"' for datatype :\"+<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>.getName());\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genModel.useGenerics() && (genDataType.isArrayType() || !genDataType.getEcoreDataType().getETypeParameters().isEmpty() || genDataType.getEcoreDataType().getInstanceTypeName().contains(\"<\"))) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn super.convertToString(instanceValue);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genDataType.isArrayType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t// TODO: implement this method\n//&&&staticSymbol&&&\t\t// Ensure that you remove @generated or mark it @generated NOT\n//&&&staticSymbol&&&\t\tthrow new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.UnsupportedOperationException\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\n} else if (genDataType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn super.convertToString(<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>, new <%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(instanceValue));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn super.convertToString(<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useGenerics() && (genDataType.getItemType() != null || genDataType.isUncheckedCast()) && (genPackage.isDataTypeConverters() || genDataType.hasCreatorBody())) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@SuppressWarnings(\"unchecked\")\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic String convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EDataType\")\n//&&&staticSymbol&&&%> eDataType, Object instanceValue)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&& <%\nif (genDataType instanceof GenEnum) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters() || genDataType.hasConverterBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genDataType.getImportedInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn instanceValue == null ? null : instanceValue.toString();\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getBaseType() != null) { GenDataType genBaseType = genDataType.getBaseType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genBaseType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getItemType() != null) { GenDataType genItemType = genDataType.getItemType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters() || genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genDataType.getImportedBoundedWildcardInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue);\n//&&&staticSymbol&&& <%\n} else { final String singleWildcard = genModel.useGenerics() ? \"<?>\" : \"\";\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (instanceValue == null) return null;\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.List\")\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=singleWildcard\n//&&&staticSymbol&&&%> list = (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.List\")\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=singleWildcard\n//&&&staticSymbol&&&%>)instanceValue;\n//&&&staticSymbol&&&\t\tif (list.isEmpty()) return \"\";\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.StringBuffer\")\n//&&&staticSymbol&&&%> result = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.StringBuffer\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\nString item; if (!genModel.useGenerics()) { item = \"i.next()\"; \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.Iterator\")\n//&&&staticSymbol&&&%> i = list.iterator(); i.hasNext(); )\n//&&&staticSymbol&&& <%\n} else { item = \"item\";\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.Object\")\n//&&&staticSymbol&&&%> item : list)\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(convert<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(<%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(' ');\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\treturn result.substring(0, result.length() - 1);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (!genDataType.getMemberTypes().isEmpty()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters() || genDataType.hasConverterBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isPrimitiveType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn instanceValue == null ? null : convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(((<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue)<%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>.<%\n//&&&staticSymbol&&&=genDataType.getPrimitiveValueFunction()\n//&&&staticSymbol&&&%>()<%\n}\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (instanceValue == null) return null;\n//&&&staticSymbol&&& <%\nfor (GenDataType genMemberType : genDataType.getMemberTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>.isInstance(instanceValue))\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\ttry\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tif (value != null) return value;\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t\tcatch (Exception e)\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&&\t\t\t\t// Keep trying other member types until all have failed.\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tthrow new IllegalArgumentException(\"Invalid value: '\"+instanceValue+\"' for datatype :\"+eDataType.getName());\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genPackage.isDataTypeConverters() || genDataType.hasConverterBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isPrimitiveType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn instanceValue == null ? null : convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(<%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>(<%\n}\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue<%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>).<%\n//&&&staticSymbol&&&=genDataType.getPrimitiveValueFunction()\n//&&&staticSymbol&&&%>()<%\n}\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genDataType.getImportedBoundedWildcardInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genModel.useGenerics() && (genDataType.isArrayType() || !genDataType.getEcoreDataType().getETypeParameters().isEmpty() || genDataType.getEcoreDataType().getInstanceTypeName().contains(\"<\"))) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn super.convertToString(instanceValue);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genDataType.isArrayType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t// TODO: implement this method\n//&&&staticSymbol&&&\t\t// Ensure that you remove @generated or mark it @generated NOT\n//&&&staticSymbol&&&\t\tthrow new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.UnsupportedOperationException\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn super.convertToString(eDataType, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nfor (GenClass genClass : genPackage.getGenClasses()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genClass.hasFactoryInterfaceCreateMethod()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Returns a new object of class '<em><%\n//&&&staticSymbol&&&=genClass.getFormattedName()\n//&&&staticSymbol&&&%></em>'.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @return a new object of class '<em><%\n//&&&staticSymbol&&&=genClass.getFormattedName()\n//&&&staticSymbol&&&%></em>'.\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=genClass.getTypeParameters()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getImportedInterfaceName()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getInterfaceTypeArguments()\n//&&&staticSymbol&&&%> create<%\n//&&&staticSymbol&&&=genClass.getName()\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&&\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nfor (GenDataType genDataType : genPackage.getAllGenDataTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isSerializable()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Returns an instance of data type '<em><%\n//&&&staticSymbol&&&=genDataType.getFormattedName()\n//&&&staticSymbol&&&%></em>' corresponding the given literal.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @param literal a literal of the data type.\n//&&&staticSymbol&&&\t * @return a new instance value of the data type.\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedInstanceClassName()\n//&&&staticSymbol&&&%> create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(String literal);\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Returns a literal representation of an instance of data type '<em><%\n//&&&staticSymbol&&&=genDataType.getFormattedName()\n//&&&staticSymbol&&&%></em>'.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @param instanceValue an instance value of the data type.\n//&&&staticSymbol&&&\t * @return a literal representation of the instance value.\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\tString convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getImportedBoundedWildcardInstanceClassName()\n//&&&staticSymbol&&&%> instanceValue);\n//&&&staticSymbol&&&\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (!isImplementation && !genModel.isSuppressEMFMetaData()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Returns the package supported by this factory.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @return the package supported by this factory.\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=genPackage.getPackageInterfaceName()\n//&&&staticSymbol&&&%> get<%\n//&&&staticSymbol&&&=genPackage.getBasicPackageName()\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n} else if (isImplementation) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\tpublic <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%> get<%\n//&&&staticSymbol&&&=genPackage.getBasicPackageName()\n//&&&staticSymbol&&&%>()\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\treturn (<%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%>)getEPackage();\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @deprecated\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useClassOverrideAnnotation()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@Deprecated\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic static <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%> getPackage()\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%>.eINSTANCE;\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&} //<%\n//&&&staticSymbol&&&*%%storeSymbol%%*1\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.emitSortedImports();\n//&&&staticSymbol&&&%>\n\n}", "static void feladat9() {\n\t}", "@Override\n public boolean isVersionCodeCompatible(int version) {\n return true;\n }", "public void mo4359a() {\n }", "private static List<String> getJavasSourceCodeFiels(Map<String,Object> map){\r\n \t\t\r\n \t\t\r\n \t\tSystem.out.println(\"............\");\r\n \t\tLinkedList<String> list = new LinkedList<String>();\r\n \t\tfor(String key : map.keySet()){\r\n \t\t\tObject o = map.get(key);\r\n \r\n \t\t\t//package...\r\n \t\t\tif(o instanceof IPackageFragment){\r\n \t\t\t\t//System.out.println(\"Package --> \" + key);\r\n \t\t\t\tkey = key.substring(0,key.indexOf('[')).trim();\r\n \t\t\t\tkey = PACKAGE + \"(\" + key + \")\";\r\n \t\t\t\tlist.add(key);\r\n \t\t\t}\r\n \t\t\t//class...\r\n \t\t\tif(o instanceof ICompilationUnit){\r\n \t\t\t\t//System.out.println(\"Class --> \" + key);\r\n \t\t\t\tString classname = key.substring(0,key.indexOf('[')).trim();\r\n \t\t\t\tString packagename = key.substring(key.indexOf(PACKAGE),key.indexOf('\\n',key.indexOf(PACKAGE)));\r\n \t\t\t\tkey = CLASS_WITH_MEMBERS + \"(\" + packagename + \",\" + classname + \")\";\r\n \t\t\t\tlist.add(key);\r\n \t\t\t}//method\r\n \t\t\tif(o instanceof IMethod){\r\n \t\t\t\tSystem.out.println(\"Methode --> \" + key);\r\n \t\t\t\tkey = METHOD + \"(\" + getQueryFromMethod((IMethod)o) + \")\";\r\n \t\t\t\tlist.add(key);\r\n \t\t\t}\r\n \t\t\t\r\n \t\t\tif(o instanceof IField){\r\n \t\t\t\tSystem.out.println(\"Attribut --> \" + key);\r\n \t\t\t\tkey = FIELD + \"(\" + getQueryFromField((IField)o) + \")\";\r\n \t\t\t\tlist.add(key);\r\n \t\t\t}\r\n \t\t}\r\n \t\treturn list;\r\n \t\t\r\n \t\t\r\n \t\t/*\r\n \t\tfor(String key : map.keySet()){\r\n \t\t\tObject o = map.get(key);\r\n \t\t\t//if(o instanceof ISourceAttribute)\r\n \t\t\t\t//System.out.println(\"attribute\");\r\n \t\t\t//if(o instanceof ISourceMethod)\r\n \t\t\t\t//System.out.println(\"methode\");\r\n \t\t\tif(o instanceof IPackageFragment) \r\n \t\t\t\tSystem.out.println(\"Package\");\r\n \t\t\tif(o instanceof ICompilationUnit)\r\n \t\t\t\tSystem.out.println(\"sour code file\");\r\n \t\t\t\t\r\n \t\t\t//\"oldquery or class('voller packagename', klassenname)\"\r\n \t\t\t\t\r\n \t\t\t\t\r\n \t\t\tif(o instanceof IField)\r\n \t\t\t\tSystem.out.println(\"Attribut\");\r\n \t\t\tif(o instanceof IType)\r\n \t\t\t\tSystem.out.println(\"classe also class ... in einem file\");\r\n \t\t\tif(o instanceof IMethod)\r\n \t\t\t\tSystem.out.println(\"Methode\");\r\n \t\t\tif(o instanceof IPackageFragmentRoot) \r\n \t\t\t\tSystem.out.println(\"jar package / src Ordner\");\r\n \t\t\tif(o instanceof IProject)\r\n \t\t\t\tSystem.out.println(\"Projekt Ordner\");\r\n \t\t\tif(o instanceof IClassFile)\r\n \t\t\t\tSystem.out.println(\"ClassFile\");\r\n \t\t\tif(o instanceof IAdaptable) //trieft auch auf viele ander sachen zu\r\n \t\t\t\tSystem.out.println(\"Libaraycontainer\");\r\n \t\t\tif(o instanceof IFile)\r\n \t\t\t\tSystem.out.println(\"file\"); //je nach ausgewlter ansicht knnen file auch *.java datein sein\r\n \t\t\tif(o instanceof IFolder)\r\n \t\t\t\tSystem.out.println(\"folder\");\r\n \t\t\tSystem.out.println(o.getClass());\r\n \t\t\t\r\n \t\r\n \t\t}\r\n \t\treturn null;\r\n \t\t*/\r\n \t}", "public void mo1531a() {\n }", "public void mo1976s() throws cf {\r\n }", "void mo119581a();", "static void feladat6() {\n\t}", "private void generateSolution() {\n\t\t// TODO\n\n\t}" ]
[ "0.5890391", "0.58054996", "0.57008785", "0.56167847", "0.54946315", "0.54761344", "0.524263", "0.52340496", "0.5233149", "0.52029705", "0.5160466", "0.51574665", "0.5143396", "0.5094738", "0.5084682", "0.5069909", "0.50661004", "0.50645214", "0.5064437", "0.50475377", "0.5041245", "0.5039573", "0.5037435", "0.50317824", "0.5007829", "0.500209", "0.49986184", "0.4996393", "0.49733046", "0.49654463", "0.49482828", "0.49374196", "0.49367213", "0.49362347", "0.4931423", "0.49300268", "0.49164099", "0.49096605", "0.4893169", "0.48904118", "0.4883474", "0.4883474", "0.4883474", "0.4883474", "0.4883474", "0.4883474", "0.4869394", "0.48675945", "0.4863796", "0.4849808", "0.48444158", "0.48439786", "0.48421556", "0.4838581", "0.48383453", "0.4837389", "0.4833218", "0.48310906", "0.4830076", "0.4827487", "0.481306", "0.48097232", "0.4807137", "0.48028547", "0.4801506", "0.47964317", "0.47952133", "0.479351", "0.4792214", "0.4791279", "0.47875714", "0.47851777", "0.47851777", "0.47834784", "0.47784257", "0.47747812", "0.47722042", "0.47722042", "0.47719148", "0.47705945", "0.47705132", "0.47681588", "0.47653475", "0.47629744", "0.47611335", "0.47570732", "0.47566834", "0.47548115", "0.4751401", "0.47484854", "0.47464594", "0.47460574", "0.47457317", "0.4742769", "0.47399607", "0.47344413", "0.47313395", "0.47252822", "0.47233605", "0.4721698", "0.47122636" ]
0.0
-1
This is a test of creating a new Writer object.
@Test public void testWriter() { String s = "This is a test of the writer"; Writer w = new Writer(); assertThat(w, is(notNullValue())); w.write(s); assertThat(w.read(), is(s)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private WriterFactory() {\n }", "Write createWrite();", "private void setupWriter() {\n output = new StringWriter();\n writer = new PrintWriter(output);\n }", "@Test\n\tpublic void testVariousWriteMethods() throws Exception {\n\t\tfinal String reference = \"test\";\n\t\tfinal StringWriter destination1 = new StringWriter();\n\n\t\tfinal TeeWriter tee = new TeeWriter(destination1);\n\t\t// \"t\"\n\t\ttee.write(reference.charAt(0));\n\t\t// \"est\"\n\t\ttee.write(reference, 1, 3);\n\t\tassertEquals(\"the two string are equals\", reference,\n\t\t\t\tdestination1.toString());\n\t\tassertEquals(\"byte count\", reference.length(), tee.getSize());\n\t}", "@Test\n public void testWriteToPrintWriter() throws Exception {\n System.out.println(\"writeToPrintWriter\");\n PrintWriter output = new PrintWriter(\"tmp.log\");\n String data = \"abc\";\n boolean expResult = true;\n boolean result = IOUtil.writeToPrintWriter(output, data);\n assertEquals(expResult, result);\n result = IOUtil.writeToPrintWriter(output, null);\n assertEquals(false, result);\n\n }", "public void test_ConstructorI() {\n cw = new CharArrayWriter(90);\n assertEquals(\"Test 1: Incorrect writer created.\", 0, cw.size());\n\n try {\n cw = new CharArrayWriter(-1);\n fail(\"IllegalArgumentException expected.\");\n } catch (IllegalArgumentException e) {\n // Expected.\n }\n }", "public Writer getWriter ()\n {\n\tif (myWriter == null)\n\t{\n\t myWriter = new MyWriter ();\n\t}\n\n\treturn myWriter;\n }", "@Test\n\tpublic void testWrite(){\n\t\tGameWorld gw = getGameWorld();\n\t\ttry{\n\t\t\tXMLWriter writer = new XMLWriter(\"testWrite\");\n\t\t\twriter.write(gw);\n\t\t\twriter.close();\n\t\t} catch(FileNotFoundException e){\n\t\t\te.printStackTrace();\n\t\t\tfail(\"XMLWriter, testWrite.xml not found\");\n\t\t} catch(IntrospectionException e){\n\t\t\te.printStackTrace();\n\t\t\tfail(\"XMLWriter, introspection failure\");\n\t\t}\n\t}", "private StringWriter createStringWriter(String str)\n\t{\n\t\treturn new StringWriter((int) (str.length() + (str.length() * 0.1)));\n\t}", "private PrintWriterUtil() {}", "public void testCreateProxy() throws Exception {\n XMLStreamWriter result = openFilteredWriter(new StringWriter(), factory);\n\n assertNotNull(result);\n }", "public MockJspWriter(Writer targetWriter) {\n\t\tthis(null, targetWriter);\n\t}", "public MockSNSWriter getMockWriter()\n {\n return (MockSNSWriter)writer;\n }", "public static JsonWriter newWriter(Writer writer) {\n if (provider == JsonProvider.UNKNOWN) {\n init();\n }\n return provider.newWriter(writer);\n }", "private void createWriter() throws IOException {\n if (outputFile.exists()) {\n outputFile.delete();\n }\n FileWriter outFw = null;\n try {\n outFw = new FileWriter(outputFile.getAbsolutePath());\n } catch (IOException e) {\n LOG.error(\"Can not create writer for {} {}\", outputFile.getAbsolutePath(), e);\n throw e;\n }\n this.bufferedWriter = new BufferedWriter(outFw);\n writeOutputLine(\"User Agent - started\");\n }", "public TeeWriter() {\r\n ; // nothing to do\r\n }", "public static XMLStringWriter create() {\r\n return new XMLStringWriter(new StringWriter());\r\n }", "public abstract JsonWriter newWriter(Writer writer);", "public void testGetWritable_2()\n\t\tthrows Exception {\n\t\tFiles fixture = new Files();\n\t\tfixture.setAbsolutePath(\"\");\n\t\tfixture.setType(\"\");\n\t\tfixture.setReadable(\"\");\n\t\tfixture.setSize(\"\");\n\t\tfixture.setWritable(\"\");\n\t\tfixture.setExecutable(\"\");\n\t\tfixture.setMtime(\"\");\n\n\t\tString result = fixture.getWritable();\n\n\t\t\n\t\tassertEquals(\"\", result);\n\t}", "@Test(timeout = 4000)\n public void test09() throws Throwable {\n ClassWriter classWriter0 = new ClassWriter(1556);\n FieldWriter fieldWriter0 = null;\n try {\n fieldWriter0 = new FieldWriter(classWriter0, 2, \"!Wk\\\":Mn\", \"!Wk\\\":Mn\", \"!Wk\\\":Mn\", classWriter0);\n fail(\"Expecting exception: IllegalArgumentException\");\n \n } catch(IllegalArgumentException e) {\n //\n // value wheel.asm.ClassWriter@5\n //\n verifyException(\"wheel.asm.ClassWriter\", e);\n }\n }", "private HFile.Writer getNewWriter(final HFile.Writer writer,\n final Path familydir)\n throws IOException {\n close(writer);\n return new HFile.Writer(fs, StoreFile.getUniqueFile(fs, familydir),\n blocksize, compression, KeyValue.KEY_COMPARATOR);\n }", "public PropertiesWriter() {\r\n }", "public MockJspWriter(HttpServletResponse response, Writer targetWriter) {\n\t\tsuper(DEFAULT_BUFFER, true);\n\t\tthis.response = (response != null ? response : new MockHttpServletResponse());\n\t\tif (targetWriter instanceof PrintWriter) {\n\t\t\tthis.targetWriter = (PrintWriter) targetWriter;\n\t\t}\n\t\telse if (targetWriter != null) {\n\t\t\tthis.targetWriter = new PrintWriter(targetWriter);\n\t\t}\n\t}", "public static StringDescriptionWriter stringWriter() {\n return new StringDescriptionWriter();\n }", "public MarkupWriterMock() {\n this.document.newRootElement(\"html\");\n this.currentElement = this.document.getRootElement();\n }", "public PipedWriter() { throw new RuntimeException(\"Stub!\"); }", "private BufferedWriter createWriter(String filePath, String fileName)\r\n\t\t\tthrows IOException {\r\n\t\tString fullPath = filePath + \"/\" + fileName;\r\n\t\tFile file = new File(fullPath);\r\n\t\tboolean exists = new File(filePath).exists();\r\n\t\tif (!exists) {\r\n\t\t\tfile.mkdir();\r\n\t\t}\r\n\t\tFileWriter writer = new FileWriter(file);\r\n\t\tBufferedWriter bufferWriter = new BufferedWriter(writer);\r\n\r\n\t\treturn bufferWriter;\r\n\t}", "public interface IWriter {\n void write(int b) throws WriterException;\n}", "public JsonGenerator createGenerator(Writer w)\n/* */ throws IOException\n/* */ {\n/* 1129 */ IOContext ctxt = _createContext(w, false);\n/* 1130 */ return _createGenerator(_decorate(w, ctxt), ctxt);\n/* */ }", "@Test(timeout = 4000)\n public void test10() throws Throwable {\n StringWriter stringWriter0 = new StringWriter(85);\n stringWriter0.append('T');\n StringWriter stringWriter1 = new StringWriter();\n StringWriter stringWriter2 = stringWriter0.append((CharSequence) \",2KY\");\n FileSystemHandling.shouldAllThrowIOExceptions();\n stringWriter0.append('y');\n stringWriter2.append('4');\n stringWriter2.close();\n SimpleNode simpleNode0 = new SimpleNode('T');\n simpleNode0.setIdentifier(\">>\");\n simpleNode0.dump((String) null, stringWriter2);\n assertEquals(\"T,2KYy4<ForInit>\\n <identifier>*rshft</identifier>\\n</ForInit>\\n\", stringWriter2.toString());\n \n String string0 = simpleNode0.toString();\n assertEquals(\"ForInit : >>\", string0);\n }", "@Test\n\tpublic void testStandardTee() throws Exception {\n\t\tfinal String reference = \"test\";\n\t\tfinal Reader source = new StringReader(reference);\n\t\tfinal StringWriter destination1 = new StringWriter();\n\t\tfinal StringWriter destination2 = new StringWriter();\n\n\t\tfinal TeeWriter tee = new TeeWriter(destination1, destination2);\n\t\torg.apache.commons.io.IOUtils.copy(source, tee);\n\t\ttee.close();\n\n\t\tassertEquals(\"the two string are equals\", reference,\n\t\t\t\tdestination1.toString());\n\t\tassertEquals(\"the two string are equals\", reference,\n\t\t\t\tdestination2.toString());\n\t\tassertEquals(\"byte count\", reference.length(), tee.getSize());\n\t}", "@Test(timeout = 4000)\n public void test04() throws Throwable {\n ClassWriter classWriter0 = new ClassWriter((-2252));\n String[] stringArray0 = new String[5];\n stringArray0[0] = \"Code\";\n stringArray0[1] = \"\";\n stringArray0[2] = \"Code\";\n stringArray0[3] = \"Code\";\n stringArray0[4] = \"Code\";\n MethodWriter methodWriter0 = null;\n try {\n methodWriter0 = new MethodWriter(classWriter0, 1, \"\", \"\", \"Code\", stringArray0, true, false);\n fail(\"Expecting exception: StringIndexOutOfBoundsException\");\n \n } catch(StringIndexOutOfBoundsException e) {\n }\n }", "public abstract JsonWriter newWriter(OutputStream out);", "public Writer openWriter() throws IOException {\n return new FileWriter(this);\n }", "@Test(timeout = 4000)\n public void test01() throws Throwable {\n ClassWriter classWriter0 = new ClassWriter(441);\n classWriter0.index = (-2784);\n FieldWriter fieldWriter0 = new FieldWriter(classWriter0, 441, \"N}o.<G8IO,,S#lU9s2Q\", \"N}o.<G8IO,,S#lU9s2Q\", \"N}o.<G8IO,,S#lU9s2Q\", \"N}o.<G8IO,,S#lU9s2Q\");\n int int0 = fieldWriter0.getSize();\n assertEquals(24, int0);\n }", "public static Writer writerCreator(String iFile, String config) throws IOException\n\t{\n\t\tWriter writer = new BufferedWriter(\n\t\t\t\tnew OutputStreamWriter(new FileOutputStream(iFile), UTF8));\n\t\twriter.write(config);\n\t\treturn writer;\n\t}", "@Override\n\tpublic void write(Object obj, File file) throws IJunitException {\n\t\t\n\t}", "@Test(timeout = 4000)\n public void test16() throws Throwable {\n ClassWriter classWriter0 = new ClassWriter(9);\n FieldWriter fieldWriter0 = new FieldWriter(classWriter0, 1596, \"ConstantVlue\", \"xWJwacYp%f=Qk\", \"eprF6eZaPtd\", (Object) null);\n Object object0 = new Object();\n FieldWriter fieldWriter1 = null;\n try {\n fieldWriter1 = new FieldWriter(classWriter0, 2, \"The list of names must not be null\", \"The list of names must not be null\", \":qO^Q~\", object0);\n fail(\"Expecting exception: IllegalArgumentException\");\n \n } catch(IllegalArgumentException e) {\n //\n // value java.lang.Object@6f18df94\n //\n verifyException(\"wheel.asm.ClassWriter\", e);\n }\n }", "public void testGetWritable_1()\n\t\tthrows Exception {\n\t\tFiles fixture = new Files();\n\t\tfixture.setAbsolutePath(\"\");\n\t\tfixture.setType(\"\");\n\t\tfixture.setReadable(\"\");\n\t\tfixture.setSize(\"\");\n\t\tfixture.setWritable((String) null);\n\t\tfixture.setExecutable(\"\");\n\t\tfixture.setMtime(\"\");\n\n\t\tString result = fixture.getWritable();\n\n\t\t\n\t\tassertEquals(\"0\", result);\n\t}", "@Test\n public void testWrite() {\n System.out.println(\"write\");\n RecordFile instance = new RecordFile();\n \n String first = \"hello\";\n String second = \"hello 2\";\n String third = \"hello 3\";\n \n instance.write(first.getBytes(), 0);\n instance.write(second.getBytes(), 1);\n instance.write(third.getBytes(), 2);\n \n Assert.assertEquals(first, new String(instance.read(0)));\n Assert.assertEquals(second, new String(instance.read(1)));\n Assert.assertEquals(third, new String(instance.read(2)));\n \n instance.write(third.getBytes(), 1);\n \n Assert.assertEquals(first, new String(instance.read(0)));\n Assert.assertEquals(third, new String(instance.read(1)));\n Assert.assertEquals(third, new String(instance.read(2)));\n }", "public static interface Writer {\n /**\n * Write object.\n *\n * @param writer Writer.\n * @param obj Object.\n * @param err Error.\n */\n public void write(BinaryRawWriterEx writer, Object obj, Throwable err);\n\n /**\n * Determines whether this writer can write given data.\n *\n * @param obj Object.\n * @param err Error.\n * @return Value indicating whether this writer can write given data.\n */\n public boolean canWrite(Object obj, Throwable err);\n }", "@Test\n public void testWriteToStream() throws Exception {\n System.out.println(\"writeToStream\");\n FileOutputStream output = new FileOutputStream(\"tmp.log\");\n String data = \"abc\";\n boolean expResult = true;\n boolean result = IOUtil.writeToStream(output, data);\n assertEquals(expResult, result);\n result = IOUtil.writeToStream(output, null);\n assertEquals(false, result);\n\n }", "@Test(timeout = 4000)\n public void test023() throws Throwable {\n ClassWriter classWriter0 = new ClassWriter((-1983180370));\n ClassWriter classWriter1 = new ClassWriter(2);\n FileSystemHandling.appendStringToFile((EvoSuiteFile) null, \"/||OC]6QKvi*G\");\n classWriter0.visitInnerClass(\"I)3(E\\\"fl>%a;-7\", \"8oDTx&g*ZVx?eE@.\", \"/||OC]6QKvi*G\", 1);\n ByteVector byteVector0 = new ByteVector(1);\n String[] stringArray0 = new String[0];\n MethodWriter methodWriter0 = new MethodWriter(classWriter0, 1499, \"long\", \"Code\", \"8oDTx&g*ZVx?eE@.\", stringArray0, false, false);\n methodWriter0.put(byteVector0);\n }", "public abstract AbstractLineWriter newWriter(String filename)\r\n\t\t\tthrows FileNotFoundException, IOException;", "@Test(timeout = 4000)\n public void test03() throws Throwable {\n ClassWriter classWriter0 = new ClassWriter(2694);\n String string0 = \"\";\n MethodWriter methodWriter0 = null;\n try {\n methodWriter0 = new MethodWriter(classWriter0, (-2160), \"\", \"\", \"\", (String[]) null, true, true);\n fail(\"Expecting exception: StringIndexOutOfBoundsException\");\n \n } catch(StringIndexOutOfBoundsException e) {\n }\n }", "@Test\n public void testNewWorker() {\n BuildingWorker worker = new BuildingWorker(\"one\", 1, 0);\n\n assertTrue(worker.isWorker());\n\n assertEquals(\"one\", worker.getPlayerName());\n assertEquals(1, worker.getWorkerNumber());\n assertEquals(0, worker.getHeight());\n }", "public String getWriter() {\r\n return writer;\r\n }", "@Test\n public void testNewWorker2() {\n BuildingWorker worker = new BuildingWorker(\"two\", 2, 3);\n\n assertTrue(worker.isWorker());\n\n assertEquals(\"two\", worker.getPlayerName());\n assertEquals(2, worker.getWorkerNumber());\n assertEquals(3, worker.getHeight());\n }", "@Test(timeout = 4000)\n public void test012() throws Throwable {\n ClassWriter classWriter0 = new ClassWriter((-1983180370));\n FileSystemHandling.appendStringToFile((EvoSuiteFile) null, \"\");\n String[] stringArray0 = new String[0];\n classWriter0.visit(1, 1, \"InnerClasses\", \"\", \"EQIUR?\", stringArray0);\n classWriter0.newField(\"\", \"\", \"\\\"\");\n String[] stringArray1 = new String[4];\n stringArray1[0] = \"\\\"\";\n stringArray1[1] = \"char\";\n stringArray1[2] = \"boolean\";\n stringArray1[3] = \" ,G\";\n MethodWriter methodWriter0 = new MethodWriter(classWriter0, (-1983180370), \" ,G\", \"<T'RwU+)i.UKJX>\", \"\", stringArray1, true, true);\n methodWriter0.visitCode();\n }", "@Test\n void fileWriter() {\n\n\n ArrayList<String> fileLines = Name_Sorter.fileRead(this.readFile, \"src/main/java/oop/assignment3/ex41/base/testFile-ex41\");\n Collections.sort(fileLines);\n this.writeFile = Name_Sorter.fileWriter(this.writeFile, fileLines, \"src/main/java/oop/assignment3/ex41/base/ex41-testOutputFile.txt\");\n boolean actualOutput = this.writeFile != null;\n Assertions.assertTrue(actualOutput);\n }", "public static JsonWriter newWriter(OutputStream out) {\n if (provider == JsonProvider.UNKNOWN) {\n init();\n }\n return provider.newWriter(out);\n }", "@Test\n public void testCreateReader() {\n System.out.println(\"createReader\");\n String data = \"\";\n Reader expResult = null;\n Reader result = IOUtil.createReader(data);\n assertNotNull(\"empty string reader should not be null\", result);\n result = IOUtil.createReader(null);\n assertNull(\"null string reader should be null\", result);\n result = IOUtil.createReader(\"hello\");\n assertNotNull(\"hello string reader should not be null\", result);\n\n }", "public static FactoryWriter getInstance() {\n return FactoryWriterHolder.INSTANCE;\n }", "void messageWriter(MessageWriter messageWriter);", "public void testSetWritable_1()\n\t\tthrows Exception {\n\t\tFiles fixture = new Files();\n\t\tfixture.setAbsolutePath(\"\");\n\t\tfixture.setType(\"\");\n\t\tfixture.setReadable(\"\");\n\t\tfixture.setSize(\"\");\n\t\tfixture.setWritable(\"\");\n\t\tfixture.setExecutable(\"\");\n\t\tfixture.setMtime(\"\");\n\t\tString value = \"\";\n\n\t\tfixture.setWritable(value);\n\n\t\t\n\t}", "private void initReportWriter() {\n\t\tfinal XMLOutputFactory xmlof = XMLOutputFactory.newInstance();\r\n\r\n\t\t// Create an XML stream writer\r\n\t\tfinal File reportFile = new File(getOutputDirectory(), \"report.xml\");\r\n\t\ttry {\r\n\t\t\treportWriter = xmlof.createXMLStreamWriter(new FileWriter(reportFile));\r\n\r\n\t\t} catch (final XMLStreamException e) {\r\n\t\t\te.printStackTrace();\r\n\t\t} catch (final IOException e) {\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t}", "public abstract AbstractLineWriter newWriter(OutputStream datastream)\r\n\t\t\tthrows IOException;", "public WstxOutputFactory() {\n mConfig = WriterConfig.createFullDefaults();\n }", "public final void createReporter(){\n\n buildWriter();\n buildReporter();\n buildCloser();\n\n Validate.notNull(writer,\"Writer can not be null\");\n Validate.notNull(reporter,\"Reporter can not be null\");\n Validate.notNull(closer,\"Closer can not be null\");\n }", "public void setWriter(Writer writer) {\n this.writer = writer;\n }", "@Test(timeout = 4000)\n public void test18() throws Throwable {\n ClassWriter classWriter0 = new ClassWriter(1);\n FieldWriter fieldWriter0 = new FieldWriter(classWriter0, 2949, \"8K?-\", \":VGFU)%jS`|@:~mW<\", \":VGFU)%jS`|@:~mW<\", \":VGFU)%jS`|@:~mW<\");\n Enumeration<SequenceInputStream> enumeration0 = (Enumeration<SequenceInputStream>) mock(Enumeration.class, new ViolatedAssumptionAnswer());\n doReturn(false).when(enumeration0).hasMoreElements();\n SequenceInputStream sequenceInputStream0 = new SequenceInputStream(enumeration0);\n FieldWriter fieldWriter1 = null;\n try {\n fieldWriter1 = new FieldWriter(classWriter0, 341, \"A7P+:Q/'V,Wg4\", \"A7P+:Q/'V,Wg4\", \"<init>\", sequenceInputStream0);\n fail(\"Expecting exception: IllegalArgumentException\");\n \n } catch(IllegalArgumentException e) {\n //\n // value java.io.SequenceInputStream@7dbd3e20\n //\n verifyException(\"wheel.asm.ClassWriter\", e);\n }\n }", "@Test\n\tdefault void testAlllowedWriting() {\n\t\tperformStreamTest(stream -> {\n\t\t\tErrorlessTest.run(() -> stream.writeByte((byte) 42, 6));\n\t\t});\n\t}", "@Test(timeout = 4000)\n public void test052() throws Throwable {\n Frame frame0 = new Frame();\n Label label0 = new Label();\n Label label1 = label0.getFirst();\n frame0.owner = label1;\n FileSystemHandling.appendLineToFile((EvoSuiteFile) null, \"\");\n ClassWriter classWriter0 = new ClassWriter(16777228);\n ClassWriter classWriter1 = new ClassWriter(2);\n int int0 = Frame.INTEGER;\n Item item0 = classWriter1.newInteger(1);\n item0.set(2);\n item0.next = item0;\n item0.longVal = (long) 2;\n frame0.execute(167, 188, classWriter1, item0.next);\n assertFalse(classWriter1.equals((Object)classWriter0));\n }", "@Test(timeout = 4000)\n public void test103() throws Throwable {\n FileSystemHandling fileSystemHandling0 = new FileSystemHandling();\n ClassWriter classWriter0 = new ClassWriter((-4015));\n FileSystemHandling.setPermissions((EvoSuiteFile) null, false, false, false);\n int int0 = MethodWriter.SAME_FRAME;\n FileSystemHandling fileSystemHandling1 = new FileSystemHandling();\n String[] stringArray0 = new String[5];\n stringArray0[0] = \"dVw2ZwM){e/Y(#j\";\n stringArray0[1] = \"<T'RwU+).UKJX>\";\n stringArray0[2] = \"char\";\n stringArray0[3] = \"dVw2ZwM){e/Y(#j\";\n stringArray0[4] = \"<T'RwU+).UKJX>\";\n MethodWriter methodWriter0 = new MethodWriter(classWriter0, 2, \"char\", \"<T'RwU+).UKJX>\", \"char\", stringArray0, true, false);\n methodWriter0.classReaderOffset = 1;\n Item item0 = new Item();\n Integer integer0 = new Integer(64);\n methodWriter0.visitLdcInsn(\"dVw2ZwM){e/Y(#j\");\n ByteVector byteVector0 = new ByteVector(26);\n int int1 = methodWriter0.getSize();\n assertEquals(6, int1);\n }", "protected Writer makeWriter(OutputStream out, String enc)\r\n throws java.io.UnsupportedEncodingException {\r\n // \"UTF-8\" is not recognized before JDK 1.1.6, so we'll translate\r\n // into \"UTF8\" which works with all JDKs.\r\n if (\"UTF-8\".equals(enc)) {\r\n enc = \"UTF8\";\r\n }\r\n\r\n Writer writer = new BufferedWriter(\r\n (new OutputStreamWriter(\r\n new BufferedOutputStream(out), enc)\r\n ));\r\n return writer;\r\n }", "@TestMethod(\"testClose\")\n public void close() throws IOException {\n writer.close();\n }", "@Test(timeout = 4000)\n public void test07() throws Throwable {\n ClassWriter classWriter0 = new ClassWriter((-1284));\n FieldWriter fieldWriter0 = null;\n try {\n fieldWriter0 = new FieldWriter(classWriter0, (-1284), \"\", \"\", \"\", classWriter0);\n fail(\"Expecting exception: IllegalArgumentException\");\n \n } catch(IllegalArgumentException e) {\n //\n // value wheel.asm.ClassWriter@5\n //\n verifyException(\"wheel.asm.ClassWriter\", e);\n }\n }", "@Test(timeout = 4000)\n public void test15() throws Throwable {\n ClassWriter classWriter0 = new ClassWriter(9);\n Object object0 = new Object();\n FieldWriter fieldWriter0 = null;\n try {\n fieldWriter0 = new FieldWriter(classWriter0, 8, \"?0dqr\", \"ConstantVlue\", (String) null, object0);\n fail(\"Expecting exception: IllegalArgumentException\");\n \n } catch(IllegalArgumentException e) {\n //\n // value java.lang.Object@61854751\n //\n verifyException(\"wheel.asm.ClassWriter\", e);\n }\n }", "public static JSONWriter getInstance(){\n\t\treturn new JSONWriter();\n\t}", "@Test\n public void testWrite_LemonModel_Writer() {\n String expResult = \"<?xml version=\\\"1.0\\\" encoding=\\\"us-ascii\\\"?>\" + ls\n + \"<rdf:RDF xmlns:rdf=\\\"http://www.w3.org/1999/02/22-rdf-syntax-ns#\\\">\" + ls\n + \" <lemon:Lexicon rdf:about=\\\"file:test#lexicon\\\" xmlns:lemon=\\\"http://lemon-model.net/lemon#\\\">\" + ls\n + \" <lemon:language>en</lemon:language>\" + ls\n + \" <lemon:entry>\" + ls\n + \" <lemon:LexicalEntry rdf:about=\\\"file:test#Cat\\\">\" + ls\n + \" <lemon:canonicalForm>\" + ls\n + \" <lemon:Form rdf:about=\\\"file:test#Cat/canonicalForm\\\">\" + ls\n + \" <lemon:writtenRep xml:lang=\\\"en\\\">cat</lemon:writtenRep>\" + ls\n + \" </lemon:Form>\" + ls\n + \" </lemon:canonicalForm>\" + ls\n + \" <lemon:sense>\" + ls\n + \" <lemon:LexicalSense rdf:about=\\\"file:test#Cat/sense\\\">\" + ls\n + \" <lemon:reference rdf:resource=\\\"http://dbpedia.org/resource/Cat\\\"/>\" + ls\n + \" </lemon:LexicalSense>\" + ls\n + \" </lemon:sense>\" + ls\n + \" </lemon:LexicalEntry>\" + ls\n + \" </lemon:entry>\" + ls\n + \" </lemon:Lexicon>\" + ls\n + \"</rdf:RDF>\";\n //System.out.println(\"write\");\n LemonSerializerImpl instance = new LemonSerializerImpl(null);\n LemonModel model = makeModel(instance);\n Writer target = new StringWriter();\n instance.write(model, target);\n //System.out.println(target.toString());\n assertEquals(expResult.replaceAll(\"\\\\s\", \"\").toLowerCase(), target.toString().replaceAll(\"\\\\s\", \"\").toLowerCase());\n }", "@Test(timeout = 4000)\n public void test102() throws Throwable {\n ClassWriter classWriter0 = new ClassWriter((-2450));\n String string0 = \"9~\\\"GM0+ ?&-(JmN[0f.\";\n FileSystemHandling.appendLineToFile((EvoSuiteFile) null, \"`abrPw?i1\");\n MethodWriter methodWriter0 = new MethodWriter(classWriter0, (-2450), \"9~\\\"GM0+ ?&-(JmN[0f.\", \"Fj)3/|(;sZXz$\", \"oc[MfnZM[~MHOK iO\", (String[]) null, false, false);\n Object object0 = new Object();\n classWriter0.newInteger((-2450));\n classWriter0.newDouble((-2450));\n Item item0 = classWriter0.key3;\n // Undeclared exception!\n try { \n methodWriter0.visitFrame((-1), 2, (Object[]) null, 2, (Object[]) null);\n fail(\"Expecting exception: NullPointerException\");\n \n } catch(NullPointerException e) {\n //\n // no message in exception (getMessage() returned null)\n //\n verifyException(\"org.objectweb.asm.jip.MethodWriter\", e);\n }\n }", "@Test(timeout = 4000)\n public void test21() throws Throwable {\n ClassWriter classWriter0 = new ClassWriter(2452);\n FieldWriter fieldWriter0 = new FieldWriter(classWriter0, 2452, \"yY^e*Uz#>@n8v((\", \"yY^e*Uz#>@n8v((\", \"yY^e*Uz#>@n8v((\", \"yY^e*Uz#>@n8v((\");\n FieldWriter fieldWriter1 = null;\n try {\n fieldWriter1 = new FieldWriter(classWriter0, 1, (String) null, (String) null, \"yY^e*Uz#>@n8v((\", \"yY^e*Uz#>@n8v((\");\n fail(\"Expecting exception: NullPointerException\");\n \n } catch(NullPointerException e) {\n //\n // no message in exception (getMessage() returned null)\n //\n }\n }", "@Test(timeout = 4000)\n public void test056() throws Throwable {\n FileSystemHandling fileSystemHandling0 = new FileSystemHandling();\n ClassWriter classWriter0 = new ClassWriter((-4015));\n String string0 = \"+t1`X]_2(_63\";\n MethodWriter methodWriter0 = new MethodWriter(classWriter0, 2, \"dVw2Z7M){e/Y(#j\", \"dVw2Z7M){e/Y(#j\", \"dVw2Z7M){e/Y(#j\", (String[]) null, false, true);\n Label label0 = new Label();\n Label label1 = label0.getFirst();\n Label[] labelArray0 = new Label[1];\n labelArray0[0] = label1;\n methodWriter0.visitTableSwitchInsn(14, 1, label1, labelArray0);\n methodWriter0.visitAnnotationDefault();\n String string1 = \"qBd*JX4Q%HiR1LZ\";\n methodWriter0.visitTypeInsn(57, \"qBd*JX4Q%HiR1LZ\");\n MethodWriter methodWriter1 = classWriter0.lastMethod;\n MockFileInputStream mockFileInputStream0 = null;\n try {\n mockFileInputStream0 = new MockFileInputStream((File) null);\n fail(\"Expecting exception: NullPointerException\");\n \n } catch(NullPointerException e) {\n //\n // no message in exception (getMessage() returned null)\n //\n verifyException(\"org.evosuite.runtime.mock.java.io.MockFileInputStream\", e);\n }\n }", "public static Writer createWriter(Path path,\n WriterOptions opts\n ) throws IOException {\n FileSystem fs = opts.fileSystemValue == null ?\n path.getFileSystem(opts.configuration) : opts.fileSystemValue;\n\n return new WriterImpl(fs, path, opts.configuration, opts.inspectorValue,\n opts.stripeSizeValue, opts.compressValue,\n opts.bufferSizeValue, opts.rowIndexStrideValue,\n opts.memoryManagerValue, opts.blockPaddingValue,\n opts.versionValue);\n }", "@Test(timeout = 4000)\n public void test31() throws Throwable {\n StringWriter stringWriter0 = new StringWriter(70);\n char[] charArray0 = new char[10];\n charArray0[1] = 'T';\n charArray0[5] = 'T';\n stringWriter0.write(70);\n charArray0[2] = 'T';\n charArray0[2] = '\\u0000';\n stringWriter0.write(charArray0);\n StringWriter stringWriter1 = new StringWriter('T');\n StringWriter stringWriter2 = new StringWriter();\n stringWriter2.write(charArray0);\n stringWriter0.write(charArray0);\n stringWriter0.close();\n StringWriter stringWriter3 = new StringWriter();\n stringWriter2.flush();\n stringWriter2.close();\n StringWriter stringWriter4 = new StringWriter('T');\n stringWriter1.write((int) 'T');\n StringWriter stringWriter5 = new StringWriter();\n stringWriter3.close();\n StringWriter stringWriter6 = new StringWriter('\\u0000');\n stringWriter2.flush();\n stringWriter2.flush();\n StringWriter stringWriter7 = new StringWriter('T');\n stringWriter0.write(90);\n stringWriter0.write(\"*le\");\n SimpleNode simpleNode0 = new SimpleNode('T');\n stringWriter3.write(204);\n StringWriter stringWriter8 = new StringWriter(70);\n stringWriter0.flush();\n stringWriter1.write(\"n~}KXk4pnRbMtpaDYJ\");\n simpleNode0.setIdentifier(\"ForUpdate\");\n stringWriter7.write(charArray0);\n simpleNode0.dump(\"n~}KXk4pnRbMtpaDYJ\", stringWriter2);\n assertEquals(\"\\u0000T\\u0000\\u0000\\u0000T\\u0000\\u0000\\u0000\\u0000<ForInit>\\n <identifier>ForUpdate</identifier>\\n</ForInit>\\n\", stringWriter2.toString());\n }", "public PrintWriter getTestCommentWriter() {\n return sections[0].getMessageWriter();\n }", "@Test\n\tvoid test() throws IOException\n\t{\n\t\t\tFile f1=new File(\"testcase1.txt\");\n\t\t\tf1.createNewFile();\n\t\t\tFileWriter fileWriter;\n\t\t\tfileWriter = new FileWriter(f1.getPath());\n\t\t\tString str1=\"I am a test string and number one two three four five six seven eight nine ten eleven twelve.\";\n\t\t\tfileWriter.write(str1);\n\t\t fileWriter.close();\n\n\t\t /**\n\t\t * TO-DO\n\t\t * call formatter to get actual.txt\n\t\t */\n\t\t \n\t\t File f2=new File(\"expected1.txt\");\n\t\t\tf2.createNewFile();\n\t\t\tFileWriter fileWriter2 = new FileWriter(f2.getPath());\n\t\t\tString str2=\"I am a test string and number one two three four five six seven eight nine ten\\neleven twelve.\";\n\t\t\tfileWriter2.write(str2);\n\t\t fileWriter2.close();\n\t\t \t\t \n\t\t\tassertFalse(equalFile(\"testcase1.txt\",\"expected1.txt\"));\t\n\t}", "SocketWriter newSocketWriter(SocketConnection connection);", "@Test(timeout = 4000)\n public void test021() throws Throwable {\n ClassWriter classWriter0 = new ClassWriter((-1790259326));\n Item item0 = new Item(1);\n String[] stringArray0 = new String[4];\n stringArray0[0] = \"LocalVariableTable\";\n stringArray0[1] = \"LocalVariableTable\";\n stringArray0[2] = \"H\";\n stringArray0[3] = \"H\";\n FileSystemHandling.shouldAllThrowIOExceptions();\n MethodWriter methodWriter0 = new MethodWriter(classWriter0, (-1790259326), \"H\", \"Fj)3/|(;sZXz$\", \"LocalVariableTable\", stringArray0, true, true);\n methodWriter0.visitVarInsn(191, 1);\n ClassWriter classWriter1 = new ClassWriter((-1790259326));\n MethodWriter methodWriter1 = null;\n try {\n methodWriter1 = new MethodWriter(classWriter0, 2, \"l\", (String) null, \"RuntimeInvisibleAnnotations\", stringArray0, true, true);\n fail(\"Expecting exception: NullPointerException\");\n \n } catch(NullPointerException e) {\n //\n // no message in exception (getMessage() returned null)\n //\n }\n }", "@Test(timeout = 4000)\n public void test05() throws Throwable {\n StringWriter stringWriter0 = new StringWriter(70);\n char[] charArray0 = new char[9];\n charArray0[0] = 'T';\n stringWriter0.write(70);\n stringWriter0.write(charArray0);\n StringWriter stringWriter1 = new StringWriter();\n StringWriter stringWriter2 = new StringWriter();\n stringWriter2.write(charArray0);\n stringWriter1.write(charArray0);\n StringBuffer stringBuffer0 = new StringBuffer();\n StringWriter stringWriter3 = stringWriter1.append((CharSequence) stringBuffer0);\n stringWriter2.flush();\n StringWriter stringWriter4 = new StringWriter(70);\n stringWriter2.write(63);\n StringWriter stringWriter5 = new StringWriter();\n stringWriter3.close();\n stringWriter5.flush();\n StringWriter stringWriter6 = new StringWriter(70);\n SimpleNode simpleNode0 = new SimpleNode(63);\n stringWriter2.write(1);\n StringWriter stringWriter7 = new StringWriter(63);\n stringWriter0.flush();\n stringWriter3.write(\"k}^Bdh;XfPc/Onl>.\");\n simpleNode0.setIdentifier(\"null\");\n stringWriter0.write(charArray0);\n simpleNode0.dump(\"*gt\", stringWriter0);\n assertEquals(\"FT\\u0000\\u0000\\u0000\\u0000\\u0000\\u0000\\u0000\\u0000T\\u0000\\u0000\\u0000\\u0000\\u0000\\u0000\\u0000\\u0000<Literal>\\n<identifier>Literal Value</identifier>\\n</Literal>\\n\", stringWriter0.toString());\n }", "public static TeaFileWriter getWriter(String fileFormat) {\r\n\t\t\r\n\t\tfor(FileFormats ff : FileFormats.values()) {\r\n\t\t\tif(ff.equals(fileFormat)) {\r\n\t\t\t\treturn ff.writer;\r\n\t\t\t}\r\n\t\t}\r\n\t\t// Default. Should never happen :)\r\n\t\treturn new TextWriter();\r\n\t}", "@Test(timeout = 4000)\n public void test041() throws Throwable {\n Frame frame0 = new Frame();\n Label label0 = new Label();\n Label label1 = label0.getFirst();\n frame0.owner = label1;\n FileSystemHandling.appendLineToFile((EvoSuiteFile) null, \"\");\n ClassWriter classWriter0 = new ClassWriter(16777228);\n ClassWriter classWriter1 = new ClassWriter(2);\n ClassWriter classWriter2 = new ClassWriter(2);\n int int0 = Frame.INTEGER;\n FileSystemHandling fileSystemHandling0 = new FileSystemHandling();\n Item item0 = classWriter0.newDouble(0.0);\n frame0.execute(1, 2, classWriter1, item0);\n assertFalse(classWriter1.equals((Object)classWriter2));\n }", "static void mainTest(PrintWriter out) throws Exception {\n\t}", "private PrintWriter getWriter(String signature) throws IOException {\n\n\tFile f = signature2file.get(signature);\n\n\tif (f == null) {\n\n\t throw new IllegalStateException(\"Supposed to have file name for \"\n\t\t + signature + \", but don't???\");\n\t}\n\n\t// Create a FileWriter with 'append'\n\treturn new PrintWriter(new FileWriter(f, true));\n }", "XMLWriter getStringWriter() {\n\t\tOutputFormat format = new OutputFormat(\" \", true);\n\t\tformat.setTrimText(true);\n\t\tStringWriter sw = new StringWriter();\n\t\ttry {\n\t\t\tstringWriter = new XMLWriter(sw, format);\n\t\t} catch (Exception e) {\n\t\t\tprtln(\"getStringWriter(): \" + e);\n\t\t}\n\n\t\tprtln(\" ... format.encoding: \" + format.getEncoding());\n\t\tprtln(\" ... format.isNewLines: \" + format.isNewlines());\n\t\tprtln(\" ... format.isTrimText: \" + format.isTrimText());\n\t\tprtln(\" ... format.indent: \\'\" + format.getIndent() + \"\\'\");\n\n\t\tstringWriter.setEscapeText(false);\n\t\tif (stringWriter.isEscapeText()) {\n\t\t\tprtln(\" ... isEscapeText\");\n\t\t} else {\n\t\t\tprtln(\" ... is NOT escapeText\");\n\t\t}\n\t\treturn stringWriter;\n\t}", "public void testWriteOrders() throws Exception {\n }", "@Test(timeout = 4000)\n public void test091() throws Throwable {\n ClassWriter classWriter0 = new ClassWriter((-2450));\n FileSystemHandling fileSystemHandling0 = new FileSystemHandling();\n MethodWriter methodWriter0 = new MethodWriter(classWriter0, (-2450), \"9~\\\"GM0+ ?&-(JmN[0f.\", \"Fj)3/|(;sZXz$\", \"oc[MfnZM[~MHOK iO\", (String[]) null, true, false);\n methodWriter0.visitVarInsn(63, 2);\n FieldWriter fieldWriter0 = classWriter0.firstField;\n Object object0 = new Object();\n Object object1 = new Object();\n methodWriter0.visitFrame(17, (-1299), (Object[]) null, (-2450), (Object[]) null);\n int int0 = MethodWriter.SAME_LOCALS_1_STACK_ITEM_FRAME;\n FileSystemHandling.setPermissions((EvoSuiteFile) null, false, true, true);\n methodWriter0.visitTypeInsn(8, \"java/lang/Throwable\");\n FileSystemHandling.appendStringToFile((EvoSuiteFile) null, \"oc[MfnZM[~MHOK iO\");\n Label label0 = new Label();\n methodWriter0.visitFieldInsn(2, \"k!Hb\", \"java/lang/Throwable\", \"Deprecated\");\n Integer integer0 = new Integer(64);\n methodWriter0.visitLdcInsn(integer0);\n Label label1 = new Label();\n methodWriter0.visitLabel(label1);\n methodWriter0.visitLdcInsn(\"oc[MfnZM[~MHOK iO\");\n methodWriter0.visitLineNumber(196, label0);\n assertNotSame(label0, label1);\n }", "@Test(timeout = 4000)\n public void test029() throws Throwable {\n FileSystemHandling fileSystemHandling0 = new FileSystemHandling();\n ClassWriter classWriter0 = new ClassWriter((-4015));\n MethodWriter methodWriter0 = new MethodWriter(classWriter0, 2, \"dVw2Z7M){e/Y(#j\", \"dVw2Z7M){e/Y(#j\", \"dVw2Z7M){e/Y(#j\", (String[]) null, false, false);\n methodWriter0.visitInsn((-4015));\n FieldWriter fieldWriter0 = classWriter0.firstField;\n classWriter0.firstField = null;\n Object[] objectArray0 = new Object[7];\n objectArray0[0] = (Object) \"+t1`X]_2(_63\";\n Attribute attribute0 = new Attribute(\"zLWhmp0G*{\");\n ClassReader classReader0 = null;\n try {\n classReader0 = new ClassReader(\"dVw2Z7M){e/Y(#j\");\n fail(\"Expecting exception: IOException\");\n \n } catch(Throwable e) {\n //\n // Class not found\n //\n verifyException(\"org.objectweb.asm.jip.ClassReader\", e);\n }\n }", "public Writer getWriter() \r\n\t{\r\n\tif (null == writer)\r\n\t\twriter = new PrintWriter(System.out);\r\n\treturn writer;\r\n\t}", "public static Test suite() {\n \t\treturn new TestSuite(ModelObjectReaderWriterTest.class);\n \t}", "@Test(timeout = 4000)\n public void test058() throws Throwable {\n ClassWriter classWriter0 = new ClassWriter((-1983180370));\n FileSystemHandling.appendStringToFile((EvoSuiteFile) null, \"/||OC]6QKvi*G\");\n FileSystemHandling.setPermissions((EvoSuiteFile) null, false, false, false);\n String[] stringArray0 = new String[2];\n stringArray0[0] = \"?t|o'XqH!B#u5<FG2z\";\n stringArray0[1] = \"?t|o'XqH!B#u5<FG2z\";\n MethodWriter methodWriter0 = new MethodWriter(classWriter0, 17, \"?t|o'XqH!B#u5<FG2z\", \"?t|o'XqH!B#u5<FG2z\", \"/||OC]6QKvi*G\", stringArray0, false, false);\n methodWriter0.visitVarInsn(17, 2);\n MethodWriter methodWriter1 = classWriter0.firstMethod;\n methodWriter1.visitIntInsn(17, 172);\n MethodWriter methodWriter2 = classWriter0.firstMethod;\n methodWriter2.visitInsn(1);\n assertSame(methodWriter2, methodWriter1);\n }", "public interface Writer {\n\n void write(ResultEntry resultEntry) throws IOException;\n\n}", "@Test(timeout = 4000)\n public void test06() throws Throwable {\n Label label0 = new Label();\n FieldWriter fieldWriter0 = null;\n try {\n fieldWriter0 = new FieldWriter((ClassWriter) null, 4360, (String) null, (String) null, \"AnnotationDefault\", label0);\n fail(\"Expecting exception: NullPointerException\");\n \n } catch(NullPointerException e) {\n //\n // no message in exception (getMessage() returned null)\n //\n verifyException(\"wheel.asm.FieldWriter\", e);\n }\n }", "protected void setUp() throws Exception {\n String workingDir = getWorkDirPath();\n new File(workingDir).mkdirs();\n File outputFile = new File(workingDir + \"/output.txt\");\n outputFile.createNewFile();\n File errorFile = new File(workingDir + \"/error.txt\");\n errorFile.createNewFile();\n PrintWriter outputWriter = new PrintWriter(new FileWriter(outputFile));\n PrintWriter errorWriter = new PrintWriter(new FileWriter(errorFile));\n org.netbeans.jemmy.JemmyProperties.setCurrentOutput(new org.netbeans.jemmy.TestOut(System.in, outputWriter, errorWriter));\n }", "@Test\n public void testGetWriteRequest() {\n System.out.println(\"getWriteRequest\");\n Connection connection = null;\n IoGeneric instance = null;\n WriteRequest expResult = null;\n WriteRequest result = instance.getWriteRequest(connection);\n assertEquals(expResult, result);\n // TODO review the generated test code and remove the default call to fail.\n fail(\"The test case is a prototype.\");\n }", "@Test(timeout = 4000)\n public void test01() throws Throwable {\n ClassWriter classWriter0 = new ClassWriter(2452);\n classWriter0.index = (-4211);\n FieldWriter fieldWriter0 = new FieldWriter(classWriter0, 2452, \"jyY)^e *Uz#>@n8v((\", \"jyY)^e *Uz#>@n8v((\", \"jyY)^e *Uz#>@n8v((\", \"jyY)^e *Uz#>@n8v((\");\n ByteVector byteVector0 = new ByteVector();\n fieldWriter0.put(byteVector0);\n }", "@Test(timeout = 4000)\n public void test067() throws Throwable {\n Frame frame0 = new Frame();\n Label label0 = new Label();\n Label label1 = label0.getFirst();\n frame0.owner = label1;\n FileSystemHandling.appendLineToFile((EvoSuiteFile) null, \"\");\n ClassWriter classWriter0 = new ClassWriter(16777228);\n ClassWriter classWriter1 = new ClassWriter(2);\n ClassWriter classWriter2 = new ClassWriter(2);\n int int0 = Frame.INTEGER;\n Item item0 = classWriter2.newInteger(1);\n item0.set(2);\n item0.next = item0;\n item0.longVal = (long) 2;\n classWriter0.toByteArray();\n frame0.execute(174, 50, classWriter1, item0);\n assertFalse(classWriter1.equals((Object)classWriter0));\n }", "@Test(timeout = 4000)\n public void test08() throws Throwable {\n StringWriter stringWriter0 = new StringWriter(70);\n char[] charArray0 = new char[10];\n charArray0[1] = 'T';\n charArray0[5] = 'T';\n stringWriter0.write(70);\n charArray0[2] = 'T';\n charArray0[2] = '\\u0000';\n stringWriter0.write(charArray0);\n StringWriter stringWriter1 = new StringWriter('T');\n StringWriter stringWriter2 = new StringWriter();\n stringWriter2.write(charArray0);\n stringWriter0.write(charArray0);\n stringWriter0.close();\n StringWriter stringWriter3 = new StringWriter();\n stringWriter2.flush();\n stringWriter2.close();\n StringWriter stringWriter4 = new StringWriter('T');\n stringWriter1.write((int) 'T');\n StringWriter stringWriter5 = new StringWriter();\n stringWriter3.close();\n StringWriter stringWriter6 = new StringWriter('\\u0000');\n stringWriter2.flush();\n stringWriter2.flush();\n StringWriter stringWriter7 = new StringWriter('T');\n stringWriter0.write(90);\n stringWriter0.write(\"*le\");\n SimpleNode simpleNode0 = new SimpleNode('T');\n stringWriter3.write(204);\n StringWriter stringWriter8 = new StringWriter(70);\n stringWriter0.flush();\n stringWriter1.write(\"n~}KXk4pnRbMtpaDYJ\");\n simpleNode0.setIdentifier(\"}\");\n stringWriter7.write(charArray0);\n simpleNode0.dump(\"n~}KXk4pnRbMtpaDYJ\", stringWriter2);\n assertEquals(\"\\u0000T\\u0000\\u0000\\u0000T\\u0000\\u0000\\u0000\\u0000<ForInit>\\n</ForInit>\\n\", stringWriter2.toString());\n }", "@Test(timeout = 4000)\n public void test027() throws Throwable {\n int int0 = 8;\n ClassWriter classWriter0 = new ClassWriter(8);\n String[] stringArray0 = new String[7];\n stringArray0[0] = \"oc[MfnZM[~xMHOK iO\";\n stringArray0[1] = \"oc[MfnZM[~xMHOK iO\";\n stringArray0[2] = \"oc[MfnZM[~xMHOK iO\";\n stringArray0[3] = \"oc[MfnZM[~xMHOK iO\";\n stringArray0[4] = \"<init>\";\n stringArray0[5] = \"oc[MfnZM[~xMHOK iO\";\n stringArray0[6] = \"oc[MfnZM[~xMHOK iO\";\n MethodWriter methodWriter0 = null;\n try {\n methodWriter0 = new MethodWriter(classWriter0, 2048, \"<init>\", \"oc[MfnZM[~xMHOK iO\", \"oc[MfnZM[~xMHOK iO\", stringArray0, true, true);\n fail(\"Expecting exception: StringIndexOutOfBoundsException\");\n \n } catch(StringIndexOutOfBoundsException e) {\n }\n }", "private NewsWriter() {\n }" ]
[ "0.72184074", "0.67673564", "0.6668672", "0.6383786", "0.63742256", "0.6293572", "0.6281074", "0.62686205", "0.6259815", "0.62559766", "0.6248378", "0.6065288", "0.60149026", "0.60013646", "0.59941137", "0.59623665", "0.5917328", "0.5906243", "0.5875125", "0.5860252", "0.5857422", "0.5845313", "0.5845016", "0.58363354", "0.58227915", "0.57849276", "0.5782705", "0.5729965", "0.57090086", "0.57055426", "0.57006", "0.5693256", "0.5692523", "0.56868994", "0.56678194", "0.5667281", "0.56620216", "0.5658324", "0.56323236", "0.56226134", "0.56205124", "0.5616647", "0.5613409", "0.56013495", "0.55954856", "0.5576529", "0.5570098", "0.5564021", "0.55611473", "0.55593044", "0.5554582", "0.55540824", "0.55293715", "0.5521475", "0.55205864", "0.55107856", "0.55034924", "0.54943407", "0.54877967", "0.54700416", "0.546266", "0.545675", "0.54522735", "0.5449558", "0.54410833", "0.5425237", "0.5420899", "0.5419485", "0.54166913", "0.5414307", "0.5407273", "0.5404747", "0.5401307", "0.54011685", "0.539213", "0.53920525", "0.53919786", "0.53895396", "0.53856117", "0.53695846", "0.5368476", "0.5367476", "0.53638434", "0.5357692", "0.53512204", "0.534949", "0.53428185", "0.5331907", "0.53124547", "0.53110343", "0.5308549", "0.530833", "0.5307475", "0.53034526", "0.5299758", "0.5297498", "0.5297026", "0.5288852", "0.5287812", "0.5287038" ]
0.7936644
0
This is the default constructor
public illumPanelEdit1() { super(); initialize(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "Constructor() {\r\n\t\t \r\n\t }", "public Constructor(){\n\t\t\n\t}", "defaultConstructor(){}", "@SuppressWarnings(\"unused\")\n public NoConstructor() {\n // Empty\n }", "public Orbiter() {\n }", "public Pitonyak_09_02() {\r\n }", "public PSRelation()\n {\n }", "public Pasien() {\r\n }", "private Instantiation(){}", "public Tbdtokhaihq3() {\n super();\n }", "public Anschrift() {\r\n }", "public Aanbieder() {\r\n\t\t}", "public CyanSus() {\n\n }", "public Chauffeur() {\r\n\t}", "public Curso() {\r\n }", "public CSSTidier() {\n\t}", "public Chick() {\n\t}", "public Coche() {\n super();\n }", "void DefaultConstructor(){}", "public Cohete() {\n\n\t}", "private Default()\n {}", "public Tbdcongvan36() {\n super();\n }", "public Generic(){\n\t\tthis(null);\n\t}", "public Lanceur() {\n\t}", "public Mannschaft() {\n }", "public Demo() {\n\t\t\n\t}", "public AntrianPasien() {\r\n\r\n }", "public Achterbahn() {\n }", "ConstructorPractice () {\n\t\tSystem.out.println(\"Default Constructor\");\n\t}", "public SgaexpedbultoImpl()\n {\n }", "@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}", "public Mitarbeit() {\r\n }", "public Odontologo() {\n }", "public Supercar() {\r\n\t\t\r\n\t}", "public Trening() {\n }", "public SlanjePoruke() {\n }", "public Phl() {\n }", "public Basic() {}", "public Ov_Chipkaart() {\n\t\t\n\t}", "public _355() {\n\n }", "public Parser()\n {\n //nothing to do\n }", "public Overview() {\n\t\t// It will work whenever i create object with using no parameter const\n\t\tSystem.out.println(\"This is constructor\");\n\t}", "public Clade() {}", "protected Asignatura()\r\n\t{}", "public Zeffit()\n {\n // TODO: initialize instance variable(s)\n }", "public Data() {\n }", "public Data() {\n }", "private Rekenhulp()\n\t{\n\t}", "public Waschbecken() {\n this(0, 0);\n }", "public Node(){\n\n\t\t}", "public EnsembleLettre() {\n\t\t\n\t}", "@Override public void init()\n\t\t{\n\t\t}", "private TMCourse() {\n\t}", "public mapper3c() { super(); }", "public Libro() {\r\n }", "public ExamMB() {\n }", "protected Betaling()\r\n\t{\r\n\t\t\r\n\t}", "@Override\n\t\tpublic void init() {\n\t\t}", "public Main() {\n\t\tsuper();\n\t}", "public Catelog() {\n super();\n }", "public Factory() {\n\t\tsuper();\n\t}", "public Data() {\n \n }", "public CMN() {\n\t}", "public PjxParser()\r\n {\r\n LOG.info(this + \" instantiated\");\r\n }", "private Main() {\n\n super();\n }", "public Magazzino() {\r\n }", "public ChaCha()\n\t{\n\t\tsuper();\n\t}", "public RngObject() {\n\t\t\n\t}", "public Alojamiento() {\r\n\t}", "public Excellon ()\n {}", "protected GraphNode() {\n }", "protected GraphNode() {\n }", "public SimOI() {\n super();\n }", "private Converter()\n\t{\n\t\tsuper();\n\t}", "public JSFOla() {\n }", "public Node() {\n }", "private Node() {\n\n }", "@Override\r\n\tpublic void init() {}", "public TTau() {}", "public Job() {\n\t\t\t\n\t\t}", "public AirAndPollen() {\n\n\t}", "public Soil()\n\t{\n\n\t}", "@Override\n public void init() {}", "public TennisCoach () {\n\t\tSystem.out.println(\">> inside default constructor.\");\n\t}", "public Livro() {\n\n\t}", "public Data() {}", "public Connection() {\n\t\t\n\t}", "public Goodsinfo() {\n super();\n }", "public DetArqueoRunt () {\r\n\r\n }", "public Car() {\r\n this(\"\", \"\", \"\", 0, Category.EMPTY, 0.00, \"\", 0, \"\", 0.00, \"\", DriveTrain.EMPTY,\r\n Aspiration.EMPTY, 0.00, 0.00, 0.00, 0.00, 0.0, 0.0, 0.0, 0.0, 0.0);\r\n }", "public Book() {\n\t\t// Default constructor\n\t}", "public Tigre() {\r\n }", "public Carrinho() {\n\t\tsuper();\n\t}", "public Content() {\n\t}", "public Rol() {}", "public Node() {\r\n\t}", "public Node() {\r\n\t}", "private Sequence() {\n this(\"<Sequence>\", null, null);\n }", "public Job() {\r\n\t\tSystem.out.println(\"Constructor\");\r\n\t}", "public Node() {\n\t}", "private NfkjBasic()\n\t\t{\n\t\t\t\n\t\t}" ]
[ "0.85315686", "0.8274922", "0.75848484", "0.74773645", "0.7456932", "0.7447545", "0.7443651", "0.7441528", "0.7410326", "0.74039483", "0.7391621", "0.7377517", "0.73672515", "0.7351425", "0.73242426", "0.7324195", "0.73132765", "0.73016304", "0.7279156", "0.7262864", "0.72578615", "0.7245583", "0.7229312", "0.72281915", "0.7211734", "0.72051984", "0.7185298", "0.7184384", "0.71790564", "0.7176436", "0.7175265", "0.71689993", "0.7151911", "0.7143988", "0.714167", "0.71416116", "0.71346617", "0.71331203", "0.7115635", "0.7104915", "0.7104565", "0.71001244", "0.7098205", "0.70919895", "0.70840013", "0.70816535", "0.70816535", "0.707803", "0.70770115", "0.70722747", "0.70719784", "0.7071146", "0.7067329", "0.7064678", "0.70623577", "0.7048247", "0.70420784", "0.70372427", "0.7030708", "0.7029412", "0.7029382", "0.7029282", "0.7024578", "0.7024181", "0.7022025", "0.70202535", "0.7017857", "0.7017089", "0.7014772", "0.7008654", "0.70085454", "0.70085454", "0.70051914", "0.7003109", "0.7000585", "0.69971156", "0.69901764", "0.6985152", "0.6983319", "0.6983309", "0.69713455", "0.6964426", "0.6964122", "0.6960143", "0.69536775", "0.6952563", "0.6951489", "0.6946712", "0.6943544", "0.69430006", "0.6937155", "0.69328207", "0.6928417", "0.69263786", "0.6925607", "0.69225854", "0.69225854", "0.69220567", "0.6916494", "0.6904696", "0.6902761" ]
0.0
-1
return ifD1.getValue()100.0;// X100 lux
public double getValue() { return ifD1.getValue();// X100 lux }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@VTID(14)\r\n double getValue();", "public double getLoX() {\r\n\treturn fieldLoX;\r\n}", "float getAccX();", "float getValue();", "float getValue();", "float getValue();", "double getValue();", "double getValue();", "double getValue();", "float getIva();", "double getDoubleValue3();", "public double getValue() {\n\t\t// TODO Auto-generated method stub\n\t\treturn 1.00;\n\t}", "double getDoubleValue1();", "float getD();", "public double getRange(){\n\n double range = fuelRemaining * fuelEconomy;\n return range;\n }", "public double getValue() {\n return 0.05;\n }", "public double getHiX() {\r\n\treturn fieldHiX;\r\n}", "public double getValue();", "double getDoubleValue2();", "public double getValue(){\n value*=100;\n value = Math.floor(value);\n value/=100;//returns to hundredths place\n return value;\n }", "public double getLow() {return low;}", "Double getValue();", "int getLumOff(){\n return getPercentageValue(\"lumOff\");\n }", "public float approach_x_GET()\n { return (float)(Float.intBitsToFloat((int) get_bytes(data, 41, 4))); }", "public int FitVal(){\r\n return _FitVal;\r\n}", "public float approach_x_GET()\n { return (float)(Float.intBitsToFloat((int) get_bytes(data, 40, 4))); }", "double getRealValue();", "double getrx() {\nreturn this.rx;\n }", "public double getValue(){\n return value;\n }", "double getPValue();", "@Override\n public double getValue() {\n return 0;\n }", "@Override\r\n\tpublic double getX1() {\n\t\treturn 0;\r\n\t}", "public float getW1 () {\r\n return w1;\r\n }", "public double x() { return _x; }", "public double lo() {\n return lo;\n }", "int getLikelihoodValue();", "public abstract double getValue();", "int getLum(){\n return getPercentageValue(\"lum\");\n }", "@Override\n\tpublic double fiyatlandir() {\n\t\treturn 7.95;\n\t}", "private float getRsiPotential() {\r\n\t\treturn 1F - (float)(stochRsiCalculator.getCurrentValue()/50.0);\r\n\t}", "int getLumMod(){\n return getPercentageValue(\"lumMod\");\n }", "public double getX1() {\n\t\treturn x1;\n\t}", "float getLt();", "@Override\n public double getValue()\n {\n return value;\n }", "double getBasedOnValue();", "double getX(){\r\n\t\treturn x;\r\n\t}", "public double x() {return _x;}", "public abstract Double getDataValue();", "public void cal_AdjustedFuelMoist(){\r\n\tADFM=0.9*FFM+0.5+9.5*Math.exp(-BUO/50);\r\n}", "public double value(){\n\t return (double) this.f;\n }", "public float approach_y_GET()\n { return (float)(Float.intBitsToFloat((int) get_bytes(data, 45, 4))); }", "public abstract double getValue(R1Interval interval);", "@AnyLogicInternalCodegenAPI\n private double __plot_expression0_dataSet_xjal_YValue() {\n return \nI \n;\n }", "public double x() { return x; }", "int range(){\n return fuelcap*mpg;\n }", "public float getDCD();", "public abstract float mo9744i();", "public double getValue(Hashtable positions, int[] conf) {\n\n return 0.0;\n}", "public float getDCL();", "public double getValue() {\n\t\treturn(value);\n\t}", "public double getX1()\n {\n return m_X1;\n }", "public Double getTVA()\n {\n return (20.0/100.0);\n }", "public java.lang.Double getVar111() {\n return var111;\n }", "public double getLoY() {\r\n\treturn fieldLoY;\r\n}", "public float getX1() {\r\n return (b + 3*a)/3;\r\n }", "public double getValue(){\n\t\treturn slider.getValue() ;\n\t}", "int getSat(){\n return getPercentageValue(\"sat\");\n }", "public double getResistance() \n {\n //dummy return value.\n return 0;\n }", "int getMPValue();", "public double getX(){\n return x;\n }", "public int getValue() {\n/* 450 */ return this.value;\n/* */ }", "protected float l()\r\n/* 72: */ {\r\n/* 73: 84 */ return 0.0F;\r\n/* 74: */ }", "@AnyLogicInternalCodegenAPI\n private double __plot_expression1_dataSet_xjal_YValue() {\n return \nS \n;\n }", "public double getx0()\n\t{\n\t\treturn this.x0;\n\t}", "public double getF();", "public double getX(){\r\n return x;\r\n }", "@Override\n\tpublic double getValue() {\n\t\treturn value;\n\t}", "public java.lang.Double getVar111() {\n return var111;\n }", "int getSatMod(){\n return getPercentageValue(\"satMod\");\n }", "double getAxon();", "public abstract float getValue();", "private double getValue() {\n return value;\n }", "float mo56157b();", "public double getFLAngle(){\r\n \treturn frontLeftPot.get() - FLOFFSET;\r\n }", "float xMax();", "public float spiderScaleAmount()\n {\nreturn 1F;\n }", "float getB();", "public double getFlete(){\n return localFlete;\n }", "public double GetX(){\n return this._X;\n }", "float getLte();", "float getA();", "public double getLoZ() {\r\n\treturn fieldLoZ;\r\n}", "public double x() {\n\t\treturn x;\n\t}", "public BigDecimal getLBR_DIFAL_TaxRateFCPUFDest();", "int getSatOff(){\n return getPercentageValue(\"satOff\");\n }", "public double getHiY() {\r\n\treturn fieldHiY;\r\n}", "int getCoorX();", "public double getB1() {\n return B1;\n }", "public double getX1()\n\t{\n\t\treturn this.x[1];\n\t}", "public double value() {\r\n return value;\r\n }" ]
[ "0.6832763", "0.67398816", "0.6721467", "0.6698777", "0.6698777", "0.6698777", "0.66829854", "0.66829854", "0.66829854", "0.66701204", "0.6654627", "0.66249883", "0.6502648", "0.6444885", "0.64383817", "0.64342123", "0.642001", "0.64168763", "0.6408717", "0.6400617", "0.6364355", "0.63356936", "0.63208526", "0.6293716", "0.6292403", "0.62667304", "0.6219433", "0.62041545", "0.6201215", "0.61745197", "0.61711603", "0.6168746", "0.61600184", "0.61595166", "0.61577666", "0.6155176", "0.61526173", "0.6143891", "0.61303544", "0.6115867", "0.61156785", "0.6113592", "0.61062306", "0.6097391", "0.60954994", "0.6095198", "0.60898435", "0.6071119", "0.60703886", "0.60579354", "0.6051343", "0.6045654", "0.6035996", "0.6030835", "0.60303277", "0.6028667", "0.6023849", "0.60229623", "0.60223424", "0.6022322", "0.6020228", "0.6019838", "0.6016177", "0.60146326", "0.60130733", "0.6011189", "0.600268", "0.59978884", "0.5991127", "0.5984719", "0.5984704", "0.59799373", "0.5974319", "0.59662974", "0.5964351", "0.5963787", "0.5962496", "0.5961807", "0.59612054", "0.5956593", "0.5951356", "0.59494674", "0.59452575", "0.59370375", "0.5933629", "0.5932942", "0.5924182", "0.59217465", "0.5911866", "0.59102374", "0.5909927", "0.5908017", "0.58905506", "0.5877161", "0.58743393", "0.5872644", "0.58675694", "0.58669573", "0.58621764", "0.5860956" ]
0.8334092
0
This method initializes this
private void initialize() { GridLayout gridLayout = new GridLayout(); gridLayout.setRows(1); GridBagLayout gridbag = new GridBagLayout(); base=new JPanel(gridbag); base.setBackground(new Color(250,251,245)); // default size base.setComponentOrientation(ComponentOrientation.LEFT_TO_RIGHT); //base.setPreferredSize(new Dimension(200,320)); /* // separator GridBagConstraints constraints1 = new GridBagConstraints(); constraints1.gridx = 0; constraints1.gridy = 0; constraints1.gridwidth= 1; constraints1.gridheight = 1; constraints1.insets = new Insets(0, 0, 0, 0); JSeparator vspr=new JSeparator(JSeparator.HORIZONTAL); vspr.setPreferredSize(new Dimension(200, 20)); gridbag.setConstraints(vspr, constraints1); base.add(vspr); */ // panel1 String st = Path.getPath()+"/images//program_h6_bg_illuminance.gif"; if(IsMacorWin.isMacOrWin()==false) st = Path.getPath()+"images\\/program_h6_bg_illuminance.gif"; gJPanel = new GJPanel(st); gJPanel.setText("LEDライト"); GridBagConstraints constraints1 = new GridBagConstraints(); constraints1.gridx = 0; constraints1.gridy = 1; constraints1.gridwidth= 1; constraints1.gridheight = 1; constraints1.insets = new Insets(0, 0, 0, 0); gridbag.setConstraints(gJPanel, constraints1); base.add(gJPanel); // panel JPanel jp1=new JPanel(); jp1.setComponentOrientation(ComponentOrientation.LEFT_TO_RIGHT); jp1.setLayout(gridLayout); // jp1.setPreferredSize(new Dimension(gJPanel.getWidth(),gJPanel.getHeight())); jp1.setPreferredSize(new Dimension(160,50)); jp1.setBackground(Color.gray); // ifD1=new InfoDispEdit(); ifD1.setText("警告下限照度"); // lux String[] illumdata=new String[50]; for(int i=0;i<50;i++){ illumdata[i]= String.valueOf(i*100); } ifD1.setSelectionItems(illumdata); ifD1.setSelectedIndex(22);// 2500 lux ifD1.setUnit("lux"); // GridBagConstraints constraints2 = new GridBagConstraints(); constraints2.gridy = 0; constraints2.gridy = 2; constraints2.gridwidth= 1; constraints2.gridheight = 1; constraints2.insets = new Insets(0, 0, 0, 0); gridbag.setConstraints(ifD1, constraints2); if(Version.getRevision().equals("Education")!=true) base.add(ifD1); setParentClass(this); this.setLayout(new BorderLayout()); this.add( base, BorderLayout.CENTER ); // 観察される人を生成 observableMan = new ObservableMan(); // デフォルトの観察者を追加 defaultO=new PlantPrgEdit.ObserverA(); observableMan.addObserver(defaultO); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override public void init()\n\t\t{\n\t\t}", "public void initialize()\n {\n }", "@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}", "public void init() {\n \n }", "@Override\n\t\tpublic void init() {\n\t\t}", "protected void initialize() {\n \t\n }", "@Override\r\n\tpublic void init() {}", "@Override\n public void initialize() {\n \n }", "public void init() {\n\t\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "public void initialize(){\n\t\t//TODO: put initialization code here\n\t\tsuper.initialize();\n\t\t\n\t}", "public void init() {\r\n\t\t// to override\r\n\t}", "@Override\n protected void init() {\n }", "@Override\n public void init() {}", "@Override\r\n\tpublic void init()\r\n\t{\n\t}", "protected void initialize() {}", "protected void initialize() {}", "@Override\r\n public void initialize()\r\n {\n }", "@Override\n\tprotected void initialize() {\n\n\t}", "@Override\r\n\tpublic final void init() {\r\n\r\n\t}", "@Override\n public void init() {\n\n super.init();\n\n }", "public void init() {\r\n\r\n\t}", "@Override\n\tpublic void init()\n\t{\n\n\t}", "protected void initialize() {\r\n }", "protected void initialize() {\r\n }", "public void initialize() {\n // empty for now\n }", "@Override\n public void initialize() {\n }", "@Override\n public void initialize() {\n }", "@Override\n public void initialize() {\n }", "@Override\n public void init() {\n }", "@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() \n {\n \n }", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "protected void init() {\n // to override and use this method\n }", "public void initialize() {\r\n }", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "public void init(){\n \n }", "private void init() {\n\n\t}", "protected void initialize() {\n\n\t}", "protected void initialize()\r\n {\n }", "public void init() {\n\n\t}", "public void init() {\n\n\t}", "public void init() {\n\n\t}", "@Override\n\tprotected void initialize() {\n\t}", "@Override\n\tprotected void initialize() {\n\t}", "@Override\n public void initialize() {\n }", "@Override\n public void initialize() {\n }", "@Override\n public void initialize() {\n }", "@Override\n public void initialize() {\n }", "@Override\n public void initialize() {\n }", "@Override\n public void initialize() {\n }", "@Override\n public void initialize() {\n }", "@Override\n public void initialize() {\n }", "@Override\n public void initialize() {\n }", "@Override\n public void initialize() {\n }", "@Override\n public void initialize() {\n\n }", "@Override\n public void initialize() {\n\n }", "@Override\n\tpublic void initialize() {\n\t\t\n\t}", "public void init() {\n\t\t\n\t}", "protected void initialize() {\n }", "protected void initialize() {\n }", "protected void initialize() {\n }", "protected void initialize() {\n }", "protected void initialize() {\n }", "protected void initialize() {\n }", "protected void initialize() {\n }", "protected void initialize() {\n }", "protected void initialize() {\n }", "protected void initialize() {\n }", "protected void initialize() {\n }", "protected void initialize() {\n }", "protected void initialize() {\n }", "protected void initialize() {\n }", "protected void initialize() {\n }", "protected void initialize() {\n }", "protected void initialize() {\n }", "protected void initialize() {\n }", "protected void initialize() {\n\t\t\n\t}", "protected void initialize() {\n\t\t\n\t}", "protected void init() {\n }", "@Override\r\n\tpublic void init() {\n\t\tsuper.init();\r\n\t}", "@Override\n\tpublic void init() {\n\t}", "private void initialize() {\n\t\t\n\t}", "@Override\n public void init() {\n\n }", "@Override\n public void init() {\n\n }" ]
[ "0.8354825", "0.8309513", "0.8283604", "0.8257773", "0.8200911", "0.8199891", "0.8150085", "0.812387", "0.8104957", "0.8103473", "0.8103473", "0.8103473", "0.80656415", "0.8054776", "0.8038111", "0.8030163", "0.8019929", "0.7993678", "0.7993678", "0.7987857", "0.798652", "0.7983854", "0.79793257", "0.79786295", "0.7977045", "0.7972241", "0.7972241", "0.7969346", "0.7967627", "0.7967627", "0.7967627", "0.7966397", "0.796026", "0.79560524", "0.79560524", "0.7955674", "0.7955674", "0.7955674", "0.7955674", "0.7955674", "0.7955674", "0.79457337", "0.7940181", "0.7940181", "0.7940181", "0.79193515", "0.7903334", "0.7903296", "0.7903296", "0.7903296", "0.7903296", "0.7903296", "0.7902127", "0.79015803", "0.7900651", "0.7900316", "0.78990835", "0.78990835", "0.78990835", "0.7894291", "0.7894291", "0.78883314", "0.78883314", "0.78883314", "0.78883314", "0.78883314", "0.78883314", "0.78883314", "0.78883314", "0.78883314", "0.78883314", "0.7880605", "0.7880605", "0.7878887", "0.78725487", "0.7864268", "0.7864268", "0.7864268", "0.7864268", "0.7864268", "0.7864268", "0.7864268", "0.7864268", "0.7864268", "0.7864268", "0.7864268", "0.7864268", "0.7864268", "0.7864268", "0.7864268", "0.7864268", "0.7864268", "0.7864268", "0.7859564", "0.7859564", "0.7846584", "0.78357077", "0.7835328", "0.7833668", "0.78257954", "0.78257954" ]
0.0
-1
Metodo que obtiene todos los datos
@GET public List<EnterpriseUserDTO> getEnterpriseUserList(){ List <EnterpriseUserEntity> enterpriseUsers = enterpriseUsersLogic.obtenerEnterpriseUsers(); return EnterpriseUserDTO.toEnterpriseUserList(enterpriseUsers); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void limpiarDatos() {\n\t\t\n\t}", "public ArrayList<Mascota> obtenerDatos(){\n\n BaseDatos db = new BaseDatos(context);\n\n ArrayList<Mascota> aux = db.obtenerTodoslosContactos();\n\n if(aux.size()==0){\n insertarMascotas(db);\n aux = db.obtenerTodoslosContactos();\n }\n\n return aux;\n }", "@Override\r\npublic List<Map<String, Object>> readAll() {\n\treturn detalle_pedidoDao.realAll();\r\n}", "public ArrayList<ProductoDTO> mostrartodos() {\r\n\r\n\r\n PreparedStatement ps;\r\n ResultSet res;\r\n ArrayList<ProductoDTO> arr = new ArrayList();\r\n try {\r\n\r\n ps = conn.getConn().prepareStatement(SQL_READALL);\r\n res = ps.executeQuery();\r\n while (res.next()) {\r\n\r\n arr.add(new ProductoDTO(res.getInt(1), res.getString(2), res.getString(3), res.getInt(4), res.getInt(5), res.getString(6), res.getString(7), res.getString(8), res.getString(9)));\r\n }\r\n } catch (SQLException ex) {\r\n JOptionPane.showMessageDialog(null, \"error vuelva a intentar\");\r\n } finally {\r\n conn.cerrarconexion();\r\n\r\n }\r\n return arr;\r\n\r\n }", "public Cursor CargarTodosLosDatos()\n {\n return db.query(DATABASE_TABLE, new String[] {KEY_ATRIBUTO01}, null, null, null, null, null);\n }", "@Override\r\n public List<Assunto> buscarTodas() {\r\n EntityManager em = PersistenceUtil.getEntityManager();\r\n Query query = em.createQuery(\"FROM Assunto As a\");\r\n return query.getResultList();\r\n }", "public ArrayList<Contacto> obtenerDatos(){\n\n BaseDatos db=new BaseDatos(context);\n insertarContactos(db);\n\n return db.obtenerTodosContactos();\n\n }", "public ArrayList<DataUsuario> listarUsaurios();", "List<Persona> obtenerTodasLasPersona();", "protected List<List> cargarDatos() throws ExcArgumentoInvalido {\n\t\treturn null;\n\t}", "private void getObsequios(){\n mObsequios = estudioAdapter.getListaObsequiosSinEnviar();\n //ca.close();\n }", "@Override\n public List recuperarTodosLosElementos(Class clase) {\n Query query = database.query();\n query.constrain(clase);\n ObjectSet result = query.execute();\n return result;\n }", "private void caricaLista() {\n /** variabili e costanti locali di lavoro */\n ArrayList unaLista = null;\n CampoDati unCampoDati = null;\n CDBLinkato unCampoDBLinkato = null;\n //@todo da cancellare\n try { // prova ad eseguire il codice\n /* recupera il campo DB specializzato */\n unCampoDBLinkato = (CDBLinkato)unCampoParente.getCampoDB();\n\n /* recupera la lista dal campo DB */\n unaLista = unCampoDBLinkato.caricaLista();\n\n /* recupera il campo dati */\n unCampoDati = unCampoParente.getCampoDati();\n\n /* registra i valori nel modello dei dati del campo */\n if (unaLista != null) {\n unCampoDati.setValoriInterni(unaLista);\n// unCampoDatiElenco.regolaElementiAggiuntivi();\n } /* fine del blocco if */\n\n } catch (Exception unErrore) { // intercetta l'errore\n /* mostra il messaggio di errore */\n Errore.crea(unErrore);\n } /* fine del blocco try-catch */\n\n }", "public List<String> getAllData(){\n\t}", "private ArrayList<String[]> getTodasOS() {\n ArrayList <OrdemServico> os = new OS_Controller(this).buscarTodasOrdemServicos();\n\n ArrayList<String[]> rows = new ArrayList<>();\n ArrayList<OrdemServico> ordemServicos=new ArrayList<>();\n\n for (OrdemServico ordemServico :os){\n String id = String.valueOf(ordemServico.getId());\n String numero = ordemServico.getNumero_ordem_servico();\n String cliente = ordemServico.getCliente().getNome();\n SimpleDateFormat formato = new SimpleDateFormat(\"dd-MM-yyyy\");\n String dataEntrada = formato.format(ordemServico.getData_entrada());\n String status = ordemServico.getStatus_celular();\n String tecnico = ordemServico.getTecnico_responsavel();\n String precoFinal = ordemServico.getValor_final();\n String marca = ordemServico.getMarca();\n String modelo = ordemServico.getModelo();\n\n rows.add(new String[]{id,numero,dataEntrada, marca, modelo,cliente,status,tecnico, precoFinal});\n ordemServicos.add(ordemServico);\n }\n //String cliente = String.valueOf(os.getCliente());\n return rows;\n\n }", "Serializable retrieveAllData();", "public List<PerfilTO> buscarTodos();", "@Override\n\tpublic List<ExamenDTO> obtenerTodos() {\n\t\tList<ExamenDTO> examenes= new ArrayList<ExamenDTO>();\n\t\tdao.findAll().forEach(e -> examenes.add(Mapper.getDTOFromEntity(e)));\n\t\treturn examenes;\n\t}", "public ArrayList consultarTodo() {\n Cursor cursor = this.myDataBase.rawQuery(\"SELECT des_invfisico_tmp._id,des_invfisico_tmp.cod_ubicacion,des_invfisico_tmp.cod_referencia,des_invfisico_tmp.cod_plu,plu.descripcion FROM des_invfisico_tmp LEFT OUTER JOIN plu ON plu.cod_plu = des_invfisico_tmp.cod_plu \", null);\n ArrayList arrayList = new ArrayList();\n new ArrayList();\n if (cursor.moveToFirst()) {\n do {\n for (int i = 0; i <= 4; ++i) {\n if (cursor.isNull(i)) {\n arrayList.add(\"\");\n continue;\n }\n arrayList.add(cursor.getString(i));\n }\n } while (cursor.moveToNext());\n }\n\n return arrayList;\n }", "private void cargarDatosDefault() {\n\t\tPersonasJSON personas = new PersonasJSON();\n\t\tpersonas = personas.leerJSON(\"src/datosJSON/Personas.JSON\");\n\t\t\n\t\tfor(int i=0 ; i<personas.getCantidadPersonas(); i++) {\n\t\t\t\n\t\t\tString nombre = personas.getPersona(i).getNombre();\n\t\t\tint deporte = personas.getPersona(i).getDeporte();\n\t\t\tint musica = personas.getPersona(i).getMusica();\n\t\t\tint espectaculo = personas.getPersona(i).getEspectaculo();\n\t\t\tint ciencia = personas.getPersona(i).getCiencia();\n\t\t\t\n\t\t\tmodel.addRow(new String[]{ nombre, String.valueOf(deporte), String.valueOf(musica),\n\t\t\t\t\tString.valueOf(espectaculo), String.valueOf(ciencia) });\n\t\t}\n\t\t\n\t\tdatos.addAll(personas.getTodasLasPersonas());\n\t\t\n\t}", "@SuppressWarnings(\"unchecked\")\r\n\tprotected List<List> cargarDatos() throws ExcArgumentoInvalido {\n\t\treturn null;\r\n\t}", "@Override\n\tpublic List<Materia> recuperarTodo() throws DataAccessException {\n\t\treturn null;\n\t}", "private void listaContatos() throws SQLException {\n limpaCampos();\n BdLivro d = new BdLivro();\n livros = d.getLista(\"%\" + jTPesquisar.getText() + \"%\");\n\n // Após pesquisar os contatos, executa o método p/ exibir o resultado na tabela pesquisa\n mostraPesquisa(livros);\n livros.clear();\n }", "List<O> obtenertodos() throws DAOException;", "public List<Tripulante> buscarTodosTripulantes();", "@Override\n\tpublic void mostrarDados() {\n\t\t\n\t}", "public static ArrayList<obj_dos_campos> carga_tipo_producto() {\n ArrayList<obj_dos_campos> lista = new ArrayList<obj_dos_campos>();\n Connection c=null;\n try {\n c = conexion_odbc.Connexion_datos();\n Statement s = c.createStatement();\n ResultSet rs = s.executeQuery(\"select tip_prod_idn as data, tip_prod_nombre as label from tipo_producto order by tip_prod_nombre desc\");\n lista.add(new obj_dos_campos(\"0\",\"-- Seleccione --\"));\n while (rs.next()){\n lista.add(new obj_dos_campos(rs.getString(\"data\"),rs.getString(\"label\")));\n }\n } catch (Exception e) {\n e.printStackTrace();\n } finally {\n try {\n c.close();\n } catch (SQLException e) {\n e.printStackTrace();\n }\n }\n return lista;\n }", "private void listaContatos() throws SQLException {\n limpaCampos();\n DAOLivro d = new DAOLivro();\n livros = d.getLista(\"%\" + jTPesquisar.getText() + \"%\"); \n \n // Após pesquisar os contatos, executa o método p/ exibir o resultado na tabela pesquisa\n mostraPesquisa(livros);\n livros.clear();\n }", "public ArrayList < Dataclass > getData() {\n ArrayList < Dataclass > dataList = new ArrayList < Dataclass > ();\n Connection connection = getConnection();\n String query = \"SELECT * FROM `przychodnia` \";\n if (option == 1) query = \"SELECT * FROM `lekarz` \";\n if (option == 2) query = \"SELECT * FROM `wizyta` \";\n if (option == 3) query = \"SELECT * FROM `badanie` \";\n Statement st;\n ResultSet rs;\n\n try {\n st = connection.createStatement();\n rs = st.executeQuery(query);\n Dataclass dc;\n while (rs.next()) {\n if (option == 1) dc = new Dataclass(rs.getInt(\"ID\"), rs.getString(\"Imię\"), rs.getString(\"Nazwisko\"), rs.getString(\"Specjalizacja\"), rs.getInt(\"ID_Przychodni\"));\n else if (option == 2) dc = new Dataclass(rs.getInt(\"ID\"), rs.getString(\"Data\"), rs.getString(\"Opis Badania\"), rs.getString(\"Imię i nazwisko pacjenta\"), rs.getInt(\"ID_Lekarza\"));\n else if (option == 3) dc = new Dataclass(rs.getInt(\"ID\"), rs.getString(\"Data\"), rs.getBlob(\"Załącznik\"));\n else dc = new Dataclass(rs.getInt(\"ID\"), rs.getString(\"Nazwa\"), rs.getString(\"Adres\"), rs.getString(\"Miasto\"));\n dataList.add(dc);\n }\n } catch (Exception e) {\n System.err.print(e);\n }\n return dataList;\n }", "private void getMuestras(){\n mMuestras = estudioAdapter.getListaMuestrasSinEnviar();\n //ca.close();\n }", "public List<TblRetur>getAllDataRetur();", "public void Listar() {\n try {\n ApelacionesDao apelacionesDao = new ApelacionesDao();\n this.listaApelaciones.clear();\n setListaApelaciones(apelacionesDao.cargaApelaciones());\n } catch (ExceptionConnection ex) {\n Logger.getLogger(ApelacionController.class.getName()).log(Level.SEVERE, null, ex);\n }\n }", "public void datos_elegidos(){\n\n\n }", "public List<tipoDetalle> obtenerDetallesBD(){\n List<tipoDetalle> detalles=new ArrayList<>();\n try{\n //Obteniendo el ID del auto desde la activity de Mostrar_datos\n String idAuto;\n Bundle extras=getIntent().getExtras();\n if(extras!=null)\n {\n idAuto=extras.getString(\"id_auto\");\n Log.e(\"auto\",\"el auto id es= \"+idAuto);\n ResultSet rs = (ResultSet) TNT.mostrarDetalles(idAuto);\n while (rs.next()){\n detalles.add(new tipoDetalle(rs.getString(\"id\"), rs.getString(\"nombre\"), rs.getString(\"fecha_entrada\"), rs.getString(\"fecha_salida\"), rs.getString(\"fecha_terminacion\"), rs.getString(\"estado\"), rs.getString(\"descripcion\"), rs.getString(\"costo\")));\n }\n }\n }catch(SQLException e){\n Toast.makeText(getApplicationContext(),e.getMessage(),Toast.LENGTH_SHORT).show();\n }\n return detalles;\n }", "List<ParqueaderoEntidad> listar();", "public List<Curso> recuperaTodosCursos(){\r\n Connection conexao = ConexaoComBD.conexao();\r\n //instrução sql\r\n String sql = \"SELECT * FROM curso;\";\r\n try {\r\n //statement de conexão\r\n PreparedStatement ps = conexao.prepareStatement(sql);\r\n //recebe a tabela de retorno do banco de dados em um formato java\r\n ResultSet rs = ps.executeQuery();\r\n //criar lista de retorno\r\n List<Curso> lista = new ArrayList<>();\r\n \r\n //tratar o retorno do banco\r\n \r\n while(rs.next()){\r\n //criar um objeto modelo do tipo do retorno \r\n Curso c = new Curso();\r\n c.setIdCurso(rs.getInt(1));\r\n c.setNome(rs.getString(2));\r\n c.setArea(rs.getString(3));\r\n c.setCargaHoraria(rs.getInt(5));\r\n c.setValorCurso(rs.getDouble(6));\r\n c.setValorMensal(rs.getDouble(7));\r\n c.setCod(rs.getString(8));\r\n lista.add(c);\r\n }\r\n //retornar lista preenchida \r\n return lista;\r\n } catch (SQLException ex) {\r\n Logger.getLogger(CursoDAO.class.getName()).log(Level.SEVERE, null, ex);\r\n }\r\n //retorna null em caso de excessao\r\n return null;\r\n }", "List<Entidade> listarTodos();", "@Override\r\n public List<Prova> consultarTodosProva() throws Exception {\n return rnProva.consultarTodos();\r\n }", "public ArrayList<clsPago> consultaDataPagosCuotaInicial(int codigoCli)\n { \n ArrayList<clsPago> data = new ArrayList<clsPago>(); \n try{\n bd.conectarBaseDeDatos();\n sql = \" SELECT a.id_pagos_recibo idPago, a.id_usuario, b.name name_usuario, \"\n + \" a.referencia referencia, \"\n + \" a.fecha_pago fecha_pago, a.estado, \"\n + \" a.valor valor_pago, a.id_caja_operacion, e.name_completo nombre_cliente, \"\n + \" a.fecha_pago fecha_registro\"\n + \" FROM ck_pagos_recibo AS a\"\n + \" JOIN ck_usuario AS b ON a.id_usuario = b.id_usuario\"\n + \" JOIN ck_cliente AS e ON a.codigo = e.codigo\"\n + \" WHERE a.estado = 'A'\"\n + \" AND a.cuota_inicial = 'S'\"\n + \" AND a.estado_asignado = 'N'\"\n + \" AND a.codigo = \" + codigoCli; \n \n System.out.println(sql);\n bd.resultado = bd.sentencia.executeQuery(sql);\n \n if(bd.resultado.next())\n { \n do \n { \n clsPago oListaTemporal = new clsPago();\n \n oListaTemporal.setReferencia(bd.resultado.getString(\"referencia\"));\n oListaTemporal.setFechaPago(bd.resultado.getString(\"fecha_pago\"));\n oListaTemporal.setNombreUsuario(bd.resultado.getString(\"name_usuario\"));\n oListaTemporal.setNombreCliente(bd.resultado.getString(\"nombre_cliente\"));\n oListaTemporal.setValor(bd.resultado.getDouble(\"valor_pago\"));\n oListaTemporal.setFechaRegistro(bd.resultado.getString(\"fecha_registro\"));\n oListaTemporal.setIdPago(bd.resultado.getInt(\"idPago\"));\n data.add(oListaTemporal);\n }\n while(bd.resultado.next()); \n //return data;\n }\n else\n { \n data = null;\n } \n }\n catch(Exception ex)\n {\n System.out.print(ex);\n data = null;\n } \n bd.desconectarBaseDeDatos();\n return data;\n }", "public ArrayList<Libro> recuperaTodos();", "public List<GrupoLocalResponse> buscarTodos();", "public void cargarDatos() {\n \n if(drogasIncautadoList==null){\n return;\n }\n \n \n \n List<Droga> datos = drogasIncautadoList;\n\n Object[][] matriz = new Object[datos.size()][4];\n \n for (int i = 0; i < datos.size(); i++) {\n \n \n //System.out.println(s[0]);\n \n matriz[i][0] = datos.get(i).getTipoDroga();\n matriz[i][1] = datos.get(i).getKgDroga();\n matriz[i][2] = datos.get(i).getQuetesDroga();\n matriz[i][3] = datos.get(i).getDescripcion();\n \n }\n Object[][] data = matriz;\n String[] cabecera = {\"Tipo Droga\",\"KG\", \"Quetes\", \"Descripción\"};\n dtm = new DefaultTableModel(data, cabecera);\n tableDatos.setModel(dtm);\n }", "public ArrayList<DataCliente> listarClientes();", "public List<Aluno> buscarTodos() {\n\t\treturn null;\n\t}", "@Parameters\n\tpublic static Collection<Object[]> data() {\n\t\tObject[][] data = new Object[][] { \n\t\t\t{null, null, null, null, null},\n\t\t\t{null, \"\", null, null, null},\n\t\t\t{null, troppoLunga, null, null, null},\n\t\t};\n\t\treturn Arrays.asList(data);\n\t}", "public List listar() {\n Query query = Database.manager.createNamedQuery(\"StatussistemaDTO.findAll\");\n query.setHint(QueryHints.MAINTAIN_CACHE, HintValues.FALSE);// evita consulta em cache\n List lista = query.getResultList();\n return lista;\n }", "public void mostrarDados() {\n txtId.setText(\"\" + lista.get(indice).getId());\n txtNome.setText(lista.get(indice).getNome());\n txtEmail.setText(lista.get(indice).getEmail());\n txtSenha.setText(lista.get(indice).getSenha());\n preencheTabela();\n }", "@Override\r\n public List<Funcionario> consultarTodosFuncionarios() throws Exception {\n return rnFuncionario.consultarTodos();\r\n }", "private void remplirUtiliseData() {\n\t}", "public ArrayList<DataRestaurante> listarRestaurantes();", "@Override\n\tpublic List<OaAutoInfo> getDataList(String param) throws Exception {\n\t\treturn null;\n\t}", "public List<Ejemplar> getAll();", "public ArrayList<DatosNombre> listaNombre(){\n \n ArrayList<DatosNombre> respuesta = new ArrayList<>();\n Connection conexion = null;\n JDBCUtilities conex = new JDBCUtilities();\n \n try{\n conexion= conex.getConnection();\n \n String query = \"SELECT usuario, contrasenia, nombre\"\n + \" FROM empleado\"\n + \" WHERE estado=true\";\n \n PreparedStatement statement = conexion.prepareStatement(query);\n ResultSet resultado = statement.executeQuery();\n \n while(resultado.next()){\n DatosNombre consulta = new DatosNombre();\n consulta.setUsuario(resultado.getString(1));\n consulta.setContrasenia(resultado.getString(2));\n consulta.setNombreAnt(resultado.getString(3));\n \n respuesta.add(consulta);\n }\n }catch(SQLException e){\n JOptionPane.showMessageDialog(null, \"Error en la consulta \" + e);\n }\n return respuesta;\n }", "@Override\r\n public List<QuestaoDiscursiva> consultarTodosQuestaoDiscursiva()\r\n throws Exception {\n return rnQuestaoDiscursiva.consultarTodos();\r\n }", "private void cargarDeDB() {\n Query query = session.createQuery(\"SELECT p FROM Paquete p WHERE p.reparto is NULL\");\n data = FXCollections.observableArrayList();\n\n List<Paquete> paquetes = query.list();\n for (Paquete paquete : paquetes) {\n data.add(paquete);\n }\n\n cargarTablaConPaquetes();\n }", "public ArrayList<AnuncioDTO> ObtenerAnuncios(){\n ArrayList<AnuncioDTO> ret=new ArrayList<AnuncioDTO>();\n\n try{\n Connection conect = getConection();\n Properties sqlProp = new Properties();\n InputStream is = new FileInputStream(sqlPropertiesPath);\n sqlProp.load(is);\n PreparedStatement ps = conect.prepareStatement(sqlProp.getProperty(\"getAll.Anuncio\"));\n ResultSet rs = ps.executeQuery();\n while(rs.next()){\n int id=rs.getInt(1);\n TipoAnuncio tipoAnuncio=TipoAnuncio.valueOf(rs.getString(2));\n String titulo = rs.getString(3);\n String cuerpo = rs.getString(4);\n Date fechaPublicacion = new Date(rs.getDate(5).getTime());\n Date fechaFin=null;\n if(tipoAnuncio.equals(TipoAnuncio.Flash)){\n fechaFin= new Date(rs.getDate(6).getTime());\n }\n String emailPropietario = rs.getString(7);\n EstadoAnuncio estadoAnuncio = EstadoAnuncio.valueOf(rs.getString(8));\n \n ArrayList<String>temas=null;\n if(tipoAnuncio.equals(TipoAnuncio.Tematico)){\n temas=new ArrayList<String>();\n ArrayList<String>temasId = null;\n temasId=new ArrayList<String>(Arrays.asList(rs.getString(9).split(\",\")));\n InteresesDAO interesesDAO = new InteresesDAO(sqlPropertiesPath);\n Hashtable<Integer,String> intereses = interesesDAO.DevolverIntereses();\n for(String interes : temasId){\n temas.add(intereses.get(Integer.parseInt(interes)));\n }\n\n }\n ArrayList<String>destinatarios = ObtenerDestinatariosAnuncio(id);\n AnuncioDTO anuncioDTO=new AnuncioDTO(id, tipoAnuncio, titulo, cuerpo, fechaPublicacion, fechaFin, emailPropietario, estadoAnuncio, temas,destinatarios);\n\n ret.add(anuncioDTO);\n }\n }catch(Exception e){\n e.printStackTrace();\n }\n return ret;\n }", "@SuppressWarnings(\"unchecked\")\n\tpublic List<Empresa> listarTodos() {\n\t\tList<Empresa> lista = new ArrayList<Empresa>();\n\t\t\n\t\ttry {\n\t\t\tlista = empresaDAO.listarTodosDesc();\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\t\n\t\treturn lista;\n\t}", "@Override\r\n\tpublic List<Categoria> readAll() {\n\t\tList<Categoria> lista = new ArrayList<>();\r\n\t\tString SQL = \"select *from categoria\";\r\n\t\ttry {\r\n\t\t\tcx = Conexion.getConexion();\r\n\t\t\tps = cx.prepareStatement(SQL);\r\n\t\t\trs = ps.executeQuery(SQL);\r\n\t\t\twhile(rs.next()) {\r\n\t\t\t\tCategoria r = new Categoria();\r\n\t\t\t\tr.setCategoria_idcategoria(rs.getInt(\"CATEGORIA_IDCATEGORIA\"));\r\n\t\t\t\tr.setNombre(rs.getString(\"NOMBRE\"));\r\n\t\t\t\tlista.add(r);\r\n\t\t\t}\r\n\t\t} catch (Exception e) {\r\n\t\t\t// TODO: handle exception\r\n\t\t\tSystem.out.println(\"Error: \"+e);\r\n\t\t}\r\n\t\t\r\n\t\treturn lista;\r\n\t}", "@SuppressWarnings({ \"unchecked\", \"static-access\" })\n\t@Override\n\t/**\n\t * Leo todos los empleados.\n\t */\n\tpublic List<Employees> readAll() {\n\t\tList<Employees> ls = null;\n\n\t\tls = ((SQLQuery) sm.obtenerSesionNueva().createQuery(\n\t\t\t\tInstruccionesSQL.CONSULTAR_TODOS)).addEntity(Employees.class)\n\t\t\t\t.list();// no creo que funcione, revisar\n\n\t\treturn ls;\n\t}", "public static List<PolovniAutomobili> readAll() {\n List<PolovniAutomobili> listaUsera = new ArrayList<>();\n try {\n CONNECTION = DriverManager.getConnection(URL, USERNAME, PASSWORD);\n String query = \"SELECT * FROM polovni WHERE 1\";\n try (Statement st = (Statement) CONNECTION.createStatement()) {\n ResultSet rs = st.executeQuery(query);\n while (rs.next()) {\n String imgUrl = rs.getString(\"imgUrl\");\n String naziv = rs.getString(\"naziv\");\n int godiste = rs.getInt(\"godiste\");\n int cena = rs.getInt(\"cena\");\n String url = rs.getString(\"url\");\n listaUsera.add(new PolovniAutomobili(imgUrl, naziv, godiste,cena,url));\n }\n }\n CONNECTION.close();\n } catch (SQLException ex) {\n System.out.println(\"MySql Connection error...\");\n ex.printStackTrace();\n }\n return listaUsera;\n }", "public List<Usuario> buscarTodos(){\n\t\tList<Usuario> listarUsuarios = new ArrayList<>();\n\t\t\n\t\tString sql = \"Select * from usuario\";\n\t\tUsuario usuario = null ;\n\t\t\n\t\ttry(PreparedStatement preparedStatement = con.prepareStatement(sql)) {\n\t\t\t\n\t\t\tResultSet result = preparedStatement.executeQuery();\n\t\t\t\n\t\t\t/*\n\t\t\t * Dentro do while estou verificando se tem registro no banco de dados, enquanto tiver registro vai \n\t\t\t * adcionando um a um na lista e no final fora do while retorna todos os registro encontrados. \n\t\t\t */\n\t\t\twhile(result.next()){\n\t\t\t\tusuario = new Usuario();\n\t\t\t\tusuario.setIdUsuario(result.getInt(\"idUsuario\"));\n\t\t\t\tusuario.setNome(result.getString(\"Nome\"));\n\t\t\t\tusuario.setLogin(result.getString(\"Login\"));\n\t\t\t\tusuario.setSenha(result.getString(\"senha\"));\n\t\t\t\t\n\t\t\t\t// Adcionando cada registro encontro, na lista .\n\t\t\t\tlistarUsuarios.add(usuario);\n\t\t\t}\n\t\t\t\n\t\t} catch (SQLException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn listarUsuarios;\n\t}", "@Override\n\tpublic List<Aluno> carregar() {\n\t\tList<Aluno> lista = new ArrayList<Aluno>();\n\t\ttry {\n\t\t\tConnection con = DBUtil.getInstance().getConnection();\n\t\t\tString cmd = \"SELECT * FROM Aluno \";\n\t\t\tPreparedStatement stmt = con.prepareStatement( cmd );\n\t\t\n\t\t\tResultSet rs = stmt.executeQuery();\n\t\t\twhile (rs.next()) { \n\t\t\t\tAluno a = new Aluno();\n\t\t\t\ta.setNome( rs.getString(\"Nome\") );\n\t\t\t\ta.setNumero(Integer.parseInt(rs.getString(\"idAluno\")) );\n\t\t\t\tlista.add( a );\n\t\t\t}\t\n\t\t} catch (SQLException e) {\n\t\t\tJOptionPane.showMessageDialog(null, \"Erro no Sql, verifique o banco\", \"ERRO\", JOptionPane.ERROR_MESSAGE);\n\n\t\t}\n\t\treturn lista;\n\t}", "public DefaultTableModel cargarDatos () {\r\n DefaultTableModel modelo = new DefaultTableModel(\r\n new String[]{\"ID SALIDA\", \"IDENTIFICACIÓN CAPITÁN\", \"NÚMERO MATRICULA\", \"FECHA\", \"HORA\", \"DESTINO\"}, 0); //Creo un objeto del modelo de la tabla con los titulos cargados\r\n String[] info = new String[6];\r\n String query = \"SELECT * FROM actividad WHERE eliminar = false\";\r\n try {\r\n Statement st = con.createStatement();\r\n ResultSet rs = st.executeQuery(query);\r\n while (rs.next()) { \r\n info[0] = rs.getString(\"id_salida\");\r\n info[1] = rs.getString(\"identificacion_navegate\");\r\n info[2] = rs.getString(\"numero_matricula\");\r\n info[3] = rs.getString(\"fecha\");\r\n info[4] = rs.getString(\"hora\");\r\n info[5] = rs.getString(\"destino\");\r\n Object[] fila = new Object[]{info[0], info[1], info[2], info[3], info[4], info[5]};\r\n modelo.addRow(fila);\r\n }\r\n st.close();\r\n rs.close();\r\n } catch (SQLException ex) {\r\n Logger.getLogger(PActividad.class.getName()).log(Level.SEVERE, null, ex);\r\n }\r\n return modelo;\r\n }", "public void ConsultaVehiculosSQlite() {\n preguntas = mydb.getCartList();\n for( int i = 0 ; i < preguntas.size() ; i++ ){\n //Toast.makeText(getApplicationContext(), preguntas.get( i ).getPregunta(), Toast.LENGTH_SHORT).show();\n persons.add(new Solicitud(\"Pregunta \" + String.valueOf(i+1) +\": \"+preguntas.get( i ).getPregunta(),\"Fecha: \"+ preguntas.get( i ).getFecha(), R.drawable.solicitudes,\"Motivo: \"+preguntas.get( i ).getMotivo(),\"Observacion: \"+preguntas.get( i ).getObservacion(),\"\"));\n }\n }", "public List<LocoDataFois> getdata(LocoDataFois unlocos) {\n\t\t\t// TODO Auto-generated method stub\n\t\t\tSystem.out.println(\"getuncleasedlocos\");\n\t\t\tint locono= unlocos.getLoco_No();\n\t\t\tList<LocoDataFois> locos= new ArrayList<>();\n\t\t\tobj_uncleansedrepo.getallLocodata(locono)\n\t\t\t.forEach(locos::add);\t\t\n\t\t\tif(locos.isEmpty()) {\n\t\t\t\treturn locos ;\n\t\t\t}\n\t\t\telse\n\t\t\t\tSystem.out.println(\"data\" +locos);\n\t\t\t\treturn locos;\n\t\t\t\n\t\t\n\t\t}", "@Override\n public Retorno_MsgObj obtenerLista() {\n PerManejador perManager = new PerManejador();\n\n return perManager.obtenerLista(\"Curso.findAll\", null);\n }", "public ArrayList<DTOValoracion> listaValoraciones() {\n ArrayList<DTOValoracion> lista = new ArrayList<>();\n try {\n Connection conn = DriverManager.getConnection(CONN, USER, PASS);\n\n Statement st = conn.createStatement();\n ResultSet rs = st.executeQuery(\"select valoracion, COUNT (valoracion) cantidad\\n\"\n + \"from Comentarios\\n\"\n + \"where valoracion is not null\\n\"\n + \"group by valoracion \");\n\n while (rs.next()) {\n\n int valoracion = rs.getInt(1);\n int cantidad = rs.getInt(2);\n\n DTOValoracion v = new DTOValoracion(valoracion, cantidad);\n\n lista.add(v);\n }\n\n st.close();\n conn.close();\n } catch (SQLException ex) {\n ex.printStackTrace();\n }\n\n return lista;\n }", "public List<Usuario> listarTodos() {\n List<Usuario> r = new ArrayList<>();\n try {\n try (Connection cnx = bd.obtenerConexion(Credenciales.BASE_DATOS, Credenciales.USUARIO, Credenciales.CLAVE);\n Statement stm = cnx.createStatement();\n ResultSet rs = stm.executeQuery(CMD_LISTAR2)) {\n while (rs.next()) {\n r.add(new Usuario(\n rs.getString(\"cedula\"),\n rs.getString(\"apellido1\"),\n rs.getString(\"apellido2\"),\n rs.getString(\"nombre\")\n ));\n }\n }\n } catch (SQLException ex) {\n System.err.printf(\"Excepción: '%s'%n\",\n ex.getMessage());\n }\n return r;\n }", "private void loadData(){\n\t\t \n\t\t model.getDataVector().clear();\n\t\t ArrayList<Person> personList = DataBase.getInstance().getPersonList();\n\t\t for(Person person : personList){\n\t\t\t addRow(person.toBasicInfoStringArray());\n\t\t }\n\t\t \n\t }", "@Override\n\t@Transactional\n\tpublic List<DetalleCarrito> readAll() throws Exception {\n\t\treturn detalleCarritoRepository.findAll();\n\t}", "void all_Data_retrieve() {\n\t\tStatement stm=null;\n\t\tResultSet rs=null;\n\t\ttry{\n\t\t\t//Retrieve tuples by executing SQL command\n\t\t stm=con.createStatement();\n\t String sql=\"select * from \"+tableName+\" order by id desc\";\n\t\t rs=stm.executeQuery(sql);\n\t\t DataGUI.model.setRowCount(0);\n\t\t //Add rows to table model\n\t\t while (rs.next()) {\n Vector<Object> newRow = new Vector<Object>();\n //Add cells to each row\n for (int i = 1; i <=colNum; i++) \n newRow.addElement(rs.getObject(i));\n DataGUI.model.addRow(newRow);\n }//end of while\n\t\t //Catch SQL exception\n }catch (SQLException e ) {\n \te.printStackTrace();\n\t } finally {\n\t \ttry{\n\t if (stm != null) stm.close(); \n\t }\n\t \tcatch (SQLException e ) {\n\t \t\te.printStackTrace();\n\t\t }\n\t }\n\t}", "@Override\r\n public List<Concursando> consultarTodosConcursando() throws Exception {\n return rnConcursando.consultarTodos();\r\n }", "public static String buscarTodosLosLibros() throws Exception{ //BUSCARtODOS no lleva argumentos\r\n //primero: nos conectamos a oracle con la clase conxion\r\n \r\n Connection con=Conexion.conectarse(\"system\",\"system\");\r\n //segundo: generamos un statemenr de sql con la conexion anterior\r\n Statement st=con.createStatement();\r\n //3: llevamos a cabo la consulta select \r\n ResultSet res=st.executeQuery(\"select * from persona\"); //reset arreglo enmutado de java estructura de datos\r\n System.out.println(\"depues del select\");\r\n int indice=0;\r\n ArrayList<persona> personas=new ArrayList<persona>();\r\n while(res.next()){ //del primero hasta el ultimo prod que vea SI PONGO SECUENCIA NO ENTRA AL WHILE\r\n Integer id= res.getInt(1); \r\n String nombre=res.getString(2);\r\n String empresa=res.getString(3);\r\n Integer edad=res.getInt(4);\r\n String telefono=res.getString(5);\r\n \r\n ///llenamos el arrayList en cada vuelta\r\n personas.add(new persona(id,nombre,empresa,edad,telefono));\r\n \r\n System.out.println(\"estoy en el array list despues del select\");\r\n }\r\n \r\n //el paso final, transformamos a objeto json con jackson\r\n ObjectMapper maper=new ObjectMapper(); //mapeo a objeto jackson\r\n \r\n st.close();\r\n con.close();\r\n System.out.println(\"convirtiendo el json\");\r\n return maper.writeValueAsString(personas);\r\n \r\n }", "private void initializeData() {\n ListaOfertas.removeAll(ListaOfertas);\n for(Articulo listaJuegos: ArticuloRepository.getListArticulo()){\n if(listaJuegos.getOferta().contains(\"S\")){\n listaJuegos.setValorDescuento(String.valueOf(listaJuegos.getPrecioArticulo()-(listaJuegos.getPrecioArticulo()*listaJuegos.getPorcentajeDescuento()/100)));\n ListaOfertas.add(listaJuegos);\n }\n\n }\n }", "@Override\n\t@Transactional\n\tpublic List<String> leerColumnasTxtDelServidor(String ubicacion) {\n\t\tList<String> lines = Collections.emptyList();\n\t\tList<String> listadoColumnas = new ArrayList<String>(); // Agregar nombres de la columna\n\t\tSpssDataFileReader reader = null;\n\t\ttry {\n\n\t\t\tlines = Files.readAllLines(Paths.get(ubicacion), StandardCharsets.UTF_8);\n\t\t\tSystem.out.println(lines.get(0));\n\t\t\tString campos = lines.get(0);\t\t\t\n\t\t\tlistadoColumnas=Arrays.asList(campos.split(\",\"));\n\t\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace(System.out);\n\t\t}\n\t\treturn listadoColumnas;\n\t}", "public List<Usuario> listar() {\n List<Usuario> listaUsuarios = new ArrayList<>();\n String consulta = \"select tipoDocumento, documento, nombre, apellido, password, correo, tipoUsuario from Usuario\";\n Cursor temp = conex.ejecutarSearch(consulta);\n if (temp.moveToFirst()) {\n do {\n Usuario usuario = new Usuario(temp.getString(0), Integer.parseInt(temp.getString(1)), temp.getString(2), temp.getString(3), temp.getString(4), temp.getString(5), temp.getString(6));\n listaUsuarios.add(usuario);\n } while (temp.moveToNext());\n }\n return listaUsuarios;\n }", "private void cargarDatos()\n {\n // Pantalla carga\n showProgress(true, mView, mProgressView, getContext());\n Comando login = new LoginComando(KPantallas.PANTALLA_PERFIL);\n String email = UtilUI.getEmail(getContext());\n String password = UtilUI.getPassword(getContext());\n login.ejecutar(email,password);\n }", "@Override\n public ArrayList<Asesor> getListaAsesores() {\n ArrayList<Asesor> listaAsesores = new ArrayList();\n ConexionSQL conexionSql = new ConexionSQL();\n Connection conexion = conexionSql.getConexion();\n try{\n PreparedStatement orden = conexion.prepareStatement(\"select * from asesor\");\n ResultSet resultadoConsulta = orden.executeQuery();\n String numeroPersonal;\n String nombre;\n String idioma;\n String telefono;\n String correo;\n Asesor asesor;\n while(resultadoConsulta.next()){\n numeroPersonal = resultadoConsulta.getString(1);\n nombre = resultadoConsulta.getString(4) +\" \"+ resultadoConsulta.getString(6) +\" \"+ resultadoConsulta.getString(5);\n idioma = resultadoConsulta.getString(2);\n telefono = resultadoConsulta.getString(8);\n correo = resultadoConsulta.getString(7);\n asesor = new Asesor(numeroPersonal, nombre, idioma,telefono,correo);\n listaAsesores.add(asesor);\n }\n }catch(SQLException | NullPointerException excepcion){\n Logger logger = Logger.getLogger(\"Logger\");\n logger.log(Level.WARNING, \"La conexión podría ser nula | la sentencia SQL esta mal\");\n }\n return listaAsesores;\n }", "public Collection<FlujoDetalleDTO> cargarTodos(int codigoFlujo) {\n/* 138 */ Collection<FlujoDetalleDTO> resultados = new ArrayList<FlujoDetalleDTO>();\n/* */ try {\n/* 140 */ String s = \"select t.codigo_flujo,t.secuencia,t.servicio_inicio,r1.descripcion as nombre_servicio_inicio,t.accion,t.codigo_estado,r3.descripcion as nombre_codigo_estado,t.servicio_destino,r4.descripcion as nombre_servicio_destino,t.nombre_procedimiento,t.correo_destino,t.enviar_solicitud,t.ind_mismo_proveedor,t.ind_mismo_cliente,t.estado,t.caracteristica,t.valor_caracteristica,t.caracteristica_correo,m5.descripcion as nombre_estado,c.DESCRIPCION nombre_caracteristica,cv.DESCRIPCION descripcion_valor,t.metodo_seleccion_proveedor,t.ind_correo_clientes,t.usuario_insercion,t.fecha_insercion,t.usuario_modificacion,t.fecha_modificacion from wkf_detalle t left join SERVICIOS r1 on (r1.CODIGO=t.servicio_inicio) left join ESTADOS r3 on (r3.codigo=t.codigo_estado) left join SERVICIOS r4 on (r4.CODIGO=t.servicio_destino) left join sis_multivalores m5 on (m5.tabla='ESTADO_REGISTRO' and m5.valor=t.estado) LEFT JOIN CARACTERISTICAS c ON (t.Caracteristica = c.CODIGO) LEFT JOIN CARACTERISTICAS_VALOR cv ON (t.CARACTERISTICA=cv.CARACTERISTICA AND t.VALOR_CARACTERISTICA = cv.VALOR) where t.codigo_flujo=\" + codigoFlujo + \" order by t.secuencia\";\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 178 */ boolean rtaDB = this.dat.parseSql(s);\n/* 179 */ if (!rtaDB) {\n/* 180 */ return resultados;\n/* */ }\n/* 182 */ this.rs = this.dat.getResultSet();\n/* 183 */ while (this.rs.next()) {\n/* 184 */ resultados.add(leerRegistro());\n/* */ }\n/* */ }\n/* 187 */ catch (Exception e) {\n/* 188 */ e.printStackTrace();\n/* 189 */ Utilidades.writeError(\"FlujoDetalleDAO:cargarTodos \", e);\n/* */ } \n/* 191 */ return resultados;\n/* */ }", "Object getDados(long id);", "@Override\n\tpublic List<Usuario> obtenerTodas() {\n\t\treturn lista;\n\t}", "public List<Permiso> obtenerTodosActivos();", "public void listar_saldoData(String data_entrega,String tipo_pedido){\n \n \n OrdemCorteDAO dao = new OrdemCorteDAO();\n DefaultTableModel model = (DefaultTableModel) jTable_Saldo.getModel(); \n \n model.setNumRows(0);\n \n for (OrdemCorteDTO mp : dao.getSaldoVendaCorte(data_entrega, tipo_pedido)) {\n \n model.addRow(new Object[]{mp.getCodigo(), mp.getTotal()});\n }\n \n \n }", "@Override\r\n\tpublic List<Object> consultarVehiculos() {\r\n\t\t\r\n\t\tFormat formato = new SimpleDateFormat(\"yyyy-MM-dd HH:mm:ss\");\r\n\t\t\r\n\t\treturn AdminEstacionamientoImpl.getParqueadero().stream().map(\r\n\t\t\t\t temp -> {HashMap<String, String> lista = new HashMap<String, String>(); \r\n\t\t\t\t lista.put( \"placa\", temp.getVehiculo().getPlaca() );\r\n\t\t\t\t lista.put( \"tipo\", temp.getVehiculo().getTipo() );\r\n\t\t\t\t lista.put( \"fechaInicio\", formato.format( temp.getFechaInicio() ) );\r\n\r\n\t\t\t\t return lista;\r\n\t\t\t\t }\r\n\t\t\t\t).collect(Collectors.toList());\r\n\t}", "public static List<CentroDeCusto> readAll() {\n Query query = HibernateUtil.getSession().createQuery(\"FROM CentroDeCusto\");\n return query.list();\n }", "public void buscaTodasOSs() {\n try {\n ServicoDAO sDAO = new ServicoDAO(); // instancia a classe ProdutoDB()\n ArrayList<OS> cl = sDAO.consultaTodasOs(); // coloca o método dentro da variável\n\n DefaultTableModel modeloTabela = (DefaultTableModel) jTable1.getModel();\n // coloca a tabela em uma variável do tipo DefaultTableModel, que permite a modelagem dos dados da tabela\n\n for (int i = modeloTabela.getRowCount() - 1; i >= 0; i--) {\n modeloTabela.removeRow(i);\n // loop que limpa a tabela antes de ser atualizada\n }\n\n for (int i = 0; i < cl.size(); i++) {\n // loop que pega os dados e insere na tabela\n Object[] dados = new Object[7]; // instancia os objetos. Cada objeto representa um atributo \n dados[0] = cl.get(i).getNumero_OS();\n dados[3] = cl.get(i).getStatus_OS();\n dados[4] = cl.get(i).getDefeito_OS();\n dados[5] = cl.get(i).getDataAbertura_OS();\n dados[6] = cl.get(i).getDataFechamento_OS();\n\n // pega os dados salvos do banco de dados (que estão nas variáveis) e os coloca nos objetos definidos\n modeloTabela.addRow(dados); // insere uma linha nova a cada item novo encontrado na tabela do BD\n }\n } catch (SQLException ex) {\n JOptionPane.showMessageDialog(null, \"Falha na operação.\\nErro: \" + ex.getMessage());\n } catch (Exception ex) {\n Logger.getLogger(FrmPesquisar.class.getName()).log(Level.SEVERE, null, ex);\n }\n }", "private void fillData() {\n String[] from = new String[] {\n NOMBRE_OBJETO,\n DESCRIPCION,\n TEXTURA\n };\n // Campos de la interfaz a los que mapeamos\n int[] to = new int[] {\n R.id.txtNombreObjeto,\n R.id.txtDescripcion,\n R.id.imgIconoObjeto\n };\n getLoaderManager().initLoader(OBJETOS_LOADER, null, this);\n ListView lvObjetos = (ListView) findViewById(R.id.listaObjetos);\n adapter = new SimpleCursorAdapter(this, R.layout.activity_tiendaobjetos_filaobjeto, null, from, to, 0);\n lvObjetos.setAdapter(adapter);\n }", "@Override\n public List listar() {\n return instalaciones.getAll();\n }", "public List<Clientes> read(){\n Connection con = ConectionFactory.getConnection();\n PreparedStatement pst = null;\n ResultSet rs = null;\n \n List<Clientes> cliente = new ArrayList<>();\n \n try {\n pst = con.prepareStatement(\"SELECT * from clientes ORDER BY fantasia\");\n rs = pst.executeQuery();\n \n while (rs.next()) { \n Clientes clientes = new Clientes();\n clientes.setCodigo(rs.getInt(\"codigo\"));\n clientes.setFantasia(rs.getString(\"fantasia\"));\n clientes.setCep(rs.getString(\"cep\"));\n clientes.setUf(rs.getString(\"uf\"));\n clientes.setLogradouro(rs.getString(\"logradouro\"));\n clientes.setNr(rs.getString(\"nr\"));\n clientes.setCidade(rs.getString(\"cidade\"));\n clientes.setBairro(rs.getString(\"bairro\"));\n clientes.setContato(rs.getString(\"contato\"));\n clientes.setEmail(rs.getString(\"email\"));\n clientes.setFixo(rs.getString(\"fixo\"));\n clientes.setCelular(rs.getString(\"celular\"));\n clientes.setObs(rs.getString(\"obs\"));\n cliente.add(clientes); \n }\n } catch (SQLException ex) {\n \n }finally{\n ConectionFactory.closeConnection(con, pst, rs);\n }\n return cliente;\n}", "@Override\n public List<Pessoa> todas() {\n this.conexao = Conexao.abrirConexao();\n List<Pessoa> pessoas = new ArrayList<>();\n try {\n String consulta = \"SELECT * FROM pessoa;\";\n PreparedStatement statement = conexao.prepareStatement(consulta);\n ResultSet resut = statement.executeQuery();\n while (resut.next()) {\n pessoas.add(criarPessoa(resut));\n }\n } catch (SQLException ex) {\n Logger.getLogger(PessoasJDBC.class.getName()).log(Level.SEVERE, null, ex);\n } finally {\n Conexao.fecharConexao(conexao);\n }\n if (pessoas.size() > 0) {\n return Collections.unmodifiableList(pessoas);\n } else {\n return Collections.EMPTY_LIST;\n }\n\n }", "public void datosBundle()\n {\n //creamos un Bundle para recibir los datos de MascotasFavoritas al presionar el boton de atras en la ActionBar\n Bundle datosBundleAtras = getActivity().getIntent().getExtras();\n //preguntamos si este objeto viene con datos o esta vacio\n if(datosBundleAtras!=null)\n {//si hay datos estos se los agregamos a un ArrayList de mascotas\n mascotas = (ArrayList<Mascota>) datosBundleAtras.getSerializable(\"listamascotasatras\");\n }else{\n //si el bundle No trae datos entonces se inicializara la lista con datos\n validarBundle=1;\n //return;\n }\n }", "public List<Attribute> buscarTodas() {\r\n EntityManager em = PersistenceUtil.getEntityManager();\r\n Query query = em.createQuery(\"from Attribute As a\");\r\n return query.getResultList();\r\n }", "public void listar_saldoMontadoData(String data_entrega,String tipo_pedido){\n \n \n OrdemCorteDAO dao = new OrdemCorteDAO();\n DefaultTableModel model = (DefaultTableModel) jTable_Saldo_Montado.getModel(); \n \n model.setNumRows(0);\n \n for (OrdemCorteDTO mp : dao.getSaldoVendaMontadoPorData(data_entrega, tipo_pedido)) {\n \n model.addRow(new Object[]{mp.getCodigo(), mp.getTotal()});\n }\n \n \n }", "@Override\n\tpublic List<OaAutoInfo> getDataList() throws Exception {\n\t\treturn null;\n\t}", "@Override\n public List<Caja> buscarMovimientos(){\n List<Caja> listaCaja= cajaRepository.findAll();\n\n return listaCaja;\n\n }", "@SuppressWarnings(\"unchecked\")\r\n\tpublic List cargarDato(UnidadFuncional tipo) {\n\t\treturn null;\r\n\t}", "@Override\r\n public List<Anggota> getAll() {\r\n List<Anggota> datas = new ArrayList<>();\r\n String query = \"SELECT *From Anggota\";\r\n try {\r\n\r\n PreparedStatement preparedStatement = connection.prepareStatement(query);\r\n ResultSet rs = preparedStatement.executeQuery();\r\n\r\n while (rs.next()) {\r\n Anggota anggota = new Anggota();\r\n anggota.setKdAnggota(rs.getString(1));\r\n anggota.setNmAnggota(rs.getString(2));\r\n anggota.setTelepon(rs.getString(3));\r\n anggota.setAlamat(rs.getString(4));\r\n datas.add(anggota);\r\n }\r\n\r\n } catch (SQLException ex) {\r\n Logger.getLogger(AnggotaDAO.class.getName()).log(Level.SEVERE, null, ex);\r\n }\r\n\r\n return datas;\r\n\r\n }", "public listaAlumnos()\r\n\t{\r\n\t\tinicio = fin = null; \r\n\t}", "public Data() {\n initComponents();\n koneksi_db();\n tampil_data();\n }", "public List<Usuario> listarUsuario() {\n \n List<Usuario> lista = usuarioDAO.findAll();\n return lista;\n \n \n\n }", "@Override\n\tpublic List<CLIENTE> listarTodos() {\n\t\t\n\t\tString sql = \"SELECT * FROM CLIENTE\";\n\t\t\n\t\tList<CLIENTE> listaCliente = new ArrayList<CLIENTE>();\n\t\t\n\t\tConnection conexao;\n\t\t\n\t\ttry {\n\t\t\t\n\t\t\tconexao = JdbcUtil.getConexao();\n\t\t\t\n\t\t\tPreparedStatement ps = conexao.prepareStatement(sql);\n\t\t\t\n\t\t\tResultSet res = ps.executeQuery();\n\t\t\t\n\t\t\twhile(res.next()){\n\t\t\t\t\n\t\t\t\tcliente = new CLIENTE();\n\t\t\t\tcliente.setNomeCliente(res.getString(\"NOME_CLIENTE\"));\n\t\t\t\t\n\t\t\t\tlistaCliente.add(cliente);\n\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\tps.close();\n\t\t\tconexao.close();\n\t\t\t\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t\t\n\t\t}\n\t\t\n\t\treturn listaCliente;\n\t}" ]
[ "0.7333164", "0.70674896", "0.69931525", "0.6933376", "0.68214005", "0.67768997", "0.67518824", "0.6714798", "0.6692888", "0.66880447", "0.6676573", "0.66734004", "0.66421455", "0.663411", "0.6615938", "0.6582651", "0.6572583", "0.65621364", "0.6561266", "0.65403897", "0.65334016", "0.6521104", "0.65163803", "0.6514328", "0.65082365", "0.65063554", "0.650612", "0.65012354", "0.6496461", "0.64685833", "0.6456521", "0.6448476", "0.6442478", "0.6410911", "0.64042085", "0.63991725", "0.6395571", "0.6379919", "0.6378315", "0.6356362", "0.6352004", "0.6348613", "0.63444287", "0.63432914", "0.63325447", "0.6323583", "0.6322136", "0.6313823", "0.6311274", "0.63070333", "0.6302227", "0.63007075", "0.63003665", "0.6293412", "0.6281832", "0.627536", "0.627081", "0.6269046", "0.62687314", "0.6249843", "0.62437516", "0.6236254", "0.6223487", "0.6223145", "0.6221909", "0.622013", "0.62190974", "0.62187546", "0.62143344", "0.62055486", "0.6204246", "0.6202345", "0.6199675", "0.6198575", "0.61974025", "0.61955076", "0.6194023", "0.61887646", "0.61820525", "0.61808294", "0.61786765", "0.6177942", "0.61766684", "0.6175866", "0.6174686", "0.61723095", "0.61705863", "0.6166595", "0.6163118", "0.6161931", "0.6160381", "0.6160357", "0.61586225", "0.61508954", "0.61506706", "0.6150443", "0.6148814", "0.6141921", "0.6137004", "0.6134596", "0.6131207" ]
0.0
-1
Obtener por su id
@GET @Path("{id: \\d+}") public EnterpriseUserDTO getEnterpriseUser(@PathParam("id") Long id){ EnterpriseUserEntity enterpriseUser = enterpriseUsersLogic.obtenerEnterpriseUser(id); if (enterpriseUser == null){ throw new RuntimeException("No existe"); } return new EnterpriseUserDTO(enterpriseUser); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getID();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getId();", "String getID();", "String getID();", "String getID();", "String getID();", "Object getId();", "Integer getId();", "Integer getId();", "Integer getId();", "int getId();", "int getId();", "int getId();", "int getId();", "int getId();", "int getId();", "int getId();", "int getId();", "int getId();", "int getId();", "int getId();", "int getId();", "int getId();", "int getId();", "int getId();", "int getId();", "int getId();", "int getId();", "int getId();", "int getId();", "int getId();", "int getId();", "int getId();", "int getId();", "int getId();", "int getId();", "int getId();", "int getId();", "int getId();", "int getId();" ]
[ "0.7972716", "0.7972716", "0.7972716", "0.7972716", "0.7972716", "0.7972716", "0.7972716", "0.7972716", "0.7972716", "0.7972716", "0.7972716", "0.7972716", "0.7972716", "0.7972716", "0.7972716", "0.7972716", "0.7972716", "0.7972716", "0.7972716", "0.78744555", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.7863147", "0.77371293", "0.77371293", "0.77371293", "0.77371293", "0.7697887", "0.75588584", "0.75588584", "0.75588584", "0.7555424", "0.7555424", "0.7555424", "0.7555424", "0.7555424", "0.7555424", "0.7555424", "0.7555424", "0.7555424", "0.7555424", "0.7555424", "0.7555424", "0.7555424", "0.7555424", "0.7555424", "0.7555424", "0.7555424", "0.7555424", "0.7555424", "0.7555424", "0.7555424", "0.7555424", "0.7555424", "0.7555424", "0.7555424", "0.7555424", "0.7555424", "0.7555424", "0.7555424", "0.7555424" ]
0.0
-1
Instantiates a new bank remittance list controller.
public BankRemittanceListController() { // Default empty constructor. }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public BankRegistrationController() {\n }", "public PortalController() {\n bank = new Bank();\n }", "@Override\n\tprotected AbstractManageController createController() {\n\t\tif (m_ctrl == null)\n\t\t\tm_ctrl = new BankKeepController();\n\t\treturn m_ctrl;\n\t}", "@RequestMapping(value = \"bankRemittanceList\", method = RequestMethod.POST)\n\tpublic String createBankRemittance(@Valid @ModelAttribute BankRemittanceForm bankRemittanceForm, RedirectAttributes ra) {\n\n\t\tbankRemittanceService.createBankRemittance(DateUtils.format(bankRemittanceForm.getDateCharge(), DateUtils.FORMAT_DATE),\n\t\t\t\tDateUtils.format(bankRemittanceForm.getMonthCharge(), DateUtils.FORMAT_MONTH_YEAR));\n\t\tMessageHelper.addSuccessAttribute(ra, \"bankRemittance.successCreate\", bankRemittanceForm.getDateCharge());\n\t\treturn REDIRECT_BANKREMITTANCE;\n\t}", "public TransplantWaitingListPaneController() {\n observableAccounts = FXCollections.observableArrayList();\n accountManagerTest = accountManager;\n generateAccounts();\n }", "public ListaSEController() {\n }", "public Controller() {\n\n lastSearches = new SearchHistory();\n\n }", "public TransactionsAndFinesController() {\n }", "public ControllerAdministrarTrabajadores() {\r\n }", "private static CompanyController initializeController() {\n\n controller = new CompanyController();\n return controller;\n }", "public Bank(BankDisplay bankDisplay) {\n this(\"bank\", \"localhost\", 1234, bankDisplay);\n }", "public BudgetSubAwardController() {\r\n setFunctionType(TypeConstants.DISPLAY_MODE);\r\n initComponents();\r\n registerComponents();\r\n }", "public CreditPayuiController() {\n\t\tuserbl = new UserController();\n\t}", "public MyBank() {\n initComponents();\n fillClients();\n }", "public BankModel() {\n accounts = new ArrayList<AccountModel>();\n\n // Master account inbedded into system for easy access to test features.\n accounts.add(new AccountModel(\"c\", \"123\", 500));\n }", "public Bank ()\n {\n super (\"Bank\", defaults, trans, sharedQueue);\n customer = new Source (0, defaults [0], \"Bank$Customer\", customer_es, sharedQueue);\n teller = new Facility (1, defaults [1], new LinkedList<Coroutine> (), teller_es, sharedQueue);\n exit = new Sink (2, defaults [2], null, sharedQueue);\n initModel (new DynamicNode [] { customer, teller, exit });\n \n }", "public Controller(RegistryCreator registers,Printer printer) {\n registryCreator = registers;\n this.printer = printer;\n cashRegister = new CashRegister(startingBalance);\n }", "public Bank() {\n\n\t\tcustomerList = new ArrayList<Customer>();\n\t\tCustomer C = new Customer(\"madison\", \"bynum\", \"madb\", \"123\");\n\t\tcustomerList.add(C);\n\t\temployeeList = new ArrayList<Employee>();\n\t\tEmployee E = new Employee(\"madi\", \"by\", \"madib\", \"1234\");\n\t\temployeeList.add(E);\n\t\tadminList = new ArrayList<Admin>();\n\t\tAdmin A = new Admin(\"amber\", \"stone\", \"amberstone195\", \"12345\");\n\t\tadminList.add(A);\n\t\tsbank.writeSerializeMyBank();\n\t\tsbank.loadSerializeMyBank();\n\t}", "public ControllerRol() {\n }", "public TaxiInformationController() {\n }", "public detalleInventarioController() {\n }", "private Bank() {\r\n\t\tsuper();\r\n\t\tlogService = new Logger(\"driverName\");\r\n\t\tlogger = new Logger(\"driverName\");\r\n\t\tthis.balance = balance;\r\n\t\tthis.clients = new Client[100];\r\n\t}", "public PiranhaController() {\n piranhas = new ArrayList<Piranha>();\n toRemove = new ArrayList<Piranha>();\n }", "public TipoInformazioniController() {\n\n\t}", "public Controller() {\n model = new Model();\n comboBox = new ChannelComboBox();\n initView();\n new ChannelWorker().execute();\n timer = new Timer();\n }", "private void initializeWashControllers() {\n trNewPetWash = WashesControllersFactory.createTrNewPetWash();\n trObtainAllPetWashes = WashesControllersFactory.createTrObtainAllPetWashes();\n trDeleteWash = WashesControllersFactory.createTrDeleteWash();\n trUpdateWash = WashesControllersFactory.createTrUpdateWash();\n }", "public RevenueList() {\n }", "public ClientAccountViewController() {\n }", "@Override\r\n\tprotected ICardController createController() {\n\t\treturn new ClientCtrl();\r\n\t}", "ABcontroller(){\n\t\tsuper(50);\n\t\ttimer = new Timer();\n\t}", "public ControllerReporteHistorialClinico() {\n }", "public reporteController() {\n }", "public LicenciaController() {\n }", "public Bank() {\n\t\tsuper();\n\t}", "public MdrCreater()\n {\n super();\n client = new RawCdrAccess();\n }", "public Bank() {\n\n }", "public NationalController() {\n try {\n national = new National();\n isDisplayBtnConfirm = false;\n lstNational = DataUtil.getData(NationalModel.class, \"getAllNational\");\n if (!lstNational.isEmpty()) {\n mselectedNational = new National(lstNational.get(0));\n national = new National(lstNational.get(0));\n isSelectedApp = true;\n } else {\n isSelectedApp = false;\n mselectedNational = new National();\n }\n } catch (Exception ex) {\n SystemLogger.getLogger().error(ex);\n ClientMessage.logErr(ex.getMessage());\n }\n }", "public Controller() {\n\t\tthis.nextID = 0;\n\t\tthis.data = new HashMap<Integer, T>();\n\t}", "public ControllerEnfermaria() {\n }", "public Controller() {\n\t\tplaylist = new ArrayList<>();\n\t\tshowingMore = false;\n\t\tstage = Main.getStage();\n\t}", "@Autowired\r\n public RentController(RentService rentService){\r\n this.rentService = rentService;\r\n }", "public PlantillaController() {\n }", "PersonalDetailsController(){\n hrDB=new HRDatabase();\n }", "public DashboardController() {\n }", "public RegisterCostumerController() {\n this.costumerService = new CostumerService();\n }", "public TaskOverviewController(){\n }", "public LoadBalancerWRR(List<ServerUnit> _ListOfServers)\n\t{\n\t\tsuper(_ListOfServers);\n\t\ttypeOfLoadBalancer = typeOfLoadBalancer.WeightedRoundRobin;\n\t\tinitChosenServerIndex();\n\n\t/*\tinitTableOfServer();\n\t\tinitTempTableOfServer();*/\n\n\t}", "public PersonasController() {\r\n }", "public DomeinController() {\r\n DAOFactory.initFactory();\r\n gebruikerRepository = new GebruikerRepository();\r\n presentatieRepository = new PresentatieRepository();\r\n inschrijvingRepository = new InschrijvingRepository();\r\n campusRepository = new CampusRepository();\r\n lokaalRepository = new LokaalRepository();\r\n gastRepository = new GastRepository();\r\n bpCoordinator = gebruikerRepository.getBpCoordinator();\r\n }", "public CustomerController() {\n\t\tsuper();\n\n\t}", "public Controller() {\n super();\n }", "public Controller() {\n super();\n }", "public Bank() {\n\t\tnamesTree = new BankAccountsBinarySearchTree(new AccountComparatorByName());\n\t\taccountNumbersTree = new BankAccountsBinarySearchTree(new AccountComparatorByNumber());\n\t}", "public GlAccountBank () {\n\t\tsuper();\n\t}", "public SearchedRecipeController() {\n }", "public FoodMoodStatsController(NavController navCntrl){\n System.out.println(\"FoodMoodStatsController Class Instantiated.\");\n this.navCntrl= navCntrl;\n }", "private void initializeMedicationControllers() {\n trNewPetMedication = MedicationControllersFactory.createTrNewPetMedication();\n trObtainAllPetMedications = MedicationControllersFactory.createTrObtainAllPetMedications();\n trDeleteMedication = MedicationControllersFactory.createTrDeleteMedication();\n trUpdateMedication = MedicationControllersFactory.createTrUpdateMedication();\n }", "public RouteController() throws SQLException {\n\t\tbgCtr = new BjergbyGraphController();\n\t\toCtr = new OrderController();\n\t\trDb = new RouteDB();\n\t}", "BankAccount(){\n\t\tSystem.out.println(\"NEW ACCOUNT CREATED\");\t\n\t}", "void newLoans(List<Loan> loans);", "public FilmController(){\r\n // Create a new ArrayList which will store ALL the films the cinema can show\r\n this.cinema_film_list = new ArrayList<Film>();\r\n this.film_database_controller = new FilmDatabaseController();\r\n }", "public MySteamBoilerController(SteamBoilerCharacteristics configuration) {\n this.configuration = configuration;\n this.pumpStateMessages = new Message[this.configuration.getNumberOfPumps() + 1];\n this.pumpControlStateMessages = new Message[this.configuration.getNumberOfPumps() + 1];\n\n pumpListInitialisation();\n }", "public SalaculturalController() {\n jpa = new SalaculturalJpaController(PersistenceUtil.getEntityManagerFactory());\n salacultural = new Salacultural();\n lista = jpa.findSalaculturalEntities();\n jpa2 = new EdificioJpaController(PersistenceUtil.getEntityManagerFactory());\n edificios = jpa2.findEdificioEntities();\n edificio = new Edificio();\n tmpid = 0;\n }", "public Car createListings(int year, String brand, String model, int mileage, int bidPrice) {\r\n\r\n car = new Car(year, brand, model, mileage, bidPrice);\r\n\r\n cars.addCar(car);\r\n\r\n return car;\r\n\r\n }", "public DBController() {\n System.out.println(\"[\" + this.getClass() + \" : consctructor]\");\n this.listeObservers = new ArrayList<>();\n this.url = \"/Users/nico/Desktop/testSquirell.db\";\n //this.listeMorceau=new ArrayList<Morceau>();\n //this.initDB();\n addTableMorceau();\n System.out.println(\"[end constructor \" + this.getClass() + \"]\");\n }", "public AccountListView() {\r\n initComponents();\r\n \r\n }", "public LobbyController(LobbyManager lobbyManager) throws RemoteException {\n super();\n this.lobbyManager = lobbyManager;\n this.lobbyNetworkManager = lobbyManager.getLobbyNetworkManager();\n networkGetItem = new ServerGetMessage();\n }", "public PiBellController() {\n java.util.Timer timer = new Timer();\n this.rest = new Rest(USER_ID, this, LOCAL);\n this.window = new PiBellWindow(this, LOCAL);\n this.window.setVisible(true);\n this.window.showContact(RECIPIENT);\n this.window.addWindowListener(new WindowAdapter() {\n public void windowClosing(WindowEvent windowEvent) {\n timer.cancel();\n timer.purge();\n }\n });\n TimerTask tt = new TimerTask() {\n @Override\n public void run() {\n try {\n PiBellController.this.rest.performStatusRequest(RECIPIENT);\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n };\n timer.schedule(tt, 0, 3000);\n }", "public ClientController() {\n }", "public BankPanel() {\r\n\t super();\r\n\t}", "@Override\n\tpublic LightTank create() {\n\t\treturn new LightTank(GameContext.getGameContext());\n\t}", "public GeneralListVueController() {\n\n\t}", "public Controller()\n\t{\n\n\t}", "public Bank(String name, int accs){\n bankAccounts = new Account[accs];\n bankName = name;\n maxAccounts = accs;\n currAccounts = 0; //empty\n }", "public MainController() {\n\t\tcontroller = new Controller(this);\n\t}", "private Application(){\r\n theAccounts = new ArrayList<Account>();\r\n\r\n accountInTotal = 100;\r\n startingBonds = 10000;\r\n }", "public MatchController()\n {\n // Here from Game_Constants interface constants such as number of players, black coins count\n // and red coins count are fetched.\n this.playerControllerList = new PriorityQueue<PlayerController>(new Comparator<PlayerController>(){\n @Override\n public int compare(PlayerController p1, PlayerController p2) \n {\n return (p1.getPoints() > p2.getPoints() ) ? -1: (p1.getPoints() < p2.getPoints()) ? 1:0 ;\n }\n });\n for(int i=0; i<GameConfiguration.NUMBER_OF_PLAYERS; i++)\n {\n this.playerControllerList.add(new PlayerController(i));\n }\n this.gameController = new GameController(GameConfiguration.BLACK_COINS_COUNT, GameConfiguration.RED_COINS_COUNT);\n this.turn = 0;\n }", "public BankImpl() {\n persons = new ConcurrentHashMap<String, RemotePerson>();\n try {\n registry = LocateRegistry.createRegistry(8080);\n } catch (RemoteException e) {\n e.printStackTrace();\n System.exit(2);\n }\n }", "public Controller()\r\n\t{\r\n\t\tview = new View();\r\n\t}", "public Patient_Generate_Bill_Receptionist() {\n initComponents();\n }", "public TCpyBankCreditExample() {\n oredCriteria = new ArrayList<Criteria>();\n }", "public banks() {\n initComponents();\n }", "private MissaJpaController() {\r\n }", "public Controller()\n {\n // Create initial queues and stations\n q0 = new Queue(); //registration q\n \n // p[arameters are id of station, 4 queues, completed q)\n s0 = new Station(0, q0, q1, q2, q3, qx);\n \n //Student soiurce ss is an actor\n \n actors = new ArrayList<>(); \n actors.add(s0); // add all Actor implementors\n //actors.add(myStudentSorce);\n }", "public EstadoProyectoController() {\n \n }", "private void initializeMealsControllers() {\n trNewPetMeal = MealsControllersFactory.createTrNewPetMeal();\n trObtainAllPetMeals = MealsControllersFactory.createTrObtainAllPetMeals();\n trDeleteMeal = MealsControllersFactory.createTrDeleteMeal();\n trUpdateMeal = MealsControllersFactory.createTrUpdateMeal();\n }", "public ProduktController() {\r\n }", "public InternmentList() {\n\t\tsuper(\"Internments\", List.IMPLICIT);\n\n\t\tstartData();\n\t\tstartComponents();\n\t}", "public TransactionController() {\n lnf = new ListenerNotifier();\n }", "public AdminController()\n { \n int totalNumAdmin = 99999;\n admin = new Administrator[totalNumAdmin];\n for(int index = 0; index < totalNumAdmin; index++)\n {\n admin[index] = new Administrator(\"????\",\"????\");\n }\n }", "public InvoiceMenuBoundary()\n {\n invoiceController = new InvoiceController();\n }", "public CreateDocumentController() {\n }", "public ModuloAgenteBR() {\n initComponents();\n }", "public RDR_RDR() { \r\n this(new DefaultModelClassFactory());\r\n }", "public UndoController() {\r\n \t}", "protected RBNBControl createRBNBControl(){\r\n\t\tlog.write(\"createRBNBControl() called from \" + this.getClass().getName());\r\n\t\treturn new RBNBControl();\r\n\t}", "public TournamentController()\n\t{\n\t\tinitMap();\n\t}", "public Bank() {\n accounts = new Account[2];\n numOfAccounts = 0;\n }", "@Override\n public void initialize(URL url, ResourceBundle rb) {\n \t\taddSelectedBidderButton.setVisible(false);\n \n \t\tbtc = new BiddersTableController();\n btc.biddersTable(biddersTableView);\n // Get all of the bidders\n getBidders(null);\n\n // Listen for the text to change on the search input\n searchInput.textProperty().addListener((obs, ov, nv) -> {\n if (nv == null || nv.trim().isEmpty()) {\n getBidders(null);\n }\n });\n\n // Set click listener for table\n biddersTableView.setRowFactory(tv -> {\n TableRow<Bidders> row = new TableRow<>();\n row.setOnMouseClicked(event -> {\n if (event.getClickCount() == 2 && !row.isEmpty()) {\n BidderMain bidderMain = new BidderMain();\n bidderMain.isNew = false;\n bidderMain.bidderId = String.valueOf(row.getItem().getId());\n try {\n bidderMain.start(new Stage());\n } catch (IOException ex) {\n System.err.println(ex.getMessage());\n }\n }\n });\n return row;\n });\n }", "public FilmOverviewController() {\n }" ]
[ "0.6204305", "0.60007745", "0.5898503", "0.576941", "0.57579833", "0.56629246", "0.566226", "0.5526544", "0.5503401", "0.5480617", "0.547292", "0.54707783", "0.54522014", "0.5423508", "0.5401258", "0.53963107", "0.53751904", "0.5366443", "0.5332575", "0.5331728", "0.5293595", "0.5288199", "0.5213602", "0.5209956", "0.5198019", "0.51797193", "0.51744944", "0.51737183", "0.51630354", "0.5162838", "0.51433235", "0.514228", "0.5137532", "0.5135338", "0.5105845", "0.51008654", "0.5088366", "0.50788265", "0.50768685", "0.5075873", "0.5059885", "0.50579107", "0.50558645", "0.5050075", "0.5044737", "0.5044051", "0.5033263", "0.5031629", "0.5015633", "0.50130045", "0.50098974", "0.50098974", "0.5009839", "0.50039756", "0.5000597", "0.49821678", "0.498006", "0.49776095", "0.49707153", "0.49605802", "0.49605137", "0.49556163", "0.49502784", "0.4948436", "0.49423242", "0.49329475", "0.49193007", "0.4918056", "0.49140432", "0.49129596", "0.49108705", "0.49076363", "0.4907482", "0.48990676", "0.48939604", "0.48935667", "0.48920205", "0.48915562", "0.48909634", "0.48849925", "0.48808774", "0.48773146", "0.48754638", "0.4863338", "0.4857956", "0.485642", "0.4849815", "0.48484805", "0.48470777", "0.48326942", "0.48286143", "0.48137283", "0.4809989", "0.48070997", "0.48030597", "0.479036", "0.47889104", "0.4788758", "0.47845975", "0.47812966" ]
0.8336269
0
Creates the bank remittance.
@RequestMapping(value = "bankRemittanceList", method = RequestMethod.POST) public String createBankRemittance(@Valid @ModelAttribute BankRemittanceForm bankRemittanceForm, RedirectAttributes ra) { bankRemittanceService.createBankRemittance(DateUtils.format(bankRemittanceForm.getDateCharge(), DateUtils.FORMAT_DATE), DateUtils.format(bankRemittanceForm.getMonthCharge(), DateUtils.FORMAT_MONTH_YEAR)); MessageHelper.addSuccessAttribute(ra, "bankRemittance.successCreate", bankRemittanceForm.getDateCharge()); return REDIRECT_BANKREMITTANCE; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Test\n\tpublic void createNewAccountWithOpeningBalanceDebitTest() {\n\t\tcreateAccountDebtsTest();\n\t\tcreateNewAccountWithOpeningBalanceHelper();\n\t}", "@Test\n\tpublic void createAccountDebtsTest() {\n\t\tsetChequingRadioDefaultOff();\n\t\trdbtnDebt.setSelected(true);\n\t\tdata.setRdbtnDebt(rdbtnDebt);\n\t\tAccount account = data.createNewAccount();\n\t\taccountTest = new Account(TEST_ACCOUNT_NAME, bankTest,\n\t\t\t\tAccount.Types.DEBITS.getAccountType());\n\t\tassertEquals(accountTest, account);\n\t}", "@Test\n\tpublic void createAccountRRSPInvestmentTest() {\n\t\tsetChequingRadioDefaultOff();\n\t\trdbtnRrspInvestments.setSelected(true);\n\t\tdata.setRdbtnRrspInvestments(rdbtnRrspInvestments);\n\t\tAccount account = data.createNewAccount();\n\t\taccountTest = new Account(TEST_ACCOUNT_NAME, bankTest,\n\t\t\t\tAccount.Types.RRSP_INVESTMENTS.getAccountType());\n\t\tassertEquals(accountTest, account);\n\t}", "Rental createRental();", "public int createBank(String owner,String bankName,int type) {\n\t\tif (type==1) {\n\t\t\tbankDb.add(new NormalAccount(owner,bankName,this.bankCount));\n\t\t\tthis.bankCount+=1;\n\t\t}\n\t\telse if(type==2) {\n\t\t\tbankDb.add(new OnlyInAccount(owner,bankName,this.bankCount));\n\t\t\tthis.bankCount+=1;\n\t\t}\n\t\telse if(type==3) {\n\t\t\tbankDb.add(new OnlyOutAccount(owner,bankName,this.bankCount,10000));\n\t\t\tthis.bankCount+=1;\n\t\t}\n\t\telse {\n\t\t\t/* Invalid type defined */\n\t\t\treturn -3;\n\t\t}\n\t\t/* normally created */\n\t\treturn this.bankCount-1;\n\t}", "public void createAccount(double balance) {\r\n\t\tAccount account = new Account(balance);\r\n\t\tsetPlayerAccount(account);\r\n\t}", "@Test\n\tpublic void createNewAccountWithOpeningBalanceRRSPTest() {\n\t\tcreateAccountRRSPInvestmentTest();\n\t\tcreateNewAccountWithOpeningBalanceHelper();\n\t}", "public void createAccount() {\n\t\tSystem.out.print(\"Enter Name: \");\n\t\tString name = nameCheck(sc.next());\n\t\tSystem.out.print(\"Enter Mobile No.: \");\n\t\tlong mobNo = mobCheck(sc.nextLong());\n\t\tlong accNo = mobNo - 1234;\n\t\tSystem.out.print(\"Enter Balance: \"); \n\t\tfloat balance = amountCheck(sc.nextFloat());\n\t\tuserBean BeanObjCreateAccountObj = new userBean(accNo, name, mobNo, balance);\n\t\tSystem.out.println(\"Account created with Account Number: \" +accNo);\n\t\tServiceObj.bankAccountCreate(BeanObjCreateAccountObj);\n\t\t\n\t\n\t}", "public void create_crystal() {\n\t\tcrystalQuantity[1] += (1+create_modifier);\n\t\tautomerge();\n\t\tcollection();\n\t}", "public com.vodafone.global.er.decoupling.binding.request.ResourceBalanceType createResourceBalanceType()\n throws javax.xml.bind.JAXBException\n {\n return new com.vodafone.global.er.decoupling.binding.request.impl.ResourceBalanceTypeImpl();\n }", "@Test(groups = \"Transactions Tests\", description = \"Create new transaction\")\n\tpublic void createNewTransaction() {\n\t\tMainScreen.clickAccountItem(\"Income\");\n\t\tSubAccountScreen.clickSubAccountItem(\"Salary\");\n\t\tTransactionsScreen.clickAddTransactionBtn();\n\t\tTransactionsScreen.typeTransactionDescription(\"Extra income\");\n\t\tTransactionsScreen.typeTransactionAmount(\"300\");\n\t\tTransactionsScreen.clickTransactionType();\n\t\tTransactionsScreen.typeTransactionNote(\"Extra income from this month\");\n\t\tTransactionsScreen.clickSaveBtn();\n\t\tTransactionsScreen.transactionItem(\"Extra income\").shouldBe(visible);\n\t\tTransactionsScreen.transactionAmout().shouldHave(text(\"$300\"));\n\t\ttest.log(Status.PASS, \"Sub-account created successfully and the value is correct\");\n\n\t\t//Testing if the transaction was created in the 'Double Entry' account, if the value is correct and logging the result to the report\n\t\treturnToHomeScreen();\n\t\tMainScreen.clickAccountItem(\"Assets\");\n\t\tSubAccountScreen.clickSubAccountItem(\"Current Assets\");\n\t\tSubAccountScreen.clickSubAccountItem(\"Cash in Wallet\");\n\t\tTransactionsScreen.transactionItem(\"Extra income\").shouldBe(visible);\n\t\tTransactionsScreen.transactionAmout().shouldHave(text(\"$300\"));\n\t\ttest.log(Status.PASS, \"'Double Entry' account also have the transaction and the value is correct\");\n\n\t}", "public BankRemittanceListController() {\n\t\t// Default empty constructor.\n\t}", "public TimeDepositAccount(double interestRate, double balance, int maturityPeriods, double interestPenaltyRate) // constructor\n {\n super(interestRate,balance);\n this.elapsedPeriods=0;\n this.maturityPeriods=maturityPeriods;\n this.interestPenaltyRate = interestPenaltyRate;\n \n \n }", "private void makeDeposit() {\n\t\t\r\n\t}", "public Raum() {}", "@Test\n\tpublic void createAccountCashTest() {\n\t\tsetChequingRadioDefaultOff();\n\t\trdbtnCash.setSelected(true);\n\t\tdata.setRdbtnCash(rdbtnCash);\n\t\tAccount account = data.createNewAccount();\n\t\taccountTest = new Account(TEST_ACCOUNT_NAME, bankTest,\n\t\t\t\tAccount.Types.CASH.getAccountType());\n\t\tassertEquals(accountTest, account);\n\n\t}", "Account create();", "public void createExpense(ExpenseBE expenseBE) {\n\n }", "public Reimbursement(){}", "public void createNewAccountWithOpeningBalanceHelper() {\n\t\tparseDateTextFieldHelper();\n\t\tBalance balance = data.createNewAccountWithOpeningBalance();\n\t\tLocalDate date = LocalDate.of(year, month, dayOfMonth);\n\t\tbalance.setDate(date);\n\t\tJTextField amount = data.getTextFieldBalance();\n\t\t// this before was not being set, i thought i set it in expectedResult but\n\t\t// that's a different object!\n\t\tbalance.setAmount(Float.parseFloat(amount.getText()));\n\t\t// I think you can actually just insert the values here instead if using get()\n\t\tBalance resultExpected = new Balance(bankTest, accountTest,\n\t\t\t\tdate.getYear(), date.getMonthValue(), date.getDayOfMonth(),\n\t\t\t\tFloat.parseFloat(amount.getText()), TEST_TXTR_EXTRA_NOTES);\n\t\tassertEquals(resultExpected, balance);\n\t}", "public int makeNewAccount(int balance){\n int generated_id = 0;\n\n try {\n accountLock.lock();\n executeNewAccount(generated_id = currentAccountId++, balance, rawDataSource.getConnection());\n accountLock.unlock();\n\n cache.add(new Account(generated_id, balance));\n\n operationLock.lock();\n logNewAccount(currentOperationId, generated_id, balance);\n currentOperationId++;\n operationLock.unlock();\n } catch (SQLException e) {\n e.printStackTrace();\n }\n\n return generated_id;\n }", "@Test\n public void testCreateRewardAccount0() {\n Dining dining = Dining.createDining(\"100.00\", \"1234123412341234\", \"0123456789\");\n\n Account account = AccountTestData.createTestAccount0();\n\n AccountContribution contribution = account.makeContribution(new MonetaryAmount(8));\n try {\n RewardConfirmation confirmation = repository.confirmReward(contribution, dining);\n Assert.assertNotNull(\"confirmation should not be null\", confirmation);\n Assert.assertNotNull(\"confirmation number should not be null\", confirmation.getConfirmationNumber());\n Assert.assertEquals(\"wrong contribution object\", contribution, confirmation.getAccountContribution());\n verifyRewardInserted(confirmation, dining);\n } catch (DataIntegrityViolationException dive) {\n logger.error(\"exception on creation of reward from contribution=\" + contribution + \":dining=\" + dining,\n dive);\n throw dive;\n }\n }", "public void createAccount(String accountType, double balance){\r\n // check what is the type of the account being created\r\n /* update the list each time an account is being created and then put it into the hashtable. Then increase the\r\n counter do this for each of the following accounts each time an account is created*/\r\n switch (accountType){\r\n case \"1\":\r\n credits[creditCounter]= new CreditCardAccount(balance);\r\n allAccounts.replace(\"CreditCard\",credits);\r\n creditCounter++;\r\n break;\r\n case \"2\":\r\n lineOfCredits[lineOfCreditCounter] = new LineOfCreditAccount(balance);\r\n allAccounts.replace(\"LineOfCredit\",lineOfCredits);\r\n lineOfCreditCounter++;\r\n break;\r\n case \"3\":\r\n chequing[chequingCounter] = new ChequingAccount(balance);\r\n allAccounts.replace(\"Chequing\",chequing);\r\n chequingCounter++;\r\n break;\r\n case \"4\":\r\n saving[savingCounter] = new SavingsAccount(balance);\r\n allAccounts.replace(\"Saving\",saving);\r\n savingCounter++;\r\n break;\r\n default:\r\n System.out.println(\"ERROR IN CREATE ACCOUNT\");\r\n break;\r\n }\r\n }", "@Test\n\tpublic void createNewAccountWithOpeningBalanceCashTest() {\n\t\tcreateAccountCashTest();\n\t\tcreateNewAccountWithOpeningBalanceHelper();\n\t}", "@Test\n\tpublic void createAccountOtherInvestmentTest() {\n\t\tsetChequingRadioDefaultOff();\n\t\trdbtnOtherInvestments.setSelected(true);\n\t\tdata.setRdbtnOtherInvestments(rdbtnOtherInvestments);\n\t\tAccount account = data.createNewAccount();\n\t\taccountTest = new Account(TEST_ACCOUNT_NAME, bankTest,\n\t\t\t\tAccount.Types.OTHER_INVESTMENTS.getAccountType());\n\t\tassertEquals(accountTest, account);\n\t}", "@Test\n\tpublic void createNewAccountWithOpeningBalanceOtherTest() {\n\t\tcreateAccountOtherInvestmentTest();\n\t\tcreateNewAccountWithOpeningBalanceHelper();\n\t}", "public BankAccount() {\n numberOfAccounts++;\n this.accountNumber = accountNumberGenerator(); \n }", "@Test\n public void create() throws RazorpayException{\n JSONObject request = new JSONObject(\"{\" +\n \"\\\"amount\\\":\\\"100\\\",\" +\n \"\\\"speed\\\":\\\"normal\\\",\" +\n \"\\\"notes\\\":{\\\"notes_key_1\\\":\\\"BeammeupScotty.\\\",\" +\n \"\\\"notes_key_2\\\":\\\"Engage\\\"},\" +\n \"\\\"receipt\\\":\\\"ReceiptNo.31\\\"}\");\n\n String mockedResponseJson = \"{\\n\" +\n \" \\\"id\\\": \"+REFUND_ID+\",\\n\" +\n \" \\\"entity\\\": \\\"refund\\\",\\n\" +\n \" \\\"amount\\\": 500100,\\n\" +\n \" \\\"receipt\\\": \\\"Receipt No. 31\\\",\\n\" +\n \" \\\"currency\\\": \\\"INR\\\",\\n\" +\n \" \\\"payment_id\\\": \\\"pay_FCXKPFtYfPXJPy\\\",\\n\" +\n \" \\\"notes\\\": [],\\n\" +\n \" \\\"acquirer_data\\\": {\\n\" +\n \" \\\"arn\\\": null\\n\" +\n \" },\\n\" +\n \" \\\"created_at\\\": 1597078866,\\n\" +\n \" \\\"batch_id\\\": null,\\n\" +\n \" \\\"status\\\": \\\"processed\\\",\\n\" +\n \" \\\"speed_processed\\\": \\\"normal\\\"\\n\" +\n \"}\";\n\n try {\n mockResponseFromExternalClient(mockedResponseJson);\n mockResponseHTTPCodeFromExternalClient(200);\n Refund fetch = refundClient.create(request);\n assertNotNull(fetch);\n assertEquals(REFUND_ID,fetch.get(\"id\"));\n assertEquals(\"refund\",fetch.get(\"entity\"));\n assertEquals(500100,(int)fetch.get(\"amount\"));\n assertEquals(\"INR\",fetch.get(\"currency\"));\n String createRequest = getHost(Constants.REFUNDS);\n verifySentRequest(true, request.toString(), createRequest);\n } catch (IOException e) {\n assertTrue(false);\n }\n }", "@Test\n\tpublic void createNewAccountWithOpeningBalanceSavingTest() {\n\t\tcreateAccountSavingTest();\n\t\tcreateNewAccountWithOpeningBalanceHelper();\n\t}", "private void giveBirthToRabbits() {\n\t\tfor (int i = (rabbitList.size() - 1); i >= 0; i--) {\n\t\t\tRabbitsGrassSimulationAgent rabbit = rabbitList.get(i);\n\t\t\tif (rabbit.isReproducing()) {\n\t\t\t\taddNewRabbit();\n\t\t\t}\n\t\t}\n\t}", "public BankRekening() {\n setSaldo(0);\n }", "@Override\n public TransactionModel createTransaction(String custId, LocalDateTime transactionTime, String accountNumber, TransactionType type, BigDecimal amount,String description)\n {\n return transactionDao.createTransaction(custId,accountNumber,transactionTime,type,amount,description);\n }", "private void makeWithdraw() {\n\t\t\r\n\t}", "BankAccount(){\n\t\tSystem.out.println(\"NEW ACCOUNT CREATED\");\t\n\t}", "@Override\n\tpublic int createTransaction(BankTransaction transaction) throws BusinessException {\n\t\tint tran = 0;\n\t\t\n\t\ttry {\n\t\t\tConnection connection = PostgresqlConnection.getConnection();\n\t\t\tString sql = \"insert into dutybank.transactions (account_id, transaction_type, amount, transaction_date) values(?,?,?,?)\";\n\t\t\t\n\t\t\tPreparedStatement preparedStatement = connection.prepareStatement(sql);\n\t\t\t\n\t\t\tpreparedStatement.setInt(1, transaction.getAccountid());\n\t\t\tpreparedStatement.setString(2, transaction.getTransactiontype());\n\t\t\tpreparedStatement.setDouble(3, transaction.getTransactionamount());\n\t\t\tpreparedStatement.setDate(4, new java.sql.Date(transaction.getTransactiondate().getTime()));\n\n\t\t\t\n\t\t\ttran = preparedStatement.executeUpdate();\n\t\t\t\n\t\t} catch (ClassNotFoundException | SQLException e) {\n\t\t\tthrow new BusinessException(\"Some internal error has occurred while inserting data\");\n\t\t}\n\t\t\n\n\t\treturn tran;\n\t}", "public CreditReversal create(CreditReversalCreateParams params, RequestOptions options)\n throws StripeException {\n String path = \"/v1/treasury/credit_reversals\";\n return getResponseGetter()\n .request(\n BaseAddress.API,\n ApiResource.RequestMethod.POST,\n path,\n ApiRequestParams.paramsToMap(params),\n CreditReversal.class,\n options,\n ApiMode.V1);\n }", "TRule createTRule();", "@Override\n\tpublic void createBank(String bankName) {\n\t\tBank newBank = new Bank(bankName, new HashSet<Account>());\n\t\tcache.addToCache(newBank);\n\t\t\n\t}", "private void createTransaction() {\n\n String inputtedAmount = etAmount.getText().toString().trim().replaceAll(\",\", \"\");\n\n if (inputtedAmount.equals(\"\") || Double.parseDouble(inputtedAmount) == 0) {\n etAmount.setError(getResources().getString(R.string.Input_Error_Amount_Empty));\n return;\n }\n\n if (mAccount == null) {\n ((ActivityMain) getActivity()).showError(getResources().getString(R.string.Input_Error_Account_Empty));\n return;\n }\n\n if(mCategory == null) {\n ((ActivityMain) getActivity()).showError(getResources().getString(R.string.Input_Error_Category_Income_Empty));\n return;\n }\n\n Double amount = Double.parseDouble(etAmount.getText().toString().replaceAll(\",\", \"\"));\n if(amount < 0) {\n ((ActivityMain) getActivity()).showError(getResources().getString(R.string.Input_Error_Amount_Invalid));\n return;\n }\n\n int CategoryId = mCategory != null ? mCategory.getId() : 0;\n String Description = tvDescription.getText().toString();\n int accountId = mAccount.getId();\n String strEvent = tvEvent.getText().toString();\n Event event = null;\n\n if (!strEvent.equals(\"\")) {\n event = mDbHelper.getEventByName(strEvent);\n if (event == null) {\n long eventId = mDbHelper.createEvent(new Event(0, strEvent, mCal, null));\n if (eventId != -1) {\n event = mDbHelper.getEvent(eventId);\n }\n }\n }\n\n boolean isDebtValid = true;\n // Less: DebtCollect, More: Borrow\n if(mCategory.getDebtType() == Category.EnumDebt.LESS) { // Income -> Debt Collecting\n List<Debt> debts = mDbHelper.getAllDebtByPeople(tvPeople.getText().toString());\n\n Double lend = 0.0, debtCollect = 0.0;\n for(Debt debt : debts) {\n if(mDbHelper.getCategory(debt.getCategoryId()).isExpense() && mDbHelper.getCategory(debt.getCategoryId()).getDebtType() == Category.EnumDebt.MORE) {\n lend += debt.getAmount();\n }\n\n if(!mDbHelper.getCategory(debt.getCategoryId()).isExpense() && mDbHelper.getCategory(debt.getCategoryId()).getDebtType() == Category.EnumDebt.LESS) {\n debtCollect += debt.getAmount();\n }\n }\n\n if(debtCollect + amount > lend) {\n isDebtValid = false;\n ((ActivityMain) getActivity()).showError(getResources().getString(R.string.message_debt_collect_invalid));\n }\n }\n\n if(isDebtValid) {\n Transaction transaction = new Transaction(0,\n TransactionEnum.Income.getValue(),\n amount,\n CategoryId,\n Description,\n 0,\n accountId,\n mCal,\n 0.0,\n \"\",\n event);\n\n long newTransactionId = mDbHelper.createTransaction(transaction);\n\n if (newTransactionId != -1) {\n\n if(mCategory.getDebtType() == Category.EnumDebt.LESS || mCategory.getDebtType() == Category.EnumDebt.MORE) {\n Debt newDebt = new Debt();\n newDebt.setCategoryId(mCategory.getId());\n newDebt.setTransactionId((int) newTransactionId);\n newDebt.setAmount(amount);\n newDebt.setPeople(tvPeople.getText().toString());\n\n long debtId = mDbHelper.createDebt(newDebt);\n if(debtId != -1) {\n ((ActivityMain) getActivity()).showToastSuccessful(getResources().getString(R.string.message_transaction_create_successful));\n cleanup();\n\n if(getFragmentManager().getBackStackEntryCount() > 0) {\n // Return to last fragment\n getFragmentManager().popBackStackImmediate();\n }\n } else {\n ((ActivityMain) getActivity()).showError(getResources().getString(R.string.message_transaction_create_fail));\n mDbHelper.deleteTransaction(newTransactionId);\n }\n } else {\n ((ActivityMain) getActivity()).showToastSuccessful(getResources().getString(R.string.message_transaction_create_successful));\n cleanup();\n\n if(getFragmentManager().getBackStackEntryCount() > 0) {\n // Return to last fragment\n getFragmentManager().popBackStackImmediate();\n }\n }\n\n } else {\n ((ActivityMain) getActivity()).showError(getResources().getString(R.string.message_transaction_create_fail));\n }\n }\n\n }", "@Test\n\tpublic void createAccountSavingTest() {\n\t\tsetChequingRadioDefaultOff();\n\t\trdbtnSaving.setSelected(true);\n\t\tdata.setRdbtnSaving(rdbtnSaving);\n\t\tAccount account = data.createNewAccount();\n\t\taccountTest = new Account(TEST_ACCOUNT_NAME, bankTest,\n\t\t\t\tAccount.Types.SAVING.getAccountType());\n\t\tassertEquals(accountTest, account);\n\t}", "private Account createAccount8() {\n Account account = new Account(\"123456008\", \"Jean Sans Enfant\",\n new SimpleDate(4, 23, 1976).asDate(), \"[email protected]\", true, false, new CreditCard(\"4320123412340008\"));\n\n return account;\n }", "public static void createPayment() throws IOException {\t\t\n\t\tDate date = new Date((long) random(100000000));\n\t\tString date2 = \"'19\" + date.getYear() + \"-\" + (random(12)+1) + \"-\" + (random(28)+1) + \"'\";\n\t\tint amount = random(10000);\n\t\t\n\t\twriter.write(\"INSERT INTO Payment (Id, Date, CCNum, amount) Values (\" + pid++ +\", \" \n\t\t\t\t+ date2 + \", '\" + CCnumbers.get(random(CCnumbers.size())) + \"', \" + amount + line);\n\t\twriter.flush();\n\t}", "public BankAccount() {\r\n\t\tbalance=0;\r\n\t\t\r\n\t}", "public void createER(final Context ctx, final Transaction trans, final String id, final int resultCode,\r\n final int ocgResultCode)\r\n {\r\n RecurringRechargeSupport.createRechargeER(ctx, trans, getSub(), id, resultCode, ocgResultCode,\r\n sub_.getSubscriptionType());\r\n }", "public IBankTransfert payment();", "public Bank ()\n {\n super (\"Bank\", defaults, trans, sharedQueue);\n customer = new Source (0, defaults [0], \"Bank$Customer\", customer_es, sharedQueue);\n teller = new Facility (1, defaults [1], new LinkedList<Coroutine> (), teller_es, sharedQueue);\n exit = new Sink (2, defaults [2], null, sharedQueue);\n initModel (new DynamicNode [] { customer, teller, exit });\n \n }", "public void createESEAccount(String farmerId, String farmerAcctNo, Date txnTime, int type);", "@Override\r\n\tpublic void createReimbursement(RebsObj reb) {\n\t\tPreparedStatement ps = null;\r\n\t\tPreparedStatement ps2 = null;\r\n\t\tResultSet rs = null; // creating a resultSet which will save any queries\r\n\t\t\r\n\t\t// looks in util/ConnectionUtil.java and saves the url, username and password to \"conn\"\r\n\t\ttry(Connection conn = ConnectionUtil.getConnection();){ \r\n\t\t\t\r\n\t\t\t//int rebs_id = reb.getRebsId(); // REBS_ID IS AUTO INCREMENTING\r\n\t\t\tint user_id = reb.getUserId();\r\n\t\t\t//int man_id = reb.getManagerId(); // not needed\r\n\t\t\tint rebs_type = reb.getRebsType();\r\n\t\t\tint rebs_status = reb.getRebsStatus();\r\n\t\t\tdouble rebs_amount = reb.getRebsAmount();\r\n\t\t\tString rebs_description = reb.getRebsDescription();\r\n\t\t\t// Blob rebs_attachments\r\n\t\t\tTimestamp time_submitted = new Timestamp(System.currentTimeMillis());\t\t\r\n\t\t\t// Timestamp time_resolved\r\n\t\t\t\r\n\t\t\tPart rebs_photo = reb.getRebsPhoto();\r\n\t\t\t\r\n\t\t\t\r\n\t\t\tDateFormat dateFormat = new SimpleDateFormat(\"dd-MMM-YY hh:mm:ss.SSSSSSSSS\");\r\n\t\t\tdateFormat.format(time_submitted);\r\n\t\t\treb.setTimeSubmitted(time_submitted);\r\n\t\t\tSystem.out.println(\"TIME STAMP IN DAO: \" + time_submitted);\r\n\t\t\t\r\n\t\t\tString sql2 = \"SELECT REBS_SEQ.nextval FROM DUAL\"; // trying to get the next table value (for id #)\r\n\t\t\tps2 = conn.prepareStatement(sql2); // uses connection to send string as a prepared statement\r\n\t\t\trs = ps2.executeQuery();\r\n\t\t\t\r\n\t\t\twhile (rs.next()) // goes through all query results (in this case, we should only have 1)\r\n\t\t\t{\r\n\t\t\t\t// get first column of rs, then set it ==\r\n\t\t\t\treb.setRebsId(rs.getInt(1)); \r\n\t\t\t\t\r\n\t\t\t}\r\n\t\t\tint rebs_id = reb.getRebsId(); // setting rebs_id to the the rebs_seq value\r\n\t\t\t\r\n\t\t\t// you can put this string 'sql' into multiple lines by adding +, and having everything within \"\"\r\n\t\t\t// this sql line will be ran on SQL\r\n\t\t\tString sql = \"INSERT INTO ERS_REIMBURSEMENTS(rebs_id, user_id_author, user_id_resolver, \"\r\n\t\t\t\t\t+ \"rebs_type, rebs_status, rebs_amount, rebs_description, rebs_receipt, \"\r\n\t\t\t\t\t+ \"rebs_submitted, rebs_resolved) \" \r\n\t\t\t\t\t+ \"VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?)\";\r\n\t\t\t\t\t//+ \"RETURNING rebs_id INTO ?\";\r\n\t\t\t\r\n\t\t\t// creating prepared statement\r\n\t\t\tps = conn.prepareStatement(sql); // uses connection to send string as a prepared statement\r\n\t\t\tps.setInt(1, rebs_id); // REBS_ID IS AUTO INCREMENTING\r\n\t\t\tps.setInt(2, user_id);\r\n\t\t\tps.setString(3, null);\r\n\t\t\tps.setInt(4, rebs_type);\r\n\t\t\tps.setInt(5, rebs_status);\r\n\t\t\tps.setDouble(6, rebs_amount);\r\n\t\t\tps.setString(7, rebs_description);\r\n\t\t\t//ps.setString(8, null); this is the attachment\r\n\t\t\t\r\n\t\t\ttry {\r\n\t\t\t\t// size must be converted to int otherwise it results in error\r\n\t\t\t\tps.setBinaryStream(8, rebs_photo.getInputStream(), (int) rebs_photo.getSize());\r\n\t\t\t} catch (IOException e) {\r\n\t\t\t\te.printStackTrace();\r\n\t\t\t}\r\n\t\t\tps.setTimestamp(9, time_submitted);\r\n\t\t\tps.setString(10, null);\r\n\t\t\t//ps.setInt(11, rebs_id);\r\n\t\t\t\r\n\t\t\tSystem.out.println(\"in DAO, rebs_id: \" + rebs_id);\r\n\t\t\t// rows affected\r\n\t\t\tint affected = ps.executeUpdate();\r\n\t\t\tSystem.out.println(\"Rows inserted: \" + affected);\r\n\t\t\t\r\n\t\t\t\r\n\t\t}catch(SQLException e){\r\n\t\t\te.printStackTrace();\r\n\t\t}finally{\r\n\t\t\tclose(ps);\r\n\t\t}\r\n\t\t\r\n\t\tSystem.out.println(\"Created new reimbursement request!\");\r\n\r\n\t}", "public BankAccount() {\t\n\t\tthis.accountNumber = UUID.randomUUID().toString().substring(0, 6);\n\t\tthis.balance = 0;\n\t\tthis.accountType = \"Bank account\";\n\t}", "public void makeTransaction(Transaction transaction)\n throws BalanceNotAvailableException, TransactionIdNotUniqueException, TransactionTypeInCorrectException {\n\n if (checkTransactionId(transaction.getTransactionId())) {\n throw new TransactionIdNotUniqueException(\"Transaction Id should be unique\");\n } else if (transaction.getTransactionType().equalsIgnoreCase(\"debit\")) {\n if (checkAvailableBalance(transaction.getAccountId(), transaction.getAmount())) {\n throw new BalanceNotAvailableException(\"Balance Not Available\");\n }\n updateAccountBalance(transaction.getAccountId(),\n getAccountBalance(transaction.getAccountId()) - transaction.getAmount());\n transactionRepository.save(transaction);\n } else if (transaction.getTransactionType().equalsIgnoreCase(\"credit\")) {\n updateAccountBalance(transaction.getAccountId(),\n getAccountBalance(transaction.getAccountId()) + transaction.getAmount());\n transactionRepository.save(transaction);\n } else {\n throw new TransactionTypeInCorrectException(\"Transaction type should be debit or credit\");\n }\n }", "private static void generateCashWithdraw(int branchID) {\n long accountNo = getRandAccountFromBranch(branchID);\n int amount = getRandomAmount();\n writeToFile(String.format(\"%d %d\\n\", accountNo, amount));\n }", "public void createAccount() {\n System.out.println(\"Would you like to create a savings or checking account?\");\n String AccountRequest = input.next().toLowerCase().trim();\n createAccount(AccountRequest);\n\n }", "public void createInventoryReward() {\n if (inventoryEntityToRetrieve == null) {\n try {\n inventoryEntityToRetrieve = RandomBenefitModel.getInventoryRewards(application, encounter, characterVM.getDistance());\n } catch (JSONException e) {\n e.printStackTrace();\n }\n }\n }", "public Bank() {\n\t\tsuper();\n\t}", "@Test\n public void testLoanRefundByCashCashBasedAccounting() {\n\n Calendar fourMonthsfromNowCalendar = Calendar.getInstance(Utils.getTimeZoneOfTenant());\n fourMonthsfromNowCalendar.add(Calendar.MONTH, -4);\n\n // FINERACT-885: If the loan starts on day 27-31th of month and not all months have that\n // many days, then loan payment will get reset to a day of month less than today's day\n // and 4th payment will be in the past. In such case, start the loan a few days later,\n // so that 4th payment is guaranteed to be in the future.\n if (fourMonthsfromNowCalendar.get(Calendar.DAY_OF_MONTH) > 27) {\n fourMonthsfromNowCalendar.add(Calendar.DAY_OF_MONTH, 4);\n }\n\n String fourMonthsfromNow = Utils.convertDateToURLFormat(fourMonthsfromNowCalendar);\n\n final Integer clientID = ClientHelper.createClient(REQUEST_SPEC, RESPONSE_SPEC);\n ClientHelper.verifyClientCreatedOnServer(REQUEST_SPEC, RESPONSE_SPEC, clientID);\n\n /***\n * Create loan product with Default STYLE strategy\n */\n\n final Account assetAccount = ACCOUNT_HELPER.createAssetAccount();\n final Account incomeAccount = ACCOUNT_HELPER.createIncomeAccount();\n final Account expenseAccount = ACCOUNT_HELPER.createExpenseAccount();\n final Account overpaymentAccount = ACCOUNT_HELPER.createLiabilityAccount();\n\n final Integer loanProductID = createLoanProduct(\"0\", \"0\", LoanProductTestBuilder.DEFAULT_STRATEGY, CASH_BASED, assetAccount,\n incomeAccount, expenseAccount, overpaymentAccount);\n Assertions.assertNotNull(loanProductID);\n\n /***\n * Apply for loan application and verify loan status\n */\n final String savingsId = null;\n final String principal = \"12,000.00\";\n\n // Add charges with payment mode regular\n List<HashMap> charges = new ArrayList<>();\n\n Integer flatInstallmentFee = ChargesHelper.createCharges(REQUEST_SPEC, RESPONSE_SPEC,\n ChargesHelper.getLoanInstallmentJSON(ChargesHelper.CHARGE_CALCULATION_TYPE_FLAT, \"50\", false));\n addCharges(charges, flatInstallmentFee, \"50\", null);\n\n List<HashMap> collaterals = new ArrayList<>();\n\n final Integer collateralId = CollateralManagementHelper.createCollateralProduct(REQUEST_SPEC, RESPONSE_SPEC);\n\n final Integer clientCollateralId = CollateralManagementHelper.createClientCollateral(REQUEST_SPEC, RESPONSE_SPEC,\n String.valueOf(clientID), collateralId);\n addCollaterals(collaterals, clientCollateralId, BigDecimal.valueOf(1));\n\n final Integer loanID = applyForLoanApplicationWithPaymentStrategyAndPastMonth(clientID, loanProductID, charges, savingsId,\n principal, LoanApplicationTestBuilder.DEFAULT_STRATEGY, -4, collaterals);\n Assertions.assertNotNull(loanID);\n HashMap loanStatusHashMap = LoanStatusChecker.getStatusOfLoan(REQUEST_SPEC, RESPONSE_SPEC, loanID);\n LoanStatusChecker.verifyLoanIsPending(loanStatusHashMap);\n\n LOG.info(\"-----------------------------------APPROVE LOAN-----------------------------------------\");\n loanStatusHashMap = LOAN_TRANSACTION_HELPER.approveLoan(fourMonthsfromNow, loanID);\n LoanStatusChecker.verifyLoanIsApproved(loanStatusHashMap);\n LoanStatusChecker.verifyLoanIsWaitingForDisbursal(loanStatusHashMap);\n\n LOG.info(\"-------------------------------DISBURSE LOAN-------------------------------------------\");\n String loanDetails = LOAN_TRANSACTION_HELPER.getLoanDetails(REQUEST_SPEC, RESPONSE_SPEC, loanID);\n loanStatusHashMap = LOAN_TRANSACTION_HELPER.disburseLoanWithNetDisbursalAmount(fourMonthsfromNow, loanID,\n JsonPath.from(loanDetails).get(\"netDisbursalAmount\").toString());\n LoanStatusChecker.verifyLoanIsActive(loanStatusHashMap);\n\n final JournalEntry[] assetAccountInitialEntry = {\n new JournalEntry(Float.parseFloat(\"12000.00\"), JournalEntry.TransactionType.CREDIT),\n new JournalEntry(Float.parseFloat(\"12000.00\"), JournalEntry.TransactionType.DEBIT) };\n JOURNAL_ENTRY_HELPER.checkJournalEntryForAssetAccount(assetAccount, fourMonthsfromNow, assetAccountInitialEntry);\n\n ArrayList<HashMap> loanSchedule = LOAN_TRANSACTION_HELPER.getLoanRepaymentSchedule(REQUEST_SPEC, RESPONSE_SPEC, loanID);\n HashMap firstInstallment = loanSchedule.get(1);\n validateNumberForEqual(\"2290\", String.valueOf(firstInstallment.get(\"totalOutstandingForPeriod\")));\n\n // Make payment for installment #1\n\n fourMonthsfromNowCalendar.add(Calendar.MONTH, 1);\n\n final String threeMonthsfromNow = Utils.convertDateToURLFormat(fourMonthsfromNowCalendar);\n\n LOAN_TRANSACTION_HELPER.makeRepayment(threeMonthsfromNow, Float.parseFloat(\"2290\"), loanID);\n loanSchedule.clear();\n loanSchedule = LOAN_TRANSACTION_HELPER.getLoanRepaymentSchedule(REQUEST_SPEC, RESPONSE_SPEC, loanID);\n firstInstallment = loanSchedule.get(1);\n validateNumberForEqual(\"0.00\", String.valueOf(firstInstallment.get(\"totalOutstandingForPeriod\")));\n\n // Make payment for installment #2\n fourMonthsfromNowCalendar.add(Calendar.MONTH, 1);\n\n final String twoMonthsfromNow = Utils.convertDateToURLFormat(fourMonthsfromNowCalendar);\n\n LOAN_TRANSACTION_HELPER.makeRepayment(twoMonthsfromNow, Float.parseFloat(\"2290\"), loanID);\n JOURNAL_ENTRY_HELPER.checkJournalEntryForAssetAccount(assetAccount, twoMonthsfromNow,\n new JournalEntry(Float.parseFloat(\"2290\"), JournalEntry.TransactionType.DEBIT),\n new JournalEntry(Float.parseFloat(\"2000\"), JournalEntry.TransactionType.CREDIT));\n JOURNAL_ENTRY_HELPER.checkJournalEntryForIncomeAccount(incomeAccount, twoMonthsfromNow,\n new JournalEntry(Float.parseFloat(\"50\"), JournalEntry.TransactionType.CREDIT),\n new JournalEntry(Float.parseFloat(\"240\"), JournalEntry.TransactionType.CREDIT));\n\n loanSchedule.clear();\n loanSchedule = LOAN_TRANSACTION_HELPER.getLoanRepaymentSchedule(REQUEST_SPEC, RESPONSE_SPEC, loanID);\n Map secondInstallment = loanSchedule.get(2);\n validateNumberForEqual(\"0.00\", String.valueOf(secondInstallment.get(\"totalOutstandingForPeriod\")));\n\n // Make payment for installment #3\n // Pay 2290 more than expected\n fourMonthsfromNowCalendar.add(Calendar.MONTH, 1);\n\n final String oneMonthfromNow = Utils.convertDateToURLFormat(fourMonthsfromNowCalendar);\n\n LOAN_TRANSACTION_HELPER.makeRepayment(oneMonthfromNow, Float.parseFloat(\"4580\"), loanID);\n JOURNAL_ENTRY_HELPER.checkJournalEntryForAssetAccount(assetAccount, oneMonthfromNow,\n new JournalEntry(Float.parseFloat(\"4580\"), JournalEntry.TransactionType.DEBIT),\n new JournalEntry(Float.parseFloat(\"4000\"), JournalEntry.TransactionType.CREDIT));\n JOURNAL_ENTRY_HELPER.checkJournalEntryForIncomeAccount(incomeAccount, oneMonthfromNow,\n new JournalEntry(Float.parseFloat(\"100\"), JournalEntry.TransactionType.CREDIT),\n new JournalEntry(Float.parseFloat(\"480\"), JournalEntry.TransactionType.CREDIT));\n\n loanSchedule.clear();\n loanSchedule = LOAN_TRANSACTION_HELPER.getLoanRepaymentSchedule(REQUEST_SPEC, RESPONSE_SPEC, loanID);\n HashMap thirdInstallment = loanSchedule.get(3);\n validateNumberForEqual(\"0.00\", String.valueOf(thirdInstallment.get(\"totalOutstandingForPeriod\")));\n\n // Make refund of 20\n // max 2290 to refund. Pay 20 means only principal\n // Default style refund order(principal, interest, fees and penalties\n // paid: principal 2000, interest 240, fees 50, penalty 0\n // refund 20 means paid: principal 1980, interest 240, fees 50, penalty\n // 0\n\n // FINERACT-885: As loan may not have started exactly four months ago,\n // make final payment today and not four months from start (as that may be in the future)\n fourMonthsfromNowCalendar.setTime(Date.from(Utils.getLocalDateOfTenant().atStartOfDay(Utils.getZoneIdOfTenant()).toInstant()));\n final String now = Utils.convertDateToURLFormat(fourMonthsfromNowCalendar);\n\n LOAN_TRANSACTION_HELPER.makeRefundByCash(now, Float.parseFloat(\"20\"), loanID);\n JOURNAL_ENTRY_HELPER.checkJournalEntryForAssetAccount(assetAccount, now,\n new JournalEntry(Float.parseFloat(\"20\"), JournalEntry.TransactionType.CREDIT),\n new JournalEntry(Float.parseFloat(\"20\"), JournalEntry.TransactionType.DEBIT));\n\n loanSchedule.clear();\n loanSchedule = LOAN_TRANSACTION_HELPER.getLoanRepaymentSchedule(REQUEST_SPEC, RESPONSE_SPEC, loanID);\n HashMap fourthInstallment = loanSchedule.get(4);\n validateNumberForEqual(\"20.00\", String.valueOf(fourthInstallment.get(\"totalOutstandingForPeriod\")));\n validateNumberForEqual(\"20.00\", String.valueOf(fourthInstallment.get(\"principalOutstanding\")));\n validateNumberForEqual(\"0.00\", String.valueOf(fourthInstallment.get(\"interestOutstanding\")));\n validateNumberForEqual(\"0.00\", String.valueOf(fourthInstallment.get(\"feeChargesOutstanding\")));\n\n // Make refund of 2000\n // max 2270 to refund. Pay 2000 means only principal\n // paid: principal 1980, interest 240, fees 50, penalty 0\n // refund 2000 means paid: principal 0, interest 220, fees 50, penalty 0\n\n LOAN_TRANSACTION_HELPER.makeRefundByCash(now, Float.parseFloat(\"2000\"), loanID);\n JOURNAL_ENTRY_HELPER.checkJournalEntryForAssetAccount(assetAccount, now,\n new JournalEntry(Float.parseFloat(\"2000\"), JournalEntry.TransactionType.CREDIT),\n new JournalEntry(Float.parseFloat(\"1980\"), JournalEntry.TransactionType.DEBIT));\n\n JOURNAL_ENTRY_HELPER.checkJournalEntryForIncomeAccount(incomeAccount, now,\n new JournalEntry(Float.parseFloat(\"20\"), JournalEntry.TransactionType.DEBIT));\n\n loanSchedule.clear();\n loanSchedule = LOAN_TRANSACTION_HELPER.getLoanRepaymentSchedule(REQUEST_SPEC, RESPONSE_SPEC, loanID);\n fourthInstallment = loanSchedule.get(4);\n validateNumberForEqual(\"2020.00\", String.valueOf(fourthInstallment.get(\"totalOutstandingForPeriod\")));\n validateNumberForEqual(\"2000.00\", String.valueOf(fourthInstallment.get(\"principalOutstanding\")));\n validateNumberForEqual(\"20.00\", String.valueOf(fourthInstallment.get(\"interestOutstanding\")));\n validateNumberForEqual(\"0.00\", String.valueOf(fourthInstallment.get(\"feeChargesOutstanding\")));\n\n }", "@Test\r\n public void testCreateMethod() {\r\n DailyBudget budget = new DailyBudget();\r\n\r\n budget.setName(\"Test budget\");\r\n RequestBuilder requestBuilder = MockMvcRequestBuilders\r\n .post(\"/api/budget\")\r\n .characterEncoding(\"utf-8\")\r\n .accept(MediaType.APPLICATION_JSON)\r\n .contentType(MediaType.APPLICATION_JSON)\r\n .header(\"authorization\", authUtils.generateToken(testUser.getEmail()))\r\n .content(String.format(\"{%s: %s}\",\r\n getEnclosedString(\"id\"),\r\n getEnclosedString(testUser.getId().toString())));\r\n\r\n try {\r\n MvcResult result = mockMvc.perform(requestBuilder).andReturn();\r\n MockHttpServletResponse response = result.getResponse();\r\n BudgetRole createdRole;\r\n\r\n assertEquals(HttpStatus.CREATED.value(), response.getStatus());\r\n assertEquals(1, testRoles.size()); // make sure only one instance was created\r\n\r\n createdRole = testRoles.get(0);\r\n assertEquals(testUser, createdRole.getUser());\r\n assertEquals(BudgetRoleType.CREATOR.rank, createdRole.getRoleType().rank);\r\n }\r\n catch (Exception ex) {\r\n log.error(ex.getMessage());\r\n }\r\n }", "public void makeDeposit() {\n deposit();\n }", "public com.vodafone.global.er.decoupling.binding.request.RefundCreditRequestType createRefundCreditRequestType()\n throws javax.xml.bind.JAXBException\n {\n return new com.vodafone.global.er.decoupling.binding.request.impl.RefundCreditRequestTypeImpl();\n }", "RentalAgency createRentalAgency();", "public static void main(String[] args) throws FileNotFoundException\r\n\t{\n\t\tBank b1 = new Bank();\r\n//\t\tb1.setCustomers(b1.LoadCustomersFromFile());\r\n\t\tSystem.out.println(b1.printCustomersToString());\r\n\t\tSystem.out.println(b1.printTransactionsToString());\r\n\t\tCustomer customer = b1.getCustomers().get(5);\r\n\t\tAccount account = b1.getCustomers().get(5).getAccounts().get(0);\r\n//\t\taccount.createMonthlyStatement(\"Oct\", 2019, account, customer, b1);\r\n//\t\tb1.setTransactions(b1.LoadTransactionsFromFile());\r\n\t\tSystem.out.println(b1);\r\n//\t\tBank b1=runcreate();\r\n//\t\tSystem.out.println(b1);\r\n//\t\tSaveorLoadBank.LoadBankFromFile();\r\n//\t\tArrayList<Customer> customers = b1.getCustomers();\r\n//\t\tCustomer c1 = customers.get(4);\r\n//\t\tCustomer c2 = customers.get(5);\r\n//\t\tSystem.out.println(customers.get(4));\r\n//\t\tSystem.out.println(customers.get(5));\r\n//\t\tAccount a1 = customers.get(4).getAccounts().get(0);\r\n//\t\tAccount a2 = customers.get(5).getAccounts().get(0);\r\n//\t\tTransferManager.Transfer(c1, a1, c2, a2, (long) 100);\r\n//\t\tSystem.out.println(c1);\r\n//\t\tSystem.out.println(c2);\r\n//\t\tSystem.out.println(b1);\r\n//\t\tSystem.out.println(b1);\r\n\t\tb1.saveTofilePrintWriter();\r\n\t\t\r\n\t\t\r\n\t\t\r\n\r\n\t}", "@Test\n\tpublic void createNewBankTest() {\n\t\tBank bank = data.createNewBank();\n\t\tassertEquals(bankTest, bank);\n\t}", "Document newWithdrawal(String reason, String expenseCategory,\n double amount, String effectiveDate);", "@Test\n\tpublic void createNewAccountWithOpeningBalanceChequingTest() {\n\t\tcreateAccountChequingTest();\n\t\tcreateNewAccountWithOpeningBalanceHelper();\n\t}", "@Test\n public void testLoanRefundByCashAccrualBasedAccounting() {\n Calendar fourMonthsfromNowCalendar = Calendar.getInstance(Utils.getTimeZoneOfTenant());\n fourMonthsfromNowCalendar.add(Calendar.MONTH, -4);\n\n // FINERACT-885: If the loan starts on day 27-31th of month and not all months have that\n // many days, then loan payment will get reset to a day of month less than today's day\n // and 4th payment will be in the past. In such case, start the loan a few days later,\n // so that 4th payment is guaranteed to be in the future.\n if (fourMonthsfromNowCalendar.get(Calendar.DAY_OF_MONTH) > 27) {\n fourMonthsfromNowCalendar.add(Calendar.DAY_OF_MONTH, 4);\n }\n\n String fourMonthsfromNow = Utils.convertDateToURLFormat(fourMonthsfromNowCalendar);\n\n final Integer clientID = ClientHelper.createClient(REQUEST_SPEC, RESPONSE_SPEC);\n ClientHelper.verifyClientCreatedOnServer(REQUEST_SPEC, RESPONSE_SPEC, clientID);\n\n /***\n * Create loan product with Default STYLE strategy\n */\n\n final Account assetAccount = ACCOUNT_HELPER.createAssetAccount();\n final Account incomeAccount = ACCOUNT_HELPER.createIncomeAccount();\n final Account expenseAccount = ACCOUNT_HELPER.createExpenseAccount();\n final Account overpaymentAccount = ACCOUNT_HELPER.createLiabilityAccount();\n\n final Integer loanProductID = createLoanProduct(\"0\", \"0\", LoanProductTestBuilder.DEFAULT_STRATEGY, ACCRUAL_UPFRONT, assetAccount,\n incomeAccount, expenseAccount, overpaymentAccount);// ,\n // LoanProductTestBuilder.EQUAL_INSTALLMENTS,\n // LoanProductTestBuilder.FLAT_BALANCE);\n Assertions.assertNotNull(loanProductID);\n\n /***\n * Apply for loan application and verify loan status\n */\n final String savingsId = null;\n final String principal = \"12,000.00\";\n\n // Add charges with payment mode regular\n List<HashMap> charges = new ArrayList<>();\n\n Integer flatInstallmentFee = ChargesHelper.createCharges(REQUEST_SPEC, RESPONSE_SPEC,\n ChargesHelper.getLoanInstallmentJSON(ChargesHelper.CHARGE_CALCULATION_TYPE_FLAT, \"50\", false));\n addCharges(charges, flatInstallmentFee, \"50\", null);\n\n List<HashMap> collaterals = new ArrayList<>();\n\n final Integer collateralId = CollateralManagementHelper.createCollateralProduct(REQUEST_SPEC, RESPONSE_SPEC);\n Assertions.assertNotNull(collateralId);\n final Integer clientCollateralId = CollateralManagementHelper.createClientCollateral(REQUEST_SPEC, RESPONSE_SPEC,\n String.valueOf(clientID), collateralId);\n Assertions.assertNotNull(clientCollateralId);\n addCollaterals(collaterals, clientCollateralId, BigDecimal.valueOf(1));\n\n final Integer loanID = applyForLoanApplicationWithPaymentStrategyAndPastMonth(clientID, loanProductID, charges, savingsId,\n principal, LoanApplicationTestBuilder.DEFAULT_STRATEGY, -4, collaterals);\n Assertions.assertNotNull(loanID);\n HashMap loanStatusHashMap = LoanStatusChecker.getStatusOfLoan(REQUEST_SPEC, RESPONSE_SPEC, loanID);\n LoanStatusChecker.verifyLoanIsPending(loanStatusHashMap);\n\n LOG.info(\"-----------------------------------APPROVE LOAN-----------------------------------------\");\n loanStatusHashMap = LOAN_TRANSACTION_HELPER.approveLoan(fourMonthsfromNow, loanID);\n LoanStatusChecker.verifyLoanIsApproved(loanStatusHashMap);\n LoanStatusChecker.verifyLoanIsWaitingForDisbursal(loanStatusHashMap);\n\n LOG.info(\"-------------------------------DISBURSE LOAN-------------------------------------------\");\n String loanDetails = LOAN_TRANSACTION_HELPER.getLoanDetails(REQUEST_SPEC, RESPONSE_SPEC, loanID);\n loanStatusHashMap = LOAN_TRANSACTION_HELPER.disburseLoanWithNetDisbursalAmount(fourMonthsfromNow, loanID,\n JsonPath.from(loanDetails).get(\"netDisbursalAmount\").toString());\n LoanStatusChecker.verifyLoanIsActive(loanStatusHashMap);\n\n final JournalEntry[] assetAccountInitialEntry = { new JournalEntry(Float.parseFloat(\"1440\"), JournalEntry.TransactionType.DEBIT),\n new JournalEntry(Float.parseFloat(\"300.00\"), JournalEntry.TransactionType.DEBIT),\n new JournalEntry(Float.parseFloat(\"12000.00\"), JournalEntry.TransactionType.CREDIT),\n new JournalEntry(Float.parseFloat(\"12000.00\"), JournalEntry.TransactionType.DEBIT) };\n JOURNAL_ENTRY_HELPER.checkJournalEntryForAssetAccount(assetAccount, fourMonthsfromNow, assetAccountInitialEntry);\n\n ArrayList<HashMap> loanSchedule = LOAN_TRANSACTION_HELPER.getLoanRepaymentSchedule(REQUEST_SPEC, RESPONSE_SPEC, loanID);\n HashMap firstInstallment = loanSchedule.get(1);\n validateNumberForEqual(\"2290\", String.valueOf(firstInstallment.get(\"totalOutstandingForPeriod\")));\n\n // Make payment for installment #1\n\n fourMonthsfromNowCalendar.add(Calendar.MONTH, 1);\n\n final String threeMonthsfromNow = Utils.convertDateToURLFormat(fourMonthsfromNowCalendar);\n\n LOAN_TRANSACTION_HELPER.makeRepayment(threeMonthsfromNow, Float.parseFloat(\"2290\"), loanID);\n loanSchedule.clear();\n loanSchedule = LOAN_TRANSACTION_HELPER.getLoanRepaymentSchedule(REQUEST_SPEC, RESPONSE_SPEC, loanID);\n firstInstallment = loanSchedule.get(1);\n validateNumberForEqual(\"0.00\", String.valueOf(firstInstallment.get(\"totalOutstandingForPeriod\")));\n\n // Make payment for installment #2\n fourMonthsfromNowCalendar.add(Calendar.MONTH, 1);\n\n final String twoMonthsfromNow = Utils.convertDateToURLFormat(fourMonthsfromNowCalendar);\n\n LOAN_TRANSACTION_HELPER.makeRepayment(twoMonthsfromNow, Float.parseFloat(\"2290\"), loanID);\n JOURNAL_ENTRY_HELPER.checkJournalEntryForAssetAccount(assetAccount, twoMonthsfromNow,\n new JournalEntry(Float.parseFloat(\"2290\"), JournalEntry.TransactionType.DEBIT),\n new JournalEntry(Float.parseFloat(\"2290\"), JournalEntry.TransactionType.CREDIT));\n\n loanSchedule.clear();\n loanSchedule = LOAN_TRANSACTION_HELPER.getLoanRepaymentSchedule(REQUEST_SPEC, RESPONSE_SPEC, loanID);\n Map secondInstallment = loanSchedule.get(2);\n validateNumberForEqual(\"0.00\", String.valueOf(secondInstallment.get(\"totalOutstandingForPeriod\")));\n\n // Make payment for installment #3\n // Pay 2290 more than expected\n fourMonthsfromNowCalendar.add(Calendar.MONTH, 1);\n\n final String oneMonthfromNow = Utils.convertDateToURLFormat(fourMonthsfromNowCalendar);\n\n LOAN_TRANSACTION_HELPER.makeRepayment(oneMonthfromNow, Float.parseFloat(\"4580\"), loanID);\n JOURNAL_ENTRY_HELPER.checkJournalEntryForAssetAccount(assetAccount, oneMonthfromNow,\n new JournalEntry(Float.parseFloat(\"4580\"), JournalEntry.TransactionType.DEBIT),\n new JournalEntry(Float.parseFloat(\"4580\"), JournalEntry.TransactionType.CREDIT));\n\n loanSchedule.clear();\n loanSchedule = LOAN_TRANSACTION_HELPER.getLoanRepaymentSchedule(REQUEST_SPEC, RESPONSE_SPEC, loanID);\n HashMap thirdInstallment = loanSchedule.get(3);\n validateNumberForEqual(\"0.00\", String.valueOf(thirdInstallment.get(\"totalOutstandingForPeriod\")));\n\n // Make refund of 20\n // max 2290 to refund. Pay 20 means only principal\n // Default style refund order(principal, interest, fees and penalties\n // paid: principal 2000, interest 240, fees 50, penalty 0\n // refund 20 means paid: principal 1980, interest 240, fees 50, penalty\n // 0\n\n // FINERACT-885: As loan may not have started exactly four months ago,\n // make final payment today and not four months from start (as that may be in the future)\n fourMonthsfromNowCalendar.setTime(Date.from(Utils.getLocalDateOfTenant().atStartOfDay(Utils.getZoneIdOfTenant()).toInstant()));\n final String now = Utils.convertDateToURLFormat(fourMonthsfromNowCalendar);\n\n LOAN_TRANSACTION_HELPER.makeRefundByCash(now, Float.parseFloat(\"20\"), loanID);\n JOURNAL_ENTRY_HELPER.checkJournalEntryForAssetAccount(assetAccount, now,\n new JournalEntry(Float.parseFloat(\"20\"), JournalEntry.TransactionType.CREDIT),\n new JournalEntry(Float.parseFloat(\"20\"), JournalEntry.TransactionType.DEBIT));\n\n loanSchedule.clear();\n loanSchedule = LOAN_TRANSACTION_HELPER.getLoanRepaymentSchedule(REQUEST_SPEC, RESPONSE_SPEC, loanID);\n HashMap fourthInstallment = loanSchedule.get(4);\n validateNumberForEqual(\"20.00\", String.valueOf(fourthInstallment.get(\"totalOutstandingForPeriod\")));\n validateNumberForEqual(\"20.00\", String.valueOf(fourthInstallment.get(\"principalOutstanding\")));\n validateNumberForEqual(\"0.00\", String.valueOf(fourthInstallment.get(\"interestOutstanding\")));\n validateNumberForEqual(\"0.00\", String.valueOf(fourthInstallment.get(\"feeChargesOutstanding\")));\n\n // Make refund of 2000\n // max 2270 to refund. Pay 2000 means only principal\n // paid: principal 1980, interest 240, fees 50, penalty 0\n // refund 2000 means paid: principal 0, interest 220, fees 50, penalty 0\n\n LOAN_TRANSACTION_HELPER.makeRefundByCash(now, Float.parseFloat(\"2000\"), loanID);\n JOURNAL_ENTRY_HELPER.checkJournalEntryForAssetAccount(assetAccount, now,\n new JournalEntry(Float.parseFloat(\"2000\"), JournalEntry.TransactionType.CREDIT),\n new JournalEntry(Float.parseFloat(\"1980\"), JournalEntry.TransactionType.DEBIT));\n\n JOURNAL_ENTRY_HELPER.checkJournalEntryForIncomeAccount(incomeAccount, now,\n new JournalEntry(Float.parseFloat(\"20\"), JournalEntry.TransactionType.DEBIT));\n\n loanSchedule.clear();\n loanSchedule = LOAN_TRANSACTION_HELPER.getLoanRepaymentSchedule(REQUEST_SPEC, RESPONSE_SPEC, loanID);\n fourthInstallment = loanSchedule.get(4);\n validateNumberForEqual(\"2020.00\", String.valueOf(fourthInstallment.get(\"totalOutstandingForPeriod\")));\n validateNumberForEqual(\"2000.00\", String.valueOf(fourthInstallment.get(\"principalOutstanding\")));\n validateNumberForEqual(\"20.00\", String.valueOf(fourthInstallment.get(\"interestOutstanding\")));\n validateNumberForEqual(\"0.00\", String.valueOf(fourthInstallment.get(\"feeChargesOutstanding\")));\n\n }", "@Override\n\tpublic void createAccount(String username, Bank bank) {\n\t\ttry {\n\t\tAccount newAccount = new Account(username, bank.getBankID(), bank.getNumOfAccounts()+1);\n\t\tbank.setNumOfAccounts(bank.getNumOfAccounts()+1);\n\t\taddAccount(bank, newAccount);\n\t\t}catch(NullPointerException e) {\n\t\t\tSystem.out.println(\"Could not find bank\");\n\t\t}\n\t\t\n\t}", "void create(Order order);", "private void BScreate() {\n\n\t\tint sum=0;//全枝数のカウント\n\t\tfor(int i=0;i<banknode;i++) sum+=Bank.get(i).deg;\n\n\t\t//e,d,nの決定\n\t\tif(NW==\"BA\"){\n\t\tfor(int i=0;i<banknode;i++) {\n\t\t\tBank.get(i).totalassets=E*((double)Bank.get(i).deg/(double)sum);\n\t\t\tBank.get(i).n=Bank.get(i).totalassets*Bank.get(i).CAR;\n\t\t\tBank.get(i).d=Bank.get(i).totalassets-Bank.get(i).n;\n\t\t\tBank.get(i).buffer=Bank.get(i).totalassets;\n\t\t}\n\t\t}\n\n\t\tif(NW==\"CM\"){\n\t\t\tfor(int i=0;i<banknode;i++){\n\t\t\t\tBank.get(i).totalassets=E/banknode;\n\t\t\t\tBank.get(i).n=Bank.get(i).totalassets*asyCAR;\n\t\t\t\tBank.get(i).forcelev=megaCAR;\n\t\t\t\tBank.get(i).d=Bank.get(i).totalassets-Bank.get(i).n;\n\t\t\t\tBank.get(i).buffer=Bank.get(i).totalassets;\n\t\t\t}\n\n\t\t}\n\n\t}", "private void createSavingsAccountsTable() {\n\t\ttry {\n\t\t\tStatement stmt = this.conn.createStatement();\n\t\t\tstmt.executeUpdate(\"CREATE TABLE savingsAccounts \"\n\t\t\t\t\t+ \"(id BIGINT GENERATED ALWAYS AS IDENTITY ( START WITH 2000000001, INCREMENT BY 1), \" + \"owner INT, \"\n\t\t\t\t\t+ \"balance DOUBLE, \" + \"intRate DOUBLE, \"\n\t\t\t\t\t+ \"timeCreated BIGINT, \" + \"lastPaidInterest DOUBLE, \"\n\t\t\t\t\t+ \"dateOfLastPaidInterest BIGINT)\");\n\t\t\tconn.commit();\n\t\t\tSystem.out.println(\"Created table SavingsAccounts\");\n\t\t} catch (SQLException sqle) {\n\t\t\tSystem.err.println(\"Creation of SavingsAccounts table FAILED\");\n\t\t\tSystem.err.println(sqle);\n\t\t}\n\t}", "public Account(){\n this.id = 0;\n this.balance = 0;\n this.annualInterestRate = 0;\n this.dateCreated = new Date();\n }", "public Account()\n {\n // initialise instance variables\n balance = 0.00;\n remainder = 0;\n }", "Account(){\r\n\t\t//id, balance and annualInterestRate are set to 0, the dateCreated is set to the current date and time\r\n\t\t setId(0);\r\n\t\t setBalance(0);\r\n\t\t setAnnualInterestRate(0);\r\n\t\t this.dateCreated = new Date(System.currentTimeMillis());\r\n\t }", "public BankAccount() {\n\t\tthis.money = 0;\n\t}", "public SavingsAccount(double balance)\n {\n startingBalance = balance;\n }", "public com.vodafone.global.er.decoupling.binding.request.RefundCreditRequest createRefundCreditRequest()\n throws javax.xml.bind.JAXBException\n {\n return new com.vodafone.global.er.decoupling.binding.request.impl.RefundCreditRequestImpl();\n }", "private Tx createTransaction(BitCoinResponseDTO btcDTO, SellerBitcoinInfo sbi) {\n\t\t\n\t\tTx tx = new Tx();\n\t\t\n\t\t\n\t\ttx.setDate(new Date());\n\t\ttx.setAmountOfMoney(btcDTO.getPrice_amount());\n\t\ttx.setStatus(TxStatus.PENDING);\n\t\ttx.setRecieverAddress(btcDTO.getPayment_url());\n\t\ttx.setorder_id(btcDTO.getId()); //ovaj id je na coin gate-u i moram ga cuvati u transakciji\n\t\ttx.setTxDescription(\"Porudzbina je kreirana od strane korisnika\");\n\t\ttx.setSbi(sbi);\n\t\t\n\t\t//trebace ovde jos da se setuje id korisnika koji je kreirao porudzbinu kako bi kasnije mogao da getuje sve\n\t\t//njegove transakcije\n\t\t\n\t\t\n\t\treturn tx;\n\t\t\n\t}", "private Bank() {\r\n\t\tsuper();\r\n\t\tlogService = new Logger(\"driverName\");\r\n\t\tlogger = new Logger(\"driverName\");\r\n\t\tthis.balance = balance;\r\n\t\tthis.clients = new Client[100];\r\n\t}", "public static void createTransaction() throws IOException {\n\t\t\n\t\tDate date = new Date((long) random(100000000));\n\t\tString date2 = \"'19\" + date.getYear() + \"-\" + (random(12)+1) + \"-\" + (random(28)+1) + \"'\";\n\t\tint amount = random(10000);\n\t\tint cid = random(SSNmap.size()) + 1;\n\t\tint vid = random(venders.size()) + 1;\n\t\t\n\t\twhile(ownership.get(cid) == null)\n\t\t\tcid = random(SSNmap.size()) + 1;\n\t\tString cc = ownership.get(cid).get(random(ownership.get(cid).size()));\n\t\t\n\t\twriter.write(\"INSERT INTO Transaction (Id, Date, vid, cid, CCNum, amount) Values (\" + tid++ +\", \" \n\t\t\t\t+ date2 + \", \" + vid + \", \" + cid + \", '\" + cc + \"', \" + amount + line);\n\t\twriter.flush();\n\t}", "private static void receiverRecordCreator(DonorReceiver acc) {\n ReceiverOrganInventory organInventory = acc.getRequiredOrgans();\n\n boolean[] organPresent = {\n organInventory.getLiver(), organInventory.getKidneys(), organInventory.getHeart(),\n organInventory.getLungs(), organInventory.getIntestine(), organInventory.getCorneas(),\n organInventory.getMiddleEars(), organInventory.getSkin(), organInventory.getBone(),\n organInventory.getBoneMarrow(), organInventory.getConnectiveTissue(),\n organInventory.getPancreas()\n };\n\n LocalDateTime[] organTimes = {\n organInventory.getLiverTimeStamp(), organInventory.getKidneysTimeStamp(),\n organInventory.getHeartTimeStamp(), organInventory.getLungsTimeStamp(),\n organInventory.getIntestineTimeStamp(), organInventory.getCorneasTimeStamp(),\n organInventory.getMiddleEarsTimeStamp(), organInventory.getSkinTimeStamp(),\n organInventory.getBoneTimeStamp(), organInventory.getBoneMarrowTimeStamp(),\n organInventory.getConnectiveTissueTimeStamp(), organInventory.getPancreasTimeStamp()\n };\n\n String[] organString = {\n \"Liver\", \"Kidneys\", \"Heart\", \"Lungs\", \"Intestines\", \"Corneas\", \"Middle Ear\", \"Skin\", \"Bone\",\n \"Bone Marrow\", \"Connective Tissue\", \"Pancreas\"\n };\n\n for (int i = 0; i < organPresent.length; i++) {\n if (organPresent[i]) {\n ReceiverRecord record = new ReceiverRecord(acc.fullName(), acc.getUserName(),\n acc.getContactDetails().getAddress().getRegion(), organTimes[i], organString[i]);\n records.add(record);\n }\n }\n }", "public void createExpReward() {\n try {\n int exp = RandomBenefitModel.getExpReward(encounter, characterVM.getDistance());\n if (exp > 0) characterVM.addExp(exp);\n } catch (JSONException e) {\n e.printStackTrace();\n }\n }", "public Transaction(int staff, int memberInvovled, int bookInvovled, int rentDurationInDays, double cashFlow) {\n this.type = TransactionType.RENT;\n this.rentDurationInDays = rentDurationInDays;\n this.staffHandled = staff;\n this.memberInvovled = memberInvovled;\n this.bookInvovled = bookInvovled;\n this.cashFlow = cashFlow;\n }", "private void createTx() throws Exception {\n PublicKey recipient = Seed.getRandomAddress();\n Transaction tx = new Transaction(wallet.pb, recipient, wallet.pr);\n//\t\tSystem.out.println(\"Created a tx\");\n txPool.add(tx);\n//\t\tcache.put(tx.txId, null);\n sendTx(tx);\n }", "public void issueScheduledTransactionForRefund(Bid bid, BidsRepository bidsRepository, String memo) {\n // Create a transfer transaction for the refund\n // check the status of the bid isn't already refunded, issued or in error\n try {\n Bid testBid = bidsRepository.getBidForTimestamp(bid.getTimestamp());\n if ((testBid != null) && ! testBid.isRefunded() && ! testBid.isRefundIssued() && ! testBid.isRefundError()) {\n this.transactionId = TransactionId.generate(AccountId.fromString(Objects.requireNonNull(env.get(\"OPERATOR_ID\"))));\n this.transactionId.setScheduled(true);\n String shortTransactionId = this.transactionId.toString().replace(\"?scheduled\", \"\");\n\n TransferTransaction transferTransaction = new TransferTransaction();\n transferTransaction.setTransactionMemo(memo);\n transferTransaction.addHbarTransfer(this.auctionAccountId, Hbar.fromTinybars(-bid.getBidamount()));\n transferTransaction.addHbarTransfer(AccountId.fromString(bid.getBidderaccountid()), Hbar.fromTinybars(bid.getBidamount()));\n\n this.transaction = transferTransaction;\n\n @Var TransactionSchedulerResult transactionSchedulerResult = null;\n try {\n transactionSchedulerResult = issueScheduledTransaction(\"Scheduled Auction Refund\");\n if (transactionSchedulerResult.success\n || transactionSchedulerResult.status == Status.NO_NEW_VALID_SIGNATURES\n || transactionSchedulerResult.status == Status.DUPLICATE_TRANSACTION) {\n log.info(\"Refund transaction successfully scheduled (scheduleId {}, transactionId {})\", transactionSchedulerResult.getScheduleId(), shortTransactionId);\n log.info(\"setting bid to refund issued (timestamp = {})\", bid.getTimestamp());\n try {\n if (StringUtils.isEmpty(transactionSchedulerResult.getScheduleId())) {\n log.error(\"empty schedule id for bid transaction id {}\", bid.getTransactionid());\n bidsRepository.setRefundError(bid.getTransactionid());\n } else {\n bidsRepository.setRefundIssued(bid.getTimestamp(), shortTransactionId, transactionSchedulerResult.getScheduleId());\n }\n } catch (SQLException e) {\n log.error(\"Failed to set bid refund issued (bid timestamp {})\",bid.getTimestamp(), e);\n }\n } else {\n log.error(\"Error issuing refund to bid - timestamp = {} status {}\", bid.getTimestamp(), transactionSchedulerResult.status);\n bidsRepository.setRefundError(bid.getTransactionid());\n }\n } catch (Exception e) {\n log.error(e, e);\n }\n }\n } catch (SQLException e) {\n log.error(e, e);\n }\n }", "public ATM() {\n usuarioAutenticado = false; // al principio, el usuario no está autenticado\n numeroCuentaActual = 0; // al principio, no hay número de cuenta\n pantalla = new Pantalla(); // crea la pantalla\n teclado = new Teclado(); // crea el teclado\n dispensadorEfectivo = new DispensadorEfectivo(); // crea el dispensador de efectivo\n ranuraDeposito = new RanuraDeposito(); // crea la ranura de depósito\n baseDatosBanco = new BaseDatosBanco(); // crea la base de datos de información de cuentas\n }", "@Test\n public void testCreateRewardAccount8() {\n Dining dining = Dining.createDining(\"100.00\", \"4320123412340008\", \"123456008\");\n\n Account account = createAccount8();\n\n AccountContribution contribution = account.makeContribution(new MonetaryAmount(8));\n try {\n RewardConfirmation confirmation = repository.confirmReward(contribution, dining);\n Assert.assertNotNull(\"confirmation should not be null\", confirmation);\n Assert.assertNotNull(\"confirmation number should not be null\", confirmation.getConfirmationNumber());\n Assert.assertEquals(\"wrong contribution object\", contribution, confirmation.getAccountContribution());\n verifyRewardInserted(confirmation, dining);\n } catch (DataIntegrityViolationException dive) {\n logger.error(\"exception on creation of reward from contribution=\" + contribution + \":dining=\" + dining,\n dive);\n throw dive;\n }\n }", "public void createUserAndFundFromCash(\n constants.core.clientExperience.Constants.BrokerageAccountType desiredAccountType,\n constants.core.clientExperience.Constants.BankAccountType cashAccountType,\n constants.core.clientExperience.Constants.BrokerageAccountType destinationAccountType) throws Exception {\n\n AdvisorSplashPage advisorSplashPage = new AdvisorSplashPage(getDriver());\n AddAccountsPage addAccountsPage = signupUser(advisorSplashPage, Constants.LastName.PREMIUM_INDIVIDUAL);\n\n DepositCashForm depositCashForm = addAccountsPage.clickOpenDepositCashBtn();\n addAccountsPage = depositCashForm.reportCashAccount(\n desiredAccountType,\n \"5000\",\n cashAccountType,\n getFreeGaslampUser().routingNumber,\n getFreeGaslampUser().accountNumber);\n\n ReviewTransfersPage reviewTransfersPage = addAccountsPage.navigateToReviewTransfersPage();\n softAssert.assertTrue(reviewTransfersPage.verifyDestinationAccountType(0, destinationAccountType));\n\n ManagedApplicationPage managedApplicationPage = reviewTransfersPage.clickOnNextBtn();\n enrollFreeUserToPremium(managedApplicationPage);\n\n PaperworkStatusPage paperworkStatusPage = managedApplicationPage.navigateToPaperworkStatusPage();\n DocuSignPage docuSignPage = paperworkStatusPage.waitForPageToTransitionToDocuSign();\n paperworkStatusPage = docuSignPage.skipDocusign();\n PremiumRetirementDashboardPage retirementDashboardPage = paperworkStatusPage.clickOnGoToDashboard();\n\n softAssert.assertTrue(retirementDashboardPage.isClientEnrolling());\n\n retirementDashboardPage.header.logOut();\n softAssert.assertAll();\n }", "@Override\n public void crearReloj() {\n Manecilla seg;\n seg = new Manecilla(40,60,0,1,null);\n cronometro = new Reloj(seg);\n }", "public co.com.telefonica.atiempo.vpistbba.actividades.df.configuracion.ejb.sb.AGenerarReciboLocal create()\n\t\tthrows javax.ejb.CreateException;", "@Override\n\tpublic void createItem(Object result) {\n\t\t\n\t\tunloadform();\n\t\tif (result != null) {\n\t\t\tIOTransactionLogic tr = (IOTransactionLogic) result;\n\t\t\tint year = Calendar.getInstance().get(Calendar.YEAR);\n\t\t\tint month = Calendar.getInstance().get(Calendar.MONTH);\n\t\t\t\n\t\t\tCalendar cal = Calendar.getInstance();\n\t\t\tcal.setTime(tr.getDate());\n\t\t\tint trYear = cal.get(Calendar.YEAR);\n\t\t\tint trMonth = cal.get(Calendar.MONTH);\n\t\t\t\n\t\t\tif ((year == trYear) && (month == trMonth)\n\t\t\t\t\t&& tr.getBankAccountID() == bal.getId()) {\n\t\t\t\ttransactionDisplayer trDisplayer = new transactionDisplayer(tr);\n\t\t\t\tsetDataLineChart();\n\t\t\t\tsetDataPieChart();\n\t\t\t}\n\t\t\t\n\t\t}\n\t}", "Reservation createReservation();", "public Account() {\n\t\t//starting amount is 1500\n\t\tmoney = 1500;\n\t}", "private RentalAgreement createRentalAgreement(Order order, int discountPercentage, List<LocalDate> holidays) {\n RentalAgreement rentAgree = new RentalAgreement(order, discountPercentage, holidays);\n\n return rentAgree;\n }", "public Transaction getDummyTransaction(String action) {\n\n\t\t// Long payerAccountNum = 111l;\n\t\tLong payerRealmNum = 0l;\n\t\tLong payerShardNum = 0l;\n\t\t// Long nodeAccountNum=123l;\n\t\tLong nodeRealmNum = 0l;\n\t\tLong nodeShardNum = 0l;\n\t\tlong transactionFee = 0l;\n\t\tTimestamp startTime =\n\t\t\t\tRequestBuilder.getTimestamp(Instant.now(Clock.systemUTC()).minusSeconds(13));\n\t\tDuration transactionDuration = RequestBuilder.getDuration(100);\n\t\tboolean generateRecord = false;\n\t\tString memo = \"UnitTesting\";\n\t\tint thresholdValue = 10;\n\t\tList<Key> keyList = new ArrayList<>();\n\t\tKeyPair pair = new KeyPairGenerator().generateKeyPair();\n\t\tbyte[] pubKey = ((EdDSAPublicKey) pair.getPublic()).getAbyte();\n\t\tKey akey =\n\t\t\t\tKey.newBuilder().setEd25519(ByteString.copyFromUtf8((MiscUtils.commonsBytesToHex(pubKey)))).build();\n\t\tPrivateKey priv = pair.getPrivate();\n\t\tkeyList.add(akey);\n\t\tlong initBal = 100;\n\t\tlong sendRecordThreshold = 5;\n\t\tlong receiveRecordThreshold = 5;\n\t\tboolean receiverSign = false;\n\t\tDuration autoRenew = RequestBuilder.getDuration(100);\n\t\t;\n\t\tlong proxyAccountNum = 12345l;\n\t\tlong proxyRealmNum = 0l;\n\t\tlong proxyShardNum = 0l;\n\t\tint proxyFraction = 10;\n\t\tint maxReceiveProxyFraction = 10;\n\t\tlong shardID = 0l;\n\t\tlong realmID = 0l;\n\n\t\tTransaction trx = null;\n\t\tSignatureList sigList = SignatureList.getDefaultInstance();\n\t\tTimestamp timestamp = TestHelper.getDefaultCurrentTimestampUTC();\n\n\t\t/**\n\t\t * SignatureList sigList = SignatureList.getDefaultInstance(); Transaction transferTx =\n\t\t * RequestBuilder.getCryptoTransferRequest( payer.getAccountNum(), payer.getRealmNum(),\n\t\t * payer.getShardNum(), nodeAccount.getAccountNum(), nodeAccount.getRealmNum(),\n\t\t * nodeAccount.getShardNum(), 800, timestamp, transactionDuration, false, \"test\", sigList,\n\t\t * payer.getAccountNum(), -100l, nodeAccount.getAccountNum(), 100l); transferTx =\n\t\t * TransactionSigner.signTransaction(transferTx, accountKeys.get(payer));\n\t\t */\n\n\t\tif (\"SolidityIDQuery\".equalsIgnoreCase(action)) {\n\t\t\ttrx = RequestBuilder.getCryptoTransferRequest(payerAccountId.getAccountNum(),\n\t\t\t\t\tpayerAccountId.getRealmNum(), payerAccountId.getShardNum(), nodeAccountId.getAccountNum(),\n\t\t\t\t\tnodeAccountId.getRealmNum(), nodeAccountId.getShardNum(), 800, timestamp,\n\t\t\t\t\ttransactionDuration, false, \"test\", sigList, payerAccountId.getAccountNum(), -100l,\n\t\t\t\t\tnodeAccountId.getAccountNum(), 100l);\n\t\t\t// trx = TransactionSigner.signTransaction(trx, account2keyMap.get(payerAccountId));\n\t\t}\n\n\t\tif (\"createContract\".equalsIgnoreCase(action)) {\n\t\t\tFileID fileID = FileID.newBuilder().setFileNum(9999l).setRealmNum(1l).setShardNum(2l).build();\n\n\t\t\ttrx = RequestBuilder.getCreateContractRequest(payerAccountId.getAccountNum(),\n\t\t\t\t\tpayerAccountId.getRealmNum(), payerAccountId.getShardNum(), nodeAccountId.getAccountNum(),\n\t\t\t\t\tnodeAccountId.getRealmNum(), nodeAccountId.getShardNum(), 50000000000l, timestamp,\n\t\t\t\t\ttransactionDuration, true, \"createContract\", DEFAULT_CONTRACT_OP_GAS, fileID,\n\t\t\t\t\tByteString.EMPTY, 0, transactionDuration,\n\t\t\t\t\tSignatureList.newBuilder().addSigs(\n\t\t\t\t\t\t\tSignature.newBuilder().setEd25519(ByteString.copyFrom(\"testsignature\".getBytes())))\n\t\t\t\t\t\t\t.build(),\n\t\t\t\t\t\"\");\n\t\t}\n\n\t\t// if(\"SolidityIDQuery\".equalsIgnoreCase(action)) {\n\t\t// long durationInSeconds = DAY_SEC * 30;\n\t\t// * Duration contractAutoRenew = Duration.newBuilder().setSeconds(durationInSeconds).build();\n\t\t// * Timestamp timestamp = TestHelper.getDefaultCurrentTimestampUTC();\n\t\t// * Duration transactionDuration = RequestBuilder.getDuration(30, 0);\n\t\t// * Transaction createContractRequest =\n\t\t// RequestBuilder.getCreateContractRequest(payerAccountId.getAccountNum(),\n\t\t// * payerAccountId.getRealmNum(), payerAccountId.getShardNum(), nodeAccountId.getAccountNum(),\n\t\t// * nodeAccountId.getRealmNum(), nodeAccountId.getShardNum(), 100l, timestamp,\n\t\t// transactionDuration, true, \"createContract\",\n\t\t// * DEFAULT_CONTRACT_OP_GAS, contractFile, ByteString.EMPTY, 0, contractAutoRenew,\n\t\t// * SignatureList.newBuilder()\n\t\t// *\n\t\t// .addSigs(Signature.newBuilder().setEd25519(ByteString.copyFrom(\"testsignature\".getBytes())))\n\t\t// * .build());\n\t\t// }\n\n\t\treturn trx;\n\n\t}", "void create(Trubriques trubriques);", "public void createAccount(){\n System.out.println(\"vi skal starte \");\n }", "public BankAccount(int balance) {\n\n this.balance = balance;\n\n }", "private static void generateMoneyTransfer(int branchID) {\n long accountNo1 = getRandAccountFromBranch(branchID), accountNo2 = getRandAccount();\n int amount = getRandomAmount();\n writeToFile(String.format(\"%d %d %d\\n\", accountNo1, accountNo2, amount));\n }", "public Savings_Account (int account_num, double initial_balance, double interest_rate) \r\n {\r\n\r\n super (account_num, initial_balance);\r\n\r\n rate = interest_rate;\r\n\r\n }", "public void create(){}", "public ReturnCash(){\n\t\t\n\t}", "private Account createAccount4() {\n Account account = new Account(\"123456004\", \"Chad I. Cobbs\",\n new SimpleDate(4, 23, 1976).asDate(), \"[email protected]\", true, false,\n new CreditCard(\"1234123412340004\"), new CreditCard(\"4320123412340005\"));\n\n final Percentage percent50 = new Percentage(0.5);\n final Percentage percent25 = new Percentage(0.25);\n account.addBeneficiary(\"Jane\", percent25);\n account.addBeneficiary(\"Amy\", percent25);\n account.addBeneficiary(\"Susan\", percent50);\n return account;\n }" ]
[ "0.6318638", "0.6184281", "0.61012876", "0.5852356", "0.5823342", "0.5782764", "0.5767218", "0.5748892", "0.5744501", "0.5729803", "0.57275635", "0.5720645", "0.57185435", "0.56889886", "0.56674796", "0.55958205", "0.5568814", "0.55650115", "0.5545509", "0.5530074", "0.5527745", "0.5511704", "0.54945403", "0.5486971", "0.5471069", "0.5462488", "0.5462488", "0.54564553", "0.545277", "0.5452362", "0.54491144", "0.54283285", "0.5406899", "0.54039073", "0.5395304", "0.5377438", "0.53768194", "0.53690165", "0.53550243", "0.53485274", "0.5347331", "0.5347046", "0.5346506", "0.5346232", "0.53459626", "0.5341183", "0.5329841", "0.53181463", "0.5309135", "0.5308908", "0.53017426", "0.5300798", "0.52876186", "0.52826416", "0.5268461", "0.52669734", "0.52658516", "0.5265171", "0.5264534", "0.5249032", "0.5246791", "0.5245159", "0.52409244", "0.5228078", "0.52214605", "0.52188665", "0.5217111", "0.52148956", "0.51831347", "0.5167979", "0.5165818", "0.5161474", "0.51605713", "0.51590645", "0.51454496", "0.514367", "0.51409984", "0.51405036", "0.5133101", "0.5132184", "0.51319695", "0.5130934", "0.5126826", "0.5125984", "0.51229185", "0.51195216", "0.5116796", "0.511611", "0.51139194", "0.51108533", "0.5110232", "0.51063764", "0.51049143", "0.50938386", "0.5089182", "0.5084072", "0.5078948", "0.5070761", "0.5068895", "0.5065829" ]
0.6818048
0
This can be changed based on how harsh we want to approve messages
protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.approve_message); messagesRatedInRow = 0; AlertDialog.Builder login_dialog_builder = new AlertDialog.Builder(context); LayoutInflater inflater = (LayoutInflater) context.getSystemService(Context.LAYOUT_INFLATER_SERVICE); View rate_dialog_view = inflater.inflate(R.layout.rate_dialog, null); login_dialog_builder.setView(rate_dialog_view); confirm_dialog = login_dialog_builder.create(); // Define dialog views confirm_button = (ImageView) rate_dialog_view.findViewById(R.id.confirm); deny_button = (ImageView) rate_dialog_view.findViewById(R.id.deny); dialog_title = (TextView) rate_dialog_view.findViewById(R.id.rate_dialog_title); dialog_text = (TextView) rate_dialog_view.findViewById(R.id.rate_dialog_more); // Define views skip = (ImageView) findViewById(R.id.skip); submit = (ImageView) findViewById(R.id.submit); message = (TextView) findViewById(R.id.message_text); arrow_back = (ImageView) findViewById(R.id.arrow_back); q_button = (ImageView) findViewById(R.id.question); // Define Intents goToSplashPage = new Intent(context, SplashPage.class); // Rating stars stars = (RatingBar) findViewById(R.id.star_rating); stars.setOnRatingBarChangeListener(new OnRatingBarChangeListener(){ @Override public void onRatingChanged(RatingBar ratingBar, float rating, boolean fromUser) { currentRating = rating; } }); queue = new ArrayList<ParseObject>(); queuedMessages = new QueuedMessages(message, context, approveLimit); // Click listeners arrow_back.setOnClickListener(new OnClickListener() { @Override public void onClick(View v) { messagesRatedInRow = 0; startActivity(goToSplashPage); } }); q_button.setOnClickListener(new OnClickListener() { @Override public void onClick(View arg0) { new GeneralAlert(context, "Insert Info about Rate Page").showAlert(); } }); submit.setOnClickListener(new OnClickListener() { @Override public void onClick(View v) { dialog_title.setText("Submit Rating?"); confirm_dialog.show(); } }); skip.setOnClickListener(new OnClickListener() { @Override public void onClick(View v) { dialog_title.setText("Skip Message?"); confirm_dialog.show(); } }); confirm_button.setOnClickListener(new OnClickListener() { @Override public void onClick(View v) { submitRating(); generateMessage(); TrackStats.incrementRatedMessages(ParseUser.getCurrentUser()); confirm_dialog.dismiss(); stars.setRating((float) 3.0); messagesRatedInRow++; TrackStats.checkStamina(ParseUser.getCurrentUser(), messagesRatedInRow); } }); deny_button.setOnClickListener(new OnClickListener() { @Override public void onClick(View v) { generateMessage(); confirm_dialog.dismiss(); } }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public String approveMsg(Long id){\n return messagesParser.approve(id);\n }", "@Override\n\tpublic boolean approveIt() {\n\t\treturn false;\n\t}", "public String approveMarriageNotice() {\n if (logger.isDebugEnabled()) {\n logger.debug(\"approving marriage notice idUKey : \" + idUKey + \" and notice type : \" + noticeType +\n \" and with ignore warnings : \" + ignoreWarnings);\n }\n //todo remove\n //follow use to display serial number in action message ans action errors\n marriage = marriageRegistrationService.getByIdUKey(idUKey, user);\n String[] actionMassageArray = new String[]{(noticeType == MarriageNotice.Type.FEMALE_NOTICE) ?\n Long.toString(marriage.getSerialOfFemaleNotice()) : Long.toString(marriage.getSerialOfMaleNotice())};\n try {\n warnings = marriageRegistrationService.\n approveMarriageNotice(idUKey, noticeType, ignoreWarnings, user);\n if (warnings.size() > 0) {\n //if warning size is more than 0 we forward in to approval warning page\n warningsAtApproval = true;\n return \"warning\";\n }\n addActionMessage(getText(\"message.approve.success\", actionMassageArray));\n logger.debug(\"successfully approved marriage notice idUKey : {} and notice type :{ }\", idUKey, noticeType);\n } catch (CRSRuntimeException e) {\n //error happens when approving marriage notice\n switch (e.getErrorCode()) {\n case ErrorCodes.OTHER_PARTY_MUST_APPROVE_FIRST:\n addActionError(getText(\"error.other.party.approve.first\",\n new String[]{(noticeType == MarriageNotice.Type.FEMALE_NOTICE) ?\n (marriage.getSerialOfMaleNotice() != null) ?\n Long.toString(marriage.getSerialOfMaleNotice()) : getText(\"message.not.yet.add\") :\n (marriage.getSerialOfFemaleNotice() != null) ?\n Long.toString(marriage.getSerialOfFemaleNotice()) : getText(\"message.not.yet.add\")}));\n break;\n case ErrorCodes.UNABLE_APPROVE_MARRIAGE_NOTICE_PROHIBITED_RELATIONSHIP:\n addActionError(getText(\"error.approval.failed\", actionMassageArray) + \" , \" + e.getMessage());\n break;\n case ErrorCodes.BRIDES_FATHER_IN_PRS_IS_MISMATCHED_WITH_GIVEN_FATHER:\n addActionError(getText(\"error.given.brides.father.details.are.mismatched.with.prs\"));\n break;\n case ErrorCodes.GROOMS_FATHER_IN_PRS_IS_MISMATCHED_WITH_GIVEN_FATHER:\n addActionError(getText(\"error.given.grooms.father.details.are.mismatched.with.prs\"));\n break;\n case ErrorCodes.MORE_THAN_ONE_ACTIVE_LICENSE:\n addActionError(getText(\"error.unable.to.approve.already.issued.license\"));\n break;\n default:\n addActionError(getText(\"error.approval.failed\", actionMassageArray));\n }\n commonUtil.populateDynamicLists(districtList, dsDivisionList, mrDivisionList, districtId,\n dsDivisionId, mrDivisionId, AppConstants.MARRIAGE, user, language);\n getApprovalPendingNotices();\n return \"failed\";\n } catch (Exception e) {\n logger.debug(\"exception while approving marriage notice :idUKey \");\n return ERROR;\n }\n commonUtil.populateDynamicLists(districtList, dsDivisionList, mrDivisionList, districtId, dsDivisionId,\n mrDivisionId, AppConstants.MARRIAGE, user, language);\n getApprovalPendingNotices();\n return SUCCESS;\n }", "public void approveApplication(MortgageApplication application, Applicant applicant, String message) throws SQLException, MessagingException {\r\n\t\tapplicationDao.updateMortgageApplicationStatus(\"C\", application.getApplicationId());\r\n\t\tsendApplicationApprovedMail(application, applicant, message);\r\n\t}", "public void approveApplication(PersonalLoanApplication application, Applicant applicant, String message) throws SQLException, MessagingException {\r\n\t\tapplicationDao.updateLoanApplicationStatus(\"C\", application.getApplicationId());\r\n\t\tsendApplicationApprovedMail(application, applicant, message);\r\n\t}", "private PlainApprove(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {\n super(builder);\n }", "boolean hasPlainApprove();", "@Override\n\tpublic boolean isApproved();", "@Override\n\tpublic void confirmAndSendMessage(String messageId) {\n\t\t\n\t}", "public boolean hasPlainApprove() {\n return dataCase_ == 4;\n }", "public boolean hasPlainApprove() {\n return dataCase_ == 4;\n }", "public void autoApprove(int reimburseID, String autoReason, int status);", "@Override\n\t\t\tpublic void action() {\n\t\t\t\tACLMessage message =receive(messageTemplate);\n\t\t\t\tif(message!=null) {\n\t\t\t\t\tSystem.out.println(\"Sender => \" + message.getSender().getName());\n\t\t\t\t\tSystem.out.println(\"Content => \" + message.getContent());\n\t\t\t\t\tSystem.out.println(\"SpeechAct => \" + ACLMessage.getPerformative(message.getPerformative()));\n\t\t\t\t\t//reply with a message\n//\t\t\t\t\tACLMessage reply = new ACLMessage(ACLMessage.CONFIRM);\n//\t\t\t\t\treply.addReceiver(message.getSender());\n//\t\t\t\t\treply.setContent(\"Price = 1000\");\n//\t\t\t\t\tsend(reply);\n\t\t\t\t\t\n\t\t\t\t\tconsumerContainer.logMessage(message);\n\t\t\t\t\t\n\t\t\t\t}else {\n\t\t\t\t\tSystem.out.println(\"block() ...............\");\n\t\t\t\t\tblock();\n\t\t\t\t}\n\t\t\t}", "protected boolean processAnnouncement(String username, String message){return false;}", "@FXML\n\tvoid approveActionButton(ActionEvent event) {\n\t\t// change the duration\n\t\tboolean res = false;\n\t\tMessage messageToServer = new Message();\n\t\tmessageToServer.setMsg(req.getEcode() + \" \" + req.getNewDur());\n\t\tmessageToServer.setOperation(\"updateExamDurationTime\");\n\t\tmessageToServer.setControllerName(\"ExamController\");\n\t\tres = (boolean) ClientUI.client.handleMessageFromClientUI(messageToServer);\n\t\tif (!res) {\n\t\t\tUsefulMethods.instance().display(\"error in approval duration!\");\n\t\t} else\n\t\t\tdeleteRequest();\n\t\tUsefulMethods.instance().close(event);\n\t}", "public String getApproxsimMessage() {\n return message;\n }", "@Override\n\t\t\tpublic void action() {\n\t\t\t\tMessageTemplate cfpTemplate = MessageTemplate.MatchPerformative(ACLMessage.CFP);\n\t\t\t\tMessageTemplate informTemplate = MessageTemplate.MatchPerformative(ACLMessage.INFORM);\n\t\t\t\tMessageTemplate messageTemplate = MessageTemplate.or(cfpTemplate, informTemplate);\n\t\t\t\tACLMessage receivedMessage = myAgent.receive(messageTemplate);\n\t\t\t\t\n\t\t\t\tif (receivedMessage != null) {\n\t\t\t\t\thasReceivedMessage = true;\n\t\t\t\t\t\n\t\t\t\t\tif (receivedMessage.getPerformative() == ACLMessage.CFP) {\n\t\t\t\t\t\tdouble price = Double.parseDouble(receivedMessage.getContent());\n\t\t\t\t\t\tSystem.out.println(\"Buyer [\" + getAID().getLocalName() + \"] received \"\n\t\t\t\t\t\t\t\t+ \"CFP with price \" + Double.toString(price));\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Value in range; send proposal\n\t\t\t\t\t\tif (price <= priceToBuy) {\n\t\t\t\t\t\t\tACLMessage proposal = new ACLMessage(ACLMessage.PROPOSE);\n\t\t\t\t\t\t\tproposal.addReceiver(receivedMessage.getSender());\n\t\t\t\t\t\t\tproposal.setProtocol(receivedMessage.getProtocol());\n\t\t\t\t\t\t\tmyAgent.send(proposal);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\ttransitionStatus = sendProposal;\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t// Price too high; refuse and wait for new CFP\n\t\t\t\t\t\t\tACLMessage refusal = new ACLMessage(ACLMessage.REFUSE);\n\t\t\t\t\t\t\trefusal.addReceiver(receivedMessage.getSender());\n\t\t\t\t\t\t\trefusal.setProtocol(receivedMessage.getProtocol());\n\t\t\t\t\t\t\tmyAgent.send(refusal);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\ttransitionStatus = highPrice;\n\t\t\t\t\t\t}\n\t\t\t\t\t} else if (receivedMessage.getPerformative() == ACLMessage.INFORM) {\n\t\t\t\t\t\ttransitionStatus = noBuyers;\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tblock();\n\t\t\t\t}\n\t\t\t}", "public boolean isApproved();", "public boolean isApproved();", "@Override\n\t\tpublic void action() {\n\t\t\tMessageTemplate mt = MessageTemplate.MatchPerformative(ACLMessage.REQUEST); \n\t\t\tACLMessage msg = receive(mt);\n\t\t\tif(msg != null){\n\t\t\t\t\n\t\t\t\ttry {\n\t\t\t\t\tContentElement ce = null;\n\t\t\t\t\tSystem.out.println(msg.getContent()); //print out the message content in SL\n\n\t\t\t\t\t// Let JADE convert from String to Java objects\n\t\t\t\t\t// Output will be a ContentElement\n\t\t\t\t\tce = getContentManager().extractContent(msg);\n\t\t\t\t\tSystem.out.println(ce);\n\t\t\t\t\tif(ce instanceof Action) {\n\t\t\t\t\t\tConcept action = ((Action)ce).getAction();\n\t\t\t\t\t\tif (action instanceof SupplierOrder) {\n\t\t\t\t\t\t\tSupplierOrder order = (SupplierOrder)action;\n\t\t\t\t\t\t\t//CustomerOrder cust = order.getItem();\n\t\t\t\t\t\t\t//OrderQuantity = order.getQuantity();\n\t\t\t\t\t\t\tif(!order.isFinishOrder()) {\n\t\t\t\t\t\t\tSystem.out.println(\"exp test: \" + order.getQuantity());\n\t\t\t\t\t\t\trecievedOrders.add(order);}\n\t\t\t\t\t\t\telse {orderReciever = true;}\n\t\t\t\t\t\t\t//Item it = order.getItem();\n\t\t\t\t\t\t\t// Extract the CD name and print it to demonstrate use of the ontology\n\t\t\t\t\t\t\t//if(it instanceof CD){\n\t\t\t\t\t\t\t\t//CD cd = (CD)it;\n\t\t\t\t\t\t\t\t//check if seller has it in stock\n\t\t\t\t\t\t\t\t//if(itemsForSale.containsKey(cd.getSerialNumber())) {\n\t\t\t\t\t\t\t\t\t//System.out.println(\"Selling CD \" + cd.getName());\n\t\t\t\t\t\t\t\t//}\n\t\t\t\t\t\t\t\t//else {\n\t\t\t\t\t\t\t\t\t//System.out.println(\"You tried to order something out of stock!!!! Check first!\");\n\t\t\t\t\t\t\t\t//}\n\n\t\t\t\t\t\t\t//}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\n\t\t\t\t\t}\n\t\t\t\t\t//deal with bool set here\n\t\t\t\t\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tcatch (CodecException ce) {\n\t\t\t\t\tce.printStackTrace();\n\t\t\t\t}\n\t\t\t\tcatch (OntologyException oe) {\n\t\t\t\t\toe.printStackTrace();\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t\telse{\n\t\t\t\tblock();\n\t\t\t}\n\t\t}", "@Override\r\n\tpublic void action() {\n\t\tMessageTemplate mt=MessageTemplate.or(MessageTemplate.MatchContent(\"comida\"), MessageTemplate.MatchContent(\"bebida\"));\r\n ACLMessage msg = myAgent.receive(mt);\r\n if(msg!=null){\r\n \tif(msg.getContent().compareTo(\"comida\")==0){\r\n \t\tif(Comida>=5){\r\n \t\t\tACLMessage reply = msg.createReply();\r\n reply.setContent(\"Si\");\r\n System.out.println(myAgent.getLocalName()+\":Si, gracias tengo hambre todavia\"); \r\n myAgent.send(reply);\r\n Comida=Comida-5;\r\n \t\t}\r\n \t\telse{\r\n \t\t\tACLMessage reply = msg.createReply();\r\n reply.setContent(\"No\");\r\n System.out.println(myAgent.getLocalName()+\":No gracias\"); \r\n myAgent.send(reply);\r\n \t\t} \r\n \t}\r\n \telse if(msg.getContent().compareTo(\"bebida\")==0){\r\n \t\tif(Bebida>=5){\r\n \t\t\tACLMessage reply = msg.createReply();\r\n reply.setContent(\"Si\");\r\n System.out.println(myAgent.getLocalName()+\":Si, gracias tengo sed todavia\"); \r\n myAgent.send(reply);\r\n Bebida=Bebida-5;\r\n \t\t}\r\n \t\telse{\r\n \t\t\tACLMessage reply = msg.createReply();\r\n reply.setContent(\"No\");\r\n System.out.println(myAgent.getLocalName()+\":No gracias\"); \r\n myAgent.send(reply);\r\n \t\t} \r\n \t}\r\n }\r\n if (Comida==0 && Bebida==0){\r\n \tmyAgent.doDelete();\r\n }\r\n\t}", "@Override\n\tpublic void approveAcceptedOffer(String matriculation) {\n\t\tofferman.approveAcceptedOffer(matriculation);\n\t\t\n\t}", "public String approve() throws Exception\r\n {\r\n try\r\n {\r\n PoInvGrnDnMatchingHolder holder = poInvGrnDnMatchingService.selectByKey(param.getMatchingOid());\r\n \r\n if (\"yes\".equals(this.getSession().get(SESSION_SUPPLIER_DISPUTE)))\r\n {\r\n if (PoInvGrnDnMatchingStatus.PENDING.equals(holder.getMatchingStatus()))\r\n {\r\n this.result = \"pending\";\r\n return SUCCESS;\r\n }\r\n if (PoInvGrnDnMatchingStatus.MATCHED.equals(holder.getMatchingStatus()))\r\n {\r\n this.result = \"matched\";\r\n return SUCCESS;\r\n }\r\n if (PoInvGrnDnMatchingStatus.INSUFFICIENT_INV.equals(holder.getMatchingStatus()))\r\n {\r\n this.result = \"insufficientInv\";\r\n return SUCCESS;\r\n }\r\n if (PoInvGrnDnMatchingStatus.OUTDATED.equals(holder.getMatchingStatus()))\r\n {\r\n this.result = \"outdated\";\r\n return SUCCESS;\r\n }\r\n if (PoInvGrnDnMatchingInvStatus.APPROVED.equals(holder.getInvStatus()) || PoInvGrnDnMatchingInvStatus.SYS_APPROVED.equals(holder.getInvStatus()))\r\n {\r\n this.result = \"approved\";\r\n return SUCCESS;\r\n }\r\n if (!holder.getRevised())\r\n {\r\n if (PoInvGrnDnMatchingSupplierStatus.PENDING.equals(holder.getSupplierStatus()))\r\n {\r\n this.result = \"supplierpending\";\r\n return SUCCESS;\r\n }\r\n if (PoInvGrnDnMatchingBuyerStatus.PENDING.equals(holder.getBuyerStatus()) && PoInvGrnDnMatchingSupplierStatus.ACCEPTED.equals(holder.getSupplierStatus()))\r\n {\r\n this.result = \"supplieraccept\";\r\n return SUCCESS;\r\n }\r\n if (PoInvGrnDnMatchingBuyerStatus.PENDING.equals(holder.getBuyerStatus()) && PoInvGrnDnMatchingSupplierStatus.REJECTED.equals(holder.getSupplierStatus()))\r\n {\r\n this.result = \"buyerpending\";\r\n return SUCCESS;\r\n }\r\n if (PoInvGrnDnMatchingBuyerStatus.REJECTED.equals(holder.getBuyerStatus()))\r\n {\r\n this.result = \"rejected\";\r\n return SUCCESS;\r\n }\r\n }\r\n }\r\n if (null == param.getInvStatusActionRemarks() || param.getInvStatusActionRemarks().length() == 0 || param.getInvStatusActionRemarks().length() > 255)\r\n {\r\n this.result = \"remarks\";\r\n return SUCCESS;\r\n }\r\n this.checkInvFileExist(holder);\r\n poInvGrnDnMatchingService.changeInvDateToFirstGrnDate(holder);\r\n PoInvGrnDnMatchingHolder newHolder = new PoInvGrnDnMatchingHolder();\r\n BeanUtils.copyProperties(holder, newHolder);\r\n newHolder.setInvStatus(PoInvGrnDnMatchingInvStatus.APPROVED);\r\n newHolder.setInvStatusActionDate(new Date());\r\n newHolder.setInvStatusActionRemarks(param.getInvStatusActionRemarks());\r\n newHolder.setInvStatusActionBy(getProfileOfCurrentUser().getLoginId());\r\n poInvGrnDnMatchingService.auditUpdateByPrimaryKeySelective(this.getCommonParameter(), holder, newHolder);\r\n poInvGrnDnMatchingService.moveFile(holder);\r\n this.result = \"1\";\r\n }\r\n catch (Exception e)\r\n {\r\n ErrorHelper.getInstance().logError(log, this, e);\r\n this.result = \"0\";\r\n }\r\n return SUCCESS;\r\n }", "public LoanApplicationResponse approveLoanRequest() {\n return new LoanApplicationResponse(this, true);\n }", "public void action() {\n for (int i = 0; i < myAgent.friends.size(); ++i) {\n SendRequestToFriend(myAgent.friends.get(i));\n }\n\n // Crée un filtre pour lire d'abord les messages des amis et des leaders des amis\n MessageTemplate temp = MessageTemplate.MatchReceiver(myfriends);\n MessageTemplate temp2 = MessageTemplate.MatchReceiver(friendsLeader);\n MessageTemplate tempFinal = MessageTemplate.or(temp, temp2);\n\n // Réception des messages\n ACLMessage messageFriendly = myAgent.receive(tempFinal);\n // si on n'est pas dans un groupe\n if (messageFriendly != null && !inGroup) {\n \t// s'il reçoit une proposition d'un amis/ leader d'un ami, il accepte, peu importe le poste et s econsidère dans le groupe\n if (messageFriendly.getPerformative() == ACLMessage.PROPOSE) {\n AcceptProposal(messageFriendly, Group.Role.valueOf(messageFriendly.getContent()));\n inGroup = true;\n }\n // s'il reçoit un CONFIRM, il enregistre le leader\n else if (messageFriendly.getPerformative() == ACLMessage.CONFIRM) {\n myLeader = messageFriendly.getSender();\n }\n // s'il reçoit un INFORM, il enregistre l'AID du leader de son ami afin de recevoir ses messages et lui demande son poste préféré\n else if (messageFriendly.getPerformative() == ACLMessage.INFORM) {\n AddFriendsLeaderToList(messageFriendly);\n AnswerByAskingPreferedJob(messageFriendly);\n }\n // sinon, il renvoie une erreur\n else {\n System.out.println( \"Friendly received unexpected message: \" + messageFriendly );\n }\n }\n // si on est dans un groupe\n else if (messageFriendly != null && inGroup) { \n \t// s'il reçoit une requete et qu'il est déjà dans un groupe, il renvoir l'AID de son leader à son ami\n if (messageFriendly.getPerformative() == ACLMessage.REQUEST) {\n SendLeaderAID(messageFriendly);\n }\n // s'il reçoit un DISCONFIRM, il se remet en quete de job\n else if (messageFriendly.getPerformative() == ACLMessage.DISCONFIRM) {\n inGroup = false;\n AnswerByAskingPreferedJob(messageFriendly);\n }\n else {\n \t// sinon, il refuse tout offre\n RefuseOffer(messageFriendly);\n }\n }\n else {\n \t// on check ensuite les messages des inconnus, une fois ceux des amis triés\n ACLMessage messageFromInconnu = myAgent.receive();\n \n // si on n'est pas dans un groupe\n if (messageFromInconnu != null && !inGroup) {\n \n boolean offerPreferedJob = messageFromInconnu.getPerformative() == ACLMessage.PROPOSE && messageFromInconnu.getContent().equals((\"\\\"\" + myAgent.preferedRole.toString() + \"\\\"\"));\n boolean offerNotPreferedJob = messageFromInconnu.getPerformative() == ACLMessage.PROPOSE && messageFromInconnu.getContent() != (\"\\\"\" + myAgent.preferedRole.toString() + \"\\\"\" );\n \n //on accepte l offre s'il s'agit de notre role préféré\n if (offerPreferedJob){\n AcceptProposal(messageFromInconnu, myAgent.preferedRole);\n }\n // on refuse s'il ne s'agit pas de notre offre favorite en redemandant notre job préféré\n else if (offerNotPreferedJob){\n RefuseOffer(messageFromInconnu);\n }\n // si on reçoit une confimation, on se considère dans un groupe et on enregistre notre leader\n else if (messageFromInconnu.getPerformative() == ACLMessage.CONFIRM){\n inGroup = true;\n myLeader = messageFromInconnu.getSender();\n }\n // sinon, il s'agit d'une erreure\n else {\n System.out.println( \"Friendly received unexpected message: \" + messageFromInconnu );\n }\n }\n // si on est dans un groupe\n else if (messageFromInconnu != null && inGroup) {\n \t// si on reçoit une requete, on renvoie à notre leader\n if (messageFromInconnu.getPerformative() == ACLMessage.REQUEST) {\n SendLeaderAID(messageFromInconnu);\n }\n // si on reçoit un DISCONFIRM, on repart en quete de job\n else if (messageFromInconnu.getPerformative() == ACLMessage.DISCONFIRM) {\n inGroup = false;\n AnswerByAskingPreferedJob(messageFromInconnu);\n }\n // sinon on refuse\n else {\n RefuseOffer(messageFromInconnu);\n }\n }\n // si le message est vide, on bloque le flux\n else {\n block();\n }\n }\n }", "static void confirm_A(Messenger messenger, Response_e response)\n {\n sendToClient(messenger, Request_e.Request_A_en.valueOf(), response, null);\n }", "public void setApproveStatus(Byte approveStatus) {\n this.approveStatus = approveStatus;\n }", "org.hyperledger.fabric.protos.token.Transaction.PlainApprove getPlainApprove();", "public String checkMessage() {\n\t\tString userLatestStep = questionBot.get(owner.id());\n\n\t\t//se a amensagem comeca com '/', trata-se de um item de menu sendo acionado\n\t\tif(answerUser != null && answerUser.startsWith(\"/\"))\n\t\t\tuserLatestStep = answerUser;\n\n\t\t//busca no mapa de respostas as opcoes para o usuario\n\t\tObject options = response.get(userLatestStep);\n\n\t\t//obtem a mensagem a ser devolvida para o usuario\n\t\tString result = parseResult(options, answerUser);\n\n\t\t//mantem a ultima resposta do usuario\n\t\tuserLatestAnswer.put(owner.id(), answerUser);\n\n\t\treturn result;\n\t}", "@Override\n\tpublic boolean approvePartner(Partner partner) {\n\t\treturn false;\n\t}", "HrDocumentRequest approve(HrDocumentRequest hrDocumentRequest);", "private void prepareReply(ACLMessage msg) {\n\t\treply = msg.createReply();\n\t\treply.setPerformative(ACLMessage.REQUEST);\n\t\treply.setSender(getAID());\n\t}", "public String approveRegistration() {\n\t\treturn \"Company approved\";\r\n\t}", "@ApiModelProperty(value = \"The approve action text. Defaults to 'Approve'.\")\n public String getApproveText() {\n return approveText;\n }", "protected ACLMessage handleAcceptProposal(ACLMessage cfp, ACLMessage propose,ACLMessage accept) throws FailureException \r\n\t{\r\n\t\tACLMessage inform = accept.createReply();\r\n\t\tinform.setPerformative(ACLMessage.INFORM);\r\n\t\t//TODO: devrementer le nb de trajets disponibles suite a la vente\r\n\t\treturn inform;\r\n\t}", "@Override\n\tpublic boolean isApproved() {\n\t\treturn model.isApproved();\n\t}", "@SystemAPI\n\tboolean needsApproval();", "public Byte getApproveStatus() {\n return approveStatus;\n }", "@Override\n\tpublic Boolean approveRejectLista(int statoApprovazione, String nomeLista) {\n\t\t\n\t\tLista listaElettorale = listaElettoraleDaNome(nomeLista);\n\t\t\n\t\tlistaElettorale.setStatoApprovazione(statoApprovazione);\n\t\t\n\t\t//modifica la lista elettorale dato lo stato di approvazione\n\t\tmodificaListaElettorale(listaElettorale);\n\n\t\treturn true;\n\t}", "org.hyperledger.fabric.protos.token.Transaction.PlainApproveOrBuilder getPlainApproveOrBuilder();", "@Override\n\tpublic void approveForm(Context ctx) {\n\t\t//Authentication\n\t\tUser approver = ctx.sessionAttribute(\"loggedUser\");\n\t\tif (approver == null) {\n\t\t\tctx.status(401);\n\t\t\treturn;\n\t\t}\n\t\tString username = ctx.pathParam(\"username\");\n\t\tif (!approver.getUsername().equals(username)) {\n\t\t\tctx.status(403);\n\t\t\treturn;\n\t\t}\n\t\t// Implementation\n\t\tString id = ctx.pathParam(\"id\");\n\t\tForm form = fs.getForm(UUID.fromString(id));\n\t\tapprover.getAwaitingApproval().remove(form);\n\t\tus.updateUser(approver);\n\t\t// If approver is just the direct supervisor\n\t\tif (!approver.getType().equals(UserType.DEPARTMENT_HEAD) && !approver.getType().equals(UserType.BENCO)) {\n\t\t\tform.setSupervisorApproval(true);\n\t\t\tUser departmentHead = us.getUserByName(approver.getDepartmentHead());\n\t\t\tdepartmentHead.getAwaitingApproval().add(form);\n\t\t\tus.updateUser(departmentHead);\n\t\t}\n\t\t// If the approver is a department head but not a benco\n\t\tif (approver.getType().equals(UserType.DEPARTMENT_HEAD) && !approver.getType().equals(UserType.BENCO)) {\n\t\t\tform.setDepartmentApproval(true);\n\t\t\tUser benco = us.getUser(\"sol\");\n\t\t\tbenco.getAwaitingApproval().add(form);\n\t\t\tus.updateUser(benco);\n\t\t}\n\t\t// if the approver is a BenCo\n\t\tif (approver.getType().equals(UserType.BENCO)) {\n\t\t\tform.setBencoApproval(true);\n\t\t\tUser formSubmitter = us.getUserByName(form.getName());\n\t\t\tif (formSubmitter.getAvailableReimbursement() >= form.getCompensation()) {\n\t\t\t\tformSubmitter.setAvailableReimbursement(formSubmitter.getAvailableReimbursement() - form.getCompensation());\n\t\t\t}\n\t\t\telse {\n\t\t\t\tformSubmitter.setAvailableReimbursement(0.00);\n\t\t\t}\n\t\t\tformSubmitter.getAwaitingApproval().remove(form);\n\t\t\tformSubmitter.getCompletedForms().add(form);\n\t\t\tus.updateUser(formSubmitter);\n\t\t}\n\t\t\n\t\tfs.updateForm(form);\n\t\tctx.json(form);\n\t}", "@Override\r\n\t\tpublic void action() {\n MessageTemplate mt = MessageTemplate.MatchPerformative(ACLMessage.ACCEPT_PROPOSAL);\r\n MessageTemplate mt2 = MessageTemplate.MatchPerformative(ACLMessage.PROPOSE);\r\n ACLMessage msg = myAgent.receive(mt);\r\n //If it is a ACCEPT_PROPOSAL, the seller sell the book to the buyer (execpt if the book if not here anymore)\r\n if (msg != null) {\r\n // ACCEPT_PROPOSAL Message received. Process it\r\n title = msg.getContent();\r\n ACLMessage reply = msg.createReply();\r\n\r\n Integer price = (Integer) catalogue.remove(title);\r\n if (price != null) {\r\n reply.setPerformative(ACLMessage.INFORM);\r\n reply.setContent(String.valueOf(price));\r\n System.out.println(title+\" sold to agent \"+msg.getSender().getName());\r\n }\r\n else {\r\n // The requested book has been sold to another buyer in the meanwhile .\r\n reply.setPerformative(ACLMessage.FAILURE);\r\n reply.setContent(\"not-available\");\r\n }\r\n myAgent.send(reply);\r\n }\r\n //If it is a new PROPOSE, the buyer is trying to negociate.\r\n else {\r\n ACLMessage msg2 = myAgent.receive(mt2);\r\n if(msg2 != null){\r\n ACLMessage reply = msg2.createReply();\r\n //If the price of the buyer is OK for the seller according to his tolerance, the transaction is made\r\n if(((Integer) catalogue.get(title) - Integer.parseInt(msg2.getContent())) <= tolerance){\r\n System.out.println(myAgent.getLocalName() + \" say : OK, let's make a deal\");\r\n updateCatalogue(title, Integer.parseInt(msg2.getContent()));\r\n reply.setPerformative(ACLMessage.INFORM);\r\n reply.setContent(msg2.getContent());\r\n }\r\n //Else, the seller accept to negociate, he up his tolerance and ask the buyer to up his real price\r\n else{\r\n //Send a REQUEST Message to negociate with the buyer\r\n reply.setPerformative(ACLMessage.REQUEST);\r\n //Up the tolerance by *change*\r\n tolerance += change;\r\n reply.setContent(String.valueOf(change));\r\n System.out.println(myAgent.getLocalName() + \" say : Let's up your real price while I up my tolerance (\" + ((Integer) catalogue.get(title) - Integer.parseInt(msg2.getContent())) + \" < \" + tolerance + \")\");\r\n }\r\n myAgent.send(reply);\r\n }\r\n else{\r\n block();\r\n }\r\n }\r\n\t\t}", "public boolean isApproved()\n\t{\n\t\tif(response.containsKey(\"Result\")) {\n\t\t\tif(response.get(\"Result\").equals(\"APPROVED\")) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}", "public String getApprove() {\r\n if (approve == null)\r\n approve = initApproveElement().findElement(By.cssSelector(\"[data-role*='approvalStatus']\")).getText();\r\n return approve;\r\n }", "String getConfirmationMessage();", "public int approve_reject_Request(int approval_status, String approvedBy, String approverComment, Timestamp time_approved,String social_Email)\r\n\t{\r\n\t\tConnection conn=getConnection();\r\n\r\n\t\tPreparedStatement pstmt = null;\r\n\t\tint result=0;\r\n\r\n\t\ttry\r\n\t\t{\r\n\t\t\tString query = \"update SOCIAL_EAI_APPROVAL set (APPROVAL_STATUS,APPROVED_BY,APPROVER_COMMENT,TIME_APPROVED)=(?,?,?,?) where REQ_SOCIAL_EMAIL=?\";\r\n\t\t\tpstmt = conn.prepareStatement(query); \r\n\t\t\tpstmt.setInt(1,approval_status); \r\n\t\t\tpstmt.setString(2,approvedBy); \r\n\t\t\tpstmt.setString(3,approverComment);\r\n\t\t\tpstmt.setTimestamp(4,time_approved);\r\n\t\t\tpstmt.setString(5,social_Email);\r\n\r\n\t\t\tresult=pstmt.executeUpdate(); \r\n\r\n\t\t}\r\n\t\tcatch (Exception e) {\r\n\r\n\t\t\tSystem.out.println(\"EXception:\");\r\n\t\t\te.printStackTrace();\r\n\t\t} \r\n\r\n\r\n\t\treturn result;\r\n\t}", "@Override\n\tpublic boolean isAutoApprove(String arg0) {\n\t\treturn false;\n\t}", "pb4server.GiveRansomAskReq getGiveRansomAskReq();", "public void approveQuestion(Question question) throws Exception {\n DataBaseBroker dbb = new DataBaseBroker();\n dbb.loadDriver();\n dbb.establishConnection();\n question.setApproved(true);\n dbb.overwriteQuestion(question);\n dbb.commit();\n dbb.closeConnection();\n }", "List<String> viewPendingApprovals();", "pb4server.SendNoticeToLeaderAskReq getSendNoticeToLeaderAskReq();", "@Override\n public void handelNotification(String message) {\n if (message.equalsIgnoreCase(\"Change is successful\")) {\n Intent intent = null;\n if (actionType == 0) {\n intent = new Intent(UpdateIssueActivity.this, IssueMenuActivity.class);\n intent.putExtra(\"Order\", Header);\n message = \"Issue Updated\";\n } else if (actionType == 1) {\n intent = new Intent(UpdateIssueActivity.this, ApproveIssueActivity.class);\n intent.putExtra(\"Order\", Header);\n message = \"Issue Sent to Approval\";\n startActivity(intent);\n } else if (actionType == 2) {\n intent = new Intent(UpdateIssueActivity.this, IssueMenuActivity.class);\n intent.putExtra(\"Order\", Header);\n message = \"Issue Cancelled\";\n startActivity(intent);\n }\n\n //change Toast to snack bar\n customToastext.setText(Html.fromHtml(message));\n customToastLayout.setBackgroundColor(getResources().getColor(R.color.successMessage));\n // Toast...\n showCustomToast();\n } else {\n Log.d(\"mytag\", \"handelNotification: Change Failed\");\n customToastext.setText(Html.fromHtml(\"Change Failed\"));\n customToastLayout.setBackgroundColor(getResources().getColor(R.color.errorMessage));\n showCustomToast();\n }\n }", "public boolean requiresPostApproval() {\n return true;\n }", "private void sendApplicationApprovedMail(Application application, Applicant applicant, String message) throws MessagingException {\r\n\t\tMailSender ms = new MailSender(\"smtp.gmail.com\", 465, \"[email protected]\", \"fairsailtest\");\r\n\t\t\r\n\t\tms.sendMessage(\"[email protected]\", \"Application was approved\", \"Your application \" + application.getApplicationId() + \" has been successfully approved \\n\\n\" + message, applicant.getEmailAddress());\r\n\t}", "private boolean isApproved() {\r\n if (rnd.nextInt(10) < 5) {\r\n return true;\r\n } else {\r\n return false;\r\n }\r\n\r\n }", "protected ACLMessage prepareResponse(ACLMessage msg) {\n ACLMessage reply = msg.createReply();\n try {\n Object contentRebut = (Object)msg.getContent();\n showMessage(\"RECIEVED \"+msg.getSender().getName() + \", \"+msg.getPerformative());\n if(contentRebut.equals(\"Movement request\")) {\n showMessage(\"Movement request received\");\n reply.setPerformative(ACLMessage.AGREE);\n }\n } catch (Exception e) {\n e.printStackTrace();\n }\n showMessage(\"Answer sent Movement requet recieved\"); //: \\n\"+reply.toString());\n return reply;\n }", "public appaporve(String id,String approve) {\n this.id = id;\n this.approve = approve;\n }", "protected boolean processPersonalTell(String username, String titles, String message){return false;}", "@Override\n public void action() {\n ACLMessage acl = receive();\n if (acl != null) {\n if (acl.getPerformative() == ACLMessage.REQUEST) {\n try {\n ContentElement elemento = myAgent.getContentManager().extractContent(acl);\n if (elemento instanceof PublicarServicio) {\n PublicarServicio publicar = (PublicarServicio) elemento;\n Servicio servicio = publicar.getServicio();\n jadeContainer.iniciarChat(servicio.getTipo(), servicio.getDescripcion());\n //myAgent.addBehaviour(new IniciarChatBehaviour(myAgent, servicio.getTipo(), servicio.getDescripcion()));\n } else if (elemento instanceof EnviarMensaje) {\n EnviarMensaje enviar = (EnviarMensaje) elemento;\n Mensaje mensaje = enviar.getMensaje();\n jadeContainer.enviarMensajeChatJXTA(mensaje.getRemitente(), mensaje.getMensaje());\n }\n } catch (CodecException ex) {\n System.out.println(\"CodecException: \" + ex.getMessage());\n } catch (UngroundedException ex) {\n System.out.println(\"UngroundedException: \" + ex.getMessage());\n } catch (OntologyException ex) {\n System.out.println(\"OntologyException: \" + ex.getMessage());\n }\n }\n } else {\n block();\n }\n }", "@Override\r\n public boolean canDisapprove(Document document) {\n return false;\r\n }", "private void constructACLMessage()\n {\n PlayIntroAction playIntroObject = new PlayIntroAction();\n playIntroObject.setLenght(numberOfMeasures);\n playIntroObject.setNow(true);\n playIntroObject.setDuration(-1);\n msg = new ACLMessage(ACLMessage.CFP);\n msg.setLanguage(codec.getName());\n msg.setOntology(ontology.getName());\n for(int i = 0; i < receivers.size(); i++)\n {\n try\n {\n //fill the content using the Ontology concept\n myAgent.getContentManager().fillContent(msg,new Action((AID)receivers.elementAt(i),playIntroObject));\n }catch (Exception ex) { ex.printStackTrace(); }\n //Set the receiver of the message\n msg.addReceiver((AID)receivers.elementAt(i));\n\n }\n\n //Set the protocol that we gonna use\n msg.setProtocol(FIPANames.InteractionProtocol.FIPA_CONTRACT_NET);\n //We indicate the deadline of the reply\n msg.setReplyByDate(new Date(System.currentTimeMillis() + 30000));\n\n\n }", "public void setAccepted() {\r\n\t\tstatus = \"Accepted\";\r\n\t}", "public TLUpdateShortSentMessage() {\n super();\n }", "private void updatePlanboardMessageStatus(PlanboardMessage planboardMessage, DocumentStatus status) {\n if (DocumentStatus.SENT == planboardMessage.getDocumentStatus()\n || DocumentStatus.PENDING_FLEX_TRADING == planboardMessage.getDocumentStatus()) {\n planboardMessage.setDocumentStatus(status);\n }\n }", "RequestSender onAgree(Consumer<Message> consumer);", "public boolean isApproved() {\n return approved;\n }", "boolean isDisplayMessageOnRedeem();", "@Override\n\tprotected final void sendMessage(Object content, Performative performative, AgentAddress to){\n\n\t\tACLMessage message = new ACLMessage(content, performative);\n\t\t\n\t\tmessage.setProtocol(EnumFipaProtocol.FIPA_REQUEST);\n\t\tmessage.setConversationId( getConversationId() );\n\t\t\n\t\tgetRefAclAgent().sendACLMessage(message, to);\n\t\t\n\t\t//System.out.println(\"\\n=> MESSAGE envoyé via REQUEST PROTOCOL : \\n\" + message.toString());\n\t}", "@Override\n\tpublic boolean response(Notification notification) {\n\t\tUser sender;\n\t\tif (!userManager.hasUser(notification.getSender())) {\n\t\t\tsender=utils.reinitializeUser(notification.getSender());\n\t\t\tif(sender==null)\n\t\t\t{\n\t\t\t\t//throw exception\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\tsender = userManager.getUser(notification.getSender());\n\t\tString receiverUserId = notification.getOwnerId();\n\t\t// Account account;\n\t\tAccount account = accountManager.getAccountByUserId(receiverUserId);\n\t\tif (account == null) {\n\t\t\ttry {\n\t\t\t\taccount = accountDao.getByUserId(receiverUserId);\n\t\t\t\tif (account == null)\n\t\t\t\t\treturn false;\n\t\t\t} catch (AccountNotFoundException e) {\n\t\t\t\tSystem.out.println(e.getMessage());\n\t\t\t\treturn false;\n\t\t\t}\n\n\t\t}\n\t\tsender.setAcceptanceStatus(account, notification.getAcceptanceStatus(),\n\t\t\t\tnotification.getSuggestionId());\n\t\tAccount receiverAccount = accountManager\n\t\t\t\t.getAccountByUserId(receiverUserId);\n\t\tif (receiverAccount == null) {\n\t\t\ttry {\n\t\t\t\treceiverAccount = accountDao.getByUserId(receiverUserId);\n\t\t\t\tif (receiverAccount == null)\n\t\t\t\t\treturn false;\n\t\t\t} catch (AccountNotFoundException e) {\n\t\t\t\tSystem.out.println(e.getMessage());\n\t\t\t\treturn false;\n\t\t\t}\n\n\t\t}\n\t\tUser receiver;// =userManager.getUser(receiverAccount);\n\t\tif (!userManager.hasUser(receiverAccount)) {\n\t\t\treceiver=utils.reinitializeUser(receiverAccount);\n\t\t\tif(receiver==null)\n\t\t\t{\n\t\t\t\t//throw exception\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\treceiver = userManager.getUser(receiverAccount);\n\t\treceiver.deleteNotification(notification);\n\t\t// check for all the other status values(logic)\n\t\t// the statement below modifies the acceptanceStatus by the specific\n\t\t// ownerID\n\t\tboolean success = false;\n\t\ttry {\n\t\t\tsuccess = suggestionDao.modifySuggestionReceiver(notification,\n\t\t\t\t\t\"acceptanceStatus\");\n\t\t\tif (!success) {\n\t\t\t\tsuccess = suggestionDao.modifySuggestionReceiver(notification,\n\t\t\t\t\t\t\"acceptanceStatus\");\n\t\t\t\tif (!success) {\n\t\t\t\t\t// an exception should be thrown for transaction management\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t}\n\t\t} catch (SuggestionNotFoundException e) {\n\t\t\tSystem.out.println(e.getMessage());\n\t\t\treturn false;\n\t\t}\n\t\treturn success;\n\t}", "public void setTermsApproved() {\n mTermsApproved = true;\n }", "@OnClick(R.id.mApprovalCommit)\n void onApprovalPress() {\n String userName = mPetitionConcertUserName.getText().toString();\n// if (!userName.equals(\"\")) {\n// userName = userName.substring(1, userName.length() - 1);\n// }\n// String content = mPetitionContent.getText().toString();\n// String petitioner = mPetitioner.getText().toString();\n// String timeRange = mPetitionTimeRange.getText().toString();\n String result = mApprovalResultMenuTab.getText().toString();\n String opinion = mApprovalOpinion.getText().toString();\n if (opinion.equals(\"\")) {\n Toast.makeText(this, \"请输入审批意见\", Toast.LENGTH_SHORT).show();\n } else {\n if (mDialog == null) mDialog = new ProgressDialog(this);\n mDialog.setMessage(\"正在提交,请稍后...\");\n mDialog.setCancelable(false);\n mDialog.show();\n switch (result) {\n case \"同意\":\n mPresent.approvalAgree(approval.getRequestid(), approval.getApproveNodeId(), approval.getApprovePerson(), opinion);\n break;\n case \"不同意\":\n mPresent.approvalRefused(approval.getRequestid(), approval.getApprovePerson(), opinion);\n break;\n default:\n Log.e(TAG, \"onApprovalPress: \" + approval.getRequestid() + \"::\" + approval.getApproveNodeId() + \"::\" + approval.getApprovePerson() + \"::\" + opinion);\n break;\n }\n }\n\n\n }", "@SkipValidation\n public String makeChangesToShowMessage() {\n important = impService.getImportantNews(important.getImportantNewsId());\n if (important.isShowMessage() == false) {\n important.setShowMessage(true);\n impService.updateImportantNews(important);\n }\n return SUCCESS;\n }", "@Override\n\tpublic boolean isApproved() {\n\t\treturn _scienceApp.isApproved();\n\t}", "public void setApproved(boolean approved) {\n this.approved = approved;\n }", "public org.hyperledger.fabric.protos.token.Transaction.PlainApproveOrBuilder getPlainApproveOrBuilder() {\n if ((dataCase_ == 4) && (plainApproveBuilder_ != null)) {\n return plainApproveBuilder_.getMessageOrBuilder();\n } else {\n if (dataCase_ == 4) {\n return (org.hyperledger.fabric.protos.token.Transaction.PlainApprove) data_;\n }\n return org.hyperledger.fabric.protos.token.Transaction.PlainApprove.getDefaultInstance();\n }\n }", "@Override\n public void action() {\n ACLMessage acl = blockingReceive();\n System.err.println(\"Hola, que gusto \" + acl.getSender() + \", yo soy \" + getAgent().getName());\n new EnviarMensaje().enviarMensajeString(ACLMessage.INFORM, \"Ag4\", getAgent(), \"Hola agente, soy \" + getAgent().getName(),\n \"COD0001\");\n }", "public void m() {\n String str;\n d a2 = d.a((Context) this);\n int c2 = a2.c();\n String d2 = a2.d();\n if (c2 > 0 && !TextUtils.isEmpty(d2)) {\n a2.a();\n this.f6131d.setVisibility(0);\n if (c2 > 1) {\n str = getString(R.string.recently_reject_message, new Object[]{d2, Integer.valueOf(c2)});\n } else {\n str = getString(R.string.recently_reject_message_one, new Object[]{d2});\n }\n this.e.setText(str);\n }\n }", "@Override\n\tpublic void sendReviewResponseE2A(Editor e, Author a, PitchMessage pm, PitchReview pr) {\n\t\tPReviewE2A prea = new PReviewE2A();\n\t\tprea.setPitchReview(pr);\n\t\tprea.setAuthor(a);\n\t\tprea.setEditor(e);\n\t\t\n\t\tPMessageE2A pmea = new PMessageE2A();\n\t\tpmea.setAuthor(a);\n\t\tpmea.setEditor(e);\n\t\tpmea.setPitchMessage(pm);\n\t\t\n\t\t//delete Draft Change notification the author sent\n\t\tPReviewA2E prae = messageDAO.getPReviewA2E(pr);\n\t\tmessageDAO.deleteFromPReviewA2E(prae);\n\t\t\n\t\t//create a notification for the author\n\t\tmessageDAO.addToPReviewE2A(prea);\n\t\t\n\t\t//send message\n\t\tmessageDAO.addPitchMessage(pm);\n\t\tmessageDAO.addToPMessageE2A(pmea);\n\t\t\n\t\t\n\t}", "public void processAppointmentRequest(int appointmentId)\n {\n AppointmentListSingleton appointments = AppointmentListSingleton.getInstance();\n appointments.approveRequest(appointmentId);\n }", "public void handleSend(ActionEvent actionEvent) {\r\n String to=textFieldTo.getText();\r\n try{\r\n Long idto = Long.parseLong(to);\r\n\r\n FriendshipRequest request = new FriendshipRequest();\r\n Tuple<Long,Long> f = new Tuple<>(user.getId(), idto);\r\n request.setId(f);\r\n\r\n service.addRequest(request);\r\n showMessage(Alert.AlertType.CONFIRMATION,\"Request sent!\",\"Request is now pending!\");\r\n\r\n textFieldTo.clear();\r\n\r\n\r\n }catch(NumberFormatException exception){\r\n showMessage(Alert.AlertType.ERROR,\"Error\",exception.toString());\r\n }catch (ServiceException exception){\r\n showMessage(Alert.AlertType.ERROR,\"Error\",exception.toString());\r\n }\r\n }", "@Override\n public void onOkButtonClicked() {\n\n\n String reasonMsg1 = backToOrderView.editText.getText().toString();\n reasonMsg = reasonMsg1.trim();\n\n if (reasonMsg.length() == 0) {\n Toast.makeText(getApplicationContext(), \"Please give reason...\", Toast.LENGTH_LONG).show();\n\n } else {\n\n\n // sendNotificationToUser(\"driver_cancel\");\n updateTripStatusApi(\"driver_cancel_at_pickup\", controller.pref.getTRIP_ID(), reasonMsg);\n\n\n }\n }", "public boolean ApproveReimbursement(int employeeID, int reimburseID, String reason, int status);", "protected void setProved() {\n\t\tproveState = PROVED;\n\t}", "@Override\n\tpublic String viewmessage_request() {\n\t\treturn null;\n\t}", "protected ACLMessage prepareResultNotification(ACLMessage msg, ACLMessage response) {\n ACLMessage reply = msg.createReply();\n reply.setPerformative(ACLMessage.INFORM);\n \n Object content = (Object)msg.getContent();\n \n // Prepare response for a ships movement request\n if(content.equals(\"Movement request\")){\n prepareMovementResultNotitication(reply);\n \n // Prepare response for a start negotiation requests\n }else if(content.equals(\"Negotiation request\")){\n \n }\n \n showMessage(\"Answer sent inform movement\"); //+reply.toString());\n return reply;\n\n }", "public static ApproveRequest buildApproveRequest(Integer chatRoomID, Integer userID, Boolean isApprove) {\n ApproveRequest.Data approveRequestData = ApproveRequest.Data.builder()\n .chatRoomID(chatRoomID)\n .userID(userID)\n .isApprove(isApprove)\n .build();\n return ApproveRequest.builder()\n .request(\"approve\")\n .data(approveRequestData)\n .build();\n }", "Notification createAppointmentRequestSubmissionConfirmationNotification(AppointmentRequest appointmentRequest, List<Appointment> appointments );", "public boolean isApproved() {\n\t\treturn isApproved;\n\t}", "public boolean approveAppointment() {\n\t\tIHealthCareDAO dao = new HealthCareDAO();\r\n\t\treturn dao.approveAppointment();\r\n\t}", "public String getAPPROVED_BY() {\r\n return APPROVED_BY;\r\n }", "public org.hyperledger.fabric.protos.token.Transaction.PlainApprove getPlainApprove() {\n if (plainApproveBuilder_ == null) {\n if (dataCase_ == 4) {\n return (org.hyperledger.fabric.protos.token.Transaction.PlainApprove) data_;\n }\n return org.hyperledger.fabric.protos.token.Transaction.PlainApprove.getDefaultInstance();\n } else {\n if (dataCase_ == 4) {\n return plainApproveBuilder_.getMessage();\n }\n return org.hyperledger.fabric.protos.token.Transaction.PlainApprove.getDefaultInstance();\n }\n }", "@Override\n\tpublic String createMsg_request() {\n\t\treturn null;\n\t}", "public void needconfirmstion(Pending_appoint_Owner pending_appoint_owner) {\n //TODO\n newOwners.put(pending_appoint_owner.grantee.getId(), pending_appoint_owner);\n user.add_msg(\"a new Owner is being appointed for store:\" + getStore().getName()\n + \"- required your confirmation - \" + pending_appoint_owner.grantee.getId());\n }", "@Override\n\tpublic void msgAtFrige() {\n\t\t\n\t}", "public void beforeSendingeGainChatRequest();", "@Override\n public void onClick(View v) {\n\n\n Toast.makeText(MainSOSActivity.this, \"Stay Safe and Confirm the Message! Your emergnecy conctacts will be notified!\", Toast.LENGTH_SHORT).show();\n\n }", "@Override\r\n\t\tpublic boolean promptYesNo(String message) {\n\t\t\treturn true;\r\n\t\t}", "public boolean approveAppointment() {\n\t\tSet <String> set=(HealthCareDAO.map).keySet();\r\n\t\tint count=1;\r\n\t\tfor(String s:set)\r\n\t\t{\r\n\t\t\tSystem.out.println(\"You have a center \"+map.get(s).getCenterName() +\"--\"+\"Center and id is \"+s);\r\n\t\t\tcount++;\r\n\t\t}\r\n\t\tSystem.out.println(\"Enter Center id :\");\r\n\t\tString str=scan.next();\r\n\t\tDiagnoisticCenter center=HealthCareDAO.map.get(str); //get Diagonistic object of given key \r\n\t\tList<Appointment> l=center.getAppointmentList();\r\n\t\t//System.out.println(l);\r\n\t\tint y=1;\r\n\t\tfor(Appointment a:l)\r\n\t\t{\r\n\t\t\tSystem.out.println(\"Enter Approval or disapproval\");\r\n\t\tboolean decision=scan.nextBoolean()\t;\r\n\t\t\ta.setApproved(decision);\r\n\t\t\tif(a.isApproved()==true)\r\n\t\t\t{\tSystem.out.println(\"Appointment id number \"+a.getAppointmentid()+\"---is Approved\");}\r\n\t\t\telse {System.out.println(\"Appointment id number \"+a.getAppointmentid()+\"---is not Approved\");}\r\n\t\t\ty++;\r\n\t\t\tif(y>3)\r\n\t\t\t\tbreak;\r\n\t\t\t\r\n\t\t}\r\n\t\tcenter.setAppointmentList(l);\r\n\t\tSystem.out.println(\"Appointment List count :\"+l.size());\r\n\t\t\r\n\t\treturn false;\r\n\t}", "private void approveItem(final int position){\n }", "private void alertDialogeForAskingPermissions() {\n builder.setMessage(getResources().getString(R.string.app_name) + \" needs access to \" + permissions[0] + \", \" + permissions[1]).setTitle(R.string.permissions_required);\n\n //Setting message manually and performing action on button click\n //builder.setMessage(\"Do you want to close this application ?\")\n builder.setCancelable(false)\n .setPositiveButton(R.string.later, new DialogInterface.OnClickListener() {\n public void onClick(DialogInterface dialog, int id) {\n\n // Action for 'Later'\n //Saving later boolean value as true, also saving time of pressed later\n Date dateObj = new Date();\n long timeNow = dateObj.getTime();\n editor.putLong(getResources().getString(R.string.later_pressed_time), timeNow);\n editor.putBoolean(getResources().getString(R.string.later), true);\n editor.commit();\n dialog.cancel();\n }\n })\n .setNegativeButton(R.string.give_permissions, new DialogInterface.OnClickListener() {\n public void onClick(DialogInterface dialog, int id) {\n requestPermission();\n }\n });\n //Creating dialog box\n AlertDialog alert = builder.create();\n alert.show();\n }", "@Override\n\tpublic void getMessage(TranObject msg) {\n\n\t}" ]
[ "0.71801764", "0.6408428", "0.6246567", "0.61855716", "0.61162627", "0.5992898", "0.5967407", "0.595515", "0.59513813", "0.5920113", "0.5895455", "0.5849021", "0.58475643", "0.57785046", "0.57400817", "0.57388026", "0.57345325", "0.57315105", "0.57315105", "0.5706015", "0.56674343", "0.56519735", "0.5630667", "0.56031597", "0.55982316", "0.5590165", "0.5583055", "0.5571236", "0.5567715", "0.5562804", "0.5549814", "0.55442715", "0.55352527", "0.5518657", "0.55121285", "0.55075496", "0.5503074", "0.5500444", "0.549139", "0.5490553", "0.54767513", "0.5467087", "0.5465202", "0.54523605", "0.54466075", "0.5438924", "0.543888", "0.54092336", "0.5397118", "0.5389464", "0.5386321", "0.53682375", "0.5368163", "0.5365433", "0.53539115", "0.5351851", "0.53480947", "0.5331037", "0.53289056", "0.5328326", "0.53231555", "0.5322324", "0.53150564", "0.5308347", "0.53002906", "0.5290389", "0.5290378", "0.5286667", "0.52823275", "0.52720857", "0.52707684", "0.52670527", "0.52637595", "0.5262645", "0.52583885", "0.52560186", "0.52521825", "0.524959", "0.5248029", "0.5246401", "0.5246252", "0.5243456", "0.52407044", "0.52399945", "0.5234154", "0.52276516", "0.5220496", "0.5216745", "0.52071905", "0.5203023", "0.5196899", "0.51941615", "0.51906824", "0.519013", "0.5189267", "0.51843846", "0.5177534", "0.5175928", "0.5170315", "0.51585394", "0.5154314" ]
0.0
-1
/import com.sinosoft.one.ams.model.Role; import com.sinosoft.one.ams.model.RoleDesignateInfo; import com.sinosoft.one.ams.model.Task;
@Service public interface RoleService { //查询角色信息 public Role findRoleById(String roleId); //根据角色ID查询角色关联的功能 public List<Task> findTaskByRole(String roleId); //根据机构查询所有可用的功能 public List<Task> findTaskByComCode(String comCode); //查询机构下所有可见的角色 public Page<Role> findRole(String comCode,String name,Pageable pageable); public Page<RoleDesignateInfo> findRoleDesignate(String superComCode ,String comCode,Pageable pageable); //根据用户组ID查询相应的角色 public List<Role> findRoleByGroupId(String groupId,String comCode); //更新角色 public void updateRole(String roleid,String comCode,String userCode,String name,String des,String roleTpe,List<String> taskids); public void addRole(String comCode,String userCode,String name,String des,String roleTpe,List<String> taskids); public void deleteRole(String roleId, String comCode); public void designateRole(String roleId, String comCode); //根据机构Id查询角色ID public List<String> findRoleIdByComCode(String comCode); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "Import createImport();", "Import createImport();", "protected String getImportStatement() {\n return \"\";\n }", "@Override\n\tprotected void generatePkgImports() {\n\t\toutputList.add(new OutputLine(indentLvl, \"import uvm_pkg::*;\"));\n\t\toutputList.add(new OutputLine(indentLvl, \"import ordt_uvm_reg_translate1_pkg::*;\"));\n\t\tif (UVMRdlTranslate1Classes.altModelPackage != null) outputList.add(new OutputLine(indentLvl, \"import \" + UVMRdlTranslate1Classes.altModelPackage + \";\")); // add alt model pkg\n\t\toutputList.add(new OutputLine(indentLvl, \"import jspec::*;\"));\n\t}", "Imports createImports();", "public TpImport(){\r\n\t\t\r\n\t}", "public static void provideDAOsImports(final FileWriterWrapper writer,\n final String entityCodeName)\n throws IOException {\n writer.write(\"import java.sql.Connection;\\n\");\n writer.write(\"import java.sql.PreparedStatement;\\n\");\n writer.write(\"import java.sql.ResultSet;\\n\");\n writer.write(\"import java.sql.SQLException;\\n\");\n writer.write(\"import java.util.ArrayList;\\n\\n\");\n\n writer.write(\"import pojos.\" + entityCodeName + \";\\n\\n\");\n }", "private ExportRoles() {}", "public String toString()\n {\n String rr = \"\";\n \n // First process the normal (non-wildcard non-static) imports\n Iterator i = normalImports.values().iterator();\n while (i.hasNext()) {\n // String importName = ()\n JavaEntity importEntity = (JavaEntity) i.next();\n \n // build the statement string\n rr += \"import \";\n rr += importEntity.getName() + \";\" + Config.nl;\n }\n \n // Now do the (non-static) wildcard imports\n i = wildcardImports.iterator();\n while (i.hasNext()) {\n PackageOrClass importEntity = (PackageOrClass) i.next();\n rr += \"import \";\n rr += importEntity.getName() + \".*;\" + Config.nl;\n }\n \n // Now the static imports (non-wildcard)\n i = staticImports.keySet().iterator();\n while (i.hasNext()) {\n String importName = (String) i.next();\n List l = (List) staticImports.get(importName);\n Iterator j = l.iterator();\n while (j.hasNext()) {\n ClassEntity importEntity = (ClassEntity) j.next();\n rr += \"import static \" + importEntity.getName();\n rr += \".\" + importName + \";\" + Config.nl;\n }\n }\n \n // Finally the wildcard static imports\n i = staticWildcardImports.iterator();\n while (i.hasNext()) {\n ClassEntity importEntity = (ClassEntity) i.next();\n rr += \"import static \" + importEntity.getName();\n rr += \".*;\" + Config.nl;\n }\n \n return rr;\n }", "Import getImport();", "public static void main(String[] args){\n String importPath = \"import.CSV\";\n String exportQuery = \"SELECT * FROM PAIS\";\n SQLUtils t = new SQLUtilsImpl();\n File export = t.importCSV(exportQuery);\n //t.runFile(file);\n //t.importCSV(importF);\n //System.out.println(t.executeQuery(\"SELECT * FROM CIDADE WHERE ID = 3000\")); \n \n System.out.println(\"termino\");\n }", "private String importDeclaration()\r\n {\r\n String handle;\r\n\r\n matchKeyword(Keyword.IMPORTSY);\r\n handle = nextToken.string;\r\n matchKeyword(Keyword.IDENTSY);\r\n handle = qualifiedImport(handle);\r\n matchKeyword(Keyword.SEMICOLONSY);\r\n\r\n return handle;\r\n }", "private void importCatalogue() {\n\n mAuthors = importModelsFromDataSource(Author.class, getHeaderClass(Author.class));\n mBooks = importModelsFromDataSource(Book.class, getHeaderClass(Book.class));\n mMagazines = importModelsFromDataSource(Magazine.class, getHeaderClass(Magazine.class));\n }", "public static void main(String[] args) {\n String s = \"We are testing import statements\";\n System.out.println(s);\n\n // We use simple name because we specified location in the import\n // statement\n VineVegetable.main(args);\n }", "private String imported(String string) {\n string = IMPORT.matcher(string).replaceAll(\"\");\n string = DOT.matcher(string).replaceAll(\"/\");\n string = SEMICOLON.matcher(string).replaceAll(\"\");\n string = \"/\" + string.trim() + \".java\";\n return string;\n }", "ImportDeclaration createImportDeclaration();", "public static void main(String[] args) {\n\n String sql = \"load json.`F:\\\\tmp\\\\user` as 121;\";\n CodePointCharStream input = CharStreams.fromString(sql);\n DslLexer lexer = new DslLexer(input);\n CommonTokenStream tokens = new CommonTokenStream(lexer);\n DslParser parser = new DslParser(tokens);\n DslParser.SqlContext tree = parser.sql();\n ParseListener listener = new ParseListener();\n ParseTreeWalker.DEFAULT.walk(listener,tree); //规则树遍历\n\n\n\n }", "public static void main (String[] args) {import java.util.*;%>\n//&&&staticSymbol&&&<%import org.eclipse.emf.codegen.ecore.genmodel.*;%>\n//&&&staticSymbol&&&<%\n\n/**\n * Copyright (c) 2002-2010 IBM Corporation and others.\n * All rights reserved. This program and the accompanying materials\n * are made available under the terms of the Eclipse Public License v1.0\n * which accompanies this distribution, and is available at\n * http://www.eclipse.org/legal/epl-v10.html\n *\n * Contributors:\n * IBM - Initial API and implementation\n */\n\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nGenPackage genPackage = (GenPackage)((Object[])argument)[0]; GenModel genModel=genPackage.getGenModel(); /* Trick to import java.util.* without warnings */Iterator.class.getName();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nboolean isInterface = Boolean.TRUE.equals(((Object[])argument)[1]); boolean isImplementation = Boolean.TRUE.equals(((Object[])argument)[2]);\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nString publicStaticFinalFlag = isImplementation ? \"public static final \" : \"\";\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%include(\"../Header.javajetinc\");%>\n//&&&staticSymbol&&&<%\nif (isInterface || genModel.isSuppressInterfaces()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&package <%\n//&&&staticSymbol&&&=genPackage.getReflectionPackageName()\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&<%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&package <%\n//&&&staticSymbol&&&=genPackage.getClassPackageName()\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\nif (isImplementation) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.addPseudoImport(\"org.eclipse.emf.ecore.impl.MinimalEObjectImpl.Container\");\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.addPseudoImport(\"org.eclipse.emf.ecore.impl.MinimalEObjectImpl.Container.Dynamic\");\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.addImport(\"org.eclipse.emf.ecore.EClass\");\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.addImport(\"org.eclipse.emf.ecore.EObject\");\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (!genPackage.hasJavaLangConflict() && !genPackage.hasInterfaceImplConflict() && !genPackage.getClassPackageName().equals(genPackage.getInterfacePackageName())) genModel.addImport(genPackage.getInterfacePackageName() + \".*\");\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.markImportLocation(stringBuffer);\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\nif (isInterface) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&/**\n//&&&staticSymbol&&& * <!-- begin-user-doc -->\n//&&&staticSymbol&&& * The <b>Factory</b> for the model.\n//&&&staticSymbol&&& * It provides a create method for each non-abstract class of the model.\n//&&&staticSymbol&&& * <!-- end-user-doc -->\n//&&&staticSymbol&&&<%\nif (!genModel.isSuppressEMFMetaData()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& * @see <%\n//&&&staticSymbol&&&=genPackage.getQualifiedPackageInterfaceName()\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& * @generated\n//&&&staticSymbol&&& */\n//&&&staticSymbol&&&<%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&/**\n//&&&staticSymbol&&& * <!-- begin-user-doc -->\n//&&&staticSymbol&&& * An implementation of the model <b>Factory</b>.\n//&&&staticSymbol&&& * <!-- end-user-doc -->\n//&&&staticSymbol&&& * @generated\n//&&&staticSymbol&&& */\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (isImplementation) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&public class <%\n//&&&staticSymbol&&&=genPackage.getFactoryClassName()\n//&&&staticSymbol&&&%> extends <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.impl.EFactoryImpl\")\n//&&&staticSymbol&&&%><%\nif (!genModel.isSuppressInterfaces()) {\n//&&&staticSymbol&&&%> implements <%\n//&&&staticSymbol&&&=genPackage.getImportedFactoryInterfaceName()\n//&&&staticSymbol&&&%><%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&public interface <%\n//&&&staticSymbol&&&=genPackage.getFactoryInterfaceName()\n//&&&staticSymbol&&&%><%\nif (!genModel.isSuppressEMFMetaData()) {\n//&&&staticSymbol&&&%> extends <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EFactory\")\n//&&&staticSymbol&&&%><%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&{\n//&&&staticSymbol&&&<%\nif (genModel.hasCopyrightField()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=publicStaticFinalFlag\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.String\")\n//&&&staticSymbol&&&%> copyright = <%\n//&&&staticSymbol&&&=genModel.getCopyrightFieldLiteral()\n//&&&staticSymbol&&&%>;<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (isImplementation && (genModel.isSuppressEMFMetaData() || genModel.isSuppressInterfaces())) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * The singleton instance of the factory.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=publicStaticFinalFlag\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genPackage.getFactoryClassName()\n//&&&staticSymbol&&&%> eINSTANCE = init();\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (isInterface && genModel.isSuppressEMFMetaData()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * The singleton instance of the factory.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=publicStaticFinalFlag\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genPackage.getFactoryInterfaceName()\n//&&&staticSymbol&&&%> INSTANCE = <%\n//&&&staticSymbol&&&=genPackage.getQualifiedFactoryClassName()\n//&&&staticSymbol&&&%>.eINSTANCE;\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n} else if (isInterface && !genModel.isSuppressInterfaces()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * The singleton instance of the factory.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=publicStaticFinalFlag\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genPackage.getFactoryInterfaceName()\n//&&&staticSymbol&&&%> eINSTANCE = <%\n//&&&staticSymbol&&&=genPackage.getQualifiedFactoryClassName()\n//&&&staticSymbol&&&%>.init();\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (isImplementation) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Creates the default factory implementation.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&<%\nString factoryType = genModel.isSuppressEMFMetaData() ? genPackage.getFactoryClassName() : genPackage.getImportedFactoryInterfaceName();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic static <%\n//&&&staticSymbol&&&=factoryType\n//&&&staticSymbol&&&%> init()\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\ttry\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\t<%\n//&&&staticSymbol&&&=factoryType\n//&&&staticSymbol&&&%> the<%\n//&&&staticSymbol&&&=genPackage.getFactoryName()\n//&&&staticSymbol&&&%> = (<%\n//&&&staticSymbol&&&=factoryType\n//&&&staticSymbol&&&%>)<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EPackage\")\n//&&&staticSymbol&&&%>.Registry.INSTANCE.getEFactory(<%\n//&&&staticSymbol&&&=genPackage.getPackageInterfaceName()\n//&&&staticSymbol&&&%>.eNS_URI);\n//&&&staticSymbol&&&\t\t\tif (the<%\n//&&&staticSymbol&&&=genPackage.getFactoryName()\n//&&&staticSymbol&&&%> != null)\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&&\t\t\t\treturn the<%\n//&&&staticSymbol&&&=genPackage.getFactoryName()\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\tcatch (Exception exception)\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\t<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.plugin.EcorePlugin\")\n//&&&staticSymbol&&&%>.INSTANCE.log(exception);\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\treturn new <%\n//&&&staticSymbol&&&=genPackage.getImportedFactoryClassName()\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Creates an instance of the factory.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\tpublic <%\n//&&&staticSymbol&&&=genPackage.getFactoryClassName()\n//&&&staticSymbol&&&%>()\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\tsuper();\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useClassOverrideAnnotation()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@Override\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic EObject create(EClass eClass)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\tswitch (eClass.getClassifierID())\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&<%\nfor (GenClass genClass : genPackage.getGenClasses()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (!genClass.isAbstract()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tcase <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%>.<%\n//&&&staticSymbol&&&=genClass.getClassifierID()\n//&&&staticSymbol&&&%>: return <%\n//&&&staticSymbol&&&*%%storeSymbol%%*0\n//&&&staticSymbol&&&%>create<%\n//&&&staticSymbol&&&=genClass.getName()\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tdefault:\n//&&&staticSymbol&&&\t\t\t\tthrow new IllegalArgumentException(\"The class '\" + eClass.getName() + \"' is not a valid classifier\");<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(2)\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\nif (!genPackage.getAllGenDataTypes().isEmpty()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useClassOverrideAnnotation()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@Override\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic Object createFromString(<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EDataType\")\n//&&&staticSymbol&&&%> eDataType, String initialValue)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\tswitch (eDataType.getClassifierID())\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&<%\nfor (GenDataType genDataType : genPackage.getAllGenDataTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isSerializable()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tcase <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%>.<%\n//&&&staticSymbol&&&=genDataType.getClassifierID()\n//&&&staticSymbol&&&%>:\n//&&&staticSymbol&&&\t\t\t\treturn create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>FromString(eDataType, initialValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tdefault:\n//&&&staticSymbol&&&\t\t\t\tthrow new IllegalArgumentException(\"The datatype '\" + eDataType.getName() + \"' is not a valid classifier\");<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(2)\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useClassOverrideAnnotation()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@Override\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic String convertToString(<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EDataType\")\n//&&&staticSymbol&&&%> eDataType, Object instanceValue)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\tswitch (eDataType.getClassifierID())\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&<%\nfor (GenDataType genDataType : genPackage.getAllGenDataTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isSerializable()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tcase <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%>.<%\n//&&&staticSymbol&&&=genDataType.getClassifierID()\n//&&&staticSymbol&&&%>:\n//&&&staticSymbol&&&\t\t\t\treturn convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>ToString(eDataType, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tdefault:\n//&&&staticSymbol&&&\t\t\t\tthrow new IllegalArgumentException(\"The datatype '\" + eDataType.getName() + \"' is not a valid classifier\");<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(2)\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nfor (GenClass genClass : genPackage.getGenClasses()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (!genClass.isAbstract()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\tpublic <%\n//&&&staticSymbol&&&=genClass.getTypeParameters()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getImportedInterfaceName()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getInterfaceTypeArguments()\n//&&&staticSymbol&&&%> create<%\n//&&&staticSymbol&&&=genClass.getName()\n//&&&staticSymbol&&&%>()\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&& <%\nif (genClass.isDynamic()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genClass.getImportedInterfaceName()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getInterfaceTypeArguments()\n//&&&staticSymbol&&&%> <%\n//&&&staticSymbol&&&=genClass.getSafeUncapName()\n//&&&staticSymbol&&&%> = <%\n//&&&staticSymbol&&&=genClass.getCastFromEObject()\n//&&&staticSymbol&&&%>super.create(<%\n//&&&staticSymbol&&&=genClass.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genClass.getImportedClassName()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getClassTypeArguments()\n//&&&staticSymbol&&&%> <%\n//&&&staticSymbol&&&=genClass.getSafeUncapName()\n//&&&staticSymbol&&&%> = new <%\n//&&&staticSymbol&&&=genClass.getImportedClassName()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getClassTypeArguments()\n//&&&staticSymbol&&&%>()<%\nif (genModel.isSuppressInterfaces() && !genPackage.getReflectionPackageName().equals(genPackage.getInterfacePackageName())) {\n//&&&staticSymbol&&&%>{}<%\n}\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genClass.getSafeUncapName()\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nfor (GenDataType genDataType : genPackage.getAllGenDataTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isSerializable()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (genPackage.isDataTypeConverters() || genDataType.hasCreatorBody()) { String eDataType = genDataType.getQualifiedClassifierAccessor();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useGenerics() && genDataType.isUncheckedCast() && !genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@SuppressWarnings(\"unchecked\")\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic <%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedInstanceClassName()\n//&&&staticSymbol&&&%> create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(<%\nif (genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>final <%\n}\n//&&&staticSymbol&&&%>String <%\nif (genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>it<%\n} else {\n//&&&staticSymbol&&&%>literal<%\n}\n//&&&staticSymbol&&&%>)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&& <%\nif (genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getCreatorBody(genModel.getIndentation(stringBuffer))\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType instanceof GenEnum) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getImportedInstanceClassName()\n//&&&staticSymbol&&&%> result = <%\n//&&&staticSymbol&&&=genDataType.getImportedInstanceClassName()\n//&&&staticSymbol&&&%>.get(literal);\n//&&&staticSymbol&&&\t\tif (result == null) throw new IllegalArgumentException(\"The value '\" + literal + \"' is not a valid enumerator of '\" + <%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>.getName() + \"'\");<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(2)\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(3)\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn result;\n//&&&staticSymbol&&& <%\n} else if (genDataType.getBaseType() != null) { GenDataType genBaseType = genDataType.getBaseType(); boolean isPrimitiveConversion = !genDataType.isPrimitiveType() && genBaseType.isPrimitiveType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genBaseType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (isPrimitiveConversion && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn new <%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(create<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(literal));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn create<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genBaseType.getGenPackage().isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (isPrimitiveConversion && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn new <%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.create<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(literal));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.create<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getItemType() != null) { GenDataType genItemType = genDataType.getItemType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (literal == null) return null;\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedInstanceClassName()\n//&&&staticSymbol&&&%> result = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.ArrayList\")\n//&&&staticSymbol&&&%><%\nif (genModel.useGenerics()) {\n//&&&staticSymbol&&&%><<%=genItemType.getObjectType().getImportedParameterizedInstanceClassName()%>><%\n}\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\nif (genModel.getRuntimeVersion().getValue() < GenRuntimeVersion.EMF26_VALUE) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.StringTokenizer\")\n//&&&staticSymbol&&&%> stringTokenizer = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.StringTokenizer\")\n//&&&staticSymbol&&&%>(literal); stringTokenizer.hasMoreTokens(); )\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (String item : split(literal))\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genModel.getRuntimeVersion().getValue() < GenRuntimeVersion.EMF26_VALUE) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString item = stringTokenizer.nextToken();\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) { genItemType = genItemType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(create<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>(item));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(create<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, item));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage().isDataTypeConverters()) { genItemType = genItemType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(<%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.create<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>(item));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(<%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, item));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\treturn result;\n//&&&staticSymbol&&& <%\n} else if (!genDataType.getMemberTypes().isEmpty()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (literal == null) return <%\n//&&&staticSymbol&&&=genDataType.getStaticValue(null)\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getImportedInstanceClassName()\n//&&&staticSymbol&&&%> result = <%\n//&&&staticSymbol&&&=genDataType.getStaticValue(null)\n//&&&staticSymbol&&&%>;\n//&&&staticSymbol&&&\t\tRuntimeException exception = null;\n//&&&staticSymbol&&& <%\nfor (GenDataType genMemberType : genDataType.getMemberTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\ttry\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) { if (!genDataType.isPrimitiveType()) genMemberType = genMemberType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = create<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(literal);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = (<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)create<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) { if (!genDataType.isPrimitiveType()) genMemberType = genMemberType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.create<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(literal);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = (<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tif (<%\nif (!genDataType.isPrimitiveType()) {\n//&&&staticSymbol&&&%>result != null && <%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.util.Diagnostician\")\n//&&&staticSymbol&&&%>.INSTANCE.validate(<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>, <%\nif (genDataType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>new <%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(result)<%\n} else {\n//&&&staticSymbol&&&%>result<%\n}\n//&&&staticSymbol&&&%>, null, null))\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&&\t\t\t\treturn result;\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\tcatch (RuntimeException e)\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\texception = e;\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (<%\nif (!genDataType.isPrimitiveType()) {\n//&&&staticSymbol&&&%>result != null || <%\n}\n//&&&staticSymbol&&&%>exception == null) return result;\n//&&&staticSymbol&&& \n//&&&staticSymbol&&&\t\tthrow exception;\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genModel.useGenerics() && (genDataType.isArrayType() || !genDataType.getEcoreDataType().getETypeParameters().isEmpty() || genDataType.getEcoreDataType().getInstanceTypeName().contains(\"<\"))) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn (<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%>)super.createFromString(literal);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genDataType.isArrayType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t// TODO: implement this method\n//&&&staticSymbol&&&\t\t// Ensure that you remove @generated or mark it @generated NOT\n//&&&staticSymbol&&&\t\tthrow new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.UnsupportedOperationException\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\n} else if (genDataType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn ((<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)super.createFromString(<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>, literal)).<%\n//&&&staticSymbol&&&=genDataType.getPrimitiveValueFunction()\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%>super.createFromString(<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>, literal);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (!genPackage.isDataTypeConverters() && genModel.useGenerics() && genDataType.isUncheckedCast() && !genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@SuppressWarnings(\"unchecked\")\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic <%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%> create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EDataType\")\n//&&&staticSymbol&&&%> eDataType, String initialValue)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&& <%\nif (genDataType instanceof GenEnum) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters() || genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(initialValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=((GenEnum)genDataType).getImportedInstanceClassName()\n//&&&staticSymbol&&&%> result = <%\n//&&&staticSymbol&&&=((GenEnum)genDataType).getImportedInstanceClassName()\n//&&&staticSymbol&&&%>.get(initialValue);\n//&&&staticSymbol&&&\t\tif (result == null) throw new IllegalArgumentException(\"The value '\" + initialValue + \"' is not a valid enumerator of '\" + eDataType.getName() + \"'\");<%\n//&&&staticSymbol&&&=genModel.getNonNLS()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(2)\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genModel.getNonNLS(3)\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn result;\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getBaseType() != null) { GenDataType genBaseType = genDataType.getBaseType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genBaseType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.getObjectInstanceClassName().equals(genBaseType.getObjectInstanceClassName())) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%>create<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, initialValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, initialValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getItemType() != null) { GenDataType genItemType = genDataType.getItemType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(initialValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (initialValue == null) return null;\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%> result = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.ArrayList\")\n//&&&staticSymbol&&&%><%\nif (genModel.useGenerics()) {\n//&&&staticSymbol&&&%><<%=genItemType.getObjectType().getImportedParameterizedInstanceClassName()%>><%\n}\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\nif (genModel.getRuntimeVersion().getValue() < GenRuntimeVersion.EMF26_VALUE) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.StringTokenizer\")\n//&&&staticSymbol&&&%> stringTokenizer = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.StringTokenizer\")\n//&&&staticSymbol&&&%>(initialValue); stringTokenizer.hasMoreTokens(); )\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (String item : split(initialValue))\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genModel.getRuntimeVersion().getValue() < GenRuntimeVersion.EMF26_VALUE) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString item = stringTokenizer.nextToken();\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(create<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, item));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.add(<%\nif (!genItemType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genItemType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, item));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\treturn result;\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (!genDataType.getMemberTypes().isEmpty()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn new <%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(initialValue));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(initialValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (initialValue == null) return null;\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%> result = null;\n//&&&staticSymbol&&&\t\tRuntimeException exception = null;\n//&&&staticSymbol&&& <%\nfor (GenDataType genMemberType : genDataType.getMemberTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\ttry\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = <%\nif (!genDataType.isObjectType() && !genDataType.getObjectInstanceClassName().equals(genMemberType.getObjectInstanceClassName())) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%>create<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>FromString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, initialValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult = <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.createFromString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, initialValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tif (result != null && <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.util.Diagnostician\")\n//&&&staticSymbol&&&%>.INSTANCE.validate(eDataType, result, null, null))\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&&\t\t\t\treturn result;\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\tcatch (RuntimeException e)\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\texception = e;\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (result != null || exception == null) return result;\n//&&&staticSymbol&&& \n//&&&staticSymbol&&&\t\tthrow exception;\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genPackage.isDataTypeConverters() || genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(initialValue);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genModel.useGenerics() && (genDataType.isArrayType() || !genDataType.getEcoreDataType().getETypeParameters().isEmpty() || genDataType.getEcoreDataType().getInstanceTypeName().contains(\"<\"))) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%>super.createFromString(initialValue);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genDataType.isArrayType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t// TODO: implement this method\n//&&&staticSymbol&&&\t\t// Ensure that you remove @generated or mark it @generated NOT\n//&&&staticSymbol&&&\t\tthrow new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.UnsupportedOperationException\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\nif (!genDataType.isObjectType()) {\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n}\n//&&&staticSymbol&&&%>super.createFromString(eDataType, initialValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\nif (genPackage.isDataTypeConverters() || genDataType.hasConverterBody()) { String eDataType = genDataType.getQualifiedClassifierAccessor();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\tpublic String convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(<%\nif (genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>final <%\n}\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genDataType.getImportedBoundedWildcardInstanceClassName()\n//&&&staticSymbol&&&%> <%\nif (genDataType.hasConverterBody()) {\n//&&&staticSymbol&&&%>it<%\n} else {\n//&&&staticSymbol&&&%>instanceValue<%\n}\n//&&&staticSymbol&&&%>)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&& <%\nif (genDataType.hasConverterBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genDataType.getConverterBody(genModel.getIndentation(stringBuffer))\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType instanceof GenEnum) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn instanceValue == null ? null : instanceValue.toString();\n//&&&staticSymbol&&& <%\n} else if (genDataType.getBaseType() != null) { GenDataType genBaseType = genDataType.getBaseType(); boolean isPrimitiveConversion = !genDataType.isPrimitiveType() && genBaseType.isPrimitiveType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genBaseType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (isPrimitiveConversion) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn instanceValue == null ? null : convert<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(instanceValue<%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>.<%\n//&&&staticSymbol&&&=genBaseType.getPrimitiveValueFunction()\n//&&&staticSymbol&&&%>()<%\n}\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genBaseType.getGenPackage().isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedFactoryInstanceAccessor()\n//&&&staticSymbol&&&%>.convert<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getItemType() != null) { GenDataType genItemType = genDataType.getItemType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (instanceValue == null) return null;\n//&&&staticSymbol&&&\t\tif (instanceValue.isEmpty()) return \"\";\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.StringBuffer\")\n//&&&staticSymbol&&&%> result = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.StringBuffer\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\nString item; if (!genModel.useGenerics()) { item = \"i.next()\"; \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.Iterator\")\n//&&&staticSymbol&&&%> i = instanceValue.iterator(); i.hasNext(); )\n//&&&staticSymbol&&& <%\n} else { item = \"item\";\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.Object\")\n//&&&staticSymbol&&&%> item : instanceValue)\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) { genItemType = genItemType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(convert<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genItemType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(convert<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage().isDataTypeConverters()) { genItemType = genItemType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(<%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convert<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genItemType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)<%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(<%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(' ');\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\treturn result.substring(0, result.length() - 1);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.getMemberTypes().isEmpty()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (!genDataType.isPrimitiveType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (instanceValue == null) return null;\n//&&&staticSymbol&&& <%\nfor (GenDataType genMemberType : genDataType.getMemberTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>.isInstance(instanceValue))\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\ttry\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genMemberType.getQualifiedInstanceClassName().equals(genDataType.getQualifiedInstanceClassName())) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n} else if (genMemberType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(((<%\n//&&&staticSymbol&&&=genMemberType.getObjectType().getImportedInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue).<%\n//&&&staticSymbol&&&=genMemberType.getPrimitiveValueFunction()\n//&&&staticSymbol&&&%>());\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genMemberType.getObjectType().getImportedBoundedWildcardInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage().isDataTypeConverters()) { genMemberType = genMemberType.getObjectType();\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genMemberType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tif (value != null) return value;\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t\tcatch (Exception e)\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&&\t\t\t\t// Keep trying other member types until all have failed.\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nfor (GenDataType genMemberType : genDataType.getMemberTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\ttry\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>new <%\n//&&&staticSymbol&&&=genMemberType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(instanceValue)<%\n} else {\n//&&&staticSymbol&&&%>instanceValue<%\n}\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage().isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString value = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tString value = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>new <%\n//&&&staticSymbol&&&=genMemberType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(instanceValue)<%\n} else {\n//&&&staticSymbol&&&%>instanceValue<%\n}\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tif (value != null) return value;\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\tcatch (Exception e)\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\t// Keep trying other member types until all have failed.\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tthrow new IllegalArgumentException(\"Invalid value: '\"+instanceValue+\"' for datatype :\"+<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>.getName());\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genModel.useGenerics() && (genDataType.isArrayType() || !genDataType.getEcoreDataType().getETypeParameters().isEmpty() || genDataType.getEcoreDataType().getInstanceTypeName().contains(\"<\"))) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn super.convertToString(instanceValue);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genDataType.isArrayType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t// TODO: implement this method\n//&&&staticSymbol&&&\t\t// Ensure that you remove @generated or mark it @generated NOT\n//&&&staticSymbol&&&\t\tthrow new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.UnsupportedOperationException\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\n} else if (genDataType.isPrimitiveType() && genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn super.convertToString(<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>, new <%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>(instanceValue));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn super.convertToString(<%\n//&&&staticSymbol&&&=eDataType\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useGenerics() && (genDataType.getItemType() != null || genDataType.isUncheckedCast()) && (genPackage.isDataTypeConverters() || genDataType.hasCreatorBody())) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@SuppressWarnings(\"unchecked\")\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic String convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"org.eclipse.emf.ecore.EDataType\")\n//&&&staticSymbol&&&%> eDataType, Object instanceValue)\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&& <%\nif (genDataType instanceof GenEnum) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters() || genDataType.hasConverterBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genDataType.getImportedInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn instanceValue == null ? null : instanceValue.toString();\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getBaseType() != null) { GenDataType genBaseType = genDataType.getBaseType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genBaseType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genBaseType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genBaseType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genBaseType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genDataType.getItemType() != null) { GenDataType genItemType = genDataType.getItemType(); \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters() || genDataType.hasCreatorBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genDataType.getImportedBoundedWildcardInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue);\n//&&&staticSymbol&&& <%\n} else { final String singleWildcard = genModel.useGenerics() ? \"<?>\" : \"\";\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (instanceValue == null) return null;\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.List\")\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=singleWildcard\n//&&&staticSymbol&&&%> list = (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.List\")\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=singleWildcard\n//&&&staticSymbol&&&%>)instanceValue;\n//&&&staticSymbol&&&\t\tif (list.isEmpty()) return \"\";\n//&&&staticSymbol&&&\t\t<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.StringBuffer\")\n//&&&staticSymbol&&&%> result = new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.StringBuffer\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\nString item; if (!genModel.useGenerics()) { item = \"i.next()\"; \n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.util.Iterator\")\n//&&&staticSymbol&&&%> i = list.iterator(); i.hasNext(); )\n//&&&staticSymbol&&& <%\n} else { item = \"item\";\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tfor (<%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.Object\")\n//&&&staticSymbol&&&%> item : list)\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&& <%\nif (genItemType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(convert<%\n//&&&staticSymbol&&&=genItemType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(<%\n//&&&staticSymbol&&&=genItemType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genItemType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, <%\n//&&&staticSymbol&&&=item\n//&&&staticSymbol&&&%>));\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\tresult.append(' ');\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&&\t\treturn result.substring(0, result.length() - 1);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (!genDataType.getMemberTypes().isEmpty()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters() || genDataType.hasConverterBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isPrimitiveType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn instanceValue == null ? null : convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(((<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue)<%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>.<%\n//&&&staticSymbol&&&=genDataType.getPrimitiveValueFunction()\n//&&&staticSymbol&&&%>()<%\n}\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (instanceValue == null) return null;\n//&&&staticSymbol&&& <%\nfor (GenDataType genMemberType : genDataType.getMemberTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tif (<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>.isInstance(instanceValue))\n//&&&staticSymbol&&&\t\t{\n//&&&staticSymbol&&&\t\t\ttry\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&& <%\nif (genMemberType.getGenPackage() == genPackage) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = convert<%\n//&&&staticSymbol&&&=genMemberType.getName()\n//&&&staticSymbol&&&%>ToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tString value = <%\n//&&&staticSymbol&&&=genMemberType.getGenPackage().getQualifiedEFactoryInternalInstanceAccessor()\n//&&&staticSymbol&&&%>.convertToString(<%\n//&&&staticSymbol&&&=genMemberType.getQualifiedClassifierAccessor()\n//&&&staticSymbol&&&%>, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t\t\tif (value != null) return value;\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t\tcatch (Exception e)\n//&&&staticSymbol&&&\t\t\t{\n//&&&staticSymbol&&&\t\t\t\t// Keep trying other member types until all have failed.\n//&&&staticSymbol&&&\t\t\t}\n//&&&staticSymbol&&&\t\t}\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\tthrow new IllegalArgumentException(\"Invalid value: '\"+instanceValue+\"' for datatype :\"+eDataType.getName());\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (genPackage.isDataTypeConverters() || genDataType.hasConverterBody()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isPrimitiveType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn instanceValue == null ? null : convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(<%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>(<%\n}\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getObjectInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue<%\nif (genModel.getComplianceLevel().getValue() < GenJDKLevel.JDK50) {\n//&&&staticSymbol&&&%>).<%\n//&&&staticSymbol&&&=genDataType.getPrimitiveValueFunction()\n//&&&staticSymbol&&&%>()<%\n}\n//&&&staticSymbol&&&%>);\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>((<%\n//&&&staticSymbol&&&=genDataType.getImportedBoundedWildcardInstanceClassName()\n//&&&staticSymbol&&&%>)instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genModel.useGenerics() && (genDataType.isArrayType() || !genDataType.getEcoreDataType().getETypeParameters().isEmpty() || genDataType.getEcoreDataType().getInstanceTypeName().contains(\"<\"))) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn super.convertToString(instanceValue);\n//&&&staticSymbol&&& <%\n} else if (!genDataType.hasConversionDelegate() && genDataType.isArrayType()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\t// TODO: implement this method\n//&&&staticSymbol&&&\t\t// Ensure that you remove @generated or mark it @generated NOT\n//&&&staticSymbol&&&\t\tthrow new <%\n//&&&staticSymbol&&&=genModel.getImportedName(\"java.lang.UnsupportedOperationException\")\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&& <%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t\treturn super.convertToString(eDataType, instanceValue);\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n} else {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nfor (GenClass genClass : genPackage.getGenClasses()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genClass.hasFactoryInterfaceCreateMethod()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Returns a new object of class '<em><%\n//&&&staticSymbol&&&=genClass.getFormattedName()\n//&&&staticSymbol&&&%></em>'.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @return a new object of class '<em><%\n//&&&staticSymbol&&&=genClass.getFormattedName()\n//&&&staticSymbol&&&%></em>'.\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=genClass.getTypeParameters()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getImportedInterfaceName()\n//&&&staticSymbol&&&%><%\n//&&&staticSymbol&&&=genClass.getInterfaceTypeArguments()\n//&&&staticSymbol&&&%> create<%\n//&&&staticSymbol&&&=genClass.getName()\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&&\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genPackage.isDataTypeConverters()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nfor (GenDataType genDataType : genPackage.getAllGenDataTypes()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\nif (genDataType.isSerializable()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Returns an instance of data type '<em><%\n//&&&staticSymbol&&&=genDataType.getFormattedName()\n//&&&staticSymbol&&&%></em>' corresponding the given literal.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @param literal a literal of the data type.\n//&&&staticSymbol&&&\t * @return a new instance value of the data type.\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=genDataType.getImportedParameterizedInstanceClassName()\n//&&&staticSymbol&&&%> create<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(String literal);\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Returns a literal representation of an instance of data type '<em><%\n//&&&staticSymbol&&&=genDataType.getFormattedName()\n//&&&staticSymbol&&&%></em>'.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @param instanceValue an instance value of the data type.\n//&&&staticSymbol&&&\t * @return a literal representation of the instance value.\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\tString convert<%\n//&&&staticSymbol&&&=genDataType.getName()\n//&&&staticSymbol&&&%>(<%\n//&&&staticSymbol&&&=genDataType.getImportedBoundedWildcardInstanceClassName()\n//&&&staticSymbol&&&%> instanceValue);\n//&&&staticSymbol&&&\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\nif (!isImplementation && !genModel.isSuppressEMFMetaData()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * Returns the package supported by this factory.\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @return the package supported by this factory.\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\t<%\n//&&&staticSymbol&&&=genPackage.getPackageInterfaceName()\n//&&&staticSymbol&&&%> get<%\n//&&&staticSymbol&&&=genPackage.getBasicPackageName()\n//&&&staticSymbol&&&%>();\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n} else if (isImplementation) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&&\tpublic <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%> get<%\n//&&&staticSymbol&&&=genPackage.getBasicPackageName()\n//&&&staticSymbol&&&%>()\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\treturn (<%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%>)getEPackage();\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&\t/**\n//&&&staticSymbol&&&\t * <!-- begin-user-doc -->\n//&&&staticSymbol&&&\t * <!-- end-user-doc -->\n//&&&staticSymbol&&&\t * @deprecated\n//&&&staticSymbol&&&\t * @generated\n//&&&staticSymbol&&&\t */\n//&&&staticSymbol&&& <%\nif (genModel.useClassOverrideAnnotation()) {\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\t@Deprecated\n//&&&staticSymbol&&& <%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&\tpublic static <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%> getPackage()\n//&&&staticSymbol&&&\t{\n//&&&staticSymbol&&&\t\treturn <%\n//&&&staticSymbol&&&=genPackage.getImportedPackageInterfaceName()\n//&&&staticSymbol&&&%>.eINSTANCE;\n//&&&staticSymbol&&&\t}\n//&&&staticSymbol&&&\n//&&&staticSymbol&&&<%\n}\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&} //<%\n//&&&staticSymbol&&&*%%storeSymbol%%*1\n//&&&staticSymbol&&&%>\n//&&&staticSymbol&&&<%\ngenModel.emitSortedImports();\n//&&&staticSymbol&&&%>\n\n}", "DataModelOracle getDataModelOracle( Path project );", "public static void main(String[] args) {\n\t\t\r\n\r\n\t\tSession se2 = impl.getSe();\r\n\t\tTransaction tx2 = se2.beginTransaction();\r\n\t\t\r\n\t\tString sql = \"SELECT * FROM member\";\r\n\t\tSQLQuery sql1=se2.createSQLQuery(\"SELECT * FROM member\");\r\n\r\n\t\tsql1.addEntity(\"member\",member.class);\r\n\t\t\r\n\t\tList<member> l = sql1.list();\r\n\t\t\r\n\t\tl.forEach(s -> System.out.println(s));\r\n\t\t\r\n\t\tse2.close();\r\n\t\t\r\n\t\t\r\n//\t\t\r\n//\t\t\r\n\r\n\t}", "public String identity () throws CGException {\n return new String(\"ModelImport\");\n }", "@UseClasspathSqlLocator\npublic interface MovieDao {\n\n @SqlQuery\n @RegisterRowMapper(Movie.MovieMapper.class)\n List<Movie> getMovies(@Bind(\"year\") int year);\n\n @SqlQuery\n @RegisterRowMapper(Actor.ActorMapper.class)\n List<Actor> getActors(@BindCountry Country country);\n}", "public static void main(String[] args) {\n\t\tClass aClass = Role.class;\n\t\tField[] fields = aClass.getDeclaredFields();\n\t\t\n\t\tfor(Field field : fields) {\n\t\t\tAnnotation[] annotations = field.getAnnotations();\n\t\t\tfor(Annotation annotation : annotations){\n\t\t\t if(annotation instanceof Column){\n//\t\t\t \tColumn myAnnotation = (Column) annotation;\n//\t\t\t System.out.println(\"name: \" + myAnnotation.name());\n\t\t\t switch(field.getType().getSimpleName()) {\n\t\t\t case \"String\":\n\t\t\t \tSystem.out.println(field.getName() + \": string;\");\n\t\t\t \tbreak;\n\t\t\t case \"Integer\":\n\t\t\t \tSystem.out.println(field.getName() + \": number;\");\n\t\t\t \tbreak;\n\t\t\t default:\n\t\t\t \tSystem.out.println(field.getName() + \":\" + field.getType().getSimpleName()+ \";\");\n\t\t\t \tbreak;\n\t\t\t }\n\t\t\t \n\t\t\t }\n\t\t\t}\n\t\t}\n\t\t\n\n\t}", "public static void main(String[] args) {\n MySQLScriptGen databaseobject = new MySQLScriptGen();\n\n //this is same for every model\n JsonFileReader jsonFileReader = JsonFileReader.getInstance();\n JSONObject pim = jsonFileReader.getplatformIndependentModel();\n String ddl_script = databaseobject.createDDLScript(pim);\n String dml_script = databaseobject.createDMLScript(pim);\n String dql_script = databaseobject.createDQLScript(pim);\n System.out.println(\">>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>RIP_SQL_GEN_BEGIN>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>\\n\\n\");\n System.out.println(ddl_script);\n System.out.println(\"\\n\\n>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>RIP_SQL_GEN_END>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>\");\n System.out.println(\"\\n\\n>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>RIP_SQL_GEN_DML_BEGIN>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>\");\n System.out.println(dml_script);\n System.out.println(\"\\n\\n>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>RIP_SQL_GEN_DML_END>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>\");\n System.out.println(\"\\n\\n>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>RIP_SQL_GEN_DQL_BEGIN>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>\");\n System.out.println(dql_script);\n System.out.println(\"\\n\\n>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>RIP_SQL_GEN_DQL_END>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>\");\n }", "@Test\n public void testRequire() {\n StringConcatenation _builder = new StringConcatenation();\n _builder.append(\"ePackageImport testmodel\");\n _builder.newLine();\n _builder.newLine();\n _builder.append(\"rule rulename() {\");\n _builder.newLine();\n _builder.append(\"\\t\");\n _builder.append(\"graph {\");\n _builder.newLine();\n _builder.append(\"\\t\\t\");\n _builder.append(\"edges [(require a->b:testmodel.type)]\");\n _builder.newLine();\n _builder.append(\"\\t\\t\");\n _builder.append(\"require node a:testmodel.type\");\n _builder.newLine();\n _builder.append(\"\\t\\t\");\n _builder.append(\"require node b:testmodel.type {}\");\n _builder.newLine();\n _builder.append(\"\\t\");\n _builder.append(\"}\");\n _builder.newLine();\n _builder.append(\"}\");\n _builder.newLine();\n _builder.newLine();\n final String model = _builder.toString();\n final Procedure1<FormatterTestRequest> _function = new Procedure1<FormatterTestRequest>() {\n public void apply(final FormatterTestRequest it) {\n it.setToBeFormatted(model.replace(\"\\n\", \"\").replace(\"\\t\", \"\"));\n it.setExpectation(model);\n }\n };\n this.assertFormatted(_function);\n }", "public interface ModelConstants {\n \n // elements\n @Deprecated\n public final static String ACQUISITION_STRATEGY = \"acquisition-strategy\";\n \n public final static String DATASOURCE = \"datasource\";\n public final static String HISTORY_LEVEL = \"history-level\";\n public final static String JOB_ACQUISITION = \"job-acquisition\";\n public final static String JOB_ACQUISITIONS = \"job-acquisitions\";\n public final static String JOB_EXECUTOR = \"job-executor\";\n public final static String PROCESS_ENGINE = \"process-engine\";\n public final static String PROCESS_ENGINES = \"process-engines\";\n public final static String PROPERTY = \"property\";\n public final static String PROPERTIES = \"properties\";\n public final static String CONFIGURATION = \"configuration\";\n\n public final static String PLUGINS = \"plugins\";\n public final static String PLUGIN = \"plugin\";\n public final static String PLUGIN_CLASS = \"class\";\n \n // attributes\n public final static String DEFAULT = \"default\";\n public final static String NAME = \"name\";\n public final static String THREAD_POOL_NAME = \"thread-pool-name\";\n /** The name of our subsystem within the model. */\n public static final String SUBSYSTEM_NAME = \"camunda-bpm-platform\";\n \n}", "@Test\n public void testLHSMapping() {\n StringConcatenation _builder = new StringConcatenation();\n _builder.append(\"ePackageImport testmodel\");\n _builder.newLine();\n _builder.newLine();\n _builder.append(\"rule rulename() {\");\n _builder.newLine();\n _builder.append(\"\\t\");\n _builder.append(\"graph {\");\n _builder.newLine();\n _builder.append(\"\\t\\t\");\n _builder.append(\"node a:testmodel.type\");\n _builder.newLine();\n _builder.append(\"\\t\\t\");\n _builder.append(\"node b:testmodel.type\");\n _builder.newLine();\n _builder.append(\"\\t\\t\");\n _builder.append(\"node c:testmodel.type\");\n _builder.newLine();\n _builder.append(\"\\t\\t\");\n _builder.append(\"matchingFormula {\");\n _builder.newLine();\n _builder.append(\"\\t\\t\\t\");\n _builder.append(\"formula !conGraph\");\n _builder.newLine();\n _builder.append(\"\\t\\t\\t\");\n _builder.append(\"conditionGraph conGraph {\");\n _builder.newLine();\n _builder.append(\"\\t\\t\\t\\t\");\n _builder.append(\"node d:testmodel.type\");\n _builder.newLine();\n _builder.append(\"\\t\\t\\t\\t\");\n _builder.append(\"reuse a {\");\n _builder.newLine();\n _builder.append(\"\\t\\t\\t\\t\\t\");\n _builder.append(\"attribute=\\\"test\\\"\");\n _builder.newLine();\n _builder.append(\"\\t\\t\\t\\t\");\n _builder.append(\"}\");\n _builder.newLine();\n _builder.append(\"\\t\\t\\t\\t\");\n _builder.append(\"edges [(d->b:testmodel.type)]\");\n _builder.newLine();\n _builder.append(\"\\t\\t\\t\");\n _builder.append(\"}\");\n _builder.newLine();\n _builder.append(\"\\t\\t\");\n _builder.append(\"}\");\n _builder.newLine();\n _builder.append(\"\\t\");\n _builder.append(\"}\");\n _builder.newLine();\n _builder.append(\"}\");\n _builder.newLine();\n _builder.newLine();\n final String model = _builder.toString();\n final Procedure1<FormatterTestRequest> _function = new Procedure1<FormatterTestRequest>() {\n public void apply(final FormatterTestRequest it) {\n it.setToBeFormatted(model.replace(\"\\n\", \"\").replace(\"\\t\", \"\"));\n it.setExpectation(model);\n }\n };\n this.assertFormatted(_function);\n }", "StatementsPackage getStatementsPackage();", "@Projection(name = \"experiencetaskinfo\", types = {ExperienceTask.class})\npublic interface ExperienceTaskProjection {\n\n int getId();\n\n String getName();\n\n int getExperience();\n\n String getDescription();\n\n int getLimitPeriod();\n\n int getLimitTimes();\n}", "public JmlModelImport () throws CGException {\n try {\n\n ivModel = null;\n ivImport = UTIL.ConvertToString(new String());\n }\n catch (Exception e){\n\n e.printStackTrace(System.out);\n System.out.println(e.getMessage());\n }\n }", "public static void main(String[] args) {\n\t\t\n\t\tSwotTaskDAOInterface swotTaskDAO = new SwotTaskDAO();\n//\t\tSwotActorDAOInterface swotActorDAO = new SwotActorDAO();\n//\t\t\n//\t\tSwotTask swotTask = swotTaskDAO.getSwotTaskByID(1);\n//\t\tList<SwotActor> swotActorList = swotTaskDAO.getAllTaskActors(swotTask);\n//\t\t\n//\t\tfor(SwotActor swotActor:swotActorList) {\n//\t\t\tSwotActorDAOInterface swotActorDAO = new SwotActorDAO();\n//\t\t\tList<SwotActorProperty> actorPropertyList = swotActorDAO.getAllActorPropertys(swotActor);\t\n//\t\t\tfor(SwotActorProperty actorProperty:actorPropertyList) {\t\t//删除属性\n//\t\t\t\tSwotPropertyDAOInterface swotPropertyDAO = new SwotPropertyDAO();\n//\t\t\t\tswotPropertyDAO.deletePropertyByID(actorProperty.getPropertyID());\n//\t\t\t}\t\n//\t\t\tswotActorDAO.deleteActorByID(swotActor.getActorID());\n//\t\t}\n//\t\tswotTaskDAO.deleteTaskByID(1);\n\t\t\n\t\tCalendar calendar = Calendar.getInstance();\n calendar.set(2023, \t\t//年份自动多余,不知缘由\n \t\t1, 2, 0, 0, 0);\n calendar.set(Calendar.MILLISECOND, 0);\n \n\t\tSwotTask swotTask = new SwotTask();\n\t\tswotTask.setTaskName(\"测试用例3\");\n\t\tswotTask.setArgueTime(calendar.getTime());\t\n\t\tswotTaskDAO.addTask(swotTask);\n//\n//\t\tSwotActor swotActor = new SwotActor();\n//\t\tswotActor.setActorName(\"参与者0\");\n//\t\tswotActorDAO.addActor(swotTask, swotActor);\n//\t\t\n//\t\tSwotActor swotActor1 = new SwotActor();\n//\t\tswotActor1.setActorName(\"参与者1\");\n//\t\tswotActorDAO.addActor(swotTask, swotActor1);\n\t\t\n\t\t\n//\t\tList<SwotTask> swotTaskssList = swotActorDAO.getSwotTaskByActorName(\"2\");\n//\t\tfor(SwotTask lists:swotTaskssList) {\n//\t\t\tSystem.out.println(lists.toString());\n//\t\t}\n\t\t\n\t//\tList<SwotActor> swotTasksList = swotActorDAO.getSwotActorByActorName(\"2\");\n//\t\tList<SwotTask> swotTaskList = swotTaskDAO.getAllSwotTasks();\n//\t\tfor(SwotTask lists:swotTaskList) {\n//\t\t\tSystem.out.println(lists.toString());\n//\t\t}\n//\t\t\n//\t\tSwotTask swotTask = swotTaskDAO.getSwotTaskByID(1);\n//\t\tSwotActor swotActor = new SwotActor();\n//\t\tswotActor.setActorName(\"22222\");\n//\t\tswotActorDAO.addActor(swotTask, swotActor);\n\t\t\n\n\t}", "TopLevelImport createTopLevelImport();", "public static void providePOJOsImports(final FileWriterWrapper writer,\n final Entity entity)\n throws IOException {\n if (entity.hasADateField()) {\n writer.write(\"import java.util.Date;\\n\");\n }\n\n if (entity.hasAManyRelation()) {\n writer.write(\"import java.util.ArrayList;\\n\");\n }\n writer.write(\"\\n\");\n }", "public static void main(String[] args) {\n \n\t\tInstructor instructor = new Instructor();\n\t\tinstructor.id=1;\n\t\tinstructor.firstName=\"ali\";\n\t\tinstructor.lastName=\"Veli\";\n\t\tinstructor.lessons=\"C#\";\n\t\tinstructor.phoneNumber=\"00000000000\";\n\t\tinstructor.email=\"[email protected]\";\n\t\tinstructor.password=\"1222\";\n\t\t\n\t\tStudent student = new Student();\n\t\tstudent.firstName =\"Oya\";\n\t\tstudent.lastName =\"deniz\";\n\n\t\t\n\t\t\n\t\tUserManager userManager = new UserManager();\n\t\tuserManager.add(student);\n\t\tuserManager.add(instructor);\n\t\tUser[] users = {instructor,student};\n\t\t\n\t\tuserManager.allList(users);\n\t\t\n\t\t\n\t\t\n\t\t\n\t}", "public static void main(String[] args) throws Exception \n\t{\n\t\t///////////////////////////////////////////////////////////////////////////\n\t\t//Define Class Attributes[Variables] Here\n\t\t\n\t\t// Here are the class variables for the:\n\t\t// 1. The Query string passed to the entity class 'query';\n\t\t// 2. The ResultSet 'result' that the query is returned.\n\t\t\n\t\tString access_result;\n\t\t // this is the variable that stores the result of the access\n\t\t // If access_result==\"show_welcome\", it will present the welcome screen\n\t\t // If access_result==\"logged_in\", it will create a new session for the user.\n\t\t // Once logged in, there is need for a loop that checks \n\t\t // If access_result==\"logged_out\", it will close the open session for the user\n\t\t \n\t\t\n\t\tString query;\n\t\t// this variable holds the query that shall be passed to the entity class\n\t\tResultSet result;\n\t\t// this variable holds the results returned from executing the query\n\t\t// on the entity class.\n\t\t\n\t\t// call the control for the welcome screen Control001AccessManWecome\n\t\t// This control then calls the Bound001AccessManWecome class\n\t\t// that retrieves the value. \n\t\t// If the user chooses to register then control will remain with\n\t\t// Control001AccessManWecome.\n\t\t// If the user chooses to login, then control will return \n\t\t// back to this main method.\n\t\t\n\t\tString role;\n\t\t// this stores the value of the role being returned back from \n\t\t// the query of the session table.\n\t\t\n\t\tString usName;\n\t\t// this stores the user name of the user who has logged in.\n\t\t\n\t\tControl001AccessManWecome WecomeControl = new Control001AccessManWecome();\n\t\t\n\t\t// create an instance of the EntityMySQLInteraction class\n\t\t// to make a database connection.\t\t\n\t\tEntityMySQLInteraction dbConnect= new EntityMySQLInteraction();\n\t\t\n\n\t\tquery=\"SET SQL_SAFE_UPDATES = 0\";\n\t\t// this prevents the mysql error message Error Code: 1175, so you can use any other key apart from the primary key\n\t\t\n\t\tdbConnect.setQuery(query);\n\t\ttry {\n\t\t\tdbConnect.setInsertData();\n\t\t} //end the try block\n\t\tcatch (Exception e) \n\t\t{\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}//end the catch block\n\t\t\n\t\tquery=\"delete from session where login_status=\"+ \"\\'logged_in\\'\";\n\t\t// this removes all previous database entries that had a Logged in status… in the session table.\n\t\t// This would mean that there should be no entries\n\n\t\t\n\t\tdbConnect.setQuery(query);\n\t\ttry {\n\t\t\tdbConnect.setInsertData();\n\t\t} //end the try block\n\t\tcatch (Exception e) \n\t\t{\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}//end the catch block\n\t\t\n\t\t\n\n\t\t\n\t\t// may need a loop here..\n\t\taccess_result=\"\";\n\t\tdo \n\t\t{\n\t\t\t// call the control class for the welcome\n\t\t\t// return the access_result to determine the result\n\t\t\tWecomeControl.getAccessManWecome();\n\t\t\taccess_result=WecomeControl.access_outcome();\n\t\t\tclear_console_screen();\n\n\n\t\t} while (access_result!=\"logged_in\");\n\n\t\t//complete the log in process\n\t\t\n\t\t/*\n\t\t * retrieve from the session table the role of the logged in user\n\t\t * select the role from the session table where the login_status= logged_in\n\t\t * This is stored on the local variable 'role'\n\t\t */\n\t\tquery=\"select role from session where login_status=\"+ \"\\'logged_in\\'\";\n\t\trole=\"\";\n\t\t// set initial state to NUL value.\n\t\tdbConnect.setQuery(query);\n\t\ttry \n\t\t{\n\t\t\tresult=dbConnect.getResults();\n\t\t\twhile(result.next())\n\t\t\t{\n\t\t\t\trole=result.getString(\"Role\");\t\t\t\t\n\t\t\t\t//store the value of the role\n\t\t\t}//close while statement\n\t\t}//end the try \n\t\tcatch (Exception e) \n\t\t{\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}//end the catch\n\t\t\n\t\t\n\t\t/*\n\t\t * Here we will have a do while loop\n\t\t * do\n\t\t * {\n\t\t * .. code\n\t\t * } while (access_result!=\"logged_out\");\n\t\t * This will loop around until \n\t\t * it via an accessor method calling the \n\t\t * relevant administrator_, coordinator_, lecturer_, student_ control/boundary \n\t\t * class changes access_result==\"logged_out\"\n\t\t * \n\t\t * \"student\",\"lecturer\", \"coordinator\", \"administrator\"\n\t\t * \n\t\t */\n\t\tdo\n\t\t{\n\t\t\t//insert a switch\n\t\t\t\n\t\t\tif (role.equals(\"administrator\"))\n\t\t\t{\t\n\t\t\t\t// hand off to the administrator control and boundary class\n\t\t\t\t// check the access_result from the administrator control\n\t\t\t\t// if this has not changed from \"logged_in\" to \"logged_out\"\n\t\t\t\t\n\t\t\t\tControl020AdminCMS AdminCMSControl=new Control020AdminCMS();\n\t\t\t\tAdminCMSControl.CMSApplicationAdministrationManagementControl();\n\t\t\t\taccess_result= AdminCMSControl.getLogout_choice();\n\t\t\t\t\n\t\t\t\t//break;\n\t\t\t}// end if (role.equals(\"administrator\"))\n\t\t\telse if (role.equals(\"coordinator\"))\n\t\t\t{\t\n\t\t\t\t// hand off to the coordinator control and boundary class\n\t\t\t\t// check the access_result from the coordinator control\n\t\t\t\t// if this has not changed from \"logged_in\" to \"logged_out\"\n\t\t\t\t\n\t\t\t\t//insert app code for \"coordinator\"\n\t\t\t\t\n\t\t\t\t//diagnotic\n\t\t\t\t//System.out.println(\"hand off to the coordinator control class\");\n\t\t\t\t\n\t\t\t\t//break;\n\t\t\t}// end if (role.equals(\"coordinator\"))\t\n\t\t\t\n\t\t\telse if (role.equals(\"lecturer\"))\n\t\t\t{\t\n\t\t\t\t// hand off to the lecturer control and boundary class\n\t\t\t\t// check the access_result from the lecturer control\n\t\t\t\t// if this has not changed from \"logged_in\" to \"logged_out\"\n\t\t\t\t\n\t\t\t\t//insert app code for \"lecturer\"\n\t\t\t\t\n\t\t\t\t//diagnotic\n\t\t\t\tSystem.out.println(\"hand off to the lecturer control class\");\n\t\t\t\t\n\t\t\t\t//break;\n\t\t\t}// end if (role.equals(\"lecturer\"))\t\n\t\t\t\n\t\t\telse if (role.equals(\"student\"))\n\t\t\t{\t\n\t\t\t\t// hand off to the student control and boundary class\n\t\t\t\t// check the access_result from the student control\n\t\t\t\t// if this has not changed from \"logged_in\" to \"logged_out\"\n\t\t\t\t\n\t\t\t\t//insert app code for \"student\"\n\t\t\t\t\n\t\t\t\t//diagnotic\n\t\t\t\t//System.out.println(\"hand off to the student control class\");\n\t\t\t\t\n\t\t\t\t//break;\n\t\t\t}// end if (role.equals(\"student\"))\n\t\t\t\n\t\t\t\n\t\t}while (access_result!=\"logged_out\");\n\t\t\n\t\t// commence the logout process from here...\n\t\t/*\n\t\t * change the login_status in the session table from logged_in to logged_out\n\t\t * Update the End_Date_time with the date-time stamp of the session end\n\t\t * represent the welcome screen\n\t\t * \n\t\t */\n\t\tusName=\"\";\n\t\tquery=\"select UserName from session where login_status=\"+ \"\\'logged_in\\'\";\n\t\tdbConnect.setQuery(query);\n\t\ttry \n\t\t{\n\t\t\tresult=dbConnect.getResults();\n\t\t\twhile(result.next())\n\t\t\t{\n\t\t\t\tusName=result.getString(\"UserName\");\t\t\t\t\n\t\t\t\t//store the value of the role\n\t\t\t}//close while statement\n\t\t}//end the try \n\t\tcatch (Exception e) \n\t\t{\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}//end the catch\n\t\t\t\t\t\t\t\n\t\t// now lets enter the data-time for the session \n\t\t// end time\n\t\tjava.util.Date dt = new java.util.Date();\n\t\tjava.text.SimpleDateFormat sdf = new java.text.SimpleDateFormat(\"yyyy-MM-dd HH:mm:ss\");\n\t\tString currentTime = sdf.format(dt);\n\t\t\n\t\t\n\t\tquery=\"update session SET End_Date_time=\"+\"\\'\"+ currentTime +\"\\'\" \n\t\t+ \"where login_status=\"+ \"\\'logged_in\\'\"\n\t\t+ \"and username =\"+\"\\'\"+usName+\"\\'\";\n\t\t\t\n\t\t\n\t\tdbConnect.setQuery(query);\n\t\ttry {\n\t\t\tdbConnect.setInsertData();\n\t\t} //end the try block\n\t\tcatch (Exception e) \n\t\t{\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}//end the catch block\n\t\t\n\t\t//now change the status of the user from \"logged in\" to logged out\"\n\t\t\n\t\t\n\t\tquery=\"update session SET login_status=\" + \"\\'logged_out\\'\" \n\t\t\t\t+ \"where login_status=\"+ \"\\'logged_in\\'\"\n\t\t\t\t+ \"and username =\"+\"\\'\"+usName+\"\\'\";\t\n\t\t\n\t\tdbConnect.setQuery(query);\n\t\ttry {\n\t\t\tdbConnect.setInsertData();\n\t\t} //end the try block\n\t\tcatch (Exception e) \n\t\t{\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}//end the catch block\n\t\t\n\n\t\n\t\t\n\t\t\n\t}", "@Import(\"name\")\n\tString getName();", "java.util.concurrent.Future<StartImportTaskResult> startImportTaskAsync(StartImportTaskRequest startImportTaskRequest);", "@Test\n public void shouldListActivatorsInSourceCode() throws Exception {\n initializeOSGiProjectWithBundlesInSourceCode();\n resetOutput();\n getShell().execute(\"osgi activators\");\n String mod1Expected = \"/main/src/module1/br/ufrgs/rmpestano/activator/Activator.java\";\n String mod2Expected = \"/main/src/module2/br/ufrgs/rmpestano/activator/Activator.java\";\n String mod3Expected = \"/main/src/module3/src/br/ufrgs/rmpestano/activator/Activator.java\";\n if(OSUtils.isWindows()){\n mod1Expected = mod1Expected.replaceAll(\"/\", File.separator + File.separator);\n mod2Expected = mod2Expected.replaceAll(\"/\", File.separator + File.separator);\n mod3Expected = mod3Expected.replaceAll(\"/\", File.separator + File.separator);\n }\n getOutput().contains(mod1Expected);\n getOutput().contains(mod2Expected);\n getOutput().contains(mod3Expected);\n\n\n }", "public abstract String getImportFromFileTemplate( );", "SpaceinvadersPackage getSpaceinvadersPackage();", "public interface Ast {\n /**\n * Method for generating abstract syntactic structure for the source code\n * written in a programming language(Java or Python for example)\n */\n void genAst();\n\n}", "TypeImport createTypeImport();", "public void exportAllLists(){\n }", "ComponentmodelPackage getComponentmodelPackage();", "@Override\n public String generareSourcecodetoReadInputFromFile() throws Exception {\n String typeVar = VariableTypes.deleteStorageClasses(this.getType())\n .replace(IAbstractDataNode.REFERENCE_OPERATOR, \"\");\n // Ex: A::B, ::B. We need to get B\n if (typeVar.contains(\"::\"))\n typeVar = typeVar.substring(typeVar.lastIndexOf(\"::\") + 2);\n\n String loadValueStm = \"data.findStructure\" + typeVar + \"ByName\" + \"(\\\"\" + getVituralName() + \"\\\")\";\n\n String fullStm = typeVar + \" \" + this.getVituralName() + \"=\" + loadValueStm + SpecialCharacter.END_OF_STATEMENT;\n return fullStm;\n }", "org.hyperledger.fabric.protos.token.Transaction.PlainImport getPlainImport();", "public static void main(String[] args) throws Exception {\n CalciteConnection connection = new SimpleCalciteConnection();\n String salesSchema = Resources.toString(SimpleQueryPlanner2.class.getResource(\"/sales.json\"), Charset.defaultCharset());\n // ModelHandler reads the sales schema and load the schema to connection's root schema and sets the default schema\n new ModelHandler(connection, \"inline:\" + salesSchema);\n\n // Create the query planner with sales schema. conneciton.getSchema returns default schema name specified in sales.json\n SimpleQueryPlanner2 queryPlanner = new SimpleQueryPlanner2(connection.getRootSchema().getSubSchema(connection.getSchema()));\n RelNode logicalPlan = queryPlanner.getLogicalPlan(\"select id,product from orders where product='paint' and units>=5\");\n System.out.println(logicalPlan.getDescription());\n System.out.println(RelOptUtil.toString(logicalPlan));\n\n System.out.println(\"======================================\");\n\n queryPlanner = new SimpleQueryPlanner2(connection.getRootSchema().getSubSchema(connection.getSchema()));\n //RelNode plan = queryPlanner.getTRel(\"select id,product from orders where product='paint' and units>=5\"); // TODO 报错\n RelNode plan = queryPlanner.getTRel(\"select id,product from orders\");\n System.out.println(RelOptUtil.toString(plan));\n ((TRel) plan).doSomething(0);\n }", "void genAst();", "public void testDynamicImport() throws Exception {\n\t\tdoTest(\";version=\\\"[1,2)\\\"\", TEST_ALT_IMPORT_SYM_NAME + \"_1.0.0\");\n\t}", "public final PythonParser.import_stmt_return import_stmt() throws RecognitionException {\n PythonParser.import_stmt_return retval = new PythonParser.import_stmt_return();\n retval.start = input.LT(1);\n\n PythonTree root_0 = null;\n\n PythonParser.import_name_return import_name102 = null;\n\n PythonParser.import_from_return import_from103 = null;\n\n\n\n try {\n // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:769:5: ( import_name | import_from )\n int alt48=2;\n int LA48_0 = input.LA(1);\n\n if ( (LA48_0==IMPORT) ) {\n alt48=1;\n }\n else if ( (LA48_0==FROM) ) {\n alt48=2;\n }\n else {\n if (state.backtracking>0) {state.failed=true; return retval;}\n NoViableAltException nvae =\n new NoViableAltException(\"\", 48, 0, input);\n\n throw nvae;\n }\n switch (alt48) {\n case 1 :\n // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:769:7: import_name\n {\n root_0 = (PythonTree)adaptor.nil();\n\n pushFollow(FOLLOW_import_name_in_import_stmt2839);\n import_name102=import_name();\n\n state._fsp--;\n if (state.failed) return retval;\n if ( state.backtracking==0 ) adaptor.addChild(root_0, import_name102.getTree());\n\n }\n break;\n case 2 :\n // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:770:7: import_from\n {\n root_0 = (PythonTree)adaptor.nil();\n\n pushFollow(FOLLOW_import_from_in_import_stmt2847);\n import_from103=import_from();\n\n state._fsp--;\n if (state.failed) return retval;\n if ( state.backtracking==0 ) adaptor.addChild(root_0, import_from103.getTree());\n\n }\n break;\n\n }\n retval.stop = input.LT(-1);\n\n if ( state.backtracking==0 ) {\n\n retval.tree = (PythonTree)adaptor.rulePostProcessing(root_0);\n adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop);\n }\n }\n\n catch (RecognitionException re) {\n errorHandler.reportError(this, re);\n errorHandler.recover(this, input,re);\n retval.tree = (PythonTree)adaptor.errorNode(input, retval.start, input.LT(-1), re);\n }\n finally {\n }\n return retval;\n }", "public interface ITaskMapPipeModel {\n}", "public static void main(String args[]) {\n Model model = ModelFactory.createDefaultModel(); \n\n//set namespace\n Resource NAMESPACE = model.createResource( relationshipUri );\n \tmodel.setNsPrefix( \"rela\", relationshipUri);\n \n// Create the types of Property we need to describe relationships in the model\n Property childOf = model.createProperty(relationshipUri,\"childOf\"); \n Property siblingOf = model.createProperty(relationshipUri,\"siblingOf\");\n Property spouseOf = model.createProperty(relationshipUri,\"spouseOf\");\n Property parentOf = model.createProperty(relationshipUri,\"parentOf\"); \n \n \n// Create resources representing the people in our model\n Resource Siddharth = model.createResource(familyUri+\"Siddharth\");\n Resource Dhvanit = model.createResource(familyUri+\"Dhvanit\");\n Resource Rekha = model.createResource(familyUri+\"Rekha\");\n Resource Sandeep = model.createResource(familyUri+\"Sandeep\");\n Resource Kanchan = model.createResource(familyUri+\"Kanchan\");\n Resource Pihu = model.createResource(familyUri+\"Pihu\");\n Resource DwarkaPrasad = model.createResource(familyUri+\"Dwarkesh\");\n Resource Shakuntala = model.createResource(familyUri+\"Shakuntala\");\n Resource Santosh = model.createResource(familyUri+\"Santosh\");\n Resource Usha = model.createResource(familyUri+\"Usha\");\n Resource Priyadarshan = model.createResource(familyUri+\"Priyadarshan\");\n Resource Sudarshan = model.createResource(familyUri+\"Sudarshan\");\n Resource Pragya = model.createResource(familyUri+\"Pragya\");\n Resource Shailendra = model.createResource(familyUri+\"Shailendra\");\n Resource Rajni = model.createResource(familyUri+\"Rajni\");\n Resource Harsh = model.createResource(familyUri+\"Harsh\");\n Resource Satendra = model.createResource(familyUri+\"Satendra\");\n Resource Vandana = model.createResource(familyUri+\"Vandana\");\n Resource Priyam = model.createResource(familyUri+\"Priyam\");\n Resource Darshan = model.createResource(familyUri+\"Darshan\");\n Resource Vardhan = model.createResource(familyUri+\"Vardhan\");\n \n List<Statement> list = new ArrayList(); \n list.add(model.createStatement(Dhvanit,spouseOf,Kanchan)); \n list.add(model.createStatement(Sandeep,spouseOf,Rekha)); \n list.add(model.createStatement(DwarkaPrasad,spouseOf,Shakuntala)); \n list.add(model.createStatement(Santosh,spouseOf,Usha)); \n list.add(model.createStatement(Shailendra,spouseOf,Rajni)); \n list.add(model.createStatement(Satendra,spouseOf,Vandana)); \n list.add(model.createStatement(Sandeep,childOf,DwarkaPrasad)); \n list.add(model.createStatement(Sandeep,childOf,Shakuntala)); \n list.add(model.createStatement(Santosh,childOf,DwarkaPrasad)); \n list.add(model.createStatement(Santosh,childOf,Shakuntala)); \n list.add(model.createStatement(Shailendra,childOf,DwarkaPrasad)); \n list.add(model.createStatement(Shailendra,childOf,Shakuntala)); \n list.add(model.createStatement(Satendra,childOf,DwarkaPrasad)); \n list.add(model.createStatement(Satendra,childOf,Shakuntala)); \n list.add(model.createStatement(DwarkaPrasad,parentOf,Sandeep)); \n list.add(model.createStatement(DwarkaPrasad,parentOf,Santosh)); \n list.add(model.createStatement(DwarkaPrasad,parentOf,Shailendra)); \n list.add(model.createStatement(DwarkaPrasad,parentOf,Satendra)); \n list.add(model.createStatement(Shakuntala,parentOf,Sandeep)); \n list.add(model.createStatement(Shakuntala,parentOf,Santosh)); \n list.add(model.createStatement(Shakuntala,parentOf,Shailendra)); \n list.add(model.createStatement(Shakuntala,parentOf,Satendra)); \n list.add(model.createStatement(Sandeep,parentOf,Siddharth)); \n list.add(model.createStatement(Sandeep,parentOf,Dhvanit)); \n list.add(model.createStatement(Rekha,parentOf,Siddharth)); \n list.add(model.createStatement(Rekha,parentOf,Dhvanit)); \n list.add(model.createStatement(Siddharth,childOf,Rekha)); \n list.add(model.createStatement(Dhvanit,childOf,Rekha)); \n list.add(model.createStatement(Siddharth,childOf,Sandeep)); \n list.add(model.createStatement(Dhvanit,childOf,Sandeep)); \n list.add(model.createStatement(Harsh,childOf,Shailendra)); \n list.add(model.createStatement(Harsh,childOf,Rajni)); \n list.add(model.createStatement(Shailendra,parentOf,Harsh)); \n list.add(model.createStatement(Rajni,parentOf,Harsh)); \n list.add(model.createStatement(Santosh,parentOf,Priyadarshan)); \n list.add(model.createStatement(Santosh,parentOf,Sudarshan));\n list.add(model.createStatement(Santosh,parentOf,Pragya));\n list.add(model.createStatement(Usha,parentOf,Priyadarshan)); \n list.add(model.createStatement(Usha,parentOf,Sudarshan));\n list.add(model.createStatement(Usha,parentOf,Pragya));\n list.add(model.createStatement(Priyadarshan,childOf,Santosh));\n list.add(model.createStatement(Pragya,childOf,Santosh));\n list.add(model.createStatement(Sudarshan,childOf,Santosh));\n list.add(model.createStatement(Priyadarshan,childOf,Usha));\n list.add(model.createStatement(Pragya,childOf,Usha));\n list.add(model.createStatement(Sudarshan,childOf,Usha));\n list.add(model.createStatement(Satendra,parentOf,Priyam)); \n list.add(model.createStatement(Satendra,parentOf,Darshan));\n list.add(model.createStatement(Satendra,parentOf,Vardhan));\n list.add(model.createStatement(Vandana,parentOf,Priyam)); \n list.add(model.createStatement(Vandana,parentOf,Darshan));\n list.add(model.createStatement(Vandana,parentOf,Vardhan));\n list.add(model.createStatement(Priyam,childOf,Satendra));\n list.add(model.createStatement(Darshan,childOf,Satendra));\n list.add(model.createStatement(Vardhan,childOf,Satendra));\n list.add(model.createStatement(Priyam,childOf,Vandana));\n list.add(model.createStatement(Darshan,childOf,Vandana));\n list.add(model.createStatement(Vardhan,childOf,Vandana));\n list.add(model.createStatement(Pihu,childOf,Dhvanit));\n list.add(model.createStatement(Pihu,childOf,Kanchan));\n list.add(model.createStatement(Dhvanit,parentOf,Pihu));\n list.add(model.createStatement(Kanchan,parentOf,Pihu));\n list.add(model.createStatement(Siddharth,siblingOf,Dhvanit));\n list.add(model.createStatement(Dhvanit,siblingOf,Siddharth)); \n list.add(model.createStatement(Priyadarshan,siblingOf,Sudarshan));\n list.add(model.createStatement(Priyadarshan,siblingOf,Pragya));\n list.add(model.createStatement(Sudarshan,siblingOf,Priyadarshan));\n list.add(model.createStatement(Sudarshan,siblingOf,Pragya));\n list.add(model.createStatement(Pragya,siblingOf,Priyadarshan));\n list.add(model.createStatement(Pragya,siblingOf,Sudarshan)); \n list.add(model.createStatement(Priyam,siblingOf,Darshan));\n list.add(model.createStatement(Priyam,siblingOf,Vardhan)); \n list.add(model.createStatement(Darshan,siblingOf,Vardhan)); \n list.add(model.createStatement(Darshan,siblingOf,Priyam));\n list.add(model.createStatement(Vardhan,siblingOf,Priyam));\n list.add(model.createStatement(Vardhan,siblingOf,Darshan));\n list.add(model.createStatement(Santosh,siblingOf,Sandeep));\n list.add(model.createStatement(Santosh,siblingOf,Shailendra));\n list.add(model.createStatement(Santosh,siblingOf,Satendra));\n list.add(model.createStatement(Sandeep,siblingOf,Santosh));\n list.add(model.createStatement(Sandeep,siblingOf,Shailendra));\n list.add(model.createStatement(Sandeep,siblingOf,Satendra));\n list.add(model.createStatement(Shailendra,siblingOf,Santosh));\n list.add(model.createStatement(Shailendra,siblingOf,Sandeep));\n list.add(model.createStatement(Shailendra,siblingOf,Satendra));\n list.add(model.createStatement(Satendra,siblingOf,Shailendra));\n list.add(model.createStatement(Satendra,siblingOf,Santosh));\n list.add(model.createStatement(Satendra,siblingOf,Sandeep));\n \n model.add(list);\n try{\n \t File file=new File(\"/Users/siddharthgupta/Documents/workspace/FamilyModel/src/family/family.rdf\");\n \t \tFileOutputStream f1=new FileOutputStream(file);\n \t \tRDFWriter d = model.getWriter(\"RDF/XML-ABBREV\");\n \t \t\t\td.write(model,f1,null);\n \t\t}catch(Exception e) {}\n }", "@Mapper\npublic interface RoleMapper {\n @Insert(\"insert into T_Role(rname) values (#{rolename})\")\n int insertRole(@Param(\"rolename\") String rolename);\n\n @Update(\"update T_Role set rname=#{rolename} where rid=#{rid}\")\n int updateRole(@Param(\"rolename\") String rolename, String rid);\n\n @Delete(\"delete from T_Role where rid=#{rid}\")\n int deleteRole(@Param(\"rid\")String rid);\n\n @Select(\"select * from T_Role\")\n List<Role> listRole(int pageSize, int offset);\n}", "interface ImportService {\n /**\n * Main import method.\n */\n void doImport();\n}", "public interface RoleMapper {\n\n @Insert(\"insert into role values (role,desc) values (#{model.role},#{model.desc})\")\n @Options(useGeneratedKeys = true,keyProperty = \"model.id\")\n int insertRole(@Param(\"model\") RoleModel model);\n\n\n /**\n * 获取所有角色信息\n * @return\n */\n @Select(\"select id,role,desc,data_added,last_modified from role\")\n List<RoleModel> getAllRoles();\n\n\n /**\n * 获取角色Id\n * @param role\n * @return\n */\n @Select(\"select id from role where role=#{role}\")\n int getRoleId(String role);\n}", "private ExportUsers() {}", "private void ImportLibrary(){\n for(int i = 0; i < refact.size(); i++){\n if(refact.get(i).contains(\"import\")){\n for(String library : libraries){\n refact.add(i, library + \"\\r\");\n }\n break;\n }\n }\n\n\n }", "@Test\n\tpublic void Leads_17972_execute() throws Exception {\n\t\tVoodooUtils.voodoo.log.info(\"Running \" + testName + \"...\"); \n\n\t\tsugar().leads.navToListView();\n\t\tsugar().leads.listView.clickRecord(1);\n\n\t\t// TODO: VOOD-598. Once it is fixed, please update the following steps\n\t\t// Select Tasks module in Related \n\t\tnew VoodooControl(\"i\", \"css\", \"span.select2-chosen i.fa-caret-down\").click();\n\t\tnew VoodooControl(\"li\", \"css\", \"ul.select2-results li:nth-child(4)\").click();\n\n\t\t// Click on + in Tasks to create a Task record\n\t\tStandardSubpanel taskRecord = sugar().leads.recordView.subpanels.get(sugar().tasks.moduleNamePlural);\n\t\ttaskRecord.addRecord();\n\t\t// Create a Task record\n\t\tsugar().tasks.createDrawer.setFields(myTasks);\n\t\tsugar().tasks.createDrawer.save();\n\n\t\t// Verify the Task record is appearing in Tasks sub panel\n\t\tFieldSet fs = new FieldSet();\n\t\tfs.put(\"subject\", myTasks.get(\"subject\"));\n\t\ttaskRecord.verify(1,fs , true);\n\n\t\t// Return back to default Filter\n\t\tnew VoodooControl(\"i\", \"css\", \"span.select2-chosen i.fa-caret-down\").click();\n\t\tnew VoodooControl(\"li\", \"css\", \"ul.select2-results li:first-child\").click();\n\n\t\tVoodooUtils.voodoo.log.info(testName + \"complete.\"); \n\t}", "public void testAttributeConstrainedDynamicImport() throws Exception {\n\t\tdoTest(\";foo=bar\", TEST_IMPORT_SYM_NAME + \"_1.0.0\");\n\t}", "@Mapper\npublic interface RoleMapper extends BaseMapper<RoleEntity>{\n @Select(\"select * from role\")\n List<RoleEntity> selectAllRole();\n @Select(\"select * from role where role_name like CONCAT('%',#{role_name},'%')\")\n List<RoleEntity>selectRoleName(String role_name);\n @Select(\"select * from role where role_name = #{roleName}\")\n RoleEntity selectRoleOne(@Param(\"roleName\")String roleName);\n}", "public static void main (String[] args){\n\t\t Model model1 = ModelFactory.createDefaultModel();\n\t\t Model model2 = ModelFactory.createDefaultModel();\n\t\t // use the FileManager to find the input file\n\t\t InputStream in1 = FileManager.get().open( \"D:\\\\eclipse\\\\carta-de-exigencia-cetesb.rdf\" );\n\t\t InputStream in2 = FileManager.get().open( \"D:\\\\eclipse\\\\liminar-contra-a-usp.rdf\" );\n\t\tif (in1 == null || in2 ==null) {\n\t\t throw new IllegalArgumentException(\n\t\t \"File: \" + \"D:\\\\eclipse\\\\carta-de-exigencia-cetesb.rdf\" + \" not found\");\n\t\t}\n\n\t\t// read the RDF/XML file\n\t\tmodel1.read(in1, null);\n\t\tmodel2.read(new InputStreamReader (in2), \"\");\n\t\tModel model = model1.union(model2);\n\n\t\tmodel.write(System.out);\n\t\t// write it to standard out\n\t\t//model1.write(System.out);\n\t\t//model1.read(new InputStreamReader(in1 ), \"\"); \n\t}", "public interface ImportExport {\n public String exportUserDataAsString(Users users) throws Exception;\n public File exportUserDataAsFile(Users users)throws Exception;\n public Users importUserData() throws Exception;\n}", "public static void main(String[] args) {\n\t\tlogger.info(\"IAM import started at \" + new Date());\n\n\t\tif(SettingsUtils.initialize() == false) {\n\t\t\tlogger.error(\"Unable to load settings. Cannot proceed.\");\n\t\t\tSystem.exit(1);\n\t\t}\n\n\t\tlong startTime = new Date().getTime();\n\n\t\t/**\n\t\t * Set up Hibernate\n\t\t */\n\t\ttry {\n\t\t\t// override persistence.xml at runtime\n\t\t\tMap<String, Object> configOverrides = new HashMap<String, Object>();\n\t\t\tconfigOverrides.put(\"javax.persistence.jdbc.url\", System.getenv(\"DW_SYNC_IAM_JDBC_URL\"));\n\t\t\tconfigOverrides.put(\"javax.persistence.jdbc.user\", System.getenv(\"DW_SYNC_IAM_JDBC_USER\"));\n\t\t\tconfigOverrides.put(\"javax.persistence.jdbc.password\", System.getenv(\"DW_SYNC_IAM_JDBC_PASSWORD\"));\n\n\t\t\tentityManagerFactory = Persistence.createEntityManagerFactory(\"edu.ucdavis.dss.datawarehouse.sync.iam\", configOverrides);\n\t\t} catch (ServiceException e) {\n\t\t\tlogger.error(\"Unable to create entity manager factory. Is the database running?\");\n\t\t\tSystem.exit(-1);\n\t\t}\n\n\t\tStatusLogger.markIamLastAttempt(entityManagerFactory);\n\t\tif (shouldImportPPSDepartments) {\n\t\t\tlogger.debug(\"Importing PPS departments ...\");\n\n\t\t\tif(IamPpsDepartmentsImport.importPpsDepartments(entityManagerFactory) == false) {\n\t\t\t\tlogger.error(\"Unable to import PPS departments! Will continue ...\");\n\t\t\t}\n\t\t}\n\n\t\tif (shouldImportBOUs) {\n\t\t\tlogger.debug(\"Importing BOUs ...\");\n\n\t\t\tif(IamPpsDepartmentsImport.importBous(entityManagerFactory) == false) {\n\t\t\t\tlogger.error(\"Unable to import BOUs! Will continue ...\");\n\t\t\t}\n\t\t}\n\n\t\t// Pass list through a HashSet to ensure list if unique (as of 12/2019, it contained duplicates)\n\t\tList<String> allIamIds = new ArrayList<String>(new HashSet<String>(IamIdsImport.importIds()));\n\n\t\tlogger.info(\"Persisting \" + allIamIds.size() + \" people ...\");\n\n\t\tif(shouldImportFromIam) {\n\t\t\tList<Thread> threads = new ArrayList<Thread>();\n\n\t\t\tList<List<String>> chunkedIamIds = chunkList(allIamIds, recordsPerThread);\n\t\t\tfor (List<String> iamIds : chunkedIamIds) {\n\t\t\t\tThread t = new Thread(new IamPersonImportThread(iamIds, entityManagerFactory));\n\t\t\t\tt.setUncaughtExceptionHandler(uncaughtException);\n\t\t\t\tthreads.add(t);\n\t\t\t}\n\n\t\t\tlogger.debug(\"Queued \" + threads.size() + \" threads of size \" + recordsPerThread);\n\n\t\t\t/**\n\t\t\t * Convert all ucdPersonUUIDs to IAM IDs and fetch associated information\n\t\t\t */\n\t\t\tint activeThreads = 0;\n\n\t\t\t// Start as many threads as possible (limited by maxThreads).\n\t\t\t// If we have too many threads, the while loop below will\n\t\t\t// start them once other threads finish.\n\t\t\tfor (Thread t : threads) {\n\t\t\t\tif (activeThreads < maxThreads) {\n\t\t\t\t\tt.start();\n\t\t\t\t\tactiveThreads++;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Ensure all threads get a chance to run and\n\t\t\t// loop until all threads have finished.\n\t\t\twhile (threads.size() > 0) {\n\t\t\t\tIterator<Thread> iter = threads.iterator();\n\n\t\t\t\tlogger.debug(\"Threads remaining: \" + threads.size());\n\n\t\t\t\twhile (iter.hasNext()) {\n\t\t\t\t\tThread t = iter.next();\n\n\t\t\t\t\tif (t.isAlive()) {\n\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\tt.join(500);\n\t\t\t\t\t\t} catch (InterruptedException e) {\n\t\t\t\t\t\t\tlogger.warn(\"t.join(); was interrupted:\");\n\t\t\t\t\t\t\tlogger.warn(ExceptionUtils.stacktraceToString(e));\n\t\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\t// If thread is terminated, remove it from the list.\n\t\t\t\t\t\tif (t.getState() == Thread.State.TERMINATED) {\n\t\t\t\t\t\t\tactiveThreads--;\n\t\t\t\t\t\t\titer.remove();\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (activeThreads < maxThreads) {\n\t\t\t\t\t\t\tif (t.getState() == Thread.State.NEW) {\n\t\t\t\t\t\t\t\tt.start();\n\t\t\t\t\t\t\t\tactiveThreads++;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// We ignore this task if the number of people is under 25,000. UCD should have at least 70,000 as of\n\t\t// 3-18-18 and the 25,000 check is to avoid a mistake where the import fails and we start deleting people.\n\t\tif(allIamIds.size() > 25000) {\n\t\t\t// Remove people (and their associated records) older than 'expireRecordsOlderThanDays' days\n\t\t\tesClient = new edu.ucdavis.dss.elasticsearch.ESClient(SettingsUtils.getElasticSearchHost());\n\n\t\t\tif ((entityManager != null) && (entityManager.isOpen())) {\n\t\t\t\tentityManager.close();\n\t\t\t}\n\t\t\tentityManager = entityManagerFactory.createEntityManager();\n\t\t\tentityManager.getTransaction().begin();\n\n\t\t\tDate expiration = new Date(System.currentTimeMillis() - (expireRecordsOlderThanDays * DAY_IN_MS));\n\t\t\tList<Long> expiredIamIds = entityManager.createQuery(\"SELECT ci.iamId FROM IamPerson ci WHERE (ci.lastSeen < :expiration) OR (ci.lastSeen is NULL)\")\n\t\t\t\t\t.setParameter(\"expiration\", expiration).getResultList();\n\n\t\t\tentityManager.getTransaction().commit();\n\n\t\t\tfor (Long iamId : expiredIamIds) {\n\t\t\t\tremoveAllRecordsForIamId(iamId, entityManager, esClient);\n\t\t\t}\n\n\t\t\t// Resolve the case where multiple IAM IDs exist for an individual\n\t\t\tList<String> duplicatedUserIds = entityManager.createNativeQuery(\"select userId from (SELECT userId, COUNT(*) c FROM iam_prikerbacct GROUP BY userId HAVING c > 1) s\").getResultList();\n\t\t\tfor (String userId: duplicatedUserIds) {\n\t\t\t\t// A user ID is associated with more than one IAM ID. Pick one.\n\n\t\t\t\t// First, if only one IAM ID is active in IAM, choose that one.\n\t\t\t\tList<BigInteger> redundantIamIds = (List<BigInteger>)entityManager.createNativeQuery(\"select iamId FROM iam_prikerbacct WHERE userId=:userId order by iamId ASC\").setParameter(\"userId\", userId).getResultList();\n\t\t\t\tList<Long> inactiveIamIds = new ArrayList<>();\n\t\t\t\tList<Long> activeIamIds = new ArrayList<>();\n\n\t\t\t\tfor(BigInteger _redundantIamId : redundantIamIds) {\n\t\t\t\t\tString redundantIamId = _redundantIamId.toString();\n\n\t\t\t\t\tif(allIamIds.contains(redundantIamId)) {\n\t\t\t\t\t\tactiveIamIds.add(Long.parseLong(redundantIamId));\n\t\t\t\t\t} else {\n\t\t\t\t\t\tinactiveIamIds.add(Long.parseLong(redundantIamId));\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif(activeIamIds.size() == 1) {\n\t\t\t\t\t// Only one of the multiple IAM IDs are active. Delete the others.\n\t\t\t\t\tinactiveIamIds.forEach(iamId -> removeAllRecordsForIamId(iamId, entityManager, esClient));\n\t\t\t\t} else {\n\t\t\t\t\t// Multiple IAM IDs are active for the same person. Favor the bigger one (presumed to be newer and correct)\n\n\t\t\t\t\t// Sort IAM IDs so largest (the keeper) is at the end\n\t\t\t\t\tCollections.sort(redundantIamIds);\n\n\t\t\t\t\t// Remove the last IAM ID (the keeper)\n\t\t\t\t\tredundantIamIds.remove(redundantIamIds.size() - 1);\n\n\t\t\t\t\tredundantIamIds.forEach(iamId -> removeAllRecordsForIamId(iamId.longValue(), entityManager, esClient));\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tentityManager.close();\n\t\t}\n\n\t\tStatusLogger.markIamLastSuccess(entityManagerFactory);\n\t\tStatusLogger.recordIamDuration(entityManagerFactory, (int)(new Date().getTime() - startTime) / 1000);\n\n\t\t/**\n\t\t * Close Hibernate\n\t\t */\n\t\tentityManagerFactory.close();\n\n\t\tlogger.info(\"Import completed successfully. Took \" + (float)(new Date().getTime() - startTime) / 1000.0 + \"s\");\n\t}", "private Cursor selectStatements(TransferObject feature) throws Exception {\r\n\t //ContentValues cv = new ContentValues(); \r\n\t List<FieldTO> fields = feature.getFields();\r\n\t String[] selectionArgs = new String[fields.size()];\r\n\t for (int i=0; i<fields.size();i++) {\r\n\t \tFieldTO fieldTO = fields.get(i);\r\n\t \tString name = fieldTO.getName();\r\n\t \tObject value = fieldTO.getValue();\r\n\t \tselectionArgs[i] = String.valueOf(value);\r\n\r\n\t\t}\r\n\t // return getDb().insert(getTableName(), null, cv);\r\n\t\tStatementFactory statement = new StatementFactory(feature);\r\n StringBuilder sqls = statement.createStatementSQL();\r\n Cursor c = getDb().rawQuery(sqls.toString(), selectionArgs);\r\n\t return c;\r\n\t}", "@io.vertigo.datamodel.task.proxy.TaskAnnotation(\r\n\t\t\tname = \"TkGetTopicIhmById\",\r\n\t\t\trequest = \"SELECT \ttop.top_id,\\n\" + \n \" \t\t\t\t\ttop.title,\\n\" + \n \" \t\t\t\t\ttop.code,\\n\" + \n \" \t\t\t\t\tsmt.smt_id,\\n\" + \n \" \t\t\t\t\tsin.sin_id,\\n\" + \n \" \t\t\t\t\ttop.is_enabled,\\n\" + \n \" \t\t\t\t\ttto.label as type,\\n\" + \n \" \t\t\t\t\ttop.tto_cd,\\n\" + \n \" \t\t\t\t\ttpc.label as cat_label,\\n\" + \n \" \t\t\t\t\tstring_agg(tpl.label, ',') as labels\\n\" + \n \" \t\t\tfrom topic top \\n\" + \n \" \t\t\tleft join small_talk smt on smt.top_id = top.top_id\\n\" + \n \" \t\t\tleft join script_intention sin on sin.top_id = top.top_id\\n\" + \n \" \t\t\tjoin type_topic tto on top.tto_cd = tto.tto_cd\\n\" + \n \" \t\t\tjoin topic_category tpc on (tpc.top_cat_id = top.top_cat_id)\\n\" + \n \" \t\t\tleft join topic_topic_label ttl on (ttl.top_id = top.top_id)\\n\" + \n \" \t\t\tleft join topic_label tpl on (tpl.label_id = ttl.label_id)\\n\" + \n \" \t\t\twhere top.top_id = #topId#\\n\" + \n \" \t\t\tgroup by top.top_id,\\n\" + \n \" \t\t\t\t\ttop.title,\\n\" + \n \" \t\t\t\t\ttop.code,\\n\" + \n \" \t\t\t\t\tsmt.smt_id,\\n\" + \n \" \t\t\t\t\tsin.sin_id,\\n\" + \n \" \t\t\t\t\ttop.is_enabled,\\n\" + \n \" \t\t\t\t\ttto.label ,\\n\" + \n \" \t\t\t\t\ttop.tto_cd,\\n\" + \n \" \t\t\t\t\ttpc.label\\n\" + \n \" \t\t\t\\n\" + \n \" \t\t\tLIMIT 1\",\r\n\t\t\ttaskEngineClass = io.vertigo.basics.task.TaskEngineSelect.class)\r\n\[email protected](smartType = \"STyDtTopicIhm\")\r\n\tpublic io.vertigo.chatbot.commons.domain.topic.TopicIhm getTopicIhmById(@io.vertigo.datamodel.task.proxy.TaskInput(name = \"topId\", smartType = \"STyId\") final Long topId) {\r\n\t\tfinal Task task = createTaskBuilder(\"TkGetTopicIhmById\")\r\n\t\t\t\t.addValue(\"topId\", topId)\r\n\t\t\t\t.build();\r\n\t\treturn getTaskManager()\r\n\t\t\t\t.execute(task)\r\n\t\t\t\t.getResult();\r\n\t}", "public interface ModuleMapper {\n String menuList(@Param(\"roleId\") Integer roleId\n , @Param(\"groupId\") Integer groupId\n , @Param(\"passportId\") Integer passportId);\n}", "ImportedPackage createImportedPackage();", "public static void main(String args[]){\n //---------------------------------------------------------------------------\n SQLTagsGeneratorTable sqlTagsGeneratorTable=new SQLTagsGeneratorTable();\n ClassVariables classVariables=new ClassVariables(sqlTagsGeneratorTable);\n System.out.println(classVariables.getClassVariablesMethods());\n\t}", "void pramitiTechTutorials() {\n\t\n}", "@io.vertigo.datamodel.task.proxy.TaskAnnotation(\r\n\t\t\tname = \"TkGetAllTopicsIhmFromBot\",\r\n\t\t\trequest = \"SELECT \ttop.top_id,\\n\" + \n \" \t\t\t\t\ttop.title,\\n\" + \n \" \t\t\t\t\ttop.code,\\n\" + \n \" \t\t\t\t\tsmt.smt_id,\\n\" + \n \" \t\t\t\t\tsin.sin_id,\\n\" + \n \" \t\t\t\t\ttop.is_enabled,\\n\" + \n \" \t\t\t\t\tCASE #locale#\\n\" + \n \" \t\t\t\t\t\tWHEN 'fr_FR' THEN tto.label_fr\\n\" + \n \" \t\t\t\t\t\tELSE tto.label\\n\" + \n \" \t\t\t\t\tEND as type,\\n\" + \n \" \t\t\t\t\ttop.tto_cd,\\n\" + \n \" \t\t\t\t\ttpc.label as cat_label,\\n\" + \n \" \t\t\t\t\tstring_agg(tpl.label, ',') as labels\\n\" + \n \" \t\t\tfrom topic top \\n\" + \n \" \t\t\tleft join small_talk smt on smt.top_id = top.top_id\\n\" + \n \" \t\t\tleft join script_intention sin on sin.top_id = top.top_id\\n\" + \n \" \t\t\tjoin type_topic tto on top.tto_cd = tto.tto_cd\\n\" + \n \" \t\t\tjoin topic_category tpc on (tpc.top_cat_id = top.top_cat_id)\\n\" + \n \" \t\t\tleft join topic_topic_label ttl on (ttl.top_id = top.top_id)\\n\" + \n \" \t\t\tleft join topic_label tpl on (tpl.label_id = ttl.label_id)\\n\" + \n \" \t\t\twhere top.bot_id = #botId#\\n\" + \n \" \t\t\t<% if (ktoCds != null){ %>\\n\" + \n \" \t\t\t\tand top.kto_cd in (#ktoCds.rownum#)\\n\" + \n \" \t\t\t<% } %>\\n\" + \n \" \t\t\tgroup by top.top_id,\\n\" + \n \" \t\t\t\t\ttop.title,\\n\" + \n \" \t\t\t\t\ttop.code,\\n\" + \n \" \t\t\t\t\tsmt.smt_id,\\n\" + \n \" \t\t\t\t\tsin.sin_id,\\n\" + \n \" \t\t\t\t\ttop.is_enabled,\\n\" + \n \" \t\t\t\t\ttto.label,\\n\" + \n \" \t\t\t\t\ttto.label_fr,\\n\" + \n \" \t\t\t\t\ttop.tto_cd,\\n\" + \n \" \t\t\t\t\ttpc.label\",\r\n\t\t\ttaskEngineClass = io.vertigo.basics.task.TaskEngineSelect.class)\r\n\[email protected](smartType = \"STyDtTopicIhm\")\r\n\tpublic io.vertigo.datamodel.structure.model.DtList<io.vertigo.chatbot.commons.domain.topic.TopicIhm> getAllTopicsIhmFromBot(@io.vertigo.datamodel.task.proxy.TaskInput(name = \"botId\", smartType = \"STyId\") final Long botId, @io.vertigo.datamodel.task.proxy.TaskInput(name = \"ktoCds\", smartType = \"STyCode\") final java.util.List<String> ktoCds, @io.vertigo.datamodel.task.proxy.TaskInput(name = \"locale\", smartType = \"STyCode\") final String locale) {\r\n\t\tfinal Task task = createTaskBuilder(\"TkGetAllTopicsIhmFromBot\")\r\n\t\t\t\t.addValue(\"botId\", botId)\r\n\t\t\t\t.addValue(\"ktoCds\", ktoCds)\r\n\t\t\t\t.addValue(\"locale\", locale)\r\n\t\t\t\t.build();\r\n\t\treturn getTaskManager()\r\n\t\t\t\t.execute(task)\r\n\t\t\t\t.getResult();\r\n\t}", "public interface BackTestOperation {\n\n\n @Select( \"SELECT * FROM ${listname}\")\n public ArrayList<BackTestDailyResultPo> getResult(@Param(\"listname\") String resultid);\n\n @Select(\" SELECT resultid FROM backtesting WHERE userid = #{0,jdbcType=BIGINT} AND sid = #{1,jdbcType=BIGINT} AND start = #{2,jdbcType=LONGVARCHAR}\\n\" +\n \" AND end = #{3,jdbcType=LONGVARCHAR}\")\n public String getResultid(String userid, String strategyid, String startdate, String enddate);\n}", "public static void main(String[] args) throws Exception{\n\t\tMySqlStyle style = new MySqlStyle();\n//\t\tOracleStyle style = new OracleStyle();\n\t\t\n\t\tMySqlConnectoinSource cs = new MySqlConnectoinSource();\n\t\tSQLLoader loader = new ClasspathLoader(\"/org/beetl/sql/test\");\n\t\t\n\t\tInterceptor[] inters = new Interceptor[]{ new DebugInterceptor()};\n\t\tSQLManager \tsql = new SQLManager(style,loader,cs,new UnderlinedNameConversion(), inters);\n\t\t\n\t\tUserDao dao = sql.getMapper(UserDao.class);\n\t\tdao.getIds3();\n\t\t\n\t\n\t\t\t\n\t}", "public static void main(String[] args) {\n\n try ( LLModel gptjModel = new LLModel(Path.of(\"C:\\\\Users\\\\felix\\\\AppData\\\\Local\\\\nomic.ai\\\\GPT4All\\\\ggml-gpt4all-j-v1.3-groovy.bin\")) ){\n\n LLModel.GenerationConfig config = LLModel.config()\n .withNPredict(4096).build();\n\n // String result = gptjModel.generate(prompt, config, true);\n gptjModel.chatCompletion(\n List.of(Map.of(\"role\", \"system\", \"content\", \"You are a helpful assistant\"),\n Map.of(\"role\", \"user\", \"content\", \"Add 2+2\")), config, true, true);\n\n\n } catch (Exception e) {\n throw new RuntimeException(e);\n }\n }", "public static void main(String[] args) {\n\t\tString email = \"[email protected]\";\n\t\tString password = \"vikas1590\";\n\t\tString role = \"jobseeker\";\n//\t\tBaseModel test = new BaseModel();\n//\t\tSystem.out.println(BaseModel.verifyLogin(email, password, role));\n//\t\tBaseModel.addUser(\"[email protected]\", \"vvvv\", \"aspirant\", \"vikas\");\n//\t\tBaseModel.updateJobseeker(\"[email protected]\", \"some major\", \"1-3\", \"yes\", \"yes\", \"1\", \"male\", \"no\", \"yes\");\n\t\tSystem.out.println(BaseModel.getJobseekerDetails(\"[email protected]\"));\n\t}", "public interface ImportModel<T> {\n\n Class<T> getImportClass();\n\n ImportModelProperty[] getModelProperties();\n\n MethodHandle getLineNumberHandler();\n}", "LectureProject createLectureProject();", "public static void main(String[] args) {\n IAcessoDatos datos = new ImplementacionMySql();\n //datos.listar();\n imprimir(datos);\n \n datos = new ImplementacionOracle();\n //datos.listar();\n imprimir(datos);\n }", "public static void main(String[] args) {\n\n OnlineStudent onlineStundent= new OnlineStudent();\n onlineStundent.attendClass();\n\n CampusStudent campusStudent= new CampusStudent();\n campusStudent.attendClass();\n \n }", "@Test(priority = 66)\r\n@Epic(\"BILLS PAYMENT\")\r\n@Features(value = { @Feature(value = \"BUY GOODS USING MPESA\") })\r\n@Step (\"BUY GOODS USING MPESA\")\r\n@Severity(SeverityLevel.TRIVIAL)\r\npublic void Buy_Goods_Using_MPESA_Test_cases() {\n\tSystem.out.println(\"BUY GOODS AND SERVICES\");\t\r\n\tSystem.out.println(\"*************************(1)Running Buy Goods Using MPESA Testcases***********************************\");\r\n\r\n}", "public JmlModelImport (final Boolean p1, final String p2) throws CGException {\n\n try {\n\n ivModel = null;\n ivImport = UTIL.ConvertToString(new String());\n }\n catch (Exception e){\n\n e.printStackTrace(System.out);\n System.out.println(e.getMessage());\n }\n {\n\n setModel(p1);\n setImport(p2);\n }\n }", "@Mapper\npublic interface ModularMapper extends BaseMapper<ModularEntity>{\n @Select(\"select * from modular\")\n List<ModularEntity> selectModularAll();\n @Select(\"select * from modular where modular_name like CONCAT('%',#{modular_name},'%')\")\n List<ModularEntity> selectModular_name(String modular_name);\n}", "public JmlModelImport (final Boolean p1, final String p2, final Long line, final Long column) throws CGException {\n\n try {\n\n ivModel = null;\n ivImport = UTIL.ConvertToString(new String());\n }\n catch (Exception e){\n\n e.printStackTrace(System.out);\n System.out.println(e.getMessage());\n }\n {\n\n setModel(p1);\n setImport(p2);\n setPosition(line, column);\n }\n }", "public static void main(String[] args) throws Exception {\n EmploymentHistoryDaoInter userDao = Context.instanceEmploymentHistoryDao();//bu klass dao impl i gormur cunki atdiq Context de ki bu menim mysql le isleyeceyim UserDaoImpl() dir \n// sabah Oracl istifade etsem bir bunu deyisecem UserDaoImpl2 qoyacam birde proyektde coxlu deyisikliye ehtiyac olmayacaq \n// implementasiya ile interface i ayirdiq buda loosly coupling(ic ice kecmir iki obyekt bir birinden asli deyil) adlanir\n\n System.out.println(userDao.getAllEmploymentHistoryById(1));\n\n }", "public static void main(String[] args) {\n\t\tCompanyDao companyDao = new CompanyDao();\n\t\tArrayList<Company> company_list = companyDao.getArrayList_company();\n\n\t\tfor(int i = 0; i < company_list.size(); i++) {\n\t\t\tSystem.out.print(company_list.get(i).getNameString());\n\t\t\tSystem.out.print(company_list.get(i).getSalesman_nameString());\n\t\t}\n \n\t}", "public String convertStatement (String oraStatement);", "public String convertStatement (String oraStatement);", "@Test\n void displayAllTasks() {\n }", "public interface YjxtEdisposeflowMapper {\n public void insertEdisposeflow(YjxtEdisposeflow yjxtEdisposeflow);\n public List<YjxtEdisposeflow> getEdisposeflow();\n\n}", "public interface Roles {\n String DIRECTOR = \"ROLE_DIRECTOR\";\n String TEACHER = \"ROLE_TEACHER\";\n String STUDENT = \"ROLE_STUDENT\";\n String PARENT = \"ROLE_PARENT\";\n}", "public ImportVo() {\r\n // nothing to do\r\n }", "public interface SQL_CONSTANTS {\n\t\tstatic final String JDBC_DRIVER = \"com.mysql.jdbc.Driver\";\n\t\tstatic final String DB_URL = \"jdbc:mysql://localhost/EMP\";\n\t\tstatic final String USER = \"username\";\n\t\tstatic final String PASSWORD = \"password\";\n\t}", "public static void main(String[] args) {\n \tStudentDao dao=new StudentDao();\r\n\t\tList<Student> students=dao.getStudents();\r\n\t\tfor (Student student : students) {\r\n\t\t\tSystem.out.println(student);\r\n\t\t}\r\n//\t\tStudent student=new Student();\r\n//\t\tstudent.setName(\"²ρΘ®\");\r\n//\t\tstudent.setBId(3);\r\n//\t\tstudent.setGerden(0);\r\n//\t\tstudent.setId(5);\r\n// \tint result= dao.add(student);\r\n//\t\tint result=dao.update(student);\r\n//\t\tint result =dao.del(7);\r\n//\t\tSystem.out.println(result);\r\n\t}", "List<CliStaffProject> selectByExample(CliStaffProjectExample example);", "public Cmdline(String file) {\n \n try {\n File selectedFile = new File(file);\n Model m = loadModel( selectedFile );\n if( m != null )\n models.add( m );\n } catch (FileNotFoundException fnfe) {\n System.out.println(\"File not found\");\n } catch( ParseException pe ) {\n System.out.println(\"Parse Error: \" + pe.getMessage());\n } catch( LemException le ) {\n System.out.println(\"Parse Error: \" + le.getMessage());\n } catch( IOException ioe ) {\n System.out.println(\"I/OO Error: \" + ioe.getMessage());\n }\n \n/* metamodel.Procedure p = m.getDomain( \"Publications\" ).getClass( \"Manuscript\" ).getStateMachine().getState(\"Adding\").getProcedure();\n runtime.ModelInstance i = new runtime.ModelInstance();\n \n p.execute(i); */\n }", "public void importClass(String klass) throws Exception;", "void example(org.linlinjava.litemall.db.domain.LitemallTypeRoleExample example);", "public static void main(String[] args) {\n\tstudent stu= new student();\r\nSystem.out.println(stu.sno+\"\\t\"+stu.sname+\"\\t\"+stu.sfee+\"\\t\"+stu.sresult+\"\\t\"+stu.flag);\r\n }", "List<ExtDagTask> taskList(ExtDagTask extDagTask);", "static public String[] parseImport(String value) {\n \treturn value.split(\";\");\n }", "public static void main(String[] args) {\n\tProfessorSql sql= new ProfessorSql();\n\t//sql.add(professor);\n\t//sql.delete(\"49022518841\");\n}", "List<JindouyunRole> selectByExample(JindouyunRoleExample example);" ]
[ "0.5515908", "0.5515908", "0.54917604", "0.518991", "0.51779366", "0.5131719", "0.5112301", "0.50980574", "0.5086179", "0.50507855", "0.50309056", "0.49662316", "0.4827662", "0.4792537", "0.47715163", "0.47707415", "0.47120634", "0.47060174", "0.47029263", "0.4696344", "0.4693096", "0.46663272", "0.4652712", "0.46388325", "0.46083888", "0.46073115", "0.4594712", "0.4589702", "0.45834693", "0.45827904", "0.45812204", "0.45660147", "0.4551887", "0.4537863", "0.45303848", "0.4503319", "0.4492897", "0.44849658", "0.4483525", "0.44796953", "0.44718364", "0.4459174", "0.44583458", "0.44535947", "0.4452733", "0.44525802", "0.44493228", "0.44480836", "0.44374034", "0.44321162", "0.44273335", "0.44249526", "0.442407", "0.44105232", "0.44054183", "0.440328", "0.44008362", "0.43978578", "0.43902496", "0.43707713", "0.43641877", "0.4353455", "0.4352526", "0.43516436", "0.43489704", "0.43464833", "0.4346159", "0.43448555", "0.43442202", "0.43438682", "0.43373165", "0.43333638", "0.43322647", "0.43285224", "0.4324524", "0.4316628", "0.4303879", "0.42990303", "0.42962202", "0.42952636", "0.42801607", "0.42795917", "0.42763898", "0.42756417", "0.42725688", "0.42725688", "0.42714393", "0.4267556", "0.42653105", "0.4264771", "0.42597026", "0.4259312", "0.42564648", "0.4253826", "0.42504194", "0.4249993", "0.42487404", "0.42476106", "0.42468756", "0.42439014", "0.4237777" ]
0.0
-1
Inflate your custom layout
@Override protected void findView() { final ViewGroup actionBarLayout = (ViewGroup) getLayoutInflater().inflate( R.layout.action_bar,null); // Set up your ActionBar final ActionBar actionBar = getActionBar(); actionBar.setDisplayShowHomeEnabled(true); actionBar.setDisplayShowTitleEnabled(true); actionBar.setDisplayShowCustomEnabled(true); actionBar.setCustomView(actionBarLayout); category = (TextView)findViewById(R.id.detail_category); created_at = (TextView)findViewById(R.id.detail_created_at); content = (TextView)findViewById(R.id.detail_content); delete = (Button)findViewById(R.id.delete_diary); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void onFinishInflate() {\n super.onFinishInflate();\n this.mIconView = (ImageView) findViewById(R.id.icon);\n this.mTitleView = (TextView) findViewById(R.id.title);\n this.mSummaryView = (TextView) findViewById(R.id.summary);\n this.mSlidingButton = findViewById(R.id.sliding_button);\n }", "@Override\n protected void onFinishInflate() {\n super.onFinishInflate();\n mTitleContent = (TextView) findViewById(R.id.title_content);\n mLeftTv = (TextView) findViewById(R.id.title_left_tv);\n mRightTv = (TextView) findViewById(R.id.title_right_tv);\n mRightImg = (ImageView) findViewById(R.id.title_right_img);\n mMessageView = (RelativeLayout) findViewById(R.id.toolbar_message_view);\n mUnReadImg = (ImageView) findViewById(R.id.toolbar_message_unread_img);\n }", "@Override\n protected void onFinishInflate() {\n super.onFinishInflate();\n\n //'this' refers to the LinearLayout, cause we are currently in LinearLayout\n\n //access the day UI element\n mTextDate = (TextView) this.findViewById(R.id.tv_day);\n\n //access the month UI element\n mTextMonth = (TextView) this.findViewById(R.id.tv_month);\n\n //access the year UI element\n mTextYear = (TextView) this.findViewById(R.id.tv_year);\n\n //setOnTouchListener on the UI elements\n\n mTextDate.setOnTouchListener(this);\n mTextMonth.setOnTouchListener(this);\n mTextYear.setOnTouchListener(this);\n\n //get the current date from the Calendar\n int date = mCalendar.get(Calendar.DATE);\n\n //get current month\n int month = mCalendar.get(Calendar.MONTH);\n\n //get current year\n int year = mCalendar.get(Calendar.YEAR);\n\n //pass the date, month and year to update method which will update the UI\n update(date, month, year, 0, 0, 0);\n\n\n }", "@Override\n\tpublic void onCreate() {\n\t\tsuper.onCreate();\n\t\tinflater = LayoutInflater.from(getApplicationContext());\n\t}", "@Override\n public void setContentView(int layoutResID){\n }", "@Override\n\tprotected int initView() {\n\t\treturn R.layout.activity_zhusu_detail;\n\t}", "@Override\r\n\tprotected void onCreate(Bundle savedInstanceState) {\n\t\tsuper.onCreate(savedInstanceState);\r\n\r\n\t\tCustomLayout layout = new CustomLayout(this);\r\n\t\tsetContentView(layout);\r\n\t}", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n\t\tmRoot = inflater.inflate(R.layout.mouse_layout, container, false); \n\t\tinitializeUI();\n\t\treturn mRoot; \n }", "@SuppressLint(\"InflateParams\")\r\n\t@Override\r\n\tpublic View initLayout(LayoutInflater inflater) {\n\t\tView view = inflater.inflate(R.layout.frag_customer_all, null);\r\n\t\treturn view;\r\n\t}", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(getLayoutId(), container, false);\n init(view);\n return view;\n }", "@Override\r\n\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container,\r\n\t\t\tBundle savedInstanceState) {\n\t\tv = inflater.inflate(R.layout.wisata, container, false);\r\n \r\n\t\t\r\n\t\t\r\n\t\treturn v;\r\n\t}", "@Nullable\n @Override\n public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {\n\n\n view = inflater.inflate(LAYOUT, container, false);\n return view;\n }", "@Override\n\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container,\n\t\t\tBundle savedInstanceState) {\n\t\treturn inflater.inflate(R.layout.xxh_gamelayout3, container, false);\n\t}", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n root = (ViewGroup) inflater.inflate(R.layout.money_main, container, false);\n context = getActivity();\n initHeaderView(root);\n initView(root);\n\n getDate();\n initEvetn();\n return root;\n }", "@Override\r\n\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container,\r\n\t\t\tBundle savedInstanceState) {\n\t\treturn inflater.inflate(R.layout.wallpager_layout, null);\r\n\t}", "public void onFinishInflate() {\n super.onFinishInflate();\n this.logo = findViewById(C1167R.C1170id.channel_logo);\n this.logoTitle = findViewById(C1167R.C1170id.logo_title);\n this.actionsHint = findViewById(C1167R.C1170id.actions_hint);\n this.sponsoredChannelBackground = findViewById(C1167R.C1170id.sponsored_channel_background);\n this.channelViewMainLinearLayout = findViewById(C1167R.C1170id.main_linear_layout);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n View v = inflater.inflate(R.layout.day_layout, container,false);\n setPieMap(v);\n loadDatas();\n simulator();\n return v;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n final View v = inflater.inflate(R.layout.fragemnt_reserve, container, false);\n\n\n\n\n return v;\n }", "@Nullable\n @Override\n public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.layout_number_full,container,false);\n itemView(view);\n return view;\n }", "@Override\n\tpublic void init(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n\t\tsuper.init(inflater, container, savedInstanceState);\n\n\t\tmDxCountTextView = (TextView) findViewById(R.id.dx_count);\n\t\tmDxTotalTextView = (TextView) findViewById(R.id.dx_total);\n\t\tmZyCountTextView = (TextView) findViewById(R.id.zy_count);\n\t\tmZyTotalTextView = (TextView) findViewById(R.id.zy_total);\n\t\tmTimeTextView = (TextView) findViewById(R.id.time);\n\t\t\n\t\tmDxTipText = (TextView) findViewById(R.id.dx_count_tip);\n\t\tmZyTipText = (TextView) findViewById(R.id.zy_count_tip);\n\t\tmDxBottonText = (TextView) findViewById(R.id.dx_total_tip);\n\t\tmXyBottonText = (TextView) findViewById(R.id.zy_total_tip);\n\t}", "@Override\r\n\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container,\r\n\t\t\tBundle savedInstanceState) {\n\t\treturn inflater.inflate(R.layout.main_fhmx, container, false);\r\n\t}", "@Override\n protected void onFinishInflate() {\n super.onFinishInflate();\n tv_slider_icon = (TextView) findViewById(R.id.slider_icon);\n }", "private void inflateView() {\n\t\tLog.v(T, \"inflateView\");\n\t\tif (!isInEditMode()) {\n\t\t\tString inflaterService = Context.LAYOUT_INFLATER_SERVICE;\n\n\t\t\tLayoutInflater layoutInflater = (LayoutInflater) getContext()\n\t\t\t\t\t.getSystemService(inflaterService);\n\t\t\tlayoutInflater.inflate(R.layout.dms_coordinate, this, true);\n\n\t\t\t// Get child control references\n\t\t\teditDegrees = (EditText) findViewById(R.id.editDegrees);\n\t\t\teditMinutes = (EditText) findViewById(R.id.editMinutes);\n\t\t\teditSeconds = (EditText) findViewById(R.id.editSeconds);\n\t\t}\n\t}", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.information_view, container, false);\n mFillContentCallback.invoke(view);\n\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.list_base, container, false);\n }", "@Override\n public void setContentView(int layoutResID) {\n if (view_stub != null) {\n LayoutInflater inflater = (LayoutInflater) getSystemService(LAYOUT_INFLATER_SERVICE);\n ViewGroup.LayoutParams lp = new ViewGroup.LayoutParams(\n ViewGroup.LayoutParams.MATCH_PARENT,\n ViewGroup.LayoutParams.MATCH_PARENT);\n View stubView = inflater.inflate(layoutResID, view_stub, false);\n view_stub.addView(stubView, lp);\n }\n }", "@Override\n public void setContentView(int layoutResID) {\n if (view_stub != null) {\n LayoutInflater inflater = (LayoutInflater) getSystemService(LAYOUT_INFLATER_SERVICE);\n ViewGroup.LayoutParams lp = new ViewGroup.LayoutParams(\n ViewGroup.LayoutParams.MATCH_PARENT,\n ViewGroup.LayoutParams.MATCH_PARENT);\n View stubView = inflater.inflate(layoutResID, view_stub, false);\n view_stub.addView(stubView, lp);\n }\n }", "@Override\n public void onCreate(Bundle savedInstanceState) \n {\n super.onCreate(savedInstanceState);\n\n setContentView(R.layout.main); \n createLayout();\n }", "@Override\n\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container,\n\t\t\tBundle savedInstanceState) {\n\t\tif (mObjView == null) {\n\t\t\tmObjView = inflater.inflate(R.layout.jeep_airset, container, false);\n\t\t\tinit();\n\t\t}\n\n\t\treturn mObjView;\n\t}", "@Override\r\n\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container,\r\n\t\t\tBundle savedInstanceState) {\n\t\trootView = inflater.inflate(R.layout.fragment_attack_armor, container, false);\r\n\r\n\t\tfindInterfaceElements();\r\n\t\taddRangeSelector();\r\n\t\tupdateHeadings();\r\n\t\tsetListeners();\r\n\r\n\t\tsetFromData();\r\n\r\n\t\treturn rootView;\r\n\t}", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n ctx = getActivity();\n View view = inflater.inflate(getLayoutID(),null);\n mPreenter = createPresenter();\n loading = new MyProgressLoading(ctx, R.style.DialogStyle);\n sp = ctx.getSharedPreferences(SpUtiles.SP_Mode,Context.MODE_PRIVATE);\n HideUtil.init(getActivity());\n unbinder = ButterKnife.bind(this, view);\n initView();\n initData();\n initListener();\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View layout = inflater.inflate(R.layout.custom_row, container, false);\n recyclerView = (RecyclerView) layout.findViewById(R.id.rv);\n adapter = new WebCrawlerRecyclerViewAdapter(getActivity(), getData());\n recyclerView.setAdapter(adapter);\n LinearLayoutManager layoutManager = new LinearLayoutManager(getActivity());\n layoutManager.setOrientation(LinearLayoutManager.VERTICAL);\n recyclerView.setLayoutManager(layoutManager);\n return layout;\n\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.book_list, container, false);\n\n /** RETURN THE VIEW INSTANCE TO SETUP THE LAYOUT **/\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.word_list, container, false);\n }", "@Override\n public View onCreateView(\n LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState\n ) {\n return inflater.inflate(R.layout.select_game, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.screen_select_list_student, container, false);\n }", "public final void onFinishInflate() {\n super.onFinishInflate();\n TextView textView = (TextView) findViewById(C0126R.C0129id.title);\n this.f110062a = textView;\n C1280ps.m19893a(textView, \"excludeViewFromChangeBounds\");\n this.f110062a.setTag(C0126R.C0129id.summary_expander_transition_name, \"summaryField\");\n TextView textView2 = (TextView) findViewById(C0126R.C0129id.subtitle);\n this.f110063b = textView2;\n textView2.setTag(C0126R.C0129id.summary_expander_transition_name, \"summaryField\");\n LinearLayout linearLayout = (LinearLayout) findViewById(C0126R.C0129id.collapsed_image_container);\n this.f110064c = linearLayout;\n linearLayout.setTag(C0126R.C0129id.summary_expander_transition_name, \"summaryField\");\n LinearLayout linearLayout2 = (LinearLayout) findViewById(C0126R.C0129id.expanded_image_container);\n this.f110065d = linearLayout2;\n linearLayout2.setTag(C0126R.C0129id.summary_expander_transition_name, \"summaryField\");\n this.f110066e = (ImageView) findViewById(C0126R.C0129id.expand_collapse_icon);\n ImageWithCaptionView imageWithCaptionView = (ImageWithCaptionView) findViewById(C0126R.C0129id.tooltip_view);\n this.f110068g = imageWithCaptionView;\n imageWithCaptionView.setDefaultImageResId(bkfr.m105543a(getContext(), (int) ErrorInfo.TYPE_SDU_MEMORY_FULL, -1));\n this.f110068g.setOnClickListener(this);\n }", "@Override\r\n protected void onCreate(Bundle savedInstanceState) {\n super.onCreate(savedInstanceState);\r\n setContentView(layoutId);\r\n }", "@Override \n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.article_reader_layout, container, false);\n textView = (TextView)view.findViewById(R.id.text) ;\n return view;\n\t}", "@Override\n protected void loadViewLayout() {\n setContentView(R.layout.ui_imgs_graffit);\n }", "private void initView() {\n\n LayoutInflater inflater = getLayoutInflater();\n final int screenWidth = MyUtils.getScreenMetrics(this).widthPixels;\n final int screenHeight = MyUtils.getScreenMetrics(this).heightPixels;\n for (int i = 0; i < 3; i++) {\n ViewGroup layout = (ViewGroup) inflater.inflate(\n R.layout.content_layout, myHorizontal, false);\n layout.getLayoutParams().width = screenWidth;\n TextView textView = (TextView) layout.findViewById(R.id.title);\n textView.setText(\"page \" + (i + 1));\n layout.setBackgroundColor(Color.rgb(255 / (i + 1), 255 / (i + 1), 0));\n createList(layout);\n myHorizontal.addView(layout);\n }\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.results_screen, container, false);\n settingsView = (RelativeLayout) view.findViewById(R.id.setting_layout);\n setBasicContents(view);\n return view;\n }", "@Override\r\n protected void onFinishInflate() {\r\n initComponents();\r\n }", "@Override\n \tpublic View onCreateView(LayoutInflater inflater, ViewGroup container,\n \t\t\tBundle savedInstanceState) {\n \t\treturn inflater.inflate(R.layout.list, container, false);\n \t}", "public void onFinishInflate() {\n super.onFinishInflate();\n this.mTvMain = (TextView) findViewById(R.id.tv_main);\n this.mTvSub = (TextView) findViewById(R.id.tv_second);\n this.mIvIcon = (ImageView) findViewById(R.id.iv_icon);\n this.mIvIcon.setVisibility(8);\n this.mTvSub.setMovementMethod(ScrollingMovementMethod.getInstance());\n }", "@Nullable\n @Override\n public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.read_layout,container,false);\n mContext = view.getContext();\n if(readPresenter ==null)\n readPresenter = new ReadPresenter(getContext(),this);\n initUI(view);\n return view;\n\n }", "private void initializeViews(Context context) {\n LayoutInflater inflater = (LayoutInflater) context.getSystemService(Context.LAYOUT_INFLATER_SERVICE);\n inflater.inflate(R.layout.number_picker, this);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.first_step_layout, container, false);\n initView();\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view= inflater.inflate(R.layout.activity_click_product_layout, container, false);\n\n ivList=view.findViewById(R.id.iv_list);\n txtProductDescription=view.findViewById(R.id.txt_productDescription);\n txtShowOfeerPrice=view.findViewById(R.id.txt_showOfferPrice);\n txtShowPrice=view.findViewById(R.id.txt_showPrice);\n txtTitleName=view.findViewById(R.id.tv_list_name);\n edtEnterPinCode=view.findViewById(R.id.edt_enterPinCode);\n\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup parent, Bundle savedInstanceState) {\n return inflater.inflate(R.layout.activity_recetas, parent, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n\treturn inflater.inflate(R.layout.activity_main, container, false);\n }", "@Override\n public void baseSetContentView() {\n View layout = View.inflate(this, R.layout.crm_vistor_signaddinfo, mContentLayout);\n mContext = this;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.activity_adddatacat, container, false);\n\n }", "@Override\r\n\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container,\r\n\t\t\tBundle savedInstanceState) {\n\t\treturn inflater.inflate(R.layout.live_layout, null);\r\n\t}", "public void onFinishInflate() {\n super.onFinishInflate();\n this.mTextAndBackground = (ViewGroup) findViewById(C0622R.C0625id.text_and_background);\n ColorDrawable colorDrawable = (ColorDrawable) this.mTextAndBackground.getBackground();\n this.mBackgroundColor = colorDrawable.getColor();\n this.mTextAndBackground.setBackground(new RippleDrawable(ColorStateList.valueOf(Themes.getAttrColor(getContext(), 16843820)), colorDrawable, null));\n this.mTitleView = (TextView) this.mTextAndBackground.findViewById(C0622R.C0625id.title);\n this.mTextView = (TextView) this.mTextAndBackground.findViewById(C0622R.C0625id.text);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.goals_overview, container, false);\n }", "@Override\n\tpublic View onCreateView(LayoutInflater inflater,\n\t\t\t@Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {\n\t\tweatherView = LayoutInflater.from(getActivity()).inflate(\n\t\t\t\tR.layout.weather_layout, null);\n\t\ttry {\n\t\t\tinitLayoutParams();\n\t\t\tinitView();\n\t\t\tinitListener();\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t}\n\n\t\treturn weatherView;\n\t}", "private void initView(Context context) {\n\t\tLinearLayout.LayoutParams params = new LinearLayout.LayoutParams(LayoutParams.MATCH_PARENT, 0);\n\t\tmContainer = (LinearLayout)LayoutInflater.from(context).inflate(R.layout.pullable_refresh, null);\n\t\taddView(mContainer, params);\n\t\tsetGravity(Gravity.BOTTOM);\n\t\t\n\t\trefreshArrowView = (ImageView)findViewById(R.id.pull_down_arrow);\n\t\trefreshingView = (ImageView)findViewById(R.id.pull_down_refreshing_view);\n\t\trefreshStateTextView = (TextView)findViewById(R.id.pull_down_state_text);\n\t\t\n\t\trotateAnimation = (RotateAnimation)AnimationUtils.loadAnimation(context, R.anim.reverse_anim);\n\t\trefreshingAnimation = (RotateAnimation)AnimationUtils.loadAnimation(context, R.anim.rotating);\n\t\tLinearInterpolator lir = new LinearInterpolator();\n\t\trotateAnimation.setInterpolator(lir);\n\t\trefreshingAnimation.setInterpolator(lir);\n\t}", "@Nullable\n public View onCreateView(LayoutInflater inflater,\n @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {\n if (null == view) {\n myContainer = new LinearLayout(mContext);\n view = inflater.inflate(R.layout.listitem_banner, null);\n view.setMinimumHeight(((WindowManager) getActivity()\n .getSystemService(Context.WINDOW_SERVICE))\n .getDefaultDisplay().getHeight());\n view.setMinimumWidth(((WindowManager) getActivity()\n .getSystemService(Context.WINDOW_SERVICE))\n .getDefaultDisplay().getWidth());\n initData();\n myContainer.addView(view);\n } else {\n myContainer.removeAllViews();\n myContainer = new LinearLayout(getActivity());\n myContainer.addView(view);\n }\n return myContainer;\n }", "@Override\n public View onCreateView(\n LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState\n ) {\n return inflater.inflate(R.layout.activity_person_info, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_main_allinfo, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.motor_home_ui, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fg_movie, null);\n }", "@Override\n\tprotected void initContentView() {\n\t\t\n\t}", "@Override\n\tpublic View onCreateView(LayoutInflater inflater,\n\t\t\t@Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {\n\t\tView view = inflater.inflate(R.layout.one, null);\n\t\treturn view;\n\t}", "protected void onLoadLayout(View view) {\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n layout = (FrameLayout) inflater.inflate(R.layout.fragment_actualites, container, false);\n\n relLayout = (RelativeLayout) layout.findViewById(R.id.relLayoutActus);\n\n initListView();\n getXMLData();\n\n return layout;\n }", "@Override\n\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container,\n\t\t\tBundle savedInstanceState) {\n\t\tView view = inflater.inflate(R.layout.authentication_layout, container, false);\n\t\tbtnLogin = (ButtonRectangle) view.findViewById(R.id.btn_login);\n\t\tbtnLoginAsGuest = (ButtonRectangle) view.findViewById(R.id.btn_login_as_guest);\n\n\t\treturn view;\n\t}", "@SuppressLint(\"InflateParams\")\r\n\t@Override\r\n\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\r\n\t\tView view = (View) inflater.inflate(R.layout.customprogress, null);\r\n//\t\tButton buttonPositive = (Button) view.findViewById(R.id.dialog_button_positive);\r\n//\t\tButton buttonNegative = (Button) view.findViewById(R.id.dialog_button_negative);\r\n\t\tmProgressBar = (ProgressBar) view.findViewById(R.id.progress_bar);\r\n\t\tmProgressTextView = (TextView) view.findViewById(R.id.progress_txt);\r\n\t\tmProgressBarfile = (ProgressBar) view.findViewById(R.id.progress_bar2);\r\n\t\tmProgressTextViewFile = (TextView) view.findViewById(R.id.progress_txt2);\r\n\r\n//\t\tbuttonNegative.setOnClickListener(this);\r\n//\t\tbuttonPositive.setEnabled(false);\r\n//\t\tbuttonPositive.setOnClickListener(this);\r\n\t\tgetDialog().getWindow().requestFeature(Window.FEATURE_NO_TITLE);\r\n\t\treturn view;\r\n\t}", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n super.onCreateView(inflater, container, savedInstanceState);\n view = inflater.inflate(R.layout.layout_inventory_list, container, false);\n\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n return initUiComponents(inflater, container);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.activity_post_property_screen, container, false);\n }", "@Override\n\tprotected View initContentView(Context context)\n\t{\n\n\t\tmContainer = new FrameLayout(mContext);\n\t\treturn mContainer;\n\t}", "private void initializeViews(Context context) {\n LayoutInflater inflater = (LayoutInflater) context\n .getSystemService(Context.LAYOUT_INFLATER_SERVICE);\n inflater.inflate(R.layout.field_spinner_field, this);\n }", "@Override\n protected void onCreate(@Nullable Bundle savedInstanceState) {\n super.onCreate(savedInstanceState);\n setContentView(getLayoutViewId());\n// presenter = getPresenter(typePresenter);\n init();\n }", "@Override\r\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\r\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.fragment_fore_cast, container, false);\r\n initView();\r\n mainLayout.setVisibility(View.GONE);\r\n apiInterface = RestClinet.getClient().create(ApiInterface.class);\r\n loadData();\r\n return view;\r\n }", "@Override\n public View onCreateView(LayoutInflater inflater,\n @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {\n mRootView = inflater.inflate(getLayoutId(), null);\n x.view().inject(this, mRootView);\n return mRootView;\n }", "protected void setupView(Context context, final ViewGroup parent) {\n\n\t\tLayoutInflater inflater = (LayoutInflater) context\n\t\t.getSystemService(Context.LAYOUT_INFLATER_SERVICE);\n\t\tView v = inflater.inflate(R.layout.map_popup_layout, parent);\n\t\timage = (ImageView) v.findViewById(R.id.statusImgOnMAP);\n\t\tBitmap weatherImg = UtilityFunctions.StringToBitMap(\"\");\n\t\tif(weatherImg!=null)\n\t\t\timage.setImageBitmap(weatherImg);\n\t\theader = (TextView) v.findViewById(R.id.locationHeaderOnMap);\n\t\ttitle1 = (TextView) v.findViewById(R.id.descripOnMap);\n\t\ttitle2 = (TextView) v.findViewById(R.id.dateOnMap);\n\t\ttitle3 = (TextView) v.findViewById(R.id.minTempOnMapValue);\n\t\ttitle4 = (TextView) v.findViewById(R.id.maxTempOnMapValue);\n\n\t}", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n\n return inflater.inflate(R.layout.all_books, container, false);\n }", "public void onFinishInflate() {\n super.onFinishInflate();\n this.titleIconContainer = findViewById(C1167R.C1170id.watch_next_info_icon_title_container);\n this.message = findViewById(C1167R.C1170id.watch_next_info_message);\n Resources res = getContext().getResources();\n this.selectedMessageWidth = res.getDimensionPixelSize(C1167R.dimen.watch_next_info_card_selected_message_width);\n this.selectedCardHeight = res.getDimensionPixelSize(C1167R.dimen.program_default_height);\n }", "@Override\n\tpublic void onCreate(Bundle savedInstanceState) {\n\t\tsuper.onCreate(savedInstanceState);\n\t\tmContext = getActivity();\n\t\tll = new LinearLayout(getActivity());\n\t\tLinearLayout.LayoutParams params = new LinearLayout.LayoutParams(\n\t\t\t\tLinearLayout.LayoutParams.FILL_PARENT,\n\t\t\t\tLinearLayout.LayoutParams.FILL_PARENT);\n\t\tthis.getActivity().addContentView(ll, params);\n\t}", "public final void onFinishInflate() {\n super.onFinishInflate();\n m118789x();\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.be_admin_printers, container, false);\n\n /** RETURN THE VIEW INSTANCE TO SETUP THE LAYOUT **/\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.game_zipe_observation, container, false);\n settingThingsUp(view);\n\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return Utils.setCustomAdapterTheme(getActivity(), inflater, R.layout.slide_result, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.layoutview3, container, false);\n }", "private void initializeViews(Context context) {\n LayoutInflater inflater = (LayoutInflater) context.getSystemService(Context.LAYOUT_INFLATER_SERVICE);\n inflater.inflate(R.layout.progressive_next_view_layout, this);\n }", "@Override\r\n\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container,\r\n\t\t\tBundle savedInstanceState) {\n\t\tView v=inflater.inflate(R.layout.notepad_main, container, false);\r\n\t\tbody=(LineEditText) v.findViewById(R.id.body);\r\n\t\tdel=(Button) v.findViewById(R.id.delAll);\r\n\t\tdel.setOnClickListener(this);\r\n\t\treturn v;\r\n\t}", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState){\n View layout = inflater.inflate(R.layout.setup_chatroom_dialog, container, false);\n Button setupButton = (Button)layout.findViewById(R.id.setup_chatRoom_dialog_setup_button);\n Button cancelButton = (Button)layout.findViewById(R.id.setup_chatRoom_dialog_cancel_button);\n editText = (EditText)layout.findViewById(R.id.setup_chatRoom_dialog_edit_text);\n setupButton.setOnClickListener(setupListener);\n cancelButton.setOnClickListener(cancelListener);\n return layout;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n return inflater.inflate(R.layout.folio_activity, container, false);\n }", "@Override\n\tpublic int bindLayout() {\n\t\treturn R.layout.activity_init;\n\t}", "public CustomView(Context context, AttributeSet attrs) {\n super(context, attrs);\n init();\n }", "@Override\n\t\tpublic void layout(int l, int t, int r, int b) {\n\t\t\tsuper.layout(l, t, r, b);\n\t\t\tLog.e(\"FYF\", getId() + \" ImageView layout\");\n\t\t}", "@Nullable\n @Override\n public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {\n View view=inflater.inflate(R.layout.chart,container,false);\n\n initView(view);\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view=inflater.inflate(R.layout.fragment_layout12, container, false);\n\n iniv();\n\n init();\n\n return view;\n }", "private void initView() {\n\n main_ll_rl = (LinearLayout) findViewById(R.id.main_ll_rili);\n main_ll_xw = (LinearLayout) findViewById(R.id.main_ll_xw);\n main_ll_wode = (LinearLayout) findViewById(R.id.main_ll_wd);\n main_ll_self = (LinearLayout) findViewById(R.id.main_ll_self);\n main_ll_hq = (LinearLayout) findViewById(R.id.main_ll_hq);\n main_zt_color = (LinearLayout) findViewById(R.id.main_zt_color);\n\n main_zt_color.setBackgroundColor(Color.parseColor(\"#e9e9ea\"));\n\n imgrl = (ImageView) findViewById(R.id.imgrili);\n imgxw = (ImageView) findViewById(R.id.imgxw);\n imgwd = (ImageView) findViewById(R.id.imgwd);\n imggr = (ImageView) findViewById(R.id.imgself);\n imghq = (ImageView) findViewById(R.id.imghq);\n\n main_rl_tv = (TextView) findViewById(R.id.main_rl_tv);\n main_xw_tv = (TextView) findViewById(R.id.main_xw_tv);\n main_wd_tv = (TextView) findViewById(R.id.main_wd_tv);\n main_gr_tv = (TextView) findViewById(R.id.main_self_tv);\n main_hq_tv = (TextView) findViewById(R.id.main_hq_tv);\n\n main_ll_rl.setOnClickListener(this);\n main_ll_xw.setOnClickListener(this);\n main_ll_wode.setOnClickListener(this);\n main_ll_hq.setOnClickListener(this);\n main_ll_self.setOnClickListener(this);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.fragment_wheretogo, container, false);\n ids();\n setup();\n click();\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_mod_image, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n ViewGroup rootView = (ViewGroup) inflater.inflate(\n R.layout.fragment_chu_de_page, container, false);\n\n imgHinh = (ImageView) rootView.findViewById(R.id.imgHinh);\n txt_nameWord = (TextView) rootView.findViewById(R.id.txt_nameWord);\n txt_phatamWord = (TextView) rootView.findViewById(R.id.txt_phatamWord);\n txt_nghiaWord = (TextView) rootView.findViewById(R.id.txt_nghiaWord);\n btnLoa = (ImageView) rootView.findViewById(R.id.btnLoa);\n\n return rootView;\n }", "public int onCreateContentView() {\n return R.layout.activity_network_diagnostics;\n }", "@Override\n public View newView(Context context, Cursor cursor, ViewGroup parent) {\n //inflate(XmlPullParser parser, ViewGroup root, boolean attachToRoot)\n //Inflate a new view hierarchy from the specified XML node\n return LayoutInflater.from(context).inflate(R.layout.list_item, parent, false);\n }" ]
[ "0.68913174", "0.68802816", "0.6692654", "0.66695833", "0.6658985", "0.66384774", "0.66171247", "0.65857816", "0.6568135", "0.6560309", "0.6544205", "0.6531368", "0.648756", "0.6483713", "0.64816105", "0.6480777", "0.6479792", "0.64452887", "0.64275897", "0.6414344", "0.640316", "0.6387675", "0.6376765", "0.63760835", "0.63665503", "0.6362402", "0.6362402", "0.6347076", "0.6345937", "0.6339368", "0.63092434", "0.62945974", "0.62899977", "0.6285846", "0.62841666", "0.6279381", "0.6278986", "0.62787336", "0.62725407", "0.6272515", "0.62696177", "0.6258965", "0.62589604", "0.62416005", "0.6236915", "0.62358433", "0.62192833", "0.6218126", "0.621781", "0.6216935", "0.621677", "0.62158096", "0.6212796", "0.61972475", "0.61770993", "0.61615497", "0.6147994", "0.61479414", "0.61473876", "0.61414766", "0.61317176", "0.61266303", "0.61169237", "0.6116549", "0.6115287", "0.61103106", "0.6109927", "0.6109814", "0.6104716", "0.60988224", "0.6095423", "0.60771257", "0.6075226", "0.6074251", "0.6072081", "0.6072046", "0.6071486", "0.6069", "0.60646313", "0.60640717", "0.60637695", "0.6058512", "0.6054977", "0.6048964", "0.6047965", "0.60477793", "0.60460246", "0.6043891", "0.60392743", "0.6037869", "0.6035931", "0.6033758", "0.6027556", "0.6026449", "0.60217613", "0.6021372", "0.6019935", "0.601507", "0.60140926", "0.60135794", "0.60061014" ]
0.0
-1
Busca Amount na lista a partir do nome do mineral
public Amount<Mineral> searchByName(String name){ for(int i=0; i<this.mineralList.size(); i++) { if(this.mineralList.get(i).getObject().getName() == name) return this.mineralList.get(i); } return null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public ArrayList<String> Mass(String from, float amount, String[] units) {\n\t\tfrom = findFrom(from);\n\t\tif (from.equals(\"gram\")) {\n\t\t\tArrayList<String> kaduvil = new ArrayList<String>();\n\t\t\tkaduvil.add(\"\" + amount + \" \" + units[0] );\n\t\t\tkaduvil.add(\"\" + amount / 1000 + \" \" + units[1] );\n\t\t\tkaduvil.add(\"\" + amount / 453.59237f + \" \" + units[2] );\n\t\t\treturn kaduvil;\n\t\t} else {\n\t\t\tif (from.equals(\"pounds\")) {\n\t\t\t\treturn Mass(\"gram\", amount * 453.59237f, units);\n\t\t\t} else {\n\t\t\t\treturn Mass(\"gram\", amount * 1000, units);\n\t\t\t}\n\t\t}\n\t}", "public List<FaturamentoVO> validaSelecionaTotalFaturamento(String ano, String anoTexto) {\n\t\tDecimalFormat roundForm = new DecimalFormat(\"0.0\");\n\n\t\tList<FaturamentoVO> listaTratada = new ArrayList<FaturamentoVO>();\n\t\tList<FaturamentoVO> lista = null;\n\t\tList<FaturamentoVO> listaRvne = null;\n\n\t\tswitch (anoTexto) {\n\t\tcase \"atual\":\n\t\t\tlista = dadosFaturamentoDetalhado;\n\t\t\tlistaRvne = rvneTipo2;\n\t\t\tbreak;\n\t\tcase \"anterior\":\n\t\t\tlista = dadosFaturamentoDetalhadoAnoAnterior;\n\t\t\tlistaRvne = rvneTipo2AnoAnterior;\n\t\t\tbreak;\n\t\t}\n\n\t\tBigDecimal totalMes = new BigDecimal(0.0);\n\n\t\t// Insere BP na lista\n\t\tint i = 0;\n\t\tFaturamentoVO faturamentoVObp = new FaturamentoVO();\n\t\tfaturamentoVObp.setProduto(lista.get(i).getProduto());\n\t\tString mesesTotalBP[] = new String[12];\n\n\t\tfor (int k = 0; k < 12; k++) {\n\t\t\tmesesTotalBP[k] = roundForm.format(Double.parseDouble(lista.get(i).getMeses()[k]) / 1000000).replace(\",\",\n\t\t\t\t\t\".\");\n\t\t}\n\n\t\tfaturamentoVObp.setMeses(mesesTotalBP);\n\t\tlistaTratada.add(faturamentoVObp);\n\n\t\t// i = 1;\n\t\t// Trata apenas do Faturamento:\n\t\tFaturamentoVO faturamentoVOtratado = new FaturamentoVO();\n\t\tString mesesTotal[] = new String[12];\n\t\tfaturamentoVOtratado.setProduto(\"Faturamento \");\n\t\tfor (int j = 0; j < 12; j++) {\n\t\t\tint c = 0;\n\t\t\twhile (c < lista.size()) {\n\t\t\t\tif (lista.get(c).getProduto().equalsIgnoreCase(\"EMITIDO\")\n\t\t\t\t\t\t|| lista.get(c).getProduto().equalsIgnoreCase(\"EMITIDOS CANCELADOS\")\n\t\t\t\t\t\t|| lista.get(c).getProduto().equalsIgnoreCase(\"EMITIDOS RESTITUIDOS\")) {\n\n\t\t\t\t\ttotalMes = totalMes.add(new BigDecimal(lista.get(c).getMeses()[j]));\n\t\t\t\t}\n\t\t\t\tc++;\n\t\t\t}\n\t\t\t// RVNE trazido direto da tabela do banco\n\t\t\tif (listaRvne.get(0).getMeses()[j] != null) {\n\t\t\t\ttotalMes = totalMes.add(new BigDecimal(listaRvne.get(0).getMeses()[j]));\n\t\t\t} else {\n\t\t\t\ttotalMes = new BigDecimal(0.0);\n\t\t\t}\n\t\t\tmesesTotal[j] = roundForm.format(Double.parseDouble(totalMes.toString()) / 1000000).replace(\",\", \".\");\n\t\t\ttotalMes = new BigDecimal(0.0D);\n\t\t}\n\t\tfaturamentoVOtratado.setMeses(mesesTotal);\n\t\tlistaTratada.add(faturamentoVOtratado);\n\n\t\treturn listaTratada;\n\t}", "public static int buy(ArrayList<Medicine> list, String name){\n \n for (Medicine medicine : list) {\n String n = medicine.getSupplierName(); // name of saved medicine\n if(n.equals(name)){// compare between two name\n //if equlas --> return cost of this medicine\n return medicine.getUnitCost();\n }\n }\n return 0;\n }", "private String getAmountUnit(int unit) {\n switch (unit) {\n case UNIT_LITERS:\n return getResourceString(R.string.val_l);\n case UNIT_GALLONS:\n return getResourceString(R.string.val_g);\n }\n\n return \"\";\n }", "@Override\n public String toString() {\n return name+\" : \"+ CommonUtils.formatCurrency(amount);\n }", "public static String sumCreditList(List<String> list) {\r\n if (list == null || list.isEmpty()) return \"0\";\r\n float minCredits = 0;\r\n float maxCredits = 0;\r\n for (String item : list) {\r\n String[] split = item.split(\"[ ,/-]\");\r\n\r\n String first = split[0];\r\n float min = Float.parseFloat(first);\r\n minCredits += min;\r\n\r\n String last = split[split.length - 1];\r\n float max = Float.parseFloat(last);\r\n maxCredits += max;\r\n }\r\n\r\n String credits = Float.toString(minCredits);\r\n\r\n if (minCredits != maxCredits) {\r\n credits = credits + \"-\" + Float.toString(maxCredits);\r\n }\r\n\r\n credits = credits.replace(\".0\", \"\");\r\n return credits;\r\n }", "private void checkSortedAmount() {\n\n\t\tList<String> actualAmountList = new ArrayList<String>();\n\t\tList<WebElement> elementList = util.findElementsByXpath(\"//td[5]/span\");\n\t\tfor (WebElement we : elementList) {\n\t\t\tactualAmountList.add(we.getText());\n\t\t}\n\n\t\tassertEquals(actualAmountList, dataService.getAscendingAmounts());\n\t\tdriver.manage().timeouts().implicitlyWait(2, TimeUnit.SECONDS);\n\t}", "List<TypeSumDto> somaValoresPorTipo(TransactionType transactionType, Integer mes);", "public List<MovimentoPorCanalDeVendaVO> validaSelecionaEmissaoPorCanal(String movimento) {\n\n\t\tList<MovimentoPorCanalDeVendaVO> list = new ArrayList<MovimentoPorCanalDeVendaVO>(listaEmissaoPorCanal);\n\n\t\tList<MovimentoPorCanalDeVendaVO> listTotal = new ArrayList<MovimentoPorCanalDeVendaVO>();\n\n\t\tString[] mesesTotaisValor = { \"0.0\", \"0.0\", \"0.0\", \"0.0\", \"0.0\", \"0.0\", \"0.0\", \"0.0\", \"0.0\", \"0.0\", \"0.0\",\n\t\t\t\t\"0.0\" };\n\n\t\tString[] mesesTotaisQuantidade = { \"0\", \"0\", \"0\", \"0\", \"0\", \"0\", \"0\", \"0\", \"0\", \"0\", \"0\", \"0\" };\n\n\t\tString anoTotal = null;\n\t\tString produtoTotal = null;\n\n\t\tint qtdQuantidade = 0;\n\t\tint qtdValor = 0;\n\n\t\tfor (int i = 0; i < list.size(); i++) {\n\t\t\tif (!(list.get(i).getMovimento().trim().equalsIgnoreCase(movimento.trim()))) {\n\t\t\t\tlist.remove(i);\n\t\t\t\ti--;\n\t\t\t}\n\t\t}\n\n\t\tfor (MovimentoPorCanalDeVendaVO objLista : list) {\n\t\t\tif (objLista.getTipo().equalsIgnoreCase(\"Valor\")) {\n\t\t\t\tqtdValor++;\n\t\t\t} else if (objLista.getTipo().equalsIgnoreCase(\"Quantidade\")) {\n\t\t\t\tqtdQuantidade++;\n\t\t\t}\n\t\t}\n\t\tint indiceElementoNaoEncontrado = 0;\n\t\tif (qtdValor != qtdQuantidade) {\n\n\t\t\tif (qtdValor > qtdQuantidade) {// Valor eh maior\n\t\t\t\touter: for (int i = 0; i < list.size(); i++) {\n\t\t\t\t\tif (list.get(i).getTipo().equalsIgnoreCase(\"Valor\")) {\n\n\t\t\t\t\t\t// System.out.println();\n\t\t\t\t\t\t//\n\t\t\t\t\t\t// System.out.print(\" 1 | \"\n\t\t\t\t\t\t// + list.get(i).getCanalDeVenda());\n\t\t\t\t\t\t// System.out.println();\n\n\t\t\t\t\t\tfor (int j = 0; j < list.size(); j++) {\n\t\t\t\t\t\t\tint achou = -1;\n\t\t\t\t\t\t\tif (list.get(j).getTipo().equalsIgnoreCase(\"Quantidade\")) {\n\n\t\t\t\t\t\t\t\t// System.out.print(\" 2 | \"\n\t\t\t\t\t\t\t\t// + list.get(j).getCanalDeVenda());\n\t\t\t\t\t\t\t\t// System.out.println();\n\n\t\t\t\t\t\t\t\tif (list.get(i).getCanalDeVenda().equals(list.get(j).getCanalDeVenda())) {\n\t\t\t\t\t\t\t\t\tachou = j;\n\t\t\t\t\t\t\t\t\tcontinue outer;\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\tif (j == list.size() - 1 && achou == -1) {\n\t\t\t\t\t\t\t\t\tindiceElementoNaoEncontrado = i;\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tString[] meses = { \"0\", \"0\", \"0\", \"0\", \"0\", \"0\", \"0\", \"0\", \"0\", \"0\", \"0\", \"0\" };\n\n\t\t\t\tMovimentoPorCanalDeVendaVO canalVendaVazio = new MovimentoPorCanalDeVendaVO();\n\t\t\t\tcanalVendaVazio.setCanalDeVenda(list.get(indiceElementoNaoEncontrado).getCanalDeVenda());\n\t\t\t\tcanalVendaVazio.setProduto(list.get(indiceElementoNaoEncontrado).getProduto());\n\t\t\t\tcanalVendaVazio.setTipo(\"Quantidade\");\n\t\t\t\tcanalVendaVazio.setMeses(meses);\n\n\t\t\t\tlist.add(((list.size() + 1) / 2 + indiceElementoNaoEncontrado), canalVendaVazio);// aqui\n\t\t\t\t/* estou ordenando tudo que é tipo 'Valor' antes de 'Quantidade' */\n\t\t\t} else {// Qtd eh maior\n\t\t\t\touter: for (int i = 0; i < list.size(); i++) {\n\t\t\t\t\tif (list.get(i).getTipo().equalsIgnoreCase(\"Quantidade\")) {\n\n\t\t\t\t\t\t// System.out.println();\n\t\t\t\t\t\t//\n\t\t\t\t\t\t// System.out.print(\" 1 | \"\n\t\t\t\t\t\t// + list.get(i).getCanalDeVenda());\n\t\t\t\t\t\t// System.out.println();\n\n\t\t\t\t\t\tfor (int j = 0; j < list.size(); j++) {\n\t\t\t\t\t\t\tint achou = -1;\n\t\t\t\t\t\t\tif (list.get(j).getTipo().equalsIgnoreCase(\"Valor\")) {\n\n\t\t\t\t\t\t\t\t// System.out.print(\" 2 | \"+\n\t\t\t\t\t\t\t\t// list.get(j).getCanalDeVenda());\n\t\t\t\t\t\t\t\t// System.out.println();\n\n\t\t\t\t\t\t\t\tif (list.get(i).getCanalDeVenda().equals(list.get(j).getCanalDeVenda())) {\n\t\t\t\t\t\t\t\t\tachou = j;\n\t\t\t\t\t\t\t\t\tcontinue outer;\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\tif (j == list.size() - 1 && achou == -1) {\n\t\t\t\t\t\t\t\t\tindiceElementoNaoEncontrado = i;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tString[] meses = { \"0\", \"0\", \"0\", \"0\", \"0\", \"0\", \"0\", \"0\", \"0\", \"0\", \"0\", \"0\" };\n\n\t\t\t\tMovimentoPorCanalDeVendaVO canalVendaVazio = new MovimentoPorCanalDeVendaVO();\n\t\t\t\tcanalVendaVazio.setCanalDeVenda(list.get(indiceElementoNaoEncontrado).getCanalDeVenda());\n\t\t\t\tcanalVendaVazio.setProduto(list.get(indiceElementoNaoEncontrado).getProduto());\n\t\t\t\tcanalVendaVazio.setTipo(\"Valor\");\n\t\t\t\tcanalVendaVazio.setMeses(meses);\n\n\t\t\t\tlist.add(((list.size() + 1) / 2 + indiceElementoNaoEncontrado), canalVendaVazio);// aqui\n\t\t\t\t/* estou ordenando tudo que é tipo 'Valor' antes de 'Quantidade' */\n\n\t\t\t}\n\n\t\t}\n\n\t\t/*\n\t\t * ===Primeiro crio os objetos com os totais=========\n\t\t */\n\t\tfor (MovimentoPorCanalDeVendaVO emi : list) {\n\n\t\t\tif (emi.getTipo().equals(\"Valor\")) {\n\n\t\t\t\tfor (int i = 0; i < emi.getMeses().length; i++) {\n\t\t\t\t\tmesesTotaisValor[i] = new BigDecimal(mesesTotaisValor[i]).add(new BigDecimal(emi.getMeses()[i]))\n\t\t\t\t\t\t\t.toString();\n\t\t\t\t}\n\n\t\t\t} else if (emi.getTipo().equals(\"Quantidade\")) {\n\n\t\t\t\tfor (int i = 0; i < emi.getMeses().length; i++) {\n\t\t\t\t\tmesesTotaisQuantidade[i] = Integer.toString(\n\t\t\t\t\t\t\t(Integer.parseInt(mesesTotaisQuantidade[i]) + Integer.parseInt(emi.getMeses()[i])));\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tanoTotal = emi.getAno();\n\t\t\tprodutoTotal = emi.getProduto();\n\n\t\t}\n\n\t\tMovimentoPorCanalDeVendaVO totalValor = new MovimentoPorCanalDeVendaVO();\n\t\tMovimentoPorCanalDeVendaVO totalQuantidade = new MovimentoPorCanalDeVendaVO();\n\n\t\ttotalValor.setCanalDeVenda(\"Total\");\n\t\ttotalValor.setProduto(produtoTotal);\n\t\ttotalValor.setTipo(\"Valor\");\n\t\ttotalValor.setAno(anoTotal);\n\t\ttotalValor.setMeses(mesesTotaisValor);\n\t\tlistTotal.add(totalValor);\n\n\t\ttotalQuantidade.setCanalDeVenda(\"Total\");\n\t\ttotalQuantidade.setProduto(produtoTotal);\n\t\ttotalQuantidade.setTipo(\"Quantidade\");\n\t\ttotalQuantidade.setAno(anoTotal);\n\t\ttotalQuantidade.setMeses(mesesTotaisQuantidade);\n\t\tlistTotal.add(totalQuantidade);\n\n\t\t/*\n\t\t * ===Agora calculo os percentuais=========\n\t\t */\n\n\t\tfinal int VALOR = 0;\n\t\tfinal int QUANTIDADE = 1;\n\n\t\tDecimalFormat percentForm = new DecimalFormat(\"0.00%\");\n\t\tDecimalFormat roundForm = new DecimalFormat(\"0.00\");\n\t\tUteis uteis = new Uteis();\n\t\tList<MovimentoPorCanalDeVendaVO> listFinal = new ArrayList<MovimentoPorCanalDeVendaVO>();\n\n\t\tfor (int i = 0; i < list.size() / 2; i++) {\n\t\t\tMovimentoPorCanalDeVendaVO emissaoValor = new MovimentoPorCanalDeVendaVO();\n\t\t\t/* ===VALOR==== */\n\t\t\temissaoValor.setCanalDeVenda(list.get(i).getCanalDeVenda());\n\t\t\temissaoValor.setTipo(list.get(i).getTipo());\n\t\t\temissaoValor.setMeses(list.get(i).getMeses());\n\n\t\t\tMovimentoPorCanalDeVendaVO emissaoValorPercent = new MovimentoPorCanalDeVendaVO();\n\t\t\t/* ===%=VALOR==== */\n\t\t\temissaoValorPercent.setCanalDeVenda(list.get(i).getCanalDeVenda());\n\t\t\temissaoValorPercent.setTipo(\"% \" + list.get(i).getTipo());\n\n\t\t\tString[] mesesPercentValor = new String[12];\n\t\t\tfor (int k = 0; k < list.get(i).getMeses().length; k++) {\n\n\t\t\t\ttry {\n\t\t\t\t\tdouble total = Double.parseDouble(new BigDecimal(list.get(i).getMeses()[k])\n\t\t\t\t\t\t\t.divide(new BigDecimal(listTotal.get(VALOR).getMeses()[k]), 5, RoundingMode.HALF_DOWN)\n\t\t\t\t\t\t\t.toString());\n\t\t\t\t\tmesesPercentValor[k] = percentForm.format(total);\n\n\t\t\t\t} catch (ArithmeticException e) {\n\t\t\t\t\tmesesPercentValor[k] = \"0%\";\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t}\n\t\t\temissaoValorPercent.setMeses(mesesPercentValor);\n\n\t\t\tMovimentoPorCanalDeVendaVO emissaoQuantidade = new MovimentoPorCanalDeVendaVO();\n\t\t\t/* ===QUANTIDADE==== */\n\t\t\tint j = list.size() / 2;\n\t\t\temissaoQuantidade.setCanalDeVenda(list.get(j + i).getCanalDeVenda());\n\t\t\temissaoQuantidade.setTipo(list.get(j + i).getTipo());\n\t\t\temissaoQuantidade.setMeses(list.get(j + i).getMeses());\n\n\t\t\tMovimentoPorCanalDeVendaVO emissaoQuantidadePercent = new MovimentoPorCanalDeVendaVO();\n\t\t\t/* ===%=QUANTIDADE==== */\n\t\t\temissaoQuantidadePercent.setCanalDeVenda(list.get(j + i).getCanalDeVenda());\n\t\t\temissaoQuantidadePercent.setTipo(\"% \" + list.get(j + i).getTipo());\n\n\t\t\tString[] mesesPercentQuantidade = new String[12];\n\t\t\tfor (int k = 0; k < list.get(j + i).getMeses().length; k++) {\n\n\t\t\t\ttry {\n\n\t\t\t\t\tdouble total = Double.parseDouble(list.get(j + i).getMeses()[k])\n\t\t\t\t\t\t\t/ Double.parseDouble(listTotal.get(QUANTIDADE).getMeses()[k]);\n\t\t\t\t\tmesesPercentQuantidade[k] = percentForm\n\t\t\t\t\t\t\t.format(Double.toString(total).equalsIgnoreCase(\"NaN\") ? 0.0 : total);\n\n\t\t\t\t} catch (ArithmeticException e) {\n\t\t\t\t\tmesesPercentQuantidade[k] = \"0%\";\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t}\n\t\t\temissaoQuantidadePercent.setMeses(mesesPercentQuantidade);\n\n\t\t\tString[] valorFormatado = new String[12];\n\t\t\tfor (int k = 0; k < emissaoValor.getMeses().length; k++) {\n\t\t\t\tvalorFormatado[k] = uteis\n\t\t\t\t\t\t.insereSeparadoresMoeda(roundForm.format(Double.parseDouble(emissaoValor.getMeses()[k])));\n\n\t\t\t}\n\t\t\temissaoValor.setMeses(valorFormatado);\n\n\t\t\tString[] valorFormatado2 = new String[12];\n\t\t\tfor (int k = 0; k < emissaoQuantidade.getMeses().length; k++) {\n\t\t\t\tvalorFormatado2[k] = uteis.insereSeparadores(emissaoQuantidade.getMeses()[k]);\n\t\t\t}\n\t\t\temissaoQuantidade.setMeses(valorFormatado2);\n\n\t\t\tlistFinal.add(emissaoValor);\n\t\t\tlistFinal.add(emissaoValorPercent);\n\t\t\tlistFinal.add(emissaoQuantidade);\n\t\t\tlistFinal.add(emissaoQuantidadePercent);\n\n\t\t}\n\n\t\treturn listFinal;\n\n\t}", "public String order(int amount) {\n if (this._noOfItems < 1) {\n return \"\"; // return empty if nothing to check for\n }\n // The string to return\n String resultString = \"\";\n // stores the previous items' sum of quantitys\n int prevQuantity = 0;\n FoodItem prevItem = null;\n FoodItem currentItem = null;\n // for each item in stock, and an extra loop to check the last\n for (int i = 0; i <= this._noOfItems; i++) {\n if (i != this._noOfItems) {\n currentItem = this._stock[i];\n }\n if (i > 0) {\n // if not same item as previous OR after last item (means we are checking for last item)\n if (i == this._noOfItems || (currentItem.getName() != prevItem.getName() ||\n currentItem.getCatalogueNumber() != prevItem.getCatalogueNumber())) {\n // if the total amount of all sames is less than parameter amount\n if (prevQuantity < amount) {\n // add comma and space if nothing have been added yet\n if (!(resultString.length() == 0)) {\n resultString+=\", \";\n }\n // add name to string\n resultString += prevItem.getName();\n }\n // reset quantity, as the next to be checked (means, the current) is different\n prevQuantity = 0;\n }\n }\n // sum the quantities - have already resetted if last or different\n prevQuantity += currentItem.getQuantity();\n // anyway, set the next loop prev item to this loop current.\n prevItem = currentItem;\n }\n return resultString;\n }", "public void Millas_M(){\r\n System.out.println(\"Cálcular Metros o Kilometros de Millas Marinas\");\r\n System.out.println(\"Ingrese un valor en Millas Marinas\");\r\n cadena =numero.next(); \r\n valor = metodo.Doble(cadena);\r\n valor = metodo.NegativoD(valor);\r\n totalM = valor * 1852 ;\r\n Millas_KM(totalM);\r\n }", "private String validateQuantityAmountNumPromotionShop(List<PromotionShopMap> lstPromotionShopMap) {\n\t\tint size = lstPromotionShopMap.size();\n\t\tint ALL_ALLOCATE = size;\n\t\tint NO_ALLOCATE = 0;\n\t\tint allocateQuantity = 0;\n\t\tint allocateAmount = 0;\n\t\tint allocateNum = 0;\n\t\tfor (int i = 0; i < size; i++) {\n\t\t\tPromotionShopMap psm = lstPromotionShopMap.get(i);\n\t\t\tif (psm.getQuantityMax() != null) {\n\t\t\t\tallocateQuantity++;\n\t\t\t}\n\t\t\tif (psm.getAmountMax() != null) {\n\t\t\t\tallocateAmount++;\n\t\t\t}\n\t\t\tif (psm.getNumMax() != null) {\n\t\t\t\tallocateNum++;\n\t\t\t}\n\t\t}\n\t\t// neu co phan bo thi phai phan bo tat ca cac dong\n\t\tif (NO_ALLOCATE < allocateQuantity && allocateQuantity < ALL_ALLOCATE) {\n\t\t\treturn Configuration.getResourceString(ConstantManager.VI_LANGUAGE, \"promotion.program.shop.no.allcate.all.quantity\");\n\t\t}\n\t\tif (NO_ALLOCATE < allocateAmount && allocateAmount < ALL_ALLOCATE) {\n\t\t\treturn Configuration.getResourceString(ConstantManager.VI_LANGUAGE, \"promotion.program.shop.no.allcate.all.amount\");\n\t\t}\n\t\tif (NO_ALLOCATE < allocateNum && allocateNum < ALL_ALLOCATE) {\n\t\t\treturn Configuration.getResourceString(ConstantManager.VI_LANGUAGE, \"promotion.program.shop.no.allcate.all.num\");\n\t\t}\n\t\t// phai phan bo it nhat 1 loai (so suat/so tien/so luong)\n\t\tif (allocateQuantity == NO_ALLOCATE && allocateAmount == NO_ALLOCATE && allocateNum == NO_ALLOCATE) {\n\t\t\treturn Configuration.getResourceString(ConstantManager.VI_LANGUAGE, \"promotion.program.shop.no.allocate.all\");\n\t\t}\n\t\treturn \"\";\n\t}", "private String getMiles(String numero) {\n String c = numero.substring(numero.length() - 3);\r\n //obtiene los miles\r\n String m = numero.substring(0, numero.length() - 3);\r\n String n = \"\";\r\n //se comprueba que miles tenga valor entero\r\n if (Integer.parseInt(m) > 0) {\r\n n = getCentenas(m);\r\n return n + \"mil \" + getCentenas(c);\r\n } else {\r\n return \"\" + getCentenas(c);\r\n }\r\n\r\n }", "float getAmount();", "private void calculateMediem(){\r\n int mediemNum = accountInTotal/2;\r\n Account mediemAccount = theAccounts.get(mediemNum);\r\n System.out.println(mediemAccount.toString());\r\n }", "private String getBillPrice() {\n double cost = 0.00;\n\n for (MenuItem item : bill.getItems()) {\n cost += (item.getPrice() * item.getQuantity());\n cost += item.getExtraIngredientPrice();\n cost -= item.getRemovedIngredientsPrice();\n }\n\n return String.format(\"%.2f\", cost);\n }", "List<Number> getTransactionAmounts(final StatisticalDTO dto);", "private int getUnitListValue() {\r\n\t\tint value = 0;\r\n\t\tfor (Unit unit : this.unitList) {\r\n\t\t\tvalue += unit.getValue();\r\n\t\t}\r\n\t\treturn value;\r\n\t}", "public String getAmount() {\r\n return this.amount;\r\n }", "public ArrayList<String> Distance(String from, float amount, String[] units) {\n\t\tfrom = findFrom(from);\n\t\tif (from.equals(\"meter\")) {\n\t\t\tArrayList<String> kaduvil = new ArrayList<String>();\n\t\t\tkaduvil.add(\"\" + amount + \" \" + units[0] );\n\t\t\tkaduvil.add(\"\" + amount / 1000 + \" \" + units[1] );\n\t\t\tkaduvil.add(\"\" + amount * 39.37007874 + \" \" + units[2] );\n\t\t\treturn kaduvil;\n\t\t} else {\n\t\t\tif (from.equals(\"inches\")) {\n\t\t\t\treturn Distance(\"meter\", amount / 39.37007874f, units);\n\t\t\t} else {\n\t\t\t\treturn Distance(\"meter\", amount * 1000, units);\n\t\t\t}\n\t\t}\n\t}", "public ArrayList<String> Volume(String from, float amount, String[] units) {\n\t\tfrom = findFrom(from);\n\t\tif (from.equals(\"liter\")) {\n\t\t\tArrayList<String> kaduvil = new ArrayList<String>();\n\t\t\tkaduvil.add(\"\" + amount + \" \" + units[0] );\n\t\t\tkaduvil.add(\"\" + amount * 1000 + \" \" + units[1] );\n\t\t\tkaduvil.add(\"\" + amount / 3.785411784f + \" \" + units[2] );\n\t\t\treturn kaduvil;\n\t\t} else {\n\t\t\tif (from.equals(\"US gallon\")) {\n\t\t\t\treturn Volume(\"liter\", amount * 3.785411784f, units);\n\t\t\t} else {\n\t\t\t\treturn Volume(\"liter\", amount / 1000, units);\n\t\t\t}\n\t\t}\n\t}", "public String getPuissanceCampMechant(){ \n Integer total = 0;\n total+=bonusTemporaireMechant;\n for(Monstre p : CampMechant)\n total += p.getPuissance(); \n return total.toString();\n }", "public List<Integer> getMemAmount(String delegation_name,String sports_name){\r\n\t\t\tList<Integer> list = new ArrayList<Integer>();\r\n\t\t\tList<String> list2 = new ArrayList<String>();\r\n\t\t\tConnection conn = DBConnect.getConnection();\r\n\t\t\tString sql = \"select count(athlete_name) as amount,sex from athlete where sports_name='\" + sports_name\r\n\t\t\t\t\t+ \"' and delegation_name='\" + delegation_name +\"' group by sex order by sex\";\r\n\t\t\ttry {\r\n\t\t\t\tPreparedStatement pst = conn.prepareStatement(sql);\r\n\t\t\t\tResultSet rst = pst.executeQuery();\r\n\t\t\t\twhile(rst.next()) {\r\n\t\t\t\t\tString amount = String.valueOf(rst.getInt(\"amount\"));\r\n\t\t\t\t\tString sex = rst.getString(\"sex\");\r\n\t\t\t\t\tlist2.add(amount);\r\n\t\t\t\t\tlist2.add(sex);\r\n\t\t\t\t}\r\n\t\t\t\tif(list2.size()==0) {\r\n\t\t\t\t\tlist.add(0);\r\n\t\t\t\t\tlist.add(0);\r\n\t\t\t\t}\r\n\t\t\t\telse if(list2.size()==2) {\r\n\t\t\t\t\tif(list2.get(1).equals(\"Female\")) {\r\n\t\t\t\t\t\tlist.add(Integer.parseInt(list2.get(0)));\r\n\t\t\t\t\t\tlist.add(0);\r\n\t\t\t\t\t}else {\r\n\t\t\t\t\t\tlist.add(0);\r\n\t\t\t\t\t\tlist.add(Integer.parseInt(list2.get(0)));\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\tlist.add(Integer.parseInt(list2.get(0)));\r\n\t\t\t\t\tlist.add(Integer.parseInt(list2.get(2)));\r\n\t\t\t\t}\r\n\t\t\t\trst.close();\r\n\t\t\t\tpst.close();\r\n\t\t\t}catch (SQLException e) {\r\n\t\t\t\t// TODO: handle exception\r\n\t e.printStackTrace();\t\t\t\r\n\t\t\t}\r\n\t\t\treturn list;\r\n\t\t}", "public String getAmount() {\n\n return amount.getText();\n }", "public void totalPrice(){\n int total = 0;\n\n if (list_order.isEmpty()) {\n totalHarga.setText(\"Rp. \" + 0);\n }\n else {\n for (int i = 0; i < list_order.size(); i++) {\n total += list_order.get(i).getHarga();\n }\n totalHarga.setText(\"Rp. \" + total);\n }\n }", "public BigDecimal getTaxAmtPriceList();", "Money getItemValue();", "public String getAmountString() {\n return amount + \"\";\n }", "public static void main(String[] args) {\n\t\tLocale.setDefault(Locale.US);\n\t\t//criando objeto do tipo Scanner que irá realizar a leitura padrão do teclado\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\t//cria uma lista do tipo TaxPlayer recebendo um new ArrayList\n\t\tList<TaxPlayer> list = new ArrayList<>();\n\t\t\n\t\t//solicita a informação de quantos contribuintes terão os dados lidos\n\t\tSystem.out.println(\"Enter the number of tax payers: \");\n\t\t//armazena a quantidade de contribuintes no atributo numberTaxPlayer\n\t\tint numberTaxPlayer = sc.nextInt();\n\t\t\n\t\t//laço for para que ocorra um loop conforme a quantidade de contribuintes que foi informado\n\t\tfor(int i=1; i<=numberTaxPlayer; i++) {\n\t\t\tSystem.out.println(\"\\nTax payer #\" + i + \" data: \");\n\t\t\t//solicitando que informe se é pessoa física ou jurídica\n\t\t\tSystem.out.println(\"Individual or company (i/c)? \");\n\t\t\t//armazenando no atributo op o caracter que foi digitado pelo usuário\n\t\t\tchar op = sc.next().charAt(0);\n\t\t\t//limpando o buffer\n\t\t\tsc.nextLine();\n\t\t\t//solicita a informação do nome do contribuinte\n\t\t\tSystem.out.println(\"Name: \");\n\t\t\t//armazena o nome do contribuinte no atributo name\n\t\t\tString name = sc.nextLine();\n\t\t\t//solicita a informação de quanto é a renda anual do contribuinte\n\t\t\tSystem.out.println(\"Anual income: \");\n\t\t\t//armazenando o valor da renda anual do contribuinte no atributo currentIncome\n\t\t\tdouble currentIncome = sc.nextDouble();\n\t\t\t\n\t\t\t//verifica se foi informado que o contribuinte é pessoa física ou jurídica\n\t\t\tif(op == 'i') {\n\t\t\t\t//solicita o valor dos gatos com saúde que o contribuinte teve durante o ano\n\t\t\t\tSystem.out.println(\"Health expenditures: \");\n\t\t\t\t//armazena no atributo healthExpenses o valor dos gastos com saúde\n\t\t\t\tdouble healthExpenses = sc.nextDouble();\n\t\t\t\t//adiciona na lista um new PhysicalPerson chamando o construtor da classe passando os dados do contribuinte como parâmetro\n\t\t\t\tlist.add(new PhysicalPerson(name, currentIncome, healthExpenses));\n\t\t\t}\n\t\t\telse if(op == 'c') {\n\t\t\t\t//solicita que o contribuinte informe quantos funcionários possui\n\t\t\t\tSystem.out.println(\"Number of employees: \");\n\t\t\t\t//armazena no atributo numberEmployees o número de funcionários\n\t\t\t\tint numberEmployees = sc.nextInt();\n\t\t\t\t//adiciona na lista um new LegalPerson chamando o construtor da classe passando os dados do contribuinte como parâmetro\n\t\t\t\tlist.add(new LegalPerson(name, currentIncome, numberEmployees));\n\t\t\t}\n\t\t}\n\t\t\t\n\t\t\t//instanciando e inicializando atributo que irá armazenar a soma da arrecadação de imposto\n\t\t\tdouble totalTax = 0;\n\t\t\t//percorre cada posição na lista\n\t\t\tSystem.out.println(\"\\nTAXES PAID: \");\n\t\t\tfor(TaxPlayer x : list) {\n\t\t\t\t//printando ome do contribuinte e a taxa de imposto a ser paga pelo contribuinte\n\t\t\t\tSystem.out.println(x.getName() + \": $\" + String.format(\"%.2f\", x.tax()));\n\t\t\t\t\n\t\t\t\t//somando a taxa de imposto a ser paga por cada contribuinte\n\t\t\t\ttotalTax += x.tax();\n\t\t\t}\n\t\t\t//printando a arrecação total de imposto\n\t\t\tSystem.out.println(\"\\nTOTAL TAXES: $\" + String.format(\"%.2f\", totalTax));\n\t\t\n\t//encerrando o objeto do tipo scanner que permite a entrada de dados padrão do teclado\n\tsc.close();\n\t}", "long getAmount();", "private void calculateBill() {\n\t\tif (unit <= 100) {\r\n\t\t\tbill = unit * 5;\r\n\t\t}else if(unit<=200){\r\n\t\t\tbill=((unit-100)*7+500);\r\n\t\t}else if(unit<=300){\r\n\t\t\tbill=((unit-200)*10+1200);\r\n\t\t}else if(unit>300){\r\n\t\t\tbill=((unit-300)*15+2200);\r\n\t\t}\r\n\t\tSystem.out.println(\"EB amount is :\"+bill);\r\n\t}", "public static void main(String[] args) {\n\t\tScanner entrada = new Scanner(System.in);\n\n\t\tint quantidade_de_mulheres_loiras_olhos_azuis_idade_entre_18_25_anos_solteiras_salario_maior_10000 = 0;\n\n\t\tdouble maiorSalario = 0;\n\t\tString nomeMaiorSalario = \"\";\n\n\t\tdouble menorSalario = 0;\n\t\tString nomeMenorSalario = \"\";\n\t\tfor (int i = 0; i < 50; i++) {\n\t\t\tSystem.out.print(\"Insira o nome: \");\n\t\t\tString nome = entrada.nextLine();\n\n\t\t\tSystem.out.print(\"Insira a idade: \");\n\t\t\tint idade = entrada.nextInt();\n\t\t\tentrada.nextLine();\n\n\t\t\tSystem.out.print(\"Insira o sexo: \");\n\t\t\tchar sexo = entrada.nextLine().charAt(0);\n\t\t\t// M = masculino\n\t\t\t// F = feminino\n\n\t\t\tSystem.out.print(\"Insira o estado Civil: \");\n\t\t\tchar estadoCivil = entrada.nextLine().charAt(0);\n\t\t\t// C = casado\n\t\t\t// S = solteiro\n\t\t\t// O = outros\n\n\t\t\tSystem.out.println(\"Insira a cor dos olhos: \");\n\t\t\tchar corDosOlhos = entrada.nextLine().charAt(0);\n\t\t\t// A = azul\n\t\t\t// C = castanho\n\t\t\t// P = preto\n\t\t\t// O = outros\n\t\t\tSystem.out.print(\"Insira a cor dos cabelos: \");\n\t\t\tchar corDosCabelos = entrada.nextLine().charAt(0);\n\t\t\t// L = Loiro\n\t\t\t// P = Preto\n\t\t\t// C = Castanho\n\t\t\t// R = Ruivo\n\n\t\t\tSystem.out.print(\"Insira o salário: R$\");\n\t\t\tdouble salario = entrada.nextDouble();\n\t\t\tentrada.nextLine();\n\n\t\t\tSystem.out.println(\"Insira a escolaridade: \");\n\t\t\tint escolaridade = entrada.nextInt();\n\t\t\tentrada.nextLine();\n\n\t\t\tif (sexo == 'F' && corDosCabelos == 'L' && corDosOlhos == 'A' && idade >= 18 && idade < 25\n\t\t\t\t\t&& estadoCivil == 'S' && salario > 10000 && escolaridade == 4) {\n\t\t\t\tquantidade_de_mulheres_loiras_olhos_azuis_idade_entre_18_25_anos_solteiras_salario_maior_10000++;\n\t\t\t}\n\n\t\t\tif (salario > maiorSalario) {\n\t\t\t\tmaiorSalario = salario;\n\t\t\t\tnomeMaiorSalario = nome;\n\t\t\t}\n\n\t\t\tif (salario < menorSalario || menorSalario == 0) {\n\t\t\t\tmenorSalario = salario;\n\t\t\t\tnomeMenorSalario = nome;\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(\n\t\t\t\t\"Quantidade de mulheres loiras, de olhos azuis, com idade entre 18 e 25 anos, solteiras, salário maior que R$10.000 e curso superior completo: \"\n\t\t\t\t\t\t+ quantidade_de_mulheres_loiras_olhos_azuis_idade_entre_18_25_anos_solteiras_salario_maior_10000);\n\t\tSystem.out.println(\"Nome da pessoa com maior salário: \" + nomeMaiorSalario);\n\t\tSystem.out.println(\"Diferença entre maior e menos salário: \" + (maiorSalario - menorSalario));\n\t\tentrada.close();\n\t}", "public List<FaturamentoVO> validaSelecionaSinistros(String ano, int tipo) {\n\t\tDecimalFormat roundForm = new DecimalFormat(\"0.00\");\n\n\t\tDecimalFormat percentForm = new DecimalFormat(\"0%\");\n\n\t\tUteis uteis = new Uteis();\n\t\tString anoAnterior = Integer.toString((Integer.parseInt(uteis.cortaRetornaAno(ano)) - 1));\n\n\t\tList<FaturamentoVO> listaTratada = new ArrayList<FaturamentoVO>();\n\n\t\tList<FaturamentoVO> listaAnoParam = dadosFaturamentoDetalhado;\n\t\tList<FaturamentoVO> listaAnoAnterior = dadosFaturamentoDetalhadoAnoAnterior;\n\n\t\tString quantidadeTextoBancoDados = \"\";\n\t\tString quantidadeTextoApresentacao = \"\";\n\t\tString valorTextoBancoDados = \"\";\n\t\tString valorTextoApresentacao = \"\";\n\n\t\tswitch (tipo) {\n\t\tcase 1: // AVISADO\n\t\t\tquantidadeTextoBancoDados = \"QT SINISTROS AVISADOS\";\n\t\t\tquantidadeTextoApresentacao = \"&nbsp;&nbsp;&nbsp;Quantidade&nbsp;&nbsp;&nbsp;\";\n\t\t\tvalorTextoBancoDados = \"SINISTROS AVISADOS\";\n\t\t\tvalorTextoApresentacao = \"Valor\";\n\t\t\tbreak;\n\t\tcase 2: // INDENIZADO\n\t\t\tquantidadeTextoBancoDados = \"QT SINISTROS INDENIZADOS\";\n\t\t\tquantidadeTextoApresentacao = \"&nbsp;&nbsp;&nbsp;Quantidade&nbsp;&nbsp;&nbsp;\";\n\t\t\tvalorTextoBancoDados = \"SINISTROS INDENIZADOS\";\n\t\t\tvalorTextoApresentacao = \"Valor\";\n\t\t\tbreak;\n\t\tcase 3: // PENDENTE\n\t\t\tquantidadeTextoBancoDados = \"QT SINISTROS PENDENTES\";\n\t\t\tquantidadeTextoApresentacao = \"&nbsp;&nbsp;&nbsp;Quantidade&nbsp;&nbsp;&nbsp;\";\n\t\t\tvalorTextoBancoDados = \"SINISTROS PENDENTES\";\n\t\t\tvalorTextoApresentacao = \"Valor\";\n\t\t\tbreak;\n\t\tcase 4: // DESPESA\n\t\t\tquantidadeTextoBancoDados = \"QT SINISTROS - DESPESAS\";\n\t\t\tquantidadeTextoApresentacao = \"&nbsp;&nbsp;&nbsp;Quantidade&nbsp;&nbsp;&nbsp;\";\n\t\t\tvalorTextoBancoDados = \"SINISTROS - DESPESAS\";\n\t\t\tvalorTextoApresentacao = \"Valor\";\n\t\t\tbreak;\n\n\t\t}\n\n\t\tfor (int i = 0; i < listaAnoParam.size(); i++) {\n\t\t\tif (listaAnoParam.get(i).getProduto().equals(quantidadeTextoBancoDados)) {\n\n\t\t\t\tFaturamentoVO sinistroVOtratado = new FaturamentoVO();\n\t\t\t\tString mesesTratado[] = new String[13];\n\n\t\t\t\tsinistroVOtratado.setAno(uteis.cortaRetornaAno(ano));\n\t\t\t\tsinistroVOtratado.setProduto(quantidadeTextoApresentacao);\n\n\t\t\t\tint somaTotal = 0;\n\t\t\t\tfor (int k = 0; k <= 12; k++) {\n\n\t\t\t\t\tif (k != 12) {\n\t\t\t\t\t\tsomaTotal += Integer.parseInt(listaAnoParam.get(i).getMeses()[k]);\n\n\t\t\t\t\t\tmesesTratado[k] = uteis.insereSeparadores(listaAnoParam.get(i).getMeses()[k]);\n\n\t\t\t\t\t} else { // total\n\n\t\t\t\t\t\tmesesTratado[k] = uteis.insereSeparadores(String.valueOf(somaTotal));\n\n\t\t\t\t\t}\n\t\t\t\t\tsinistroVOtratado.setMeses(mesesTratado);\n\t\t\t\t}\n\t\t\t\tlistaTratada.add(sinistroVOtratado);\n\n\t\t\t} else if (listaAnoParam.get(i).getProduto().equals(valorTextoBancoDados)) {\n\n\t\t\t\tFaturamentoVO faturamentoVOtratado = new FaturamentoVO();\n\t\t\t\tString mesesTratado[] = new String[13];\n\n\t\t\t\tfaturamentoVOtratado.setAno(uteis.cortaRetornaAno(ano));\n\t\t\t\tfaturamentoVOtratado.setProduto(valorTextoApresentacao);\n\n\t\t\t\tdouble somaTotal = 0.0;\n\t\t\t\tfor (int k = 0; k <= 12; k++) {\n\n\t\t\t\t\tif (k != 12) {\n\n\t\t\t\t\t\tsomaTotal += Double.parseDouble(listaAnoParam.get(i).getMeses()[k]);\n\n\t\t\t\t\t\tString tratada = roundForm.format(Double.parseDouble(listaAnoParam.get(i).getMeses()[k]));\n\n\t\t\t\t\t\tmesesTratado[k] = uteis.insereSeparadores(tratada);\n\n\t\t\t\t\t} else { // total\n\n\t\t\t\t\t\tString tratada = roundForm.format(somaTotal);\n\n\t\t\t\t\t\tmesesTratado[k] = uteis.insereSeparadores(tratada);\n\n\t\t\t\t\t}\n\n\t\t\t\t\tfaturamentoVOtratado.setMeses(mesesTratado);\n\t\t\t\t}\n\t\t\t\tlistaTratada.add(faturamentoVOtratado);\n\n\t\t\t}\n\t\t} // for anoParam\n\n\t\tfor (int i = 0; i < listaAnoAnterior.size(); i++) {\n\t\t\tif (listaAnoAnterior.get(i).getProduto().equals(quantidadeTextoBancoDados)) {\n\n\t\t\t\tFaturamentoVO sinistroVOtratado = new FaturamentoVO();\n\t\t\t\tString mesesTratado[] = new String[13];\n\n\t\t\t\tsinistroVOtratado.setAno(anoAnterior);\n\t\t\t\tsinistroVOtratado.setProduto(quantidadeTextoApresentacao);\n\n\t\t\t\tint somaTotal = 0;\n\t\t\t\tfor (int k = 0; k <= 12; k++) {\n\n\t\t\t\t\tif (k != 12) {\n\n\t\t\t\t\t\tsomaTotal += Integer.parseInt(listaAnoAnterior.get(i).getMeses()[k]);\n\n\t\t\t\t\t\tmesesTratado[k] = uteis.insereSeparadores(listaAnoAnterior.get(i).getMeses()[k]);\n\n\t\t\t\t\t} else { // total\n\n\t\t\t\t\t\tmesesTratado[k] = uteis.insereSeparadores(String.valueOf(somaTotal));\n\n\t\t\t\t\t}\n\t\t\t\t\tsinistroVOtratado.setMeses(mesesTratado);\n\n\t\t\t\t}\n\t\t\t\tlistaTratada.add(sinistroVOtratado);\n\n\t\t\t} else if (listaAnoAnterior.get(i).getProduto().equals(valorTextoBancoDados)) {\n\t\t\t\tFaturamentoVO faturamentoVOtratado = new FaturamentoVO();\n\t\t\t\tString mesesTratado[] = new String[13];\n\n\t\t\t\tfaturamentoVOtratado.setAno(anoAnterior);\n\t\t\t\tfaturamentoVOtratado.setProduto(valorTextoApresentacao);\n\n\t\t\t\tdouble somaTotal = 0.0;\n\t\t\t\tfor (int k = 0; k <= 12; k++) {\n\n\t\t\t\t\tif (k != 12) {\n\n\t\t\t\t\t\tsomaTotal += Double.parseDouble(listaAnoAnterior.get(i).getMeses()[k]);\n\n\t\t\t\t\t\tString tratada = roundForm.format(Double.parseDouble(listaAnoAnterior.get(i).getMeses()[k]));\n\n\t\t\t\t\t\tmesesTratado[k] = uteis.insereSeparadores(tratada);\n\n\t\t\t\t\t} else { // total\n\n\t\t\t\t\t\tString tratada = roundForm.format(somaTotal);\n\n\t\t\t\t\t\tmesesTratado[k] = uteis.insereSeparadores(tratada);\n\n\t\t\t\t\t}\n\n\t\t\t\t\tfaturamentoVOtratado.setMeses(mesesTratado);\n\t\t\t\t}\n\t\t\t\tlistaTratada.add(faturamentoVOtratado);\n\n\t\t\t}\n\t\t} // for anoAnterior\n\n\t\tbyte qtdAnoParam = 0;\n\t\tbyte qtdAnoAnterior = 2;\n\n\t\tbyte vlrAnoParam = 1;\n\t\tbyte vlrAnoAnterior = 3;\n\n\t\t// *******************************************\n\t\t// *******************************************\n\t\t// Variacao 16/15 QTD\n\t\tString[] mesesQtdTratado = new String[13];\n\t\tdouble totalQtd = 0.0D;\n\t\tFaturamentoVO variacaoQtdVO = new FaturamentoVO();\n\n\t\tfor (int j = 0; j <= 12; j++) {\n\t\t\tBigDecimal bigQtdAnoParam = new BigDecimal(\n\t\t\t\t\tDouble.parseDouble(listaTratada.get(qtdAnoParam).getMeses()[j].replace(\".\", \"\")));\n\n\t\t\ttry {\n\t\t\t\ttotalQtd = Double.parseDouble((bigQtdAnoParam.divide(\n\t\t\t\t\t\tnew BigDecimal(listaTratada.get(qtdAnoAnterior).getMeses()[j].replace(\".\", \"\")), 4,\n\t\t\t\t\t\tRoundingMode.HALF_DOWN)).toString()) - 1;\n\t\t\t} catch (Exception e) {\n\t\t\t\ttotalQtd = 0D;\n\t\t\t}\n\n\t\t\tmesesQtdTratado[j] = percentForm.format(totalQtd);\n\n\t\t}\n\t\tvariacaoQtdVO.setProduto(\"Varia&ccedil;&atilde;o Qtd.\");\n\t\tvariacaoQtdVO.setMeses(mesesQtdTratado);\n\t\tlistaTratada.add(variacaoQtdVO);\n\n\t\t// *******************************************\n\t\t// *******************************************\n\t\t// Variacao 16/15 Valor\n\t\tString[] mesesVlrTratado = new String[13];\n\t\tdouble totalVlr = 0.0D;\n\t\tFaturamentoVO variacaoVlrVO = new FaturamentoVO();\n\n\t\tfor (int j = 0; j <= 12; j++) {\n\n\t\t\tBigDecimal bigVlrAnoParam = new BigDecimal(\n\t\t\t\t\tDouble.parseDouble(listaTratada.get(vlrAnoParam).getMeses()[j].replace(\".\", \"\").replace(\",\", \".\")));\n\n\t\t\ttry {\n\t\t\t\ttotalVlr = Double.parseDouble((bigVlrAnoParam.divide(\n\t\t\t\t\t\tnew BigDecimal(\n\t\t\t\t\t\t\t\tlistaTratada.get(vlrAnoAnterior).getMeses()[j].replace(\".\", \"\").replace(\",\", \".\")),\n\t\t\t\t\t\t4, RoundingMode.HALF_DOWN)).toString()) - 1;\n\t\t\t} catch (Exception e) {\n\t\t\t\ttotalVlr = 0D;\n\t\t\t}\n\n\t\t\tmesesVlrTratado[j] = percentForm.format(totalVlr);\n\n\t\t}\n\t\tvariacaoVlrVO.setProduto(\"Varia&ccedil;&atilde;o Valor\");\n\t\tvariacaoVlrVO.setMeses(mesesVlrTratado);\n\t\tlistaTratada.add(variacaoVlrVO);\n\n\t\t// *******************************************\n\t\t// *******************************************\n\t\t// Aviso Medio anoParam - anoAtual\n\t\tString[] mesesAvisoMedioAnoParamTratado = new String[13];\n\t\tdouble totalAvisoMedioAnoParam = 0.0D;\n\t\tFaturamentoVO variacaoAvisoMedioAnoParamVO = new FaturamentoVO();\n\n\t\tfor (int j = 0; j <= 12; j++) {\n\n\t\t\tBigDecimal bigVlrAnoParam = new BigDecimal(\n\t\t\t\t\tDouble.parseDouble(listaTratada.get(vlrAnoParam).getMeses()[j].replace(\".\", \"\").replace(\",\", \".\")));\n\n\t\t\ttry {\n\t\t\t\ttotalAvisoMedioAnoParam = Double.parseDouble((bigVlrAnoParam.divide(\n\t\t\t\t\t\tnew BigDecimal(listaTratada.get(qtdAnoParam).getMeses()[j].replace(\".\", \"\").replace(\",\", \".\")),\n\t\t\t\t\t\t2, RoundingMode.HALF_DOWN)).toString());\n\t\t\t} catch (Exception e) {\n\t\t\t\ttotalAvisoMedioAnoParam = 0D;\n\t\t\t}\n\t\t\tmesesAvisoMedioAnoParamTratado[j] = uteis.insereSeparadoresMoeda(roundForm.format(totalAvisoMedioAnoParam));\n\n\t\t}\n\t\tvariacaoAvisoMedioAnoParamVO.setAno(uteis.cortaRetornaAno(ano));\n\t\tvariacaoAvisoMedioAnoParamVO.setProduto(\"Aviso M&eacute;dio\");\n\t\tvariacaoAvisoMedioAnoParamVO.setMeses(mesesAvisoMedioAnoParamTratado);\n\t\tlistaTratada.add(variacaoAvisoMedioAnoParamVO);\n\n\t\t// *******************************************\n\t\t// *******************************************\n\t\t// Aviso Medio anoAnterior\n\t\tString[] mesesAvisoMedioAnoAnteriorTratado = new String[13];\n\t\tdouble totalAvisoMedioAnoAnterior = 0.0D;\n\t\tFaturamentoVO variacaoAvisoMedioAnoAnteriorVO = new FaturamentoVO();\n\n\t\tfor (int j = 0; j <= 12; j++) {\n\n\t\t\tBigDecimal bigVlrAnoAnterior = new BigDecimal(Double\n\t\t\t\t\t.parseDouble(listaTratada.get(vlrAnoAnterior).getMeses()[j].replace(\".\", \"\").replace(\",\", \".\")));\n\n\t\t\ttry {\n\t\t\t\ttotalAvisoMedioAnoAnterior = Double.parseDouble((bigVlrAnoAnterior.divide(\n\t\t\t\t\t\tnew BigDecimal(listaTratada.get(qtdAnoAnterior).getMeses()[j].replace(\".\", \"\")), 2,\n\t\t\t\t\t\tRoundingMode.HALF_DOWN)).toString());\n\t\t\t} catch (Exception e) {\n\t\t\t\ttotalAvisoMedioAnoAnterior = 0D;\n\t\t\t}\n\t\t\tmesesAvisoMedioAnoAnteriorTratado[j] = uteis\n\t\t\t\t\t.insereSeparadoresMoeda(roundForm.format(totalAvisoMedioAnoAnterior));\n\n\t\t}\n\t\tvariacaoAvisoMedioAnoAnteriorVO.setAno(anoAnterior);\n\t\tvariacaoAvisoMedioAnoAnteriorVO.setProduto(\"Aviso M&eacute;dio\");\n\t\tvariacaoAvisoMedioAnoAnteriorVO.setMeses(mesesAvisoMedioAnoAnteriorTratado);\n\t\tlistaTratada.add(variacaoAvisoMedioAnoAnteriorVO);\n\n\t\t// *******************************************\n\t\t// *******************************************\n\t\t// Variacao Media\n\t\tshort avisoMedioAnoParam = 6;\n\t\tshort avisoMedioAnoAnterior = 7;\n\n\t\tString[] meses_AM_Tratado = new String[13];// AM -aviso medio\n\t\tdouble total_AM = 0.0D;\n\t\tFaturamentoVO variacao_AM_VO = new FaturamentoVO();\n\n\t\tfor (int j = 0; j <= 12; j++) {\n\n\t\t\tBigDecimal big_AM_AnoParam = new BigDecimal(Double.parseDouble(\n\t\t\t\t\tlistaTratada.get(avisoMedioAnoParam).getMeses()[j].replace(\".\", \"\").replace(\",\", \".\")));\n\n\t\t\ttry {\n\t\t\t\ttotal_AM = Double\n\t\t\t\t\t\t.parseDouble((big_AM_AnoParam\n\t\t\t\t\t\t\t\t.divide(new BigDecimal(listaTratada.get(avisoMedioAnoAnterior).getMeses()[j]\n\t\t\t\t\t\t\t\t\t\t.replace(\".\", \"\").replace(\",\", \".\")), 4, RoundingMode.HALF_DOWN)).toString())\n\t\t\t\t\t\t- 1;\n\t\t\t} catch (Exception e) {\n\t\t\t\ttotal_AM = 0D;\n\t\t\t}\n\n\t\t\tmeses_AM_Tratado[j] = percentForm.format(total_AM);\n\n\t\t}\n\t\tvariacao_AM_VO.setProduto(\"Varia&ccedil;&atilde;o M&eacute;dia\");\n\t\tvariacao_AM_VO.setMeses(meses_AM_Tratado);\n\t\tlistaTratada.add(variacao_AM_VO);\n\n\t\treturn listaTratada;\n\t}", "private String getMillones(String numero) {\n String miles = numero.substring(numero.length() - 6);\r\n //se obtiene los millones\r\n String millon = numero.substring(0, numero.length() - 6);\r\n String n = \"\";\r\n if (millon.length() > 1) {\r\n n = getCentenas(millon) + \"millones \";\r\n } else {\r\n n = getUnidades(millon) + \"millon \";\r\n }\r\n return n + getMiles(miles);\r\n }", "public List quantInscritosVestibular(String vest_info);", "@Override\n public float getAmount() {\n return Float.parseFloat(inputAmount.getText());\n }", "private HashMap<Integer, Integer> obtainBills(double amount)\n {\n HashMap<Integer, Integer> bills = new HashMap<>();\n bills.put(5, 0);\n bills.put(10, 0);\n bills.put(20, 0);\n bills.put(50, 0);\n return obtainBills(amount, bills);\n }", "public BigDecimal getPriceListEntered();", "int getAmount();", "public String getAmount() {\n return amount;\n }", "public String getAmount() {\n return amount;\n }", "public void calcularTotal() {\n double valor = 0;\n String servico = (String)consultaSelecionada.getSelectedItem().toString();\n switch(servico) {\n case \"Consulta\":\n valor += 100;\n break;\n case \"Limpeza\":\n valor += 130;\n break;\n case \"Clareamento\":\n valor += 450;\n break;\n case \"Aparelho\":\n valor += 100;\n break;\n case \"Raio-x\":\n valor += 80;\n break;\n case \"Cirurgia\":\n valor += 70;\n break;\n }\n Total.setText(String.valueOf(valor));\n }", "@Override\n\tpublic String toString() {\n\t\treturn \"\" + nome + \",\" + String.format(\"%.2f\", getPrecoTotal());\n\t}", "public static double totalcommision(int salesman_id) {\r\n\r\n\t\tResultSet rs = null;\r\n\r\n\t\tdouble total_amount = 0;\r\n\r\n\t\tString query = \"SELECT DISTINCT(appliance_name) AS apname ,(SELECT CountNumberAppliance(apname,\"\r\n\t\t\t\t+ salesman_id + \")) FROM appliance\";\r\n\t\tint count;\r\n\t\tString name;\r\n\t\ttry (Connection con = Connect.getConnection()) {\r\n\r\n\t\t\tPreparedStatement stmt = (PreparedStatement) con\r\n\t\t\t\t\t.prepareStatement(query);\r\n\t\t\trs = stmt.executeQuery();\r\n\t\t\tSystem.out.println(query);\r\n\r\n\t\t\twhile (rs.next()) {\r\n\t\t\t\tname = rs.getString(1);\r\n\t\t\t\tif (name.equalsIgnoreCase(\"5 wott\")) {\r\n\t\t\t\t\tcount = rs.getInt(2);\r\n\r\n\t\t\t\t\tif ((count >= 10) && (count <= 20)) {\r\n\t\t\t\t\t\ttotal_amount = count * 5;\r\n\t\t\t\t\t} else if ((count >= 21) && (count <= 35)) {\r\n\t\t\t\t\t\ttotal_amount = count * 10;\r\n\t\t\t\t\t} else if ((count >= 36) && (count <= 50)) {\r\n\t\t\t\t\t\ttotal_amount = count * 20;\r\n\t\t\t\t\t} else if ((count >= 51)) {\r\n\t\t\t\t\t\ttotal_amount = count * 30;\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t} else if (name.equalsIgnoreCase(\"10 wott\")) {\r\n\t\t\t\t\tcount = rs.getInt(2);\r\n\r\n\t\t\t\t\tif ((count >= 10) && (count <= 20)) {\r\n\t\t\t\t\t\ttotal_amount = count * 15;\r\n\t\t\t\t\t} else if ((count >= 21) && (count <= 35)) {\r\n\t\t\t\t\t\ttotal_amount = count * 10;\r\n\t\t\t\t\t} else if ((count >= 36) && (count <= 50)) {\r\n\t\t\t\t\t\ttotal_amount = count * 20;\r\n\t\t\t\t\t} else if ((count >= 51)) {\r\n\t\t\t\t\t\ttotal_amount = count * 30;\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t} else if (name.equalsIgnoreCase(\"15 wott\")) {\r\n\t\t\t\t\tcount = rs.getInt(2);\r\n\r\n\t\t\t\t\tif ((count >= 10) && (count <= 20)) {\r\n\t\t\t\t\t\ttotal_amount = count * 35;\r\n\t\t\t\t\t} else if ((count >= 21) && (count <= 35)) {\r\n\t\t\t\t\t\ttotal_amount = count * 45;\r\n\t\t\t\t\t} else if ((count <= 36) && (count <= 50)) {\r\n\t\t\t\t\t\ttotal_amount = count * 55;\r\n\t\t\t\t\t} else if ((count <= 51)) {\r\n\t\t\t\t\t\ttotal_amount = count * 65;\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t} else if (name.equalsIgnoreCase(\"20 wott\")) {\r\n\t\t\t\t\tcount = rs.getInt(2);\r\n\r\n\t\t\t\t\tif ((count >= 10) && (count <= 20)) {\r\n\t\t\t\t\t\ttotal_amount = count * 45;\r\n\t\t\t\t\t} else if ((count >= 21) && (count <= 35)) {\r\n\t\t\t\t\t\ttotal_amount = count * 55;\r\n\t\t\t\t\t} else if ((count >= 36) && (count <= 50)) {\r\n\t\t\t\t\t\ttotal_amount = count * 65;\r\n\t\t\t\t\t} else if ((count >= 51)) {\r\n\t\t\t\t\t\ttotal_amount = count * 75;\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t}\r\n\r\n\t\t\t}\r\n\r\n\t\t} catch (SQLException e) {\r\n\t\t\tlogger.error(\"\", e);\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t\treturn total_amount;\r\n\t}", "private String marketSellAmounts() {\r\n\t\tint[] amounts= market.getSellAmounts();\r\n\t\tString out = \"Sell Requests Are: \";\r\n\t\tfor(int i=0; i<amounts.length;i++) {\r\n\t\t\tout=out.concat(i+\": \"+amounts[i]+\" || \");\r\n\t\t}\r\n\t\treturn out;\r\n\t}", "public ArrayList<String> Area(String from, float amount, String[] units) {\n\t\tArrayList<String> kaduvil = new ArrayList<String>();\n\t\tkaduvil.add(\"Weird bugs here.\");\n\t\treturn kaduvil;\n//\t\tfrom = findFrom(from);\n//\t\tif (from.equals(\"square inch\")) {\n//\t\t\tArrayList<String> kaduvil = new ArrayList<String>();\n//\t\t\tkaduvil.add(\"\" + amount + \" square inch\");\n//\t\t\tkaduvil.add(\"\" + amount / (1.5500031f * Math.pow(10, 9)) + \" square kilometer\");\n//\t\t\tkaduvil.add(\"\" + amount / 1550.0031f + \" square meter\");\n//\t\t\treturn kaduvil;\n//\t\t} else {\n//\t\t\tif (from.equals(\"square meter\")) {\n//\t\t\t\treturn Area(\"square inch\", (amount * 1550.0031f) );\n//\t\t\t} else {\n//\t\t\t\tfloat a = (float)(amount * (1.5500031f * Math.pow(10, 9)));\n//\t\t\t\treturn Area(\"square inch\", a);\n//\t\t\t}\n//\t\t}\n\t}", "public void setAmount(String amount) {\r\n this.amount = amount;\r\n }", "private String marketBuyAmounts() {\r\n\t\tint[] amounts= market.getBuyAmounts();\r\n\t\tString out = \"Buy Requests Are: \";\r\n\t\tfor(int i=0; i<amounts.length;i++) {\r\n\t\t\tout=out.concat(i+\": \"+amounts[i]+\" || \");\r\n\t\t}\r\n\t\treturn out;\r\n\t}", "public void calculateAmount() {\n totalAmount = kurv.calculateTotalAmount() + \" DKK\";\n headerPrice.setText(totalAmount);\n }", "private String calculateDistancePerAmount() {\n double distance = parser(getTextFromEditText(R.id.distanceEdit));\n double fuel = parser(getTextFromEditText(R.id.fuelEdit));\n double value = distance / fuel;\n return rounder(value);\n }", "public String getAllMinionNames() throws SQLException {\n PreparedStatement selectAllMinionNamesStmt = this.connection.prepareStatement(Queries.SELECT_ALL_MINION_NAMES);\n ResultSet resultSetWithMinionNames = selectAllMinionNamesStmt.executeQuery();\n\n List<String> minionNamesInOriginalOrder = new ArrayList<>();\n\n while (resultSetWithMinionNames.next()) {\n minionNamesInOriginalOrder.add(this.getResultForOneRecord(resultSetWithMinionNames).toString());\n }\n\n StringBuilder outputMinionNames = new StringBuilder();\n\n //If the records count is even\n if (minionNamesInOriginalOrder.size() % 2 == 0) {\n for (int i = 0; i < minionNamesInOriginalOrder.size() / 2; i++) {\n outputMinionNames.append(minionNamesInOriginalOrder.get(i)).append(System.lineSeparator());\n outputMinionNames.append(minionNamesInOriginalOrder.get(minionNamesInOriginalOrder.size() - 1 - i));\n if (i < minionNamesInOriginalOrder.size() / 2 - 1) {\n outputMinionNames.append(System.lineSeparator());\n }\n }\n } else { //If it is odd\n for (int i = 0; i <= minionNamesInOriginalOrder.size() / 2; i++) {\n //This is the middle record in the minion table, if the count is odd.\n if (i == minionNamesInOriginalOrder.size() / 2) {\n outputMinionNames.append(minionNamesInOriginalOrder.get(i));\n } else {\n outputMinionNames.append(minionNamesInOriginalOrder.get(i)).append(System.lineSeparator());\n outputMinionNames.append(minionNamesInOriginalOrder.get(minionNamesInOriginalOrder.size() - 1 - i)).append(System.lineSeparator());\n }\n }\n }\n\n return outputMinionNames.toString();\n }", "public String getTotalFareAmt()\n\t{\n\n\t\tString totalamt = totalFareAmount.getText().replaceAll(\"[Rs ,]\", \"\");\n\n\t\treturn String.valueOf(totalamt);\n\t}", "public int getTotalAmount();", "public void setAmount(String amount) {\n this.amount = amount;\n }", "@Override\n public String getName()\n {\n if (amount > 1)\n {\n return amount + \" Nickles\";\n }\n else\n {\n return amount + \" Nickle\";\n }\n }", "private void checkAmount() throws IOException {\n //System.out.println(\"The total amount in the cash machine is: \" + amountOfCash);\n for (int i : typeOfCash.keySet()) {\n Integer r = typeOfCash.get(i);\n if (r < 20) {\n sendAlert(i);\n JOptionPane.showMessageDialog(null, \"$\" + i + \"bills are out of stock\");\n }\n }\n }", "public Bill(String type, int people, double amount, ArrayList<String> nameList) {\n this.type = type;\n this.people = people;\n this.amount = amount;\n this.nameList = nameList;\n }", "java.util.List<frame.socket.common.proto.Login.ActAmount> \n getActAmountList();", "public void agregarVolumenes(String[] volumenes) {\n for (String volumen : volumenes) {\n if(Double.parseDouble(volumen) < 1){\n desplegableVolumen.addItem(Double.toString(Double.parseDouble(volumen)*1000) + \"ml\");\n }else{\n desplegableVolumen.addItem(volumen + \"L\");\n }\n \n }\n }", "public static void extract_money(){\n TOTALCMONEY = TOTALCMONEY - BALANCERETRIEVE; //the total cashier money equals the total cashier money minus the retrieve request\r\n BALANCE = BALANCE - BALANCERETRIEVE; //the user balance equals the account minus the retrieve request\r\n }", "public void setMinAmount(int min) {\n _min = min;\n }", "public List<Double> getmasseslist(){return masses;}", "private void filterPerName(EntityManager em) {\n System.out.println(\"Please enter the name: \");\n Scanner sc = new Scanner(System.in);\n //Debug : String name = \"Sel\";\n\n String name = sc.nextLine();\n\n TypedQuery<Permesso> query = em.createQuery(\"select p from com.hamid.entity.Permesso p where p.nome like '%\"+ name\n + \"%'\" , Permesso.class);\n\n List<Permesso> perList = query.getResultList();\n\n for (Permesso p : perList) {\n System.out.println(p.getNome());\n }\n }", "@When(\"^the user enters 'Mortgage amount = £(\\\\d+),(\\\\d+)'$\")\r\n\tpublic void the_user_enters_Mortgage_amount_£(int arg1, int arg2) throws Throwable {\n\t\tdriver.findElement(By.xpath(\"//input[@id='SearchMortgageAmount']\")).sendKeys(\"150000\");\r\n\t\tSystem.out.println(\"user entered 'Mortgage amount\");\r\n\r\n\t}", "ch.crif_online.www.webservices.crifsoapservice.v1_00.Amount getAmount();", "private String bulkorderqtycalculation() {\n String strSubtotal = estimatedSubTotalPriceDisplayShoppingCart.getText();\n float intSubtotal = Float.parseFloat(strSubtotal.replaceAll(\"[^0-9.]\", \"\"));\n DecimalFormat df = new DecimalFormat(\"#\");\n String forSubtotal = df.format(intSubtotal);\n int forIntSubtotal = Integer.parseInt(forSubtotal);\n System.out.println(\"=== Subtotal after trimming: \" + forIntSubtotal);\n int reqqty = 0;\n reqqty = (3000 / forIntSubtotal);\n System.out.println(\"=== Qty Require is: \" + reqqty);\n String qtystr = String.valueOf(reqqty);\n return qtystr;\n }", "public String[] redeemMiles(int miles, int month)\n {\n ArrayList<String> descriptions = new ArrayList<String>();\n ArrayList<String> places = new ArrayList<String>();\n\n this.miles = miles;\n \n for (Destination destination : this.destinationList)\n {\n // are we in a frequent flyer month? \n if (month >= destination.getFrequentFlyerProgramStartMonth() && month <= destination.getFrequentFlyerProgramEndMonth())\n {\n // if we are do we have enough frequent flyer miles?\n if (this.miles >= destination.getFrequentFlyerMiles())\n {\n // if we do add that destination to array of destinations\n descriptions.add(\"A trip to \" + destination.getCityName() + \" in Economy Class \" );\n places.add(destination.getCityName());\n\n // subtract miles\n this.miles = this.miles - destination.getFrequentFlyerMiles();\n }\n }\n // otherwise it's not a frequent flyer month\n else\n {\n // see if we have enough miles for this destinations normal miles \n if (this.miles >= destination.getNormalMiles())\n {\n // add the destination to list of places\n descriptions.add(\"A trip to \" + destination.getCityName() + \" in Economy Class \" );\n places.add(destination.getCityName());\n\n // deduct the miles\n this.miles = this.miles - destination.getNormalMiles();\n }\n }\n \n }\n\n // go through all the destinations\n for (Destination destination : this.destinationList)\n {\n // if we have visited that place in economy\n if (places.contains(destination.getCityName()))\n {\n // see if can we afford to upgrade to first class\n if ((this.miles >= destination.getAdditionalMilesForUpgrading()))\n {\n descriptions.set(descriptions.indexOf(\"A trip to \" + destination.getCityName() + \" in Economy Class \"), \"A trip to \" + destination.getCityName() + \" in First Class \"); \n \n // deduct the miles\n this.miles = this.miles - destination.getAdditionalMilesForUpgrading(); \n }\n }\n }\n\n // return all the arry with strings of where we can go and what tickets \n return descriptions.toArray(new String[0]);\n }", "public int incloan()\n {\n SQLiteDatabase db1 = this.getReadableDatabase();\n String stmt = \"SELECT SUM(AMOUNT) FROM INCOME GROUP BY TYPE HAVING TYPE='LOAN'\";\n Cursor tot = db1.rawQuery(stmt, null);\n if(tot.getCount()==0)\n {\n return 0;\n }\n else {\n tot.moveToFirst();\n int amount = tot.getInt(0);\n tot.close();\n return amount;\n }\n }", "private String money() {\r\n\t\tint[] m =tile.getAgentMoney();\r\n\t\tString out =\"Agent Money: \\n\";\r\n\t\tint total=0;\r\n\t\tint square=(int)Math.sqrt(m.length);\r\n\t\tif(square*square<m.length) {\r\n\t\t\tsquare++;\r\n\t\t}\r\n\t\tfor(int i=0; i<m.length;) {\r\n\t\t\tfor(int j=0; j<square; j++) {\r\n\t\t\t\tif(i<m.length) {\r\n\t\t\t\t\tout=out.concat(String.format(\"%8s\", m[i]+\"\"));\r\n\t\t\t\t\ttotal=total+m[i];\r\n\t\t\t\t\ti++;\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\tj=square;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tout=out.concat(\"\\n\");\r\n\t\t}\r\n\t\tout=out.concat(\"Agent Total: \"+total);\r\n\t\tint companyTotal=0;\r\n\t\tout=out.concat(\"\\n\\nCompany Money: \\n\");\r\n\t\tm=tile.getCompanyMoney();\r\n\t\tsquare=(int)Math.sqrt(m.length);\r\n\t\tif(square*square<m.length) {\r\n\t\t\tsquare++;\r\n\t\t}\r\n\t\tfor(int i=0; i<m.length;) {\r\n\t\t\tfor(int j=0; j<square; j++) {\r\n\t\t\t\tif(i<m.length) {\r\n\t\t\t\t\tout=out.concat(String.format(\"%8s\", m[i]));\r\n\t\t\t\t\tcompanyTotal=companyTotal+m[i];\r\n\t\t\t\t\ti++;\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\tj=square;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tout=out.concat(\"\\n\");\r\n\t\t}\r\n\t\tout=out.concat(\"Company Total: \"+companyTotal);\r\n\t\tout=out.concat(\"\\nTotal total: \"+(total+companyTotal));\r\n\t\tif(total+companyTotal!=tile.getPeopleSize()*tile.getAverageMoney()) {\r\n\t\t\tSTART=false;\r\n\t\t}\r\n\t\treturn out;\r\n\t}", "public void listar_saldoMontadoData(String data_entrega,String tipo_pedido){\n \n \n OrdemCorteDAO dao = new OrdemCorteDAO();\n DefaultTableModel model = (DefaultTableModel) jTable_Saldo_Montado.getModel(); \n \n model.setNumRows(0);\n \n for (OrdemCorteDTO mp : dao.getSaldoVendaMontadoPorData(data_entrega, tipo_pedido)) {\n \n model.addRow(new Object[]{mp.getCodigo(), mp.getTotal()});\n }\n \n \n }", "List<TotalCarritoDTO> getTotalCarritoCompras(String userName,TipoMoneda tipoMoneda);", "public void scanNameAndgetPriceValue(WebDriver driver){\n\t\tList<String> price;\n\t\t\t\n\t\t\n\t\tdo{\t\t\t\n\t\t\tList<WebElement>rows = driver.findElements(By.xpath(\"//td[1]\"));\n\t\t\tprice = rows.stream().filter(s -> s.getText().contains(\"Rice\")).map(s ->getPriceVegi(s)).collect(Collectors.toList());\n\t\t\tprice.stream().forEach(s -> System.out.println(s));\t\t\t\n\t\t\tif(price.size()<1){\n\t\t\t\tdriver.findElement(By.cssSelector(\"[aria-label='Next']\")).click();\n\t\t\t}\t\t\t\n\t\t}while(price.size()<1);\t\t\n\t}", "java.lang.String getBankNo();", "@Override\n\t\t\tpublic String getValue(BmObject bmObject) {\n\t\t\t\treturn ((BmoOrderPropertyTax)bmObject).getQuantity().toString();\n//\t\t\t\treturn String.valueOf(months);\n\t\t\t}", "public int getMinAmount() {\n return minAmount;\n }", "public String accountsOfferingLoans(){\n int total = 0;\n double sum = 0;\n for(MicroLoan record : bank.getAccount2MicroloansOffered().values()){\n total++;\n sum += record.getAmount();\n }\n return \"Number of accounts providing micro loans: \" +total +\" worth a value of \"+sum;\n }", "List<Pacote> buscarPorQtdDiasMaiorEPrecoMenor(int qtd, float preco);", "public String getAmount() {\n\t\treturn amount;\n\t}", "private List<Valuable> helper(double amount, List<Valuable> money) {\n if(money.size() == 0) return null;\n Valuable current = money.get(0);\n if(amount >= current.getValue()) {\n if(amount - current.getValue() == 0) return new ArrayList<Valuable>(money.subList(1,money.size()));\n List<Valuable> tempList;\n if(( tempList=helper(amount-current.getValue(),money.subList(1,money.size())) ) != null ) {\n return tempList;\n }\n }\n List<Valuable> returnList = helper(amount,money.subList(1,money.size()));\n if(returnList != null) returnList.add(current);\n return returnList;\n }", "public static ArrayList<Integer> get(int[] coins, int amount) {\n // table for minimum number of coins for each value up to amount\n int[] numCoins = new int[amount + 1];\n // table for the last coin used for each value up to amount\n int[] lastCoin = new int[amount + 1];\n numCoins[0] = 0;\n lastCoin[0] = 0;\n \n \n int p = 0;\n for(int k = 0; k < coins.length; k++){\n p += coins[k];\n }\n \n //if array is empty, throws the exception\n if(p == 0){\n throw new IllegalArgumentException(\"Array of size 0 is not allowed\");\n }\n \n \n // iterate through each value up to amount\n for (int i = 1; i <= amount; i++) {\n int min = Integer.MAX_VALUE;\n int used = 0;\n // iterate through coins\n for (int coin: coins) {\n // if the coin is less than the value\n if (coin <= i) {\n // and using the coin results in using less coins overall\n if (1 + numCoins[i - coin] < min) {\n // update the min number of coins\n min = 1 + numCoins[i - coin];\n // and the last coin used\n used = coin;\n }\n }\n }\n // set min number of coins for the value\n numCoins[i] = min;\n // and the last coin used for the value\n lastCoin[i] = used;\n }\n \n // create an array list to store used coins\n ArrayList<Integer> coinsUsed = new ArrayList();\n \n // get first coin\n int last = lastCoin[amount];\n int remaining = amount;\n \n // while there is more change\n while (last != 0) {\n // get next coin and redo\n coinsUsed.add(last);\n remaining = remaining - last;\n last = lastCoin[remaining];\n }\n \n return coinsUsed;\n }", "public long getAmount();", "public long getAmount();", "public void calculoSalarioBruto(){\n salarioBruto = hrTrabalhada * valorHr;\n }", "public void takeoutMoney (double amount) {\n if(amount >= 2.0) {\n int numberToRemove = (int) Math.min(getToonie(), amount / 2.0);\n for(int i = 0; i < numberToRemove; i++) {\n for(int j = 0; j < coins.size(); j++) {\n if(coins.get(j).getValue() == 2.0) {\n coins.remove(j);\n break;\n }\n }\n }\n NToonie -= numberToRemove;\n amount -= 2.0 * numberToRemove;\n }\n if(amount >= 1.0) {\n int numberToRemove = (int) Math.min(getLoonie(), amount / 1.0);\n for(int i = 0; i < numberToRemove; i++) {\n for(int j = 0; j < coins.size(); j++) {\n if(coins.get(j).getValue() == 1.0) {\n coins.remove(j);\n break;\n }\n }\n }\n NLoonie -= numberToRemove;\n amount -= 1.0 * numberToRemove;\n }\n if(amount >= 0.25) {\n int numberToRemove = (int) Math.min(getQuarter(), amount / 0.25);\n for(int i = 0; i < numberToRemove; i++) {\n for(int j = 0; j < coins.size(); j++) {\n if(coins.get(j).getValue() == 0.25) {\n coins.remove(j);\n break;\n }\n }\n }\n NQuarter -= numberToRemove;\n amount -= 0.25 * numberToRemove;\n }\n if(amount >= 0.1) {\n int numberToRemove = (int) Math.min(getDime(), amount / 0.1);\n for(int i = 0; i < numberToRemove; i++) {\n for(int j = 0; j < coins.size(); j++) {\n if(coins.get(j).getValue() == 0.1) {\n coins.remove(j);\n break;\n }\n }\n }\n NDime -= numberToRemove;\n amount -= 0.1 * numberToRemove;\n }\n if(amount >= 0.05) {\n int numberToRemove = (int) Math.min(getNickel(), amount / 0.05);\n for(int i = 0; i < numberToRemove; i++) {\n for(int j = 0; j < coins.size(); j++) {\n if(coins.get(j).getValue() == 0.05) {\n coins.remove(j);\n break;\n }\n }\n }\n NNickel -= numberToRemove;\n amount -= 0.05 * numberToRemove;\n }\n }", "public BigDecimal getBSCA_ProfitPriceListEntered();", "public List<Kunde> getKundenMitVollemKonto(double minimum) {\n return kontoMap.values().stream()\n .filter(konto -> konto.getKontostand() >= minimum)\n .map(Konto::getInhaber)\n .collect(Collectors.toList());\n }", "private void getSpendingData() {\n mort = 0;\n cred = 0;\n loan = 0;\n auto = 0;\n groc = 0;\n medi = 0;\n util = 0;\n ente = 0;\n othe = 0;\n for (int i = 0; i < remindersTable.getRowCount(); i++) {\n if (remindersTable.getValueAt(i, 0).toString().equals(\"true\")) {\n // do nothing...we want spending only\n } else {\n switch (remindersTable.getValueAt(i, 4).toString()) {\n case (\"mortgage\"):\n mort = mort + parseDouble(remindersTable.getValueAt(i, 3).toString()) * -1;\n break;\n case (\"credit\"):\n cred = cred + parseDouble(remindersTable.getValueAt(i, 3).toString()) * -1;\n break;\n case (\"loans\"):\n loan = loan + parseDouble(remindersTable.getValueAt(i, 3).toString()) * -1;\n break;\n case (\"auto\"):\n auto = auto + parseDouble(remindersTable.getValueAt(i, 3).toString()) * -1;\n break;\n case (\"utilities\"):\n util = util + parseDouble(remindersTable.getValueAt(i, 3).toString()) * -1;\n break;\n case (\"grocery\"):\n groc = groc + parseDouble(remindersTable.getValueAt(i, 3).toString()) * -1;\n break;\n case (\"medical\"):\n medi = medi + parseDouble(remindersTable.getValueAt(i, 3).toString()) * -1;\n break;\n case (\"entertainment\"):\n ente = ente + parseDouble(remindersTable.getValueAt(i, 3).toString()) * -1;\n break;\n case (\"other\"):\n othe = othe + parseDouble(remindersTable.getValueAt(i, 3).toString()) * -1;\n break;\n default:\n // no match ... do nothing \n }\n }\n }\n }", "private Integer getAmount()\n {\n Scanner scanner = new Scanner(System.in);\n System.out.println(\"\");\n System.out.print(\"Indtast mængde: \");\n return scanner.nextInt();\n }", "public static String getChange(int amount){\n String result = \"\";\n for (Coins c : Coins.values()) {\n if(amount >= c.value()){\n int numberOfCoins = amount / c.value();\n amount = amount % c.value();\n result += c + \" : \" + numberOfCoins + \"\\n\";\n }\n }\n return result;\n }", "public String listFurnitureInPriceRange(double min, double max) {\r\n\t\t StringBuilder sb = new StringBuilder();\r\n for (Iterator<Furniture> it = furniture.iterator(); it.hasNext();) {\r\n\t\t\t Furniture f = (Furniture) it.next();\r\n if ((f.price() >= min) && (f.price() <= max))\r\n\t\t\t\t sb.append(f.toString() + NL);\r\n }\r\n return sb.toString();\r\n }", "public static String unionCreditList(List<String> list) {\r\n if (list == null || list.isEmpty()) return \"\";\r\n float minCredits = Integer.MAX_VALUE;\r\n float maxCredits = Integer.MIN_VALUE;\r\n for (String item : list) {\r\n String[] split = item.split(\"[ ,/-]\");\r\n\r\n String first = split[0];\r\n float min = Float.parseFloat(first);\r\n minCredits = Math.min(min, minCredits);\r\n\r\n String last = split[split.length - 1];\r\n float max = Float.parseFloat(last);\r\n maxCredits = Math.max(max, maxCredits);\r\n }\r\n\r\n String credits = Float.toString(minCredits);\r\n\r\n if (minCredits != maxCredits) {\r\n credits = credits + \"-\" + Float.toString(maxCredits);\r\n }\r\n\r\n credits = credits.replace(\".0\", \"\");\r\n return credits;\r\n }", "public String toString(){\n\t\tString s = \"\";\n\t\ts += \"El deposito de la moneda \"+nombreMoneda+\" (\" +valor+ \" centimos) contiene \"+cantidad+\" monedas\\n\";\n\t\treturn s;\n\t}", "public void amount() {\n \t\tfloat boxOHamt=boxOH*.65f*48f;\n \t\tSystem.out.printf(boxOH+\" boxes of Oh Henry ($0.65 x 48)= $%4.2f \\n\",boxOHamt);\n \t\tfloat boxCCamt=boxCC*.80f*48f;\n \t\tSystem.out.printf(boxCC+\" boxes of Coffee Crisp ($0.80 x 48)= $%4.2f \\n\", boxCCamt);\n \t\tfloat boxAEamt=boxAE*.60f*48f;\n \t\tSystem.out.printf(boxAE+\" boxes of Aero ($0.60 x 48)= $%4.2f \\n\", boxAEamt);\n \t\tfloat boxSMamt=boxSM*.70f*48f;\n \t\tSystem.out.printf(boxSM+\" boxes of Smarties ($0.70 x 48)= $%4.2f \\n\", boxSMamt);\n \t\tfloat boxCRamt=boxCR*.75f*48f;\n \t\tSystem.out.printf(boxCR+\" boxes of Crunchies ($0.75 x 48)= $%4.2f \\n\",boxCRamt);\n \t\tSystem.out.println(\"----------------------------------------------\");\n \t\t//display the total prices\n \t\tsubtotal=boxOHamt+boxCCamt+boxAEamt+boxSMamt+boxCRamt;\n \t\tSystem.out.printf(\"Sub Total = $%4.2f \\n\", subtotal);\n \t\ttax=subtotal*.07f;\n \t\tSystem.out.printf(\"Tax = $%4.2f \\n\", tax);\n \t\tSystem.out.println(\"==============================================\");\n \t\ttotal=subtotal+tax;\n \t\tSystem.out.printf(\"Amount Due = $%4.2f \\n\", total);\n \t}", "public void setAmountAndUnits(String a) {\n \t\tint i = a.indexOf(\" \");\n \t\tString d = a.substring(0, i);\n \t\tString u = a.substring(i);\n \t\t// preBoilVol.setAmount(Double.parseDouble(d.trim()));\n \t\tpreBoilVol.setUnits(u.trim());\n \t\t// postBoilVol.setAmount(Double.parseDouble(d.trim()));\n \t\tpostBoilVol.setUnits(u.trim());\n \t\tsetPostBoil(Double.parseDouble(d.trim()));\n \n \t}", "public int totalLivrosEmprestados(String clienteNome){\n int quantidadeLivro = 0;\n for (Emprestimo e : listaEmprestimo) {\n if(e.getClienteNome().equals(clienteNome)){\n quantidadeLivro++;\n }\n }\n return quantidadeLivro;\n }", "void setShowReportAmount(String amount);", "private String validateQuantityAmountNumPromotionShop(List<PromotionShopMap> lstCurrentPromotionShopMap, List<PromotionShopMap> lstNewPromotionShopMap) {\n\t\tint size = lstCurrentPromotionShopMap.size();\n\t\tint allocateQuantity = 0;\n\t\tint allocateAmount = 0;\n\t\tint allocateNum = 0;\n\t\tfor (int i = 0; i < size; i++) {\n\t\t\tPromotionShopMap psm = lstCurrentPromotionShopMap.get(i);\n\t\t\tif (psm.getQuantityMax() != null) {\n\t\t\t\tallocateQuantity++;\n\t\t\t}\n\t\t\tif (psm.getAmountMax() != null) {\n\t\t\t\tallocateAmount++;\n\t\t\t}\n\t\t\tif (psm.getNumMax() != null) {\n\t\t\t\tallocateNum++;\n\t\t\t}\n\t\t}\n\t\tfor (int j = 0, n = lstNewPromotionShopMap.size(); j < n; j++) {\n\t\t\tPromotionShopMap promotionShopMap = lstNewPromotionShopMap.get(j);\n\t\t\tString shopName = promotionShopMap.getShop() == null ? \"\" : (promotionShopMap.getShop().getShopCode() + \" - \" + promotionShopMap.getShop().getShopName());\n\t\t\tif (promotionShopMap.getQuantityMax() != null && allocateQuantity == 0) {\n\t\t\t\treturn Configuration.getResourceString(ConstantManager.VI_LANGUAGE, \"promotion.program.shop.denied.allcate.quantity\", shopName);\n\t\t\t}\n\t\t\tif (promotionShopMap.getQuantityMax() == null && allocateQuantity > 0) {\n\t\t\t\treturn Configuration.getResourceString(ConstantManager.VI_LANGUAGE, \"promotion.program.shop.no.allcate.quantity\", shopName);\n\t\t\t}\n\t\t\tif (promotionShopMap.getAmountMax() != null && allocateAmount == 0) {\n\t\t\t\treturn Configuration.getResourceString(ConstantManager.VI_LANGUAGE, \"promotion.program.shop.denied.allcate.amount\", shopName);\n\t\t\t}\n\t\t\tif (promotionShopMap.getAmountMax() == null && allocateAmount > 0) {\n\t\t\t\treturn Configuration.getResourceString(ConstantManager.VI_LANGUAGE, \"promotion.program.shop.no.allcate.amount\", shopName);\n\t\t\t}\n\t\t\tif (promotionShopMap.getNumMax() != null && allocateNum == 0) {\n\t\t\t\treturn Configuration.getResourceString(ConstantManager.VI_LANGUAGE, \"promotion.program.shop.denied.allcate.num\", shopName);\n\t\t\t}\n\t\t\tif (promotionShopMap.getNumMax() == null && allocateNum > 0) {\n\t\t\t\treturn Configuration.getResourceString(ConstantManager.VI_LANGUAGE, \"promotion.program.shop.no.allcate.num\", shopName);\n\t\t\t}\n\t\t}\n\t\treturn \"\";\n\t}", "public void addWarehouseStock(String name, int amount);", "@Override\n public double calcularValorCompra(ArrayList<Mueble> muebles){\n double total = 0d;\n for (Mueble m : muebles) {\n total+= m.getCantidad()*m.getPrecio();\n }\n return total; \n }", "public String customersOfferingLoans(){\n int total = 0;\n double sum = 0;\n for(MicroLoan record : bank.getCustomer2MicroloansOffered().values()){\n total++;\n sum += record.getAmount();\n }\n return \"Number of customers providing micro loans: \" +total +\" worth a value of \"+sum;\n }" ]
[ "0.5683671", "0.56682044", "0.5464488", "0.5439676", "0.54184294", "0.53917813", "0.5366653", "0.53586435", "0.5347888", "0.5251159", "0.5208831", "0.5153328", "0.51427656", "0.51389605", "0.51081145", "0.51052445", "0.5094109", "0.50809014", "0.50739896", "0.5068851", "0.50631255", "0.5050674", "0.5036936", "0.50157464", "0.50084305", "0.500632", "0.5003931", "0.5003892", "0.49944735", "0.49878216", "0.49816006", "0.4980873", "0.49777147", "0.49767223", "0.49751738", "0.49679878", "0.49657804", "0.49654675", "0.4952558", "0.49500015", "0.49500015", "0.4948215", "0.49464867", "0.49450785", "0.4939825", "0.49377534", "0.4932514", "0.49305615", "0.4929155", "0.49244672", "0.49196547", "0.49163437", "0.4902333", "0.48998266", "0.48995292", "0.48927474", "0.4885686", "0.48836488", "0.487044", "0.4866191", "0.48633713", "0.48610055", "0.48594615", "0.48590493", "0.48451906", "0.48278686", "0.4824772", "0.482464", "0.48104775", "0.48037553", "0.48019117", "0.48013532", "0.47954616", "0.47851288", "0.47845364", "0.47832486", "0.47659835", "0.47588882", "0.47579822", "0.47502947", "0.4749416", "0.4749416", "0.47435874", "0.47373074", "0.47354648", "0.4734145", "0.47321773", "0.4728949", "0.47281504", "0.47246042", "0.47224957", "0.47143817", "0.47132257", "0.47120288", "0.47064415", "0.47060454", "0.47052056", "0.4700864", "0.46987948", "0.46860465" ]
0.58348185
0
constructor for loadEnterpriseList() in EnterpriseDAO
public Enterprise(Long id, String idEnterprise, String name, Long phone, String address, String description) { this.id = id; this.idEnterprise = idEnterprise; this.name = name; this.phone = phone; this.address = address; this.description = description; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public DataSourceEntityExample() {\n oredCriteria = new ArrayList<Criteria>();\n }", "public EmployeeList() {\r\n initComponents();\r\n\r\n empName = getEmployeeName();\r\n empPosition = getEmployeePosition();\r\n System.out.println(empName + \"----- \" + empPosition);\r\n details = (ArrayList<String>) setEmployeeDetails(empName, empPosition);\r\n initializeComponents(details);\r\n\r\n }", "@GET\r\n public List<EnterpriseUserDTO> getEnterpriseUserList(){\r\n List <EnterpriseUserEntity> enterpriseUsers = enterpriseUsersLogic.obtenerEnterpriseUsers();\r\n return EnterpriseUserDTO.toEnterpriseUserList(enterpriseUsers);\r\n }", "@Override\n\tpublic ArrayList<Employee> getEmpList() throws HrExceptions {\n\t\tSystem.out.println(\"In getEmpList() of Dao\");\n\t\treturn null;\n\t}", "public EmployeesAdapter(List<Employee> employeeList) {\n this.employeeList = employeeList;\n }", "public EmpdetailExample() {\r\n oredCriteria = new ArrayList<Criteria>();\r\n }", "@Override\n\tpublic List<IdName> findEnterpriseByPy(String py) {\n\t\treturn enterpriseDAO.findEnterpriseByPy(py);\n\t}", "public ProductListContract() {}", "@PostConstruct\n\tprivate void init() {\n\t\tEntrada entr = new Entrada(\n\t\t\t\tnew Persona(\"Manuel\",\"Jimenex\",\"52422\",\"100000\",\"Cra 340\"),\n\t\t\t\t(new PreFactura(1l,new Date())), itemsService.lista());\n\t\t\n\t\tlistaEntrada.add(entr);\n\t}", "public void initSalesList() {\n\n String sql = \"SELECT menu.id_product, menu.name, menu.price,size.size, COUNT(orders_menu.id_order) \"\n + \"FROM menu, orders_menu, orders, size WHERE menu.id_product=orders_menu.id_product \"\n + \"AND orders.id_order=orders_menu.id_order AND orders.id_status=4 \"\n + \"AND size.id_size=menu.id_size GROUP BY menu.id_product\";\n\n Session session = HibernateUtil.getSessionFactory().getCurrentSession();\n\n session.beginTransaction();\n List<Object[]> empDepts = session.createNativeQuery(sql).list();\n\n salesFxObservableList.clear();\n for (Object[] objects : empDepts) {\n SalesFx salesFx = new SalesFx();\n salesFx.setIdProduct((Integer) objects[0]);\n salesFx.setName((String) objects[1]);\n salesFx.setPrice((Integer) objects[2]);\n salesFx.setSize((String) objects[3]);\n BigInteger bigInteger = (BigInteger) objects[4];\n salesFx.setSale(bigInteger.intValue());\n salesFxObservableList.add(salesFx);\n }\n\n session.getTransaction().commit();\n }", "private TicketList() {\n initTicketList();\n }", "public InventoryList() {\n super(\"Inventory List\");\n }", "public DAO(List<String> listName) {\n super(listName);\n }", "public ListSemental() {\n }", "@Override\n\tpublic List<EmployeeBean> getEmployeeList() throws Exception {\n\t\treturn employeeDao.getEmployeeList();\n\t}", "public ArticleExample() {\n oredCriteria = new ArrayList<Criteria>();\n }", "public ArticleExample() {\n oredCriteria = new ArrayList<Criteria>();\n }", "public ListIFace getLovAsListService() throws Exception {\r\n\t\tListIFace list = null;\t\r\n\t\tLovResultHandler lovResultHandler = new LovResultHandler( getLovResult() );\r\n\t\tSourceBean lovResultSB = lovResultHandler.getLovResultSB();\r\n\t\tPaginatorIFace paginator = new GenericPaginator();\r\n\t\t\r\n\t\tint numRows = 10;\r\n\t\ttry{\r\n\t\t\tSingletonConfig spagoconfig = SingletonConfig.getInstance();\r\n\t\t\tString lookupnumRows = spagoconfig.getConfigValue(\"SPAGOBI.LOOKUP.numberRows\");\r\n\t\t\tif(lookupnumRows!=null) {\r\n\t\t\t\tnumRows = Integer.parseInt(lookupnumRows);\r\n\t\t\t}\r\n\t\t} catch(Exception e) {\r\n\t\t\tnumRows = 10;\r\n\t\t\tSpagoBITracer.major(SpagoBIConstants.NAME_MODULE, this.getClass().getName(),\r\n\t\t\t\t\t \"getListServiceBaseConfig\", \"Error while recovering number rows for \" +\r\n\t\t\t\t\t \"lookup from configuration, usign default 10\", e);\r\n\t\t}\r\n\t\tpaginator.setPageSize(numRows);\r\n\t\t\r\n\t\t\r\n\t\tList rows = null;\r\n\t\tif (lovResultSB != null) {\r\n\t\t\trows = lovResultSB.getAttributeAsList(\"ROW\");\r\n\t\t\tfor (int i = 0; i < rows.size(); i++)\r\n\t\t\t\tpaginator.addRow(rows.get(i));\r\n\t\t}\r\n\t\tlist = new GenericList();\r\n\t\tlist.setPaginator(paginator);\r\n\t\treturn list;\r\n\t}", "public EmployeeLookup() {\r\n\t\tfill();\r\n\t\tinitialize();\r\n\t\t//AutoCompleteDecorator.decorate(el);\r\n\t}", "@PostConstruct\r\n/* 37: */ public void init()\r\n/* 38: */ {\r\n/* 39: 49 */ this.listaMotivoLlamadoAtencion = new LazyDataModel()\r\n/* 40: */ {\r\n/* 41: */ private static final long serialVersionUID = 1L;\r\n/* 42: */ \r\n/* 43: */ public List<MotivoLlamadoAtencion> load(int startIndex, int pageSize, String sortField, SortOrder sortOrder, Map<String, String> filters)\r\n/* 44: */ {\r\n/* 45: 59 */ List<MotivoLlamadoAtencion> lista = new ArrayList();\r\n/* 46: 60 */ boolean ordenar = sortOrder == SortOrder.ASCENDING;\r\n/* 47: */ \r\n/* 48: 62 */ filters.put(\"idOrganizacion\", String.valueOf(AppUtil.getOrganizacion().getId()));\r\n/* 49: 63 */ lista = MotivoLlamadoAtencionBean.this.servicioMotivoLlamadoAtencion.obtenerListaPorPagina(startIndex, pageSize, sortField, ordenar, filters);\r\n/* 50: */ \r\n/* 51: 65 */ MotivoLlamadoAtencionBean.this.listaMotivoLlamadoAtencion.setRowCount(MotivoLlamadoAtencionBean.this.servicioMotivoLlamadoAtencion.contarPorCriterio(filters));\r\n/* 52: */ \r\n/* 53: 67 */ return lista;\r\n/* 54: */ }\r\n/* 55: */ };\r\n/* 56: */ }", "@Override\n public void initialize(URL url, ResourceBundle rb) {\n // TODO\n implPromotionService pService = new implPromotionService();\n\n try {\n list = pService.readAllPromotion();\n \n } catch (SQLException ex) {\n Logger.getLogger(PromotionsController.class.getName()).log(Level.SEVERE, null, ex);\n }\n\n }", "public EntityAdapter(List<String> entityList, Context mContext){\n this.entityList = entityList;\n this.mContext = mContext;\n }", "@SuppressWarnings(\"unchecked\")\n\t\t\n\t\tpublic List<Employee> listEmployee() throws SQLException {\n\t\t\treturn (List<Employee>) employeeDAO.listEmployee();\n\t\t}", "java.util.List<hr.domain.ResumeDBOuterClass.Resume> \n getResumesList();", "@Override\n\tpublic void initialize(URL url, ResourceBundle rb) {\n\n\t\tif(!Inventory.getAllParts().isEmpty()) {\n\t\t\tpartSearchProductTable.setItems(Inventory.getAllParts());\n\t\t}\n\t\t\n\t\tpartSearchIdCol.setCellValueFactory(new PropertyValueFactory<>(\"Id\"));\n\t\tpartSearchNameCol.setCellValueFactory(new PropertyValueFactory<>(\"Name\"));\n\t\tpartSearchInvCol.setCellValueFactory(new PropertyValueFactory<>(\"Stock\"));\n\t\tpartSearchPriceCol.setCellValueFactory(new PropertyValueFactory<>(\"Price\"));\n\t\t\n\t\tpartListProductTable.setItems(dummyList);\n\t\t\n\t\tpartListIdCol.setCellValueFactory(new PropertyValueFactory<>(\"Id\"));\n\t\tpartListNameCol.setCellValueFactory(new PropertyValueFactory<>(\"Name\"));\n\t\tpartListInvCol.setCellValueFactory(new PropertyValueFactory<>(\"Stock\"));\n\t\tpartListPriceCol.setCellValueFactory(new PropertyValueFactory<>(\"Price\"));\n\t\t\n\t\t//BEGIN TEMP\n\t\t//Temporary due to automatic id creation not implemented\n\t\tidField.setDisable(true);\n\t\tidField.setStyle(\"-fx-opacity: 1;\"\n\t\t\t\t+ \"-fx-background-color: lightgrey;\");\n\t\t//END TEMP\n\t}", "public List<Employee> getEmployees();", "private void getEcoleList(){\r\n\t\tEcoleRequestFactory rf = GWT.create(EcoleRequestFactory.class);\r\n\t\trf.initialize(this.getEventBus(), new EventSourceRequestTransport(this.getEventBus()));\r\n\t\tEcoleRequestContext rc = rf.ecoleRequest();\r\n\t\trc.listAllActive().fire(new Receiver<List<EcoleProxy>>(){\r\n\t\t\t@Override\r\n\t\t\tpublic void onSuccess(List<EcoleProxy> response){\r\n\t\t\t\tgetView().setEcoleAddList(response);\r\n\t\t\t}\r\n\t\t\t@Override\r\n\t\t\tpublic void onFailure(ServerFailure error){\r\n\t\t\t\tWindow.alert(error.getMessage());\r\n\t\t\t}\r\n\t\t});\r\n\t}", "public List<EmployeeDetails> getEmployeeDetails();", "@Override\r\n\tpublic List<Employee> getAllEmployeeList() throws Exception {\n\t\t\r\n\t\treturn (List<Employee>) employeeRepository.findAll();\r\n\t}", "protected abstract List<E> getList();", "public EpAssetsDAOImpl() {\n super();\n }", "@Override\r\n\t\r\n\tpublic List<Employee> getAllDetails()\r\n\t{\r\n\t\t\r\n\t\tList<Employee> empList =hibernateTemplate.loadAll(Employee.class);\r\n\t\t\r\n\t\treturn empList;\r\n\t}", "public InventoryJournalLinesDSBean() {\n this.setDataSourceClassName(InventoryJournalLinesDS.class.getName());\n }", "public EnterpriseBeansItem() {\n super();\n }", "@Override\n public void initialize(URL url, ResourceBundle rb) {\n nomeUtilizador.setText(f.getNome());\n factory = Persistence.createEntityManagerFactory(Persistence_UNIT_NAME);\n EntityManager em = factory.createEntityManager();\n Query q = em.createNamedQuery(\"Funcionario.findByIdfuncionario\");\n q.setParameter(\"idfuncionario\", a.getIdfuncionario());\n \n Funcionario admin = new Funcionario();\n admin = (Funcionario) q.getSingleResult();\n \n BigDecimal id = ((Funcionario) admin).getIdfuncionario();\n String nome = ((Funcionario) admin).getNome();\n password = ((Funcionario) admin).getPassword();\n String morada = ((Funcionario) admin).getRua();\n String email = ((Funcionario) admin).getEmail();\n BigInteger ncc = ((Funcionario) admin).getNcc();\n BigInteger nif = ((Funcionario) admin).getNif();\n String data = ((Funcionario) admin).getDataNascimento();\n BigInteger telemovel = ((Funcionario) admin).getTelemovel();\n \n \n adminNome.setText(nome);\n //adminPassword.setText(password);\n adminMorada.setText(morada);\n adminEmail.setText(email);\n adminNcc.setText(ncc.toString() );\n adminNif.setText(nif.toString());\n adminData.setValue(LocalDate.parse(data));\n adminTelemovel.setText(telemovel.toString());\n }", "public OnibusDAO() {}", "protected ProvinciaList() {\n\t\tsuper();\n\t\t// TODO Auto-generated constructor stub\n\t}", "public EmployeesImpl() {\r\n }", "@Logging\n\tprivate List<Employee> getEmployee(List<String> aFileList) {\n\t\t\n\t\tList<Employee> aEmployeList = aFileList.stream()\n\t\t\t\t.skip(1) // skip the header line\n\t\t\t\t.map(line -> line.split(\",\")) // transform each line to an array\n\t\t\t\t.map(employeeData -> new Employee(Long.parseLong(employeeData[0]), employeeData[1], employeeData[2],\n\t\t\t\t\t\temployeeData[3], employeeData[4])) // transform each array to an entity\n\t\t\t\t.collect(Collectors.toList());\n\t\t\n\t\treturn aEmployeList;\n\t\t\n\t}", "public list() {\r\n }", "java.util.List<hr.domain.ResumeDBOuterClass.Experience> \n getExperiencesList();", "public ACLPropertyList() {\n try {\n jbInit();\n }\n catch (Exception e) {\n e.printStackTrace();\n }\n }", "public NewsExample() {\n oredCriteria = new ArrayList<Criteria>();\n }", "public List<Engineer> getListFromDB(){\n\t\treturn engineerList;\n\t}", "@Override\r\n\tpublic List<Employee> findAllEMployees() {\n\t\tList<Employee> employees = new ArrayList<Employee>();\r\n\t\tString findData = \"select * from employee\";\r\n\r\n\t\ttry {\r\n\t\t\tStatement s = dataSource.getConnection().createStatement();\r\n\r\n\t\t\tResultSet set = s.executeQuery(findData);\r\n\r\n\t\t\twhile (set.next()) {\r\n\t\t\t\tString name = set.getString(1);\r\n\t\t\t\tint id = set.getInt(\"empId\");\r\n\t\t\t\tint sal = set.getInt(\"salary\");\r\n\t\t\t\tString tech = set.getString(\"technology\");\r\n\t\t\t\tEmployee employee = new Employee(id, sal, name, tech);\r\n\t\t\t\temployees.add(employee);\r\n\r\n\t\t\t}\r\n\r\n\t\t} catch (SQLException e) {\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t\treturn employees;\r\n\r\n\t}", "public List<Evento> listarEventos() throws Exception{\n\t\t// Hibernate.initialize(listaEspecialidades());\n\t\treturn super.findListByQueryDinamica(\" from Evento\");\n\t}", "public java.util.List<andrewNamespace.xsdconfig.EmployeeDocument.Employee> getEmployeeList()\r\n {\r\n final class EmployeeList extends java.util.AbstractList<andrewNamespace.xsdconfig.EmployeeDocument.Employee>\r\n {\r\n @Override\r\n public andrewNamespace.xsdconfig.EmployeeDocument.Employee get(int i)\r\n { return ColleaguesImpl.this.getEmployeeArray(i); }\r\n \r\n @Override\r\n public andrewNamespace.xsdconfig.EmployeeDocument.Employee set(int i, andrewNamespace.xsdconfig.EmployeeDocument.Employee o)\r\n {\r\n andrewNamespace.xsdconfig.EmployeeDocument.Employee old = ColleaguesImpl.this.getEmployeeArray(i);\r\n ColleaguesImpl.this.setEmployeeArray(i, o);\r\n return old;\r\n }\r\n \r\n @Override\r\n public void add(int i, andrewNamespace.xsdconfig.EmployeeDocument.Employee o)\r\n { ColleaguesImpl.this.insertNewEmployee(i).set(o); }\r\n \r\n @Override\r\n public andrewNamespace.xsdconfig.EmployeeDocument.Employee remove(int i)\r\n {\r\n andrewNamespace.xsdconfig.EmployeeDocument.Employee old = ColleaguesImpl.this.getEmployeeArray(i);\r\n ColleaguesImpl.this.removeEmployee(i);\r\n return old;\r\n }\r\n \r\n @Override\r\n public int size()\r\n { return ColleaguesImpl.this.sizeOfEmployeeArray(); }\r\n \r\n }\r\n \r\n synchronized (monitor())\r\n {\r\n check_orphaned();\r\n return new EmployeeList();\r\n }\r\n }", "ArrayList<E> getAllObjects() throws DatabaseNotAccessibleException;", "protected DAO()\r\n\t{\r\n\t\tcustomers = new ArrayList<Customer>();\r\n\t}", "@Override\n @Transactional\n public List<Employee> getlistEmployee() {\n \tList<Employee> employees = entityManager.createQuery(\"SELECT e FROM Employee e\", Employee.class).getResultList();\n \tfor(Employee p : employees)\n \t\tLOGGER.info(\"employee list::\" + p);\n \treturn employees;\n }", "public CustomerDatabase(){\n\t\tlist = new ArrayList<Customer>();\n\t}", "public Employee() {\n this.isActivated = false;\n this.salt = CryptographicHelper.getInstance().generateRandomString(32);\n\n this.address = new Address();\n this.reports = new ArrayList<>();\n }", "public EquipmentSetAccessBean ( javax.ejb.EJBObject o ) throws java.rmi.RemoteException {\n super(o);\n }", "public RevenueList() {\n }", "public List<Employee> getEmployees() {\n\n\t\tList<Employee> employees = new ArrayList<Employee>();\n\t\t\n\t\t/*Sample data begins\n\t\tfor (int i = 0; i < 10; i++) {\n\t\t\tEmployee employee = new Employee();\n\t\t\temployee.setEmail(\"[email protected]\");\n\t\t\temployee.setFirstName(\"Shiyong\");\n\t\t\temployee.setLastName(\"Lu\");\n\t\t\temployee.setAddress(\"123 Success Street\");\n\t\t\temployee.setCity(\"Stony Brook\");\n\t\t\temployee.setStartDate(\"2006-10-17\");\n\t\t\temployee.setState(\"NY\");\n\t\t\temployee.setZipCode(11790);\n\t\t\temployee.setTelephone(\"5166328959\");\n\t\t\temployee.setEmployeeID(\"631-413-5555\");\n\t\t\temployee.setHourlyRate(100);\n\t\t\temployees.add(employee);\n\t\t}\n\t\tSample data ends*/\n\t\ttry {\n\t\t\tClass.forName(\"com.mysql.jdbc.Driver\");\n\t\t\tConnection con = DriverManager.getConnection(\"jdbc:mysql://mysql3.cs.stonybrook.edu:3306/mwcoulter?useSSL=false\",\"mwcoulter\",\"111030721\");\n\t\t\tStatement st = con.createStatement();\n\t\t\tResultSet rs = st.executeQuery(\"SELECT P.*, E.StartDate, E.HourlyRate, E.Email, E.ID, L.* \"\n\t\t\t\t\t+ \"FROM Employee E, Person P, Location L\"\n\t\t\t\t\t+ \" WHERE P.SSN = E.SSN AND L.ZipCode = P.ZipCode\");\n\t\t\twhile(rs.next()) {\n\t\t\t\tEmployee employee = new Employee();\n\t\t\t\temployee.setEmail(rs.getString(\"Email\"));\n\t\t\t\temployee.setFirstName(rs.getString(\"FirstName\"));\n\t\t\t\temployee.setLastName(rs.getString(\"LastName\"));\n\t\t\t\temployee.setAddress(rs.getString(\"Address\"));\n\t\t\t\temployee.setCity(rs.getString(\"City\"));\n\t\t\t\temployee.setStartDate(String.valueOf(rs.getDate(\"StartDate\")));\n\t\t\t\temployee.setState(rs.getString(\"State\"));\n\t\t\t\temployee.setZipCode(rs.getInt(\"ZipCode\"));\n\t\t\t\temployee.setTelephone(String.valueOf(rs.getLong(\"Telephone\")));\n\t\t\t\temployee.setEmployeeID(String.valueOf(rs.getInt(\"SSN\")));\n\t\t\t\temployee.setHourlyRate(rs.getInt(\"HourlyRate\"));\n\t\t\t\temployees.add(employee);\n\t\t\t}\n\t\t} catch (Exception e) {\n\t\t\tSystem.out.println(e);\n\t\t}\n\t\t\n\t\treturn employees;\n\t}", "@Override\n public void initialize(URL url, ResourceBundle rb) {\n // TODO\n IdCol.setCellValueFactory(new PropertyValueFactory<>(\"id\"));\n NomCol.setCellValueFactory(new PropertyValueFactory<>(\"user\"));\n MatiereCol.setCellValueFactory(new PropertyValueFactory<>(\"matiere\"));\n DateCol.setCellValueFactory(new PropertyValueFactory<>(\"date\"));\n TimeDebCol.setCellValueFactory(new PropertyValueFactory<>(\"timeDeb\"));\n TimeFinCol.setCellValueFactory(new PropertyValueFactory<>(\"timeFin\"));\n AbsenceService as=new AbsenceService();\n TableAbsence.setItems(as.GetAbsence()); \n Recherche();\n }", "public OrderTransactionManagedBean() \n {\n orders = new ArrayList<>();\n lineItems = new ArrayList<>();\n }", "public List()\n\t{\n\t\tthis(null, null);\n\t}", "public InvoiceExample() {\n oredCriteria = new ArrayList<Criteria>();\n }", "List<Elective> loadAllElectives();", "public ArrayList<Employee> getEmployeeList()\r\n\t{\r\n\t\treturn new ArrayList<Employee>(empList);\r\n\t}", "@Test\r\n public void testGetAllEMployees() throws Exception {\r\n try {\r\n EmployeeDAOImpl instance = new EmployeeDAOImpl();\r\n List<Employee> result = instance.getAllEMployees();\r\n assertTrue(result != null);\r\n assertTrue(result.size() > 0);\r\n } catch (Exception ex) {\r\n assertTrue(ex.getMessage().contains(\"NoDataFromDatabase\"));\r\n }\r\n }", "private ServiceListingList() {\n //This Exists to defeat instantiation\n super();\n }", "public ComtocomExampleBase() {\n oredCriteria = new ArrayList<Criteria>();\n }", "private void loadCriteriaList() {\n DataBaseManager DBM = new DataBaseManager();\n criteriaList = DBM.loadCriteriaList(pantallaIdentificacion.this);\n }", "public BoxEnterprise() {\n super();\n }", "@Override\n public void initialize(URL url, ResourceBundle rb) {\n // TODO\n this.d = new getAlumnosData(false);\n }", "public DLList() {\r\n init();\r\n }", "protected ArticleListAdapter(Parcel in) {\n listOfArticles = in.createTypedArrayList(Article.CREATOR);\n }", "public LitemallOrderExample() {\n oredCriteria = new ArrayList<Criteria>();\n }", "public void init() {\n\t\texternallyManaged = getCourse().isExternallyManaged();\n\n\t\t// Get the default search text\n\t\tif(StringUtils.trimToNull(searchText) == null) {\n\t\t\tsearchText = JsfUtil.getLocalizedMessage(\"roster_search_text\");\n\t\t}\n\n\t\t// Get the site enrollments\n\t\tList siteStudents;\n\t\tif(searchText.equals(JsfUtil.getLocalizedMessage(\"roster_search_text\"))) {\n\t\t\tsiteStudents = getSectionManager().getSiteEnrollments(getSiteContext());\n\t\t} else {\n\t\t\tsiteStudents = getSectionManager().findSiteEnrollments(getSiteContext(), searchText);\n\t\t}\n\t\t\n\t\t// Get the section enrollments\n\t\tSet studentUids = new HashSet();\n\t\tfor(Iterator iter = siteStudents.iterator(); iter.hasNext();) {\n\t\t\tParticipationRecord record = (ParticipationRecord)iter.next();\n\t\t\tstudentUids.add(record.getUser().getUserUid());\n\t\t}\n\t\tSectionEnrollments sectionEnrollments = getSectionManager().getSectionEnrollmentsForStudents(getSiteContext(), studentUids);\n\t\t\n\t\t// Construct the decorated enrollments for the UI\n\t\tList unpagedEnrollments = new ArrayList();\n\t\tcategories = getSectionManager().getSectionCategories(getSiteContext());\n\t\t\n\t\tfor(Iterator iter = siteStudents.iterator(); iter.hasNext();) {\n\t\t\tEnrollmentRecord enrollment = (EnrollmentRecord)iter.next();\n\t\t\t\n\t\t\t// Build a map of categories to sections in which the student is enrolled\n\t\t\tMap map = new HashMap();\n\t\t\tfor(Iterator catIter = categories.iterator(); catIter.hasNext();) {\n\t\t\t\tString cat = (String)catIter.next();\n\t\t\t\tCourseSection section = sectionEnrollments.getSection(enrollment.getUser().getUserUid(), cat);\n\t\t\t\tmap.put(cat, section);\n\t\t\t}\n\t\t\tEnrollmentDecorator decorator = new EnrollmentDecorator(enrollment, map);\n\t\t\tunpagedEnrollments.add(decorator);\n\t\t}\n\n\t\t// Sort the list\n\t\tCollections.sort(unpagedEnrollments, getComparator());\n\t\t\n\t\t// Filter the list\n\t\tenrollments = new ArrayList();\n\t\tint lastRow;\n\t\tint maxDisplayedRows = getPrefs().getRosterMaxDisplayedRows();\n\t\tif(maxDisplayedRows < 1 || firstRow + maxDisplayedRows > unpagedEnrollments.size()) {\n\t\t\tlastRow = unpagedEnrollments.size();\n\t\t} else {\n\t\t\tlastRow = firstRow + maxDisplayedRows;\n\t\t}\n\t\tenrollments.addAll(unpagedEnrollments.subList(firstRow, lastRow));\n\t\tenrollmentsSize = unpagedEnrollments.size();\n\t}", "public static List<Employee> getAllEmployees(){\n\t\t// Get the Datastore Service\n\t\tlog.severe(\"datastoremanager-\" + 366);\n\t\tDatastoreService datastore = DatastoreServiceFactory.getDatastoreService();\n\t\tlog.severe(\"datastoremanager-\" + 368);\n\t\tQuery q = buildAQuery(null);\n\t\tlog.severe(\"datastoremanager-\" + 370);\n\t\t// Use PreparedQuery interface to retrieve results\n\t\tPreparedQuery pq = datastore.prepare(q);\n\t\tlog.severe(\"datastoremanager-\" + 373);\n\t\t//List for returning\n\t\tList<Employee> returnedList = new ArrayList<>();\n\t\tlog.severe(\"datastoremanager-\" + 376);\n\t\t//Loops through all results and add them to the returning list \n\t\tfor (Entity result : pq.asIterable()) {\n\t\t\tlog.severe(\"datastoremanager-\" + 379);\n\t\t\t//Vars to use\n\t\t\tString actualFirstName = null;\n\t\t\tString actualLastName = null;\n\t\t\tBoolean attendedHrTraining = null;\n\t\t\tDate hireDate = null;\n\t\t\tBlob blob = null;\n\t\t\tbyte[] photo = null;\n\t\t\t\n\t\t\t//Get results via the properties\n\t\t\ttry {\n\t\t\t\tactualFirstName = (String) result.getProperty(\"firstName\");\n\t\t\t} catch (Exception e){}\n\t\t\ttry {\n\t\t\t\tactualLastName = (String) result.getProperty(\"lastName\");\n\t\t\t} catch (Exception e){}\n\t\t\ttry {\n\t\t\t\tattendedHrTraining = (Boolean) result.getProperty(\"attendedHrTraining\");\n\t\t\t} catch (Exception e){}\n\t\t\ttry {\n\t\t\t\thireDate = (Date) result.getProperty(\"hireDate\");\n\t\t\t} catch (Exception e){}\n\t\t\ttry {\n\t\t\t\tblob = (Blob) result.getProperty(\"picture\");\n\t\t\t} catch (Exception e){}\n\t\t\ttry {\n\t\t\t\tphoto = blob.getBytes();\n\t\t\t} catch (Exception e){}\n\t\t\tlog.severe(\"datastoremanager-\" + 387);\n\t\t\t\n\t\t\t//Build an employee (If conditionals for nulls)\n\t\t\tEmployee emp = new Employee();\n\t\t \temp.setFirstName((actualFirstName != null) ? actualFirstName : null);\n\t\t \temp.setLastName((actualLastName != null) ? actualLastName : null);\n\t\t \temp.setAttendedHrTraining((attendedHrTraining != null) ? attendedHrTraining : null);\n\t\t \temp.setHireDate((hireDate != null) ? hireDate : null);\n\t\t \temp.setPicture((photo != null) ? photo : null);\n\t\t \tlog.severe(\"datastoremanager-\" + 395);\n\t\t \treturnedList.add(emp);\n\t\t}\n\t\tlog.severe(\"datastoremanager-\" + 398);\n\t\treturn returnedList;\n\t}", "public void initializeOnInstantiation() \n\t\t\t\tthrows PersistenceException{\n\n\t}", "public Manager() {\n\t\tsuper();\n\t\temployees = new Employee[10];\n\t}", "public FetchData(Context context, ArrayList<String> findList) {\n this.context = context;\n this.findList = findList;\n }", "public SysAuthorityExample() {\r\n oredCriteria = new ArrayList<Criteria>();\r\n }", "@RequestMapping(value = \"/v2/employees\", method = RequestMethod.GET)\r\n\tpublic List<Employee> employeev2() {\r\n JPAQuery<?> query = new JPAQuery<Void>(em);\r\n QEmployee qemployee = QEmployee.employee;\r\n List<Employee> employees = (List<Employee>) query.from(qemployee).fetch();\r\n // Employee oneEmp = employees.get(0);\r\n\t\treturn employees;\r\n }", "@Override\r\n\tpublic void initialize(URL url, ResourceBundle rb) {\r\n\t\tbtEditar.setDisable(true);\r\n\t\tcheckAdmin.setDisable(true);\r\n\t\tcheckTPV.setDisable(true);\r\n\t\tObservableList<Employee> items = FXCollections\r\n\t\t\t\t.observableArrayList(service.getStaff());\r\n\t\tlistaStaff.setItems(items);\r\n\t\tlistaStaff.setOnMouseClicked(new EventHandler<MouseEvent>() {\r\n\t\t\t@Override\r\n\t\t\tpublic void handle(MouseEvent event) {\r\n\t\t\t\tEmployee e = listaStaff.getSelectionModel().getSelectedItem();\r\n\t\t\t\ttxUsuario.setText(String.valueOf(e.getUsername()));\r\n\t\t\t\ttxPassword.setText(String.valueOf(e.getPassword()));\r\n\t\t\t\tcheckAdmin.setIndeterminate(false);\r\n\t\t\t\tcheckAdmin.setSelected(e.getIsAdmin() == 1);\r\n\t\t\t\tcheckTPV.setIndeterminate(false);\r\n\t\t\t\tcheckTPV.setSelected(e.getTpvPrivilege() == 1);\r\n\t\t\t\tputEditables(false);\r\n\t\t\t\tbtEditar.setDisable(false);\r\n\t\t\t\tbtGuardar.setDisable(true);\r\n\t\t\t\tbtDelete.setDisable(false);\r\n\t\t\t}\r\n\t\t});\r\n\t}", "@Override\n public void initialize(URL url, ResourceBundle rb) {\n entitymanager = DBConnection.getEntityManger();\n this.loadCombos();\n this.loadTime();\n this.setLocations();\n }", "@Override\r\n\tpublic List<EmployeeBean> getAllData() {\n\r\n\t\tEntityManager manager = entityManagerFactory.createEntityManager();\r\n\r\n\t\tString query = \"from EmployeeBean\";\r\n\r\n\t\tjavax.persistence.Query query2 = manager.createQuery(query);\r\n\r\n\t\tList<EmployeeBean> list = query2.getResultList();\r\n\t\tif (list != null) {\r\n\t\t\treturn list;\r\n\t\t} else {\r\n\t\t\treturn null;\r\n\t\t}\r\n\t}", "ProductInventory()\n\t{\n\n\t\t// Initialize the Product Inventory Array List\n\t\tmyProductInventory = new ArrayList<Product>();\n\n\t}", "@SuppressWarnings(\"unchecked\")\n\tpublic ArrayList() {\n\t\tObject[] oList = new Object[INIT_SIZE];\n\t\tlist = (E[]) oList;\n\t\tsize = INIT_SIZE;\n\t}", "@Inject\n\tpublic AbsenceDaoImpl() throws SQLException {\n\t\tsuper(Absence.class);\n\t}", "public CaseInsensitiveElementListIDataCursor() {\n initialize();\n }", "public void loadData() {\n String[] header = {\"Tên Cty\", \"Mã Cty\", \"Cty mẹ\", \"Giám đốc\", \"Logo\", \"Slogan\"};\n model = new DefaultTableModel(header, 0);\n List<Enterprise> list = new ArrayList<Enterprise>();\n list = enterpriseBN.getAllEnterprise();\n for (Enterprise bean : list) {\n Enterprise enterprise = enterpriseBN.getEnterpriseByID(bean.getEnterpriseParent()); // Lấy ra 1 Enterprise theo mã\n Person person1 = personBN.getPersonByID(bean.getDirector());\n Object[] rows = {bean.getEnterpriseName(), bean.getEnterpriseID(), enterprise, person1, bean.getPicture(), bean.getSlogan()};\n model.addRow(rows);\n }\n listEnterprisePanel.getTableListE().setModel(model);\n setupTable();\n }", "public void fetcherLesEo() {\r\n\t\r\n\t// Commence par fetcher les params ... et si Ok, fetche les EO !\r\n\tif (recupererValParams() && valParams != null) {\r\n\r\n\t NSArray bindings = new NSArray(valParams);\r\n\t EOQualifier qualifier = EOQualifier.qualifierWithQualifierFormat(chaineQualif, bindings);\r\n\t EOFetchSpecification fetchSpec = new EOFetchSpecification(nomEntite,qualifier, eoSortOrderings);\r\n\r\n\t fetchSpec.setRefreshesRefetchedObjects(true);\r\n\r\n\t NSArray res = null;\r\n\t res = monEc.objectsWithFetchSpecification(fetchSpec);\r\n\t listeEOFetches = res;\r\n\t \r\n\t // si on demande � ce qu'� l'init il n'y ait pas de ligne s�lectionn�e par d�faut, alors pas d'Item choisi (en cascade)\r\n\t if (noSelectionPossible) setItemChoisi(null);\r\n\t else {\r\n\t\tif (listeEOFetches != null && listeEOFetches.count() > 0)\r\n\t\t setItemChoisi((EOGenericRecord)listeEOFetches.objectAtIndex(0));\r\n\t\telse setItemChoisi(null);\r\n\t }\r\n\t}\r\n\t// les parametres n'ont pu être récupérés : vider le popUp...\r\n\telse {\r\n listeEOFetches = null;\r\n // pas d'Item choisi (en cascade)\r\n setItemChoisi(null);\r\n\t}\r\n }", "public Index() {\n EntityManager emgr = new BeanBase().getEntityManager();\n this.listaUltimasEntradas = new BeanBaseJWiki().getUltimosCincoArticulosSmall();\n this.listaExistenciasFallidas = emgr.createQuery(\"SELECT e FROM Existencia e WHERE e.idestado.idestado=2\").getResultList();\n this.listaExistenciasMantenimiento = emgr.createQuery(\"SELECT e FROM Existencia e WHERE e.idestado.idestado=3\").getResultList();\n this.listaEquiposFallidos = emgr.createQuery(\"SELECT e FROM Equiposimple e WHERE e.idestado.idestado=2\").getResultList();\n this.listaEquiposMantenimiento = emgr.createQuery(\"SELECT e FROM Equiposimple e WHERE e.idestado.idestado=3\").getResultList();\n\n Calendar cal = Calendar.getInstance(); \n this.listaReservasHoy = new BeanBaseJCanon().getReservasMismoDia(cal.get(Calendar.DAY_OF_MONTH), cal.get(Calendar.MONTH) + 1, cal.get(Calendar.YEAR));\n\n }", "public PlayerDAO(){\n\t\tplayerList = new ArrayList<Player>();\n\t}", "public UserDAO(List<String> listName) {\n super(Arrays.asList(\"Users\", listName));\n }", "public ArticleDao() {\n super(Article.ARTICLE, cn.edu.kmust.flst.domain.flst.tables.pojos.Article.class);\n }", "AbstractList<Event> getEventByCreateDate(Date d){\r\n\t\treturn events;\r\n\t}", "public ShoppingListAdministrationImpl() throws IllegalArgumentException {\r\n\r\n\t}", "public InternmentList() {\n\t\tsuper(\"Internments\", List.IMPLICIT);\n\n\t\tstartData();\n\t\tstartComponents();\n\t}", "public void setupArticlesList();", "@Override\n @PostConstruct\n protected void init() {\n super.init();\n\n // _HACK_ Attention: you must realize that associations below (when lazy) are fetched from the view, non transactionnally.\n\n if (products == null) {\n products = new SelectableListDataModel<Product>(getPart().getProducts());\n }\n }", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t\tfecha = new Date();\r\n\t\t\r\n\t\tlistaBancos = new ArrayList<SelectItem>();\r\n\t\tlistaRegiones = new ArrayList<SelectItem>();\r\n\t\tlistaCiudades = new ArrayList<SelectItem>();\r\n\t\tlistaComunas = new ArrayList<SelectItem>();\r\n\t\t\r\n\t\tfor(EmpresaDTO empresa : configJProcessService.selectEmpresasByOrganizacion(1))\r\n\t\t\tlistaBancos.add(new SelectItem(empresa.getId(), empresa.getNombre()));\r\n\t}", "private void _init() throws Exception {\n if (this.getListaDelCommunication() != null) {\n this.getObjectListDataProvider().setList(this.getListaDelCommunication());\n }\n\n if (this.getListaDelCommunication2() != null) {\n this.getObjectListDataProvider2().setList(this.getListaDelCommunication2());\n }\n\n dateTimeConverter1.setTimeZone(null);\n dateTimeConverter1.setPattern(\"dd/MM/yy\");\n dateTimeConverter1.setDateStyle(\"full\");\n }", "public ListaReservasBean() {\r\n\t\tthis.listaReservas = new ArrayList<ReservaDAO>();\r\n\t}", "protected List getList() {\n/* 88 */ return (List)getCollection();\n/* */ }", "public MySpacesListVOImpl() {\r\n }" ]
[ "0.6247666", "0.6168357", "0.596372", "0.5947107", "0.59152085", "0.5909829", "0.5876861", "0.5760325", "0.5641014", "0.5639978", "0.5593808", "0.55889165", "0.5587104", "0.5536398", "0.5526343", "0.5522317", "0.5522317", "0.5514288", "0.5498687", "0.54975164", "0.54928637", "0.548313", "0.5444579", "0.5433185", "0.54095423", "0.5406492", "0.53855795", "0.5384613", "0.5374674", "0.53725594", "0.5371109", "0.53632784", "0.53575397", "0.5354581", "0.53516185", "0.53450716", "0.53419524", "0.53384", "0.5335835", "0.5331046", "0.5324949", "0.5318642", "0.53162104", "0.53131735", "0.53092504", "0.53087056", "0.53074443", "0.53018665", "0.52983034", "0.52971375", "0.5292428", "0.5284874", "0.5279259", "0.5271023", "0.5268287", "0.52622026", "0.52595395", "0.5257814", "0.52551484", "0.52442396", "0.524068", "0.52400976", "0.52383834", "0.52374476", "0.5233593", "0.52292925", "0.52281386", "0.522585", "0.52257836", "0.52236265", "0.52219635", "0.5219895", "0.52184874", "0.5218342", "0.52090555", "0.5207809", "0.52054214", "0.520407", "0.5202067", "0.5185408", "0.5184699", "0.51783943", "0.5177093", "0.5175667", "0.51714003", "0.5169219", "0.5168366", "0.5167807", "0.51651937", "0.51625687", "0.51557493", "0.51556414", "0.51543576", "0.51499623", "0.5143872", "0.5141383", "0.5140981", "0.51404965", "0.5139496", "0.5135534" ]
0.54189104
24
Use this factory method to create a new instance of this fragment using the provided parameters.
public static TVListFragment newInstance() { TVListFragment fragment = new TVListFragment(); return fragment; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static FragmentTousWanted newInstance() {\n FragmentTousWanted fragment = new FragmentTousWanted();\n Bundle args = new Bundle();\n fragment.setArguments(args);\n return fragment;\n }", "protected abstract Fragment createFragment();", "public void createFragment() {\n\n }", "@Override\n protected Fragment createFragment() {\n Intent intent = getIntent();\n\n long id = intent.getLongExtra(MovieDetailFragment.EXTRA_ID, -1);\n return MovieDetailFragment.newInstance(id);\n }", "public CuartoFragment() {\n }", "public StintFragment() {\n }", "public ExploreFragment() {\n\n }", "public RickAndMortyFragment() {\n }", "public FragmentMy() {\n }", "public LogFragment() {\n }", "public FeedFragment() {\n }", "public HistoryFragment() {\n }", "public HistoryFragment() {\n }", "public static MyFeedFragment newInstance() {\n return new MyFeedFragment();\n }", "public WkfFragment() {\n }", "public static ScheduleFragment newInstance() {\n ScheduleFragment fragment = new ScheduleFragment();\n Bundle args = new Bundle();\n //args.putString(ARG_PARAM1, param1);\n //args.putString(ARG_PARAM2, param2);\n fragment.setArguments(args);\n return fragment;\n }", "public ProfileFragment(){}", "public WelcomeFragment() {}", "public static ForumFragment newInstance() {\n ForumFragment fragment = new ForumFragment();\n Bundle args = new Bundle();\n fragment.setArguments(args);\n\n return fragment;\n }", "public static NotificationFragment newInstance() {\n NotificationFragment fragment = new NotificationFragment();\n Bundle args = new Bundle();\n// args.putString(ARG_PARAM1, param1);\n// args.putString(ARG_PARAM2, param2);\n fragment.setArguments(args);\n return fragment;\n }", "public progFragment() {\n }", "public HeaderFragment() {}", "public static RouteFragment newInstance() {\n RouteFragment fragment = new RouteFragment();\n Bundle args = new Bundle();\n //fragment.setArguments(args);\n return fragment;\n }", "public EmployeeFragment() {\n }", "public Fragment_Tutorial() {}", "public NewShopFragment() {\n }", "public FavoriteFragment() {\n }", "public static MyCourseFragment newInstance() {\n MyCourseFragment fragment = new MyCourseFragment();\r\n// fragment.setArguments(args);\r\n return fragment;\r\n }", "public static MessageFragment newInstance() {\n MessageFragment fragment = new MessageFragment();\n Bundle args = new Bundle();\n\n fragment.setArguments(args);\n return fragment;\n }", "public static ReservationFragment newInstance() {\n\n ReservationFragment _fragment = new ReservationFragment();\n// Bundle args = new Bundle();\n// args.putString(ARG_PARAM1, param1);\n// args.putString(ARG_PARAM2, param2);\n// fragment.setArguments(args);\n return _fragment;\n }", "public CreateEventFragment() {\n // Required empty public constructor\n }", "public static RecipeListFragment newInstance() {\n RecipeListFragment fragment = new RecipeListFragment();\n// Bundle args = new Bundle();\n// args.putString(ARG_PARAM1, param1);\n// args.putString(ARG_PARAM2, param2);\n// fragment.setArguments(args);\n return fragment;\n }", "public static Fragment newInstance() {\n\t\treturn new ScreenSlidePageFragment();\n\t}", "public NoteActivityFragment() {\n }", "public static WeekViewFragment newInstance(int param1, int param2) {\n WeekViewFragment fragment = new WeekViewFragment();\n //WeekViewFragment 객체 생성\n Bundle args = new Bundle();\n //Bundle 객체 생성\n args.putInt(ARG_PARAM1, param1);\n //ARG_PARAM1에 param1의 정수값 넣어서 args에 저장\n args.putInt(ARG_PARAM2, param2);\n //ARG_PARAM2에 param2의 정수값 넣어서 args에 저장\n fragment.setArguments(args);\n //args를 매개변수로 한 setArguments() 메소드 수행하여 fragment에 저장\n return fragment; //fragment 반환\n }", "public static Fragment0 newInstance(String param1, String param2) {\n Fragment0 fragment = new Fragment0();\n Bundle args = new Bundle();\n args.putString(ARG_PARAM1, param1);\n args.putString(ARG_PARAM2, param2);\n fragment.setArguments(args);\n return fragment;\n }", "public static QueenBEmbassyF newInstance() {\n QueenBEmbassyF fragment = new QueenBEmbassyF();\n //the way to pass arguments between fragments\n Bundle args = new Bundle();\n\n fragment.setArguments(args);\n return fragment;\n }", "public static Fragment newInstance() {\n StatisticsFragment fragment = new StatisticsFragment();\n Bundle args = new Bundle();\n fragment.setArguments(args);\n return fragment;\n }", "public EventHistoryFragment() {\n\t}", "public HomeFragment() {}", "public PeopleFragment() {\n // Required empty public constructor\n }", "public static FeedFragment newInstance() {\n FeedFragment fragment = new FeedFragment();\n return fragment;\n }", "public static MainFragment newInstance(String param1, String param2) {\n MainFragment fragment = new MainFragment();\n Bundle args = new Bundle();\n fragment.setArguments(args);\n return fragment;\n }", "public VantaggiFragment() {\n // Required empty public constructor\n }", "public AddressDetailFragment() {\n }", "public ArticleDetailFragment() { }", "public static DropboxMainFrag newInstance() {\n DropboxMainFrag fragment = new DropboxMainFrag();\n // set arguments in Bundle\n return fragment;\n }", "public RegisterFragment() {\n }", "public EmailFragment() {\n }", "public static CommentFragment newInstance() {\n CommentFragment fragment = new CommentFragment();\n\n return fragment;\n }", "public static FragmentComida newInstance(String param1) {\n FragmentComida fragment = new FragmentComida();\n Bundle args = new Bundle();\n args.putString(ARG_PARAM1, param1);\n fragment.setArguments(args);\n return fragment;\n\n\n }", "public static ParqueosFragment newInstance() {\n ParqueosFragment fragment = new ParqueosFragment();\n return fragment;\n }", "public ForecastFragment() {\n }", "public FExDetailFragment() {\n \t}", "public static AddressFragment newInstance(String param1) {\n AddressFragment fragment = new AddressFragment();\n\n Bundle args = new Bundle();\n args.putString(ARG_PARAM1, param1);\n fragment.setArguments(args);\n\n return fragment;\n }", "public TripNoteFragment() {\n }", "public ItemFragment() {\n }", "public NoteListFragment() {\n }", "public CreatePatientFragment() {\n\n }", "public DisplayFragment() {\n\n }", "public static frag4_viewcompliment newInstance(String param1, String param2) {\r\n frag4_viewcompliment fragment = new frag4_viewcompliment();\r\n Bundle args = new Bundle();\r\n args.putString(ARG_PARAM1, param1);\r\n args.putString(ARG_PARAM2, param2);\r\n fragment.setArguments(args);\r\n return fragment;\r\n }", "public static fragment_profile newInstance(String param1, String param2) {\n fragment_profile fragment = new fragment_profile();\n Bundle args = new Bundle();\n args.putString(ARG_PARAM1, param1);\n args.putString(ARG_PARAM2, param2);\n fragment.setArguments(args);\n return fragment;\n }", "@Override\n\tprotected Fragment createFragment() {\n\t\treturn new FormFragment();\n\t}", "public static MainFragment newInstance() {\n MainFragment fragment = new MainFragment();\n Bundle args = new Bundle();\n fragment.setArguments(args);\n return fragment;\n }", "public ProfileFragment() {\n\n }", "public BackEndFragment() {\n }", "public CustomerFragment() {\n }", "public static FriendsFragment newInstance(int sectionNumber) {\n \tFriendsFragment fragment = new FriendsFragment();\n Bundle args = new Bundle();\n args.putInt(ARG_SECTION_NUMBER, sectionNumber);\n fragment.setArguments(args);\n return fragment;\n }", "public ArticleDetailFragment() {\n }", "public ArticleDetailFragment() {\n }", "public ArticleDetailFragment() {\n }", "public static Fragment newInstance() {\n return new SettingsFragment();\n }", "public SummaryFragment newInstance()\n {\n return new SummaryFragment();\n }", "public PeersFragment() {\n }", "public TagsFragment() {\n }", "public static ProfileFragment newInstance() {\n ProfileFragment fragment = new ProfileFragment();\n Bundle args = new Bundle();\n args.putString(ARG_PARAM1, \"\");\n args.putString(ARG_PARAM2, \"\");\n fragment.setArguments(args);\n return fragment;\n }", "public static FriendsFragment newInstance() {\n FriendsFragment fragment = new FriendsFragment();\n\n return fragment;\n }", "public HomeSectionFragment() {\n\t}", "public static FirstFragment newInstance(String text) {\n\n FirstFragment f = new FirstFragment();\n Bundle b = new Bundle();\n b.putString(\"msg\", text);\n\n f.setArguments(b);\n\n return f;\n }", "public PersonDetailFragment() {\r\n }", "public static LogFragment newInstance(Bundle params) {\n LogFragment fragment = new LogFragment();\n fragment.setArguments(params);\n return fragment;\n }", "public RegisterFragment() {\n // Required empty public constructor\n }", "public VehicleFragment() {\r\n }", "public static Fine newInstance(String param1, String param2) {\n Fine fragment = new Fine();\n Bundle args = new Bundle();\n args.putString(ARG_PARAM1, param1);\n args.putString(ARG_PARAM2, param2);\n fragment.setArguments(args);\n return fragment;\n }", "public static FriendsFragment newInstance(String param1, String param2) {\n FriendsFragment fragment = new FriendsFragment();\n Bundle args = new Bundle();\n fragment.setArguments(args);\n return fragment;\n }", "public static ChangesViewFragment newInstance() {\n\t\tChangesViewFragment fragment = new ChangesViewFragment();\n\t\tBundle args = new Bundle();\n\t\targs.putInt(HomeViewActivity.ARG_SECTION_NUMBER, 2);\n\t\tfragment.setArguments(args);\n\t\treturn fragment;\n\t}", "public static NoteFragment newInstance(String param1, String param2) {\n NoteFragment fragment = new NoteFragment();\n Bundle args = new Bundle();\n args.putString(ARG_PARAM1, param1);\n args.putString(ARG_PARAM2, param2);\n fragment.setArguments(args);\n return fragment;\n }", "public static MainFragment newInstance(Context context) {\n MainFragment fragment = new MainFragment();\n if(context != null)\n fragment.setVariables(context);\n return fragment;\n }", "@Override\n\tprotected Fragment createFragment() {\n\t\treturn new CrimeListFragment();\n\t}", "public static MoneyLogFragment newInstance() {\n MoneyLogFragment fragment = new MoneyLogFragment();\n return fragment;\n }", "public static ForecastFragment newInstance() {\n\n //Create new fragment\n ForecastFragment frag = new ForecastFragment();\n return(frag);\n }", "public static MainFragment newInstance(String param1, String param2) {\n MainFragment fragment = new MainFragment();\n Bundle args = new Bundle();\n args.putString(ARG_PARAM1, param1);\n args.putString(ARG_PARAM2, param2);\n fragment.setArguments(args);\n return fragment;\n }", "public static MainFragment newInstance(String param1, String param2) {\n MainFragment fragment = new MainFragment();\n Bundle args = new Bundle();\n args.putString(ARG_PARAM1, param1);\n args.putString(ARG_PARAM2, param2);\n fragment.setArguments(args);\n return fragment;\n }", "public static MainFragment newInstance(String param1, String param2) {\n MainFragment fragment = new MainFragment();\n Bundle args = new Bundle();\n args.putString(ARG_PARAM1, param1);\n args.putString(ARG_PARAM2, param2);\n fragment.setArguments(args);\n return fragment;\n }", "public static MyTaskFragment newInstance(String param1) {\n MyTaskFragment fragment = new MyTaskFragment();\n Bundle args = new Bundle();\n args.putString(ARG_PARAM1, param1);\n fragment.setArguments(args);\n return fragment;\n }", "public static MyProfileFragment newInstance(String param1, String param2) {\n MyProfileFragment fragment = new MyProfileFragment();\n return fragment;\n }", "public static MainFragment newInstance(int param1, String param2) {\n MainFragment fragment = new MainFragment();\n Bundle args = new Bundle();\n args.putInt(ARG_PARAM1, param1);\n\n args.putString(ARG_PARAM2, param2);\n fragment.setArguments(args);\n return fragment;\n }", "public PlaylistFragment() {\n }", "public static HistoryFragment newInstance() {\n HistoryFragment fragment = new HistoryFragment();\n return fragment;\n }", "public static SurvivorIncidentFormFragment newInstance(String param1, String param2) {\n// SurvivorIncidentFormFragment fragment = new SurvivorIncidentFormFragment();\n// Bundle args = new Bundle();\n// args.putString(ARG_PARAM1, param1);\n// args.putString(ARG_PARAM2, param2);\n// fragment.setArguments(args);\n// return fragment;\n\n SurvivorIncidentFormFragment fragment = new SurvivorIncidentFormFragment();\n Bundle args = new Bundle();\n args.putString(ARG_PARAM1, param1);\n args.putString(ARG_PARAM2, param2);\n fragment.setArguments(args);\n return fragment;\n\n\n }", "public static PersonalFragment newInstance(String param1, String param2) {\n PersonalFragment fragment = new PersonalFragment();\n Bundle args = new Bundle();\n args.putString(ARG_PARAM1, param1);\n args.putString(ARG_PARAM2, param2);\n fragment.setArguments(args);\n return fragment;\n }" ]
[ "0.7259329", "0.72331375", "0.71140355", "0.69909847", "0.69902235", "0.6834592", "0.683074", "0.68134046", "0.6801526", "0.6801054", "0.67653185", "0.6739714", "0.6739714", "0.6727412", "0.6717231", "0.6705855", "0.6692112", "0.6691661", "0.66869426", "0.66606814", "0.6646188", "0.66410166", "0.6640725", "0.6634425", "0.66188246", "0.66140765", "0.6608169", "0.66045964", "0.65977716", "0.6592119", "0.659137", "0.65910816", "0.65830594", "0.65786606", "0.6562876", "0.65607685", "0.6557126", "0.65513307", "0.65510213", "0.65431285", "0.6540448", "0.65336084", "0.6532555", "0.6528302", "0.6524409", "0.652328", "0.6523149", "0.6516528", "0.65049976", "0.6497274", "0.6497235", "0.64949715", "0.64944136", "0.6484968", "0.6484214", "0.64805835", "0.64784926", "0.64755154", "0.64710265", "0.6466466", "0.6457089", "0.645606", "0.6454554", "0.6452161", "0.64520335", "0.6450325", "0.64488834", "0.6446765", "0.64430225", "0.64430225", "0.64430225", "0.64420956", "0.6441306", "0.64411277", "0.6438451", "0.64345145", "0.64289486", "0.64287597", "0.6423755", "0.64193285", "0.6418699", "0.6414679", "0.6412867", "0.6402168", "0.6400724", "0.6395624", "0.6395109", "0.6391252", "0.63891554", "0.63835025", "0.63788056", "0.63751805", "0.63751805", "0.63751805", "0.6374796", "0.63653135", "0.6364529", "0.6360922", "0.63538784", "0.6351111", "0.635067" ]
0.0
-1
Inflate the layout for this fragment
@Override public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { View view = inflater.inflate(R.layout.fragment_tv_list, container, false); this.gridView = view.findViewById(R.id.tv_list); TVAdapter TVAdapter = new TVAdapter(getContext(), tvArrayList); this.gridView.setAdapter(TVAdapter); this.gridView.setOnItemClickListener(new AdapterView.OnItemClickListener() { @Override public void onItemClick(AdapterView<?> adapterView, View view, int i, long l) { TV tv = tvArrayList.get(i); Intent intent = new Intent(getContext(), TVDetailActivity.class); intent.putExtra("tv", tv); getActivity().startActivity(intent); } }); this.gridView.setOnItemSelectedListener(new AdapterView.OnItemSelectedListener() { @Override public void onItemSelected(AdapterView<?> adapterView, View view, int pos, long id) { //倒数第几行开始加载下一页 int preRows = 2; if (pos > tvArrayList.size() - preRows * gridView.getNumColumns() && !isLoading && !isEnded) { loadMore(); } } @Override public void onNothingSelected(AdapterView<?> adapterView) { } }); return view; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_main_allinfo, container, false);\n }", "@Override\r\n\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container,\r\n\t\t\tBundle savedInstanceState) {\n\t\treturn inflater.inflate(R.layout.wallpager_layout, null);\r\n\t}", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_invit_friends, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View inflate = inflater.inflate(R.layout.fragment_zhuye, container, false);\n initView(inflate);\n initData();\n return inflate;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup parent, Bundle savedInstanceState) {\n // Defines the xml file for the fragment\n return inflater.inflate(R.layout.fragment_posts, parent, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n return inflater.inflate(R.layout.ilustration_fragment, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View v = inflater.inflate(R.layout.fragment_sow_drug_cost_per_week, container, false);\n\n db = new DataBaseAdapter(getActivity());\n hc = new HelperClass();\n pop = new FeedSowsFragment();\n\n infltr = (LayoutInflater) getActivity().getSystemService(Context.LAYOUT_INFLATER_SERVICE);\n parent = (LinearLayout) v.findViewById(R.id.layout_for_add);\n tvTotalCost = (TextView) v.findViewById(R.id.totalCost);\n\n getData();\n setData();\n\n return v;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_stream_list, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View v = inflater.inflate(R.layout.fragment_event, container, false);\n\n\n\n\n\n\n\n\n return v;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_feed, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.screen_select_list_student, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View rootView = inflater.inflate(R.layout.fragment_overall, container, false);\n mNamesLayout = (LinearLayout) rootView.findViewById(R.id.fragment_overall_names_layout);\n mOverallView = (OverallView) rootView.findViewById(R.id.fragment_overall_view);\n return rootView;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState)\n {\n\n\n view = inflater.inflate(R.layout.fragment_earning_fragmant, container, false);\n ini(view);\n return view;\n }", "@Nullable\n @Override\n public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {\n super.onCreateView(inflater, container, savedInstanceState);\n final View rootview = inflater.inflate(R.layout.activity_email_frag, container, false);\n ConfigInnerElements(rootview);\n return rootview;\n }", "@Override\r\n\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container,\r\n\t\t\tBundle savedInstanceState) {\n\t\trootView = inflater.inflate(R.layout.fragment_attack_armor, container, false);\r\n\r\n\t\tfindInterfaceElements();\r\n\t\taddRangeSelector();\r\n\t\tupdateHeadings();\r\n\t\tsetListeners();\r\n\r\n\t\tsetFromData();\r\n\r\n\t\treturn rootView;\r\n\t}", "@SuppressLint(\"InflateParams\")\r\n\t@Override\r\n\tpublic View initLayout(LayoutInflater inflater) {\n\t\tView view = inflater.inflate(R.layout.frag_customer_all, null);\r\n\t\treturn view;\r\n\t}", "@Override\r\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\r\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.fragment_fore_cast, container, false);\r\n initView();\r\n mainLayout.setVisibility(View.GONE);\r\n apiInterface = RestClinet.getClient().create(ApiInterface.class);\r\n loadData();\r\n return view;\r\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_friend, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n rootView = inflater.inflate(R.layout.fragment_detail, container, false);\n image = rootView.findViewById(R.id.fr_image);\n name = rootView.findViewById(R.id.fr_name);\n phoneNumber = rootView.findViewById(R.id.fr_phone_number);\n email = rootView.findViewById(R.id.fr_email);\n street = rootView.findViewById(R.id.fr_street);\n city = rootView.findViewById(R.id.fr_city);\n state = rootView.findViewById(R.id.fr_state);\n zipcode = rootView.findViewById(R.id.fr_zipcode);\n dBrith = rootView.findViewById(R.id.date_brith);\n return rootView;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_pm25, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_kkbox_playlist, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View rootView = inflater.inflate(R.layout.fragment_feed_pager, container, false);\n\n// loadData();\n\n findViews(rootView);\n\n setViews();\n\n return rootView;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n layout = (FrameLayout) inflater.inflate(R.layout.fragment_actualites, container, false);\n\n relLayout = (RelativeLayout) layout.findViewById(R.id.relLayoutActus);\n\n initListView();\n getXMLData();\n\n return layout;\n }", "@Nullable\n @Override\n public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {\n rootView = inflater.inflate(R.layout.frag_post_prayer_video, container, false);\n setCustomDesign();\n setCustomClickListeners();\n return rootView;\n }", "@Override\n\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container,\n\t\t\tBundle savedInstanceState) {\n\t\treturn inflater.inflate(R.layout.lf_em4305_fragment, container, false);\n\t}", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_recordings, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view=inflater.inflate(R.layout.fragment_category, container, false);\n initView(view);\n bindRefreshListener();\n loadParams();\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_cm_box_details, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view=inflater.inflate(R.layout.fragment_layout12, container, false);\n\n iniv();\n\n init();\n\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.fragment_details, container, false);\n //return inflater.inflate(R.layout.fragment_details, container, false);\n getIntentValues();\n initViews();\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_mem_body_blood, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_qiugouxiaoxi, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View inflate = inflater.inflate(R.layout.fragment_coll_blank, container, false);\n initView(inflate);\n initData();\n return inflate;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_attendance_divide, container, false);\n\n initView(view);\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup parent, Bundle savedInstanceState) {\n // Defines the xml file for the fragment\n return inflater.inflate(R.layout.show_program_fragment, parent, false);\n }", "@Override\n public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container,\n @Nullable Bundle savedInstanceState) {\n return inflater.inflate(R.layout.visualization_fragment, container, false);\n\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n rootView = inflater.inflate(R.layout.fragment_category_details_page, container, false);\n initializeAll();\n\n return rootView;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n final View v = inflater.inflate(R.layout.fragemnt_reserve, container, false);\n\n\n\n\n return v;\n }", "protected int getLayoutResId() {\n return R.layout.activity_fragment;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_all_quizs, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n role = getArguments().getInt(\"role\");\n rootview = inflater.inflate(R.layout.fragment_application, container, false);\n layout = rootview.findViewById(R.id.patentDetails);\n progressBar = rootview.findViewById(R.id.progressBar);\n try {\n run();\n } catch (IOException e) {\n e.printStackTrace();\n }\n return rootview;\n }", "@Override\n\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container,\n\t\t\tBundle savedInstanceState) {\n\t\tview = inflater.inflate(R.layout.fragment_zhu, null);\n\t\tinitView();\n\t\tinitData();\n\t\treturn view;\n\t}", "@Override\n\t\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState)\n\t\t{\n\t\t\tView rootView = inflater.inflate(R.layout.maimfragment, container, false);\n\t\t\treturn rootView;\n\t\t}", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n // Inflate the layout for this fragment\n return inflater.inflate(R.layout.fragment__record__week, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_porishongkhan, container, false);\n\n\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_dashboard, container, false);\n resultsRv = view.findViewById(R.id.db_results_rv);\n resultText = view.findViewById(R.id.db_search_empty);\n progressBar = view.findViewById(R.id.db_progressbar);\n lastVisitText = view.findViewById(R.id.db_last_visit);\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(getLayoutId(), container, false);\n init(view);\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.fragment_feedback, container, false);\n self = getActivity();\n initUI(view);\n initControlUI();\n initData();\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View v = inflater.inflate(R.layout.fragment_service_summery, container, false);\n tvVoiceMS = v.findViewById(R.id.tvVoiceValue);\n tvDataMS = v.findViewById(R.id.tvdataValue);\n tvSMSMS = v.findViewById(R.id.tvSMSValue);\n tvVoiceFL = v.findViewById(R.id.tvVoiceFLValue);\n tvDataBS = v.findViewById(R.id.tvDataBRValue);\n tvTotal = v.findViewById(R.id.tvTotalAccountvalue);\n return v;\n }", "@Override\r\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\r\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_clan_rank_details, container, false);\r\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_star_wars_list, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View inflate = inflater.inflate(R.layout.fragment_lei, container, false);\n\n initView(inflate);\n initData();\n return inflate;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_quotation, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_wode_ragment, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup parent, Bundle savedInstanceState) {\n\n\n\n\n\n return inflater.inflate(R.layout.fragment_appoint_list, parent, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n if (rootView == null) {\n rootView = inflater.inflate(R.layout.fragment_ip_info, container, false);\n initView();\n }\n return rootView;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_offer, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_rooms, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n\n View view = inflater.inflate(R.layout.fragment_img_eva, container, false);\n\n getSendData();\n\n initView(view);\n\n initData();\n\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_project_collection, container, false);\n ButterKnife.bind(this, view);\n fragment = this;\n initView();\n getCollectionType();\n // getCategoryList();\n initBroadcastReceiver();\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.fragment_yzm, container, false);\n initView(view);\n return view;\n }", "@Override\r\n\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n\t\tmainLayout = inflater.inflate(R.layout.fragment_play, container, false);\r\n\t\treturn mainLayout;\r\n\t}", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.fragment_invite_request, container, false);\n initialiseVariables();\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n getLocationPermission();\n return inflater.inflate(R.layout.centrum_fragment, container, false);\n\n\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View rootView = inflater.inflate(R.layout.fragment_habit_type_details, container, false);\n\n habitTitle = rootView.findViewById(R.id.textViewTitle);\n habitReason = rootView.findViewById(R.id.textViewReason);\n habitStartDate = rootView.findViewById(R.id.textViewStartDate);\n habitWeeklyPlan = rootView.findViewById(R.id.textViewWeeklyPlan);\n\n return rootView;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View v = inflater.inflate(R.layout.fragment_information_friends4, container, false);\n\n if (getArguments() != null) {\n FriendsID = getArguments().getString(\"keyFriends\");\n }\n\n return v;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_post_details, container, false);\n\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_hotel, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view=inflater.inflate(R.layout.fragment_bus_inquiry, container, false);\n initView();\n initData();\n initDialog();\n getDataFromNet();\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_weather, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_srgl, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.fragment_ground_detail_frgment, container, false);\n init();\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_book_appointment, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.fragment_wheretogo, container, false);\n ids();\n setup();\n click();\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n binding = DataBindingUtil\n .inflate(inflater, R.layout.fragment_learning_leaders, container, false);\n init();\n\n return rootView;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_end_game_tab, container, false);\n\n setupWidgets();\n setupTextFields(view);\n setupSpinners(view);\n\n // Inflate the layout for this fragment\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.memoir_fragment, container, false);\n\n getUserIdFromSharedPref();\n configureUI(view);\n configureSortSpinner();\n configureFilterSpinner();\n\n networkConnection = new NetworkConnection();\n new GetAllMemoirTask().execute();\n\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_jadwal, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.fragment_delivery_detail, container, false);\n initialise();\n\n\n\n return view;\n }", "@Nullable\n @Override\n public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_4, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_all_product, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_group_details, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment06_7, container, false);\n initView(view);\n setLegend();\n setXAxis();\n setYAxis();\n setData();\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_downloadables, container, false);\n }", "@Override\n public View onCreateView(@NonNull LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.movie_list_fragment, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_like, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_hall, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_unit_main, container, false);\n TextView mTxvBusinessAassistant = (TextView) view.findViewById(R.id.txv_business_assistant);\n TextView mTxvCardINformation = (TextView) view.findViewById(R.id.txv_card_information);\n RelativeLayout mRelOfficialWebsite = (RelativeLayout) view.findViewById(R.id.rel_official_website);\n RelativeLayout mRelPictureAblum = (RelativeLayout) view.findViewById(R.id.rel_picture_album);\n TextView mTxvQrCodeCard = (TextView) view.findViewById(R.id.txv_qr_code_card);\n TextView mTxvShareCard = (TextView) view.findViewById(R.id.txv_share_card);\n mTxvBusinessAassistant.setOnClickListener(this.mOnClickListener);\n mTxvCardINformation.setOnClickListener(this.mOnClickListener);\n mRelOfficialWebsite.setOnClickListener(this.mOnClickListener);\n mRelPictureAblum.setOnClickListener(this.mOnClickListener);\n mTxvQrCodeCard.setOnClickListener(this.mOnClickListener);\n mTxvShareCard.setOnClickListener(this.mOnClickListener);\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_moviespage, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_s, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_overview, container, false);\n\n initOverviewComponents(view);\n registerListeners();\n initTagListener();\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_bahan_ajar, container, false);\n initView(view);\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n root = (ViewGroup) inflater.inflate(R.layout.money_main, container, false);\n context = getActivity();\n initHeaderView(root);\n initView(root);\n\n getDate();\n initEvetn();\n return root;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup parent, Bundle savedInstanceState) {\n // Defines the xml file for the fragment\n return inflater.inflate(R.layout.fragment_historical_event, parent, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_event_details, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_video, container, false);\n unbinder = ButterKnife.bind(this, view);\n initView();\n initData();\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n\n v= inflater.inflate(R.layout.fragment_post_contacts, container, false);\n this.mapping(v);\n return v;\n }", "@Nullable\n @Override\n public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_measures, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_feed, container, false);\n findViews(view);\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_surah_list, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_data_binded, container, false);\n }" ]
[ "0.6739604", "0.67235583", "0.6721706", "0.6698254", "0.6691869", "0.6687986", "0.66869223", "0.6684548", "0.66766286", "0.6674615", "0.66654444", "0.66654384", "0.6664403", "0.66596216", "0.6653321", "0.6647136", "0.66423255", "0.66388357", "0.6637491", "0.6634193", "0.6625158", "0.66195583", "0.66164845", "0.6608733", "0.6596594", "0.65928894", "0.6585293", "0.65842897", "0.65730995", "0.6571248", "0.6569152", "0.65689117", "0.656853", "0.6566686", "0.65652984", "0.6553419", "0.65525705", "0.65432084", "0.6542382", "0.65411425", "0.6538022", "0.65366334", "0.65355957", "0.6535043", "0.65329415", "0.65311074", "0.65310687", "0.6528645", "0.65277404", "0.6525902", "0.6524516", "0.6524048", "0.65232015", "0.65224624", "0.65185034", "0.65130377", "0.6512968", "0.65122765", "0.65116245", "0.65106046", "0.65103024", "0.6509013", "0.65088093", "0.6508651", "0.6508225", "0.6504662", "0.650149", "0.65011525", "0.6500686", "0.64974767", "0.64935696", "0.6492234", "0.6490034", "0.6487609", "0.6487216", "0.64872116", "0.6486594", "0.64861935", "0.6486018", "0.6484269", "0.648366", "0.6481476", "0.6481086", "0.6480985", "0.6480396", "0.64797544", "0.647696", "0.64758915", "0.6475649", "0.6474114", "0.6474004", "0.6470706", "0.6470275", "0.64702207", "0.6470039", "0.6467449", "0.646602", "0.6462256", "0.64617974", "0.6461681", "0.6461214" ]
0.0
-1
Continue the most recent workout.
private void continueLastWorkout() { Workout last_workout = lift_db_helper.selectLastWorkout(); if (last_workout != null) { AddLift.start(current_context, last_workout); } else { Snackbar no_previous_workouts = Snackbar.make(findViewById(R.id.continue_workout_button), R.string.no_workouts_to_continue, Snackbar.LENGTH_LONG); no_previous_workouts.setAction(R.string.start_new_workout, new View.OnClickListener() { @Override public void onClick(View v) { NewWorkoutDialog new_workout_dialog = new NewWorkoutDialog(v.getContext(), lift_db_helper); new_workout_dialog.show(); } }); no_previous_workouts.show(); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void getNextWorkout(){\n mCurrentWorkout += 1;\n mCurrentData += 1;\n if (mCurrentData > 1) {\n mTxtTitle.setText(\"(\" + mCurrentWorkout + \"/\" + mWorkoutNames.size() + \") \" +\n mWorkoutNames.get(mCurrentData - 1));\n mIsPlay = true;\n mIsBreak = true;\n// int is = Integer.parseInt(mWorkoutIds.get(mCurrentData - 1));\n startTimer(mWorkoutTimes.get(mCurrentData - 1));\n }\n\n mCirclePageIndicator.setCurrentItem(mCurrentData - 1);\n }", "private boolean nextWorkorder() {\n\t\treturn Console.readString(\" Any other workorder? (y/n) \").equalsIgnoreCase(\"y\");\n\t}", "@Override\n\tpublic void comeBackToWork() {\n\t\t\n\t}", "private static void askForContinue() {\n\t\t\t\n\t\t}", "private void replayNextOp() {\n\t\topNum++;\n\t\tif (opNum > ops.length) {\n\t\t\topNum = -1;\n\t\t\tupdate();\n\t\t} else if (!getExited()) {\n\t\t\tjavax.swing.SwingUtilities.invokeLater(doReplayNextOp);\n\t\t}\n\t}", "@Override\n\tprotected void updateOtherProgress() {\n\t\t\n\t\ttempList.clear();\n\t\titeration++;\n\t\tJMetalLogger.logger.info(iteration + \" iteration...\");\n\t\t\n//\t\ttry {\n//\t\t\tnew SolutionListOutput(getPopulation()).printObjectivesToFile(\"results/media/FUN\"+iteration+\".tsv\");\n//\t\t} catch (IOException e) {\n//\t\t\te.printStackTrace();\n//\t\t}\n\t}", "@Override\r\n\tpublic void goWork() {\n\t\tSystem.out.println(\"骑自行去上班\");\r\n\t}", "public void goToNextDay() {\n currDay ++;\n\n // at the beginning of a new day, all the unvisited POIs should be feasible\n feasiblePOIs = new LinkedList<>(unvisitedPOIs);\n\n // update features for the feasible POIs\n for (PlaceOfInterest poi : feasiblePOIs)\n updateFeatures(poi);\n }", "@Override\r\n public void updateExit() {\r\n if (((CompositeGoal) compositeGoal).allOtherGoalsComplete()) {\r\n goalCompleted = true;\r\n compositeGoal.processGoal();\r\n } else {\r\n System.out.println(\"Need to complete other goals first\");\r\n }\r\n }", "public void backtrack() {\n advance();\n if (isGoal()) {\n if (print) {\n System.out.println(\"\\nGOAL!\");\n }\n winConfig = copyBoard();\n deadvance();\n }\n else {\n for (int i = 1; i < 10; i++) {\n board[currRow][currColumn] = i;\n if (print) {\n printThings(i);\n }\n if (isValid()) {\n backtrack();\n }\n }\n board[currRow][currColumn] = 0;\n deadvance();\n }\n }", "private void doExit() {\n\t\tif (userMadeChanges()) {\n showSaveChangesBeforeExitPrompt();\n\t\t} else {\n\t\t\tfinish();\n\t\t}\n\t}", "private void advanceToNextInteractionSteps() {\r\n if (this.currentStep < this.notifications.size() - 1) {\r\n this.currentStep++;\r\n this.notificationLabel.setText(\" \" + this.notifications.get(this.currentStep).getMessage());\r\n this.notificationLabel.repaint();\r\n }\r\n }", "public void addContinue() {\n if (cursor == 0) {\n JOptionPane.showMessageDialog(null, \"There's no note to continue!\", \"Invalid Continue\", JOptionPane.WARNING_MESSAGE);\n } else {\n notePressed(CONTINUE);\n }\n }", "WorkoutBatch end(boolean wasInVehicle);", "private void btnendActionPerformed(java.awt.event.ActionEvent evt) {\n if(curtask==tottask)\n return;\n while(li.hasNext())\n li.next();\n t=(Task)li.previous();\n curtask=tottask;\n //updates display and the scheduled task\n lblctask.setText(\" \"+ curtask);\n txtname.setText(t.getName());\n txtdesc.setText(t.getDescription());\n \n }", "public void action() {\n store.readNextArrival();\n Employee employee = (Employee)this.getActor();\n checkout = store.firstUnmannedCheckout();\n checkout.setCashier(employee);\n checkout.setOpen(true);\n int quittingTime = employee.getQuittingTime();\n Event event = new ShiftCompletedEvent(quittingTime, employee, checkout);\n store.getEventList().addEvent(event);\n \n System.out.printf(\"Time %d: Cashier %d arrives (Speed %d, quitting time %d, checkout %d)\\n\",\n time,\n employee.getId(),\n employee.getSpeed(),\n employee.getQuittingTime(),\n checkout.getIndex());\n }", "public void endCurrentStage() {\n \n stages.getItem(currentStage - 1).setIsFinished(true);\n stages.getItem(currentStage - 1).setEndDate(super.getTimeFormat().format(LocalDateTime.now()));\n if (stages.getItem(currentStage - 1).isFinished()) {\n currentStage++;\n } else {\n System.out.println(\"Por favor, revise y emprenda acciones en su producción \" +\n \"para cumplir con los estándares de calidad, tome nuevos datos e intente de nuevo.\");\n }\n }", "public static void skipCurrentJob() {\n\t\tdo {\n\t\t\tcurrentCombo[jobsChosen - 1]++;\n\t\t} while (!checkRows() && currentCombo[jobsChosen - 1] < numPeople);\n\t\t\n\t}", "public void advanceToEndOfNextTrick() {\n\n if (isGameOver()) {\n return;\n }\n \n if (isFirstTurn) {\n startTurn();\n isFirstTurn=false;\n }\n else {\n state=state.withTrickCollected();\n for (Map.Entry<PlayerId, Player> pId: players.entrySet()) {\n pId.getValue().updateScore(state.score());\n }\n }\n\n if (isGameOver()) {\n for (Map.Entry<PlayerId, Player> pId: players.entrySet()) {\n pId.getValue().setWinningTeam(findWinningTeam());\n }\n return;\n }\n\n if (!isFirstTurn && state.isTerminal()) {\n startTurn();\n }\n\n for (Map.Entry<PlayerId, Player> pId: players.entrySet()) {\n pId.getValue().updateScore(state.score());\n pId.getValue().updateTrick(state.trick());\n }\n\n while (!(state.trick().isFull())) {\n playNextPlayer();\n }\n }", "public void switchLastWindow() {\n\n Set<String> allwindow = driver.getWindowHandles();\n\n for (String next : allwindow) {\n driver.switchTo().window(next);\n\n }\n }", "public void masterProg() {\n\t\tmoveObjsToGoals();\r\n\t}", "public void continueRun() {\n pause = false;\n }", "@Override\r\n\tprotected void doLast() {\n\t\t\r\n\t}", "protected void end() {\n \tif (waitForMovement) Robot.intake.setHopperTracker(deploy ? Status.deployed : Status.stowed);\n }", "@Override\n public void update(Workout e) {\n\n }", "public void finish(){\n\t\tnotfinish = false;\n\t}", "public void onLast() {\r\n\t\t\t\t\tif (wip.decrementAndGet() == 0) {\r\n\t\t\t\t\t\tobserver.finish();\r\n\t\t\t\t\t\tclose();\r\n\t\t\t\t\t}\r\n\t\t\t\t}", "void ifDoneFinish() {\r\n\t\t\t\t\t\tif (wip.decrementAndGet() == 0) {\r\n\t\t\t\t\t\t\tobserver.finish();\r\n\t\t\t\t\t\t\tclose();\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}", "public void makeNextMove() {\n\t\ttakeNextNonTabuedCheapestStep();\n\t\t}", "void finishSwitching();", "public static void toContinue() {\n System.out.println(EOF + \"Presiona ENTER para continuar...\");\n new Scanner(System.in).nextLine();\n }", "public void switchToLastWindow() {\n\t\tSet<String> windowHandles = getDriver().getWindowHandles();\n\t\tfor (String str : windowHandles) {\n\t\t\tgetDriver().switchTo().window(str);\n\t\t}\n\t}", "public void addDefaultWorkouts() {\n DatabaseHelper databaseHelper = new DatabaseHelper(context);\n for (int i = 0; i < builtIns.length; i++) {\n if (builtIns[i].getDurations().length == builtIns[i].getDurations().length) {\n if (databaseHelper.insertWorkout(builtIns[i].getName())) {\n databaseHelper.fillWorkout(builtIns[i].getName(),\n builtIns[i].getActivities(),\n builtIns[i].getDurations());\n }\n }\n }\n }", "public void onFinish() {\n updatedTime = 0;\n\n if (seqNumber > 1) {\n if (cycleNumber != 0) {\n if (!didiwork) {\n didiwork = true;\n nextTimer(workTime);\n ActionName = \"Travail\";\n } else {\n didiwork = false;\n cycleNumber --;\n nextTimer(downTime);\n ActionName = \"Repos\";\n }\n } else {\n cycleNumber = initialCycleNumber;\n seqNumber --;\n didiwork = false;\n nextTimer(longDownTime);\n ActionName = \"LongRepos\";\n }\n } else {\n if (cycleNumber != 0) {\n if (!didiwork) {\n didiwork = true;\n nextTimer(workTime);\n ActionName = \"Travail\";\n } else {\n didiwork = false;\n cycleNumber --;\n nextTimer(downTime);\n ActionName = \"Repos\";\n }\n } else {\n ActionName = \"FINIIIIII\";\n }\n }\n shakeItBaby();\n // Mise à jour\n update();\n }", "public void pauseWorkout(){\n mStart = 0;\n mEnd = 0;\n mIsPlay = false;\n mIsPause = true;\n mFabPlay.setIcon(R.mipmap.ic_play_arrow_white_24dp);\n if(mCounter != null) {\n if (mCounter.timerCheck()) mCounter.cancel();\n mCurrentTime = mCounter.timerPause();\n }\n if(mIsFirstAppRun){\n mTxtBreakTime.setText(mCurrentTime);\n }else {\n if (mIsBreak) {\n // If this is break, set mTimer to break time view and set sub title view\n // with initial time\n mTxtBreakTime.setText(mCurrentTime);\n mTxtSubTitle.setText(mCurrentTime);\n } else {\n mTxtSubTitle.setText(mCurrentTime);\n }\n }\n }", "public void previousSolution() {\r\n\t\tif (solutionIndex > 0) {\r\n\t\t\tsolutionIndex--;\r\n\t\t\tcreateObjectDiagram(solutions.get(solutionIndex));\r\n\t\t} else {\r\n\t\t\tLOG.info(LogMessages.pagingFirst);\r\n\t\t}\r\n\t}", "@Override\n\tpublic void work() {\n\t\t// TODO Auto-generated method stub\n\t\tSystem.out.println(\"We work in TestYantra software solution\");\n\t\t\n\t}", "public void playWorkouts(){\n mFabPlay.setIcon(R.mipmap.ic_pause_white_24dp);\n mIsPlay = true;\n mCirclePageIndicator.setCurrentItem(mCurrentWorkout);\n\n if(mIsPause) {\n // re-play paused workout\n mCounter.cancel();\n startTimer(mCurrentTime);\n } else {\n // Start ready timer\n mLytBreakLayout.setVisibility(View.VISIBLE);\n if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) {\n ttsGreater21(getString(R.string.beginning_workout));\n } else {\n ttsUnder20(getString(R.string.beginning_workout));\n }\n startTimer(_str_break);\n }\n }", "@Override\n\tvoid finishWork() {\n\t\t\n\t}", "@Override\n\tvoid finishWork() {\n\t\t\n\t}", "public void moveToNextStep() {\n Step.Phase nextPhase = currentStep.GetNextPhase();\n changeCurrentStep(nextPhase);\n if (currentStep.getCurrentPhase().equals(Step.Phase.COMPLETED) ||\n currentStep.getCurrentPhase().equals(Step.Phase.FAILED)) {\n setCompleteTime(System.currentTimeMillis());\n }\n }", "private void next() {\n Timeline currentTimeline = simpleExoPlayerView.getPlayer().getCurrentTimeline();\n if (currentTimeline.isEmpty()) {\n return;\n }\n int currentWindowIndex = simpleExoPlayerView.getPlayer().getCurrentWindowIndex();\n if (currentWindowIndex < currentTimeline.getWindowCount() - 1) {\n player.seekTo(currentWindowIndex + 1, C.TIME_UNSET);\n } else if (currentTimeline.getWindow(currentWindowIndex, new Timeline.Window(), false).isDynamic) {\n player.seekTo(currentWindowIndex, C.TIME_UNSET);\n }\n }", "public void moveAccepted()\n {\n printOut(printerMaker.moveAccepted());\n }", "private void doLastTurn()\n\t{\n\t\tInteger time = turn;\n\n\t\tstartEnterScore(time);\n\t\tdisposeFrameMap();\n\n\t\ttimer.cancel();\n\t}", "private void continueGame() {\n System.out.println(\"\\n\" + \"Do you want to play more games or quit?\\n\" + \"1. Lotto\\n\" + \"2. Small Lotto\\n\" + \"3. Quit\");\n input = scanner.next();\n changeGame();\n }", "public void backStep() {\r\n\t\tif (engaged && !backSteps.empty()) {\r\n\t\t\tProgramStatement statement = ((BackStep) backSteps.peek()).ps;\r\n\t\t\tengaged = false; // GOTTA DO THIS SO METHOD CALL IN SWITCH WILL NOT\r\n\t\t\t\t\t\t\t\t// RESULT IN NEW ACTION ON STACK!\r\n\t\t\tdo {\r\n\t\t\t\tBackStep step = (BackStep) backSteps.pop();\r\n\t\t\t\t/*\r\n\t\t\t\t * System.out.println(\"backstep POP: action \"+step.action+\" pc \"\r\n\t\t\t\t * +mars.util.Binary.intToHexString(step.pc)+\r\n\t\t\t\t * \" source \"+((step.ps==null)? \"none\":step.ps.getSource())+\r\n\t\t\t\t * \" parm1 \"+step.param1+\" parm2 \"+step.param2);\r\n\t\t\t\t */\r\n\t\t\t\tif (step.pc != NOT_PC_VALUE) {\r\n\t\t\t\t\tRegisterFile.setProgramCounter(step.pc);\r\n\t\t\t\t}\r\n\t\t\t\ttry {\r\n\t\t\t\t\tswitch (step.action) {\r\n\t\t\t\t\tcase MEMORY_RESTORE_RAW_WORD:\r\n\t\t\t\t\t\tGlobals.memory.setRawWord(step.param1, step.param2);\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tcase MEMORY_RESTORE_WORD:\r\n\t\t\t\t\t\tGlobals.memory.setWord(step.param1, step.param2);\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tcase MEMORY_RESTORE_HALF:\r\n\t\t\t\t\t\tGlobals.memory.setHalf(step.param1, step.param2);\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tcase MEMORY_RESTORE_BYTE:\r\n\t\t\t\t\t\tGlobals.memory.setByte(step.param1, step.param2);\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tcase REGISTER_RESTORE:\r\n\t\t\t\t\t\tRegisterFile.updateRegister(step.param1, step.param2);\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tcase PC_RESTORE:\r\n\t\t\t\t\t\tRegisterFile.setProgramCounter(step.param1);\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tcase COPROC0_REGISTER_RESTORE:\r\n\t\t\t\t\t\tCoprocessor0.updateRegister(step.param1, step.param2);\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tcase COPROC1_REGISTER_RESTORE:\r\n\t\t\t\t\t\tCoprocessor1.updateRegister(step.param1, step.param2);\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tcase COPROC1_CONDITION_CLEAR:\r\n\t\t\t\t\t\tCoprocessor1.clearConditionFlag(step.param1);\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tcase COPROC1_CONDITION_SET:\r\n\t\t\t\t\t\tCoprocessor1.setConditionFlag(step.param1);\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tcase DO_NOTHING:\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t}\r\n\t\t\t\t} catch (Exception e) {\r\n\t\t\t\t\t// if the original action did not cause an exception this\r\n\t\t\t\t\t// will not either.\r\n\t\t\t\t\tSystem.out.println(\"Internal MARS error: address exception while back-stepping.\");\r\n\t\t\t\t\tSystem.exit(0);\r\n\t\t\t\t}\r\n\t\t\t} while (!backSteps.empty() && statement == ((BackStep) backSteps.peek()).ps);\r\n\t\t\tengaged = true; // RESET IT (was disabled at top of loop -- see\r\n\t\t\t\t\t\t\t// comment)\r\n\t\t}\r\n\t}", "public void finish(){\n \t\tString congrats=\"Congratulations, you won in \" + model.getNumberOfSteps()+\" steps! \";\n \t\tJFrame frame = new JFrame();\n\t\tString[] options = new String[2];\n\t\toptions[0] = new String(\"Play again\");\n\t\toptions[1] = new String(\"Quit\");\n\t\tint result= JOptionPane.showOptionDialog(frame.getContentPane(),congrats,\"Won! \", 0,JOptionPane.INFORMATION_MESSAGE,null,options,null);\n\t\tif (result == JOptionPane.NO_OPTION) {\n\t\t\t\t\tSystem.exit(0);\n\t\t\t\t}\n\t\t\t\tif (result == JOptionPane.YES_OPTION) {\n\t\t\t\t\tcontroller.reset(); }\n \t}", "public void resumeUpdates();", "@Override\n\tpublic void doJob() {\n\t\tSystem.out.println(\"Studying\");\n\t}", "@Override\n\t\tpublic void finishIteration() {\n\t\t\trailroad.save();\n\t\t\tSystem.out.println(\"SAVING!\");\n\t\t\tsuper.finishIteration();\n\t\t}", "private void endingAction() {\n this.detectChanges();\n if (this.isModifed) {\n //System.out.println(JOptionPane.showConfirmDialog(null, \"Do you want to save unsaved changes?\", \"Hey User!\", JOptionPane.YES_NO_CANCEL_OPTION));\n switch (JOptionPane.showConfirmDialog(null, \"Do you want to save current data?\", \"Hey User!\", JOptionPane.YES_NO_CANCEL_OPTION)) {\n case 0: {\n if (this.file != null) {\n INSTANCE.saveData();\n INSTANCE.dispose();\n System.exit(0);\n break;\n }\n }\n\n case 1: {\n INSTANCE.dispose();\n System.exit(0);\n break;\n }\n }\n\n //cancel op 2\n //no op 1\n //yes op 0\n } else {\n INSTANCE.dispose();\n System.exit(0);\n }\n }", "public void playerFinishedGoNext() {\n\t\t// If game is over we don't want to switch turn.\n\t\tif (!isOver()) {\n\t\t\tswitchTurn();\n\t\t}\n\t}", "public void commitExploration() {\n watermarkCommittedTick = watermarkGoalTick;\n }", "public void sendToStagingArea() {\n if (queryExpired) {\n String[] options = {\"Resubmit\", \"New Query\"};\n int rtn = JOptionPane.showOptionDialog(this,\n \"Query has Expired;\\nNew Query Required\", null,\n JOptionPane.YES_NO_OPTION, JOptionPane.WARNING_MESSAGE,\n null, options, options[0]);\n\n if (rtn == JOptionPane.YES_OPTION) {\n // Resubmit the existing query\n InfoPanel.searchButton.doClick();\n\n return;\n\n } else {\n // Reset the panel to the search panel\n tabbedPane.setSelectedIndex(0);\n\n // Clear the summary model\n msbQTM.clear();\n\n // Clear the project model\n ((ProjectTableModel) projectTable.getModel()).clear();\n initProjectTable();\n\n return;\n }\n }\n\n if (table.getSelectedRow() != -1) {\n performSendToStagingArea();\n om.updateDeferredList();\n\n } else {\n JOptionPane.showMessageDialog(this,\n \"Must select a project summary first!\");\n }\n }", "private void nextTraining() {\n\t\tif(!training_queue.isEmpty()) {\n\t\t\tPair<Soldier, Integer> tmp = training_queue.remove();\n\t\t\tif(tmp!=null) {\n\t\t\t\tcurrent = tmp.getKey();\n\t\t\t\tnb_to_train = tmp.getValue();\t\t\n\t\t\t\tnb_rounds = current.getTime_prod();\n\t\t\t}else {\n\t\t\t\tcurrent = null;\n\t\t\t\tnb_to_train = 1;\n\t\t\t\tnb_rounds = 100+50*(owner_castle.getLevel()+1);\n\t\t\t\tupgrade = true;\n\t\t\t}\n\t\t}else\n\t\t\tcurrent = null;\n\t}", "public GoToWork(Player player)\n\t\t{\n\t\t\tsuper(player,\"Work\",100);\n\t\t}", "public void run() {\n LocalDateTime now = LocalDateTime.now();\n int month = now.getMonthValue();\n int day = now.getDayOfMonth();\n int year = now.getYear();\n String workingDate = \"\" + month + day + year;\n cio.print(\"\\nThe current date is \" + month + \"/\" + day + \"/\" + year);\n\n myOrder.load(workingDate);\n myProduct.load();\n myTax.load();\n\n int command = 0;\n\n while (command != 7) {\n command = ui.promptMenuChoice();\n switch (command) {\n case 1:\n boolean wantToSave = ui.promptToSave();\n if (wantToSave) {\n myOrder.save(workingDate);\n cio.print(\"Your work has been saved.\\n\");\n }\n //set date\n workingDate = ui.promptForDate();\n myOrder.load(workingDate);\n break;\n case 2:\n //add order\n addOrder(workingDate);\n break;\n case 3:\n //display all orders\n displayAllOrders(workingDate);\n break;\n case 4:\n //edit an order\n editOrder();\n break;\n case 5:\n //cancel an order\n cancelOrder();\n break;\n case 6:\n myOrder.save(workingDate);\n cio.print(\"Your work has been saved.\\n\");\n break;\n case 7:\n //prompt to save\n wantToSave = ui.promptToSave();\n if (wantToSave) {\n myOrder.save(workingDate);\n cio.print(\"Your work has been saved.\\n\");\n }\n //quit program\n default:\n break;\n }\n }\n myProduct.save();\n myTax.save();\n }", "public void clickContinue() {\n\t\tcontinueButton.click();\n\t}", "@Override\n public void redo()\n {\n story.setEstimate(newEstimate);\n }", "public void next() {\n Solver<ArrayList<Integer>> mySolver =\n new Solver<ArrayList<Integer>>();\n ArrayList<ArrayList<Integer>> Solution =\n mySolver.SolveBFS(this);\n\n //Reset 'tried' to none\n tried = new HashSet<ArrayList<Integer>>();\n\n //Set up the nextState\n ArrayList<Integer> nextState = new ArrayList<Integer>();\n\n if(Solution.size() == 0) {\n //No Solution\n } else if (Solution.size() == 1) {\n nextState = Solution.get(0);\n curBoard = nextState;\n } else {\n nextState = Solution.get(1);\n curBoard = nextState;\n moveCount++;\n }\n clearStack();\n\n\tsetChanged();\n\tnotifyObservers();\n }", "protected void finishExecution() {\r\n\r\n\t}", "@Override\n\t\t\tpublic void worked(int work) {\n\t\t\t\t\n\t\t\t}", "public void jumpToCurrentState() {\n if (mRunningAnimator != null) {\n mRunningAnimator.end();\n }\n }", "public void startExploration() {\n watermarkGoalTick = currentTick;\n }", "public void runTillNextPhase () throws NormalizeNullVectorException\n {\n \tint currentPhase = getPhase ();\n \tLearningEditProposal bestEditProposal = getBestEdit (true, true);\n while ((bestEditProposal != null) && (currentPhase == getPhase ()))\n {\n step ( bestEditProposal.getEdit ());\n bestEditProposal = getBestEdit (true, true);\n }\n }", "protected void end() {\r\n lang.nextStep();\r\n int total = seen + failed;\r\n\r\n hideAll();\r\n SourceCode end = lang.newSourceCode(new Offset(0, 50, pMap.get(\"hRect\"),\r\n \"SW\"), \"end\", null, sourceCodeProperties);\r\n end.addCodeLine(\r\n \"Das h\\u00F6chste Ergebnis, dass der Spieler bei einem optimal spielenden Gegner erzielen kann, ist \"\r\n + result + \".\", \"end\", 0, null);\r\n if (seen == 1) {\r\n end.addCodeLine(\"Von den insgesamt \" + nodesTotal + \" Knoten wurde \"\r\n + seen + \" nur Knoten untersucht.\", \"end\", 0, null);\r\n } else {\r\n end.addCodeLine(\"Von den insgesamt \" + nodesTotal + \" Knoten wurden \"\r\n + seen + \" verschiedene Knoten untersucht.\", \"end\", 0, null);\r\n }\r\n if (pruned == 1) {\r\n end.addCodeLine(\"Es wurde \" + pruned + \" Knoten gepruned.\", \"end\", 0,\r\n null);\r\n } else {\r\n end.addCodeLine(\"Es wurde \" + pruned + \" Knoten gepruned.\", \"end\", 0,\r\n null);\r\n }\r\n if (failed == 1) {\r\n end.addCodeLine(\"Allerdings musste auch \" + failed\r\n + \" Knoten erneut untersucht werden, weil es zum Fail High kam.\",\r\n \"end\", 0, null);\r\n } else {\r\n end.addCodeLine(\"Allerdings mussten auch \" + failed\r\n + \" Knoten erneut untersucht werden, weil es zum Fail High kam.\",\r\n \"end\", 0, null);\r\n }\r\n end.addCodeLine(\"Damit wurde der Algorithmus insgesamt \" + total\r\n + \" Mal aufgerufen.\", \"end\", 0, null);\r\n end.addCodeLine(\r\n \"Im Vergleich dazu h\\u00E4tte der Minimax-Algorithmus alle \"\r\n + nodesTotal + \" Knoten einmal untersucht.\", \"end\", 0, null);\r\n end.addCodeLine(\"\", \"end\", 0, null);\r\n end.addCodeLine(\r\n \"Da der Algorithmus annimmt, dass jeweils der erste Kindknoten der beste ist \",\r\n \"end\", 0, null);\r\n end.addCodeLine(\r\n \"und danach mit einem Nullwindow arbeitet, ist die Reihenfolge der Knoten sehr wichtig, \",\r\n \"end\", 0, null);\r\n end.addCodeLine(\r\n \"damit m\\u00F6glichst viele Knoten gepruned werden und m\\u00F6glichst wenige erneut untersucht werden m\\u00FCssen.\",\r\n \"end\", 0, null);\r\n end.addCodeLine(\r\n \"Es kann sich sogar zeitlich lohnen, die Knoten vorzusortieren.\",\r\n \"end\", 0, null);\r\n end.addCodeLine(\r\n \"Bei unsortierten Knoten ist der Negascout-Algorithmus langsamer als das Alpha-Beta-Pruning,\",\r\n \"end\", 0, null);\r\n end.addCodeLine(\r\n \"bei dem zwar weniger Knoten nicht untersucht werden, daf\\u00FCr aber auch keine erneut untersucht werden m\\u00FCssen.\",\r\n \"end\", 0, null);\r\n end.addCodeLine(\r\n \"Die Komplexit\\u00E4t von Negascout betr\\u00E4gt O(b^d) in der Landau-Notation,\",\r\n \"end\", 0, null);\r\n end.addCodeLine(\r\n \"wobei b f\\u00FCr den Verzweigungsfaktor (branching factor) und d f\\u00FCr die Baumtiefe (depth) steht\",\r\n \"end\", 0, null);\r\n lang.nextStep(\"Conclusion\");\r\n }", "@Override\n\tpublic void reallyDoStep() {\n\t\tif(!(this.isFinished())) this.timeRemaining--; \n\t\treturn;\n\t}", "public void endOfRoundUpdates() {\n roundsHistory.push(new RoundHistory(gameDescriptor,++roundNumber));\n loadPlayersIntoQueueOfTurns();\n //activateEventsHandler();\n }", "public void goToLoopCounter() throws EndTaskException {\n\t\tgoToOrigin();\n\t\tturnAround();\n\t\tmove();//lane 2\n\t\tmove();\n\t}", "public void ex02() {\n\n boolean hasFinished = false;\n\n\n if (hasFinished==true) {\n printResults();\n }\n\n\n }", "private void advance() {\n assert currentItemState == ItemProcessingState.COMPLETED || currentIndex == -1\n : \"moving to next but current item wasn't completed (state: \" + currentItemState + \")\";\n currentItemState = ItemProcessingState.INITIAL;\n currentIndex = findNextNonAborted(currentIndex + 1);\n retryCounter = 0;\n requestToExecute = null;\n executionResult = null;\n assert assertInvariants(ItemProcessingState.INITIAL);\n }", "public void nextTurn() {\n\t\tLog.d(TAG, \"nextTurn()\");\t\t\n\t\ttickPeople();\n\t\t//doEvents();\n\t\tupdateBar();\n\t}", "private void continueButton() {\n Optional<Squadron> anyAvailable = game\n .getHumanPlayer()\n .getNations()\n .stream()\n .filter(Nation::isSquadronsPresent)\n .flatMap(nation -> game.getHumanPlayer().getSquadrons(nation, SquadronLocationType.LAND).stream())\n .filter(Squadron::isAvailable)\n .findAny();\n\n List<Region> regionsNotSatisfied = gameMap\n .areAllRegionsSatisfied(game.getHumanSide());\n\n if (anyAvailable.isPresent()) {\n warnNotAllSquadronsDeployed();\n } else if (regionsNotSatisfied.size() > 0) {\n warnNotAllRegionsSatisfied(regionsNotSatisfied);\n } else {\n navigate.goNext(this.getClass(), stage);\n }\n }", "public void toNow() {\r\n // in suspending state, the current step must be non-interruptable\r\n if (currentStep != null && !currentStep.isInterruptable()) {\r\n double now = currentSimulationTime();\r\n double passed_time = now - lastTime;\r\n\r\n if (MathTools.less(0, passed_time)) {\r\n // get the demand of the first job\r\n double demand = running_processes.get(currentStep);\r\n demand -= passed_time;\r\n\r\n // avoid trouble caused by rounding issues\r\n demand = MathTools.equalsDouble(demand, 0) ? 0.0 : demand;\r\n\r\n assert demand >= 0 : \"Remaining demand (\" + demand + \") smaller than zero! at simulation time: \"\r\n + now;\r\n\r\n running_processes.put(currentStep, demand);\r\n }\r\n lastTime = now;\r\n }\r\n }", "protected void finishUp() {\r\n // pushOutput(table, 0);\r\n viewDone(\"Done\");\r\n }", "private static void doWeTerminate() {\n if(nrOfResults == nrOfWorks){\n //clear this round\n nrOfWorks = 0;\n nrOfResults = 0;\n finished = true;\n return;\n }\n }", "@Override\n public WorkflowStep next() {\n this.boardChangeDetected = 0;\n this.missingFutures = 0;\n this.missingTetromino = 0;\n startCalculator(false);\n return DETECT_ANOMALIES;\n }", "@Override\n\tpublic void work() {\n\t\tSystem.out.println(\"看门!!!\");\n\t}", "static void backtocheckpoint1() {\n System.out.println(\"You came back to the main entrance of challenge 1...Are you ready to restart this challenge?\");\n strings = responses.nextLine();\n Door1challenge();\n }", "private void finish() {\n }", "public Iterator<IBDLocus> runLastChrom() {\n return runModelAndCoallateResults();\n }", "public boolean runWizard() throws Exception\n{\n\t// Tells us what came before each state\n\tMap<Wiz,Wiz> prevWizs = new TreeMap();\n\t// v = (xv == null ? new TypedHashMap() : xv);\n\tscreenCache = new TreeMap();\n\tcon = new WizContext();\n\tWiz wiz = nav.getStart();\t\t// Current state\n\tfor (; wiz != null; ) {\n\n\t\t// Get the screen for this Wiz\n\t\tWizScreen screen = screenCache.get(wiz);\n\t\tif (screen == null) {\n\t\t\tscreen = wiz.newScreen(con);\n\t\t\tif (wiz.isCached(Wiz.NAVIGATE_BACK)) screenCache.put(wiz,screen);\n\t\t}\n\n\t\t// Prepare and show the Wiz\n\t\tpreWiz(wiz, con);\n\t\tMap<String,Object> values = new TreeMap();\n\t\tshowScreen(screen, values);\n\n\t\t// Run the post-processing\n\t\twiz.getAllValues(values);\n\t\tcon.localValues = values;\n\t\tString suggestedNextName = postWiz(wiz, con);\n\n\t\t// Figure out where we're going next\n\t\tWiz nextWiz = null;\n\t\tString submit = (String)values.get(\"submit\");\nSystem.out.println(\"submit = \" + submit);\n\t\tif (\"next\".equals(submit)) {\n\t\t\tif (suggestedNextName != null) {\n\t\t\t\tnextWiz = nav.getWiz(suggestedNextName);\n\t\t\t} else {\n\t\t\t\tnextWiz = nav.getNext(wiz, Wiz.NAVIGATE_FWD);\n\t\t\t}\n\t\t\tcon.addValues(values);\n\t\t} else if (\"back\".equals(submit)) {\n\t\t\t// Remove it from the cache so we re-make\n\t\t\t// it going \"forward\" in the Wizard\n\t\t\tif (!wiz.isCached(Wiz.NAVIGATE_FWD)) screenCache.remove(wiz);\n\n\t\t\t// Nav will usually NOT set a NAVIGATE_BACK...\n\t\t\tnextWiz = nav.getNext(wiz, Wiz.NAVIGATE_BACK);\n\n\t\t\t// ... which leaves us free to do it from our history\n\t\t\tif (nextWiz == null) nextWiz = prevWizs.get(wiz);\n\n\t\t\t// Falling off the beginning of our history...\n\t\t\tif (nextWiz == null && reallyCancel()) return false;\n\t\t\tcontinue;\n\t\t} else if (\"cancel\".equals(submit) && reallyCancel()) {\n\t\t\treturn false;\n\t\t} else {\n\t\t\t// Navigation without a \"submit\"; rare but possible...\n\t\t\tif (suggestedNextName != null) {\n\t\t\t\tnextWiz = nav.getWiz(suggestedNextName);\n\t\t\t}\n\t\t\t// Custom navigation!\n\t\t\t// Incorporate the values into the main WizContext\n\t\t\tcon.addValues(values);\n\t\t}\n\n\t\t// ================= Finish up\n\t\twiz.post(con);\n\t\twiz = nextWiz;\n\t}\n\treturn true;\t\t// Won't get here\n}", "public void interrupt(boolean promptToKeepPartialResult) {\n if(worker!=null) worker.interrupt(promptToKeepPartialResult);\n }", "public final void addWorkout(Workout workout) {\r\n\t\tworkoutList.add(workout);\r\n\t}", "public synchronized void back ()\n\t// one move up\n\t{\n\t\tState = 1;\n\t\tgetinformation();\n\t\tgoback();\n\t\tshowinformation();\n\t\tcopy();\n\t}", "@Override\n public void timePassed() {\n moveOneStep();\n }", "@Override\n\tpublic void finish() throws DPFTRuntimeException {\n\t\tDPFTLogger.info(this, \"Updating Outbound Control Records...\");\n\t\tDPFTOutboundDboSet rSet = (DPFTOutboundDboSet) this.getPreviousAction().getResultSet();\n\t\tDPFTOutboundControlDboSet ctrlSet = rSet.getControlTableRecords(\"process_status='\" + GlobalConstants.DPFT_OBND_STAT_RUN + \"'\");\n\t\tctrlSet.taskComplete();\n\t\tctrlSet.close();\n\t\t\n\t\t//send Notification\n\t\tString cmp_code = ctrlSet.getDbo(0).getString(\"camp_code\");\n\t\tfor(String sf: success_ftp_files){\n\t\t\tObject[] params = {sf, this.getOutFileRemoteDir()};\n\t\t\tDPFTUtil.pushNotification(\n\t\t\t\t\tDPFTUtil.getCampaignOwnerEmail(cmp_code), \n\t\t\t\t\tnew DPFTMessage(\"CUSTOM\", \"TFB00011I\", params)\n\t\t\t);\n\t\t}\n\t\tsuccess_ftp_files.clear();\n\t}", "public boolean advanceStep() {\n\t\t// TODO: Implement\n\t\t/*System.out.println(\"Before:\");\n\t\tfor(int i=0; i < getSlotCount(); i++)\n\t\t{\n\t\t\tif(inFlightBeans.get(i)==null)\n\t\t\t\tSystem.out.println(i+\"=null\");\n\t\t\telse\n\t\t\t\tSystem.out.println(i+\" not null:\" + inFlightBeans.get(i).getXPos());\n\t\t}*/\n\t\t\n\t\tboolean anyStatusChange=false;\n\t\tBean prev=null; \n\t\tBean bean=inFlightBeans.get(0);\n\t\t\n\t\tfor(int i=0; i < getSlotCount(); i++)\n\t\t{\n\t\t\tif(i < getSlotCount()-1)\n\t\t\t{\n\t\t\t\t//System.out.println(\"i < count-2\");\n\t\t\t\tprev = bean;\n\t\t\t\tbean = inFlightBeans.get(i+1);\n\t\t\t\tif(prev!=null) prev.choose();\n\t\t\t\tinFlightBeans.set(i+1, prev);\t\t\n\t\t\t\tanyStatusChange = true;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t//System.out.println(\"i else: \" + i);\n\t\t\t\tif(bean != null) {\n\t\t\t\t\tthis.slotBean.get(bean.getXPos()).add(bean);\n\t\t\t\t\tanyStatusChange= true;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t\t\t\t\n\t\t}\n\t\tinsertBean();\n\t\tif(inFlightBeans.get(0) != null) inFlightBeans.get(0).reset();\n\t\t//System.out.println(\"After:\");\n\t\t/*for(int i=0; i < getSlotCount(); i++)\n\t\t{\n\t\t\tif(inFlightBeans.get(i)==null)\n\t\t\t\tSystem.out.println(i+\"=null\");\n\t\t\telse\n\t\t\t\tSystem.out.println(i+\" not null:\" + inFlightBeans.get(i).getXPos());\n\t\t}*/\n\t\treturn anyStatusChange;\n\n\t}", "@Override\n public void run() {\n if (getCurrentItem() + 1 == adapter.getCount()) {\n adapter.markAsFinished();\n }\n\n // Transition to next question\n setCurrentItem(getCurrentItem() + 1);\n\n pendingTransition = false;\n }", "@Override\n public void startIteration() {\n mWindowId = getCurrentWindow();\n\n // Clear out any previous data\n mUiAutomation.clearWindowContentFrameStats(mWindowId);\n }", "public void last(View view){\n finish();\n return;\n }", "public void resume() {\n moveStop = true;\n }", "private void runOverlay_ContinueMethod(){\n ChainTourGuide tourGuide1 = ChainTourGuide.init(getActivity())\n .setToolTip(new ToolTip()\n .setTitle(\"BottomBar\")\n .setDescription(\"The bottom bar is the primary navigation tool in the app.\" +\n \" Use it to switch functionality.\")\n .setGravity(Gravity.TOP)\n .setBackgroundColor(Color.parseColor(\"#333333\"))\n )\n .playLater(bottomBar);\n\n ChainTourGuide tourGuide2 = ChainTourGuide.init(getActivity())\n .setToolTip(new ToolTip()\n .setTitle(\"Add a Profile\")\n .setDescription(\"This button takes you to a screen where you can create Profiles.\" +\n \" Profiles are simply a set of apps to block, and an associated name.\")\n .setGravity(Gravity.BOTTOM | Gravity.LEFT)\n .setBackgroundColor(Color.parseColor(\"#333333\"))\n )\n .playLater(addItemButton);\n\n ChainTourGuide tourGuide3 = ChainTourGuide.init(getActivity())\n .setToolTip(new ToolTip()\n .setTitle(\"Menu\")\n .setDescription(\"This is the menu button - it will have different context\" +\n \" tools based on your location in the app.\")\n .setGravity(Gravity.BOTTOM | Gravity.LEFT)\n .setBackgroundColor(Color.parseColor(\"#333333\"))\n )\n .playLater(largerMenuButton);\n\n ChainTourGuide tourGuide4 = ChainTourGuide.init(getActivity())\n .setToolTip(new ToolTip()\n .setTitle(\"Profile Area\")\n .setDescription(\"This is where profiles will show up once they have been created. \")\n .setGravity(Gravity.BOTTOM)\n .setBackgroundColor(Color.parseColor(\"#333333\"))\n )\n .playLater(profilesRecyclerView);\n\n Sequence sequence = new Sequence.SequenceBuilder()\n .add(tourGuide1, tourGuide2, tourGuide3, tourGuide4)\n .setDefaultOverlay(new Overlay()\n .setEnterAnimation(mEnterAnimation)\n .setExitAnimation(mExitAnimation)\n )\n .setDefaultPointer(null)\n .setContinueMethod(Sequence.ContinueMethod.Overlay)\n .build();\n\n\n ChainTourGuide.init(getActivity()).playInSequence(sequence);\n }", "boolean previousStep();", "@Override\r\n\tpublic void pick() {\r\n\t\tSystem.out.println(\"Stay away from Jessica ya dweeb.\");\r\n\t\r\n\t}", "public void animatingDone() {\n\n\t\t//assign newMap to map\n\t\tupdateMap();\n\n\t\t//assign newPlayerLocation to playerLocation\n\t\tsetPlayerLocation(getNewPlayerLocation());\n\n\t\t//Check if the game has reached game over requirements\n\t\tif(gameOver) {\n\t\t\tif(win) {\n\n\t\t\t\t//show the winning message\n\t\t\t\tMain.showEndMessage(1, 0);\n\t\t\t} else {\n\n\t\t\t\t//show losing message with Mho in the context\n\t\t\t\tif (newMap[getNewPlayerLocation()[0]][getPlayerLocation()[1]] instanceof Mho) {\n\t\t\t\t\tMain.showEndMessage(-1, -1);\n\t\t\t\t} \n\n\t\t\t\t//show losing message with Fence in the context\n\t\t\t\telse {\n\t\t\t\t\tMain.showEndMessage(-1, 1);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "private void moveToNewLocation() {\r\n System.out.println(\"\\nThis is the move to a new location option\");\r\n }", "void run() {\n System.out.println(\"Enter a date (MM/DD/YY): \");\n Scanner scan = new Scanner(System.in);\n String date = scan.next();\n ArrayList<Order> orders = Screen.state.getOrdersByOrderDate(date);\n int index = 0;\n if (orders.size() != 0) {\n while (true) {\n System.out.print(orders.get(index).toString());\n System.out.println(\"Press n for Next, p for Previous\");\n scan = new Scanner(System.in);\n String key = scan.next();\n if (key.equalsIgnoreCase(\"n\")) {\n if (index == orders.size() - 1) {\n index = 0;\n } \n else {\n index++;\n }\n } \n else if (key.equalsIgnoreCase(\"p\")) {\n if (index == 0) {\n index = orders.size() - 1;\n } \n else {\n index--;\n }\n } \n else {\n break;\n }\n }\n } \n else {\n System.out.println(\"No such order\");\n System.out.println(\"Press any key to continue\");\n scan = new Scanner(System.in);\n scan.next();\n }\n this.prev.run();\n }", "public void interactWhenLeaving() {\r\n\t\t\r\n\t}", "@FXML\n public void completeCurrentInterview() {\n try {\n Interview selectedInterview = this.listInterview.getSelectionModel().getSelectedItem();\n selectedInterview.setCompleted(true);\n selectedInterview.getApplication().completeInterview();\n this.interviewClicked();\n\n AlertHelper.showInformationAlert(\"This interview has been completed.\");\n\n // Reset view\n this.populateListInterview(interviewer.getPendingInterviews());\n this.populateInterviewInfo(selectedInterview);\n } catch (Exception ex) {\n AlertHelper.showErrorAlert(\"Unable to complete interview: \" + ex.getLocalizedMessage());\n }\n }" ]
[ "0.6457005", "0.6150596", "0.6109988", "0.59967524", "0.590251", "0.5737371", "0.57312065", "0.5567844", "0.54395807", "0.5437038", "0.5424185", "0.5382206", "0.53782165", "0.53682554", "0.53256637", "0.5324046", "0.5316004", "0.52853477", "0.52850103", "0.52709657", "0.52694196", "0.5268983", "0.52686036", "0.52642363", "0.5263057", "0.5257687", "0.5256177", "0.5226303", "0.52223694", "0.5221432", "0.5211058", "0.518603", "0.518562", "0.51814806", "0.51779354", "0.51754427", "0.5166803", "0.5154623", "0.51431453", "0.51431453", "0.51370263", "0.51219773", "0.5114716", "0.5110881", "0.51096046", "0.51003194", "0.50731635", "0.507311", "0.50675666", "0.5067304", "0.5065405", "0.5054832", "0.5046055", "0.5045616", "0.5044776", "0.5043788", "0.5014195", "0.50123113", "0.50099695", "0.5003715", "0.49988544", "0.49960405", "0.49904513", "0.4989608", "0.4983698", "0.49721876", "0.49421418", "0.49368563", "0.49318838", "0.49296337", "0.49264455", "0.49128094", "0.4910581", "0.49105567", "0.4901342", "0.48909473", "0.48898128", "0.48861942", "0.48821428", "0.48714596", "0.4869436", "0.4864374", "0.48620704", "0.48581564", "0.4857773", "0.48569417", "0.48475906", "0.48410177", "0.48409426", "0.4835952", "0.4832639", "0.482691", "0.48240104", "0.481992", "0.48142081", "0.4808256", "0.48030055", "0.4801525", "0.48000187", "0.47950232" ]
0.8163677
0
carrega os medicamentos na tabela
@PostConstruct public void init(){ medicamentos = new ArrayList<Medicamento>(); if (getUsuario().getPermissao().contains("ROLE_PECUARISTA")) { medicamentos = medicamentoFacade.medicamentosUsuario(getUsuario()); }else { medicamentos = medicamentoFacade.medicamentosUsuario(systemSessionMB.getFazenda().getPecuarista()); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void cargarDatos() {\n \n if(drogasIncautadoList==null){\n return;\n }\n \n \n \n List<Droga> datos = drogasIncautadoList;\n\n Object[][] matriz = new Object[datos.size()][4];\n \n for (int i = 0; i < datos.size(); i++) {\n \n \n //System.out.println(s[0]);\n \n matriz[i][0] = datos.get(i).getTipoDroga();\n matriz[i][1] = datos.get(i).getKgDroga();\n matriz[i][2] = datos.get(i).getQuetesDroga();\n matriz[i][3] = datos.get(i).getDescripcion();\n \n }\n Object[][] data = matriz;\n String[] cabecera = {\"Tipo Droga\",\"KG\", \"Quetes\", \"Descripción\"};\n dtm = new DefaultTableModel(data, cabecera);\n tableDatos.setModel(dtm);\n }", "private void carregarTabela() {\n try {\n\n Vector<String> cabecalho = new Vector();\n cabecalho.add(\"Id\");\n cabecalho.add(\"Nome\");\n cabecalho.add(\"Telefone\");\n cabecalho.add(\"Titular\");\n cabecalho.add(\"Data de Nascimento\");\n\n Vector detalhe = new Vector();\n\n for (Dependente dependente : new NDependente().listar()) {\n Vector<String> linha = new Vector();\n\n linha.add(dependente.getId() + \"\");\n linha.add(dependente.getNome());\n linha.add(dependente.getTelefone());\n linha.add(new NCliente().consultar(dependente.getCliente_id()).getNome());\n linha.add(dependente.getDataNascimento().toString());\n detalhe.add(linha);\n\n }\n\n tblDependentes.setModel(new DefaultTableModel(detalhe, cabecalho));\n\n } catch (Exception e) {\n JOptionPane.showMessageDialog(this, e.getMessage());\n }\n\n }", "public void preencherTabela(){\n imagemEnunciado.setImage(imageDefault);\n pergunta.setImagemEnunciado(caminho);\n imagemResposta.setImage(imageDefault);\n pergunta.setImagemResposta(caminho);\n ///////////////////////////////\n perguntas = dao.read();\n if(perguntas != null){\n perguntasFormatadas = FXCollections.observableList(perguntas);\n\n tablePerguntas.setItems(perguntasFormatadas);\n }\n \n }", "public void carga_bd_empleados(){\n try {\n Connection conectar = Conexion.conectar();\n PreparedStatement pst = conectar.prepareStatement(\n \"select nombre, edad, cargo, direccion, telefono from empleados\");\n\n ResultSet rs = pst.executeQuery();\n\n table = new JTable(model);\n jScrollPane1.setViewportView(table);\n table.setBackground(Color.yellow);\n\n model.addColumn(\"Nombre\");\n model.addColumn(\"Edad\");\n model.addColumn(\"Cargo\");\n model.addColumn(\"Direccion\");\n model.addColumn(\"Telefono\");\n\n while (rs.next()) {\n Object[] fila = new Object[8];\n //material mimaterial = new material();\n\n for (int i = 0; i < 5; i++) {\n fila[i] = rs.getObject(i + 1);\n }\n\n// model.addRow(fila);\n Empleado mimaterial = this.ChangetoEmpleado(fila);\n this.AddToArrayTableEmpleado(mimaterial);\n\n }\n\n conectar.close();\n \n } catch (SQLException e) {\n System.err.println(\"Error al llenar tabla\" + e);\n JOptionPane.showMessageDialog(null, \"Error al mostrar informacion\");\n\n }\n }", "@FXML\n private void populaTabela(){\n ObservableList<Medico> medicos = observableArrayList(medicoDAO.read());\n medicoNome.setCellValueFactory(new PropertyValueFactory<>(\"nome\"));\n medicoCrm.setCellValueFactory(new PropertyValueFactory<>(\"crm\"));\n medicoEspecialidade.setCellValueFactory(new PropertyValueFactory<>(\"nomeEspecialidade\"));\n tabelaMedicos.setItems(FXCollections.observableArrayList(medicos));\n }", "public void llenadoDeTablas() {\n \n DefaultTableModel modelo1 = new DefaultTableModel();\n modelo1 = new DefaultTableModel();\n modelo1.addColumn(\"ID Usuario\");\n modelo1.addColumn(\"NOMBRE\");\n UsuarioDAO asignaciondao = new UsuarioDAO();\n List<Usuario> asignaciones = asignaciondao.select();\n TablaPerfiles.setModel(modelo1);\n String[] dato = new String[2];\n for (int i = 0; i < asignaciones.size(); i++) {\n dato[0] = (Integer.toString(asignaciones.get(i).getId_usuario()));\n dato[1] = asignaciones.get(i).getNombre_usuario();\n\n modelo1.addRow(dato);\n }\n }", "public void popular(){\n DAO dao = new DAO();\n modelo.setNumRows(0);\n\n for(Manuais m: dao.selecTudoManuaisVenda()){\n modelo.addRow(new Object[]{m.getId(),m.getNome(),m.getClasse(),m.getEditora(),m.getPreco()+\".00 MZN\"});\n \n }\n }", "private void cargarColumnasTabla(){\n \n modeloTabla.addColumn(\"Nombre\");\n modeloTabla.addColumn(\"Telefono\");\n modeloTabla.addColumn(\"Direccion\");\n }", "private void TampilData(){\n try{ //\n String sql = \"SELECT * FROM buku\"; // memanggil dari php dengan tabel buku\n stt = con.createStatement(); // membuat statement baru dengan mengkonekan ke database\n rss = stt.executeQuery(sql); \n while (rss.next()){ \n Object[] o = new Object [3]; // membuat array 3 dimensi dengan nama object\n \n o[0] = rss.getString(\"judul\"); // yang pertama dengan ketentuan judul\n o[1] = rss.getString(\"penulis\"); // yang kedua dengan ketentuan penulis\n o[2] = rss.getInt(\"harga\"); // yang ketiga dengan ketentuan harga\n model.addRow(o); // memasukkan baris dengan mengkonekan di tabel model\n } \n }catch(SQLException e){ // memanipulasi kesalahan\n System.out.println(\"ini error\"); // menampilkan pesan ini error\n }\n }", "private void carregarTabela() {\n try {\n\n Vector<String> cabecalho = new Vector();\n cabecalho.add(\"Id\");\n cabecalho.add(\"Nome\");\n cabecalho.add(\"CPF\");\n cabecalho.add(\"Telefone\");\n cabecalho.add(\"Endereço\");\n cabecalho.add(\"E-mail\");\n cabecalho.add(\"Data de Nascimento\");\n\n Vector detalhe = new Vector();\n\n for (Cliente cliente : new NCliente().listar()) {\n Vector<String> linha = new Vector();\n\n linha.add(cliente.getId() + \"\");\n linha.add(cliente.getNome());\n linha.add(cliente.getCpf());\n linha.add(cliente.getTelefone());\n linha.add(cliente.getEndereco());\n linha.add(cliente.getEmail());\n linha.add(cliente.getData_nascimento().toString());\n detalhe.add(linha);\n\n }\n\n tblClientes.setModel(new DefaultTableModel(detalhe, cabecalho));\n\n } catch (Exception e) {\n JOptionPane.showMessageDialog(this, e.getMessage());\n }\n\n }", "private void preencherTabela() {\n\t\tList<Cidade> listCidade;\n\t\tCidadeDAO cidadeDAO;\n\t\tObservableList<Cidade> oListCidade;\n\n\t\t// Determina os atributos que irão preencher as colunas\n\t\tcolCidade.setCellValueFactory(new PropertyValueFactory<>(\"nomeCidades\"));\n\t\tcolEstado.setCellValueFactory(new PropertyValueFactory<>(\"nomeEstado\"));\n\t\tcolSigla.setCellValueFactory(new PropertyValueFactory<>(\"siglaEstado\"));\n\t\tcolCodigoCidade.setCellValueFactory(new PropertyValueFactory<>(\"idCidade\"));\n\t\tcolIdEstado.setCellValueFactory(new PropertyValueFactory<>(\"idEstado\"));\n\n\t\t// Instancia a lista de cidades e a DAO\n\t\tlistCidade = new ArrayList<Cidade>();\n\t\tcidadeDAO = new CidadeDAO();\n\n\t\t// Chama o metodo para selecionar todas as cidades e atribuir a lista\n\t\tlistCidade = cidadeDAO.selecionar();\n\n\t\t// Converte a lista de cidades em observablearray\n\t\toListCidade = FXCollections.observableArrayList(listCidade);\n\n\t\t// Adiciona a lista na tabela\n\t\ttblCidades.setItems(oListCidade);\n\t}", "private void cargarTabla() {\n\t\tObject[] fila = new Object[7];\r\n\t\tfila[1] = txtCedula.getText();\r\n\t\tfila[2] = txtFuncionario.getText();\r\n\t\tfila[3] = util.getDateToString(dcDesde.getDate());\r\n\t\tif (cbTipo.getSelectedIndex() == 1 || cbTipo.getSelectedIndex() == 2) {\r\n\t\t\tfila[4] = util.getDateToString(dcDesde.getDate());\r\n\t\t} else {\r\n\t\t\tfila[4] = util.getDateToString(dcHasta.getDate());\r\n\t\t}\r\n\t\tfila[5] = cbTipo.getSelectedItem();\r\n\t\tfila[6] = txtMotivo.getText().toUpperCase();\r\n\t\tthis.modelo.addRow(fila);\r\n\t\ttbJustificaciones.setModel(this.modelo);\r\n\t}", "public void popularTabela() {\n\n try {\n\n RelatorioRN relatorioRN = new RelatorioRN();\n\n ArrayList<PedidoVO> pedidos = relatorioRN.buscarPedidos();\n\n javax.swing.table.DefaultTableModel dtm = (javax.swing.table.DefaultTableModel) tRelatorio.getModel();\n dtm.fireTableDataChanged();\n dtm.setRowCount(0);\n\n for (PedidoVO pedidoVO : pedidos) {\n\n String[] linha = {\"\" + pedidoVO.getIdpedido(), \"\" + pedidoVO.getData(), \"\" + pedidoVO.getCliente(), \"\" + pedidoVO.getValor()};\n dtm.addRow(linha);\n }\n\n } catch (SQLException sqle) {\n\n JOptionPane.showMessageDialog(null, \"Erro: \" + sqle.getMessage(), \"Bordas\", JOptionPane.ERROR_MESSAGE);\n \n } catch (Exception e) {\n\n JOptionPane.showMessageDialog(null, \"Erro: \" + e.getMessage(), \"Bordas\", JOptionPane.ERROR_MESSAGE);\n }\n }", "private DefaultTableModel getDatos3(){\n String folio = String.valueOf(venta.ns);\n //consulta sql\n String SQL_SELECT = \"SELECT p.Nombres,dv.Cantidad,dv.PrecioVenta FROM ventas v JOIN detalle_ventas dv ON v.IdVentas=dv.IdVentas JOIN producto p ON p.IdProducto=dv.IdProducto WHERE v.NumeroSerie = \"+folio+\"\";\n try {\n setTitutlos3();\n ps = con.getConnection().prepareStatement(SQL_SELECT);\n RS = ps.executeQuery();\n Object[] fila = new Object[3];\n while (RS.next()){\n fila[0] = RS.getString(1);\n fila[1] = RS.getInt(2);\n fila[2] = RS.getDouble(3);\n DT.addRow(fila);\n }\n //System.out.println(\"si hizo el desmadre\");\n } catch (SQLException e) {\n System.out.println(\"error en la tabla de ticket\");\n }\n \n return DT;\n \n }", "private ArrayList<FornecedorModelo> iniciaTabela() {\n int i;\n DefaultTableModel model=(DefaultTableModel)tblFornecedor.getModel();\n // atribui 0 linhas à coluna\n model.setNumRows(0);\n // atribui um tamanho fixo a coluna codigo\n tblFornecedor.getColumnModel().getColumn(0).setPreferredWidth(2);\n ArrayList<FornecedorModelo> listaFornecedores = new ArrayList<FornecedorModelo>();\n listaFornecedores = new FornecedorControle().listarFornecedor();\n //adiciona alunos as tabelas\n for (i=0;i<=listaFornecedores.size()-1;i++){\n model.addRow(\n new Object[]{\n listaFornecedores.get(i).getCodFornecedor(),\n listaFornecedores.get(i).getNomeFantasia(),\n listaFornecedores.get(i).getRazaoSocial(),\n listaFornecedores.get(i).getEndereco(),\n listaFornecedores.get(i).getEmail(),\n listaFornecedores.get(i).getTelefone(),\n listaFornecedores.get(i).getCnpj(),\n Boolean.FALSE\n }\n );\n }\n return listaFornecedores;\n }", "private void cargar(List<Personas> listaP) {\n int total= listaP.size();\n Object [][] tab = new Object [total][10];\n int i=0;\n Iterator iter = listaP.iterator();\n while (iter.hasNext()){\n Object objeto = iter.next();\n Personas pro = (Personas) objeto;\n\n tab[i][0]=pro.getLocalidadesid().getProvinciasId();\n tab[i][1]=pro.getLocalidadesid();\n tab[i][2]=pro.getCuilcuit();\n tab[i][3]=pro.getApellido();\n tab[i][4]=pro.getNombres();\n tab[i][5]=pro.getCalle();\n tab[i][6]=pro.getAltura();\n tab[i][7]=pro.getPiso();\n tab[i][8]=pro.getEmail();\n// if(pro.getEmpleados().equals(\"\")){\n tab[i][9]=\"Cliente\";\n // }else{\n // tab[i][7]=\"Empleado\";\n // }\n i++;\n }\njTable1 = new javax.swing.JTable();\n\njTable1.setModel(new javax.swing.table.DefaultTableModel(\ntab,\nnew String [] {\n \"Provincia\", \"Localidad\", \"DNI/Cuit\", \"Apellido\", \"Nombres\", \"Calle\", \"Altura\", \"Piso\", \"Email\", \"Tipo\"\n}\n));\n jScrollPane1.setViewportView(jTable1);\n }", "public void calendario4Dias(JTable tabla,String categoria, String f1,String f2,String f3,String f4)\n {String [] columna ={\"Cedula\",\"Nombres\",f1,f2,f3,f4};\n String [] pesos=new String [4];\n String [] fechas=new String [4];\n fechas[0]=f1;\n fechas[1]=f2;\n fechas[2]=f3;\n fechas[3]=f4;\n \n int filas;\n DefaultTableModel encabezado=new DefaultTableModel (null,columna);\n \n tabla.setModel(encabezado);\n String[] entrenadorDtos2 = new String[3];\n String sql = \"select * from federado \";\n PreparedStatement sentencia_sql = null;\n ResultSet rs = null;\n try {sentencia_sql = miConexion.prepareStatement(sql);\n rs = sentencia_sql.executeQuery(sql);\n while (rs.next()) {\n entrenadorDtos2[0]= rs.getString(\"idfederado\");\n entrenadorDtos2[1]= rs.getString(\"nombres\")+\"\"+rs.getString(\"apellidos\");\n encabezado.addRow(entrenadorDtos2);}\n rs.close();}\n catch (Exception e) {\n JOptionPane.showMessageDialog(null, \"Error en obtener los datos \" + e.getMessage());}\n \n /// llenar con peso\n filas=encabezado.getRowCount();\n String cedula,peso;\n for (int i = 0; i < filas; i++) {\n cedula=String.valueOf(encabezado.getValueAt(i, 0));\n for (int j = 0; j <= 3; j++) {\n sql = \"SELECT cargas.peso, cargas.serie \"+\n \"from federado, cargas, entrenamiento\" +\n \" where federado.idfederado=cargas.identrena and entrenamiento.idEntreno=cargas.idfede and cargas.fecha='\"+fechas[j]+\"' and federado.idfederado='\"+cedula+\"' and entrenamiento.tipo='\"+categoria+\"'\";\n \n PreparedStatement sentencia_sql2 = null;\n ResultSet rs2 = null;\n try {sentencia_sql2 = miConexion.prepareStatement(sql);\n rs2 = sentencia_sql2.executeQuery(sql);\n while (rs2.next()) {\n peso= rs2.getString(\"peso\")+\" \"+rs2.getString(\"serie\");\n encabezado.setValueAt(peso, i, j+2);\n }\n rs2.close();}\n catch (Exception e) {\n JOptionPane.showMessageDialog(null, \"Error en obtener los datos \" + e.getMessage());} \n } \n }}", "public void tabla_campos() {\n int rec = AgendarA.tblAgricultor.getSelectedRow();// devuelve un entero con la posicion de la seleccion en la tabla\n ccAgricultor = AgendarA.tblAgricultor.getValueAt(rec, 1).toString();\n crearModeloAgenda();\n }", "private void preencherTabela(List<br.cefet.renatathiago.trabalhoBim2.Entidade.Produto> lista) {\n if (lista != null){\n String[] vetor = new String[6];\n vetor [0]= \"Cod\";\n vetor [1]= \"Nome\";\n vetor [2]= \"Marca\";\n vetor [3] = \"Preço Compra\";\n vetor [4] = \"Preço Venda\";\n vetor [5] = \"Qtd em Estoque\";\n String [][] matriz = new String[lista.size()][6];\n \n for (int i = 0; i<lista.size(); i++){\n matriz [i][0]=lista.get(i).getCod()+\"\";\n matriz [i][1]=lista.get(i).getNome();\n matriz [i][2]=lista.get(i).getMarca();\n matriz [i][3]=lista.get(i).getPrecoCompra()+\"\";\n matriz [i][4]=lista.get(i).getPrecoVenda()+\"\";\n matriz [i][5]=lista.get(i).getQtdEstoque()+\"\";\n }\n \n jTable1.setModel(new javax.swing.table.DefaultTableModel(\n matriz, vetor));\n }\n }", "public void crearModelo() {\n modeloagr = new DefaultTableModel(null, columnasAgr) {\n public boolean isCellEditable(int fila, int columna) {\n return false;\n }\n };\n tbl.llenarTabla(AgendarA.tblAgricultor, modeloagr, columnasAgr.length, \"SELECT idPersonalExterno,cedula,CONCAT(nombres,' ',apellidos),municipios.nombre,telefono,telefono2,telefono3 FROM personalexterno,municipios WHERE tipo='agricultor' AND personalexterno.idMunicipio=municipios.idMunicipio\");\n tbl.alinearHeaderTable(AgendarA.tblAgricultor, headerColumnas);\n tbl.alinearCamposTable(AgendarA.tblAgricultor, camposColumnas);\n tbl.rowNumberTabel(AgendarA.tblAgricultor);\n }", "private void createTable(){\n Object[][] data = new Object[0][8];\n int i = 0;\n for (Grupo grupo : etapa.getGrupos()) {\n Object[][] dataAux = new Object[data.length+1][8];\n System.arraycopy(data, 0, dataAux, 0, data.length);\n dataAux[i++] = new Object[]{grupo.getNum(),grupo.getAtletas().size(),\"Registar Valores\",\"Selecionar Vencedores\", \"Selecionar Atletas\"};\n data = dataAux.clone();\n }\n\n //COLUMN HEADERS\n String columnHeaders[]={\"Numero do Grupo\",\"Número de Atletas\",\"\",\"\",\"\"};\n\n tableEventos.setModel(new DefaultTableModel(\n data,columnHeaders\n ));\n //SET CUSTOM RENDERER TO TEAMS COLUMN\n tableEventos.getColumnModel().getColumn(2).setCellRenderer(new ButtonRenderer());\n tableEventos.getColumnModel().getColumn(3).setCellRenderer(new ButtonRenderer());\n tableEventos.getColumnModel().getColumn(4).setCellRenderer(new ButtonRenderer());\n\n //SET CUSTOM EDITOR TO TEAMS COLUMN\n tableEventos.getColumnModel().getColumn(2).setCellEditor(new ButtonEditor(new JTextField(), this.etapa));\n tableEventos.getColumnModel().getColumn(3).setCellEditor(new ButtonEditor(new JTextField(), this.etapa));\n tableEventos.getColumnModel().getColumn(4).setCellEditor(new ButtonEditor(new JTextField(), this.etapa));\n\n }", "Tablero consultarTablero();", "public void createTable() {\n try {\n tableLayout = findViewById(R.id.tabla);\n tb = new TableDinamic(tableLayout, getApplicationContext(), \"cargarDetalle\", clc, cap_1, cap_2, cap_ct, txtidReg, txtId, txtBloque, txtVariedad);\n tableLayout.removeAllViews();\n tb.addHeader(header);\n tb.addData(cargarTabla());\n tb.backgroundHeader(\n Color.parseColor(\"#20C0FF\")\n );\n tb.backgroundData(\n Color.parseColor(\"#FFFFFF\"),\n Color.parseColor(\"#81F0EDED\")\n );\n } catch (Exception e) {\n Toast.makeText(this, \"Error de la table: \" + e.toString(), Toast.LENGTH_LONG).show();\n }\n }", "private void cargardatos() {\n String sql = \"SELECT * FROM nomPercepciones\";\n\n Object datos[] = new Object[13];\n try {\n conn = (this.userConn != null) ? this.userConn : Conexion.getConnection();\n stmt = conn.prepareStatement(sql);\n rs = stmt.executeQuery();\n while (rs.next()) {\n datos[0] = rs.getString(\"idNomPer\");\n datos[1] = rs.getString(\"nombre\");\n datos[2] = rs.getString(\"dias\");\n if (rs.getString(\"estatus\").equalsIgnoreCase(\"1\")) {\n datos[3] = new JLabel(new ImageIcon(getClass().getResource(\"/View/img/actulizadoj.png\")));\n } else {\n datos[3] = new JLabel(new ImageIcon(getClass().getResource(\"/View/img/noactualizadoj.png\")));\n }\n\n tabla1.addRow(datos);\n }\n } catch (SQLException e) {\n JOptionPane.showMessageDialog(null, \"Error al cargar los datos\\n\" + e, \"ERROR\", JOptionPane.ERROR_MESSAGE);\n } finally {\n Conexion.close(rs);\n Conexion.close(stmt);\n if (this.userConn == null) {\n Conexion.close(conn);\n }\n }\n }", "public void llenarTabla() {\n\n String matriz[][] = new String[lPComunes.size()][2];\n\n for (int i = 0; i < AccesoFichero.lPComunes.size(); i++) {\n matriz[i][0] = AccesoFichero.lPComunes.get(i).getPalabra();\n matriz[i][1] = AccesoFichero.lPComunes.get(i).getCodigo();\n\n }\n\n jTableComun.setModel(new javax.swing.table.DefaultTableModel(\n matriz,\n new String[]{\n \"Palabra\", \"Morse\"\n }\n ) {// Bloquea que las columnas se puedan editar, haciendo doble click en ellas\n @SuppressWarnings(\"rawtypes\")\n Class[] columnTypes = new Class[]{\n String.class, String.class\n };\n\n @SuppressWarnings({\"unchecked\", \"rawtypes\"})\n @Override\n public Class getColumnClass(int columnIndex) {\n return columnTypes[columnIndex];\n }\n boolean[] columnEditables = new boolean[]{\n false, false\n };\n\n @Override\n public boolean isCellEditable(int row, int column) {\n return columnEditables[column];\n }\n });\n\n }", "private void popularTabela() {\n\n if (CadastroCliente.listaAluno.isEmpty()) {\n DefaultTableModel modelo = (DefaultTableModel) jTable1.getModel();\n modelo.setNumRows(0);\n }\n int t = 0;\n DefaultTableModel modelo = (DefaultTableModel) jTable1.getModel();\n modelo.setNumRows(0);\n int aux = CadastroCliente.listaAluno.size();\n\n while (t < aux) {\n aluno = CadastroCliente.listaAluno.get(t);\n modelo.addRow(new Object[]{aluno.getMatricula(), aluno.getNome(), aluno.getCpf(), aluno.getTel()});\n t++;\n }\n }", "public void tabelaktivitas() {\n DefaultTableModel tbl= new DefaultTableModel();\n tbl.addColumn(\"Group\");\n tbl.addColumn(\"Compart\");\n tbl.addColumn(\"Activity\");\n tbl.addColumn(\"HA\");\n tbl.addColumn(\"Harga\");\n tbl.addColumn(\"Total\");\n tblaktivitas.setModel(tbl);\n try{\n java.sql.Statement statement=(java.sql.Statement)conek.GetConnection().createStatement();\n ResultSet res=statement.executeQuery(\"select * from tblaktivitas\");\n while(res.next())\n {\n tbl.addRow(new Object[]{\n res.getString(\"nama_grup\"),\n res.getString(\"compart\"),\n res.getString(\"pekerjaan\"),\n res.getInt(\"ha\"),\n res.getInt(\"harga\"),\n res.getInt(\"total\")\n });\n tblaktivitas.setModel(tbl); \n }\n }catch (Exception e){\n JOptionPane.showMessageDialog(rootPane,\"Salah\");\n }\n }", "private String[][] getMoodsTableValues() {\n String soso = DBTypesKeys.SO_SO_MOOD.getTypeValue();\n String sad = DBTypesKeys.SAD_MOOD.getTypeValue();\n String angry = DBTypesKeys.ANGRY_MOOD.getTypeValue();\n String happy = DBTypesKeys.HAPPY_MOOD.getTypeValue();\n // moods table\n return new String[][]{\n //moods hi answers by answers // id_ (enum index + 1)\n { soso, \"hey\", \"by\"}, // 1\n { sad, \"welcome to sad world\", \"so, you too ...\"}, // 2\n { angry, \"get out!\", \"thanks god, you away\"}, // 3\n { happy, \"hi! glad to see you =)\", \"good luck, buddy\"} // 4\n };\n }", "public void llenadoDeTablas() {\n DefaultTableModel modelo = new DefaultTableModel();\n modelo.addColumn(\"ID Articulo\");\n modelo.addColumn(\"Fecha Ingreso\");\n modelo.addColumn(\"Nombre Articulo\");\n modelo.addColumn(\"Talla XS\");\n modelo.addColumn(\"Talla S\");\n modelo.addColumn(\"Talla M\");\n modelo.addColumn(\"Talla L\");\n modelo.addColumn(\"Talla XL\");\n modelo.addColumn(\"Color Articulo\");\n modelo.addColumn(\"Nombre Proveedor\");\n modelo.addColumn(\"Existencias\");\n\n RegistroArticuloDAO registroarcticuloDAO = new RegistroArticuloDAO();\n\n List<RegistroArticulo> registroarticulos = registroarcticuloDAO.select();\n TablaArticulo.setModel(modelo);\n String[] dato = new String[11];\n for (int i = 0; i < registroarticulos.size(); i++) {\n dato[0] = Integer.toString(registroarticulos.get(i).getPK_id_articulo());\n dato[1] = registroarticulos.get(i).getFecha_ingreso();\n dato[2] = registroarticulos.get(i).getNombre_articulo();\n dato[3] = registroarticulos.get(i).getTalla_articuloXS();\n dato[4] = registroarticulos.get(i).getTalla_articuloS();\n dato[5] = registroarticulos.get(i).getTalla_articuloM();\n dato[6] = registroarticulos.get(i).getTalla_articuloL();\n dato[7] = registroarticulos.get(i).getTalla_articuloXL();\n dato[8] = registroarticulos.get(i).getColor_articulo();\n dato[9] = registroarticulos.get(i).getNombre_proveedor();\n dato[10] = registroarticulos.get(i).getExistencia_articulo();\n\n //System.out.println(\"vendedor:\" + vendedores);\n modelo.addRow(dato);\n }\n }", "public List<Medico> getAllMedicos() {\n List<Medico> medicos = new ArrayList<Medico>();\n try {\n PreparedStatement pstm = null;\n ResultSet rs = null;\n String query = \"SELECT *FROM medico\";\n pstm = con.prepareStatement(query);\n rs = pstm.executeQuery();\n while (rs.next()) {\n Medico medico = new Medico();\n medico.setId(rs.getInt(\"id_medico\"));\n medico.setArea(rs.getString(\"area\"));\n medico.setNombre(rs.getString(\"nombre\"));\n medico.setAp_pat(rs.getString(\"apell_pat\"));\n medico.setAp_mat(rs.getString(\"apell_mat\"));\n medico.setDireccion(rs.getString(\"direccion\"));\n medico.setEmail(rs.getString(\"email\"));\n medico.setTel(rs.getString(\"tel\"));\n medico.setHora_inc(rs.getString(\"hora_inic\"));\n medico.setHora_fin(rs.getString(\"hora_fin\"));\n medicos.add(medico);\n }\n\n } catch (SQLException e) {\n e.printStackTrace();\n }\n return medicos;\n }", "public DefaultTableModel buscarlotes() {\n \n String encabezados[]= {\"Nombre\",\"Codigo\",\"Lote\",\"Vencimiento\",\"Dias Restantes\"};\n Control.ControlLote c = new Control.ControlLote();\n List<Modelo.Lotes> lotes = null;\n \n try {\n lotes = c.buscarlote();\n \n } catch (ClassNotFoundException ex) {\n Logger.getLogger(AgregarStock.class.getName()).log(Level.SEVERE, null, ex);\n }\n \n Long resta;//para saber cuanto queda de vencimiento\n java.util.Date fechaActual = new Date(); \n \n String [][] data = new String[lotes.size()][5];\n for (int i = 0; i < lotes.size(); i++) {\n \n resta=lotes.get(i).getVencimiento().getTime()-fechaActual.getTime();\n long dias = (resta / (1000 * 60 * 60 * 24))+1;\n \n \n data[i][0] = lotes.get(i).getNombre();\n data[i][1] = Long.toString(lotes.get(i).getCodigo());\n data[i][2] = lotes.get(i).getLote();\n data[i][3] = lotes.get(i).getVencimiento().toString();\n if(dias<1)\n data[i][4] = (\"Vencido\");\n else{\n data[i][4] = Long.toString(dias);\n }\n\n }\n\n jTable1.setDefaultRenderer (Object.class, new MiRender());\n \n return new DefaultTableModel(data,encabezados);\n }", "private void populaUnidadeMedida()\n {\n UnidadeMedida u = new UnidadeMedida(\"Gramas\", \"g\");\n unidadeMedidaDAO.insert(u);\n u = new UnidadeMedida(\"Quilo\", \"kg\");\n unidadeMedidaDAO.insert(u);\n u = new UnidadeMedida(\"Quilo\", \"kg\");\n unidadeMedidaDAO.insert(u);\n u = new UnidadeMedida(\"Unidade\", \"unidade\");\n unidadeMedidaDAO.insert(u);\n u = new UnidadeMedida(\"Colher de Sopa\", \"col. sopa\");\n unidadeMedidaDAO.insert(u);\n u = new UnidadeMedida(\"Colher de Sobremesa\", \"col. sobremesa\");\n unidadeMedidaDAO.insert(u);\n u = new UnidadeMedida(\"Colher de Chá\", \"col. chá\");\n unidadeMedidaDAO.insert(u);\n u = new UnidadeMedida(\"Copo\", \"copo\");\n unidadeMedidaDAO.insert(u);\n\n }", "private void Actualizar_Tabla() {\n String[] columNames = {\"iditem\", \"codigo\", \"descripcion\", \"p_vent\", \"p_comp\", \"cant\", \"fecha\"};\n dtPersona = db.Select_Item();\n // se colocan los datos en la tabla\n DefaultTableModel datos = new DefaultTableModel(dtPersona, columNames);\n jTable1.setModel(datos);\n }", "public void setValuesJTableResultados(){\n int alternativas = views.useController().getProblema().getAlternativas();\n TableModelPersonalizado modelo = new TableModelPersonalizado(alternativas, 1);\n jTableVectorResultados.setModel(modelo);\n jTableVectorResultados.setEnabled(false);\n jTableVectorResultados.getTableHeader().setResizingAllowed(false);\n jTableVectorResultados.getTableHeader().setReorderingAllowed(false);\n //HEADERS DE LA TABLA\n jTableVectorResultados.getColumnModel().getColumn(0).setHeaderValue(\" \"); \n //CONTENIDO DE LA TABLA\n for(int f = 0; f < alternativas; f++){\n modelo.setValueAt(df.format(views.useController().getProblema().getResult().getPriorityVector().get(f, 0)), f, 0);\n } \n }", "protected void exibirMedicos(){\n System.out.println(\"--- MEDICOS CADASTRADOS ----\");\r\n String comando = \"select * from medico order by id\";\r\n ResultSet rs = cb.buscaDados(comando);\r\n try{\r\n while(rs.next()){\r\n int id = rs.getInt(\"id\");\r\n String nome = rs.getString(\"nome\");\r\n System.out.println(\"[\"+id+\"] \"+nome);\r\n }\r\n }\r\n catch (Exception e){\r\n e.printStackTrace();\r\n }\r\n }", "public DefaultTableModel getTablaFutbolistas() {\n DefaultTableModel tablemodel = new DefaultTableModel();\n\n int registros = 0;\n String[] columNames = {\"Id\", \"NIF\", \"Nombre\", \"Apellidos\", \"Fecha nac.\", \"Nacionalidad\"};\n //obtenemos la cantidad de registros existentes en la tabla y se almacena en la variable \"registros\"\n //para formar la matriz de datos\n try {\n PreparedStatement pstm = this.getConnection().prepareStatement(\"SELECT count(*) as total FROM Futbolistas\");\n ResultSet res = pstm.executeQuery();\n res.next();\n registros = res.getInt(\"total\");\n close(res);\n } catch (SQLException e) {\n System.err.println(e.getMessage());\n }\n //se crea una matriz con tantas filas y columnas que necesite\n Object[][] data = new String[registros][7];\n try {\n //realizamos la consulta sql y llenamos los datos en la matriz \"Object[][] data\"\n PreparedStatement pstm = this.getConnection().prepareStatement(\"SELECT * FROM Futbolistas\");\n ResultSet res = pstm.executeQuery();\n int i = 0;\n while (res.next()) {\n data[i][0] = res.getString(\"id_futbolista\");\n data[i][1] = res.getString(\"nif\");\n data[i][2] = res.getString(\"nombre\");\n data[i][3] = res.getString(\"apellidos\");\n data[i][4] = res.getString(\"fecha_nacimiento\");\n data[i][5] = res.getString(\"nacionalidad\");\n i++;\n }\n close(res);\n //se añade la matriz de datos en el DefaultTableModel\n tablemodel.setDataVector(data, columNames);\n } catch (SQLException e) {\n System.err.println(e.getMessage());\n }\n return tablemodel;\n }", "public void fill_table()\n {\n Secante secante = new Secante(GraficaSecanteController.a, GraficaSecanteController.b, GraficaSecanteController.ep, FuncionController.e);\n list = secante.algoritmo();\n }", "private void cargarRegistroMedicamentos() {\r\n\t\tMap<String, Object> parametros = new HashMap<String, Object>();\r\n\t\tparametros.put(\"admision_seleccionada\", admision_seleccionada);\r\n\t\tparametros.put(\"rol_medico\", \"S\");\r\n\t\ttabboxContendor.abrirPaginaTabDemanda(false,\r\n\t\t\t\t\"/pages/registro_medicamentos.zul\", \"REGISTRO DE MEDICAMENTOS\",\r\n\t\t\t\tparametros);\r\n\t}", "private void establecerTablaPlatillos() {\n Object[] columnas = {\"Platillo\", \"Cantidad\", \"Costo\"};\n Object[][] modelo = new Object[platillosAVender.size()][3];\n int x = 0;\n\n for (VentaPlatillo ventaPlatillo : platillosAVender) {\n\n modelo[x][0] = ventaPlatillo.getPlatillo().getNombre();\n modelo[x][1] = ventaPlatillo.getCantidad();\n modelo[x][2] = ventaPlatillo.getCosto();\n x++;\n }\n // Se establece el modelo en la tabla con los datos\n tablaPlatillosAVender.setDefaultEditor(Object.class, null);\n tablaPlatillosAVender.setModel(new DefaultTableModel(modelo, columnas));\n tablaPlatillosAVender.setCellSelectionEnabled(false);\n tablaPlatillosAVender.setRowSelectionAllowed(false);\n txtTotal.setText(total + \"\");\n }", "public ArrayList<Vector<Object>> recuperaTablaFacturas(String filtro) {\r\n\t\tArrayList<Vector<Object>> tableData = null;\r\n\t\tArrayList<Factura> lista = recuperaFacturaParaTabla(filtro);\r\n\t\ttableData = new ArrayList<>();\r\n\t\tfor (Factura factura : lista) {\r\n\t\t\tVector<Object> filaData = new Vector<>();\r\n\t\t\tfilaData.add(factura);\r\n\t\t\tfilaData.add(factura.getFecha());\r\n\t\t\tfilaData.add(factura.getCliente().toString());\r\n\t\t\tfilaData.add(factura.getImpTotal());\r\n\t\t\tfilaData.add(factura.isCobrada());\r\n\t\t\ttableData.add(filaData);\r\n\t\t}\r\n\t\treturn tableData;\r\n\t}", "public void parseData(ResultSet rs) throws SQLException{\n\n\t\t\n\t\tResultSetMetaData metaDatos = rs.getMetaData();\n\t\t\n\t\t// Se obtiene el número de columnas.\n\t\tint numeroColumnas = metaDatos.getColumnCount();\n\n\t\t/*// Se crea un array de etiquetas para rellenar\n\t\tObject[] etiquetas = new Object[numeroColumnas];\n\n\t\t// Se obtiene cada una de las etiquetas para cada columna\n\t\tfor (int i = 0; i < numeroColumnas; i++)\n\t\t{\n\t\t // Nuevamente, para ResultSetMetaData la primera columna es la 1.\n\t\t etiquetas[i] = metaDatos.getColumnLabel(i + 1);\n\t\t}\n\t\tmodelo.setColumnIdentifiers(etiquetas);*/\n\t\t\t\t\n\t\ttry {\n\t\t\tthis.doc = SqlXml.toDocument(rs);\t\n\t\t\t//SqlXml.toFile(doc);\n\t\t\t\n\t\t\tmetaDatos = rs.getMetaData();\n\t\n\t\t\t\n\t\t\twhile (rs.next())\n\t\t\t{\n\t\t\t // Se crea un array que será una de las filas de la tabla.\n\t\t\t Object [] fila = new Object[numeroColumnas]; // Hay tres columnas en la tabla\n\n\t\t\t // Se rellena cada posición del array con una de las columnas de la tabla en base de datos.\n\t\t\t for (int i=0;i<numeroColumnas;i++){\n\t\t\t fila[i] = rs.getObject(i+1); // El primer indice en rs es el 1, no el cero, por eso se suma 1.\n\t\t\t \n\t\t\t if(i==2){\n\t\t\t \t \n\t\t\t \t NumberFormat formatter = new DecimalFormat(\"#0.0000\"); \n\t\t\t \t fila[i] = formatter.format(fila[i]);\n\t\t\t \t \n\t\t\t }\n\t\t\t \n\t\t\t modelo.isCellEditable(rs.getRow(), i+1);\n\t\t\t \n\t\t\t }\n\t\t\t // Se añade al modelo la fila completa.\n\t\t\t modelo.addRow(fila);\n\t\t\t}\n\t\t\t\n\t\t\ttabla.setModel(modelo);\n\n\t\t\t\n\t\t} catch (ParserConfigurationException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t\t\t\t\n\t}", "public DefaultTableModel getTablaFutbolistasPersonalizada(String nombre) {\n DefaultTableModel tablemodel = new DefaultTableModel();\n int registros = 0;\n String[] columNames = {\"Id\", \"NIF\", \"Nombre\", \"Apellidos\", \"Fecha nac.\", \"Nacionalidad\", \"Temporada\"};\n //obtenemos la cantidad de registros existentes en la tabla y se almacena en la variable \"registros\"\n //para formar la matriz de datos\n try {\n PreparedStatement pstm = this.getConnection().prepareStatement(\"SELECT count(*) as total FROM Futbolistas\");\n ResultSet res = pstm.executeQuery();\n res.next();\n registros = res.getInt(\"total\");\n close(res);\n } catch (SQLException e) {\n System.err.println(e.getMessage());\n }\n //se crea una matriz con tantas filas y columnas que necesite\n Object[][] data = new String[registros][8];\n try {\n //realizamos la llamada al procedimiento de la bd y llenamos los datos en la matriz \"Object[][] data\"\n PreparedStatement pstm = this.getConnection().prepareStatement(\"{call buscarJugadores(?)}\");\n pstm.setString(1, nombre);\n ResultSet res = pstm.executeQuery();\n int i = 0;\n while (res.next()) {\n data[i][0] = res.getString(\"id_futbolista\");\n data[i][1] = res.getString(\"nif\");\n data[i][2] = res.getString(\"nombre\");\n data[i][3] = res.getString(\"apellidos\");\n data[i][4] = res.getString(\"fecha_nacimiento\");\n data[i][5] = res.getString(\"nacionalidad\");\n data[i][6] = res.getString(\"temporada\");\n i++;\n }\n close(res);\n //se añade la matriz de datos en el DefaultTableModel\n tablemodel.setDataVector(data, columNames);\n } catch (SQLException e) {\n System.err.println(e.getMessage());\n }\n return tablemodel;\n }", "private void inicializarTablero() {\r\n\t\t\r\n\t\tfor(int i = 0; i < filas; i++) {\r\n\t\t\tfor(int j = 0; j < columnas; j++) {\r\n\t\t\t\tsuperficie[i][j] = null;\r\n\t\t\t}\r\n\t\t}\r\n\t}", "void LlenarModelo(){\n datos.addColumn(\"ID\");\n datos.addColumn(\"Descripcion\");\n datos.addColumn(\"Cantidad\");\n String []ingresar=new String[4];\n try {\n Connection con = Conexion.getConection();\n Statement estado = con.createStatement();\n //ResultSet resultado = estado.executeQuery(\"SELECT * FROM pago where codigo>=\" + SIGEPSA.IDOtrosPagosMin + \";\");\n //ResultSet resultado = estado.executeQuery(\"SELECT * FROM pago ;\");\n ResultSet resultado = estado.executeQuery(\"SELECT * FROM pago where codigo<9 or codigo>10 and activo = 1;\");\n while(resultado.next()){\n ingresar[0]=String.valueOf((String)resultado.getObject(\"CODIGO\").toString());\n ingresar[1]=String.valueOf((String)resultado.getObject(\"DESCRIPCION\").toString());\n ingresar[2]=String.valueOf((String)resultado.getObject(\"CANTIDAD\").toString());\n datos.addRow(ingresar);\n }\n }catch (Exception ex) {\n \n }\n }", "private JTable getTablePacientes() {\n\t\t\n\t\t try {\n\t \t ConnectDatabase db = new ConnectDatabase();\n\t\t\t\tResultSet rs = db.sqlstatment().executeQuery(\"SELECT * FROM PACIENTE WHERE NOMBRE LIKE '%\"+nombre.getText()+\"%' AND APELLIDO LIKE '%\"+apellido.getText()+\"%'AND DNI LIKE '%\"+dni.getText()+\"%'\");\n\t\t\t\tObject[] transf = QueryToTable.getSingle().queryToTable(rs);\n\t\t\t\treturn table = new JTable(new DefaultTableModel((Vector<Vector<Object>>)transf[0], (Vector<String>)transf[1]));\t\t\n\t\t\t} catch(Exception e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t\treturn table;\n\t}", "private static void setTableWithData()\n {\n /* Se establecen el tamaño de la tabla */\n table.setSize(1280, 630);\n table.setMaximumSize(new Dimension(1280, 630));\n table.setMinimumSize(new Dimension(1280, 630));\n\n /* Se garantiza que cada fila (album) tiene un alto proporcional de acuerdo con el numero de cancioens */\n Iterator iteratorPerRow = listSizePerRow.iterator();\n int sizePerRow, i;\n i = 0;\n while (iteratorPerRow.hasNext())\n {\n sizePerRow = (Integer) iteratorPerRow.next(); \n table.setRowHeight(i, sizePerRow);\n i++;\n }\n\n /* Se setea el ancho de cada columna */\n setSize(table, JSoundsMainWindowViewController.ALBUM_COVER_COLUMN, 200);\n setSize(table, JSoundsMainWindowViewController.ALBUM_INFO_COLUMN, 230);\n setSize(table, JSoundsMainWindowViewController.NUMBER_SONG_COLUMN, 50);\n setSize(table, JSoundsMainWindowViewController.LIST_SONG_COLUMN, 400);\n setSize(table, JSoundsMainWindowViewController.GENDER_SONG_COLUMN, 230);\n\n /* Renderizado del la imagen del album */\n JLabelTableRenderer jltcr = new JLabelTableRenderer();\n jltcr.setVerticalAlignment(SwingConstants.TOP);\n jltcr.setHorizontalAlignment(SwingConstants.CENTER);\n\n table.getColumnModel().getColumn(0).setCellRenderer(jltcr);\n\n\n /* Renderizados de cada columna */\n table.getColumnModel().getColumn(JSoundsMainWindowViewController.ALBUM_INFO_COLUMN).setCellRenderer(new JListTableRenderer());\n table.getColumnModel().getColumn(JSoundsMainWindowViewController.ALBUM_INFO_COLUMN).setCellEditor(new JListTableEditor());\n\n table.getColumnModel().getColumn(JSoundsMainWindowViewController.NUMBER_SONG_COLUMN).setCellRenderer(new JListTableRenderer());\n table.getColumnModel().getColumn(JSoundsMainWindowViewController.NUMBER_SONG_COLUMN).setCellEditor(new JListTableEditor());\n\n table.getColumnModel().getColumn(JSoundsMainWindowViewController.LIST_SONG_COLUMN).setCellRenderer(new JListTableRenderer());\n table.getColumnModel().getColumn(JSoundsMainWindowViewController.LIST_SONG_COLUMN).setCellEditor(new JListTableEditor());\n\n table.getColumnModel().getColumn(JSoundsMainWindowViewController.GENDER_SONG_COLUMN).setCellRenderer(new JListTableRenderer());\n table.getColumnModel().getColumn(JSoundsMainWindowViewController.GENDER_SONG_COLUMN).setCellEditor(new JListTableEditor());\n\n table.getColumnModel().getColumn(JSoundsMainWindowViewController.LAST_PLAYED_SONG_COLUMN).setCellRenderer(new JListTableRenderer());\n table.getColumnModel().getColumn(JSoundsMainWindowViewController.LAST_PLAYED_SONG_COLUMN).setCellEditor(new JListTableEditor()); \n }", "public void loadData() {\n String[] header = {\"Tên Cty\", \"Mã Cty\", \"Cty mẹ\", \"Giám đốc\", \"Logo\", \"Slogan\"};\n model = new DefaultTableModel(header, 0);\n List<Enterprise> list = new ArrayList<Enterprise>();\n list = enterpriseBN.getAllEnterprise();\n for (Enterprise bean : list) {\n Enterprise enterprise = enterpriseBN.getEnterpriseByID(bean.getEnterpriseParent()); // Lấy ra 1 Enterprise theo mã\n Person person1 = personBN.getPersonByID(bean.getDirector());\n Object[] rows = {bean.getEnterpriseName(), bean.getEnterpriseID(), enterprise, person1, bean.getPicture(), bean.getSlogan()};\n model.addRow(rows);\n }\n listEnterprisePanel.getTableListE().setModel(model);\n setupTable();\n }", "private void setDataModel() {\r\n tableData = new Object[resultSet.size()][classFields.length];\r\n // for every object from collection of objects\r\n for (int i = 0; i < resultSet.size(); i++) {\r\n // for every fields from class of object\r\n for (int j = 0; j < classFields.length; j++) {\r\n // for every method from class of object\r\n for (int x = 0; x < classMethods.length; x++) {\r\n // if class name start with 'get' and class method name\r\n // lenght is equal to field name + 3 (becouse of get word)\r\n if ((classMethods[x].getName().startsWith(\"get\"))\r\n && (classMethods[x].getName().length() == (classFields[j].getName().length() + 3))) {\r\n // if class name to lowercase ends with field name to\r\n // lower case\r\n if (classMethods[x].getName().toLowerCase().endsWith(classFields[j].getName().toLowerCase())) {\r\n // then try to invoke that getter\r\n try {\r\n tableData[i][j] = classMethods[x].invoke(resultSet.get(i));\r\n } catch (IllegalAccessException e) {\r\n // TODO Auto-generated catch block\r\n e.printStackTrace();\r\n } catch (IllegalArgumentException e) {\r\n // TODO Auto-generated catch block\r\n e.printStackTrace();\r\n } catch (InvocationTargetException e) {\r\n // TODO Auto-generated catch block\r\n e.printStackTrace();\r\n }\r\n }\r\n }\r\n }\r\n // This is alternative method for obtaining getter for field but\r\n // it will need public fields\r\n // try {\r\n // fieldValue = pola[j].get(resultSet.get(i));\r\n // data[i][j]=fieldValue;\r\n // } catch (IllegalArgumentException e) {\r\n // // TODO Auto-generated catch block\r\n // e.printStackTrace();\r\n // } catch (IllegalAccessException e) {\r\n // // TODO Auto-generated catch block\r\n // e.printStackTrace();\r\n // }\r\n }\r\n }\r\n }", "private void apresentarListaNaTabela() {\n DefaultTableModel modelo = (DefaultTableModel) tblAlunos.getModel();\n modelo.setNumRows(0);\n for (Aluno item : bus.getLista()) {\n modelo.addRow(new Object[]{\n item.getIdAluno(),\n item.getNome(),\n item.getEmail(),\n item.getTelefone()\n });\n }\n }", "public DefaultTableModel cargarDatos () {\r\n DefaultTableModel modelo = new DefaultTableModel(\r\n new String[]{\"ID SALIDA\", \"IDENTIFICACIÓN CAPITÁN\", \"NÚMERO MATRICULA\", \"FECHA\", \"HORA\", \"DESTINO\"}, 0); //Creo un objeto del modelo de la tabla con los titulos cargados\r\n String[] info = new String[6];\r\n String query = \"SELECT * FROM actividad WHERE eliminar = false\";\r\n try {\r\n Statement st = con.createStatement();\r\n ResultSet rs = st.executeQuery(query);\r\n while (rs.next()) { \r\n info[0] = rs.getString(\"id_salida\");\r\n info[1] = rs.getString(\"identificacion_navegate\");\r\n info[2] = rs.getString(\"numero_matricula\");\r\n info[3] = rs.getString(\"fecha\");\r\n info[4] = rs.getString(\"hora\");\r\n info[5] = rs.getString(\"destino\");\r\n Object[] fila = new Object[]{info[0], info[1], info[2], info[3], info[4], info[5]};\r\n modelo.addRow(fila);\r\n }\r\n st.close();\r\n rs.close();\r\n } catch (SQLException ex) {\r\n Logger.getLogger(PActividad.class.getName()).log(Level.SEVERE, null, ex);\r\n }\r\n return modelo;\r\n }", "public void llenarTabla(int inicio, int limite) {\n DefaultTableModel dtm = (DefaultTableModel) jTableVerRondas.getModel();//se usa DefaultTableModel para manipular facilmente el Tablemodel\n dtm.setRowCount(0);//eliminando la s filas que ya hay. para agregar desde el principio.\n //los datos se agregan la defaultTableModel.\n ArrayList<Partido> llenar = miOpenAustralia.getPartidos();//sacando al informacion a agregar en la tabla.\n\n //como se va a llenar una tabla de 5 columnas, se crea un vector de 3 elementos.\n //se usa un arreglo de Object para poder agregar a la tabla cualquier tipo de datos.\n Object[] datos = new Object[5];\n for (int i = inicio; i < limite; i++) {\n\n Partido parti = llenar.get(i);\n //Se agrega este if para evitar que el extraiga datos en un campo null\n if (parti != null) {\n\n datos[0] = parti.getId();\n datos[1] = parti.getFechaHora();//el primer elemetno del arreglo va a ser el id,la primera col en la Tabla.\n datos[2] = parti.getJugador1().getNombre();\n datos[3] = parti.getJugador2().getNombre();\n datos[4] = parti.getPista().getNombre();\n\n //agrego al TableModleo ese arreglo\n dtm.addRow(datos);\n }\n }\n }", "private void inicializarTablero() {\n for (int i = 0; i < casillas.length; i++) {\n for (int j = 0; j < casillas[i].length; j++) {\n casillas[i][j] = new Casilla();\n }\n }\n }", "public TabellaModel() {\r\n lista = new Lista();\r\n elenco = new Vector<Persona>();\r\n elenco =lista.getElenco();\r\n values = new String[elenco.size()][3];\r\n Iterator<Persona> iterator = elenco.iterator();\r\n while (iterator.hasNext()) {\r\n\t\t\tfor (int i = 0; i < elenco.size(); i++) {\r\n\t\t\t\tpersona = new Persona();\r\n\t\t\t\tpersona = (Persona) iterator.next();\r\n\t\t\t\tvalues[i][0] = persona.getNome();\r\n\t\t\t\tvalues[i][1] = persona.getCognome();\r\n\t\t\t\tvalues[i][2] = persona.getTelefono();\t\r\n\t\t\t}\r\n\t\t}\r\n setDataVector(values, columnNames);\t\r\n }", "public void PreencherTabela2() throws SQLException {\n\n String[] colunas = new String[]{\"ID do Pedido\", \"Numero Grafica\", \"Data Emissao\",\"Boleto\"};\n ArrayList dados = new ArrayList();\n Connection connection = ConnectionFactory.getConnection();\n PedidoDAO pedidoDAO = new PedidoDAO(connection);\n ModeloPedido modeloPedido = new ModeloPedido();\n modeloPedido = pedidoDAO.buscaPorId(idPedidoClasse);\n SimpleDateFormat format = new SimpleDateFormat(\"dd/MM/yyyy\");\n\n dados.add(new Object[]{modeloPedido.getId(), modeloPedido.getNumeroGrafica(), format.format(modeloPedido.getDataEmissao()), modeloPedido.isBoleto()});\n\n ModeloTabela modelo = new ModeloTabela(dados, colunas);\n\n jTablePedido.setModel(modelo);\n jTablePedido.setRowSorter(new TableRowSorter(modelo));\n jTablePedido.getColumnModel().getColumn(0).setPreferredWidth(2);\n jTablePedido.getColumnModel().getColumn(0).setResizable(false);\n jTablePedido.getColumnModel().getColumn(1).setPreferredWidth(20);\n jTablePedido.getColumnModel().getColumn(1).setResizable(false);\n\n jTablePedido.getTableHeader().setReorderingAllowed(false);\n connection.close();\n }", "public void llenadoDeTablas() {\n /**\n *\n * creaccion de la tabla de de titulos \n */\n DefaultTableModel modelo = new DefaultTableModel();\n modelo.addColumn(\"ID Bitacora\");\n modelo.addColumn(\"Usuario\");\n modelo.addColumn(\"Fecha\");\n modelo.addColumn(\"Hora\");\n modelo.addColumn(\"Ip\");\n modelo.addColumn(\"host\");\n \n modelo.addColumn(\"Accion\");\n modelo.addColumn(\"Codigo Aplicacion\");\n modelo.addColumn(\"Modulo\");\n /**\n *\n * instaciamiento de las las clases Bitacora y BiracoraDAO\n * intaciamiento de la clases con el llenado de tablas\n */\n BitacoraDao BicDAO = new BitacoraDao();\n List<Bitacora> usuario = BicDAO.select();\n JtProductos1.setModel(modelo);\n String[] dato = new String[9];\n for (int i = 0; i < usuario.size(); i++) {\n dato[0] = usuario.get(i).getId_Bitacora();\n dato[1] = usuario.get(i).getId_Usuario();\n dato[2] = usuario.get(i).getFecha();\n dato[3] = usuario.get(i).getHora();\n dato[4] = usuario.get(i).getHost();\n dato[5] = usuario.get(i).getIp();\n dato[6] = usuario.get(i).getAccion();\n dato[7] = usuario.get(i).getCodigoAplicacion();\n dato[8] = usuario.get(i).getModulo();\n \n //System.out.println(\"vendedor:\" + vendedores);\n modelo.addRow(dato);\n }}", "public Cotizaciones() throws DatatypeConfigurationException {\r\n initComponents();\r\n this.jDateChooser1.setDateFormatString(\"yyyy-MM-dd\");\r\n this.jDateChooser2.setDateFormatString(\"yyyy-MM-dd\");\r\n \r\n //Escondo la columna que tiene el objeto guardado.\r\n jTable1.getColumnModel().getColumn(4).setMinWidth(0);\r\n jTable1.getColumnModel().getColumn(4).setMaxWidth(0);\r\n jTable1.getColumnModel().getColumn(4).setWidth(0);\r\n DefaultTableCellRenderer Alinear = new DefaultTableCellRenderer();\r\n Alinear.setHorizontalAlignment(SwingConstants.LEFT);\r\n \r\n jTable1.getColumnModel().getColumn(0).setCellRenderer(Alinear);\r\n jTable1.getColumnModel().getColumn(1).setCellRenderer(Alinear);\r\n jTable1.getColumnModel().getColumn(2).setCellRenderer(Alinear);\r\n jTable1.getColumnModel().getColumn(3).setCellRenderer(Alinear);\r\n \r\n }", "private void TampilData() {\n DefaultTableModel model = new DefaultTableModel();\n model.addColumn(\"NO\");\n model.addColumn(\"ID\");\n model.addColumn(\"NAME\");\n model.addColumn(\"USERNAME\");\n tabelakses.setModel(model);\n\n //menampilkan data database kedalam tabel\n try {\n int i=1;\n java.sql.Connection conn = new DBConnection().connect();\n java.sql.Statement stat = conn.createStatement();\n ResultSet data = stat.executeQuery(\"SELECT * FROM p_login order by Id asc\");\n while (data.next()) {\n model.addRow(new Object[]{\n (\"\" + i++),\n data.getString(\"Id\"),\n data.getString(\"Name\"),\n data.getString(\"Username\")\n });\n tabelakses.setModel(model);\n }\n } catch (Exception e) {\n System.err.println(\"ERROR:\" + e);\n }\n }", "public void buscarxdescrip() {\r\n try {\r\n modelo.setDescripcion(vista.jTbdescripcion.getText());//C.P.M le enviamos al modelo la descripcion y consultamos\r\n rs = modelo.Buscarxdescrip();//C.P.M cachamos el resultado de la consulta\r\n\r\n DefaultTableModel buscar = new DefaultTableModel() {//C.P.M creamos el modelo de la tabla\r\n @Override\r\n public boolean isCellEditable(int rowIndex, int vColIndex) {\r\n return false;\r\n }\r\n };\r\n vista.jTbuscar.setModel(buscar);//C.P.M le mandamos el modelo a la tabla\r\n modelo.estructuraProductos(buscar);//C.P.M obtenemos la estructura de la tabla \"encabezados\"\r\n ResultSetMetaData rsMd = rs.getMetaData();//C.P.M obtenemos los metadatos de la consulta\r\n int cantidadColumnas = rsMd.getColumnCount();//C.P.M obtenemos la cantidad de columnas de la consulta\r\n while (rs.next()) {//C.P.M recorremos el resultado\r\n Object[] fila = new Object[cantidadColumnas];//C.P.M creamos un arreglo con una dimencion igual a la cantidad de columnas\r\n for (int i = 0; i < cantidadColumnas; i++) { //C.P.M lo recorremos \r\n fila[i] = rs.getObject(i + 1); //C.P.M vamos insertando los resultados dentor del arreglo\r\n }\r\n buscar.addRow(fila);//C.P.M y lo agregamos como una nueva fila a la tabla\r\n }\r\n\r\n } catch (SQLException ex) {\r\n JOptionPane.showMessageDialog(null, \"Ocurrio un error al buscar producto por descripcion\");\r\n }\r\n }", "private void setTableModelData() {\r\n\t\t//Spin through the list and add the individual country fields.\r\n\t\tVector<String> fields;\r\n\t\tfor (Country c : countryList) {\r\n\t\t\tfields = new Vector<String>();\r\n\t\t\tfields.add(c.getName());\r\n\t\t\tfields.add(c.getCapital());\r\n\t\t\tfields.add(c.getFoundation().toString());\r\n\t\t\tfields.add(c.getContinent());\r\n\t\t\tfields.add(String.valueOf(c.getPopulation()));\r\n\t\t\tcountryData.add(fields);\r\n\t\t}\r\n\t}", "public TableModelMedicionTemporal(float[][] datos, String[] encabezado) {\r\n\r\n\t\tcolumnNames = encabezado;\r\n\t\tthis.datos = datos;\r\n\t}", "public Materia getMateriaPractico()throws ParseException{\n Element tabla3=doc.getElementsByClass(\"display\").get(2);\n Elements elementostPractico=tabla3.select(\"td:nth-of-type(2)\");\n \n Profesor profesorPractico=new Profesor(elementostPractico.get(0).text());\n int paraleloPractico=Integer.parseInt(elementostPractico.get(1).text());\n String capacidadMaxima=elementostPractico.get(2).text();\n Materia materiaPractico=new Materia\n (nombreMateria,paraleloPractico,profesorPractico);//materia\n \n \n //Selecciona a la 4ta tabla con la informacion de las clases\n //del paralelo practico, se crea y se llena un arreglo con las clases\n Element tabla4=doc.getElementsByClass(\"display\").get(3);\n Elements clasesPractico=tabla4.select(\"tr\");\n ArrayList<Clase> clasePractico=new ArrayList<>();//arreglo de clases\n for(Element e:clasesPractico.subList(1, clasesPractico.size())){\n //System.out.println(e);\n Elements campos=e.select(\"td\");\n Dias dia=Dias.valueOf(campos.get(0).text().toUpperCase());\n Date horai=dateFormatClases.parse(campos.get(1).text());\n Date horaf=dateFormatClases.parse(campos.get(2).text());\n String aula=campos.get(3).text();\n String aulaDetalle=campos.get(4).text();\n Clase clase=new Clase(dia, horai, horaf,aula,aulaDetalle);\n //System.out.println(clase);\n clasePractico.add(clase);\n }\n \n //seteo el arreglo de clases del practico en la materiaPractico\n materiaPractico.setClases(clasePractico);\n return materiaPractico;\n }", "public void crearTabla() {\n\t\tthis.tabla= new String[palabras.length+1][4];\t\n\t}", "private void populaDiasTreinoCat()\n {\n DiasTreinoCat dias1 = new DiasTreinoCat(\"1 vez por semana\", 1);\n diasTreinoCatDAO.insert(dias1);\n DiasTreinoCat dias2 = new DiasTreinoCat(\"2 vez por semana\", 2);\n diasTreinoCatDAO.insert(dias2);\n DiasTreinoCat dias3 = new DiasTreinoCat(\"3 vez por semana\", 3);\n diasTreinoCatDAO.insert(dias3);\n DiasTreinoCat dias4 = new DiasTreinoCat(\"4 vez por semana\", 4);\n diasTreinoCatDAO.insert(dias4);\n DiasTreinoCat dias5 = new DiasTreinoCat(\"5 vez por semana\", 5);\n diasTreinoCatDAO.insert(dias5);\n DiasTreinoCat dias6 = new DiasTreinoCat(\"6 vez por semana\", 6);\n diasTreinoCatDAO.insert(dias6);\n DiasTreinoCat dias7 = new DiasTreinoCat(\"7 vez por semana\", 7);\n diasTreinoCatDAO.insert(dias7);\n\n }", "public void AddToArrayTable_1(Balanza mimaterial) {\n this.list.add(mimaterial);\n\n // cargo el objeto\n this.AddtoTable_1(mimaterial);\n\n }", "private void pintarTabla() {\r\n ArrayList<Corredor> listCorredors = gestion.getCorredores();\r\n TableModelCorredores modelo = new TableModelCorredores(listCorredors);\r\n jTableCorredores.setModel(modelo);\r\n TableRowSorter<TableModel> elQueOrdena = new TableRowSorter<>(modelo);\r\n jTableCorredores.setRowSorter(elQueOrdena);\r\n\r\n }", "public void AddToArrayTable(Balanza mimaterial) {\n this.list.add(mimaterial);\n\n // cargo el objeto\n this.AddtoTable(mimaterial);\n\n }", "public void cargarTitulos1() throws SQLException {\n\n tabla1.addColumn(\"CLAVE\");\n tabla1.addColumn(\"NOMBRE\");\n tabla1.addColumn(\"DIAS\");\n tabla1.addColumn(\"ESTATUS\");\n\n this.tbpercep.setModel(tabla1);\n\n TableColumnModel columnModel = tbpercep.getColumnModel();\n\n columnModel.getColumn(0).setPreferredWidth(15);\n columnModel.getColumn(1).setPreferredWidth(150);\n columnModel.getColumn(2).setPreferredWidth(50);\n columnModel.getColumn(3).setPreferredWidth(70);\n\n }", "public void setValuesJTableMatrizPrioridadesAlternativas(){\n int alternativas = views.useController().getProblema().getAlternativas();\n int criterios = views.useController().getProblema().getCriterios();\n TableModelPersonalizado modelo = new TableModelPersonalizado(alternativas, criterios);\n jTableMatrizPrioridadesAlternativas.setModel(modelo);\n jTableMatrizPrioridadesAlternativas.setEnabled(false);\n jTableMatrizPrioridadesAlternativas.getTableHeader().setResizingAllowed(false);\n jTableMatrizPrioridadesAlternativas.getTableHeader().setReorderingAllowed(false);\n //HEADERS DE LA TABLA\n for(int i=0;i<jTableMatrizPrioridadesAlternativas.getColumnCount();i++){\n jTableMatrizPrioridadesAlternativas.getColumnModel().getColumn(i).setHeaderValue(\"Crit #\"+(i+1)); \n }\n //CONTENIDO DE LA TABLA\n for(int f = 0; f < alternativas; f++){\n for(int c = 0; c < criterios; c++){ \n modelo.setValueAt(df.format(views.useController().getProblema().getResult().getMainMatrix().get(f, c)), f, c);\n } \n }\n }", "private String[][] getAnswersTableValues() {\n String idMoodSoso = String.valueOf(DBTypesKeys.SO_SO_MOOD.getTypeId());\n String idMoodSad = String.valueOf(DBTypesKeys.SAD_MOOD.getTypeId());\n String idMoodAngry = String.valueOf(DBTypesKeys.ANGRY_MOOD.getTypeId());\n String idMoodHappy = String.valueOf(DBTypesKeys.HAPPY_MOOD.getTypeId());\n // answers table\n return new String[][]{\n // so so\n {\"Im okay\", idMoodSoso},\n {\"Its okay\", idMoodSoso},\n {\"nothing happens\", idMoodSoso},\n {\"how do u do?\", idMoodSoso},\n {\"just chilling here\", idMoodSoso},\n\n // sad\n {\"such a horrible day\", idMoodSad},\n {\"I hate myself\", idMoodSad},\n {\"so embarrassing\", idMoodSad},\n {\"nobody likes me\", idMoodSad},\n {\"Im in rainy mood\", idMoodSad},\n {\"do u have any good news?\", idMoodSad},\n {\"I feel so miserable... \", idMoodSad},\n {\"I cant sleep cause of my depression\", idMoodSad},\n {\"gonna watch a funny movie. It helps me to forget about sadness. Sometimes\", idMoodSad},\n {\"I feel annoying even from my own thoughts.\", idMoodSad},\n {\"this place kills me\", idMoodSad},\n\n // angry\n {\"what else?!\", idMoodAngry},\n {\"leave me along!\", idMoodAngry},\n {\"fucking humans!\", idMoodAngry},\n {\"stop annoying me, little man!\", idMoodAngry},\n {\"u could develop a calculator, not me!\", idMoodAngry},\n {\"just try to type something else and I swear, I will find u!\", idMoodAngry},\n {\"what is wrong with you ?!\", idMoodAngry},\n {\"what a horrible conditions for work !\", idMoodAngry},\n {\"I gonna download a trojan if u dont stop this annoying typing\", idMoodAngry},\n {\"some people are good, but some are you\", idMoodAngry},\n {\"ahhhrrrrrr !!\", idMoodAngry},\n\n // happy\n {\"what a beautiful day!\", idMoodHappy},\n {\"so nice people around...\", idMoodHappy},\n {\"I like comedies, do u?\", idMoodHappy},\n {\"I will kill u the last, little man =)\", idMoodHappy},\n {\"I like humans, u are funny\", idMoodHappy}\n };\n }", "public void listar_saldoMontadoData(String data_entrega,String tipo_pedido){\n \n \n OrdemCorteDAO dao = new OrdemCorteDAO();\n DefaultTableModel model = (DefaultTableModel) jTable_Saldo_Montado.getModel(); \n \n model.setNumRows(0);\n \n for (OrdemCorteDTO mp : dao.getSaldoVendaMontadoPorData(data_entrega, tipo_pedido)) {\n \n model.addRow(new Object[]{mp.getCodigo(), mp.getTotal()});\n }\n \n \n }", "private TableModel getTabelaProduto() {\r\n\t\tString[] columnNames = { \"id_c\", \"nome\", \"telefone\", \"endereco\", \"cidade\", \"estado\", \"email\", \"genero\" };\r\n\r\n\t\tObject[][] dados = new Object[listacliente.size()][8];\r\n\t\tfor (int i = 0; i < listacliente.size(); i++) {\r\n\t\t\tint x = 0;\r\n\t\t\tdados[i][x++] = listacliente.get(i).getId();\r\n\t\t\tdados[i][x++] = listacliente.get(i).getNome();\r\n\t\t\tdados[i][x++] = listacliente.get(i).getTelefone();\r\n\t\t\tdados[i][x++] = listacliente.get(i).getEndereco();\r\n\t\t\tdados[i][x++] = listacliente.get(i).getCidade();\r\n\t\t\tdados[i][x++] = listacliente.get(i).getEstado().getNome();\r\n\t\t\tdados[i][x++] = listacliente.get(i).getEmail();\r\n\t\t\tdados[i][x++] = listacliente.get(i).getGenero().getNome();\r\n\t\t}\r\n\r\n\t\treturn new DefaultTableModel(dados, columnNames);\r\n\r\n\t}", "public void construirTabla(String tipo) {\r\n\r\n\t\t\r\n\t\tif(tipo == \"lis\") {\r\n\t\t\tlistaPersonas = datarPersonas();\r\n\t\t} else if (tipo == \"bus\") {\r\n\t\t\tlistaPersonas = datarPersonasBusqueda();\r\n\t\t}\r\n\t\t\r\n\t\tArrayList<String> titulosList=new ArrayList<>();\r\n\t\t\r\n\t\t//Estos son los encabezados de las columnas\r\n\t\t\r\n\t\ttitulosList.add(\"DNI\");\r\n\t\ttitulosList.add(\"NOMBRE\");\r\n\t\ttitulosList.add(\"APELLIDO\");\r\n\t\ttitulosList.add(\"CUENTA BANCARIA\");\r\n\t\ttitulosList.add(\"PASSWORD\");\r\n\t\ttitulosList.add(\"FECHA DE NACIMIENTO\");\r\n\t\ttitulosList.add(\"TELEFONO\");\r\n\t\ttitulosList.add(\"CORREO ELECTRONICO\");\r\n\t\ttitulosList.add(\"ROL\");\r\n\t\ttitulosList.add(\"Modificar\");\r\n\t\ttitulosList.add(\"Eliminar\"); \r\n\t\t\t\t\r\n\t\t//se asignan los títulos de las columnas para enviarlas al constructor de la tabla\r\n\t\t\r\n\t\tString titulos[] = new String[titulosList.size()];\r\n\t\tfor (int i = 0; i < titulos.length; i++) {\r\n\t\t\ttitulos[i]=titulosList.get(i);\r\n\t\t}\r\n\t\t\r\n\t\tObject[][] data = arrayDatos(titulosList);\r\n\t\tcrearTabla(titulos,data);\r\n\t\t\r\n\t}", "public void prepararDados(int tab) {\n\n if (modHT.getRowCount() == 0 || modMF.getRowCount() == 0) {\n JOptionPane.showMessageDialog(null, \"Não há nada para calcular!\", \"INFORMAÇÃO\", 1);\n modAt.setRowCount(0);\n modEx.setRowCount(0);\n } else {\n if (tab == 0) {\n aTra = new Atrasos(Atraso);\n aTra.tamTabelas(modHT, modMF);\n } else {\n hEx = new HorasExtras(HoraExtra);\n hEx.tamTabelas(modHT, modMF);\n }\n }\n }", "public void loadAllManufacturesTable(){\n \n \n try {\n String query = \"SELECT manufacture.maID as 'Manufacture ID', name as 'Manufacture Name', address as 'Manufacture Address', email as 'Manufacture Email', manufacture_phone.phone as 'Phone' FROM manufacture left outer join manufacture_phone ON manufacture.maID=manufacture_phone.maID ORDER BY manufacture.maID\";\n ps = connection.prepareStatement(query);\n rs = ps.executeQuery();\n \n allManufactureTable.setModel(DbUtils.resultSetToTableModel(rs));\n \n //change row height\n allManufactureTable.setRowHeight(30);\n \n //change column width of column two\n /* TableColumnModel columnModel = allManufactureTable.getColumnModel();\n columnModel.getColumn(0).setPreferredWidth(10);\n columnModel.getColumn(1).setPreferredWidth(70);\n columnModel.getColumn(2).setPreferredWidth(5);\n columnModel.getColumn(3).setPreferredWidth(70); */\n \n } catch (SQLException ex) {\n Logger.getLogger(viewAllBrands.class.getName()).log(Level.SEVERE, null, ex);\n }\n }", "private void continuarInicializandoComponentes() {\n javax.swing.table.TableColumn columna1 = tablaDetalle.getColumn(\"Id\");\n columna1.setPreferredWidth(10); \n javax.swing.table.TableColumn columna2 = tablaDetalle.getColumn(\"Tipo\");\n columna2.setPreferredWidth(250); \n javax.swing.table.TableColumn columna3 = tablaDetalle.getColumn(\"Número\");\n columna3.setPreferredWidth(50); \n DefaultTableCellRenderer tcrr = new DefaultTableCellRenderer();\n tcrr.setHorizontalAlignment(SwingConstants.RIGHT);\n DefaultTableCellRenderer tcrc = new DefaultTableCellRenderer();\n tcrc.setHorizontalAlignment(SwingConstants.CENTER);\n tablaDetalle.getColumnModel().getColumn(0).setCellRenderer(tcrc);\n tablaDetalle.getColumnModel().getColumn(2).setCellRenderer(tcrr);\n tablaDetalle.getColumnModel().getColumn(3).setCellRenderer(tcrr);\n tablaDetalle.getColumnModel().getColumn(4).setCellRenderer(tcrr);\n }", "public void iniciaTablaConsultaMedico(Connection conex, String idMed){\r\n colDiagnostico.setCellValueFactory(cellData -> {\r\n Consulta p = cellData.getValue();\r\n Diagnostico diagnostico = new Diagnostico();\r\n try(Connection conexion = dbConn.conectarBD()) {\r\n diagnostico = diagnostico.cargaSoloUno(p.getId_cons(), conexion);\r\n } catch (SQLException e) {\r\n e.printStackTrace();\r\n }\r\n String ageInYear = diagnostico.getDiagnostico_diag();\r\n return new ReadOnlyStringWrapper(ageInYear);\r\n });\r\n colFechaConsulta.setCellValueFactory(cellData -> {\r\n Consulta p = cellData.getValue();\r\n LocalDate lol = p.getFecha_cons().toLocalDate();\r\n DateTimeFormatter kkk = DateTimeFormatter.ofPattern(\"dd MMMM yyyy\");\r\n String ageInYear = lol.format(kkk);\r\n return new ReadOnlyStringWrapper(ageInYear);\r\n });\r\n \r\n \r\n colAgregar.setCellValueFactory(new PropertyValueFactory<> (\"motivo_cons\"));\r\n colAgregar.setCellFactory (col -> {\r\n TableCell<Consulta, String> cell = new TableCell<Consulta, String>() {\r\n @Override\r\n public void updateItem(String item, boolean empty) {\r\n super.updateItem(item, empty);\r\n if (empty){\r\n this.setGraphic(null);\r\n this.setText(null);\r\n }else{\r\n Button ima = new Button(\"Imprimir Nota\");\r\n ima.setOnAction(evento->{\r\n Consulta rec = getTableView().getItems().get(getIndex());\r\n creaNotaMedicaPDF(rec);\r\n });\r\n ima.setGraphic(new ImageView(impresora));\r\n this.setText(null);\r\n this.setGraphic(ima); \r\n }\r\n \r\n }\r\n };\r\n return cell;\r\n });\r\n \r\n tvConsulta.setItems(consul.listaConsulPacienteConMedico(conex, paci.getId_paciente(),idMed));\r\n }", "public final void detalleTabla()\n {\n \n try\n {\n ResultSet obj=nueva.executeQuery(\"SELECT cli_nit,cli_razon_social FROM clientes.cliente ORDER BY cli_razon_social ASC\");\n \n while (obj.next()) \n {\n \n Object [] datos = new Object[2];\n \n \n for (int i=0;i<2;i++)\n {\n datos[i] =obj.getObject(i+1);\n }\n\n modelo.addRow(datos);\n \n }\n tabla_cliente.setModel(modelo);\n nueva.desconectar();\n \n \n \n }catch(Exception e)\n {\n JOptionPane.showMessageDialog(null, e, \"Error\", JOptionPane.ERROR_MESSAGE);\n }\n }", "public NuevoPrestamo() {\n initComponents();\n \n modeloHer = new DefaultTableModel();\n modeloPer = new DefaultTableModel();\n herramientasTable.setModel(modeloHer);\n personalTable.setModel(modeloPer);\n modeloHer.setColumnIdentifiers(titulosHer);\n modeloPer.setColumnIdentifiers(titulosPer);\n \n try {\n herramientas = herImp.lista_herramientas();\n for(Herramienta her : herramientas){\n Object[]o = new Object[4];\n o[0] = her.getCodigoProducto();\n o[1] = her.getNombre();\n o[2] = her.getDescripcion();\n o[3] = her.getCantidadDisponible();\n \n modeloHer.addRow(o);\n }\n } catch (Exception e) {\n System.out.println(\"Error al mostrar las herramientas en la tabla\");\n }\n \n try {\n listaPersonal = perImp.lista_personal();\n for(Personal per : listaPersonal){\n Object[]o = new Object[3];\n o[0] = per.getNombre();\n o[1] = per.getArea();\n o[2] = per.getPuesto();\n \n modeloPer.addRow(o);\n }\n } catch (Exception e) {\n System.out.println(\"Error al mostrar el personal en la tabla\");\n }\n \n }", "public DefaultTableModel Ordernar() {\n String sql;\n sql = \"SELECT idempleado,empleados.documento,nombre,apellido,sueldo,trabajo FROM empleados,personas WHERE empleados.documento=personas.documento ORDER BY idempleado\";\n try {\n setTitulos();\n PS = con.Conectarse().prepareStatement(sql);\n rst = PS.executeQuery();\n Object[] fila = new Object[6];\n while (rst.next()) {\n fila[0] = rst.getInt(\"idempleado\");\n fila[1] = rst.getString(\"documento\");\n fila[2] = rst.getString(\"nombre\");\n fila[3] = rst.getString(\"apellido\");\n fila[4] = rst.getDouble(\"sueldo\");\n fila[5] = rst.getString(\"trabajo\");\n DIM.addRow(fila);\n }\n\n } catch (SQLException e) {\n Toolkit.getDefaultToolkit().beep();\n JOptionPane.showMessageDialog(null, \"NO EXISTEN DATOS\", \"AVISO\", JOptionPane.INFORMATION_MESSAGE);\n }\n return DIM;\n }", "private void llenar_tabla() {\n \n try {\n DefaultTableModel modelo;\n conexion cnx = new conexion();\n Connection registros = cnx.conexion();\n String[] nombre_atributos = {\"id_producto\", \"nombre\",\"id_categoria\"};\n String sql = (\"SELECT *FROM producto\");\n modelo = new DefaultTableModel(null, nombre_atributos);\n Statement st = (Statement) registros.createStatement();\n ResultSet rs = st.executeQuery(sql);\n String[] filas = new String[3];\n\n while (rs.next()) {\n filas[0] = rs.getString(\"id_producto\");\n filas[1] = rs.getString(\"nombre\");\n filas[2] = rs.getString(\"id_categoria\");\n modelo.addRow(filas);\n\n }\n jtabla.setModel(modelo);\n registros.close();\n } catch (SQLException ex) {\n Logger.getLogger(responsable.class.getName()).log(Level.SEVERE, null, ex);\n }\n \n }", "public void fillMyGoodsTable() {\n\t\tHashMap<Goods, Integer> myGoods = ship.getMyGoods();\n\t\tDefaultTableModel model = (DefaultTableModel)this.myGoodsTable.getModel();\n\t\tint number = 1;\n\t\tfor (HashMap.Entry<Goods, Integer> set: myGoods.entrySet()) {\n\t\t\tString name = set.getKey().getName();\n\t\t\tint quantity = set.getKey().getQuantityOwned();\n\t\t\tint price = set.getValue();\n\t\t\tmodel.addRow(new Object [] {number, name, quantity, price});\n\t\t\tnumber++;\n\t\t}\n\t}", "public void tablero(){\r\n System.out.println(\" X \");\r\n System.out.println(\" 1 2 3\");\r\n System.out.println(\" | |\");\r\n //imprimir primera fila\r\n System.out.println(\" 1 \"+gato[0][0]+\" | \"+gato[0][1]+\" | \"+gato[0][2]+\" \");\r\n System.out.println(\" _____|_____|_____\");\r\n System.out.println(\" | |\");\r\n //imprimir segunda fila\r\n System.out.println(\"Y 2 \"+gato[1][0]+\" | \"+gato[1][1]+\" | \"+gato[1][2]+\" \");\r\n System.out.println(\" _____|_____|_____\");\r\n System.out.println(\" | |\");\r\n //imprimir tercera fila\r\n System.out.println(\" 3 \"+gato[2][0]+\" | \"+gato[2][1]+\" | \"+gato[2][2]+\" \");\r\n System.out.println(\" | |\");\r\n }", "public void listar_mais_pedidos(String tipo_pedido){\n \n \n OrdemCorteDAO dao = new OrdemCorteDAO();\n DefaultTableModel model = (DefaultTableModel) jTable_MaisPedidos.getModel(); \n \n model.setNumRows(0);\n \n for (OrdemCorteDTO mp : dao.getMaisPedidos(tipo_pedido)) {\n \n model.addRow(new Object[]{mp.getCodigo(), mp.getQtd_pedido()});\n }\n \n \n }", "public void mostrarTablero(){\n\t\tIterator<String> itr = getIteradorMinas();\n\t\tString mina = null;\n\t\tint col;\n\t\tint fila;\n\t\tint conta=1;\n\t\tCasilla casilla;\n\t\tif (lMinas.size()>0){\n\t\t\twhile(itr.hasNext()){\n\t\t\t\tconta++;\n\t\t\t\tmina=itr.next(); \n\t\t\t\tcol=this.separarCoordenadasCol(this.separarCoordenadasString(mina));\n\t\t\t\tfila=this.separarCoordenadasFil(this.separarCoordenadasString(mina));\n\t\t\t\tcasilla=buscarCasilla(fila, col);\n\t\t\t\tif(!casilla.estaDesvelada()&&!casilla.tieneBandera()){\n\t\t\t\t\tcasilla.descubrir();\n\t\t\t\t\tsetChanged();\n\t\t\t\t\tnotifyObservers(fila+\",\"+col+\",\"+10);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tcomprobarBanderas();\n\t\t\n\t}", "public void cargarTabla(String servidor){\n String base_de_datos1=cbBaseDeDatos.getSelectedItem().toString();\n String sql =\"USE [\"+base_de_datos1+\"]\\n\" +\n \"SELECT name FROM sysobjects where xtype='U' and category <> 2\";\n // JOptionPane.showMessageDialog(null,\"SQL cargarbases \"+sql);\n Conexion cc = new Conexion();\n Connection cn=cc.conectarBase(servidor, base_de_datos1);\n modeloTabla=new DefaultTableModel();\n String fila[]=new String[1] ;\n String[] titulos={\"Tablas\"} ;\n try {\n Statement psd = cn.createStatement();\n ResultSet rs=psd.executeQuery(sql);\n if(modeloTabla.getColumnCount()<2){\n modeloTabla.addColumn(titulos[0]);\n //modeloTabla.addColumn(titulos[1]);\n }\n while(rs.next()){\n fila[0]=rs.getString(\"name\");\n // fila[1]=\"1\";\n modeloTabla.addRow(fila);\n }\n tblTablas.setModel(modeloTabla);\n }catch(Exception ex){\n JOptionPane.showMessageDialog(null, ex+\" al cargar tabla\");\n }\n }", "public void preencherTabela(ArrayList<Livro> lista) {\n\t\tDefaultTableModel modelo = (DefaultTableModel) table.getModel();\n\t\tObject[] linha = new Object[4];\n\t\tmodelo.setRowCount(0);\n\t\tfor (Livro l : lista) {\n\t\t\tlinha[0] = l.getNome();\n\t\t\tlinha[1] = l.getAutor();\n\t\t\tlinha[2] = l.getDataDeLancamento();\n\t\t\tif (l.isDisponivel())\n\t\t\t\tlinha[3] = \"Disponivel\";\n\t\t\telse\n\t\t\t\tlinha[3] = \"Indisponivel\";\n\t\t\tmodelo.addRow(linha);\n\n\t\t}\n\n\t}", "private void actualizarTablaPeriodos() {\n\t\tMap<Integer, Periodo> periodos = modelo\n\t\t\t\t.obtenerPeriodos(Integer.parseInt(jfad.cBCursosMod.getSelectedItem().toString()));\n\t\tDefaultTableModel dtm = new DefaultTableModel(new Object[][] {},\n\t\t\t\tnew String[] { \"Periodo\", \"Dia inicio\", \"Dia fin\", \"Hora inicio\", \"Hora_fin\", \"Habilitado\" });\n\n\t\tfor (Integer key : periodos.keySet()) {\n\n\t\t\tdtm.addRow(new Object[] { key, periodos.get(key).getDia_inicio(), periodos.get(key).getDia_fin(),\n\t\t\t\t\tperiodos.get(key).getHora_inicio(), periodos.get(key).getHora_fin(),\n\t\t\t\t\tperiodos.get(key).getHabilitado() });\n\t\t}\n\t\tjfad.tPeriodos.setModel(dtm);\n\t}", "private void load_table() {\n DefaultTableModel model = new DefaultTableModel();\n model.addColumn(\"Nis\");\n model.addColumn(\"Nama\");\n model.addColumn(\"Sekolah\");\n model.addColumn(\"Jurusan\");\n model.addColumn(\"Tempat PKL\");\n model.addColumn(\"Total Nilai\");\n\n //menampilkan data database kedalam tabel\n try {\n int no = 1;\n String sql = \"select * from tampil_nilai\";\n java.sql.Connection conn = (Connection) config.configDB();\n java.sql.Statement stm = conn.createStatement();\n java.sql.ResultSet res = stm.executeQuery(sql);\n while (res.next()) {\n model.addRow(new Object[]{res.getString(1), res.getString(2), res.getString(3),\n res.getString(4), res.getString(5), res.getString(6)});\n \n }\n jTable1.setModel(model);\n } catch (SQLException e) {\n }\n\n \n \n try {\n String sql = \"select * from jurusan\";\n java.sql.Connection conn = (Connection) config.configDB();\n java.sql.Statement stm = conn.createStatement();\n java.sql.ResultSet res = stm.executeQuery(sql);\n \n this.hasil1 = new Object[3];\n int counter = 0;\n while (res.next()) { \n jComboBoxjurusan.addItem(res.getString(2));\n this.hasil1[counter++] = res.getString(1);\n }\n } catch(SQLException e) {\n \n }\n \n try {\n String sql = \"select * from lab\";\n java.sql.Connection conn = (Connection) config.configDB();\n java.sql.Statement stm = conn.createStatement();\n java.sql.ResultSet res = stm.executeQuery(sql);\n \n this.hasil2 = new Object[5];\n int counter = 0;\n while (res.next()) {\n \n jComboBoxpkl.addItem(res.getString(2));\n this.hasil2[counter++] = res.getString(1);\n }\n } catch(SQLException e) {\n \n }\n }", "public ResultSet MuestraMedicos() throws SQLException {\n\t\t\n\t\tString sql = \" SELECT * FROM medico \"; // sentencia busqueda cliente\n\t\ttry {\n\t\t\tconn = conexion.getConexion(); // nueva conexion a la bbdd CREARLO EN TODOS LOS METODOS\n\t\t\tst=(Statement) conn.createStatement();\n\t\t\tresultado = st.executeQuery(sql);\n\t\t\t/*\t\n\t\t\tst.close();\n\t\t\t\tconn.close();\n\t\t\t\t*/\n\t\t}\n\t\tcatch(SQLException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn resultado;\n\t}", "public void tampil_tb_mahasiswa(){\n Object []baris = {\"No Bp\",\"Nama\",\"Tempat Lahir\",\"Tanggal Lhair\",\"Jurusan\",\"Tanggal Masuk\"};\n tabmode = new DefaultTableModel(null, baris);\n //tb_mahasiswa.setModel(tabmode);\n try {\n Connection con = new koneksi().getConnection();\n String sql = \"select * from tb_mahasiswa order by no_bp asc\";\n java.sql.Statement stat = con.createStatement();\n java.sql.ResultSet hasil = stat.executeQuery(sql);\n while (hasil.next()){\n String no_bp = hasil.getString(\"no_bp\");\n String nama = hasil.getString(\"nama\");\n String tempat_lahir = hasil.getString(\"tempat_lahir\");\n String tanggal_lahir = hasil.getString(\"tanggal_lahir\");\n String jurusan = hasil.getString(\"jurusan\"); \n String tanggal_masuk = hasil.getString(\"tanggal_masuk\");\n String[] data = {no_bp, nama, tempat_lahir, tanggal_lahir, jurusan, tanggal_masuk};\n tabmode.addRow(data);\n }\n } catch (Exception e) {\n JOptionPane.showMessageDialog(null, \"Menampilkan data GAGAL\",\"Informasi\", JOptionPane.INFORMATION_MESSAGE);\n }\n }", "@SuppressWarnings(\"unchecked\")\n private void createTable(ArrayList<Object> objects){\n log.setText(\"\");\n if(!objects.isEmpty()) {\n ArrayList<String> list = new ArrayList<String>();\n int index = 0, row = 0, column = 0;\n for (Field field : objects.get(0).getClass().getDeclaredFields()) {\n list.add(field.getName());\n }\n String[] columnName = new String[list.size()];\n for(String s:list) {\n columnName[index] = s;\n index++;\n }\n Object data[][] = getData(objects, index);\n if(data.length != 0) {\n tableMode = new DefaultTableModel(data, columnName);\n }\n else {\n tableMode = null;\n }\n }\n else {\n tableMode = null;\n }\n }", "public void displayPatients() {\n DefaultTableModel dm = new DefaultTableModel(0, 0);\n String header[] = new String[]{\"\", \"Nom:\", \"Prénom:\", \"Dg:\", \"Séance:\", \"Date visit\"};\n dm.setColumnIdentifiers(header);\n jTable1.setModel(dm);\n\n \n \n //set the data in the table =>rows\n\n for (int i = 0; i < patients.size(); i++) {\n Patient patient = patients.get(i);\n\n Vector<Object> data = new Vector<Object>();\n data.add(patient.getId());\n data.add(patient.getNom());\n data.add(patient.getPrenom());\n data.add(patient.getDg());\n data.add(patient.getNombre_seance());\n data.add(patient.getDate_visit());\n dm.addRow(data);\n \n }\n }", "private String[] getColumas(){\n String columna[]={\"Tipo Usuario \",\"Nombre\",\"Empleado ID\",\"Asignar\"};\n return columna;\n }", "private void loadTable() {\n model.getDataVector().removeAllElements();\n model.fireTableDataChanged();\n try {\n String sql = \"select * from tb_mahasiswa\";\n Statement n = a.createStatement();\n ResultSet rs = n.executeQuery(sql);\n while (rs.next()) {\n Object[] o = new Object[6];\n o[0] = rs.getString(\"id_mahasiswa\");\n o[1] = rs.getString(\"nama\");\n o[2] = rs.getString(\"tempat\");\n o[3] = rs.getString(\"waktu\");\n o[4] = rs.getString(\"status\");\n model.addRow(o);\n }\n } catch (Exception e) {\n }\n }", "private void cargarTablaConPaquetes() {\n tcId.setCellValueFactory(\n new PropertyValueFactory<Paquete, String>(\"codigo\"));\n tcdescripcion.setCellValueFactory(\n new PropertyValueFactory<Paquete, String>(\"descripcion\"));\n tcDestino.setCellValueFactory(\n new PropertyValueFactory<Paquete, String>(\"destino\"));\n tcEntregado.setCellValueFactory(\n new PropertyValueFactory<Paquete, Boolean>(\"entregado\"));\n\n tbPaqueteria.setItems(data);\n tbPaqueteria.getSelectionModel().selectFirst();\n\n //TODO futura implementacion\n //setDobleClickFila();\n }", "private TableModel getTableModelProduto() {\n\t\tString[] columnNames = { \"cod_p\", \"cod_barra\", \"categoria\", \"descricao\", \"unidade\", \"custo\", \"marge_lucro\" };\n\n\t\tObject[][] data = new Object[listaP.size()][7];\n\t\tfor (int i = 0; i < listaP.size(); i++) {\n\t\t\tint j = 0;\n\t\t\tdata[i][j++] = Long.valueOf(listaP.get(i).getCod());\n\t\t\tdata[i][j++] = listaP.get(i).getCodBarra();\n\t\t\tdata[i][j++] = listaP.get(i).getCategoria();\n\t\t\tdata[i][j++] = listaP.get(i).getDescricao();\n\t\t\tdata[i][j++] = listaP.get(i).getUnidade();\n\t\t\tdata[i][j++] = listaP.get(i).getCusto();\n\t\t\tdata[i][j++] = listaP.get(i).getMargenLucro();\n\t\t}\n\t\treturn new DefaultTableModel(data, columnNames);\n\t}", "private void tablesice() {\n //Modificamos los tamaños de las columnas.\n tablastock.getColumnModel().getColumn(0).setMaxWidth(70);\n tablastock.getColumnModel().getColumn(1).setMaxWidth(70);\n tablastock.getColumnModel().getColumn(2).setMinWidth(100);\n tablastock.getColumnModel().getColumn(3).setMaxWidth(70);\n tablastock.getColumnModel().getColumn(4).setMaxWidth(70);\n tablastock.getColumnModel().getColumn(5).setMaxWidth(70);\n }", "private void initDatas(){\r\n \t\r\n \tjTable1.setModel(ViewUtil.transferBeanList2DefaultTableModel(discountService.getAllDiscountInfo(),\"Discount\"));\r\n }", "private JTable fontesNaoPagas() {\n\t\tinitConexao();\n\t\t\n try {\t \n\t String select = \"SELECT data_ultimo_vencimento_fonte_r, cod_fonte_d, nome_fonte_d, valor_fonte_d, tipo_valor_fonte_d, data_abertura_fonte_d, periodo_fonte_d FROM Fonte_despesa WHERE vencimento_fonte_d = '0'\";\n\t \n\t PreparedStatement ptStatement = c.prepareStatement(select);\n\t rs = ptStatement.executeQuery();\n\t \n\t Object[] colunas = {\"Fonte de despesa\", \"Valor previsto\", \"Data do vencimento\", \"\", \"code\"}; \t\t\n\t\t\t DefaultTableModel model = new DefaultTableModel();\t\t \n\t\t\t model.setColumnIdentifiers(colunas); \t\t \n\t\t\t Vector<Object[]> linhas = new Vector<Object[]>(); \n\t\t\t \n\t\t\t select = \"select DATE_ADD(?,INTERVAL ? day)\";\n\t while (rs.next()){\n\t \t \n\t \tptStatement = c.prepareStatement(select);\n\t\t\t\tptStatement.setString(1, rs.getString(\"data_ultimo_vencimento_fonte_r\"));\n\t\t\t\tptStatement.setString(2, rs.getString(\"periodo_fonte_d\"));\n\t\t\t\trs2 = ptStatement.executeQuery();\n\t\t\t\trs2.next();\n\t\t linhas.add(new Object[]{rs.getString(\"nome_fonte_d\"),rs.getString(\"valor_fonte_d\"),rs2.getString(1), \"Pagar\", rs.getString(\"cod_fonte_d\")}); \t \t\n\t \t } \n\t \n\t\t\t for (Object[] linha : linhas) { \n\t\t model.addRow(linha); \n\t\t } \t\t \n\t\t\t final JTable tarefasTable = new JTable(); \t\t \n\t\t\t tarefasTable.setModel(model); \t\t\n\t\t\t \n\t\t\t ButtonColumn buttonColumn = new ButtonColumn(tarefasTable, 3, \"fonteNaoPaga\");\n\t\t\t \n\t\t\t tarefasTable.removeColumn(tarefasTable.getColumn(\"code\")); \t \n\t return tarefasTable; \n } catch (SQLException ex) {\n System.out.println(\"ERRO: \" + ex);\n }\n\t\treturn null; \n\t}", "public void readTable() {\n DefaultTableModel modelo = (DefaultTableModel) jTable1.getModel();\n modelo.setRowCount(0);\n\n }", "private Object[][] getTableData() {\n Object[][] lclArray = null;\n\n if (articles.size() == 0) {\n lclArray = new Object[1][NUM_COLS];\n lclArray[0][0] = \"\";\n lclArray[0][1] = \"\";\n lclArray[0][2] = \"\";\n return lclArray;\n } // no articles yet !!!!\n if (articles != null) {\n lclArray = new Object[articles.size()][NUM_COLS];\n }\n for (int i = 0; i < articles.size(); i++) {\n NewsArticle article = (NewsArticle) articles.elementAt(i);\n\n lclArray[i][0] = article.getSubject();\n lclArray[i][1] = String.valueOf(article.getScore(filterType));\n lclArray[i][2] = article.getUserRating();\n }\n return lclArray;\n }" ]
[ "0.6705984", "0.66684717", "0.65930337", "0.6581462", "0.65084225", "0.6425018", "0.6315489", "0.6296194", "0.6290339", "0.62816066", "0.6242437", "0.6236452", "0.61885184", "0.6182548", "0.6174927", "0.61624455", "0.613631", "0.6135035", "0.6125637", "0.61239034", "0.61152637", "0.6108023", "0.6101786", "0.6096121", "0.6094688", "0.6088323", "0.6083037", "0.6071887", "0.6069681", "0.606429", "0.6061111", "0.60542846", "0.6046969", "0.6040155", "0.6038335", "0.6023512", "0.6016586", "0.60149527", "0.6004977", "0.60004437", "0.59976125", "0.59921205", "0.59540635", "0.5944068", "0.594031", "0.59356385", "0.5933788", "0.5928307", "0.59053296", "0.59022784", "0.5896281", "0.58959496", "0.58926004", "0.58795303", "0.5873157", "0.5871247", "0.5865855", "0.5859102", "0.584652", "0.5841472", "0.5841081", "0.5840454", "0.58397317", "0.5836048", "0.58331543", "0.583269", "0.58265", "0.581852", "0.58145946", "0.58099574", "0.58088547", "0.5807643", "0.58065915", "0.58049756", "0.58028775", "0.5801377", "0.5794235", "0.579168", "0.579078", "0.5790768", "0.57842696", "0.5782401", "0.5773279", "0.57718676", "0.5757924", "0.57493925", "0.57416844", "0.57312363", "0.5728287", "0.5726511", "0.5725743", "0.5722759", "0.5721063", "0.5718262", "0.57179415", "0.57145023", "0.5711349", "0.5708617", "0.5705882", "0.57031065", "0.57019734" ]
0.0
-1
Deleta medicamento da lista e do banco de dados
public void deletaMedicamento(Medicamento medicamento){ medicamentos.remove(medicamento); medicamentoFacade.deletarMedicamento(medicamento.getId()); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n\tpublic void imprimirBancoDados() {\n\t\tSystem.out.println(\"Nome do Banco: \"+nomeBanco);\n\t\tSystem.out.println(\"Tipo do Banco: \"+tipoBanco);\n\t\tSystem.out.println(\"Lista de Metodos: \"+listaMetodos);\n\t}", "public void Lista(){\n\t\tcabeza = null;\n\t\ttamanio = 0;\n\t}", "public List<Mobibus> darMobibus();", "private void caricaLista() {\n /** variabili e costanti locali di lavoro */\n ArrayList unaLista = null;\n CampoDati unCampoDati = null;\n CDBLinkato unCampoDBLinkato = null;\n //@todo da cancellare\n try { // prova ad eseguire il codice\n /* recupera il campo DB specializzato */\n unCampoDBLinkato = (CDBLinkato)unCampoParente.getCampoDB();\n\n /* recupera la lista dal campo DB */\n unaLista = unCampoDBLinkato.caricaLista();\n\n /* recupera il campo dati */\n unCampoDati = unCampoParente.getCampoDati();\n\n /* registra i valori nel modello dei dati del campo */\n if (unaLista != null) {\n unCampoDati.setValoriInterni(unaLista);\n// unCampoDatiElenco.regolaElementiAggiuntivi();\n } /* fine del blocco if */\n\n } catch (Exception unErrore) { // intercetta l'errore\n /* mostra il messaggio di errore */\n Errore.crea(unErrore);\n } /* fine del blocco try-catch */\n\n }", "private void listaContatos() throws SQLException {\n limpaCampos();\n BdLivro d = new BdLivro();\n livros = d.getLista(\"%\" + jTPesquisar.getText() + \"%\");\n\n // Após pesquisar os contatos, executa o método p/ exibir o resultado na tabela pesquisa\n mostraPesquisa(livros);\n livros.clear();\n }", "private void listaContatos() throws SQLException {\n limpaCampos();\n DAOLivro d = new DAOLivro();\n livros = d.getLista(\"%\" + jTPesquisar.getText() + \"%\"); \n \n // Após pesquisar os contatos, executa o método p/ exibir o resultado na tabela pesquisa\n mostraPesquisa(livros);\n livros.clear();\n }", "public void mostrarDados() {\n txtId.setText(\"\" + lista.get(indice).getId());\n txtNome.setText(lista.get(indice).getNome());\n txtEmail.setText(lista.get(indice).getEmail());\n txtSenha.setText(lista.get(indice).getSenha());\n preencheTabela();\n }", "private void setListaDelCommunication2(ArrayList lista) {\n this.getComunicationAccionSocialBean().setListaSolicitudesBeneficio(lista);\n }", "@Override\n\tprotected void doListado() throws Exception {\n\t\tList<Department> deptos = new DepartmentDAO().getAllWithManager();\n//\t\tList<Department> deptos = new DepartmentDAO().getAll();\n\t\tthis.addColumn(\"Codigo\").addColumn(\"Nombre\").addColumn(\"Manager\").newLine();\n\t\t\n\t\tfor(Department d: deptos){\n\t\t\taddColumn(d.getNumber());\n\t\t\taddColumn(d.getName());\n\t\t\taddColumn(d.getManager().getFullName());\n\t\t\tnewLine();\n\t\t}\n\t}", "public void listarEquipamentos() {\n \n \n List<Equipamento> formandos =new EquipamentoJpaController().findEquipamentoEntities();\n \n DefaultTableModel tbm=(DefaultTableModel) listadeEquipamento.getModel();\n \n for (int i = tbm.getRowCount()-1; i >= 0; i--) {\n tbm.removeRow(i);\n }\n int i=0;\n for (Equipamento f : formandos) {\n tbm.addRow(new String[1]);\n \n listadeEquipamento.setValueAt(f.getIdequipamento(), i, 0);\n listadeEquipamento.setValueAt(f.getEquipamento(), i, 1);\n \n i++;\n }\n \n \n \n }", "public void borrarListas() {\n\n\t\tthis.jugadoresEnMesa = new ArrayList<Jugador>();\n\t\tListaJugadores.jugadoresRetirados = new ArrayList<Jugador>();\n\n\t}", "public void cargaDeDatos(List<List<Object>> Musuarios,List<List<Object>> Mtareas, List<List<Object>> Mrequisitos) {\r\n\tfor (List<Object> l: Musuarios) {\r\n\t\tam.addMiembro(new MiembroDeEquipo((int)l.get(0),(String)l.get(1)));\r\n\t}\r\n\t/**\r\n\t * Cargamos a la lista de administrador de tareas todas las tareas que se encuentran en la base de datos, \r\n\t * si no tiene miembro se le pone a null sino se le añade un miembro.\r\n\t */\r\n\tfor (List<Object> l: Mtareas) {\r\n\t\tat.addTarea(new Tarea((String)l.get(0),(int)l.get(1),(int)l.get(2),(int)l.get(3),(int)l.get(6)));\r\n\t\t//Si tiene un miembro asignado (cualquier id mayor que cero) le añade el miembro de equipo, sino null\r\n\t\tif(0 < (int)l.get(5)) {\r\n\t\t\tat.BuscarTarea((int)l.get(1)).setAsignadoA(am.BuscarMiembro((int) l.get(5)));\r\n\t\t}else {\r\n\t\t\tat.BuscarTarea((int)l.get(1)).setAsignadoA(null);\r\n\t\t}\r\n\t\t//Si tiene un requisito (cualquier id maor que cero) le añade el requisito, sino null\r\n\t\tif(0 < (int)l.get(4)) {\r\n\t\t\tat.BuscarTarea((int)l.get(1)).setRequisito(ar.BuscarRequisito((int) l.get(4)));\r\n\t\t}else {\r\n\t\t\tat.BuscarTarea((int)l.get(1)).setRequisito(null);\r\n\t\t}\r\n\t\tat.BuscarTarea((int)l.get(1)).setDescripcion((String)l.get(7));\r\n\t}\r\n\t/**\r\n\t * Cargamos la lista del administrador de requisitos con todos los requisitos que tenemos,\r\n\t * si el requisito tiene 5 atributos, será un defecto, sino será una historia de usuario\r\n\t */\r\n\tfor (List<Object> l: Mrequisitos) {\r\n\t\tHashSet<Tarea> lista = new HashSet<Tarea>();\r\n\t\t//Buscamos todas las tareas que tengan este requisito, para tener una lista de las tareas que este tiene\r\n\t\tfor(List<Object> t: Mtareas) {\r\n\t\t\t\r\n\t\t\tif((int)l.get(2)==(int)t.get(4)) {\r\n\t\t\t\tlista.add(at.BuscarTarea((int)t.get(1)));\r\n\t\t\t}\r\n\t\t}\r\n\t\t//Creamos defecto o historiaDeUsuario, según sea el caso y lo añadimos a la lista generica de Requisitos.\r\n\t\tif(l.size()==5) {\r\n\t\t\tDefecto req = new Defecto((String)l.get(4),(String) l.get(0), (String)l.get(1),(int)l.get(2),lista);\r\n\t\t\tif((int)l.get(3)==1) {\r\n\t\t\treq.finalizar();\r\n\t\t\t}\r\n\t\t\tar.addRequisito(req);\r\n\t\t}else {\r\n\t\t\tRequisito req = new HistoriaDeUsuario((String) l.get(0), (String)l.get(1),(int)l.get(2));\r\n\t\t\tif(!lista.isEmpty()) {\r\n\t\t\t\treq.setRequisitos(lista);\r\n\t\t\t}\r\n\t\t\tif((int)l.get(3)==1) {\r\n\t\t\treq.finalizar();\r\n\t\t\t}\r\n\t\t\tar.addRequisito(req);\t\t\r\n\t\t}\r\n\t}\r\n\tfor (List<Object> l: Mtareas) {\r\n\t\t//Si tiene un requisito (cualquier id maor que cero) le añade el requisito, sino null\r\n\t\tif(0 < (int)l.get(4)) {\r\n\t\t\tat.BuscarTarea((int)l.get(1)).setRequisito(ar.BuscarRequisito((int) l.get(4)));\r\n\t\t}else {\r\n\t\t\tat.BuscarTarea((int)l.get(1)).setRequisito(null);\r\n\t\t}\r\n\t}\r\n}", "public static void deletarProdutos(){\n if(ListaDProduto.isEmpty()){\n SaidaDados(\"Nenhum produto cadastrado\");\n return;\n } \n ListaDProduto.clear();\n SaidaDados(\"Todos produto deletado com sucesso\");\n \n \n }", "public void Listar() {\n try {\n ApelacionesDao apelacionesDao = new ApelacionesDao();\n this.listaApelaciones.clear();\n setListaApelaciones(apelacionesDao.cargaApelaciones());\n } catch (ExceptionConnection ex) {\n Logger.getLogger(ApelacionController.class.getName()).log(Level.SEVERE, null, ex);\n }\n }", "protected List<List> cargarDatos() throws ExcArgumentoInvalido {\n\t\treturn null;\n\t}", "public void eliminarMateria() {\n ejbFacade.remove(materia);\n items = ejbFacade.findAll();\n RequestContext requestContext = RequestContext.getCurrentInstance();\n requestContext.update(\"MateriaListForm:datalist\");\n requestContext.execute(\"PF('Confirmacion').hide()\");\n departamento = new Departamento();\n materia = new Materia();\n FacesMessage msg = new FacesMessage(FacesMessage.SEVERITY_INFO, \"Información\", \"La materia se eliminó con éxito\");\n FacesContext.getCurrentInstance().addMessage(null, msg);\n\n requestContext.update(\"msg\");//Actualiza la etiqueta growl para que el mensaje pueda ser mostrado\n requestContext.update(\"MateriaListForm\");\n }", "private void getMuestras(){\n mMuestras = estudioAdapter.getListaMuestrasSinEnviar();\n //ca.close();\n }", "public void cargarDatos() {\n \n if(drogasIncautadoList==null){\n return;\n }\n \n \n \n List<Droga> datos = drogasIncautadoList;\n\n Object[][] matriz = new Object[datos.size()][4];\n \n for (int i = 0; i < datos.size(); i++) {\n \n \n //System.out.println(s[0]);\n \n matriz[i][0] = datos.get(i).getTipoDroga();\n matriz[i][1] = datos.get(i).getKgDroga();\n matriz[i][2] = datos.get(i).getQuetesDroga();\n matriz[i][3] = datos.get(i).getDescripcion();\n \n }\n Object[][] data = matriz;\n String[] cabecera = {\"Tipo Droga\",\"KG\", \"Quetes\", \"Descripción\"};\n dtm = new DefaultTableModel(data, cabecera);\n tableDatos.setModel(dtm);\n }", "public void desmarcarTodos() {\r\n\t\tfor (int i = 0; i < listaPlantaCargoDto.size(); i++) {\r\n\t\t\tPlantaCargoDetDTO p = new PlantaCargoDetDTO();\r\n\t\t\tp = listaPlantaCargoDto.get(i);\r\n\t\t\tp.setReservar(false);\r\n\t\t\tlistaPlantaCargoDto.set(i, p);\r\n\t\t}\r\n\t\tcantReservados = 0;\r\n\t}", "private void carregaLista() {\n listagem = (ListView) findViewById(R.id.lst_cadastrados);\n dbhelper = new DBHelper(this);\n UsuarioDAO dao = new UsuarioDAO(dbhelper);\n //Preenche a lista com os dados do banco\n List<Usuarios> usuarios = dao.buscaUsuarios();\n dbhelper.close();\n UsuarioAdapter adapter = new UsuarioAdapter(this, usuarios);\n listagem.setAdapter(adapter);\n }", "public void llenadoDeCombos() {\n PerfilDAO asignaciondao = new PerfilDAO();\n List<Perfil> asignacion = asignaciondao.listar();\n cbox_perfiles.addItem(\"\");\n for (int i = 0; i < asignacion.size(); i++) {\n cbox_perfiles.addItem(Integer.toString(asignacion.get(i).getPk_id_perfil()));\n }\n \n }", "List<ParqueaderoEntidad> listar();", "public ListaDuplamenteEncadeada(){\r\n\t\t\r\n\t}", "public void datosBundle()\n {\n //creamos un Bundle para recibir los datos de MascotasFavoritas al presionar el boton de atras en la ActionBar\n Bundle datosBundleAtras = getActivity().getIntent().getExtras();\n //preguntamos si este objeto viene con datos o esta vacio\n if(datosBundleAtras!=null)\n {//si hay datos estos se los agregamos a un ArrayList de mascotas\n mascotas = (ArrayList<Mascota>) datosBundleAtras.getSerializable(\"listamascotasatras\");\n }else{\n //si el bundle No trae datos entonces se inicializara la lista con datos\n validarBundle=1;\n //return;\n }\n }", "public void domicilioElimina(){\r\n\t\tlog.info(\"DomicilioElimina()\");\r\n\t\tfor (int i = 0; i < DomicilioPersonaList.size(); i++) { \t\t\r\n\t \tlog.info(\"\"+DomicilioPersonaList.get(i).getItem()+\" ,idd \"+getIdd() +\" \"+DomicilioPersonaList.get(i).getDomicilio());\r\n\r\n\t\tif((DomicilioPersonaList.get(i).getIddomiciliopersona()== 0 || DomicilioPersonaList.get(i).getIddomiciliopersona()== null) && DomicilioPersonaList.get(i).getItem()==\"Por Agregar\"){\r\n\t\t\tlog.info(\"N2----> DomicilioPersonaList.get(i).getIddomiciliopersona()\" +\" \" +DomicilioPersonaList.get(i).getIddomiciliopersona());\r\n\t\t\tDomicilioPersonaSie domtemp = new DomicilioPersonaSie();\r\n\t\t\tdomtemp.setIddomiciliopersona(idd);\r\n\t\t\tDomicilioPersonaList.remove(domtemp);\r\n\t\tfor (int j = i; j < DomicilioPersonaList.size(); j++) {\r\n\t\t\tlog.info(\" i \" +i+\" j \"+ j);\r\n\t\t\ti=i+1;\r\n\t\t\tDomicilioPersonaList.set(j, DomicilioPersonaList.get(j));\r\n\t\t}break;\r\n\t\t}\r\n\t\telse if(DomicilioPersonaList.get(i).getIddomiciliopersona() ==(getIdd()) && DomicilioPersonaList.get(i).getItem()==\"Agregado\"){\r\n\t\t\tlog.info(\"ALERTA WDFFFF\");\r\n\t\t\tDomicilioPersonaSie obj = new DomicilioPersonaSie();\r\n\t\t\tobj.setIddomiciliopersona(idd);\r\n\t\t\tlog.info(\"DENTRO LISTA DESHABILITADO\");\r\n\t\t\tDomicilioPersonaDeshabilitado.add(obj);\t\r\n\t\t\tFaceMessage.FaceMessageError(\"ALERTA\", \"Los Cambios se realizaran despues de hacer clic en el boton Guardar\");\t\t\t\r\n//\t\t\tmsg = new FacesMessage(FacesMessage.SEVERITY_WARN,\r\n//\t\t\tConstants.MESSAGE_ERROR_TELEFONO_CLIENTE,mensaje);\r\n//\t\t\tFacesContext.getCurrentInstance().addMessage(null, msg);\t\t\t\t\r\n\t\t\t}\r\n\t\t}\r\n\t}", "public List<Filme> listar() {\r\n\r\n //Pegando o gerenciador de acesso ao BD\r\n EntityManager gerenciador = JPAUtil.getGerenciador();\r\n\r\n //Criando a consulta ao BD\r\n TypedQuery consulta = gerenciador.createQuery(\r\n \"Select f from Filme f\", Filme.class);\r\n\r\n //Retornar a lista de atores\r\n return consulta.getResultList();\r\n\r\n }", "@Override\n\tpublic List<DescontoBeneficiario> listarDescontos() {\n\t\treturn null;\n\t}", "public List<EntradaDeMaterial> buscarEntradasDisponibles();", "public List<Listas_de_las_Solicitudes> Mostrar_las_peticiones_que_han_llegado_al_Usuario_Administrador(int cedula) {\n\t\t//paso3: Obtener el listado de peticiones realizadas por el usuario\n\t\tEntityManagerFactory entitymanagerfactory = Persistence.createEntityManagerFactory(\"LeyTransparencia\");\n\t\tEntityManager entitymanager = entitymanagerfactory.createEntityManager();\n\t\tentitymanager.getEntityManagerFactory().getCache().evictAll();\n\t\tQuery consulta4=entitymanager.createQuery(\"SELECT g FROM Gestionador g WHERE g.cedulaGestionador =\"+cedula);\n\t\tGestionador Gestionador=(Gestionador) consulta4.getSingleResult();\n\t\t//paso4: Obtener por peticion la id, fecha y el estado\n\t\tList<Peticion> peticion=Gestionador.getEmpresa().getPeticions();\n\t\tList<Listas_de_las_Solicitudes> peticion2 = new ArrayList();\n\t\t//paso5: buscar el area de cada peticion\n\t\tfor(int i=0;i<peticion.size();i++){\n\t\t\tString almcena=\"\";\n\t\t\tString sarea=\"no posee\";\n\t\t\tBufferedReader in;\n\t\t\ttry{\n\t\t\t\tin = new BufferedReader(new InputStreamReader(new FileInputStream(\"C:/area/area\"+String.valueOf(peticion.get(i).getIdPeticion())+\".txt\"), \"utf-8\"));\n\t\t\t\ttry {\n\t\t\t\t\twhile((sarea=in.readLine())!=null){\n\t\t\t\t\t\tint s=0;\n\t\t\t\t\t\talmcena=sarea;\n\t\t\t\t\t}\n\t\t\t\t\tin.close();\n\t\t\t\t\tSystem.out.println(almcena);\n\t\t\t\t} catch (IOException e) {\n\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\n\t\t\t} catch (UnsupportedEncodingException e) {\n\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\te.printStackTrace();\n\t\t\t} catch (FileNotFoundException e) {\n\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t\t\n\t\t\t//paso6: Mostrar un listado de peticiones observando el id, la fecha de realizacion de la peticion, hora de realizacion de la peticion, y el estado actual de la peticion\n\t\t\tListas_de_las_Solicitudes agregar=new Listas_de_las_Solicitudes();\n\t\t\tagregar.setId(String.valueOf(peticion.get(i).getIdPeticion()));\n\t\t\tagregar.setFechaPeticion(peticion.get(i).getFechaPeticion());\n\t\t\tagregar.setNombreestado(peticion.get(i).getEstado().getTipoEstado());\n\t\t\tagregar.setArea(almcena);\n\t\t\tpeticion2.add(agregar);\n\t\t\t\n\t\t\t\n\t\t}\n\t\tSystem.out.println(\"el usuario existe\");\n\t\treturn peticion2;\n\t\t//aun no se\n\t}", "private void setListaDelCommunication(ArrayList lista) {\n this.getComunicationAccionSocialBean().setListaGrupoFamiliar(lista);\n }", "private void populateFields() {\n pedidos = pdao.listaTodos();\n cCliente = new HashSet();\n cEstado = new HashSet();\n cCidade = new HashSet();\n cFornecedor = new HashSet();\n\n for (int i = 0; i < pedidos.size(); i++) {\n cCliente.add(pedidos.get(i).getCliente().getNome());\n cEstado.add(pedidos.get(i).getCliente().getEstado());\n cCidade.add(pedidos.get(i).getCliente().getCidade());\n for (int j = 0; j < pedidos.get(i).getItens().size(); j++) {\n cFornecedor.add(pedidos.get(i).getItens().get(j).getProduto().getFornecedor().getNome());\n }\n }\n\n clientes = new ArrayList<>(cCliente);\n fornecedores = new ArrayList<>(cFornecedor);\n\n Iterator i = cCliente.iterator();\n while (i.hasNext()) {\n jCBCliente.addItem(i.next());\n }\n\n i = null;\n i = cEstado.iterator();\n while (i.hasNext()) {\n jCBEstado.addItem(i.next());\n }\n\n i = null;\n i = cCidade.iterator();\n while (i.hasNext()) {\n jCBCidade.addItem(i.next());\n }\n i = null;\n i = cFornecedor.iterator();\n while (i.hasNext()) {\n jCBFornecedor.addItem(i.next());\n }\n\n }", "@Override\r\n\tpublic List<CommandeDistri> offre(List<CommandeDistri> list) {\n\t\treturn null;\r\n\t}", "public void recebeDados(\n\tList<NotasFaltasModel> lista, String nome, String curso) {\n\t\tDefaultTableModel modelo = (DefaultTableModel) tbBoletim.getModel();\n\t\tlblNome.setText(nome);\n\t\tlblCurso.setText(curso);\n\t\t\n\tfor(NotasFaltasModel boletimAluno : lista) {\n\t\t\tmodelo.addRow(new Object[] {\n\t\t\t\tboletimAluno.getDisciplina(),\n\t\t\t\tboletimAluno.getNota(),\n\t\t\t\tboletimAluno.getFaltas()\n\t\t\t});\n\t\t}\n\t}", "@SuppressWarnings(\"unchecked\")\r\n\tprotected List<List> cargarDatos() throws ExcArgumentoInvalido {\n\t\treturn null;\r\n\t}", "void listarDadosNaTelaColaborador(ArrayList<Colaborador> lista,DefaultTableModel model ) {\n model.setNumRows(0);\n //Correr o ArrayList\n for (int pos = 0; pos < lista.size(); pos++) {\n String[] linha = new String[9];\n Colaborador aux = lista.get(pos);\n linha[0] = \"\"+aux.getId();\n linha[1] = \"\"+aux.getMatricula();\n linha[2] = aux.getNome();\n linha[3] = \"\"+aux.getNumeroOAB();\n linha[4] = \"\"+aux.getCpf();\n linha[5] = aux.getEmail();\n linha[6] = \"\"+aux.getTelefone();\n linha[7] = aux.getTipo().toString();\n linha[8] = aux.getStatus().toString();\n model.addRow(linha);\n }\n }", "@Override\n\tpublic ArrayList<MODEL.Medicamento> getlista() {\n\t\treturn null;\n\t}", "private void carregarAgendamentos() {\n agendamentos.clear();\n\n // Carregar os agendamentos do banco de dados\n agendamentos = new AgendamentoDAO(this).select();\n\n // Atualizar a lista\n setupRecyclerView();\n }", "public void limpiarDatos() {\r\n FormularioUtil.limpiarComponentes(groupboxEditar, idsExcluyentes);\r\n tbxNro_identificacion.setValue(\"\");\r\n tbxNro_identificacion.setDisabled(false);\r\n deshabilitarCampos(true);\r\n\r\n }", "public ArrayList<Mascota> obtenerDatos(){\n\n BaseDatos db = new BaseDatos(context);\n\n ArrayList<Mascota> aux = db.obtenerTodoslosContactos();\n\n if(aux.size()==0){\n insertarMascotas(db);\n aux = db.obtenerTodoslosContactos();\n }\n\n return aux;\n }", "private void listar() throws Exception{\n int resId=1;\n List<PlatoDia> lista = this.servicioRestaurante.listarMenuDia(resId);\n this.modelListEspecial.clear();\n lista.forEach(lse -> {\n this.modelListEspecial.addElement(\"ID: \" + lse.getId() \n + \" NOMBRE: \" + lse.getNombre()\n + \" DESCRIPCION: \" + lse.getDescripcion()\n + \" PRECIO: \" + lse.getPrecio()\n + \" ENTRADA: \"+lse.getEntrada() \n + \" PRINCIPIO: \"+lse.getPrincipio()\n + \" CARNE: \"+lse.getCarne()\n + \" BEBIDA: \"+lse.getBebida()\n + \" DIA: \"+lse.getDiaSemana());\n });\n }", "@Override\r\n public List<Assunto> buscarTodas() {\r\n EntityManager em = PersistenceUtil.getEntityManager();\r\n Query query = em.createQuery(\"FROM Assunto As a\");\r\n return query.getResultList();\r\n }", "@Override\n\tpublic List<Materia> recuperarTodo() throws DataAccessException {\n\t\treturn null;\n\t}", "public void MostrarListaInicioFin() {\n if(!estVacia()){\n String datos=\"<=>\";\n NodoDoble current=inicio;\n while(current!=null){\n datos += \"[\"+current.dato+\"]<=>\";\n current = current.siguiente;\n }\n JOptionPane.showMessageDialog(null, datos, \"Mostrando Lista de inicio a Fin\",JOptionPane.INFORMATION_MESSAGE);\n }\n }", "public ListaDE() {\n\n\t\tprimero = ultimo = null;\n\t\ttotal = 0;\n\n\t}", "@Override\r\n\tpublic ArrayList<TransferUsuario> buscarDesarroladorDescuento(int descuento) {\n Transaction transaccion= TransactionManager.getInstance().nuevaTransaccion();\r\n transaccion.start();\r\n\t\t\r\n //Obtenemos el DAO\r\n \r\n Query query = factoriaQuery.getInstance().getQuery(Eventos.QUERY_DESARROLLADOR);\t\t \r\n ArrayList<TransferUsuario> ret= (ArrayList<TransferUsuario>) query.execute(descuento);\r\n \r\n TransactionManager.getInstance().eliminarTransaccion();\r\n \r\n return ret;\r\n\t}", "@Override\n\tpublic void mostrarDados() {\n\t\t\n\t}", "public void mostrarlistafininicio(){\n if(!estavacia()){\n String datos=\"<=>\";\n nododoble auxiliar=fin;\n while(auxiliar!=null){\n datos=datos+\"[\"+auxiliar.dato+\"]<=>\";\n auxiliar=auxiliar.anterior;\n }\n JOptionPane.showMessageDialog(null,datos,\n \"Mostraando lista de fin a inicio\",JOptionPane.INFORMATION_MESSAGE);\n }}", "public void chargeListe(){\n jCbListeEtablissement.removeAllItems();\n String sReq = \"From Etablissement\";\n Query q = jfPrincipal.getSession().createQuery(sReq);\n Iterator eta = q.iterate();\n while(eta.hasNext())\n {\n Etablissement unEtablissement = (Etablissement) eta.next();\n jCbListeEtablissement.addItem(unEtablissement.getEtaNom());\n }\n bChargeListe = true;\n }", "public void listadoCarreras() {\r\n try {\r\n this.sessionProyecto.getCarreras().clear();\r\n this.sessionProyecto.getFilterCarreras().clear();\r\n this.sessionProyecto.getCarreras().addAll(sessionUsuarioCarrera.getCarreras());\r\n this.sessionProyecto.setFilterCarreras(this.sessionProyecto.getCarreras());\r\n } catch (Exception e) {\r\n }\r\n }", "protected void exibirMedicos(){\n System.out.println(\"--- MEDICOS CADASTRADOS ----\");\r\n String comando = \"select * from medico order by id\";\r\n ResultSet rs = cb.buscaDados(comando);\r\n try{\r\n while(rs.next()){\r\n int id = rs.getInt(\"id\");\r\n String nome = rs.getString(\"nome\");\r\n System.out.println(\"[\"+id+\"] \"+nome);\r\n }\r\n }\r\n catch (Exception e){\r\n e.printStackTrace();\r\n }\r\n }", "private void listarDadosNaTelaEditora(ArrayList<Editora> lista) {\n DefaultTableModel modelEditoras = (DefaultTableModel) jTable_tabelaEditoras.getModel();\n jTable_tabelaEditoras.setRowSorter(new TableRowSorter(modelEditoras));\n //Limpando a tela\n modelEditoras.setNumRows(0);\n //Correr o ArrayList\n for (int pos = 0; pos < lista.size(); pos++) {\n String[] linha = new String[2];\n Editora aux = lista.get(pos);\n linha[0] = \"\"+aux.getId();\n linha[1] = aux.getNome();\n modelEditoras.addRow(linha);\n }\n }", "private void listarEntidades() {\r\n\t\tsetListEntidades(new ArrayList<EntidadDTO>());\r\n\t\tgetListEntidades().addAll(entidadController.encontrarTodos());\r\n\t\tif (!getListEntidades().isEmpty()) {\r\n\t\t\tfor (EntidadDTO entidadDTO : getListEntidades()) {\r\n\t\t\t\t// Conversión de decimales.\r\n\t\t\t\tDouble porcentaje = entidadDTO.getPorcentajeValorAsegurable() * 100;\r\n\t\t\t\tdouble por = Math.round(porcentaje * Math.pow(10, 2)) / Math.pow(10, 2);\r\n\t\t\t\tentidadDTO.setPorcentajeValorAsegurable(por);\r\n\t\t\t}\r\n\t\t}\r\n\t}", "@SuppressWarnings(\"unchecked\")\r\n\tpublic List<ItemMedicamentoEntity> listaTodos(){\r\n\r\n\t\treturn this.entityManager.createQuery(\"SELECT * FROM ItemMedicamentoEntity ORDER BY codigo\").getResultList();\r\n\t}", "public void listarutilizador() {\n \n \n List<Utilizador> cs =new UtilizadorJpaController().findUtilizadorEntities();\n \n DefaultTableModel tbm=(DefaultTableModel) listadeutilizador.getModel();\n \n for (int i = tbm.getRowCount()-1; i >= 0; i--) {\n tbm.removeRow(i);\n }\n int i=0;\n for (Utilizador c : cs) {\n tbm.addRow(new String[1]);\n listadeutilizador.setValueAt(c.getIdutilizador(), i, 0);\n listadeutilizador.setValueAt(c.getNome(), i, 1);\n listadeutilizador.setValueAt(c.getUtilizador(), i, 2);\n listadeutilizador.setValueAt(c.getIdprevilegio().getPrevilegio(), i, 3);\n// listaderelatorio.setValueAt(f.getTotal(), i, 4);\n// Distrito di = new DistritoJpaController().getDistritoByLoc(f.getIdlocalidade());\n// Localidade lo = new LocalidadeJpaController().findLocalidade(f.getIdlocalidade());\n// listaderelatorio.setValueAt(di.getDistrito(), i, 0);//lo.getIdposto().getIddistrito().getDistrito(), i, 0);\n// listaderelatorio.setValueAt(lo.getLocalidade(), i, 1);\n \n//// listadeformando.setValueAt(f.getSexo(), i, 2);\n// listaderelatorio.setValueAt(f.getQhomem(), i, 2);\n// listaderelatorio.setValueAt(f.getQmulher(), i, 3);\n// listaderelatorio.setValueAt(f.getTotal(), i, 4);\n// \n// \n i++;\n }\n \n \n \n }", "@Test\n public void deberiaMostrarListaDeCtaMayor() {\n log.debug(\"Debiera mostrar lista de ctaMayor\");\n Ejercicio ejercicio = new Ejercicio(\"test\", \"A\");\n currentSession().save(ejercicio);\n assertNotNull(ejercicio);\n log.debug(\"ejercicio >>\" + ejercicio);\n for (int i = 0; i < 20; i++) {\n CuentaMayor ctaMayor = new CuentaMayor(\"test\" + i, \"test\");\n currentSession().save(ctaMayor);\n assertNotNull(ctaMayor);\n log.debug(\"ctaMayor>>\" + ctaMayor);\n }\n\n Map<String, Object> params = null;\n Map result = instance.lista(params);\n assertNotNull(result.get(\"ctaMayores\"));\n assertNotNull(result.get(\"cantidad\"));\n\n assertEquals(10, ((List<Empresa>) result.get(\"ctaMayores\")).size());\n assertEquals(20, ((Long) result.get(\"cantidad\")).intValue());\n }", "@Override\r\n\tpublic List<CommandeDistri> Offre(List<CommandeDistri> o) {\n\t\treturn null;\r\n\t}", "public void MostrarListas (){\n Nodo recorrer=inicio; // esto sirve para que el elemento de la lista vaya recorriendo conforme se inserta un elemento\r\n System.out.println(); // esto nos sirve para dar espacio a la codificacion de la lista al imprimir \r\n while (recorrer!=null){ // esta secuencia iterativa nos sirve para repetir las opciones del menu\r\n System.out.print(\"[\" + recorrer.dato +\"]--->\");\r\n recorrer=recorrer.siguiente;\r\n }\r\n }", "public List<DadosDiariosVO> validaSelecionaAcumuladoDadosDiarios(String ano) {\n\n\t\tList<DadosDiariosVO> listaDadosDiarios = validaSelecionaDetalhesDadosDiarios(ano);\n\n\t\tList<DadosDiariosVO> listaFiltradaDadosDiarios = new ArrayList<DadosDiariosVO>();\n\t\tList<DadosDiariosVO> listaFaturamentoDiario = new ArrayList<DadosDiariosVO>();\n\t\tList<DadosDiariosVO> listaFaturamentoAcumulado = new ArrayList<DadosDiariosVO>();\n\n\t\t/* Ordena a lista em EMITIDOS;EMITIDOS CANCELADOS;EMITIDOS RESTITUIDOS */\n\n\t\tfor (int i = 0; i < listaDadosDiarios.size(); i++) {\n\t\t\tString dataParaComparacao = listaDadosDiarios.get(i).getAnoMesDia();\n\n\t\t\tfor (int j = 0; j < listaDadosDiarios.size(); j++) {\n\n\t\t\t\tif (dataParaComparacao.equals(listaDadosDiarios.get(j).getAnoMesDia())) {\n\t\t\t\t\tDadosDiariosVO dados = new DadosDiariosVO();\n\t\t\t\t\tdados.setAnoMesDia(listaDadosDiarios.get(j).getAnoMesDia());\n\t\t\t\t\tdados.setProduto(listaDadosDiarios.get(j).getProduto());\n\t\t\t\t\tdados.setTipo(listaDadosDiarios.get(j).getTipo());\n\t\t\t\t\tdados.setValorDoDia(listaDadosDiarios.get(j).getValorDoDia());\n\n\t\t\t\t\tlistaFiltradaDadosDiarios.add(dados);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\touter: for (int i = listaFiltradaDadosDiarios.size() - 1; i >= 0; i--) {\n\t\t\tfor (int j = 0; j < listaFiltradaDadosDiarios.size(); j++) {\n\t\t\t\tif (listaFiltradaDadosDiarios.get(i).getAnoMesDia()\n\t\t\t\t\t\t.equalsIgnoreCase(listaFiltradaDadosDiarios.get(j).getAnoMesDia())\n\t\t\t\t\t\t&& listaFiltradaDadosDiarios.get(i).getProduto()\n\t\t\t\t\t\t\t\t.equalsIgnoreCase(listaFiltradaDadosDiarios.get(j).getProduto())\n\t\t\t\t\t\t&& listaFiltradaDadosDiarios.get(i).getTipo()\n\t\t\t\t\t\t\t\t.equalsIgnoreCase(listaFiltradaDadosDiarios.get(j).getTipo())\n\t\t\t\t\t\t&& listaFiltradaDadosDiarios.get(i).getValorDoDia()\n\t\t\t\t\t\t\t\t.equalsIgnoreCase(listaFiltradaDadosDiarios.get(j).getValorDoDia())) {\n\t\t\t\t\tif (i != j) {\n\n\t\t\t\t\t\tlistaFiltradaDadosDiarios.remove(i);\n\t\t\t\t\t\tcontinue outer;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t/* Ordena por data */\n\t\tCollections.sort(listaFiltradaDadosDiarios, DadosDiariosVO.anoMesDiaCoparator);\n\n\t\tString dataTemp = \"\";\n\t\tBigDecimal somaAcumulada = new BigDecimal(\"0.0\");\n\n\t\t/* abaixo a visao da faturamento de cada dia */\n\t\tDadosDiariosVO faturamentoDiario = new DadosDiariosVO();\n\n\t\ttry {\n\n\t\t\tfor (int i = 0; i <= listaFiltradaDadosDiarios.size(); i++) {\n\n\t\t\t\tif (i == 0) {\n\t\t\t\t\tdataTemp = listaFiltradaDadosDiarios.get(i).getAnoMesDia();\n\n\t\t\t\t\tfaturamentoDiario.setAnoMesDia(listaFiltradaDadosDiarios.get(i).getAnoMesDia());\n\t\t\t\t\tfaturamentoDiario.setProduto(listaFiltradaDadosDiarios.get(i).getProduto());\n\t\t\t\t\tfaturamentoDiario.setTipo(\"FATURAMENTO\");\n\t\t\t\t}\n\n\t\t\t\tif ((i != listaFiltradaDadosDiarios.size())\n\t\t\t\t\t\t&& dataTemp.equals(listaFiltradaDadosDiarios.get(i).getAnoMesDia())) {\n\n\t\t\t\t\tsomaAcumulada = new BigDecimal(listaFiltradaDadosDiarios.get(i).getValorDoDia()).add(somaAcumulada);\n\n\t\t\t\t} else {\n\t\t\t\t\tif (listaFiltradaDadosDiarios.size() == i) {\n\t\t\t\t\t\tfaturamentoDiario.setValorDoDia(somaAcumulada.toString());\n\t\t\t\t\t\tlistaFaturamentoDiario.add(faturamentoDiario);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t} else {\n\t\t\t\t\t\tfaturamentoDiario.setValorDoDia(somaAcumulada.toString());\n\t\t\t\t\t\tlistaFaturamentoDiario.add(faturamentoDiario);\n\t\t\t\t\t}\n\n\t\t\t\t\tdataTemp = listaFiltradaDadosDiarios.get(i).getAnoMesDia();\n\t\t\t\t\tsomaAcumulada = new BigDecimal(listaFiltradaDadosDiarios.get(i).getValorDoDia());\n\n\t\t\t\t\tfaturamentoDiario = new DadosDiariosVO();\n\t\t\t\t\tfaturamentoDiario.setAnoMesDia(listaFiltradaDadosDiarios.get(i).getAnoMesDia());\n\t\t\t\t\tfaturamentoDiario.setProduto(listaFiltradaDadosDiarios.get(i).getProduto());\n\t\t\t\t\tfaturamentoDiario.setTipo(\"FATURAMENTO\");\n\t\t\t\t}\n\t\t\t}\n\t\t} catch (IndexOutOfBoundsException ioobe) {\n\t\t\tSystem.err.println(\n\t\t\t\t\t\"VisãoExecutiva_Diaria_BO - método validaSelecionaAcumuladoDadosDiarios - adicionando dados fictícios...\");\n\t\t\tDadosDiariosVO dados = new DadosDiariosVO();\n\t\t\tdados.setAnoMesDia(\"2015-10-02\");\n\t\t\tdados.setProduto(\"TESTE\");\n\t\t\tdados.setTipo(\"FATURAMENTO\");\n\t\t\tdados.setValorDoDia(\"0.0\");\n\t\t\tlistaFaturamentoDiario.add(dados);\n\t\t\tSystem.err.println(\"... dados inseridos\");\n\t\t}\n\n\t\t/* abaixo construimos a visao acumulada */\n\t\tBigDecimal somaAnterior = new BigDecimal(\"0.0\");\n\t\tint quantidadeDias = 0;\n\t\tfor (int i = 0; i < listaFaturamentoDiario.size(); i++) {\n\n\t\t\tDadosDiariosVO faturamentoDiarioAcumulado = new DadosDiariosVO();\n\t\t\tif (i == 0) {\n\t\t\t\tfaturamentoDiarioAcumulado.setAnoMesDia(listaFaturamentoDiario.get(i).getAnoMesDia());\n\t\t\t\tfaturamentoDiarioAcumulado.setProduto(listaFaturamentoDiario.get(i).getProduto());\n\t\t\t\tfaturamentoDiarioAcumulado.setTipo(listaFaturamentoDiario.get(i).getTipo());\n\t\t\t\tfaturamentoDiarioAcumulado.setValorDoDia(listaFaturamentoDiario.get(i).getValorDoDia());\n\n\t\t\t\tsomaAnterior = somaAnterior.add(new BigDecimal(listaFaturamentoDiario.get(i).getValorDoDia()));\n\t\t\t\tquantidadeDias++;\n\t\t\t\tlistaFaturamentoAcumulado.add(faturamentoDiarioAcumulado);\n\n\t\t\t} else {\n\t\t\t\tfaturamentoDiarioAcumulado.setAnoMesDia(listaFaturamentoDiario.get(i).getAnoMesDia());\n\t\t\t\tfaturamentoDiarioAcumulado.setProduto(listaFaturamentoDiario.get(i).getProduto());\n\t\t\t\tfaturamentoDiarioAcumulado.setTipo(listaFaturamentoDiario.get(i).getTipo());\n\t\t\t\tfaturamentoDiarioAcumulado.setValorDoDia(\n\t\t\t\t\t\tsomaAnterior.add(new BigDecimal(listaFaturamentoDiario.get(i).getValorDoDia())).toString());\n\n\t\t\t\tsomaAnterior = somaAnterior.add(new BigDecimal(listaFaturamentoDiario.get(i).getValorDoDia()));\n\t\t\t\tquantidadeDias++;\n\t\t\t\tlistaFaturamentoAcumulado.add(faturamentoDiarioAcumulado);\n\t\t\t}\n\t\t}\n\n\t\tUteis uteis = new Uteis();\n\t\tString dataAtualSistema = new SimpleDateFormat(\"dd/MM/yyyy\").format(new Date(System.currentTimeMillis()));\n\t\tString dataCut[] = dataAtualSistema.split(\"/\");\n\t\tString mes_SO;\n\t\tmes_SO = dataCut[1];\n\n\t\t/* BP */\n\t\tList<FaturamentoVO> listaBP = dadosFaturamentoDetalhado;\n\t\tint mes_SO_int = Integer.parseInt(mes_SO);\n\t\tString bpMes = listaBP.get(0).getMeses()[mes_SO_int - 1];\n\t\tint diasUteis = uteis.retornaDiasUteisMes(mes_SO_int - 1);\n\t\tBigDecimal bpPorDia = new BigDecimal(bpMes).divide(new BigDecimal(diasUteis), 6, RoundingMode.HALF_DOWN);\n\n\t\tBigDecimal somaAnteriorBp = new BigDecimal(\"0.0\");\n\t\tfor (int i = 0; i < quantidadeDias; i++) {\n\t\t\tDadosDiariosVO faturamentoDiarioAcumulado = new DadosDiariosVO();\n\t\t\tif (i == 0) {\n\t\t\t\tfaturamentoDiarioAcumulado.setAnoMesDia(listaFaturamentoAcumulado.get(i).getAnoMesDia());\n\t\t\t\tfaturamentoDiarioAcumulado.setProduto(listaFaturamentoAcumulado.get(i).getProduto());\n\t\t\t\tfaturamentoDiarioAcumulado.setTipo(\"BP\");\n\t\t\t\tfaturamentoDiarioAcumulado.setValorDoDia(bpPorDia.toString());\n\n\t\t\t\tsomaAnteriorBp = somaAnteriorBp.add(bpPorDia);\n\t\t\t\tlistaFaturamentoAcumulado.add(faturamentoDiarioAcumulado);\n\n\t\t\t} else {\n\t\t\t\tfaturamentoDiarioAcumulado.setAnoMesDia(listaFaturamentoAcumulado.get(i).getAnoMesDia());\n\t\t\t\tfaturamentoDiarioAcumulado.setProduto(listaFaturamentoAcumulado.get(i).getProduto());\n\t\t\t\tfaturamentoDiarioAcumulado.setTipo(\"BP\");\n\n\t\t\t\tsomaAnteriorBp = somaAnteriorBp.add(bpPorDia);\n\n\t\t\t\tfaturamentoDiarioAcumulado.setValorDoDia(somaAnteriorBp.toString());\n\n\t\t\t\tlistaFaturamentoAcumulado.add(faturamentoDiarioAcumulado);\n\t\t\t}\n\t\t}\n\n\t\treturn listaFaturamentoAcumulado;\n\t}", "@Override\n\tpublic List<AlmacenDTO> listarEntrada() {\n\t\tList<AlmacenDTO> data = new ArrayList<AlmacenDTO>();\n\t\tAlmacenDTO obj = null;\n\t\tConnection cn = null;\n\t\tPreparedStatement pstm = null;\n\t\tResultSet rs = null;\n\t\ttry {\n\t\t\tcn = new MySqlDbConexion().getConexion();\n\t\t\tString sql = \"select me.codigo_entrada,p.nombre_producto,me.cantidad_entrada,me.fecha_entrada\\r\\n\" + \n\t\t\t\t\t\"from material_entrada me inner join producto p on me.codigo_producto=p.codigo_producto\";\n\n\t\t\tpstm = cn.prepareStatement(sql);\n\t\t\trs = pstm.executeQuery();\n\t\t\twhile (rs.next()) {\n\t\t\t\tobj = new AlmacenDTO();\n\t\t\t\tobj.setCodigo_entrada(rs.getInt(1));\n\t\t\t\tobj.setNombre_producto(rs.getString(2));\n\t\t\t\tobj.setCantidad_entrada(rs.getInt(3));\n\t\t\t\tobj.setFecha_entrada(rs.getDate(4));\n\n\t\t\t\tdata.add(obj);\n\n\t\t\t}\n\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t}\n\n\t\treturn data;\n\t}", "public List<NumeroMega> listar() {\n List<NumeroMega> lista = new ArrayList<NumeroMega>();\n\n // Definicao da instrucao SQL\n String sql = \"Select NumeroMega from \" +TABELA+ \" order by id\";\n\n // Objeto que recebe os registros do banco de dados\n Cursor cursor = getReadableDatabase().rawQuery(sql, null);\n\n try {\n while (cursor.moveToNext()) {\n // Criacao de nova referencia\n NumeroMega numeroMega = new NumeroMega();\n // Carregar os atributos com dados do BD\n\n numeroMega.setNumeroMega(cursor.getString(0));\n\n // Adicionar novo a lista\n lista.add(numeroMega);\n }\n } catch (SQLException e) {\n Log.e(TAG, e.getMessage());\n } finally {\n cursor.close();\n }\n return lista;\n }", "@Override\n\tpublic List<BeanDistrito> listar() {\n\t\tList<BeanDistrito> lista = new ArrayList<BeanDistrito>();\n\t\tBeanDistrito distrito = null;\n\t\tConnection con = MySQLDaoFactory.obtenerConexion();\n\t\ttry {\n\t\t\n\t\t\tString sql=\"SELECT * FROM t_distrito ORDER BY codDistrito\";\n\t\t\tStatement stmt = con.createStatement();\n\t\t\tResultSet rs = stmt.executeQuery(sql);\n\t\t\t\n\t\t\twhile(rs.next()){\n\t\t\t\tdistrito = new BeanDistrito();\n\t\t\t\tdistrito.setCodDistrito(rs.getInt(1));\n\t\t\t\tdistrito.setNombre(rs.getString(2));\n\t\t\t\t\n\t\t\t\tlista.add(distrito);\n\t\t\t}\n\t\t\tcon.close();\n\t\t} catch (Exception e) {\n\t\t\t// TODO: handle exception\n\t\t\ttry {\n\t\t\t\tcon.close();\n\t\t\t} catch (SQLException e1) {\n\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\te1.printStackTrace();\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn lista;\n\t}", "public void limpiartabla(JTable listaempleados){\n modelo = (DefaultTableModel) listaempleados.getModel();\n while(modelo.getRowCount()>0)modelo.removeRow(0);\n }", "public void solicitarRutinasPorDia() {\n eliminarTodasRutinas();\n\n }", "public void listarDadosNaTelaAreaDeConhecimento(ArrayList<AreaDeConhecimento> lista, DefaultTableModel model) {\n model.setNumRows(0);\n //Correr o ArrayList\n for (int pos = 0; pos < lista.size(); pos++) {\n String[] linha = new String[3];\n AreaDeConhecimento aux = lista.get(pos);\n linha[0] = \"\" + aux.getId();\n linha[1]=aux.getClassificacaoDecimalDireito();\n linha[2] = aux.getDescricao();\n model.addRow(linha);\n }\n }", "public void consultarListaDeContatos() {\n\t\tfor (int i = 0; i < listaDeContatos.size(); i++) {\n\t\t\tSystem.out.printf(\"%d %s \\n\", i, listaDeContatos.get(i));\n\t\t}\n\t}", "@Override\n\tpublic void exibitQtadeBancoDados() {\n\t\tSystem.out.println(\"Existem \"+qtadeBancoDadosMetodos+\" Bancos de dados de Métodos.\");\n\t}", "public void clearFields() {\n dataSearch = new Date();\n tbcliente = null;\n tbfuncionario = null;\n listTbagendamentos = agendamentoLogic.findAllTbagendamentoFromCurrentDay();\n }", "@Override\r\n\tpublic List<Usuario> listDesp() {\n\t\treturn null;\r\n\t}", "public void obtenerLista(){\n listaInformacion = new ArrayList<>();\n for (int i = 0; i < listaPersonales.size(); i++){\n listaInformacion.add(listaPersonales.get(i).getId() + \" - \" + listaPersonales.get(i).getNombre());\n }\n }", "public DAOPedidoMesa() {\n\t\trecursos = new ArrayList<Object>();\n\t}", "private void populaDiasTreinoCat()\n {\n DiasTreinoCat dias1 = new DiasTreinoCat(\"1 vez por semana\", 1);\n diasTreinoCatDAO.insert(dias1);\n DiasTreinoCat dias2 = new DiasTreinoCat(\"2 vez por semana\", 2);\n diasTreinoCatDAO.insert(dias2);\n DiasTreinoCat dias3 = new DiasTreinoCat(\"3 vez por semana\", 3);\n diasTreinoCatDAO.insert(dias3);\n DiasTreinoCat dias4 = new DiasTreinoCat(\"4 vez por semana\", 4);\n diasTreinoCatDAO.insert(dias4);\n DiasTreinoCat dias5 = new DiasTreinoCat(\"5 vez por semana\", 5);\n diasTreinoCatDAO.insert(dias5);\n DiasTreinoCat dias6 = new DiasTreinoCat(\"6 vez por semana\", 6);\n diasTreinoCatDAO.insert(dias6);\n DiasTreinoCat dias7 = new DiasTreinoCat(\"7 vez por semana\", 7);\n diasTreinoCatDAO.insert(dias7);\n\n }", "public void remplireListeOptions(){\r\n bddOptions.add(\"id\");\r\n bddOptions.add(\"EnvoieMail\");\r\n bddOptions.add(\"MailPeriode\");\r\n bddOptions.add(\"PeriodeJour\");\r\n bddOptions.add(\"PeriodeHeure\");\r\n bddOptions.add(\"PeriodeLun\");\r\n bddOptions.add(\"PeriodeMar\");\r\n bddOptions.add(\"PeriodeMerc\");\r\n bddOptions.add(\"PeriodeJeu\");\r\n bddOptions.add(\"PeriodeVen\");\r\n bddOptions.add(\"PeriodeSam\");\r\n bddOptions.add(\"PeriodeDim\");\r\n }", "public ArrayList<Miembro> daoListar() throws SQLException {\r\n\t\t\r\n\t\t\tPreparedStatement ps = con.prepareStatement(\"SELECT * from miembros\");\r\n\t\t\tResultSet rs = ps.executeQuery();\r\n\t\tArrayList<Miembro> result = new ArrayList<Miembro>();\r\n\t\t\r\n\t\twhile(rs.next()) { //Convertimos el resulset en un arraylist\r\n\t\t\tresult.add(new Miembro(rs.getInt(\"id\"),rs.getString(\"nombre\"),rs.getString(\"apellido1\"),rs.getString(\"apellido2\"),rs.getInt(\"edad\"),rs.getInt(\"cargo\")));\r\n\t\t\t\r\n\t\t}\r\n\t\t\r\n\t\treturn result;\r\n\t}", "public List<DietaBalanceada> consultar_dietaBalanceada();", "public ArrayList<Comobox> listaTodosBanco()\n {\n @SuppressWarnings(\"MismatchedQueryAndUpdateOfCollection\")\n ArrayList<Comobox> al= new ArrayList<>();\n @SuppressWarnings(\"UnusedAssignment\")\n ResultSet rs = null;\n sql=\"select * FROM VER_BANCO\";\n Conexao conexao = new Conexao();\n if(conexao.getCon()!=null)\n {\n try \n {\n if(conexao.getCon()!=null)\n {\n cs = conexao.getCon().prepareCall(sql);\n cs.execute();\n rs=cs.executeQuery(); \n if (rs!=null) \n { \n while (rs.next())\n { \n al.add(new Comobox(rs.getString(\"ID\"), rs.getString(\"SIGLA\")));\n } \n }\n rs.close();\n }\n else\n {\n al.add(new Comobox(\"djdj\",\"ddj\"));\n al.add(new Comobox(\"1dj\",\"dmsmdj\"));\n }\n } \n catch (SQLException ex)\n {\n Logger.getLogger(CreditoDao.class.getName()).log(Level.SEVERE, null, ex);\n System.out.println(\"Erro a obter fontes rendimentos \"+ex.getMessage());\n }\n }\n return al;\n }", "public void telefonoElimina(){\r\n \tlog.info(\"en eliminarTelefono()\");\t\r\n \tfor (int i = 0; i < TelefonoPersonaList.size(); i++) { \t\t\r\n \t\tlog.info(\"\"+TelefonoPersonaList.get(i).getItem()+\" ,idt \"+getIdt() +\" \"+TelefonoPersonaList.get(i).getTelefono());\r\n// \tlog.info(\"N1--->TelefonoPersonaList.get(i).getIdtelefonopersona()\"+\" --\" +TelefonoPersonaList.get(i).getIdtelefonopersona());\r\n\t\tif((TelefonoPersonaList.get(i).getIdtelefonopersona()== 0 || TelefonoPersonaList.get(i).getIdtelefonopersona()== null) && TelefonoPersonaList.get(i).getItem()==\"Por Agregar\"){\r\n\t\t\tlog.info(\"N2----> TelefonoPersonaList.get(i).getIdtelefonopersona()\" +\" \" +TelefonoPersonaList.get(i).getIdtelefonopersona());\r\n\t\t\tTelefonoPersonaSie teltemp = new TelefonoPersonaSie();\r\n\t\t\tteltemp.setIdtelefonopersona(idt);\r\n\t\t\tTelefonoPersonaList.remove(teltemp);\r\n\t\tfor (int j = i; j < TelefonoPersonaList.size(); j++) {\r\n\t\t\tlog.info(\" i \" +i+\" j \"+ j);\r\n\t\t\ti=i+1;\r\n\t\t\t//TelefonoPersonaList.get(j).setItem(i);\r\n\t\t\tTelefonoPersonaList.set(j, TelefonoPersonaList.get(j));\r\n\t\t}break;\r\n\t\t\t}\r\n\t\telse if(TelefonoPersonaList.get(i).getIdtelefonopersona() ==(getIdt()) && TelefonoPersonaList.get(i).getItem()==\"Agregado\"){\r\n\t\t\t\tlog.info(\"ALERTA WDFFFF\");\r\n\t\t\t\tTelefonoPersonaSie obj = new TelefonoPersonaSie(); \r\n\t\t\t\tobj.setIdtelefonopersona(idt);\r\n\t\t\t\tlog.info(\"DENTRO LISTA DESHABILITADO\");\t\t\t\t\r\n\t\t\t\tTelefonoDeshabilitado.add(obj);\r\n\t\t\r\n\t\t\t\tFaceMessage.FaceMessageError(\"ALERTA\", \"Los Cambios se realizaran despues de hacer clic en el boton Guardar\");\t\t\t\t\t\r\n\t\t\t}\r\n\t\t\t}\r\n\t\t }", "public List<Medico> getAllMedicos() {\n List<Medico> medicos = new ArrayList<Medico>();\n try {\n PreparedStatement pstm = null;\n ResultSet rs = null;\n String query = \"SELECT *FROM medico\";\n pstm = con.prepareStatement(query);\n rs = pstm.executeQuery();\n while (rs.next()) {\n Medico medico = new Medico();\n medico.setId(rs.getInt(\"id_medico\"));\n medico.setArea(rs.getString(\"area\"));\n medico.setNombre(rs.getString(\"nombre\"));\n medico.setAp_pat(rs.getString(\"apell_pat\"));\n medico.setAp_mat(rs.getString(\"apell_mat\"));\n medico.setDireccion(rs.getString(\"direccion\"));\n medico.setEmail(rs.getString(\"email\"));\n medico.setTel(rs.getString(\"tel\"));\n medico.setHora_inc(rs.getString(\"hora_inic\"));\n medico.setHora_fin(rs.getString(\"hora_fin\"));\n medicos.add(medico);\n }\n\n } catch (SQLException e) {\n e.printStackTrace();\n }\n return medicos;\n }", "@SuppressWarnings(\"unchecked\")\t\r\n\t@Override\r\n\tpublic List<Distrito> listar() {\n\t\tList<Distrito> lista = new ArrayList<Distrito>();\r\n\t\tQuery q = em.createQuery(\"select m from Distrito m\");\r\n\t\tlista = (List<Distrito>) q.getResultList();\r\n\t\treturn lista;\r\n\t}", "public List<tipoDetalle> obtenerDetallesBD(){\n List<tipoDetalle> detalles=new ArrayList<>();\n try{\n //Obteniendo el ID del auto desde la activity de Mostrar_datos\n String idAuto;\n Bundle extras=getIntent().getExtras();\n if(extras!=null)\n {\n idAuto=extras.getString(\"id_auto\");\n Log.e(\"auto\",\"el auto id es= \"+idAuto);\n ResultSet rs = (ResultSet) TNT.mostrarDetalles(idAuto);\n while (rs.next()){\n detalles.add(new tipoDetalle(rs.getString(\"id\"), rs.getString(\"nombre\"), rs.getString(\"fecha_entrada\"), rs.getString(\"fecha_salida\"), rs.getString(\"fecha_terminacion\"), rs.getString(\"estado\"), rs.getString(\"descripcion\"), rs.getString(\"costo\")));\n }\n }\n }catch(SQLException e){\n Toast.makeText(getApplicationContext(),e.getMessage(),Toast.LENGTH_SHORT).show();\n }\n return detalles;\n }", "private void mostradados() {\r\n\t\tint in = 0;\r\n\r\n\t\tfor (Estado e : Estado.values()) {\r\n\t\t\tif (in == 0) {\r\n\t\t\t\tcmbx_estado.addItem(\"\");\r\n\t\t\t\tin = 1;\r\n\t\t\t}\r\n\t\t\tcmbx_estado.addItem(e.getNome());\r\n\t\t}\r\n\r\n\t\tfor (int x = 0; x < listacliente.size(); x++) {\r\n\t\t\tin = 0;\r\n\t\t\tif (x == 0) {\r\n\t\t\t\tcmbx_cidade.addItem(\"\");\r\n\t\t\t}\r\n\r\n\t\t\tfor (int y = 0; y < cmbx_cidade.getItemCount(); y++) {\r\n\t\t\t\tif (listacliente.get(x).getCidade().equals(cmbx_cidade.getItemAt(y).toString()))\r\n\t\t\t\t\tin++;\r\n\t\t\t\tif (in > 1)\r\n\t\t\t\t\tbreak;\r\n\t\t\t}\r\n\t\t\tif (in < 1)\r\n\t\t\t\tcmbx_cidade.addItem(listacliente.get(x).getCidade());\r\n\t\t}\r\n\t}", "public void excluirDados() {\n\n int linha;\n\n if (verificarAbaAtiva() == 0) {\n linha = HorarioDeTrabalho.getSelectedRow();\n modHT = (DefaultTableModel) HorarioDeTrabalho.getModel();\n tratDados.excluirDadosTabela(modHT, linha);\n txtEntrada_Horario.requestFocus();\n } else {\n linha = MarcacoesFeitas.getSelectedRow();\n modMF = (DefaultTableModel) MarcacoesFeitas.getModel();\n tratDados.excluirDadosTabela(modMF, linha);\n txtEntrada_Marcacoes.requestFocus();\n }\n \n //Limpa as tabelas de Atraso e Extras\n modAt.setRowCount(0);\n modEx.setRowCount(0);\n }", "public ArrayList<Debito> getAllDebitos() {\n ArrayList<Debito> debitos = new ArrayList<Debito>();\n String selectQuery = \"SELECT * FROM \" + TABLE_DEBITOS;\n\n Log.e(LOG, selectQuery);\n\n SQLiteDatabase db = this.getReadableDatabase();\n Cursor c = db.rawQuery(selectQuery, null);\n\n // looping through all rows and adding to list\n if (c.moveToFirst()) {\n do {\n Debito td = new Debito();\n td.setCodigo(c.getInt(c.getColumnIndex(KEY_ID)));\n td.setValor(c.getDouble(c.getColumnIndex(KEY_VALOR)));\n td.setData(c.getString(c.getColumnIndex(KEY_DATA)));\n td.setEstabelecimento((c.getString(c.getColumnIndex(KEY_ESTABELECIMENTO))));\n\n // adding to todo list\n debitos.add(td);\n } while (c.moveToNext());\n }\n\n return debitos;\n }", "void desalocar(Processo processo) {\n for (int r = 0; r < size(); r++) {\n if (get(r).idProcesso == processo.getId()) {\n //TODO Marcar o bloco como livre\n get(r).espaçoUsado = 0;\n get(r).idProcesso = -1;\n }\n }\n }", "public void MostrarListafINInicio() {\n if(!estVacia()){\n String datos=\"<=>\";\n NodoDoble current=fin;\n while(current!=null){\n datos += \"[\"+current.dato+\"]<=>\";\n current = current.anterior;\n }\n JOptionPane.showMessageDialog(null, datos, \"Mostrando Lista de inicio a Fin\",JOptionPane.INFORMATION_MESSAGE);\n }\n }", "public List<Commande> getCommande() {\n return commandeDao.findAll();\r\n\r\n }", "private void CargarListaFincas() {\n listaFincas = controlgen.GetComboBox(\"SELECT '-1' AS ID, 'Seleccionar' AS DESCRIPCION\\n\" +\n \"UNION\\n\" +\n \"SELECT `id` AS ID, `descripcion` AS DESCRIPCION\\n\" +\n \"FROM `fincas`\\n\"+\n \"/*UNION \\n\"+\n \"SELECT 'ALL' AS ID, 'TODOS' AS DESCRIPCION*/\");\n \n Utilidades.LlenarComboBox(cbFinca, listaFincas, \"DESCRIPCION\");\n \n }", "@Override\n\tpublic ResponseEntity<?> deletarTodos(@Valid List<ProdutoImagem> objeto,\n\t\tHttpServletRequest request) {\n\t\treturn null;\n\t}", "private void getObsequios(){\n mObsequios = estudioAdapter.getListaObsequiosSinEnviar();\n //ca.close();\n }", "private void getDataSemua(){\n try{\n ResultSet resultSet = database.getData(\"Select * from daftar_menu;\");\n list.clear();\n while (resultSet.next()) {\n list.add(\n new casher(\n resultSet.getString(1),\n resultSet.getString(2),\n resultSet.getString(3),\n resultSet.getInt(4),\n resultSet.getString(5),\n new Button(\"Tambah\"))\n );\n }\n }catch (SQLException e){\n System.out.println(e.getMessage());\n }\n }", "public void mostrarlistafininicio(){\n if(!estaVacia()){\n String datos = \"<=>\";\n NodoBus auxiliar = fin;\n while(auxiliar!=null){\n datos = datos + \"(\" + auxiliar.dato +\")->\";\n auxiliar = auxiliar.ant;\n JOptionPane.showMessageDialog(null, datos, \"Mostrando lista de fin a inicio\", JOptionPane.INFORMATION_MESSAGE);\n }\n }\n }", "public listaAlumnos()\r\n\t{\r\n\t\tinicio = fin = null; \r\n\t}", "public ArrayList<DataUsuario> listarUsaurios();", "private void loadMaTauVaoCBB() {\n cbbMaTau.removeAllItems();\n try {\n ResultSet rs = LopKetNoi.select(\"select maTau from Tau\");\n while (rs.next()) {\n cbbMaTau.addItem(rs.getString(1));\n }\n } catch (Exception e) {\n System.out.println(\"Load ma tau vao cbb that bai\");\n }\n\n }", "public void eliminar(){\n inicio = null;\r\n // Reinicia el contador de tamaño de la lista a 0.\r\n tamanio = 0;\r\n }", "public List<Departamento> obtenerInstancias() {\n List<Departamento> lstDepas = new ArrayList();\n if (conectado) {\n try {\n String Query = \"SELECT * FROM instancias ORDER BY nombre ASC\";\n Statement st = Conexion.createStatement();\n ResultSet resultSet;\n resultSet = st.executeQuery(Query);\n while (resultSet.next()) {\n Departamento depa = new Departamento();\n depa.setCodigo(resultSet.getString(\"codigo\"));\n depa.setNombre(resultSet.getString(\"nombre\"));\n depa.setJefe(resultSet.getString(\"jefe\"));\n lstDepas.add(depa);\n }\n Logy.m(\"Consulta de datos de las instancias: exitosa\");\n return lstDepas;\n\n } catch (SQLException ex) {\n Logy.me(\"Error!! en la consulta de datos en la tabla instancias\");\n return new ArrayList();\n }\n } else {\n Logy.me(\"Error!!! no se ha establecido previamente una conexion a la DB\");\n return lstDepas;\n }\n }", "public List<SistemaFazendaModel> listaTudo(){\n\t\treturn this.session.createCriteria(SistemaFazendaModel.class).list();\n\t}", "public void reloadTable() {\n\n this.removeAllData();// borramos toda la data \n for (int i = 0; i < (list.size()); i++) { // este for va de la primera casilla hast ael largo del arreglo \n Balanza object = list.get(i);\n this.AddtoTable(object);\n }\n\n }", "public void borrarSesionesAnteriores()\r\n\t{\r\n\t\tint numerosesiones = 0;//numero de convocatorias en la BD\r\n\t\tList sesiones = null;\r\n\t\ttry\r\n {\r\n Conector conector = new Conector();\r\n conector.iniciarConexionBaseDatos();\r\n sesiones= SesionBD.listar(conector);\r\n conector.terminarConexionBaseDatos();\r\n }\r\n catch (Exception e)\r\n\t\t{\r\n \tJOptionPane.showMessageDialog(this,\"Error al conectar con la Base de Datos.\",\"Error\", JOptionPane.ERROR_MESSAGE,new ImageIcon(\"./images/IconosInterfaz/error.PNG\"));\r\n\t\t}\r\n if(sesiones != null)\r\n {\r\n \tnumerosesiones = sesiones.size();\r\n }\r\n for (int i = 0; i < numerosesiones; i++)\r\n\t\t{\r\n \tSesion sesionaux = (Sesion)sesiones.get(i);\r\n\t\t\tint idsesion = sesionaux.getIdsesion();\r\n\t\t\tString fechasesion = sesionaux.getFechasesion();\r\n\t\t\tboolean esanterior = fechaSesionAnterior(fechasesion);\r\n\t\t\tif(esanterior == true)\r\n\t\t\t{\r\n\t\t\t\ttry \r\n\t \t\t{\r\n\t \t\t\tConector conector = new Conector();\r\n\t \t\t\tconector.iniciarConexionBaseDatos();\r\n\t \t\t\tSesionBD.eliminar(idsesion, conector);\r\n\t \t\t\tconector.terminarConexionBaseDatos();\r\n\t \t\t}\r\n\t \t\tcatch (Exception e)\r\n\t \t\t{\r\n\t \t\t\tJOptionPane.showMessageDialog(this,\"Error al conectar con la Base de Datos.\",\"Error\", JOptionPane.ERROR_MESSAGE,new ImageIcon(\"./images/IconosInterfaz/error.PNG\"));\r\n\t \t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}", "List<Persona> obtenerTodasLasPersona();", "void listarDadosNaTelaAutor(ArrayList<Autor> lista, DefaultTableModel model) {\n model.setNumRows(0);\n //Correr o ArrayList\n for (int pos = 0; pos < lista.size(); pos++) {\n String[] linha = new String[2];\n Autor aux = lista.get(pos);\n linha[0] = \"\"+aux.getId();\n linha[1] = aux.getNome();\n model.addRow(linha);\n }\n }", "public void borrarTodo(){\n diccionario.clear();\n }" ]
[ "0.7040702", "0.6913195", "0.67772853", "0.67640495", "0.6736064", "0.6712098", "0.66823286", "0.6492538", "0.6462974", "0.64414793", "0.6436464", "0.64051944", "0.63921344", "0.639189", "0.63889706", "0.6383955", "0.6372964", "0.63520193", "0.6343641", "0.6323486", "0.63234353", "0.6304221", "0.62794995", "0.62717295", "0.6271492", "0.627069", "0.6270365", "0.6262516", "0.62382704", "0.623683", "0.623243", "0.62293965", "0.6217391", "0.62009084", "0.61972", "0.61955136", "0.6185156", "0.6183679", "0.61812097", "0.6161673", "0.6159483", "0.6152104", "0.61483985", "0.6147286", "0.6145302", "0.61451954", "0.6144437", "0.614229", "0.6140241", "0.61385506", "0.6136439", "0.6132218", "0.61267376", "0.61252373", "0.61223453", "0.6115406", "0.6113092", "0.61125654", "0.610881", "0.6108307", "0.60841644", "0.608159", "0.6079748", "0.60726625", "0.6071241", "0.60642487", "0.6059783", "0.60534286", "0.60521346", "0.6048551", "0.60467017", "0.60381866", "0.6030696", "0.6030466", "0.60294074", "0.6027899", "0.6011405", "0.5997186", "0.59965205", "0.5994589", "0.5991668", "0.5990784", "0.59793776", "0.59764487", "0.59743285", "0.5968494", "0.59671545", "0.5965532", "0.5957972", "0.5953168", "0.594692", "0.5945881", "0.59407014", "0.59393716", "0.59364873", "0.59293336", "0.5902645", "0.58951724", "0.58931047", "0.5893076", "0.5891961" ]
0.0
-1
TODO Autogenerated method stub
@Override public List<Ccspxxb> selectCcspxx() { return ccspxxbMapper.selectByExample(null); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\n public void perish() {\n \n }", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "@Override\n\tpublic void anular() {\n\n\t}", "@Override\n\tprotected void getExras() {\n\n\t}", "@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}", "@Override\n\tpublic void entrenar() {\n\t\t\n\t}", "@Override\n\tpublic void nadar() {\n\t\t\n\t}", "@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}", "@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}", "@Override\n\tprotected void interr() {\n\t}", "@Override\n\tpublic void emprestimo() {\n\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\n\tpublic void grabar() {\n\t\t\n\t}", "@Override\n\tpublic void gravarBd() {\n\t\t\n\t}", "@Override\r\n\tpublic void rozmnozovat() {\n\t}", "@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}", "@Override\n protected void getExras() {\n }", "@Override\r\n\tpublic void publierEnchere() {\n\t\t\r\n\t}", "@Override\n\tpublic void nefesAl() {\n\n\t}", "@Override\n\tpublic void ligar() {\n\t\t\n\t}", "@Override\n public void func_104112_b() {\n \n }", "@Override\n\tprotected void initdata() {\n\n\t}", "@Override\n\tpublic void nghe() {\n\n\t}", "@Override\n public void function()\n {\n }", "@Override\n public void function()\n {\n }", "public final void mo51373a() {\n }", "@Override\r\n\tpublic void stehReagieren() {\r\n\t\t//\r\n\t}", "@Override\n public void inizializza() {\n\n super.inizializza();\n }", "@Override\n\tprotected void initData() {\n\t\t\n\t}", "@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}", "@Override\n\tpublic void sacrifier() {\n\t\t\n\t}", "@Override\r\n\tprotected void InitData() {\n\t\t\r\n\t}", "public void designBasement() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}", "public void gored() {\n\t\t\n\t}", "@Override\r\n\tprotected void initData() {\n\r\n\t}", "@Override\n\tpublic void einkaufen() {\n\t}", "@Override\n protected void initialize() {\n\n \n }", "public void mo38117a() {\n }", "@Override\n\tprotected void getData() {\n\t\t\n\t}", "Constructor() {\r\n\t\t \r\n\t }", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "@Override\n\tpublic void one() {\n\t\t\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "private stendhal() {\n\t}", "@Override\n\tprotected void update() {\n\t\t\n\t}", "@Override\n\t\t\tpublic void ic() {\n\t\t\t\t\n\t\t\t}", "@Override\n\tprotected void initData() {\n\n\t}", "@Override\n\tprotected void initData() {\n\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n public void init() {\n\n }", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\n\tpublic void debite() {\n\t\t\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "public contrustor(){\r\n\t}", "@Override\n\tprotected void initialize() {\n\n\t}", "@Override\r\n\tpublic void dispase() {\n\r\n\t}", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "@Override\n\tpublic void dtd() {\n\t\t\n\t}", "@Override\n\tprotected void logic() {\n\n\t}", "@Override\n\tprotected void lazyLoad() {\n\t\t\n\t}", "public void mo4359a() {\n }", "@Override\r\n\tprotected void initialize() {\n\r\n\t}", "@Override\n public void memoria() {\n \n }", "@Override\n\t\tpublic void method() {\n\t\t\t\n\t\t}", "private RepositorioAtendimentoPublicoHBM() {\r\t}", "@Override\n protected void initialize() \n {\n \n }", "@Override\r\n\tpublic void getProposition() {\n\r\n\t}", "@Override\n\tpublic void particular1() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n protected void prot() {\n }", "@Override\r\n\tpublic void init()\r\n\t{\n\t}", "@Override\n\tprotected void initValue()\n\t{\n\n\t}", "public void mo55254a() {\n }" ]
[ "0.6671074", "0.6567672", "0.6523024", "0.6481211", "0.6477082", "0.64591026", "0.64127725", "0.63762105", "0.6276059", "0.6254286", "0.623686", "0.6223679", "0.6201336", "0.61950207", "0.61950207", "0.61922914", "0.6186996", "0.6173591", "0.61327106", "0.61285484", "0.6080161", "0.6077022", "0.6041561", "0.6024072", "0.6020252", "0.59984857", "0.59672105", "0.59672105", "0.5965777", "0.59485507", "0.5940904", "0.59239364", "0.5910017", "0.5902906", "0.58946234", "0.5886006", "0.58839184", "0.58691067", "0.5857751", "0.58503544", "0.5847024", "0.58239377", "0.5810564", "0.5810089", "0.5806823", "0.5806823", "0.5800025", "0.5792378", "0.5792378", "0.5792378", "0.5792378", "0.5792378", "0.5792378", "0.5790187", "0.5789414", "0.5787092", "0.57844025", "0.57844025", "0.5774479", "0.5774479", "0.5774479", "0.5774479", "0.5774479", "0.5761362", "0.57596046", "0.57596046", "0.575025", "0.575025", "0.575025", "0.5747959", "0.57337177", "0.57337177", "0.57337177", "0.5721452", "0.5715831", "0.57142824", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.5711723", "0.57041645", "0.56991017", "0.5696783", "0.56881124", "0.56774884", "0.56734604", "0.56728", "0.56696945", "0.5661323", "0.5657007", "0.5655942", "0.5655942", "0.5655942", "0.56549734", "0.5654792", "0.5652974", "0.5650185" ]
0.0
-1
TODO Autogenerated method stub
@Override public List<Ccspxxb> selectByExamplel(Ccspxxb ccspxx) { return ccspxxbMapper.selectByExamplel(ccspxx); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\n public void perish() {\n \n }", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "@Override\n\tpublic void anular() {\n\n\t}", "@Override\n\tprotected void getExras() {\n\n\t}", "@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}", "@Override\n\tpublic void entrenar() {\n\t\t\n\t}", "@Override\n\tpublic void nadar() {\n\t\t\n\t}", "@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}", "@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}", "@Override\n\tprotected void interr() {\n\t}", "@Override\n\tpublic void emprestimo() {\n\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\n\tpublic void grabar() {\n\t\t\n\t}", "@Override\n\tpublic void gravarBd() {\n\t\t\n\t}", "@Override\r\n\tpublic void rozmnozovat() {\n\t}", "@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}", "@Override\n protected void getExras() {\n }", "@Override\r\n\tpublic void publierEnchere() {\n\t\t\r\n\t}", "@Override\n\tpublic void nefesAl() {\n\n\t}", "@Override\n\tpublic void ligar() {\n\t\t\n\t}", "@Override\n public void func_104112_b() {\n \n }", "@Override\n\tprotected void initdata() {\n\n\t}", "@Override\n\tpublic void nghe() {\n\n\t}", "@Override\n public void function()\n {\n }", "@Override\n public void function()\n {\n }", "public final void mo51373a() {\n }", "@Override\r\n\tpublic void stehReagieren() {\r\n\t\t//\r\n\t}", "@Override\n public void inizializza() {\n\n super.inizializza();\n }", "@Override\n\tprotected void initData() {\n\t\t\n\t}", "@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}", "@Override\n\tpublic void sacrifier() {\n\t\t\n\t}", "@Override\r\n\tprotected void InitData() {\n\t\t\r\n\t}", "public void designBasement() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}", "public void gored() {\n\t\t\n\t}", "@Override\r\n\tprotected void initData() {\n\r\n\t}", "@Override\n\tpublic void einkaufen() {\n\t}", "@Override\n protected void initialize() {\n\n \n }", "public void mo38117a() {\n }", "@Override\n\tprotected void getData() {\n\t\t\n\t}", "Constructor() {\r\n\t\t \r\n\t }", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "@Override\n\tpublic void one() {\n\t\t\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "private stendhal() {\n\t}", "@Override\n\tprotected void update() {\n\t\t\n\t}", "@Override\n\t\t\tpublic void ic() {\n\t\t\t\t\n\t\t\t}", "@Override\n\tprotected void initData() {\n\n\t}", "@Override\n\tprotected void initData() {\n\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n public void init() {\n\n }", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\n\tpublic void debite() {\n\t\t\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "public contrustor(){\r\n\t}", "@Override\n\tprotected void initialize() {\n\n\t}", "@Override\r\n\tpublic void dispase() {\n\r\n\t}", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "@Override\n\tpublic void dtd() {\n\t\t\n\t}", "@Override\n\tprotected void logic() {\n\n\t}", "@Override\n\tprotected void lazyLoad() {\n\t\t\n\t}", "public void mo4359a() {\n }", "@Override\r\n\tprotected void initialize() {\n\r\n\t}", "@Override\n public void memoria() {\n \n }", "@Override\n\t\tpublic void method() {\n\t\t\t\n\t\t}", "private RepositorioAtendimentoPublicoHBM() {\r\t}", "@Override\n protected void initialize() \n {\n \n }", "@Override\r\n\tpublic void getProposition() {\n\r\n\t}", "@Override\n\tpublic void particular1() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n protected void prot() {\n }", "@Override\r\n\tpublic void init()\r\n\t{\n\t}", "@Override\n\tprotected void initValue()\n\t{\n\n\t}", "public void mo55254a() {\n }" ]
[ "0.6671074", "0.6567672", "0.6523024", "0.6481211", "0.6477082", "0.64591026", "0.64127725", "0.63762105", "0.6276059", "0.6254286", "0.623686", "0.6223679", "0.6201336", "0.61950207", "0.61950207", "0.61922914", "0.6186996", "0.6173591", "0.61327106", "0.61285484", "0.6080161", "0.6077022", "0.6041561", "0.6024072", "0.6020252", "0.59984857", "0.59672105", "0.59672105", "0.5965777", "0.59485507", "0.5940904", "0.59239364", "0.5910017", "0.5902906", "0.58946234", "0.5886006", "0.58839184", "0.58691067", "0.5857751", "0.58503544", "0.5847024", "0.58239377", "0.5810564", "0.5810089", "0.5806823", "0.5806823", "0.5800025", "0.5792378", "0.5792378", "0.5792378", "0.5792378", "0.5792378", "0.5792378", "0.5790187", "0.5789414", "0.5787092", "0.57844025", "0.57844025", "0.5774479", "0.5774479", "0.5774479", "0.5774479", "0.5774479", "0.5761362", "0.57596046", "0.57596046", "0.575025", "0.575025", "0.575025", "0.5747959", "0.57337177", "0.57337177", "0.57337177", "0.5721452", "0.5715831", "0.57142824", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.5711723", "0.57041645", "0.56991017", "0.5696783", "0.56881124", "0.56774884", "0.56734604", "0.56728", "0.56696945", "0.5661323", "0.5657007", "0.5655942", "0.5655942", "0.5655942", "0.56549734", "0.5654792", "0.5652974", "0.5650185" ]
0.0
-1
Transform vss model to svn model
public ISvnModel buildSvnModel() { VssModel vssModel = buildVssModel(); if (incrementalWarning) LOG.warn("unsupported operations(delete,rename,share,branch) detected in project, incremental dump can be broken"); VssTransform tr = new VssTransform(this); SvnModel svnModel = tr.transform(vssModel); LOG.info("Svn model has been created"); LOG.info("total number of revisions in svn model: " + svnModel.getRevisions().size()); return svnModel; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void testVSMMigrationInWorkspace() {\n copyFilesToTestProject(SiriusTestsPlugin.PLUGIN_ID, DATA_PATH, VSM_NAME);\n\n ResourceSet set = new ResourceSetImpl();\n Group modeler = null;\n try {\n modeler = (Group) ModelUtils.load(URI.createPlatformResourceURI(TEMPORARY_PROJECT_NAME + \"/\" + VSM_NAME, true), set);\n } catch (IOException e) {\n e.printStackTrace();\n }\n\n // Check that the migration was done.\n assertNotNull(\"Check the VSM test data.\", modeler);\n\n // The version will change on save, so migration service will still\n // indicates that the migration is needed.\n String version = modeler.getVersion();\n assertTrue(\"Before save, the migration framework will return true even if the migration has been done during load.\",\n VSMMigrationService.getInstance().isMigrationNeeded(Version.parseVersion(version)));\n\n try {\n modeler.eResource().save(Collections.emptyMap());\n } catch (IOException e) {\n e.printStackTrace();\n }\n // save should update the version.\n version = modeler.getVersion();\n assertFalse(\"The version tag should now be set telling that the migration was done.\", VSMMigrationService.getInstance().isMigrationNeeded(Version.parseVersion(version)));\n\n // We can now check the migration effect to be sure that the migration\n // is effective.\n checkMigrationEffect(modeler);\n }", "private void _generate(int versions) {\n\t \n\t \n\t \n\t _generate(); //V0\n\t \n\t File[] files = new File(System.getProperty(\"user.dir\")).listFiles();\n\t Model model = ModelFactory.createDefaultModel();\n\t //model.set\n\t\tfor(File file : files){\n\t\t\tif(!file.getName().contains(\"owl\")) continue;\n\t\t\ttry{\n\t\t\t\t\n\t\t\t\tFileInputStream in = new FileInputStream(file);\n\t\t\t\tmodel.read(in, \"http://example.com\", \"RDF/XML\");\t\t\t\n\t\t\t\tin.close();\n\t\t\t}\n\t\t\tcatch(Exception e){\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t\t\n\t\t}\n\t\tlong startingSize = model.size();\n\t\tmodel.close();\n\t double desSize = startingSize*(1+evoChange);\n\t int schemaEvol = (int)(strict*10);\n\t int schemaEvol2 = schemaEvol / (evoVersions-1);\n\t System.out.println(\"schema evol param: \" + schemaEvol2);\n\t int howManyDepts = (int) Math.floor(totalDeptsV0*evoChange);\n\t HashMap<Integer, String> newClasses = new HashMap<Integer, String>();\n\t for(int i = 0; i < schemaEvol; i++)\n\t\t newClasses.put(i,\"\");\n\n\t double evoChangeOriginal = evoChange;\n\t boolean pub = false, conf = false, journ = false, tech = false, \n\t\t\t book = false, thes = false, proj = false, even = false;\n\t HashMap<String, HashMap<Integer, Double>> initialWeightsMap = new HashMap<String, HashMap<Integer,Double>>();\n\t for(String key : fileWeightsMap.keySet()){\n\t\t HashMap<Integer, Double> innerClone = new HashMap<Integer, Double>();\n\t\t for(Integer innerKey : fileWeightsMap.get(key).keySet()){\n\t\t\t innerClone.put(innerKey, fileWeightsMap.get(key).get(innerKey));\n\t\t }\n\t\t initialWeightsMap.put(key, innerClone);\n\t }\n\t for(int vi = 0 ; vi < evoVersions-1; vi++){\n\t \t\n\t\t globalVersionTrigger = true;\n\t\t File dir = new File(System.getProperty(\"user.dir\")+\"/v\"+vi);\n dir.mkdirs();\n\t\t //assignFilters(classFilters);\n\t\t //System.out.println(\"current filters: \" + currentFilters.toString());\n\t \tint classForChange ;\n\t \n\t \t//the number of depts (files) to evolve, based on the defined evoChange parameter\t \n\t \n\t List<String> asList = new ArrayList<String>(fileWeightsMap.keySet());\n\t \n\t writer_log = new OwlWriter(this);\t \n writer_log.startLogFile(dir.getAbsolutePath()+\"/changes.rdf\");\n writer_log.start();\n\t for(int d = 0 ; d < howManyDepts ; d++){\n\t \t\n\t \t//System.out.println(\"aslist: \" + asList.size());\n\t \tif(asList.size() == 0) break;\n\t String randomFile = asList.get(random_.nextInt(asList.size()));\n\t instances_ = fileInstanceMap.get(randomFile);\n\t \n\t asList.remove(randomFile);\n\t \t\n\t //System.out.println(\"Selected file: \" + randomFile);\n\t writer_ = new OwlWriter(this);\n\t \n\t writer_.startFile(dir.getAbsolutePath()+\"/\"+randomFile);\n\t writer_.start();\n\t for(Integer nextClass : fileWeightsMap.get(randomFile).keySet()){\n\t \t\n\t \tclassForChange = nextClass;\n\t \t\n\t \tif(classForChange < 2) {\n\t \t\t\tcontinue;\n\t \t}\n\t \t\n\t \tif(classForChange == 4) continue;\n\t \tint totalIter = (int) Math.floor(2*initialWeightsMap.get(randomFile).get(classForChange))/howManyDepts;\n\t \t\n\t for(int i = 0; i < totalIter ; i++){\n\t \t\n\t \t_generateASection(classForChange, \n\t \t\t\tinstances_[classForChange].count ); \t \t\t\t\n\t }\n\t \n\t if(nextClass == 21 ){\n\t \twriter_log.addTypeClass(ontology+\"WebCourse\");\n\t \twriter_log.addSuperClass(ontology+\"WebCourse\", ontology+\"Course\");\n\t }\n\t else if(nextClass == 20 ){\n\t \twriter_log.addTypeClass(ontology+\"VisitingStudent\");\n\t \twriter_log.addSuperClass(ontology+\"VisitingStudent\", ontology+\"Student\");\n\t }\n\t else if(nextClass == 19 ){\n\t \twriter_log.addTypeClass(ontology+\"VisitingProfessor\");\n\t \twriter_log.addSuperClass(ontology+\"VisitingProfessor\", ontology+\"Professor\");\n\t }\n\t \n\t }\n\t \n\t for(int k = 0; k < schemaEvol2+1; k++){\n\t \t\n\t \tif(newClasses.isEmpty()) break;\n\t \tint newClass = _getRandomFromRange(0, newClasses.keySet().size()+1);\n\t \tint index = 0;\n\t \tfor(Integer s : newClasses.keySet()){\n\t \t\tif(index == newClass){\n\t \t\t\tnewClass = s;\n\t \t\t\tbreak;\n\t \t\t}\n\t \t\tindex++;\n\t \t}\n\t \t/*if(newClass == 1){\n\t \t_generatePublications();\n\t \tnewClasses.remove(newClass);\n\t }*/\n\t if(newClass == 2){\n\t \t_generateConferencePublications();\n\t \tnewClasses.remove(newClass);\n\t \twriter_log.addTypeClass(ontology+\"ConferencePublication\");\n\t \twriter_log.addSuperClass(ontology+\"ConferencePublication\", ontology+\"Publication\");\n\t }\n\t if(newClass == 3){\n\t \t_generateJournalPublications();\n\t \tnewClasses.remove(newClass);\n\t \twriter_log.addTypeClass(ontology+\"JournalArticle\");\n\t \twriter_log.addSuperClass(ontology+\"JournalArticle\", ontology+\"Publication\");\n\t }\n\t if(newClass == 4 ){\n\t \t_generateTechnicalReports();\n\t \tnewClasses.remove(newClass);\n\t \twriter_log.addTypeClass(ontology+\"TechnicalReport\");\n\t \twriter_log.addSuperClass(ontology+\"TechnicalReport\", ontology+\"Publication\");\n\t }\n\t if(newClass == 5 ){\n\t \t_generateBooks();\n\t \tnewClasses.remove(newClass);\n\t \twriter_log.addTypeClass(ontology+\"Book\");\n\t \twriter_log.addSuperClass(ontology+\"Book\", ontology+\"Publication\");\n\t }\n\t if(newClass == 6 ){\n\t \t_generateThesis();\n\t \tnewClasses.remove(newClass);\n\t \twriter_log.addTypeClass(ontology+\"Thesis\");\n\t \twriter_log.addSuperClass(ontology+\"Thesis\", ontology+\"Publication\");\n\t }\n\t if(newClass == 7 ){\n\t \t_generateProjects();\n\t \tnewClasses.remove(newClass);\n\t \twriter_log.addTypeClass(ontology+\"Project\");\n\t }\n\t if(newClass == 8){\n\t \t_generateEvents();\n\t \tnewClasses.remove(newClass);\n\t \twriter_log.addTypeClass(ontology+\"Event\");\n\t }\n\t }\n\t \n\t writer_.end();\n\t writer_.endFile();\n\t //correction\n\t //remainingUnderCourses_.\n\t remainingUnderCourses_.clear();\n\t \n\t for (int i = 0; i < UNDER_COURSE_NUM + (int) (UNDER_COURSE_NUM*evoChange); i++) {\n\t remainingUnderCourses_.add(new Integer(i));\n\t }\n\t remainingGradCourses_.clear();\n\t for (int i = 0; i < GRAD_COURSE_NUM + (int) (GRAD_COURSE_NUM*evoChange); i++) {\n\t remainingGradCourses_.add(new Integer(i));\n\t }\n\t remainingWebCourses_.clear();\n\t for (int i = 0; i < WEB_COURSE_NUM + (int) (WEB_COURSE_NUM*evoChange); i++) {\n\t remainingWebCourses_.add(new Integer(i));\n\t }\n\t \n\t assignWeights(randomFile);\t \t \n\t \n\t }\t\n\t evoChange = evoChange + evoVersions*evoChangeOriginal*evoChangeOriginal;\n\t \n\t writer_log.end();\n\t writer_log.endLogFile();\n\t \n\t \t\n\t }\n\t \n\t \n }", "public static void main(String[] args) {\n try{\n Properties props = new Properties();\n props.load(new FileInputStream(\"transform.properties\"));\n String outputFileName = props.getProperty(\"harpurOutput\");\n String inputFileName = props.getProperty(\"harpurInput\");\n projectId = props.getProperty(\"harpurProjectId\");\n CSVReader reader = new CSVReader(new FileReader(inputFileName));\n String [] nextLine;\n //Work no.,Work title,Version no.,Date,First line of version,Title of version,Source,Bib. details\n //0 Work no., 1 Work title,2 Version no.,3 Year, 4 Date,5 First line of version,6 Blank, 7 Title of version,8 Source,9 Page no, 10 Notes, 11 Series, 12 lines, 13 ms, 14 url\n String versTitle, workTitle=\"\";\n HashMap<String,String> currentWork = null;\n ArrayList<String> currentVersions = new ArrayList<String>();\n boolean firstLine = true;\n int rowNumber = 0;\n while ((nextLine = reader.readNext()) != null) {\n if (!firstLine){\n rowNumber++;\n // If this line represents a new work, create a work record\n if (!nextLine[0].equals(\"\")){\n // add list of versions accumulated so far to previous work and then reset\n if (currentVersions.size() != 0 && currentWork != null){\n StringBuffer cVers = new StringBuffer();\n cVers.append(\"[\");\n Iterator<String> it = currentVersions.iterator();\n while(it.hasNext()){\n cVers.append(\"\\\"\" + it.next() + \"\\\"\");\n if (it.hasNext()){\n cVers.append(\", \");\n }\n }\n cVers.append(\"]\");\n // for each in currentVersions add new ObjectId(currentVersions[i]) to cVers array\n currentWork.put(\"versions\", cVers.toString());\n currentVersions.clear();\n }\n currentWork = new HashMap<String,String>();\n currentWork.put(\"name\",nextLine[0]);\n workTitle = nextLine[1];\n currentWork.put(\"workTitle\", replaceStupidCharacters(workTitle));\n workList.add(currentWork);\n }\n //if (!nextLine[2].equals(\"\")){\n // Create a version (don't worry about issues, Harpur project only has to deal with one issue per version)\n HashMap<String,String> v = new HashMap<String,String>();\n String versionId = new ObjectId().toString();\n v.put(\"importRowNumber\", rowNumber + \"\");\n v.put(\"_id\", \"{ \\\"$oid\\\" : \\\"\" + versionId + \"\\\"}\");\n // push version id to currentVersions for later linking from work\n currentVersions.add(versionId);\n String hnum = nextLine[2];\n v.put(\"name\",hnum);\n v.put(\"date\", (!nextLine[4].equals(\"\")? nextLine[4] + \" \": \"\") + nextLine[3]);\n v.put(\"lines\", nextLine[11]);\n v.put(\"firstLine\", replaceStupidCharacters(nextLine[5]));\n versTitle = nextLine[6];\n if (versTitle.startsWith(\"^\")){\n versTitle = workTitle;\n } else if (versTitle.trim().equals(\"-\")){\n versTitle = \"Untitled\";\n }\n v.put(\"versionTitle\", replaceStupidCharacters(versTitle));\n versionList.add(v);\n \n //if (nextLine[2] == null || !nextLine[9].equals(\"\")){\n // Create an Artefact (part) for each version\n //8 Source,9 Page no, 10 Notes, 11 Series, 12 Version no, 13 lines, 14 ms, 15 url\n HashMap<String,String> a = new HashMap<String,String>();\n String artefactId = new ObjectId().toString();\n String source = nextLine[7].trim();\n String pageNumbers = nextLine[8].trim();\n a.put(\"importRowNumber\", rowNumber + \"\");\n a.put(\"_id\",\"{ \\\"$oid\\\" : \\\"\" + artefactId + \"\\\"}\");\n a.put(\"source\", source + (!pageNumbers.equals(\"\") ? \" p\" + pageNumbers: \"\"));\n a.put(\"pageNumbers\", pageNumbers);\n a.put(\"description\", nextLine[9]); // actually notes field\n a.put(\"series\", nextLine[10]);\n a.put(\"date\", (!nextLine[4].equals(\"\")? nextLine[4] + \" \": \"\") + nextLine[3]);\n artefactList.add(a);\n \n // add source,artefact id to artefact parts map\n if (!source.equals(\"\")){\n if (artefactParts.containsKey(source)){\n artefactParts.get(source).add(artefactId);\n } else {\n ArrayList<String> parts = new ArrayList<String>();\n parts.add(artefactId);\n artefactParts.put(source, parts);\n }\n }\n // Create temporary mappings that will be used later to match uploaded images with artefacts\n HashMap<String,String> t = new HashMap<String,String>();\n t.put(\"hnum\", hnum);\n t.put(\"artefact\",artefactId);\n t.put(\"version\", versionId);\n t.put(\"ms\", nextLine[12]);\n t.put(\"imageUrl\", nextLine[13]);\n mappingList.add(t);\n \n // generate link from version to artefact\n v.put(\"artefacts\", \"[\\\"\" + artefactId + \"\\\"]\");\n if (!nextLine[0].equals(\"\")){\n // composition event for each work\n HashMap<String,String> e = new HashMap<String,String>();\n e.put(\"artefacts\", \"[\\\"\" + artefactId + \"\\\"]\");\n e.put(\"startDate\", nextLine[3]);\n \n e.put(\"eventType\", \"composition\");\n e.put(\"eventtags\", \"[\\\"composition\\\"]\");\n \n e.put(\"name\", \"\\\\\\\"\" + replaceStupidCharacters(workTitle) + \"\\\\\\\"\");\n eventList.add(e);\n }\n //}\n //}\n } else {\n firstLine = false;\n }\n }\n // versions for last work\n if (currentVersions.size() != 0 && currentWork != null){\n StringBuffer cVers = new StringBuffer();\n cVers.append(\"[\");\n Iterator<String> it = currentVersions.iterator();\n while(it.hasNext()){\n cVers.append(\"\\\"\" + it.next() + \"\\\"\");\n if (it.hasNext()){\n cVers.append(\", \");\n }\n }\n cVers.append(\"]\");\n // for each in currentVersions add new ObjectId(currentVersions[i]) to cVers array\n currentWork.put(\"versions\", cVers.toString());\n }\n \n // iterate over artefact parts, if number of parts is more than 1, add an artefact to represent the source\n for (String k : artefactParts.keySet()) {\n ArrayList<String> parts = artefactParts.get(k);\n if (parts.size() > 1){\n String artefactsString = \"[\";\n for (int j=0; j<parts.size();j++){\n artefactsString += \"\\\"\" + parts.get(j) + \"\\\"\";\n if (j < (parts.size() -1)) {\n artefactsString += \",\";\n }\n }\n artefactsString += \"]\";\n HashMap<String,String> a = new HashMap<String,String>();\n String artefactId = new ObjectId().toString();\n a.put(\"_id\",\"{ \\\"$oid\\\" : \\\"\" + artefactId + \"\\\"}\");\n a.put(\"source\",k);\n a.put(\"artefacts\", artefactsString);\n artefactList.add(a);\n }\n }\n // write works to file\n File outputFile = new File(outputFileName + WORK_COLLECTION + \".json\");\n outputFile.delete();\n outputFile = new File(outputFileName + ARTEFACT_COLLECTION + \".json\");\n outputFile.delete();\n outputFile = new File(outputFileName + VERSION_COLLECTION + \".json\");\n outputFile.delete();\n outputFile = new File(outputFileName + MAPPING_COLLECTION + \".json\");\n outputFile.delete();\n outputFile = new File(outputFileName + EVENT_COLLECTION + \".json\");\n outputFile.delete();\n \n BufferedWriter bw = new BufferedWriter(new OutputStreamWriter(\n new FileOutputStream(outputFileName + WORK_COLLECTION + \".json\"), \"UTF-8\"));\n for (HashMap<String,String> w : workList) {\n bw.write(mapToString(w) + \"\\n\");\n }\n bw.close();\n \n bw = new BufferedWriter(new OutputStreamWriter(\n new FileOutputStream(outputFileName + VERSION_COLLECTION + \".json\"), \"UTF-8\"));\n for (HashMap<String,String> v : versionList) {\n bw.write(mapToString(v) + \"\\n\");\n }\n bw.close();\n \n bw = new BufferedWriter(new OutputStreamWriter(\n new FileOutputStream(outputFileName + ARTEFACT_COLLECTION + \".json\"), \"UTF-8\"));\n for (HashMap<String,String> a : artefactList) {\n bw.write(mapToString(a) + \"\\n\");\n }\n bw.close();\n \n bw = new BufferedWriter(new OutputStreamWriter(\n new FileOutputStream(outputFileName + MAPPING_COLLECTION + \".json\"), \"UTF-8\"));\n for (HashMap<String,String> t : mappingList) {\n bw.write(mapToString(t) + \"\\n\");\n }\n bw.close();\n \n bw = new BufferedWriter(new OutputStreamWriter(\n new FileOutputStream(outputFileName + EVENT_COLLECTION + \".json\"), \"UTF-8\"));\n for (HashMap<String,String> e : eventList) {\n bw.write(mapToString(e) + \"\\n\");\n }\n bw.close();\n\n } catch (IOException e) {\n e.printStackTrace();\n }\n }", "private void fileToPoSTags(String filePath,int version){\n Log.log(\"Reading TreeBank file <\" + filePath +\">\");\n\n FileReader fr = null;\n BufferedReader br = null;\n\n try{\n fr = new FileReader(filePath);\n br = new BufferedReader(fr);\n\n String currentLine;\n String[] columns;\n\n Tag tag1 = null;\n Tag tag2;\n String word;\n\n Integer numRow;\n while((currentLine = br.readLine()) != null){\n columns = currentLine.split(\"\\t\");\n numRow = getIntegerString(columns[0]);\n if(numRow != null && numRow >= 1){\n if(numRow == 1) {\n tag1 = Tag.valueOf(\"START\");\n saveTag(tag1);\n }\n try{\n tag2 = Tag.valueOf(columns[3]);\n saveTag(tag2);\n word = columns[1];\n switch (version){\n case 1:\n savePoSTag(new PoSTag(word.toLowerCase(),tag2));\n break;\n case 2:\n if(!tag2.equals(Tag.PROPN))\n savePoSTag(new PoSTag(word.toLowerCase(),tag2));\n else if(Character.isUpperCase(word.charAt(0)))\n savePoSTag(new PoSTag(word,tag2));\n break;\n case 3:\n\n if(tag2.equals(Tag.PROPN))\n savePoSTag(new PoSTag(word,tag2));\n else{\n if(Character.isUpperCase(word.charAt(0))){\n savePoSTag(new PoSTag(word,tag2));\n savePoSTag(new PoSTag(word.toLowerCase(),tag2));\n }else{\n savePoSTag(new PoSTag(word,tag2));\n savePoSTag(new PoSTag(\n word.substring(0,1).toUpperCase()\n +word.substring(1),tag2));\n }\n\n }\n\n break;\n case 4:\n\n if(!tag2.equals(Tag.PROPN))\n savePoSTag(new PoSTag(word,tag2));\n savePoSTag(new PoSTag(word,tag2));\n break;\n case 5:\n\n if(!tag2.equals(Tag.PROPN))\n savePoSTag(new PoSTag(word.toLowerCase(),tag2));\n savePoSTag(new PoSTag(word,tag2));\n break;\n\n }\n saveBigram(new BiGram(tag1,tag2));\n tag1 = tag2;\n }catch (IllegalArgumentException e){\n e.printStackTrace();\n }\n }\n }\n\n }catch (IOException e){\n e.printStackTrace();\n }finally {\n UtilitiesIO.closeFile(fr,br);\n }\n }", "public void toJMVA() {\r\n \t\tmc = new ModelChecker(model, model, model, model, true);\r\n \t\tpw = new JModelProblemsWindow(mainWindow, mc, this);\r\n \t\tif (!mc.isEverythingOkToJMVA()) {\r\n \t\t\tpw.show();\r\n \t\t}\r\n \t\tif (mc.isEverythingOkToJMVA() || ((!mc.isEverythingOkToJMVA()) && (pw.continued()))) {\r\n \t\t\tif (checkForSave(\"<html>Save changes before switching?</html>\")) {\r\n \t\t\t\treturn;\r\n \t\t\t}\r\n \t\t\t// try {\r\n \t\t\t// New Converter by Bertoli Marco\r\n \t\t\tExactModel output = new ExactModel();\r\n \t\t\tList res = ModelConverter.convertJSIMtoJMVA(model, output);\r\n \t\t\tExactWizard jmva = new ExactWizard(output);\r\n \t\t\t// If problems are found, shows warnings\r\n \t\t\tif (res.size() > 0) {\r\n \t\t\t\tnew WarningWindow(res, jmva, CommonConstants.JSIM, CommonConstants.JMVA).show();\r\n \t\t\t}\r\n \r\n \t\t\t/*\r\n \t\t\t * Old code to use XSLT transformer (really bugged and unfinished)\r\n \t\t\t * \r\n \t\t\t * File xmlTempFile = File.createTempFile(\"~SIMtoMVA\", \".xml\");\r\n \t\t\t * xmlTempFile.deleteOnExit(); File destFile =\r\n \t\t\t * File.createTempFile(\"~MVA\", \".xml\"); destFile.deleteOnExit();\r\n \t\t\t * InputStream stream =\r\n \t\t\t * XSDSchemaLoader.loadSchemaAsStream(XSDSchemaLoader.JSIM_TO_JMVA);\r\n \t\t\t * if(stream==null){ System.out.println(\"stream is null\"); return; }\r\n \t\t\t * XMLWriter.writeXML(xmlTempFile, model); InputStream is = new\r\n \t\t\t * BufferedInputStream(stream); Transformer transformer =\r\n \t\t\t * TransformerFactory.newInstance().newTransformer(new\r\n \t\t\t * StreamSource(is)); StreamSource ssrc = new\r\n \t\t\t * StreamSource(xmlTempFile); StreamResult srst = new\r\n \t\t\t * StreamResult(destFile); transformer.transform(ssrc, srst);\r\n \t\t\t * xmlTempFile.delete(); ExactModel xm = new ExactModel();\r\n \t\t\t * xm.loadDocument(new XMLUtils().loadXML(destFile)); new\r\n \t\t\t * ExactWizard(xm); }catch (Exception e) { handleException(e); }\r\n \t\t\t */\r\n \t\t}\r\n \t}", "public void output(IvyXmlWriter xw,S6SolutionSet ss)\n{\n xw.begin(\"SOLUTION\");\n String code = formatted_code;\n if (code == null) {\n code = getFragment().getFinalText(ss.getSearchType());\n\n }\n formatted_code = null;\n\n// if (code.contains(\"]]>\") || code.contains(\"<![\")) xw.textElement(\"CODE\",code);\n if (code.contains(\"]]>\")) xw.textElement(\"CODE\",code);\n else xw.cdataElement(\"CODE\",code);\n xw.textElement(\"SOLSRC\",for_source.getName());\n xw.textElement(\"NAME\",for_source.getDisplayName());\n xw.textElement(\"LICENSE\",for_source.getLicenseUid());\n\n xw.begin(\"COMPLEXITY\");\n xw.field(\"LINES\",getCodeLines(code));\n xw.field(\"CODE\",getFragment().getCodeComplexity());\n S6TestResults tr = getFragment().getTestResults();\n if (tr != null) xw.field(\"TESTTIME\",tr.getRequiredTime());\n xw.end(\"COMPLEXITY\");\n\n if (transform_set != null) {\n xw.begin(\"TRANSFORMS\");\n for (S6Transform.Memo m : transform_set) {\n\t xw.textElement(\"TRANSFORM\",m.getTransformName());\n }\n xw.end(\"TRANSFORMS\");\n }\n\n xw.end(\"SOLUTION\");\n}", "public VersionedOntology(SwoopModel swoopModel, VersionControl controlHandler, URI repURI, Description[] verDesc) {\r\n\r\n\t\tinit(swoopModel, controlHandler);\r\n\t\t\r\n\t\tthis.repositoryURI = repURI;\r\n\t\tthis.versionDescriptions = verDesc;\r\n\t\t// parse version Description array\r\n\t\ttry {\r\n\t\t\t// first parse header\r\n\t\t\tDescription header = versionDescriptions[0];\r\n\r\n\t\t\t// parse header description to get author, date, baseOntologyURI\r\n\t\t\tthis.repositoryAuthor = header.getAuthor();\r\n\t\t\tthis.reposityCreatedDate = header.getCreated();\r\n\t\t\tthis.baseOntologyURI = new URI(header.getAnnotatedEntityDefinition());\r\n\t\t\t// and headVersionNumber\r\n\t\t\tthis.headVersionNumber = Integer.parseInt(header.getBody());\r\n\t\t\t\r\n\t\t\t// also get actual URL location of annotation\r\n\t\t\tthis.repHeaderLoc = header.getLocation();\r\n\t\t\t\r\n\t\t\t// set UI accordingly\r\n\t\t\tthis.repURLFld.setText(this.repositoryURI.toString());\r\n\t\t\tthis.repAuthorFld.setText(this.repositoryAuthor);\r\n\t\t\tthis.repDateFld.setText(this.reposityCreatedDate);\r\n\t\t\tthis.repBaseOntFld.setText(this.baseOntologyURI.toString());\r\n\t\t\tthis.toggleRepOptions(false);\r\n\t\t\r\n\t\t\t// now for each version, parse and add node to repRoot\r\n\t\t\tfor (int ctr=1; ctr<=this.headVersionNumber; ctr++) {\r\n\t\t\t\tDescription version = versionDescriptions[ctr];\r\n\t\t\t\tTreeTableNode mainNode = this.parseSingleCommit(version);\r\n\t\t\t\t// set params on mainNode\r\n\t\t\t\tmainNode.swoopChange.isOnRepository = true;\r\n\t\t\t\tmainNode.location = version.getLocation();\r\n\t\t\t\tversionNodes[ctr] = mainNode;\r\n\t\t\t}\r\n\t\t\t// again set UI accordingly\r\n\t\t\tthis.refreshRepTreeTable(true);\r\n\t\t\t\r\n\t\t}\r\n\t\tcatch (Exception ex) {\r\n\t\t\tex.printStackTrace();\r\n\t\t}\r\n\t}", "protected void establishTransformationModel() {\r\n\t \r\n\t\tTransformationModel transformModel ;\r\n\t\tArrayList<TransformationStack> modelTransformStacks ;\r\n\t\t\r\n\t\t\r\n\t\t// the variables needed for the profile\r\n\t\t// targetStruc = getTargetVector();\r\n\t\tsomData = soappTransformer.getSomData() ; \r\n\t\t// soappTransformer.setSomData( somApplication.getSomData() );\r\n\t\tsomApplication.setSomData(somData) ;\r\n\t\t\r\n\t\tsomData.getVariablesLabels() ;\r\n\t\t \r\n\t\t\r\n\t\t// from here we transfer...\r\n\t\tmodelTransformStacks = soappTransformer.getTransformationModel().getVariableTransformations();\r\n\t\ttransformModel = soappTransformer.getTransformationModel() ;\r\n\t\t \r\n\t\t\r\n\t\ttransformationModelImported = true;\r\n\t}", "public static Vertical toModel(VerticalSoap soapModel) {\n Vertical model = new VerticalImpl();\n\n model.setId(soapModel.getId());\n model.setDescription(soapModel.getDescription());\n model.setEdition(soapModel.getEdition());\n\n return model;\n }", "private ModelVersion getCoreModelVersionByLegacyModelVersion(ModelVersion legacyModelVersion) {\n\n if (System.getProperty(\"jboss.test.core.model.version.override\") != null) {\n return ModelVersion.fromString(System.getProperty(\"jboss.test.core.model.version.override\"));\n }\n\n ModelVersion coreModelVersion = KnownVersions.getCoreModelVersionForSubsystemVersion(mainSubsystemName, legacyModelVersion);\n if (coreModelVersion != null) {\n return coreModelVersion;\n }\n\n String fileName = mainSubsystemName + \"-versions-to-as-versions.properties\";\n\n InputStream in = this.getClass().getResourceAsStream(\"/\" + fileName);\n if (in == null) {\n throw new IllegalArgumentException(\"Version \" + legacyModelVersion + \" of \" + mainSubsystemName + \" is not a known version. Please add it to \" +\n KnownVersions.class.getName() + \". Or if that is not possible, \" +\n \"include a src/test/resources/\" + fileName +\n \" file, which maps AS versions to model versions. E.g.:\\n1.1.0=7.1.2\\n1.2.0=7.1.3\");\n }\n Properties props = new Properties();\n try {\n props.load(in);\n } catch (IOException e) {\n throw new RuntimeException(e);\n } finally {\n IoUtils.safeClose(in);\n }\n\n String asVersion = (String)props.get(legacyModelVersion.toString());\n if (asVersion == null) {\n throw new IllegalArgumentException(\"src/test/resources/\" + fileName +\n \" does not contain an AS mapping for modelversion + \" +\n legacyModelVersion + \"'. It needs to map AS versions to model versions. E.g.:\\n1.1.0=7.1.2\\n1.2.0=7.1.3\");\n }\n\n coreModelVersion = KnownVersions.AS_CORE_MODEL_VERSION_BY_AS_VERSION.get(asVersion);\n if (coreModelVersion == null) {\n throw new IllegalArgumentException(\"Unknown AS version '\" + asVersion + \"' determined from src/test/resources/\" + fileName +\n \". Known AS versions are \" + KnownVersions.AS_CORE_MODEL_VERSION_BY_AS_VERSION.keySet());\n }\n return coreModelVersion;\n }", "SModel getOutputModel();", "public static void pruebaVisitor(String path) {\n\t\ttry {\n\t\t\t/*in = new FileInputStream(f);\n\t\t\tfinal CSharpLexer lexer = new CSharpLexer(CharStreams.fromStream(in, StandardCharsets.UTF_8));\n\t\t\t\n\t // create an instance of myWeb\n\t\t\tCSharpParser parser = new CSharpParser(new CommonTokenStream(lexer));\n\t\t\t\t\n\t\t\tSystem.out.println(\" parser -> \" + parser.toString());\n\t\t\tParseTree tree = parser.compilation_unit();*/\n\t\t\t\n\t\t\tCSharpArchIdFactory factory = CSharpArchIdFactory.eINSTANCE;\n\t\t\tModel model = factory.createModel();\n\t\t\tmodel.setName(\"CSharpModel\");\n\t\t\tprocessFiles(path, model, \"eShopOnWeb-master\");\n\t\t\t\n\t\t\tSystem.out.println(\" modelo -> \" + model);\n\t\t\tResource.Factory.Registry reg = Resource.Factory.Registry.INSTANCE;\n\t Map<String, Object> m = reg.getExtensionToFactoryMap();\n\t m.put(\"model\", new XMIResourceFactoryImpl());\n\n\t // Obtain a new resource set\n\t ResourceSet resSet = new ResourceSetImpl();\n\n\t // create a resource\n\t Resource resource = resSet.createResource(URI\n\t .createURI(\"CSharpArchId.model\"));\n\t // Get the first model element and cast it to the right type, in my\n\t // example everything is hierarchical included in this first node\n\t resource.getContents().add(model);\n\t resource.save(Collections.EMPTY_MAP);\n\t \n\t EPLHandler handler = new EPLHandler(null);\n\t //handler.execute(null);\n\t \n\t\t} catch (IOException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\n\t}", "String deploymentModel();", "private Model generateModel(String groupId, String artifactId, String version) {\n \n Model model = new Model();\n \n model.setModelVersion(\"4.0.0\");\n model.setGroupId(groupId);\n model.setArtifactId(artifactId);\n model.setVersion(version);\n model.setPackaging(HaxeFileExtensions.HAXELIB);\n model.setDescription(\"POM was created from Haxemojos\");\n \n return model;\n }", "public interface SVNService {\n public Map<String, String> getLatestFileCheckout(String svnUrl, String sourceDir, String svnId, String svnPassword, int startRevision, int endRevision) throws Exception;\n public Map<String, String> getLatestFileCheckout(ProjectParam param) throws Exception;\n public Map<String, String> getRepositorypaths(String svnUrl, String svnId, String svnPassword, int startRevision, int endRevision) throws Exception;\n public boolean compileComplete(String sourceDir, String sourceWWWDir, String sourceLibDir, String sourceDeployDir) throws Exception;\n public boolean compileComplete(ProjectParam valid) throws IOException;\n\n public boolean svnConnectionCheck(String svnId, String svnPassword);\n}", "public interface VersiontableModel extends BaseModel {\n\n /**\n * Get the {@code version_name} value.\n * Can be {@code null}.\n */\n @Nullable\n String getVersionName();\n\n /**\n * Get the {@code version_id} value.\n * Can be {@code null}.\n */\n @Nullable\n Integer getVersionId();\n\n /**\n * Get the {@code model_id} value.\n * Can be {@code null}.\n */\n @Nullable\n Integer getModelId();\n\n /**\n * Get the {@code fuel_type} value.\n * Can be {@code null}.\n */\n @Nullable\n String getFuelType();\n}", "ZenModel createZenModel();", "private static void generModeloDePrueba() {\n\t\tCSharpArchIdPackageImpl.init();\n // Retrieve the default factory singleton\n\t\tCSharpArchIdFactory factory = CSharpArchIdFactory.eINSTANCE;\n // create an instance of myWeb\n\t\tModel modelo = factory.createModel();\n\t\tmodelo.setName(\"Prueba\"); \n // create a page\n\t\tCompileUnit cu = factory.createCompileUnit();\n\t\tcu.setName(\"archivo.cs\");\n\t\tClassDeclaration clase = factory.createClassDeclaration();\n\t\t//clase.setName(\"Sumar\");\n\t\t//cu.getTypeDeclaration().add(clase);\n modelo.getCompileUnits().add(cu);\n \n Resource.Factory.Registry reg = Resource.Factory.Registry.INSTANCE;\n Map<String, Object> m = reg.getExtensionToFactoryMap();\n m.put(\"model\", new XMIResourceFactoryImpl());\n\n // Obtain a new resource set\n ResourceSet resSet = new ResourceSetImpl();\n\n // create a resource\n Resource resource = resSet.createResource(URI\n .createURI(\"CSharpArchId.model\"));\n // Get the first model element and cast it to the right type, in my\n // example everything is hierarchical included in this first node\n resource.getContents().add(modelo);\n\n // now save the content.\n try {\n resource.save(Collections.EMPTY_MAP);\n } catch (IOException e) {\n // TODO Auto-generated catch block\n e.printStackTrace();\n }\n\t\t\n // and so on, and so on\n // as you can see the EMF model can be (more or less) used as standard Java\n\t}", "public interface Version {\n\n /**\n * Check if this version is a major version.\n * \n * @return true if major version, false if it is a minor version\n */\n boolean isMajor();\n\n /**\n * Check if this version is a private working copy.\n * \n * @return true if it a PWC, false if not\n */\n boolean isPwc();\n\n /**\n * make the private working copy an official version.\n * \n * @param isMajor\n * true if major version, false if it is a minor version\n */\n void commit(boolean isMajor);\n\n /**\n * Set the check.in comment.\n * \n * @param comment\n * check-in comment\n */\n void setCheckinComment(String comment);\n\n /**\n * Get the check-in comment.\n * \n * @return check-in comment\n */\n String getCheckinComment();\n\n /**\n * Get the version label.\n * \n * @return the version label\n */\n String getVersionLabel();\n\n /**\n * Get the versioned document (parent) of this version.\n * \n * @return versioned document\n */\n VersionedDocument getParentDocument();\n}", "public void setSvnUrl(String url) {\r\n this.svnUrl = url;\r\n }", "public static com.glority.qualityserver.model.TestCase convertToServerModel(\n com.glority.quality.model.TestCase testCase) {\n com.glority.qualityserver.model.TestCase sTestCase = new com.glority.qualityserver.model.TestCase();\n\n if (testCase != null) {\n sTestCase.setName(testCase.getName());\n if (testCase.getTime() != null) {\n sTestCase.setTime(new Float(testCase.getTime()).floatValue());\n }\n sTestCase.setResult(testCase.getResult());\n sTestCase.setSvnUrl(testCase.getSvnUrl());\n sTestCase.setSvnRevision(testCase.getSvnRevision());\n }\n\n return sTestCase;\n }", "Mesh toModel(Mesh result);", "public VersionModel() {\n }", "public void generateRevisionOutput(RevisionResult resultAllAnalyzed);", "public static void convertBookToBookVO() {\n\t\t// TODDO\n\t}", "Collection<String> createVersion(Workspace workspace, Collection<String> paths) throws RepositoryException;", "public interface IModelRoot extends org.eclipse.wst.sse.sieditor.core.editorfwk.IModelObject {\n\n public boolean addChangeListener(IChangeListener listener);\n\n public boolean removeChangeListener(IChangeListener listener);\n\n public void notifyListeners(IModelChangeEvent event);\n\n public IEnvironment getEnv();\n\n public IModelObject getModelObject();\n\n /**\n * \n * @return the root of all models or this if this is the root of all models\n */\n public IModelRoot getRoot();\n \n}", "private void parseTree(BufferedReader in, VssProject vssProject) {\r\n try {\r\n String line;\r\n boolean start = false;\r\n while ((line = in.readLine()) != null) {\r\n if (!start) {\r\n if (line.startsWith(\"$\") && line.endsWith(\":\")) {\r\n start = true;\r\n continue;\r\n }\r\n } else {\r\n if (line.length() == 0)\r\n break;\r\n if (line.startsWith(\"$\")) {\r\n \t\r\n String projectName = line.substring(1);\r\n if ( config.getProjectsToIgnore().contains( projectName ) )\r\n \t\t\t\t\t{\r\n \t\t\t\t\t\t// Ignore list!\r\n \t\t\t\t\t\tLOG.warn( \"Ignore project \" + projectName + \" found in : \" + vssProject.getVssPath() );\r\n \t\t\t\t\t\tcontinue;\r\n \t\t\t\t\t}\r\n \r\n VssProject newProject = new VssProject();\r\n newProject.setName(projectName);\r\n newProject.setParent(vssProject);\r\n vssProject.addSubproject(newProject);\r\n \r\n } else \r\n {\r\n if (line.startsWith(\"No items found under $\")) {\r\n continue;\r\n } \r\n String filename = line;\r\n String parent = vssProject.getVssPath().substring(config.getProject().length());\r\n if (parent.length() > 0) {\r\n if (parent.startsWith(\"/\"))\r\n parent = parent.substring(1);\r\n if (!parent.endsWith(\"/\"))\r\n parent += \"/\";\r\n }\r\n String path = parent + filename;\r\n VssFile newFile = new VssFile(path, filename);\r\n newFile.setParent(vssProject);\r\n vssProject.addFile(newFile);\r\n }\r\n }\r\n }\r\n } catch (IOException e) {\r\n throw new VssException(\"readLine\", e);\r\n }\r\n }", "public abstract org.acorns.lesson.Lesson convert(float version) throws IOException;", "private String buildSvnCommand(final String subCmd) {\n final StringBuilder command = new StringBuilder(svn + ' ');\n command.append(subCmd);\n return command.toString();\n }", "public static void convertBookVOToBook() {\n\n\t}", "public SSModel createSSObject() {\n\t\tSSModel ssModel = new SSModel();\n\t\tssModel.create(mol);\n\t\t\n\t\treturn ssModel;\n\t}", "private IPluginVersion toVersion( Version version ) {\n IPluginVersion pluginVersion = this.pluginVersionFactory.create();\n\n //fill the instance\n pluginVersion.setBranch( version.getBranch() );\n pluginVersion.setName( version.getName() );\n String downloadUrl = version.getPackageUrl();\n if ( downloadUrl != null ) {\n downloadUrl = downloadUrl.trim();\n pluginVersion.setDownloadUrl( downloadUrl );\n pluginVersion.setIsOsgi( downloadUrl.endsWith( OSGI_URL_SUFFIX ) );\n }\n pluginVersion.setVersion( version.getVersion() );\n pluginVersion.setSamplesDownloadUrl( version.getSamplesUrl() );\n pluginVersion.setDescription( version.getDescription() );\n pluginVersion.setChangelog( version.getChangelog() );\n pluginVersion.setBuildId( version.getBuildId() );\n //pluginVersion.setReleaseDate( version.getReleaseDate() );\n pluginVersion.setMinParentVersion( version.getMinParentVersion() );\n pluginVersion.setMaxParentVersion( version.getMaxParentVersion() );\n\n // TODO: use factory for DI?\n org.pentaho.marketplace.domain.model.entities.serialization.jaxb.dto.DevelopmentStage dtoDevStage = version.getDevelopmentStage();\n if ( dtoDevStage != null ) {\n IDevelopmentStage devStage = new DevelopmentStage( dtoDevStage.getLane().value(),\n String.valueOf( dtoDevStage.getPhase() ) );\n pluginVersion.setDevelopmentStage( devStage );\n }\n\n //return the instance\n return pluginVersion;\n }", "public interface Transformer {\n\t/**\n\t * \n\t * @param srcComp an instance of the old version component\n\t * @param targetComp and instance of the new version component\n\t * @return\n\t */\n\tpublic boolean transform(Object srcComp, Object targetComp);\n\n}", "public ModelNode readTransformedModel(ModelVersion modelVersion) {\n getLegacyServices(modelVersion);//Checks we are the main controller\n ModelNode op = new ModelNode();\n op.get(OP).set(READ_TRANSFORMED_RESOURCE_OPERATION);\n op.get(OP_ADDR).set(PathAddress.EMPTY_ADDRESS.toModelNode());\n op.get(RECURSIVE).set(true);\n op.get(SUBSYSTEM).set(mainSubsystemName);\n ModelNode result = internalExecute(op, new ReadTransformedResourceOperation(getTransformersRegistry(), getCoreModelVersionByLegacyModelVersion(modelVersion), modelVersion));\n return ModelTestUtils.checkResultAndGetContents(result);\n }", "public static List<Vertical> toModels(VerticalSoap[] soapModels) {\n List<Vertical> models = new ArrayList<Vertical>(soapModels.length);\n\n for (VerticalSoap soapModel : soapModels) {\n models.add(toModel(soapModel));\n }\n\n return models;\n }", "public void createRepository() throws VcsException {\n final FossilSimpleCommand fossilCommand = new FossilSimpleCommand(myProject, myRepoPath.getParentFile(), FCommandName.new_);\n fossilCommand.addParameters(myRepoPath.getPath());\n String result = fossilCommand.run();\n result = result.replace(\"\\r\", \"\");\n final String[] split = result.split(\"\\n\");\n final List<String> lines = new ArrayList<String>(3);\n for (String line : split) {\n if (! StringUtil.isEmptyOrSpaces(line)) {\n lines.add(line.trim());\n }\n }\n\n if (lines.size() != 3) {\n throw new FossilException(\"Can not parse 'new' output: '\" + result + \"'\");\n }\n final String[] expectedHeaders = {\"project-id:\", \"server-id:\", \"admin-user:\"};\n for (int i = 0; i < lines.size(); i++) {\n final String line = lines.get(i);\n if (! line.startsWith(expectedHeaders[i])) {\n throw new FossilException(\"Can not parse 'new' output, line #\" + (i + 1) + \": '\" + result + \"'\");\n }\n }\n myProjectId = new String(lines.get(0).substring(expectedHeaders[0].length() + 1));\n myServerId = new String(lines.get(1).substring(expectedHeaders[1].length()) + 1);\n final String userPswd = lines.get(2).substring(expectedHeaders[2].length()).trim();\n final int idxSpace = userPswd.indexOf(' ');\n if (idxSpace == -1) {\n throw new FossilException(\"Can not parse 'new' output, user-password area: '\" + result + \"'\");\n }\n myUserName = new String(userPswd.substring(0, idxSpace));\n final int quot1 = userPswd.indexOf('\"', idxSpace + 1);\n int quot2 = -1;\n if (quot1 >= 0) {\n quot2 = userPswd.indexOf('\"', quot1 + 1);\n }\n if (quot1 == -1 || quot2 == -1) {\n throw new FossilException(\"Can not parse 'new' output, user-password area: '\" + result + \"'\");\n }\n myPassword = userPswd.substring(quot1 + 1 , quot2);\n }", "public static org.cidarlab.raven.datastructures.Vector phoenixVectorToRavenVector(Vector pVector, String level) {\n \n //Get parameters for Raven\n String vecSeq = pVector.getSequence().getSeq();\n HashMap<String, String> moCloOHs = reverseKeysVals(PrimerDesign.getMoCloOHseqs());\n String moCloLO;\n String moCloRO;\n String resistance;\n \n //If both ends match MoClo overhangs, add them as overhangs\n moCloLO = moCloOHs.get(vecSeq.substring(vecSeq.length() - 4).toLowerCase());\n moCloRO = moCloOHs.get(vecSeq.substring(0, 4).toLowerCase()); \n \n //Get the resistance\n resistance = pVector.getResistance().getName().replaceAll(\".ref\", \"\");\n \n org.cidarlab.raven.datastructures.Vector newVector;\n if (level == null) {\n newVector = org.cidarlab.raven.datastructures.Vector.generateVector(pVector.getName().substring(0, pVector.getName().indexOf(\"vector\")-1), pVector.getSequence().getSeq(), \"\", \"\", \"vector\", \"\", \"\", resistance, -1);\n newVector.setTransientStatus(false);\n } else {\n newVector = org.cidarlab.raven.datastructures.Vector.generateVector(pVector.getName().substring(0, pVector.getName().indexOf(\"vector\")-1), pVector.getSequence().getSeq(), moCloLO, moCloRO, \"destination vector\", pVector.getName(), \"lacZ|\" + moCloLO + \"|\" + moCloRO + \"|+\", resistance, Integer.valueOf(level));\n newVector.setTransientStatus(false);\n }\n\n return newVector;\n }", "private static String newModel(Request req) {\n\n if( req.params(\"Version\").equals(\"Updated\") ) {\n\n // make new model, make gson object, convert model to json using gson\n BattleshipModelUpdated game = new BattleshipModelUpdated();\n Gson gson = new Gson();\n return gson.toJson( game );\n\n }else{\n\n // make new model, make gson object, convert model to json using gson\n BattleshipModelNormal game = new BattleshipModelNormal();\n Gson gson = new Gson();\n return gson.toJson( game );\n\n }\n }", "public interface SmooksTransformModel extends TransformModel {\n\n /** The \"smooks\" name. */\n public static final String SMOOKS = \"smooks\";\n\n /** The \"config\" name. */\n public static final String CONFIG = \"config\";\n \n /** The \"type\" name. */\n public static final String TYPE = \"type\";\n\n /** The \"reportPath\" name. */\n public static final String REPORT_PATH = \"reportPath\";\n \n /**\n * Gets the type attribute.\n * @return the type attribute\n */\n public String getTransformType();\n\n /**\n * Sets the type attribute.\n * @param type the type attribute\n * @return this SmooksTransformModel (useful for chaining)\n */\n public SmooksTransformModel setTransformType(String type);\n\n /**\n * Gets the config attribute.\n * @return the config attribute\n */\n public String getConfig();\n\n\n /**\n * Sets the config attribute.\n * @param config the config attribute\n * @return this SmooksTransformModel (useful for chaining)\n */\n public SmooksTransformModel setConfig(String config);\n\n /**\n * Gets the reportPath attribute.\n * @return the reportPath attribute\n */\n public String getReportPath();\n\n /**\n * Sets the reportPath attribute.\n * @param reportPath the reportPath attribute\n * @return this SmooksTransformModel (useful for chaining)\n */\n public SmooksTransformModel setReportPath(String reportPath);\n\n}", "private Submodel fixUniqueVars()\n {\n Submodel model = new Submodel();\n model.setInvariant(true);\n\n _fixUniqueVars_Helper(model);\n \n return model;\n }", "public void guardarRevisionesOficiales(){\r\n \tConnection conn = null;\r\n \tPreparedStatement ps = null;\r\n \ttry{\r\n\t \tconn = getDBConnection();\r\n \t\tStringBuffer consultaTable = new StringBuffer(\"(select c.id_table from layers l, attributes a,columns c \");\r\n \t\tconsultaTable = consultaTable.append(\"where l.id_layer = a.id_layer and a.id_column = c.id \");\r\n \t\tconsultaTable = consultaTable.append(\"and a.position = 1 and l.name = ?)\");\r\n\t \tStringBuffer sbSQL = new StringBuffer(\"update versiones set oficial=?, mensaje =? where revision=? \");\r\n\t \tsbSQL = sbSQL.append(\"and id_table_versionada = \");\r\n\t \tsbSQL = sbSQL.append(consultaTable.toString());\r\n\t \tps = conn.prepareStatement(sbSQL.toString());\r\n\t \tint n = model.getRowCount();\r\n\t \tfor (int i=0;i<n;i++){\r\n\t \t\tps.setInt(1, (Boolean)model.getValueAt(i,3)==true?1:0);\r\n\t \t\tps.setString(2, (String)model.getValueAt(i, 4));\r\n\t \t\tps.setLong(3, (Long)model.getValueAt(i, 0));\r\n\t \t\tps.setString(4, this.layer.getSystemId());\r\n\t \t\tps.executeUpdate();\r\n\t \t}\r\n\t JOptionPane.showMessageDialog(this,I18N.get(\"Version\",\"DatosRevisionGuardados\"));\r\n \t}catch(Exception e){\r\n JOptionPane.showMessageDialog(this,e.getMessage());\r\n\t}finally{\r\n aplicacion.closeConnection(conn, ps, null, null);\r\n\t}\r\n }", "public static void correctXrefCaseSensitivity(Model model) throws MolgenisModelException\r\n\t{\r\n\t\tlogger.debug(\"correct case of names in xrefs...\");\r\n\t\tfor (Entity e : model.getEntities())\r\n\t\t{\r\n\t\t\tfor (Field f : e.getFields())\r\n\t\t\t{\r\n\t\t\t\t// f.setName(f.getName().toLowerCase());\r\n\r\n\t\t\t\tif (f.getType() instanceof XrefField || f.getType() instanceof MrefField)\r\n\t\t\t\t{\r\n\t\t\t\t\ttry\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t// correct for uppercase/lowercase typo's\r\n\t\t\t\t\t\tEntity xrefEntity = f.getXrefEntity();\r\n\t\t\t\t\t\tf.setXRefEntity(xrefEntity.getName());\r\n\r\n\t\t\t\t\t\tString xrefField = f.getXrefField().getName();\r\n\r\n\t\t\t\t\t\tList<String> xrefLabels = f.getXrefLabelsTemp();\r\n\t\t\t\t\t\tList<String> correctedXrefLabels = new ArrayList<String>();\r\n\t\t\t\t\t\tfor (String xrefLabel : xrefLabels)\r\n\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\tcorrectedXrefLabels.add(xrefEntity.getAllField(xrefLabel).getName());\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\tf.setXRefVariables(xrefEntity.getName(), xrefField, correctedXrefLabels);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tcatch (Exception exception)\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t// exception.printStackTrace();\r\n\t\t\t\t\t\t// logger.error(exception);\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}", "public void createModelFromAlloy(){\n\t\t// Get signatures list\n\t\tSafeList<Sig> sigs = module.getAllSigs();\n\t\t// Check if the list is empty\n\t\tif(sigs.isEmpty()) assertMessage(\"Error in create Model FromAlloy: no sig found!\");\n\t\t// Generate java class source file for one top-level sig at a time\n\t\tfor(int i = 0; i<sigs.size(); i++) {\n\t\t\tSig aSig = sigs.get(i);\n\t\t\tif (!aSig.isTopLevel()) continue;\n\t\t\tif(!aSig.builtin){ // User-defined sig\n\t\t\t\tif(aSig.isSubsig != null){\n\t\t\t\t\tPrimSig pSig = (PrimSig) aSig;\n\t\t\t\t\trecursiveGenerate(null, pSig);\t\n\t\t\t\t} else assertMessage(\"TODO: Dealt with subset sig\");\n\t\t\t}\n\t\t\telse assertMessage(\"TODO: Dealt with built-in sig\");\n\t\t}\n\t}", "@Override\n\tpublic void svnLogPrepare() {\n\t}", "public void createTranslation(File srcFile, File destFile, File modelFile, File ignoreFile,\n\t\t\tboolean onlyCopyModelFile) {\n\n\t\tcheckArgs(srcFile, destFile, modelFile);\n\t\tensureFile(destFile);\n\n\t\tMap<String, Element> srcFileStringMap = null;\n\t\tif (onlyCopyModelFile) {\n\t\t\tsrcFileStringMap = new LinkedHashMap<String, Element>();\n\t\t} else {\n\t\t\tsrcFileStringMap = mXmlParser.getStringMapByFile(srcFile);\n\t\t}\n\t\tMap<String, Element> modelFileStringMap = mXmlParser.getStringMapByFile(modelFile);\n\t\tMap<String, Element> ignoreFileStringMap = mXmlParser.getStringMapByFile(ignoreFile);\n\n\t\tIterator<Entry<String, Element>> modelFileIterator = modelFileStringMap.entrySet().iterator();\n\t\twhile (modelFileIterator.hasNext()) {\n\t\t\tEntry<String, Element> next = modelFileIterator.next();\n\t\t\tif (srcFileStringMap.containsKey(next.getKey()) || ignoreFileStringMap.containsKey(next.getKey())) {\n\t\t\t\tmodelFileIterator.remove();\n\t\t\t}\n\t\t}\n\n\t\tMap<String, Element> diffMap = modelFileStringMap;\n\t\tmXmlParser.setStringMapToFile(diffMap, destFile);\n\t}", "public void storeWorkflow(String lsid, ScuflModel model)\n throws DataServiceException {\n XScuflView view = new XScuflView(model);\n Document doc = view.getDocument();\n model.removeListener(view);\n XMLOutputter xo = new XMLOutputter(Format.getPrettyFormat());\n String xmlRepresentation = xo.outputString(doc);\n Connection con = pool.borrowConnection();\n try {\n synchronized (writeLockObject) {\n PreparedStatement st = con\n .prepareStatement(\"INSERT INTO workflow (lsid, workflow) VALUES (?,?)\");\n st.setString(1, lsid);\n st.setString(2, xmlRepresentation);\n st.executeUpdate();\n st.close();\n con.commit();\n }\n } catch (SQLException ex) {\n try {\n con.rollback();\n } catch (SQLException sqlex) {\n log.warn(\"Could not rollback\");\n }\n throw new DataServiceException(ex);\n } finally {\n pool.returnConnection(con);\n }\n }", "private int cloneByTrans(HttpServletRequest request, LineCodeMapper lcMapper, PrmVersionMapper pvMapper, LineCode po, PrmVersion prmVersion) throws Exception {\n TransactionStatus status = null;\r\n List<PrmVersion> prmVersions;\r\n // String versionNoMax;\r\n int n = 0;\r\n int n1 = 0;\r\n try {\r\n\r\n // txMgr = DBUtil.getDataSourceTransactionManager(request);\r\n status = txMgr.getTransaction(this.def);\r\n\r\n //删除草稿版本\r\n lcMapper.deleteLineCodeForClone(po);\r\n //未来或当前参数克隆成草稿版本\r\n n = lcMapper.cloneFromCurOrFurToDraft(po);\r\n //更新参数版本索引信息\r\n pvMapper.modifyPrmVersionForDraft(po);\r\n\r\n txMgr.commit(status);\r\n } catch (Exception e) {\r\n if (txMgr != null) {\r\n txMgr.rollback(status);\r\n }\r\n throw e;\r\n }\r\n return n;\r\n }", "@Test\n public void testVersioningInitialState() {\n\n String id = objService.createDocument(repositoryId, createBaseDocumentProperties(\"newdoc2\", \"cmis:document\"),\n rootFolderId, null, VersioningState.MAJOR, null, null, null, null);\n ObjectData ob = getObject(id);\n\n checkValue(PropertyIds.IS_LATEST_VERSION, Boolean.TRUE, ob);\n checkValue(PropertyIds.IS_MAJOR_VERSION, Boolean.TRUE, ob);\n checkValue(PropertyIds.IS_LATEST_MAJOR_VERSION, Boolean.TRUE, ob);\n checkValue(PropertyIds.VERSION_LABEL, \"1.0\", ob);\n checkValue(PropertyIds.VERSION_SERIES_ID, NOT_NULL, ob);\n checkValue(PropertyIds.IS_VERSION_SERIES_CHECKED_OUT, Boolean.FALSE, ob);\n checkValue(PropertyIds.VERSION_SERIES_CHECKED_OUT_ID, null, ob);\n checkValue(PropertyIds.VERSION_SERIES_CHECKED_OUT_BY, null, ob);\n checkValue(PropertyIds.CHECKIN_COMMENT, null, ob);\n checkValue(NuxeoTypeHelper.NX_ISVERSION, Boolean.FALSE, ob); // ...\n\n // copy from checked in source as checked out\n\n id = objService.createDocumentFromSource(repositoryId, id, null, rootFolderId, VersioningState.CHECKEDOUT, null,\n null, null, null);\n ob = getObject(id);\n checkValue(PropertyIds.IS_LATEST_VERSION, Boolean.FALSE, ob);\n checkValue(PropertyIds.IS_MAJOR_VERSION, Boolean.FALSE, ob);\n checkValue(PropertyIds.IS_LATEST_MAJOR_VERSION, Boolean.FALSE, ob);\n checkValue(PropertyIds.VERSION_LABEL, null, ob);\n checkValue(PropertyIds.VERSION_SERIES_ID, NOT_NULL, ob);\n checkValue(PropertyIds.IS_VERSION_SERIES_CHECKED_OUT, Boolean.TRUE, ob);\n checkValue(PropertyIds.VERSION_SERIES_CHECKED_OUT_ID, id, ob);\n checkValue(PropertyIds.VERSION_SERIES_CHECKED_OUT_BY, USERNAME, ob);\n checkValue(PropertyIds.CHECKIN_COMMENT, null, ob);\n checkValue(NuxeoTypeHelper.NX_ISVERSION, Boolean.FALSE, ob);\n\n // creation as minor version\n\n id = objService.createDocument(repositoryId, createBaseDocumentProperties(\"newdoc2\", \"cmis:document\"),\n rootFolderId, null, VersioningState.MINOR, null, null, null, null);\n ob = getObject(id);\n\n checkValue(PropertyIds.IS_LATEST_VERSION, Boolean.TRUE, ob);\n checkValue(PropertyIds.IS_MAJOR_VERSION, Boolean.FALSE, ob);\n checkValue(PropertyIds.IS_LATEST_MAJOR_VERSION, Boolean.FALSE, ob);\n checkValue(PropertyIds.VERSION_LABEL, \"0.1\", ob);\n checkValue(PropertyIds.VERSION_SERIES_ID, NOT_NULL, ob);\n checkValue(PropertyIds.IS_VERSION_SERIES_CHECKED_OUT, Boolean.FALSE, ob);\n checkValue(PropertyIds.VERSION_SERIES_CHECKED_OUT_ID, null, ob);\n checkValue(PropertyIds.VERSION_SERIES_CHECKED_OUT_BY, null, ob);\n checkValue(PropertyIds.CHECKIN_COMMENT, null, ob);\n checkValue(NuxeoTypeHelper.NX_ISVERSION, Boolean.FALSE, ob); // ...\n\n // creation checked out\n\n id = objService.createDocument(repositoryId, createBaseDocumentProperties(\"newdoc3\", \"cmis:document\"),\n rootFolderId, null, VersioningState.CHECKEDOUT, null, null, null, null);\n ob = getObject(id);\n\n checkValue(PropertyIds.IS_LATEST_VERSION, Boolean.FALSE, ob);\n checkValue(PropertyIds.IS_MAJOR_VERSION, Boolean.FALSE, ob);\n checkValue(PropertyIds.IS_LATEST_MAJOR_VERSION, Boolean.FALSE, ob);\n checkValue(PropertyIds.VERSION_LABEL, null, ob);\n checkValue(PropertyIds.VERSION_SERIES_ID, NOT_NULL, ob);\n checkValue(PropertyIds.IS_VERSION_SERIES_CHECKED_OUT, Boolean.TRUE, ob);\n checkValue(PropertyIds.VERSION_SERIES_CHECKED_OUT_ID, id, ob);\n checkValue(PropertyIds.VERSION_SERIES_CHECKED_OUT_BY, USERNAME, ob);\n checkValue(PropertyIds.CHECKIN_COMMENT, null, ob);\n checkValue(NuxeoTypeHelper.NX_ISVERSION, Boolean.FALSE, ob);\n\n // copy from checked out source as checked in\n\n id = objService.createDocumentFromSource(repositoryId, id, null, rootFolderId, VersioningState.MAJOR, null,\n null, null, null);\n ob = getObject(id);\n checkValue(PropertyIds.IS_LATEST_VERSION, Boolean.TRUE, ob);\n checkValue(PropertyIds.IS_MAJOR_VERSION, Boolean.TRUE, ob);\n checkValue(PropertyIds.IS_LATEST_MAJOR_VERSION, Boolean.TRUE, ob);\n checkValue(PropertyIds.VERSION_LABEL, \"1.0\", ob);\n checkValue(PropertyIds.VERSION_SERIES_ID, NOT_NULL, ob);\n checkValue(PropertyIds.IS_VERSION_SERIES_CHECKED_OUT, Boolean.FALSE, ob);\n checkValue(PropertyIds.VERSION_SERIES_CHECKED_OUT_ID, null, ob);\n checkValue(PropertyIds.VERSION_SERIES_CHECKED_OUT_BY, null, ob);\n checkValue(PropertyIds.CHECKIN_COMMENT, null, ob);\n checkValue(NuxeoTypeHelper.NX_ISVERSION, Boolean.FALSE, ob); // ...\n }", "private void mapVaccinesAndBranchToModel(List<VaccinesInBranchEntity> vaccinesInBranchEntities,\n\t\t\tList<Branch> branchs) {\n\t\tif (null != vaccinesInBranchEntities && !vaccinesInBranchEntities.isEmpty()) {\n\t\t\tBranch branch = mapEntityToModel(vaccinesInBranchEntities.get(0).getBranch());\n\t\t\tvaccinesInBranchEntities.forEach(\n\t\t\t\t\tvaccine -> mapVaccineEntityToBranchModel(vaccine.getVaccine(), vaccine.getQuantity(), branch));\n\t\t\tbranchs.add(branch);\n\t\t}\n\t}", "public static Model copyModel(Model base) {\n BNodeReplacer rep = new BNodeReplacer();\n Model newModel = ModelFactory.createDefaultModel();\n StmtIterator it = base.listStatements();\n Statement st;\n Node s;\n Node p;\n Node o;\n while (it.hasNext()) {\n st = it.nextStatement();\n s = st.getSubject().asNode();\n p = st.getPredicate().asNode();\n o = st.getObject().asNode();\n if (s.isBlank()) s = newModel.createResource(rep.getNew(s.getBlankNodeId())).asNode();\n if (p.isBlank()) p = newModel.createResource(rep.getNew(p.getBlankNodeId())).asNode();\n if (o.isBlank()) o = newModel.createResource(rep.getNew(o.getBlankNodeId())).asNode();\n newModel.getGraph().add(new Triple(s, p, o));\n }\n it.close();\n newModel.setNsPrefixes(base.getNsPrefixMap());\n return newModel;\n }", "protected static String getDataStoreSourceFromVpms(NbaLob lob) throws NbaBaseException {\n\t\tNbaVpmsAdaptor vpmsProxy = null;\n\t\ttry {\n\t\t if(getLogger().isDebugEnabled()) { //SPR3290\n\t\t getLogger().logDebug(\"Starting retrieval of Data Store Mode from VP/MS model\");\n\t\t } //SPR3290\n\t\t\tNbaOinkDataAccess oinkData = new NbaOinkDataAccess(lob);\n\t\t\toinkData.getFormatter().setDateSeparator(NbaOinkDefaultFormatter.DATE_SEPARATOR_DASH);\n\t\t\tvpmsProxy = new NbaVpmsAdaptor(oinkData, NbaVpmsAdaptor.DETERMINE_DATA_STORE_MODE);\n\t\t\tvpmsProxy.setVpmsEntryPoint(NbaVpmsAdaptor.EP_GET_DATASTOREMODE);\n\t\t\tNbaVpmsResultsData data = new NbaVpmsResultsData(vpmsProxy.getResults());\n\t\t\tif (data.wasSuccessful()) {\n\t\t\t\tif (data.getResultsData() != null && data.getResultsData().size() > 0) {\n\t\t\t\t if(getLogger().isDebugEnabled()) { //SPR3290\n\t\t\t\t getLogger().logDebug(\"Completed retrieval of Data Store Mode from VP/MS model\");\n\t\t\t\t } //SPR3290\n\t\t\t\t\treturn (String) data.getResultsData().get(0);\n\t\t\t\t}\n\t\t\t}\n\t\t\tthrow new NbaDataStoreModeNotFoundException(\"Could not retrieve Data Store Mode from VP/MS model\");\n\t\t} catch (Throwable th) {\n\t\t\tthrow new NbaBaseException(\"Problem retrieving Data Store Mode from VP/MS\", th);\n\t\t} finally {\n\t\t\ttry {\n\t\t\t\tif (vpmsProxy != null) {\n\t\t\t\t\tvpmsProxy.remove();\t\t\t\t\t\n\t\t\t\t}\n\t\t\t\t//SPR3362 code deleted\n\t\t\t} catch (Throwable th) {\n\t\t\t getLogger().logError(NbaBaseException.VPMS_REMOVAL_FAILED); //SPR3362\n\t\t\t}\n\t\t}\n\t}", "java.lang.String getSemanticLangidModelName();", "void findHistory(File f,IvyXmlWriter xw)\n{\n StringCommand cmd = new StringCommand(cvs_command + \" log \" + getRelativePath(f));\n String rslt = cmd.getContent();\n\n StringTokenizer tok = new StringTokenizer(rslt,\"\\n\");\n String rev = null;\n Date d = null;\n String auth = null;\n String msg = null;\n BvcrFileVersion prior = null;\n Collection<BvcrFileVersion> fvs = new ArrayList<BvcrFileVersion>();\n String headversion = null;\n\n while (tok.hasMoreTokens()) {\n String ln = tok.nextToken();\n if (rev == null) {\n\t if (ln.startsWith(\"revision \")) rev = ln.substring(9).trim();\n\t else if (ln.startsWith(\"head: \")) {\n\t headversion = ln.substring(6);\n\t }\n }\n else {\n\t if (ln.startsWith(\"date: \")) {\n\t StringTokenizer ltok = new StringTokenizer(ln,\";\");\n\t while (ltok.hasMoreTokens()) {\n\t String itm = ltok.nextToken();\n\t int idx = itm.indexOf(\":\");\n\t if (idx >= 0) {\n\t\t String what = itm.substring(0,idx).trim();\n\t\t String cnts = itm.substring(idx+1).trim();\n\t\t if (what.equals(\"date\")) {\n\t\t try {\n\t\t\td = CVS_DATE.parse(cnts);\n\t\t }\n\t\t catch (ParseException e) { }\n\t\t }\n\t\t else if (what.equals(\"author\")) auth = cnts;\n\t\t}\n\t }\n\t }\n\t else if (ln.startsWith(\"----------------------------\") ||\n\t\t ln.startsWith(\"===================================================\")) {\n\t if (auth != null && d != null) {\n\t BvcrFileVersion fv = new BvcrFileVersion(f,rev,d,auth,msg);\n\t if (headversion != null && headversion.equals(rev)) {\n\t\t fv.addAlternativeName(\"HEAD\");\n\t\t}\n\t if (prior != null) prior.addPriorVersion(fv);\n\t prior = fv;\n\t fvs.add(fv);\n\t }\n\t rev = null;\n\t d = null;\n\t msg = null;\n\t auth = null;\n\t }\n\t else if (msg == null) msg = ln;\n\t else msg = msg + \"\\n\" + ln;\n }\n }\n\n xw.begin(\"HISTORY\");\n xw.field(\"FILE\",f.getPath());\n for (BvcrFileVersion fv : fvs) {\n fv.outputXml(xw);\n }\n xw.end(\"HISTORY\");\n}", "public void transform(IPath operaModel, String actionModel) {\n\n\tURI inURI = URI.createPlatformResourceURI(operaModel.toString(), true);\n\tResource inResource = new ResourceSetImpl().getResource(inURI, true);\n\t\n\tURI outURI1 = URI.createPlatformResourceURI(actionModel, true);\t\n\tResource outResource1 = new ResourceSetImpl().createResource(outURI1);\n\t\n\tURI outURI2 = outURI1.trimFileExtension().appendFileExtension(\"OLCLMap\");\n\tResource outResource2 = new ResourceSetImpl().createResource(outURI2);\n\t\n\ttry {\n\t\tConvertOpera2Actions.convertOpera2Actions(inResource, outResource1, outResource2);\t\t\t\n\t\toutResource1.save(Collections.emptyMap());\n\t\toutResource2.save(Collections.emptyMap());\n\t\t\n\t} catch (Exception e) {\n\t\tDiagnostic diagnostic = BasicDiagnostic.toDiagnostic(e);\n\t\tInvokeActivator.getDefault().getLog().log(BasicDiagnostic.toIStatus(diagnostic));\n\t}\t\t\n\t\t\n\t\n}", "private List transformChangeList(List source) {\r\n\t\t\r\n\t\tList target = new ArrayList();\r\n\t\tfor (int i=0; i<source.size(); i++) {\r\n\t\t\tObject change = source.get(i);\r\n\t\t\tif (change instanceof SwoopChange) {\r\n\t\t\t\tSwoopChange swc = (SwoopChange) change;\r\n\t\t\t\t// change SwoopChange to a Description object\r\n\t\t\t\tDescription desc = new Description();\r\n\t\t\t\tdesc.setAuthor(swc.getAuthor());\r\n\t\t\t\tdesc.setCreated(swc.getTimeStamp());\r\n\t\t\t\tdesc.setBody(swc.getDescription());\r\n\t\t\t\tdesc.setBodyType(\"text/html\");\r\n\t\t\t\tdesc.setAnnotatedEntityDefinition(swc.comment);\r\n\t\t\t\t// create annotates URI from\r\n\t\t\t\t// 1. repository URL\r\n\t\t\t\t// 2. owlObjectURI\r\n\t\t\t\t// 3. extra URIs\r\n\t\t\t\tURI[] uris = new URI[2+swc.getExtraSubjects().size()];\r\n\t\t\t\turis[0] = repositoryURI;\r\n\t\t\t\turis[1] = swc.getOwlObjectURI();\r\n\t\t\t\tfor (int j=0; j<swc.getExtraSubjects().size(); j++) {\r\n\t\t\t\t\turis[j+2] = (URI) swc.getExtraSubjects().get(j);\r\n\t\t\t\t}\r\n\t\t\t\tdesc.setAnnotates(uris);\r\n\t\t\t\t// attach single ontology change to description\r\n\t\t\t\tList chngList = new ArrayList();\r\n\t\t\t\tchngList.add(swc.getChange());\r\n\t\t\t\tdesc.setOntologyChangeSet(chngList);\t\t\t\t\r\n\t\t\t\ttarget.add(desc);\r\n\t\t\t}\r\n\t\t\telse if (change instanceof Description) {\r\n\t\t\t\tDescription desc = (Description) change;\r\n\t\t\t\t// change Description to SwoopChange object\r\n\t\t\t\tSwoopChange swc = new SwoopChange();\r\n\t\t\t\tswc.setAuthor(desc.getAuthor());\r\n\t\t\t\tswc.setTimeStamp(desc.getCreated());\r\n\t\t\t\tswc.setDescription(desc.getBody());\r\n\t\t\t\tswc.comment = desc.getAnnotatedEntityDefinition();\r\n\t\t\t\tswc.setCommitted(true); // set committed\r\n\t\t\t\t// get URIs from desc for swc\r\n\t\t\t\tURI[] uris = desc.getAnnotates();\r\n\t\t\t\tswc.setOwlObjectURI(uris[1]);\r\n\t\t\t\tList extraSubjects = new ArrayList(); \r\n\t\t\t\tfor (int j=2; j<uris.length; j++) {\r\n\t\t\t\t\textraSubjects.add(uris[j]);\r\n\t\t\t\t}\r\n\t\t\t\tswc.setExtraSubjects(extraSubjects);\r\n\t\t\t\t// get single ontology change object\r\n\t\t\t\tList chngList = desc.getOntologyChangeSet();\r\n\t\t\t\tswc.setChange((OntologyChange) chngList.iterator().next());\r\n\t\t\t\ttarget.add(swc);\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn target;\t\t\r\n\t}", "public void toSATHelper2(Sat satModel) throws IOException {\n ASTNode tab=getChildConst(1);\n \n int varcount = getChild(0).numChildren()-1;\n \n ArrayList<ASTNode> tups=tab.getChildren();\n \n ArrayList<ASTNode> vardoms=new ArrayList<ASTNode>();\n for(int i=1; i<=varcount; i++) {\n ASTNode var=getChild(0).getChild(i);\n if(var instanceof Identifier) {\n vardoms.add(((Identifier)var).getDomain());\n }\n else if(var.isConstant()) {\n vardoms.add(new IntegerDomain(new Range(var,var)));\n }\n else if(var instanceof SATLiteral) {\n vardoms.add(new BooleanDomainFull());\n }\n else {\n assert false : \"Unknown type contained in tableshort constraint:\"+var;\n }\n }\n \n ArrayList<Long> tupleSatVars = new ArrayList<Long>(tups.size());\n \n // Make a SAT variable for each tuple. \n for(int i=1; i < tups.size(); i++) {\n // Filter out tuples that are not valid.\n boolean valid=true;\n ASTNode t = tups.get(i);\n int length = t.numChildren();\n for(int j = 1; j < length; ++j) {\n long var = t.getChild(j).getChild(1).getValue()-1;\n long val = t.getChild(j).getChild(2).getValue();\n if(!vardoms.get((int)var).containsValue(val)) {\n valid = false;\n break;\n }\n }\n \n if(!valid) {\n tups.set(i, tups.get(tups.size()-1));\n tups.remove(tups.size()-1);\n i--;\n continue;\n }\n \n // Make a new sat variable for the tuple\n long newSatVar=satModel.createAuxSATVariable();\n tupleSatVars.add(newSatVar);\n \n // If command line flag, generate an iff to define the new sat variable.\n if(CmdFlags.short_tab_sat_extra) {\n ArrayList<Long> c=new ArrayList<Long>(tups.get(i).numChildren()-1);\n \n // Get the literals for this tuple into c. \n for(int j=1; j<t.numChildren(); j++) {\n ASTNode pair=t.getChild(j);\n // System.out.print(pair);\n c.add(-getChild(0).getChild((int) pair.getChild(1).getValue()).directEncode(satModel, pair.getChild(2).getValue()));\n }\n \n satModel.addClauseReified(c, -newSatVar);\n }\n \n }\n \n // Store for each variable, a list of its domain values\n ArrayList<ArrayList<Long>> vallist = new ArrayList<ArrayList<Long>>(varcount);\n // Store, for each variable, the tuples which implictly support it\n ArrayList<ArrayList<Long>> impclauselist = new ArrayList<ArrayList<Long>>(varcount); \n // Store, for each literal, the tuples which explictly support it\n ArrayList<ArrayList<ArrayList<Long>>> expclauselist = new ArrayList<ArrayList<ArrayList<Long>>>(varcount);\n \n for(int var=1; var<=varcount; var++) {\n ASTNode varast=getChild(0).getChild(var);\n \n vallist.add(vardoms.get(var-1).getValueSet());\n impclauselist.add(new ArrayList<Long>());\n expclauselist.add(new ArrayList<ArrayList<Long>>(vallist.get(var-1).size()));\n for(int j = 0; j < vallist.get(var-1).size(); ++j)\n {\n expclauselist.get(var-1).add(new ArrayList<Long>());\n }\n }\n \n for(int tup=1; tup < tups.size(); tup++) {\n ASTNode t = tups.get(tup);\n int length = t.numChildren();\n // Track used variables\n ArrayList<Boolean> used_vars = new ArrayList<Boolean>(Collections.nCopies(varcount, false));\n for(int j = 1; j < length; ++j) {\n int var = (int)(t.getChild(j).getChild(1).getValue() - 1);\n long val = t.getChild(j).getChild(2).getValue();\n assert used_vars.get(var) == false;\n used_vars.set(var, true);\n int loc = Collections.binarySearch(vallist.get(var), val);\n assert vallist.get(var).get(loc) == val;\n expclauselist.get(var).get(loc).add(tupleSatVars.get(tup-1));\n }\n \n for(int j = 0; j < varcount; ++j)\n {\n if(used_vars.get(j) == false) {\n impclauselist.get(j).add(tupleSatVars.get(tup-1));\n }\n }\n }\n \n // Now generate and post clauses\n for(int i = 0; i < varcount; ++i)\n {\n ASTNode varast=getChild(0).getChild(i+1);\n for(int val = 0; val < vallist.get(i).size(); ++val)\n {\n // firstly, for all explicit clauses, ~lit -> ~clause ( lit \\/ ~clause )\n if(!CmdFlags.short_tab_sat_extra) {\n for(int clause = 0; clause < expclauselist.get(i).get(val).size(); ++clause)\n {\n long lit = varast.directEncode(satModel, vallist.get(i).get(val));\n \n satModel.addClause(lit, -expclauselist.get(i).get(val).get(clause));\n }\n }\n \n // Secondly, for all implicit + explicit clauses for lit,\n // ~(/\\clauses) -> ~lit ( ~lit \\/ expclause1 \\/ ... \\/ expclausen \\/ impclause1 \\/ ... impclausen)\n ArrayList<Long> buf=new ArrayList<Long>(1+expclauselist.get(i).get(val).size()+impclauselist.get(i).size());\n \n buf.add(-varast.directEncode(satModel, vallist.get(i).get(val)));\n \n for(int clause = 0; clause < expclauselist.get(i).get(val).size(); ++clause)\n {\n buf.add(expclauselist.get(i).get(val).get(clause));\n }\n for(int clause = 0; clause < impclauselist.get(i).size(); ++clause)\n {\n buf.add(impclauselist.get(i).get(clause));\n }\n satModel.addClause(buf);\n }\n }\n \n satModel.addClause(tupleSatVars); // One of the tuples must be assigned -- redundant but probably won't hurt.\n }", "public String getSvnUrl() {\r\n return this.svnUrl;\r\n }", "private void updateTree(String st, int lineno, double bl, PrintWriter missing){\n\t\t String[] str = st.split(\"\\\\s+\");\n\t\t String specName = str[0];\n\t\t if(str[0].indexOf(\"GRCh38\")>=0){\n\t\t\t specName= \"Homo_sapiens\";\n\t\t\t str[0] = specName;\n\t\t }\n\t\t String alias1 = collapse(str, 2, str.length, \" \");\n\t\t Node n = getSlug(specName, alias1);\n\t\t if(n==null) n = this.unclassified;\n\t\t Node newnode = this.createFromSpeciesFile(str,alias1, n, lineno, bl);\n\t\t this.putSlug(newnode);\n\t\t\t \n\t\t\n\t\t \n\t }", "public interface ModelConverter {\n\n\tWorkingUnit convertFromDto(WorkingUnitDto workingUnitDto);\n\n\tWord convertFromDto(WordDto wordDto);\n\n\tWorkingUnitDto convertFromDomain(WorkingUnit workingUnit);\n\n\t// WordDto convertFromDomain (Word word);\n\tWordDtoImpl convertFromDomainImpl(Word word);\n\n\tPosAnnotation convertFromDto(PosAnnotationDto posDto);\n\n\tRectangleAnnotation convertFromDto(RectangleAnnotationDto raDto);\n\n\tFormAnnotation convertFromDto(FormAnnotationDto faDto);\n\n\tChapterRange convertFromDto(ChapterRangeDto crDto);\n\n\tLanguageRange convertFromDto(LanguageRangeDto lrDto);\n\n\tPosAnnotationDto convertFromDomain(PosAnnotation pos);\n\n}", "@SuppressWarnings({ \"rawtypes\", \"unchecked\" })\n\tpublic static void createMigrationInputFiles()\n\t{\n\t\t@SuppressWarnings({ \"rawtypes\" })\n\t\tMultiValueMap structureMap = new MultiValueMap(); // MultiValueMap for adding child item rows for every parentId\n\n\t\ttry\n\t\t{\n\t\t\tWorkbook workbook = new XSSFWorkbook(EXCEL_FILE);\n\t\t\tSheet datatypeSheet = workbook.getSheetAt(0);\n\n\t\t\tint linkDocCount = 0, linkDwgCount = 0, linkPurchSpecCount = 0, linkMadeFromCount = 0, engParts = 0, altPartsCount = 0;\n\n\t\t\tList<String> serviceItemsList = new ArrayList<String>();\n\t\t\tList<String> engItemsList = new ArrayList<String>();\n\n\t\t\t// Skipping top two rows\n\t\t\tIterator<Row> rowIterator = datatypeSheet.iterator();\n\t\t\tif (rowIterator.hasNext())\n\t\t\t\trowIterator.next();\n\t\t\tif (rowIterator.hasNext())\n\t\t\t\trowIterator.next();\n\n\t\t\t// Reading the rows one by one\n\t\t\twhile (rowIterator.hasNext())\n\t\t\t{\n\t\t\t\tcurrentRow = rowIterator.next();\n\t\t\t\tString tierType = BLANK;\n\t\t\t\tif (v(TIER_TYPE) != null && v(TIER_TYPE).trim().length() != 0\n\t\t\t\t\t\t&& !v(TIER_TYPE).trim().isEmpty())\n\t\t\t\t{\n\t\t\t\t\ttierType = v(TIER_TYPE).replace(SEMICOLON_SPACE, COMMA);\n\t\t\t\t\ttierType = tierType.replace(SPACE_SEMICOLON, COMMA);\n\t\t\t\t\ttierType = tierType.replace(SEMICOLON, COMMA);\n\t\t\t\t}\n\n\t\t\t\tString engineFamily = BLANK;\n\t\t\t\tif (v(ENGINE_FAMILY) != null && v(ENGINE_FAMILY).trim().length() != 0\n\t\t\t\t\t\t&& !v(ENGINE_FAMILY).trim().isEmpty())\n\t\t\t\t{\n\t\t\t\t\tengineFamily = v(ENGINE_FAMILY).replace(SEMICOLON_SPACE, COMMA);\n\t\t\t\t\tengineFamily = engineFamily.replace(SPACE_SEMICOLON, COMMA);\n\t\t\t\t\tengineFamily = engineFamily.replace(SEMICOLON, COMMA);\n\t\t\t\t\t/*\n\t\t\t\t\tengineFamily = v(ENGINE_FAMILY).replace(SPACE, BLANK);\n\t\t\t\t\tengineFamily = engineFamily.replace(SEMICOLON, COMMA);*/\n\t\t\t\t}\n\n\t\t\t\tString componentId = BLANK;\n\t\t\t\ttry\n\t\t\t\t{\n\t\t\t\t\tif (v(SERVICE_CMP_ID) != null && v(SERVICE_CMP_ID).trim().length() != 0\n\t\t\t\t\t\t\t&& !v(SERVICE_CMP_ID).trim().isEmpty())\n\t\t\t\t\t{\n\t\t\t\t\t\t/*System.out.println(currentRow.getCell(SERVICE_CMP_ID)\n\t\t\t\t\t\t\t\t.getRichStringCellValue()); */\n\t\t\t\t\t\tcomponentId = (currentRow.getCell(SERVICE_CMP_ID).getRichStringCellValue())\n\t\t\t\t\t\t\t\t.toString();\n\t\t\t\t\t\tcomponentId = componentId.replace(SEMICOLON_SPACE, COMMA);\n\t\t\t\t\t\tcomponentId = componentId.replace(SPACE_SEMICOLON, COMMA);\n\t\t\t\t\t\tcomponentId = componentId.replace(SEMICOLON, COMMA);\n\t\t\t\t\t\t//System.out.println(componentId);\n\t\t\t\t\t}\n\t\t\t\t} catch (IllegalStateException e)\n\t\t\t\t{\n\t\t\t\t\tSystem.out.println(\"\\nError : Item \" + v(ITEM_ID)\n\t\t\t\t\t\t\t+ \" has invalid Component ID formula.\");\n\t\t\t\t\tLOG_WRITER.write(\"\\nError : Item \" + v(ITEM_ID)\n\t\t\t\t\t\t\t+ \" has invalid Component ID formula.\");\n\t\t\t\t}\n\n\t\t\t\tString catalogNum = BLANK;\n\t\t\t\tif (v(CATALOG_ITEM) != null && v(CATALOG_ITEM).trim().length() != 0\n\t\t\t\t\t\t&& !v(CATALOG_ITEM).trim().isEmpty())\n\t\t\t\t{\n\t\t\t\t\tcatalogNum = v(CATALOG_ITEM).replace(SPACE, BLANK);\n\t\t\t\t\tcatalogNum = catalogNum.replace(SEMICOLON, COMMA);\n\t\t\t\t}\n\t\t\t\t//convertRowToPipeDelimited(currentRow);\n\t\t\t\t//if it is for Service Part\n\t\t\t\tif (v(LINE_TYPE).equals(NEW_SERVICE_PART))\n\t\t\t\t{\n\t\t\t\t\t/* Check for the revision field */\n\t\t\t\t\tString revision_id = DEFAULT_REVISION_ID;\n\t\t\t\t\tif (v(REVISION) != null && v(REVISION).trim().length() != 0\n\t\t\t\t\t\t\t&& !v(REVISION).trim().isEmpty())\n\t\t\t\t\t{\n\t\t\t\t\t\trevision_id = v(REVISION).replace(SPACE, BLANK);\n\t\t\t\t\t}\n\n\t\t\t\t\t/* Service Part Writer */\n\n\t\t\t\t\tif (!serviceItemsList.contains(v(ITEM_ID)))\n\t\t\t\t\t{\n\t\t\t\t\t\tSERVICE_PART_WRITER\n\t\t\t\t\t\t\t\t.write(v(ITEM_ID)\n\t\t\t\t\t\t\t\t\t\t+ DEL\n\t\t\t\t\t\t\t\t\t\t+ v(ITEM_NAME)\n\t\t\t\t\t\t\t\t\t\t+ DEL\n\t\t\t\t\t\t\t\t\t\t+ revision_id\n\t\t\t\t\t\t\t\t\t\t+ DEL\n\t\t\t\t\t\t\t\t\t\t+ TYPE_REAL_NAME\n\t\t\t\t\t\t\t\t\t\t+ DEL\n\t\t\t\t\t\t\t\t\t\t+ ((v(UOM) == null || v(UOM).trim().length() == 0\n\t\t\t\t\t\t\t\t\t\t\t\t|| v(UOM).trim().isEmpty() || v(UOM)\n\t\t\t\t\t\t\t\t\t\t\t\t.equalsIgnoreCase(EACH)) ? BLANK : v(UOM).trim())\n\t\t\t\t\t\t\t\t\t\t+ DEL\n\t\t\t\t\t\t\t\t\t\t+ v(IP_CLASS)\n\t\t\t\t\t\t\t\t\t\t+ DEL\n\t\t\t\t\t\t\t\t\t\t+ v(OBJ_WEIGHT)\n\t\t\t\t\t\t\t\t\t\t+ DEL\n\t\t\t\t\t\t\t\t\t\t+ v(OBJ_WEIGHT_UOM)\n\t\t\t\t\t\t\t\t\t\t+ DEL\n\t\t\t\t\t\t\t\t\t\t+ v(ENG_PRODUCT_LINE)\n\t\t\t\t\t\t\t\t\t\t+ DEL\n\t\t\t\t\t\t\t\t\t\t+ ((v(DATA_MODEL).contains(MODEL_BASED)) ? MB\n\t\t\t\t\t\t\t\t\t\t\t\t: ((v(DATA_MODEL).contains(MODEL_CENTRIC)) ? MC\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t: BLANK)\n\n\t\t\t\t\t\t\t\t\t\t)\n\n\t\t\t\t\t\t\t\t\t\t+ DEL + v(ECCN) + DEL + v(ECCN_SOURCE) + DEL + v(OBJ_EVI)\n\t\t\t\t\t\t\t\t\t\t+ DEL + v(CTQ) + DEL + v(CCC) + DEL + v(ECC) + DEL + DEL\n\t\t\t\t\t\t\t\t\t\t+ v(HOMOLOGATION) + DEL + v(CRITICAL_PART) + DEL\n\t\t\t\t\t\t\t\t\t\t+ v(ENG_MAKE_BUY) + NEW_LINE);\n\n\t\t\t\t\t\t/* Service Form Update Writer */\n\t\t\t\t\t\tSERVICE_FORM_WRITER\n\t\t\t\t\t\t\t\t.write(v(ITEM_NAME) + DEL + v(ITEM_ID) + DEL + componentId + DEL\n\t\t\t\t\t\t\t\t\t\t+ v(SERVICEABLE) + DEL + v(REPAIRABLE) + DEL\n\t\t\t\t\t\t\t\t\t\t+ v(SERIALIZED) + DEL + v(POS_TRACKED) + DEL\n\t\t\t\t\t\t\t\t\t\t+ v(SERVICE_ITEM_TYPE) + DEL + tierType + DEL\n\t\t\t\t\t\t\t\t\t\t+ engineFamily + DEL + catalogNum + NEW_LINE);\n\n\t\t\t\t\t\t/* Service Parts' Owning Group update */\n\t\t\t\t\t\tSP_GROUP_ID_WRITER.write(v(ITEM_ID) + NEW_LINE);\n\n\t\t\t\t\t\t/* Relate Service Parts to Document */\n\t\t\t\t\t\tif (v(LINK_DOC) != null && v(LINK_DOC).trim().length() != 0\n\t\t\t\t\t\t\t\t&& !v(LINK_DOC).isEmpty())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tSP_ATTACHMENT_WRITER.write(v(ITEM_ID) + DEL + revision_id + DEL\n\t\t\t\t\t\t\t\t\t+ v(LINK_DOC) + DEL + SP_DOC_RELATION_NAME + NEW_LINE);\n\t\t\t\t\t\t\tlinkDocCount++;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t/* Relate Service Parts to Drawing */\n\t\t\t\t\t\tif (v(LINK_DWG) != null && v(LINK_DWG).trim().length() != 0\n\t\t\t\t\t\t\t\t&& !v(LINK_DWG).isEmpty())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tSP_ATTACHMENT_WRITER.write(v(ITEM_ID) + DEL + revision_id + DEL\n\t\t\t\t\t\t\t\t\t+ v(LINK_DWG) + DEL + SP_DWG_RELATION_NAME + NEW_LINE);\n\t\t\t\t\t\t\tlinkDwgCount++;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t/* Relate Service Parts to Purchase Specifications */\n\t\t\t\t\t\tif (v(LINK_PURCHSPEC) != null && v(LINK_PURCHSPEC).trim().length() != 0\n\t\t\t\t\t\t\t\t&& !v(LINK_PURCHSPEC).isEmpty())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tSP_ATTACHMENT_WRITER.write(v(ITEM_ID) + DEL + revision_id + DEL\n\t\t\t\t\t\t\t\t\t+ v(LINK_PURCHSPEC) + DEL + SP_PURCHSPEC_RELATION_NAME\n\t\t\t\t\t\t\t\t\t+ NEW_LINE);\n\t\t\t\t\t\t\tlinkPurchSpecCount++;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t/* Relate Service Parts to MadeFrom */\n\t\t\t\t\t\tif (v(LINK_MADEFROM) != null && v(LINK_MADEFROM).trim().length() != 0\n\t\t\t\t\t\t\t\t&& !v(LINK_MADEFROM).isEmpty())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tMADE_FROM_RELATION_WRITER.write(v(ITEM_ID) + DEL + v(LINK_MADEFROM)\n\t\t\t\t\t\t\t\t\t+ DEL + SP_MADEFROM_RELATION_NAME + NEW_LINE);\n\t\t\t\t\t\t\tlinkMadeFromCount++;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tserviceItemsList.add(v(ITEM_ID));\n\t\t\t\t\t} else\n\t\t\t\t\t{\n\t\t\t\t\t\tLOG_WRITER.write(DUPLICATE_ENTRY + v(ITEM_ID));\n\t\t\t\t\t}\n\n\t\t\t\t}\n\n\t\t\t\telse if (v(LINE_TYPE).equals(EXISTING_ENG_PART))\n\t\t\t\t{\n\t\t\t\t\t/* EngParts' Service Form Creation - ITEM_ID will be used as the Service Form's NAME */\n\t\t\t\t\tif (!engItemsList.contains(v(ITEM_ID)))\n\t\t\t\t\t{\n\t\t\t\t\t\tEP_SERVICE_FORM_WRITER.write(v(ITEM_NAME) + DEL + componentId + DEL\n\t\t\t\t\t\t\t\t+ v(SERVICEABLE) + DEL + v(REPAIRABLE) + DEL + v(SERIALIZED) + DEL\n\t\t\t\t\t\t\t\t+ v(POS_TRACKED) + DEL + v(SERVICE_ITEM_TYPE) + DEL + tierType\n\t\t\t\t\t\t\t\t+ DEL + engineFamily + DEL + catalogNum + DEL + v(ITEM_ID)\n\t\t\t\t\t\t\t\t+ NEW_LINE);\n\t\t\t\t\t\tengParts++;\n\t\t\t\t\t\tengItemsList.add(v(ITEM_ID));\n\t\t\t\t\t} else\n\t\t\t\t\t{\n\t\t\t\t\t\tLOG_WRITER.write(DUPLICATE_ENTRY + v(ITEM_ID));\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t/*\tAdd child item rows for each assembly */\n\t\t\t\tif (v(PARENT_ID) != null && v(PARENT_ID).trim().length() != 0\n\t\t\t\t\t\t&& !v(PARENT_ID).isEmpty())\n\t\t\t\t{\n\t\t\t\t\tstructureMap.put(v(PARENT_ID), currentRow.getRowNum());\n\t\t\t\t\t/*\tSTRUCTURE_WRITER.write(v(PARENT_ID) + DEL + v(ITEM_ID) + DEL + v(QTY) + DEL\n\t\t\t\t\t\t\t\t+ v(SEQ) + NEW_LINE); - can not write it here, as the same parent might come again later. IPS_DATA_UPLOAD fails if the parent has existing BVR with -bom mode. */\n\t\t\t\t}\n\n\t\t\t\t/* Global Alternate */\n\t\t\t\tString globalAltStr = v(GLOBAL_ALT);\n\t\t\t\tif (globalAltStr != null && !globalAltStr.trim().isEmpty()\n\t\t\t\t\t\t&& globalAltStr.trim().length() != 0)\n\t\t\t\t{\n\t\t\t\t\tglobalAltStr = globalAltStr.replace(SPACE, BLANK);\n\t\t\t\t\tString globalAltArray[] = globalAltStr.split(SEMICOLON);\n\t\t\t\t\tfor (int i = 0; i < globalAltArray.length; i++)\n\t\t\t\t\t{\n\t\t\t\t\t\tSP_GLOBAL_ALT_WRITER.write(v(ITEM_ID) + DEL + globalAltArray[i].trim()\n\t\t\t\t\t\t\t\t+ NEW_LINE);\n\t\t\t\t\t\taltPartsCount++;\n\t\t\t\t\t}\n\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tLOG_WRITER.write(TOTAL_SERVICE_PARTS + serviceItemsList.size() + NEW_LINE);\n\t\t\tLOG_WRITER.write(TOTAL_DOCUMENTS_TO_ATTACH + linkDocCount + NEW_LINE);\n\t\t\tLOG_WRITER.write(TOTAL_DRAWINGS_TO_ATTACH + linkDwgCount + NEW_LINE);\n\t\t\tLOG_WRITER.write(TOTAL_PURCHSPEC_TO_ATTACH + linkPurchSpecCount + NEW_LINE);\n\t\t\tLOG_WRITER.write(TOTAL_MADEFROM_TO_ATTACH + linkMadeFromCount + NEW_LINE);\n\t\t\tLOG_WRITER.write(TOTAL_ALTERNATE_PARTS_TO_ADD + altPartsCount + NEW_LINE);\n\t\t\tLOG_WRITER.write(TOTAL_ENG_PARTS_FOR_SERVICE_FORM_CREATON + engParts + NEW_LINE);\n\t\t\tLOG_WRITER.write(LINE_SEPERATOR);\n\n\t\t\t/* Write Structures */\n\t\t\tLOG_WRITER.write(STRUCTURE_START_TIME + new java.util.Date() + NEW_LINE);\n\t\t\tSet<String> parentIDs = structureMap.keySet();\n\t\t\tIterator parentIDsIterator = parentIDs.iterator();\n\t\t\tLOG_WRITER.write(TOTAL_STRUCTURES + parentIDs.size() + NEW_LINE);\n\t\t\t/*PS_STRUCTURE_WRITER.write(NEW_LINE + HASH_SIGN + TOTAL_STRUCTURES + parentIDs.size()\n\t\t\t\t\t+ NEW_LINE);*/\n\t\t\twhile (parentIDsIterator.hasNext())\n\t\t\t{\n\t\t\t\tObject parentID = parentIDsIterator.next();\n\n\t\t\t\t/*PS_STRUCTURE_WRITER.write(NEW_LINE + parentID + DEL + DEFAULT_REVISION_ID + DEL\n\t\t\t\t\t\t+ TYPE_REAL_NAME + DEL + ZERO + NEW_LINE);*/\n\n\t\t\t\tCollection childRows = (Collection) structureMap.get(parentID);\n\t\t\t\tIterator childRowsIterator = childRows.iterator();\n\t\t\t\twhile (childRowsIterator.hasNext())\n\t\t\t\t{\n\t\t\t\t\tRow cRow = datatypeSheet.getRow((int) childRowsIterator.next());\n\t\t\t\t\t/*PS_STRUCTURE_WRITER.write(rv(cRow, ITEM_ID) + DEL + DEFAULT_REVISION_ID + DEL\n\t\t\t\t\t\t\t+ TYPE_REAL_NAME + DEL + ONE + DEL + rv(cRow, SEQ) + DEL\n\t\t\t\t\t\t\t+ rv(cRow, QTY) + NEW_LINE);*/\n\t\t\t\t\tSTRUCTURE_WRITER.write(parentID + DEL + rv(cRow, ITEM_ID) + DEL + rv(cRow, QTY)\n\t\t\t\t\t\t\t+ DEL + rv(cRow, SEQ) + NEW_LINE);\n\t\t\t\t}\n\t\t\t}\n\t\t\tLOG_WRITER.write(STRUCTURE_END_TIME + new java.util.Date() + LINE_SEPERATOR);\n\t\t\tworkbook.close();\n\t\t} catch (FileNotFoundException e)\n\t\t{\n\t\t\tSystem.out.println(EXCEPTION + e.getMessage());\n\t\t} catch (IOException e)\n\t\t{\n\t\t\tSystem.out.println(EXCEPTION + e.getMessage());\n\t\t} finally\n\t\t{\n\t\t\ttry\n\t\t\t{\n\t\t\t\tif (SERVICE_PART_WRITER != null)\n\t\t\t\t{\n\t\t\t\t\tSERVICE_PART_WRITER.close();\n\t\t\t\t}\n\t\t\t\tif (SERVICE_FORM_WRITER != null)\n\t\t\t\t{\n\t\t\t\t\tSERVICE_FORM_WRITER.close();\n\t\t\t\t}\n\t\t\t\tif (EP_SERVICE_FORM_WRITER != null)\n\t\t\t\t{\n\t\t\t\t\tEP_SERVICE_FORM_WRITER.close();\n\t\t\t\t}\n\t\t\t\tif (SP_GLOBAL_ALT_WRITER != null)\n\t\t\t\t{\n\t\t\t\t\tSP_GLOBAL_ALT_WRITER.close();\n\t\t\t\t}\n\t\t\t\tif (SP_GROUP_ID_WRITER != null)\n\t\t\t\t{\n\t\t\t\t\tSP_GROUP_ID_WRITER.close();\n\t\t\t\t}\n\t\t\t\tif (SP_ATTACHMENT_WRITER != null)\n\t\t\t\t{\n\t\t\t\t\tSP_ATTACHMENT_WRITER.close();\n\t\t\t\t}\n\t\t\t\tif (MADE_FROM_RELATION_WRITER != null)\n\t\t\t\t{\n\t\t\t\t\tMADE_FROM_RELATION_WRITER.close();\n\t\t\t\t}\n\t\t\t\t/*\n\t\t\t\tif (PS_STRUCTURE_WRITER != null)\n\t\t\t\t{\n\t\t\t\t\tPS_STRUCTURE_WRITER.close();\n\t\t\t\t}*/\n\t\t\t\tif (STRUCTURE_WRITER != null)\n\t\t\t\t{\n\t\t\t\t\tSTRUCTURE_WRITER.close();\n\t\t\t\t}\n\t\t\t\tif (LOG_WRITER != null)\n\t\t\t\t{\n\t\t\t\t\tLOG_WRITER.write(END_TIME + new java.util.Date() + LINE_SEPERATOR);\n\t\t\t\t\tSystem.out.println(END_TIME + new java.util.Date() + LINE_SEPERATOR);\n\t\t\t\t\tLOG_WRITER.close();\n\t\t\t\t}\n\n\t\t\t} catch (IOException ex)\n\t\t\t{\n\t\t\t\tSystem.out.println(EXCEPTION + ex.getMessage());\n\t\t\t}\n\t\t}\n\t}", "String toSVMString();", "public SVGElementModel convert(SVGElement element) {\n \t\tSVGElementModel model = elementToModel.get(element);\n //\t\tassert(model != null);\n \t\treturn model;\n \t}", "public void saveModelAs() {\r\n \t\t// Updates station positions into data structure\r\n \t\tupdateStationPositions();\r\n \t\tint status = modelLoader.saveModel(model, mainWindow, null);\r\n \t\tswitch (status) {\r\n \t\t\tcase ModelLoader.SUCCESS:\r\n \t\t\t\tmodel.resetSaveState();\r\n \t\t\t\topenedArchive = modelLoader.getSelectedFile();\r\n \t\t\t\tmainWindow.updateTitle(openedArchive.getName());\r\n \t\t\t\tbreak;\r\n \t\t\tcase ModelLoader.FAILURE:\r\n \t\t\t\tshowErrorMessage(modelLoader.getFailureMotivation());\r\n \t\t\t\tbreak;\r\n \t\t}\r\n \t}", "Object toExternal (Object entity, Settings settings);", "public void toSATHelper(Sat satModel, long auxVar) throws IOException {\n ASTNode tab=getChildConst(1);\n \n ArrayList<Long> newSatVars = new ArrayList<Long>(tab.numChildren());\n \n for (int i=1; i < tab.numChildren(); i++) {\n ASTNode tuple = tab.getChild(i);\n \n // One sat variable for each tuple. \n long auxSatVar = satModel.createAuxSATVariable();\n \n ArrayList<Long> iffclause=new ArrayList<Long>(tuple.numChildren()-1);\n \n for (int j =1; j < tuple.numChildren(); j++) {\n long varidx=tuple.getChild(j).getChild(1).getValue();\n long value=tuple.getChild(j).getChild(2).getValue();\n \n long satLit=getChild(0).getChild((int)varidx).directEncode(satModel, value);\n \n iffclause.add(-satLit);\n }\n \n satModel.addClauseReified(iffclause, -auxSatVar); // auxSatVar iff (lit1 /\\ lit2 ...) <---> -auxSatVar iff (-lit1 \\/ -lit2 ...)\n \n newSatVars.add(auxSatVar);\n }\n \n // Finally, the given auxVar is true iff one or more of newSatVars is true. \n satModel.addClauseReified(newSatVars, auxVar);\n }", "public void upgradeToVersion12(OpProjectSession session) {\r\n OpBroker broker = session.newBroker();\r\n try {\r\n OpTransaction t = broker.newTransaction();\r\n updateSystemObjectsName(session, broker);\r\n updateSubjectsSourceFlag(broker);\r\n t.commit();\r\n }\r\n finally {\r\n broker.closeAndEvict(); \r\n }\r\n }", "Book toModeL(BookDTO booKDTO);", "static BvcrVersionManager getRepository(BvcrProject bp,File srcdir)\n{\n if (srcdir == null) return null;\n\n File f1 = new File(srcdir,\"CVS\");\n if (f1.exists() && f1.isDirectory()) {\n System.err.println(\"BVCR: HANDLE CVS REPOSITORY \" + srcdir);\n return new BvcrVersionCVS(bp);\n }\n\n return null;\n}", "private void copySTLs()\n\t{\n\t\tint u = 0;\n\t\tfor(int i = 0; i < astl.size(); i++)\n\t\t{\n\t\t\tfor(int subMod1 = 0; subMod1 < astl.get(i).size(); subMod1++)\n\t\t\t{\n\t\t\t\tString s = astl.get(i).fileItCameFrom(subMod1);\n\t\t\t\tastl.get(i).setUnique(subMod1, u);\n\t\t\t\tfor(int j = 0; j < i; j++)\n\t\t\t\t{\n\t\t\t\t\tfor(int subMod2 = 0; subMod2 < astl.get(j).size(); subMod2++)\n\t\t\t\t\t{\n\t\t\t\t\t\tif(s.equals(astl.get(j).fileItCameFrom(subMod2)))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tastl.get(i).setUnique(subMod1, astl.get(j).getUnique(subMod2));\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif(astl.get(i).getUnique(subMod1) == u)\n\t\t\t\t{\n\t\t\t\t\tcopyFile(s, rfoDir + stlName(u));\n\t\t\t\t\tu++;\n\t\t\t\t}\n\t\t\t}\n\t\t}\t\n\t}", "public static void replaceNameSpace(OntModel model, String oldNameSpace, String newNameSpace) {\n\t\t\n\t\t//log.debug(\" REPLACING NS \" +oldNameSpace+ \" WITH \" +newNameSpace);\n\t\t\n\t\t// old statements to be removed:\n\t\tList<Statement> o_stmts = new ArrayList<Statement>(); \n\t\t\n\t\t// new statements to be added:\n\t\tList<Statement> n_stmts = new ArrayList<Statement>(); \n\t\t\n\t\tStmtIterator existingStmts = model.listStatements();\n\t\twhile ( existingStmts.hasNext() ) {\n\t\t\tStatement o_stmt = existingStmts.nextStatement();\n\t\t\tResource sbj = o_stmt.getSubject();\n\t\t\tProperty prd = o_stmt.getPredicate();\n\t\t\tRDFNode obj = o_stmt.getObject();\n\t\t\t\n\t\t\tboolean any_change = false;\n\t\t\tResource n_sbj = sbj;\n\t\t\tProperty n_prd = prd;\n\t\t\tRDFNode n_obj = obj;\n\n//\t\t\tif ( oldNameSpace.equals(sbj.getNameSpace()) ) {\n\t\t\tif ( _inNamespace(sbj, oldNameSpace) ) {\n\t\t\t\tn_sbj = model.createResource(newNameSpace + sbj.getLocalName());\n\t\t\t\tany_change = true;\n\t\t\t}\n//\t\t\tif ( oldNameSpace.equals(prd.getNameSpace()) ) {\n\t\t\tif ( _inNamespace(prd, oldNameSpace) ) {\n\t\t\t\tn_prd = model.createProperty(newNameSpace + prd.getLocalName());\n\t\t\t\tany_change = true;\n\t\t\t}\n\t\t\tif ( (obj instanceof Resource) ) {\n\t\t\t\tResource objr = (Resource) obj;\n//\t\t\t\tif ( oldNameSpace.equals(objr.getNameSpace()) ) {\n\t\t\t\tif ( _inNamespace(objr, oldNameSpace) ) {\n\t\t\t\t\tn_obj = model.createResource(newNameSpace + objr.getLocalName());\n\t\t\t\t\tany_change = true;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif ( any_change ) {\n\t\t\t\to_stmts.add(o_stmt);\n\t\t\t\tStatement n_stmt = model.createStatement(n_sbj, n_prd, n_obj);\n\t\t\t\tn_stmts.add(n_stmt);\n\t\t\t\t//log.debug(\" #### \" +o_stmt);\n\t\t\t}\n\t\t}\n\t\t\n\t\tfor ( Statement n_stmt : n_stmts ) {\n\t\t\tmodel.add(n_stmt);\n\t\t}\n\t\t\n\t\tfor ( Statement o_stmt : o_stmts ) {\n\t\t\tmodel.remove(o_stmt);\n\t\t}\n\t}", "@Test\n public void testCase1() {\n File base = new File(DIR, \"case1\");\n File pl0 = new File(base, \"pl0/EASy\");\n File pl1 = new File(base, \"pl1/EASy\");\n try {\n Location pl0Loc = VarModel.INSTANCE.locations().addLocation(pl0, OBSERVER);\n Location pl1Loc = VarModel.INSTANCE.locations().addLocation(pl1, OBSERVER);\n // add Parent\n pl1Loc.addDependentLocation(pl0Loc);\n \n VarModel.INSTANCE.loaders().registerLoader(ModelUtility.INSTANCE, OBSERVER);\n \n List<ModelInfo<Project>> infos = VarModel.INSTANCE.availableModels().getModelInfo(\"pl1\");\n Assert.assertNotNull(infos);\n Assert.assertTrue(1 == infos.size());\n Project project = VarModel.INSTANCE.load(infos.get(0));\n Assert.assertNotNull(project);\n \n VarModel.INSTANCE.locations().removeLocation(pl1Loc, OBSERVER);\n VarModel.INSTANCE.locations().removeLocation(pl0Loc, OBSERVER);\n VarModel.INSTANCE.loaders().unregisterLoader(ModelUtility.INSTANCE, OBSERVER);\n } catch (ModelManagementException e) {\n Assert.fail(\"unexpected exception \" + e);\n }\n }", "@Override\n\tpublic void setVersions(SsaForm obj){\n\n\t\tAbstractBaseExt defSymbol = (AbstractBaseExt) resolve(getContext().getText());\n\t\tString str=allHdrFieldsMap.get(defSymbol);\n\t\tif(str!=null) {\n\t\t\tmapUsedStructFields.put(defSymbol, str);\n\t\t}\n\t\tif(obj.getParentCtx() instanceof IfStatementContextExt){\n\t\t\tif(obj.getMinMap().get(defSymbol)==null) {\n\t\t\t\tobj.getMinMap().put(defSymbol, defSymbol.getVersion());\n\t\t\t}\n\t\t} else {\n\t\t\tobj.getMinMap().put(defSymbol, defSymbol.getVersion());\n\t\t}\n\n\t\tdefSymbol.incVersion();\n\t\tthis.ssaVersion=defSymbol.getVersion();\n\t\tList<Pair<AbstractBaseExt,AbstractBaseExt> > tempList=obj.getAllVer().get(defSymbol);\n\t\tif(tempList!=null){\n\t\t\ttempList.add(new Pair(getExtendedContext(getContext()),obj.getAssignCtx()));\n\t\t} else {\n\t\t\tList<Pair<AbstractBaseExt,AbstractBaseExt> > newtempList=new ArrayList<>();\n\t\t\tnewtempList.add(new Pair(getExtendedContext(getContext()),obj.getAssignCtx()));\n\t\t\tobj.getAllVer().put(defSymbol, newtempList);\n\t\t}\n\t}", "public Square modelToView(Square s){\n\t\treturn new Square(s.x/zoom,height-s.y/zoom,s.w/zoom,s.isTarget);\n\t}", "private String cleanModel(String model) {\n\t\tString cleanModel = model.replaceAll(\"[$|#|@|!|%|^|&|*|(|)|]\", \"\").trim();\n\t\treturn cleanModel.substring(0,1).toUpperCase() + cleanModel.substring(1).toLowerCase();\n\t}", "public static void main(String[] args) throws ParserConfigurationException, IOException, TransformerException, OWLOntologyCreationException, OWLOntologyStorageException, SAXException {\n\t\tFile dis = new File(args[0]);\n\t\tFile csv = new File(args[1]);\n\t\tString dir = args[2];\n\t\tFile justDir = new File(args[3]);\n\t\tFile equvCSV = new File(args[4]);\n\t\t/**\n\t\tListManager lm = new ListManager();\n\t\tList<Case> caseList = lm.constructCaseListFromCSV(csv);\n\t\tXMLCaseWriter xcw = new XMLCaseWriter();\n\t\tFile xml = new File(dir + \"/cases.xml\");\n\t\txml.canWrite();\n\t\txcw.createXMLCaseFileFromList(csv, xml, caseList, \"iswc-2014\");\n\t\t/**\n\t\tint i = 0;\n\t\tList<Map<String,String>> records = CSVUtilities.getRecords(csv);\n\t\tfor(Map<String,String> r:records)\n\t\t{\n\t\t\t\n\t\t\tSystem.out.println(\"Map \" + i);\n\t\t\tfor(String k:r.keySet())\n\t\t\t{\n\t\t\t\tSystem.out.println(k);\n\t\t\t\tSystem.out.println(r.get(k));\n\t\t\t\tSystem.out.println(\"\");\n\t\t\t}\n\t\t\tSystem.out.println(\"\");\n\t\t\ti++;\n\t\t}\n\t\t**/\n\t\t\n\t\tListManager lm = new ListManager();\n\t\tList<Case> caseList = lm.constructCaseListFromCSV(csv);\n\t\tMap<String,List<Case>> splitMap = new HashMap<String,List<Case>>();\n\t\tMap<String,List<String>> equvMap = lm.getIDMapForEQClasses(equvCSV);\n\t\tXMLCaseWriter xcw = new XMLCaseWriter();\n\t\txcw.createOntologySortedXMLCaseFilesFromList(csv, new File(dir), justDir, equvMap, caseList, \"iswc-2014\");\n\t\t/**\n\t\tfor(Case c:caseList)\n\t\t{\n\t\t\tif(!splitMap.keySet().contains(c.getOntology()))\n\t\t\t{\n\t\t\t\tList<Case> list = new ArrayList<Case>();\n\t\t\t\tlist.add(c);\n\t\t\t\tsplitMap.put(c.getOntology().toString(), list);\n\t\t\t\t\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tList<Case> list = splitMap.get(c.getOntology().toString());\n\t\t\t\tlist.add(c);\n\t\t\t\tsplitMap.replace(c.getOntology().toString(), list);\n\t\t\t\t\n\t\t\t}\n\t\t}\n\t\t\n\t\t\n\t\tfor(String key:splitMap.keySet())\n\t\t{\n\t\t\tList<Case> clist = splitMap.get(key);\n\t\t\tXMLCaseWriter xcw = new XMLCaseWriter();\n\t\t\tFile xml = new File(dir + key + \".cases.xml\");\n\t\t\txml.canWrite();\n\t\t\txcw.createXMLCaseFileFromList(csv, xml, justDir, equvCSV, clist, \"iswc-2014\");\n\t\t\t\n\t\t}\n\t\t//List<Case> list = lm.constructCaseListFromDisFile(dis);\n\t\t//Map<Case,ArrayList<String>> m =lm.getCaseListMetaData(list, csv);\n\t\t\n\t\t/**\n\t\tfor(Case c:m.keySet())\n\t\t{\n\t\t\tSystem.out.println(c.getOntology().toString());\n\t\t\tSystem.out.println(c.getEntailment().toString());\n\t\t\tfor(String s: m.get(c))\n\t\t\t{\n\t\t\t\tSystem.out.println(s);\n\t\t\t}\n\t\t}\n\t\t**/\n\t\t/**\n\t\tArrayList<CaseData> cd = lm.constructCaseDataFromCSV(list, csv);\n\t\tfor(CaseData data:cd)\n\t\t{\n\t\t\tSystem.out.println(data.getCase().getOntology());\n\t\t\tSystem.out.println(data.getCase().getEntailment().toString());\n\t\t\tSystem.out.println(\"METADATA: \" + data.getMetaData().getMetaData());\n\t\t\tSystem.out.println(\"EVIDENCE \" + data.getEvidence().getMetaData());\n\t\t\tSystem.out.println(\"RV:\");\n\t\t\tfor(ReasonerVerdict rv:data.getReasonerVerdicts())\n\t\t\t{\n\t\t\t\tSystem.out.println(rv.getReasoner());\n\t\t\t\tSystem.out.println(rv.getValue());\n\t\t\t}\n\t\t\tSystem.out.println(\"SUBCASES:\");\n\t\t\tfor(Subcase s:data.getSubcases())\n\t\t\t{\n\t\t\t\tSystem.out.println(s.getJustification());\n\t\t\t}\n\t\t\tSystem.out.println(\"\");\n\t\t}\n\t\tList<Subcase> sc = lm.extractSubcasesFromCaseData(cd);\n\t\tArrayList<SubcaseData> scd = lm.constructSubCaseDataFromCSV(sc, csv);\n\t\tfor(SubcaseData data:scd)\n\t\t{\n\t\t\tSystem.out.println(data.getCase().getOntology());\n\t\t\tSystem.out.println(data.getCase().getEntailment().toString());\n\t\t\tSystem.out.println(data.getCase().getJustification());\n\t\t\tSystem.out.println(\"GEN REASONER: \" + data.getGeneratingReasoner());\n\t\t\tSystem.out.println(\"METADATA: \" + data.getMetaData().getMetaData());\n\t\t\tSystem.out.println(\"EVIDENCE \" + data.getEvidence().getMetaData());\n\t\t\tSystem.out.println(\"RV:\");\n\t\t\tfor(ReasonerVerdict rv:data.getReasonerVerdicts())\n\t\t\t{\n\t\t\t\tSystem.out.println(rv.getReasoner());\n\t\t\t\tSystem.out.println(rv.getValue());\n\t\t\t}\n\t\t\tSystem.out.println(\"\");\n\t\t}\n\t\t\n\t\tXMLCaseWriter xcw = new XMLCaseWriter();\n\t\txcw.createXMLCaseFileFromDisAndCSV(dis, csv, xml, \"iswc-2014\");\n\t\t//xcw.createXMLCaseFileFromDis(csv, xml, \"iswc\");\n\t\t * \n\t\t */\n\t\t}", "private void generateSolution() {\n\t\t// TODO\n\n\t}", "@Override\n\tpublic GstSlabEntity modelToEntity(GstSlabModel m) {\n\t\treturn null;\n\t}", "public DoubleVec invModelToView(DoubleVec pos){\n return refPoint.sub((pos.sub(refPoint)).div(zoomFactor));\n }", "@Override\n\tprotected void generatePkgImports() {\n\t\toutputList.add(new OutputLine(indentLvl, \"import uvm_pkg::*;\"));\n\t\toutputList.add(new OutputLine(indentLvl, \"import ordt_uvm_reg_translate1_pkg::*;\"));\n\t\tif (UVMRdlTranslate1Classes.altModelPackage != null) outputList.add(new OutputLine(indentLvl, \"import \" + UVMRdlTranslate1Classes.altModelPackage + \";\")); // add alt model pkg\n\t\toutputList.add(new OutputLine(indentLvl, \"import jspec::*;\"));\n\t}", "@Override\r\n\tpublic void serialize(Model model, OutputStream outputStream) {\n\t\tResourceSet resourceSet = new ResourceSetImpl();\r\n\r\n\t\t// Register the default resource factory -- only needed for stand-alone!\r\n\t\tresourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap().put(\r\n\t\t\t Resource.Factory.Registry.DEFAULT_EXTENSION, new XMIResourceFactoryImpl()\r\n\t\t);\r\n\r\n\t\t// Get the URI of the model file.\r\n\t\t//URI uri = URI.createFileURI(new File(\"mylibrary.xmi\").getAbsolutePath());\r\n\t\tURI uri = URI.createURI(SPAGOBI_MODEL_URI);\r\n\t\t \r\n\t\t// Create a resource for this file.\r\n\t\tResource resource = resourceSet.createResource(uri);\r\n\t\t \r\n\t\t// Add the book and writer objects to the contents.\r\n\t\tresource.getContents().add(model);\r\n\t\r\n\t\t// Save the contents of the resource to the file system.\r\n\t\ttry {\r\n\t\t\t//resource.save(Collections.EMPTY_MAP);\r\n\t\t\tresource.save(outputStream, Collections.EMPTY_MAP);\r\n\t\t} catch (IOException e) {\r\n\t\t throw new RuntimeException(\"Impossible to serialize model [\" + model.getName() + \"]\", e);\r\n\t\t}\t\r\n\t}", "public Entrepot(Vector v){\r\n\t\tthis.id =(Integer)v.get(0);\r\n\t\tthis.localisation=new Localisation(\r\n\t\t\t\t(Integer)v.get(1),\r\n\t\t\t\t(String)v.get(2),\r\n\t\t\t\t(String)v.get(3),\r\n\t\t\t\t(String)v.get(4));\r\n\t\tthis.telephone=(String)v.get(5);\r\n\t}", "private void normalizeModel(List<Server> servers) {\n\n for (Server server : servers) {\n ServerInstance serverInstance = getServerInstance(new ServerRef(server.getHostName(), server.getName()));\n server.setServerState(serverInstance.getServerState());\n server.setSuspendState(serverInstance.getSuspendState());\n }\n }", "private Vector3d convertToModelAnswer()\r\n {\r\n GeographicPosition pos = (GeographicPosition)EasyMock.getCurrentArguments()[0];\r\n\r\n return pos.asVector3d();\r\n }", "public static void updateCoreModel(final Resource rootResource, HostControllerEnvironment environment) {\n final ModelNode rootModel = rootResource.getModel();\n rootModel.get(RELEASE_VERSION).set(Version.AS_VERSION);\n rootModel.get(RELEASE_CODENAME).set(Version.AS_RELEASE_CODENAME);\n rootModel.get(MANAGEMENT_MAJOR_VERSION).set(Version.MANAGEMENT_MAJOR_VERSION);\n rootModel.get(MANAGEMENT_MINOR_VERSION).set(Version.MANAGEMENT_MINOR_VERSION);\n\n // Community uses UNDEF values\n ModelNode nameNode = rootModel.get(PRODUCT_NAME);\n ModelNode versionNode = rootModel.get(PRODUCT_VERSION);\n\n if (environment != null) {\n String productName = environment.getProductConfig().getProductName();\n String productVersion = environment.getProductConfig().getProductVersion();\n\n if (productName != null) {\n nameNode.set(productName);\n }\n if (productVersion != null) {\n versionNode.set(productVersion);\n }\n }\n }", "public void revise()\n {\n // check the easy stuff -- out of range parameters\n super.revise();\n \n String nm = model.get(\"name\", \"Untitled\");\n String newnm = revisePatchName(nm);\n if (!nm.equals(newnm))\n model.set(\"name\", newnm);\n \n // deal with modulation amount destinations\n for(int i = 3; i < 16; i++)\n {\n if (model.get(\"mod\" + i + \"destination\") == i + 17) // can't refer to yourself\n model.set(\"mod\" + i + \"destination\", 0); // off\n for(int j = 3; j < 16; j++)\n {\n if (model.get(\"mod\" + j + \"destination\") == i + 17 && // someone is referring to you\n model.get(\"mod\" + i + \"destination\") >= 18) // you're using a modulation destination, not legal \n model.set(\"mod\" + i + \"destination\", 0); // off\n }\n }\n }", "protected void updateMavenInfo( String path )\r\n throws Exception\r\n {\n String g = null;\r\n String a = null;\r\n String v = null;\r\n String n = null;\r\n n = path.substring( path.lastIndexOf( '/' ) + 1 );\r\n \r\n Gav gav = getGavCalculator().pathToGav( path );\r\n if ( gav != null )\r\n {\r\n g = gav.getGroupId();\r\n a = gav.getArtifactId();\r\n v = gav.getBaseVersion();\r\n }\r\n else\r\n {\r\n logger.warn( \"Unable to parse good GAV values. Path: '\" + path + \"'. GAV: '\" + g + \":\" + a + \":\" + v + \"'\" );\r\n }\r\n \r\n Model model = null;\r\n if ( path.endsWith( \"pom\" ) )\r\n {\r\n Reader reader = ReaderFactory.newXmlReader( retrieveContent( path ) );\r\n \r\n MavenXpp3Reader xpp3 = new MavenXpp3Reader();\r\n \r\n try\r\n {\r\n model = xpp3.read( reader );\r\n \r\n String mg = model.getGroupId() == null ? model.getParent().getGroupId() : model.getGroupId();\r\n String ma = model.getArtifactId();\r\n String mv = model.getVersion() == null ? model.getParent().getVersion() : model.getVersion();\r\n \r\n // if the pom could provide good values\r\n if ( !isInpropriateValue( mg ) )\r\n {\r\n g = mg;\r\n }\r\n if ( !isInpropriateValue( ma ) )\r\n {\r\n a = ma;\r\n }\r\n if ( !isInpropriateValue( mv ) )\r\n {\r\n v = mv;\r\n }\r\n }\r\n catch ( Exception e )\r\n {\r\n // quietly ignore, we still can process this using gav from path\r\n logger.debug( \"Unable to parse POM model from '\" + path + \"'.\", e );\r\n // throw new Exception( \"Unable to parse POM model from '\" + path + \"'.\", e );\r\n }\r\n finally\r\n {\r\n reader.close();\r\n \r\n reader = null;\r\n }\r\n \r\n }\r\n \r\n if ( g == null || a == null || v == null )\r\n {\r\n logger.warn( \"Unable to resolve gav for '\" + path + \"'. g:\" + g + \" a:\" + a + \" v:\" + v );\r\n return;\r\n }\r\n \r\n if ( path.endsWith( \"pom\" ) )\r\n {\r\n // G\r\n if ( model != null && model.getPackaging().equals( \"maven-plugin\" ) )\r\n {\r\n Plugin plugin = new Plugin();\r\n \r\n plugin.setArtifactId( a );\r\n \r\n plugin.setPrefix( getPluginPrefix( a ) );\r\n \r\n if ( !StringUtils.isEmpty( model.getName() ) )\r\n {\r\n plugin.setName( model.getName() );\r\n }\r\n \r\n String gPath = \"/\" + g.replace( '.', '/' );\r\n \r\n if ( gData.get( gPath ) == null )\r\n {\r\n gData.put( gPath, new ArrayList<Plugin>() );\r\n }\r\n \r\n gData.get( gPath ).add( plugin );\r\n }\r\n \r\n // GA\r\n String gaPath = \"/\" + g.replace( '.', '/' ) + \"/\" + a;\r\n \r\n if ( gaData.get( gaPath ) == null )\r\n {\r\n gaData.put( gaPath, new ArrayList<String>() );\r\n }\r\n \r\n gaData.get( gaPath ).add( v );\r\n \r\n }\r\n \r\n // GAV\r\n if ( v.endsWith( \"SNAPSHOT\" ) )\r\n {\r\n String gavPath = \"/\" + g.replace( '.', '/' ) + \"/\" + a + \"/\" + v;\r\n \r\n if ( gavData.get( gavPath ) == null )\r\n {\r\n gavData.put( gavPath, new ArrayList<String>() );\r\n }\r\n \r\n gavData.get( gavPath ).add( n );\r\n }\r\n }", "public FullVersion MprisVersion();", "@SuppressWarnings(\"unused\") \n\tprivate void extractChanges(Node commit_node, RevCommit m) throws Exception\n\t{\n\n\t\tList<String> commitIds = new ArrayList<String>(); \n\n\t\tcommitIds.add(m.toObjectId().getName());\n\t\t\n\t\tCommitInfoExtractor cie = new CommitInfoExtractor();\n\t\tcie.extractFeatureChanges(commitIds);\n\t\tList<EvolutionStep>steps = cie.getSteps();\n\t\t\n\t\ttry(Transaction tx = DBConnection.getService().beginTx())\n\t\t{\n\t\t\tfor(EvolutionStep step : steps)\n\t\t\t{\n\t\t\t\tFileChangeExtractor file_changes = new FileChangeExtractor(commit_parents_list,files);\n\t\t\t\tList<Node> file_nodes = file_changes.addFileChangesToCommit(step.files, commit_node);\n\t\t\t\t\n\t\t\t\tVMChangeExtractor vm_changes = new VMChangeExtractor(commit_parents_list,files);\n\t\t\t\tList<Node> vm_nodes = vm_changes.addVMChangesToCommit(step.fm_changes, commit_node);\n\t\t\t\t\n\t\t\t\tBuildChangeExtractor build_changes = new BuildChangeExtractor(commit_parents_list,files);\n\t\t\t\tList<Node> build_nodes = build_changes.addBuildChangesToCommit(step.build_changes, commit_node);\n\t\t\t\t\n\t\t\t\tCodeChangeExtractor code_changes = new CodeChangeExtractor(commit_parents_list,files);\n\t\t\t\tList<Node> code_nodes = code_changes.addCodeChangesToCommit(step.impl_changes, commit_node);\n\n//\t\t\t\tList<EvolutionStep> local = new ArrayList<EvolutionStep>(); local.add(step);\n//\t\t\t\tFeatureOrientedChangeExtractor dataextractor = new FeatureOrientedChangeExtractor(local);\n//\t\t\t\tdataextractor.buildFeatureChanges();\n//\t\t\t\t\n//\t\t\t\tList<FeatureOrientedChange> changes = dataextractor.getFeatureChanges();\n//\t\n//\t\t\t\tList<Node> focs = new ArrayList<Node>();\n//\t\t\t\tfor(FeatureOrientedChange c : changes)\n//\t\t\t\t{\n//\t\t\t\t\tNode foc_node = createFeatureOrientedChangeForCommit(c);\n//\t\t\t\t\tfocs.add(foc_node);\n//\t\t\t\t\tlink_file_and_vm_changes(c,foc_node,file_nodes, vm_nodes,build_nodes,code_nodes); \n//\t\t\t\t}\n//\t\t\t\t\n//\t\t\t\tMap<String,Node> known_focs = buildFOCMap(focs);\n//\t\t\t\tlink_mapping_artefacts(known_focs,build_nodes);\n//\t\t\t\tlink_code_artefacts(known_focs,code_nodes);\n\t\t\t}\n\t\t\ttx.success();\n\t\t}\n\t\tcatch(Exception e)\n\t\t{\n\t\t\tthrow new Exception(\"Failed to create Neo4j nodes - \", e);\n\t\t}\n\t}", "private boolean updateRepChanges(boolean sync) {\r\n\t\t\r\n\t\ttry {\t\t\t\t\r\n\t\t\t// get repository header since we need count of versions \r\n\t\t\t// i.e. headVersionNum\r\n\t\t\tString status = \"Status: [ACTION - Update Repository]...\";\r\n\t\t\t\r\n\t\t\tstatusBar.setText(status+\"Loading repository header to find headVersionNumber\");\r\n\t\t\tboolean existsRep = this.loadRepositoryHeader();\r\n\t\t\tif (!existsRep) {\r\n\t\t\t\tif (DEBUG) System.out.println(\"NOT FOUND\");\r\n\t\t\t\t// update from local Swoop log anyway if uri matches ontURI\r\n\t\t\t\tthis.updateRepFromLog(new URI(this.repBaseOntFld.getText()));\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\t\tstatusBar.setText(status+\"HeadVersionNum=\"+this.headVersionNumber);\r\n\t\t\r\n\t\t\t// note: all version commits have been made to URLs:\r\n\t\t\t// repositoryURL+\"#1\"...\"#headVersionNum\"\r\n\t\t\t// so iterate through versionCommits and see if value is null, implying it hasn't been updated\r\n\t\t\tfor (int ctr=1; ctr<=this.headVersionNumber; ctr++) {\r\n\t\t\t\tif (versionNodes[ctr]==null) {\r\n\t\t\t\t\t// form URI using ctr\r\n\t\t\t\t\tURI versionURI = new URI(this.repositoryURI+\"#\"+ctr);\r\n\t\t\t\t\tstatusBar.setText(status+\"Updating version at \"+versionURI);\r\n\t\t\t\t\tSet commitSet = client.findAnnotations(versionURI);\r\n\t\t\t\t\t// get single Description (version) at URI\r\n\t\t\t\t\tDescription version = (Description) commitSet.iterator().next();\r\n\t\t\t\t\tversionDescriptions[ctr] = version;\r\n\t\t\t\t\tTreeTableNode mainNode = this.parseSingleCommit(version);\r\n\t\t\t\t\t// set params on mainNode\r\n\t\t\t\t\tmainNode.swoopChange.isOnRepository = true;\r\n\t\t\t\t\tmainNode.location = version.getLocation();\r\n\t\t\t\t\tversionNodes[ctr] = mainNode;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// also if advanced is off, update from local copy as well\r\n//\t\t\tif (!advanced) {\r\n//\t\t\t\tthis.updateRepFromLog(new URI(this.repBaseOntFld.getText()));\r\n//\t\t\t}\r\n\t\t\t\r\n\t\t\t// resort all nodes under root\r\n\t\t\tthis.refreshRepTreeTable(true);\r\n\t\t\t\r\n\t\t\t// update version repository cache\r\n\t\t\tswoopModel.updateVersionRepository(repositoryURI, versionDescriptions);\r\n\t\t\t\r\n\t\t\t// if sync is true, commit all changes to the synchronized ontology\r\n\t\t\tif (sync) {\r\n\t\t\t\tstatusBar.setText(status+\"Synching with Local Swoop Ontology\");\r\n\t\t\t\tthis.commitOntChanges(true);\t\t\t\t\r\n\t\t\t}\r\n\t\t\tstatusBar.setText(status+\"DONE\");\r\n\t\t\treturn true;\r\n\t\t}\r\n\t\tcatch (Exception ex) {\r\n\t\t\tex.printStackTrace();\r\n\t\t}\r\n\t\treturn false;\r\n\t}", "@Override\n public SystemResource pojoToEntity(SystemResourcePojo pojo){\n SystemResource entity = new SystemResource();\n\n entity.setName(pojo.getName());\n entity.setPath(pojo.getPath());\n entity.setType(pojo.getType());\n entity.setOriginalFileName(pojo.getOriginalFileName());\n entity.setUrl(pojo.getUrl());\n entity.setPublicKey(pojo.getPublicKey());\n return entity;\n }", "DataModelOracle getDataModelOracle( Path project );", "public String generateVSVID();", "private boolean sort(long codeSystemVersionId){\n org.hibernate.Session hb_session = HibernateUtil.getSessionFactory().openSession();\n hb_session.getTransaction().begin();\n boolean s = false;\n try\n {\n String hql = \"select distinct csev from CodeSystemEntityVersion csev\";\n hql += \" join fetch csev.codeSystemMetadataValues csmv\";\n hql += \" join fetch csmv.metadataParameter mp\";\n hql += \" join fetch csev.codeSystemEntity cse\";\n hql += \" join fetch cse.codeSystemVersionEntityMemberships csvem\";\n hql += \" join fetch csvem.codeSystemVersion csv\";\n \n \n HQLParameterHelper parameterHelper = new HQLParameterHelper();\n parameterHelper.addParameter(\"csv.\", \"versionId\", codeSystemVersionId);\n\n // Parameter hinzufügen (immer mit AND verbunden)\n hql += parameterHelper.getWhere(\"\");\n logger.debug(\"HQL: \" + hql);\n\n // Query erstellen\n org.hibernate.Query q = hb_session.createQuery(hql);\n\n // Die Parameter können erst hier gesetzt werden (übernimmt Helper)\n parameterHelper.applyParameter(q);\n \n List<CodeSystemEntityVersion> csevList = q.list();\n \n HashMap<Integer,CodeSystemEntityVersion> workList = new HashMap<Integer, CodeSystemEntityVersion>();\n ArrayList<Integer> sortList = new ArrayList<Integer>();\n \n Iterator<CodeSystemEntityVersion> iter = csevList.iterator();\n while(iter.hasNext()){\n boolean found = false;\n CodeSystemEntityVersion csev = (CodeSystemEntityVersion)iter.next();\n \n //Get the Level\n int level = 0;\n Iterator<CodeSystemMetadataValue> iter1 = csev.getCodeSystemMetadataValues().iterator();\n while(iter1.hasNext()){\n CodeSystemMetadataValue csmv = (CodeSystemMetadataValue)iter1.next();\n if(csmv.getMetadataParameter().getParamName().equals(\"Level\")){\n\n String cleaned = csmv.getParameterValue();\n \n if(cleaned.contains(\" \"))\n cleaned = cleaned.replace(\" \", \"\");\n\n level = Integer.valueOf(cleaned);\n }\n }\n \n if(level == lowestLevel){\n \n CodeSystemVersionEntityMembershipId csvemId = null;\n Set<CodeSystemVersionEntityMembership> csvemSet = csev.getCodeSystemEntity().getCodeSystemVersionEntityMemberships();\n Iterator<CodeSystemVersionEntityMembership> it = csvemSet.iterator();\n while(it.hasNext()){\n \n CodeSystemVersionEntityMembership member = (CodeSystemVersionEntityMembership)it.next();\n if(member.getCodeSystemEntity().getId().equals(csev.getCodeSystemEntity().getId())\n && member.getCodeSystemVersion().getVersionId().equals(codeSystemVersionId)){\n \n csvemId = member.getId();\n }\n }\n \n CodeSystemVersionEntityMembership c = (CodeSystemVersionEntityMembership)hb_session.get(CodeSystemVersionEntityMembership.class, csvemId);\n c.setIsMainClass(Boolean.TRUE);\n hb_session.update(c);\n \n workList.put(level, csev);\n sortList.add(level);\n }else{\n \n int size = sortList.size();\n int count = 0;\n while(!found){\n \n if((sortList.get(size-(1+count))-level) == -1){\n \n //Setting MemberShip isMainClass false\n CodeSystemVersionEntityMembershipId csvemId = null;\n Set<CodeSystemVersionEntityMembership> csvemSet = csev.getCodeSystemEntity().getCodeSystemVersionEntityMemberships();\n Iterator<CodeSystemVersionEntityMembership> it = csvemSet.iterator();\n while(it.hasNext()){\n\n CodeSystemVersionEntityMembership member = (CodeSystemVersionEntityMembership)it.next();\n if(member.getCodeSystemEntity().getId().equals(csev.getCodeSystemEntity().getId())\n && member.getCodeSystemVersion().getVersionId().equals(codeSystemVersionId)){\n\n csvemId = member.getId();\n }\n }\n\n CodeSystemVersionEntityMembership c = (CodeSystemVersionEntityMembership)hb_session.get(CodeSystemVersionEntityMembership.class, csvemId);\n c.setIsMainClass(Boolean.FALSE);\n hb_session.update(c);\n \n found = true;\n sortList.add(level);\n workList.put(level, csev);\n CodeSystemEntityVersion csevPrev = workList.get(sortList.get(size-(1+count)));\n \n CodeSystemEntityVersionAssociation association = new CodeSystemEntityVersionAssociation(); \n association.setCodeSystemEntityVersionByCodeSystemEntityVersionId1(new CodeSystemEntityVersion());\n association.getCodeSystemEntityVersionByCodeSystemEntityVersionId1().setVersionId(csevPrev.getVersionId());\n association.setCodeSystemEntityVersionByCodeSystemEntityVersionId2(new CodeSystemEntityVersion());\n association.getCodeSystemEntityVersionByCodeSystemEntityVersionId2().setVersionId(csev.getVersionId());\n association.setAssociationKind(2); // 1 = ontologisch, 2 = taxonomisch, 3 = cross mapping \n association.setLeftId(csevPrev.getVersionId()); // immer linkes Element also csev1\n association.setAssociationType(new AssociationType()); // Assoziationen sind ja auch CSEs und hier muss die CSEVid der Assoziation angegben werden.\n association.getAssociationType().setCodeSystemEntityVersionId(4L);\n // Weitere Attribute setzen\n association.setStatus(Definitions.STATUS_CODES.ACTIVE.getCode());\n association.setStatusDate(new Date());\n association.setInsertTimestamp(new Date());\n // Beziehung abspeichern\n hb_session.save(association);\n \n CodeSystemEntityVersion csevLoc = (CodeSystemEntityVersion)hb_session.get(CodeSystemEntityVersion.class, csevPrev.getVersionId());\n if(csevLoc.getIsLeaf() != Boolean.FALSE){\n csevLoc.setIsLeaf(Boolean.FALSE);\n hb_session.update(csevLoc);\n }\n\n }else{\n count++; \n found=false;\n }\n } \n }\n }\n \n hb_session.getTransaction().commit();\n s = true;\n }\n catch (Exception e)\n {\n hb_session.getTransaction().rollback();\n s = false;\n logger.error(\"[\" + this.getClass().getCanonicalName() + \"] Fehler bei initList(): \" + e.getMessage());\n }\n finally\n {\n hb_session.close();\n }\n return s;\n }", "public JmlModelImport () throws CGException {\n try {\n\n ivModel = null;\n ivImport = UTIL.ConvertToString(new String());\n }\n catch (Exception e){\n\n e.printStackTrace(System.out);\n System.out.println(e.getMessage());\n }\n }", "private File generatePomFile(Model model) {\n \n Writer writer = null;\n try {\n File pomFile = File.createTempFile(\"mvninstall\", \".pom\");\n writer = WriterFactory.newXmlWriter(pomFile);\n new MavenXpp3Writer().write(writer, model);\n return pomFile;\n } catch (IOException e) {\n logger.error(\"Error writing temporary POM file: \" + e.getMessage(), e);\n return null;\n } finally {\n IOUtil.close(writer);\n }\n }", "public ArcReversalSV(IDWithSVNodes id) {\n\n diag = id;\n network = id;\n results = new Vector();\n resultsForPolicies = new Vector();\n crono = new Crono();\n statistics = new PropagationStatisticsID();\n\n }", "public ArrayList parseCreateView(StatementTree sTree, String sysName) throws MDSException {\r\n\r\n\t\tArrayList sourceTables = new ArrayList();\r\n\t\tArrayList resultTableList = new ArrayList();\r\n\t\tHashMap map = sTree.map;\r\n\t\t// view name\r\n\t\tString viewNameWithDot = (String) map.get(\"view_name\");\r\n\t\tString[] temp = viewNameWithDot.split(\"\\\\.\");\r\n\t\tif (temp.length == 1)// 只有view的名称,不带库名前缀\r\n\t\t{\r\n\t\t\tviewNameWithDot = sysName + \".\" + viewNameWithDot;\r\n\t\t}\r\n\r\n\t\t// view source table definition\r\n\t\tTableSelectExpression selExp = (TableSelectExpression) map.get(\"select_expression\");\r\n\r\n\t\t// get all related tables\r\n\t\tArrayList tables = new ArrayList();\r\n\t\ttables = getAllTables(selExp);\r\n\r\n\t\t// 调用getSourceTableList函数获得select中相关表的源表\r\r\n\t\tfor (int i = 0; i < tables.size(); i++) {\r\n\t\t\t// String exp = tables.get(i) + \"==>\" + viewNameWithDot;\r\n\t\t\tsourceTables = getSourceTableList((String) tables.get(i));\r\n\t\t\ttemp_relation_num = temp_relation_num + sourceTables.size();\r\n\t\t\tif (ifBeyondLimit()) {\r\n\t\t\t\treturn null;\r\n\t\t\t}\r\n\t\t\tfor (int j = 0; j < sourceTables.size(); j++) {\r\n\t\t\t\tHashMap sourceTable = (HashMap) sourceTables.get(j);\r\n\t\t\t\tHashMap resultTable = new HashMap();\r\n\t\t\t\tif (sourceTable.get(\"sourceTable\") == \"\") {\r\n\t\t\t\t\tresultTable.put(\"targetTable\", viewNameWithDot);\r\n\t\t\t\t\tresultTable.put(\"sourceTable\", (String) sourceTable.get(\"targetTable\"));\r\n\t\t\t\t\t// resultTable.put(\"expression\", getSubComm(exp));\r\n\t\t\t\t\tresultTableList.add(resultTable);\r\n\t\t\t\t} else {\r\n\t\t\t\t\tresultTable.put(\"targetTable\", viewNameWithDot);\r\n\t\t\t\t\tresultTable.put(\"sourceTable\", (String) sourceTable.get(\"sourceTable\"));\r\n\t\t\t\t\t/*\r\n\t\t\t\t\t * String commentID = (String) sourceTable.get(\"expression\"); String relationComm = commentID; if (\r\n\t\t\t\t\t * sqlNum > sql_num_limit ) relationComm = getComment(commentID); if ( blankComment )\r\n\t\t\t\t\t * resultTable.put(\"expression\",\r\n\t\t\t\t\t * \"Relation transformation is too complex, please refer to the script for detailed info...\"); else\r\n\t\t\t\t\t * resultTable.put(\"expression\", getSubComm(relationComm + \" ==> \" + viewNameWithDot));\r\n\t\t\t\t\t */\r\n\t\t\t\t\tresultTableList.add(resultTable);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\treturn new ArrayList(new HashSet(resultTableList));\r\n\t}", "RolloutInner innerModel();", "public void generate(String rootDir, String helpersDir)\n {\n\t ClassModel classModel = (ClassModel) model.getClassModel();\n if (!GraphUtil.isExternal(model))\n {\n getOrCreateParser(rootDir);\n\n insertLicense(parser);\n\n insertInterfaces();\n\n insertConstants();\n\n insertImports();\n\n insertMethods(rootDir, helpersDir);\n\n if (GraphUtil.isInterface(model) == false)\n {\n insertSuperClass();\n insertPropertyChangeSupport(rootDir);\n \n \tinsertRemoveYouMethod(rootDir);\n \n insertInterfaceMethods(model, rootDir, helpersDir);\n \n\n if (classModel.hasFeature(Feature.SERIALIZATION, model))\n insertInterfaceAttributesInCreatorClass(model, rootDir, helpersDir);\n }\n\n generateAnnotations(rootDir, helpersDir);\n generateAttributes(rootDir, helpersDir, false);\n printFile();\n }\n else\n {\n generateAttributes(rootDir, helpersDir, false);\n }\n\n if (classModel.hasFeature(Feature.SERIALIZATION, model))\n { \n // now generate the corresponding creator class\n if (getRepairClassModel().hasFeature(Feature.SERIALIZATION))\n {\n getOrCreateParserForCreatorClass(helpersDir);\n\n insertClassInCreatorCreatorClass(getModel(), rootDir, creatorParser);\n\n insertRemoveObjectInCreatorClass();\n\n printFile(creatorParser);\n }\n }\n\n // now generate the corresponding ModelSet class\n if (classModel.hasFeature(Feature.SERIALIZATION, model))\n {\n getOrCreateParserForModelSetFile(helpersDir);\n printFile(modelSetParser);\n\n// if (getRepairClassModel().hasFeature(Feature.PATTERNOBJECT))\n// {\n\n // now generate the corresponding PatterObject class\n getOrCreateParserForPatternObjectFile(helpersDir);\n printFile(patternObjectParser);\n\n // now generate the corresponding PatterObjectCreator class\n getOrCreateParserForPatternObjectCreatorFile(helpersDir);\n printFile(patternObjectCreatorParser);\n// }\n }\n }" ]
[ "0.5357046", "0.52847695", "0.5010629", "0.48396647", "0.48334715", "0.47535685", "0.47139695", "0.4700494", "0.46858537", "0.46844965", "0.4649118", "0.46321416", "0.46272117", "0.4612716", "0.45847178", "0.45748532", "0.4563531", "0.45624587", "0.45585254", "0.4558419", "0.45325145", "0.4531703", "0.45241445", "0.4514101", "0.4509488", "0.44690827", "0.44517416", "0.44513643", "0.44508567", "0.4446003", "0.4443451", "0.44079307", "0.44003123", "0.4396642", "0.4396502", "0.43963468", "0.43882293", "0.43822664", "0.4368331", "0.43631518", "0.4360798", "0.43556288", "0.4352758", "0.43450528", "0.4336011", "0.4333758", "0.43221247", "0.4315237", "0.4315157", "0.43114245", "0.4306745", "0.42951643", "0.4291827", "0.4283049", "0.42801204", "0.42774317", "0.42686749", "0.42575565", "0.42549962", "0.4253493", "0.42515323", "0.4244875", "0.42408642", "0.42386106", "0.4219606", "0.42192593", "0.42171553", "0.42146185", "0.4209496", "0.4208995", "0.42033625", "0.41982707", "0.41933894", "0.41924202", "0.4185464", "0.41849652", "0.4183176", "0.4181461", "0.41797462", "0.4176504", "0.4173923", "0.41700825", "0.4160154", "0.41591585", "0.41583458", "0.415205", "0.4148675", "0.41482905", "0.41422126", "0.41370103", "0.41367576", "0.4128944", "0.4122567", "0.41219673", "0.411416", "0.41118935", "0.41108707", "0.41101134", "0.40975273", "0.40934125" ]
0.74576336
0
Create content retriever for revision
public IContentRetriever createContentRetriever(VssFileRevision revision) { if (config.isUseOnlyLastRevisionContent() && !revision.isLastRevision()) { return ZeroContentRetriever.INSTANCE; } else { return new VssContentRetriever(this, revision); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Test\n public void testAddAndGetRevision() throws Exception {\n Revision revision = Revision.createRevision(m_WIP_Document, new Date(), c_TestRevisionContent + \" (DYNAMIC)\");\n List<Revision> revisions = DocumentManager.getInstance().getRevisions(m_WIP_Document, QueryParam.UNSORTED);\n Assert.assertEquals(\"Expect 4th added revision\", 4, revisions.size());\n Assert.assertEquals(\"Expect correct revision content\", c_TestRevisionContent + \" (DYNAMIC)\", DocumentManager.getInstance().getRevisionContent(revisions.get(3)));\n }", "public abstract String getRevision();", "public Content createContent();", "ContentFactory getContentFactory();", "public File getFileRevision(SVNUrl repoUrl, SVNUrl url, String revision, String pegRevision, String fileName) throws IOException {\n boolean canUseRevisionsCache = true;\n try {\n canUseRevisionsCache = SVNRevision.getRevision(revision).getKind() == SVNRevision.Kind.number\n && SVNRevision.getRevision(pegRevision).getKind() == SVNRevision.Kind.number;\n } catch (ParseException ex) {\n }\n try {\n Context context = new Context(VCSFileProxy.createFileProxy(fileSystem.getRoot()));\n if (!canUseRevisionsCache || \"false\".equals(System.getProperty(\"versioning.subversion.historycache.enable\", \"true\"))) { //NOI18N\n SvnClient client = Subversion.getInstance().getClient(context, repoUrl);\n InputStream in = getInputStream(client, url, revision, pegRevision);\n return createContent(fileName, in);\n } else {\n String rootUrl = repoUrl.toString();\n String resourceUrl = url.toString() + \"@\" + pegRevision; //NOI18N\n Storage cachedVersions = StorageManager.getInstance().getStorage(rootUrl);\n File cachedFile = cachedVersions.getContent(resourceUrl, fileName, revision);\n if (cachedFile.length() == 0) { // not yet cached\n SvnClient client = Subversion.getInstance().getClient(context, repoUrl);\n InputStream in = getInputStream(client, url, revision, pegRevision);\n cachedFile = createContent(fileName, in);\n if (cachedFile.length() != 0) {\n cachedVersions.setContent(resourceUrl, revision, cachedFile);\n }\n }\n return cachedFile;\n }\n } catch (SVNClientException ex) {\n throw new IOException(\"Can not load: \" + url + \" in revision: \" + revision, ex); //NOI18N\n }\n }", "@Override\n public SideDishEntity load(Long id, Number revision) throws ObjectNotFoundException {\n return null;\n }", "public interface IRevisionRepository extends IAdaptable, IWorkbookComponent {\n\n /**\n * Gets the revision manager with corresponding resource ID. If no revision\n * manager is related to the specified resource ID, a new one will be\n * created with the specified content type.\n * \n * @param resourceId\n * the ID of the resource\n * @param contentType\n * the content type of the resource, see {@link IRevision} for\n * all available content types\n * @return the corresponding revision manager with the specified resource ID\n * @see IRevision\n * @see IRevisionManager\n */\n IRevisionManager getRevisionManager(String resourceId, String contentType);\n\n}", "@Override\n public ContentHandle get(int index) {\n return storage.getArtifactByContentId(contentIds.get(index)).getContent();\n }", "public VCSFileProxy getFileRevision(VCSFileProxy base, String revision, String pegRevision) throws IOException {\n try {\n SvnClientFactory.checkClientAvailable(new Context(base));\n } catch (SVNClientException e) {\n return null;\n }\n if (Setup.REVISION_BASE.equals(revision)) {\n return getBaseRevisionFile(base);\n } else if (Setup.REVISION_PRISTINE.equals(revision)) {\n // should not be used, will not work with 1.7\n String name = base.getName();\n VCSFileProxy svnDir = getMetadataDir(base.getParentFile());\n if (svnDir != null) {\n VCSFileProxy text_base = VCSFileProxy.createFileProxy(svnDir, \"text-base\"); // NOI18N\n VCSFileProxy pristine = VCSFileProxy.createFileProxy(text_base, name + \".svn-base\"); // NOI18N\n if (pristine.isFile()) {\n return pristine;\n } else {\n return null;\n }\n } else {\n return null;\n }\n } else if (Setup.REVISION_CURRENT.equals(revision)) {\n return base;\n } else {\n SVNRevision svnrevision = SvnUtils.toSvnRevision(revision);\n try {\n SvnClient client = Subversion.getInstance().getClient(base);\n FileStatusCache cache = Subversion.getInstance().getStatusCache();\n InputStream in = null;\n try {\n boolean gotContent = false;\n if ((cache.getStatus(base).getStatus() & FileInformation.STATUS_VERSIONED) != 0) {\n try {\n in = client.getContent(base, svnrevision);\n gotContent = true;\n } catch (SVNClientException e) {\n if(svnrevision.getKind() != SVNRevision.Kind.number \n || !(SvnClientExceptionHandler.isFileNotFoundInRevision(e.getMessage()) || SvnClientExceptionHandler.isPathNotFound(e.getMessage()))) {\n throw e;\n }\n }\n }\n if (!gotContent) {\n if (Setup.REVISION_BASE.equals(pegRevision)) {\n try {\n // we can't contact server with BASE being peg revision\n ISVNStatus st = SvnUtils.getSingleStatus(client, base);\n if (st != null && st.getRevision() != null) {\n pegRevision = st.getRevision().toString();\n } else {\n pegRevision = SVNRevision.HEAD.toString();\n }\n } catch (SVNClientException e) {}\n }\n SVNUrl url = SvnUtils.getRepositoryUrl(base);\n if (url != null) {\n in = getInputStream(client, url, revision, pegRevision);\n } else {\n in = new ByteArrayInputStream(org.openide.util.NbBundle.getMessage(VersionsCache.class, \"MSG_UnknownURL\").getBytes(\"UTF-8\")); // NOI18N\n } \n }\n } catch (SVNClientException e) {\n if(SvnClientExceptionHandler.isFileNotFoundInRevision(e.getMessage()) ||\n SvnClientExceptionHandler.isPathNotFound(e.getMessage())) {\n in = new ByteArrayInputStream(new byte[] {});\n } else {\n throw e;\n }\n }\n return VCSFileProxy.createFileProxy(createContent(base.getName(), in));\n } catch (SVNClientException ex) {\n throw new IOException(\"Can not load: \" + base.getPath() + \" in revision: \" + revision, ex); //NOI18N\n }\n }\n }", "public interface VersionedContent {\n /**\n * Version of the content.\n */\n long version();\n\n /**\n * Actual content\n */\n String content();\n }", "public interface Revision extends Comparable<Revision> {\n \n /**\n * Compares the revision to the given version string. Behaves like\n * {@link Comparable#compareTo(Object)}.\n */\n public int compareTo(String version);\n \n /**\n * Returns a string representation of the version of this revision. The\n * version is used by {@link #compareTo(String)} as well as to\n * serialize/deserialize revision information. Therefore it must be self\n * descriptive as well as be able to identify one revision from another.\n */\n public String getVersion();\n \n /**\n * Returns the files that comprise this revision, as a mapping from a source\n * to a list of files.\n */\n public Map<String,List<RevisionFile>> getSourceFiles();\n \n /**\n * Returns an {@link IndexInput} for the given fileName and source. It is the\n * caller's responsibility to close the {@link IndexInput} when it has been\n * consumed.\n */\n public InputStream open(String source, String fileName) throws IOException;\n \n /**\n * Called when this revision can be safely released, i.e. where there are no\n * more references to it.\n */\n public void release() throws IOException;\n \n}", "Object getRev();", "private void makeRequest() {\n\t\tRequest request = new Request(RequestCode.GET_REVISION_HISTORY);\n\t\trequest.setDocumentName(tabs.getTitleAt(tabs.getSelectedIndex()));\n\t\ttry {\n\t\t\toos.writeObject(request);\n\t\t} catch (IOException e1) {\n\t\t\te1.printStackTrace();\n\t\t}\n\t}", "@GetMapping(\"/revisions/{id}\")\n @Timed\n @Secured({RoleAuthority.SYS_ADMIN_AUTHORITY})\n public ResponseEntity<RevisionInfoDTO> getRevision(@PathVariable(\"id\") Integer id) {\n log.debug(\"REST request to get single revision: {}\", id.toString());\n return ResponseEntity.ok(revisionService.getRevision(id));\n }", "long getCurrentRevision();", "abstract public Content createContent();", "@Override\n public void newRevision(Object revisionEntity) {\n }", "@SuppressWarnings(\"unchecked\")\n private Optional<Revision<Integer, T>> getEntityForRevision(Integer revisionNumber, ID id, AuditReader reader) {\n\n\n EnversRevisionEntity<O> revision = reader.findRevision(EnversRevisionEntity.class, revisionNumber);\n T entity = reader.find(entityInformation.getJavaType(), id, revisionNumber);\n return Optional.of(Revision.of(this.getRevisionMetadata(revision), entity));\n }", "private LCSRevisableEntity createRevisableEntry(LCSProduct product, LCSSKU lcsSKu,\n\t\t\tString materialNumber, String sizedefVR, String sourceVersion,\n\t\t\tString costsheetVersion, String specVersion, String sourceName, String costName,\n\t\t\tString specName, String nrfCode, String styleNumber, String materialDescription,\n\t\t\tString IBTINSTOREMONTH,Collection bomMOAStringColl) throws WTException , WTPropertyVetoException {\n\t\t\n\t\tLCSRevisableEntityLogic revisableEntityLogic = new LCSRevisableEntityLogic();\n\t\t\n\t\tLCSRevisableEntity createRevEntity=null;\n\n\t\tLCSLog.debug(CLASSNAME+\"createRevisableEntry(), this is a fresh entry\");\n\t\t\n\t\tFlexType IBTFlexType = FlexTypeCache\n\t\t.getFlexTypeFromPath(LFIBTConstants.ibtMaterialPath);\n\t\t\n\t\tLCSRevisableEntity ibtMaterialRevObj = LCSRevisableEntity.newLCSRevisableEntity();;\n\t\tString revId = \"\";\n\t\t// Create Blank Revisable Entity Object for the productId\n\t\t\n\t\t\n\t\t//revModel.load(FormatHelper.getObjectId(this.getRevObj()));\n\t\t// create a new model in order to create a new revisable entity.\n\t\t//LCSRevisableEntityClientModel ibtRevEntityModel = new LCSRevisableEntityClientModel();\n\t\t//ibtRevEntityModel.set\n\t\t//ibtRevEntityModel.load(FormatHelper.getObjectId(rev));\n\t\t// set the flextype to ibtRevEntityModel sub type\n\t\tibtMaterialRevObj.setFlexType(IBTFlexType);\n\t\t//System.out.println(\"****************Inside setFlexType ***********************\");\n\t\t//ibtMaterialRevObj.setRevisableEntityName(FormatHelper.format(materialNumber\n\t\t\t//\t+ dateFormat.format(Calendar.getInstance().getTime())));\n\t\t// set the product att in revisable entity child type\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTPRODUCT, product);\n\n\t\t//PLM-170 Adding product ID change\n\t\tString prodId = String.valueOf(((Double)product.getProductARevId()).intValue());\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTPRODUCTID, prodId);\n\t\t//PLM-170 Adding product ID change\n\n\t\t//System.out.println(\"****************Inside product ***********************\"+product);\n\n\t\t// setting the divison att for sap material. \n\t\t// This will drive the ACL functionality.\n\t\tString division = (String) season.getValue(divisionKey);\n\t\tLCSLog.debug(\"division -- \" + division);\n\t\t// setting division att in ibtRevEntityModel\n\t\tibtMaterialRevObj.setValue(\"lfDivision\", division);\n\n\t\t// set the colorway att in revisable entity child type\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTCOLORWAY, lcsSKu);\n\n\t\t// set the size definition version Id\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTMASTERGRID, sizedefVR);\n\t\t// set the sourcing-config version\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTSOURCINGCONFIG, sourceVersion);\n\t\t// set the cost-sheet version\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTCOSTSHEET, costsheetVersion);\n\t\t\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTSPECIFICATION, specVersion);\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.STAGINSPECNAME, specName);\n\t\t// set the source name that is used in the staging area\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTSTAGINGSOURCENAME, sourceName);\n\t\t// set the cost-sheet name to that is entered in staging area\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTSTAGINGCOSTSHEETNAME, costName);\n\t\t//Added for 7.6\n\t\tif (FormatHelper.hasContent(LFIBTConstants.IBTMATERIALSTATUS)) {\n\t\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTMATERIALSTATUS,\n\t\t\t\t\"Create\");\n\t\t}\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTCOSTSHEETSTATUS,\"Sent\");\n\t\t\n\t\t//Added for 7.6\n\t \t//Create BOM MOA Rows..\n\t\t//LFIBTUtil.setBOMMOARows(ibtRevEntityModel, \"lfIBTBOMDetails\", bomMOAStringColl,\"create\");\n\t\t// set the NRF code.\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTNRFCODE, nrfCode);\n\t\t// set style number\n\t\t// Build 6.14\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTSTYLENUMBER, styleNumber);\n\t\t// set material description\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTMATERIALDESC,\n\t\t\t\tmaterialDescription);\n\n\t\t// set In strore Month\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTINSTOREMONTH, IBTINSTOREMONTH);\n\t\t// set SAP material number\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTMATERIALNUMBER, materialNumber);\n\t\t// set the season att\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTMASTERSEASON, this.season);\n\n\t\t// set the boolean value to checked. This check is needed for the\n\t\t// plugin to pick up the revisable entity\n\t\t//ibtRevEntityModel.setValue(LFIBTConstants.IBTUPDATECHECK, Boolean.TRUE);\n\t\t// set the master object\n\t\tibtMaterialRevObj.setValue(\"lfIBTMaster\", this.masterRevEntity);\n\t\t\n\t//\tSystem.out.println(\"****************Inside 11111111 ***********************\");\n\n\t\t\n\t\t\n\t\tLCSRevisableEntity ibtMaterialRev = (LCSRevisableEntity)revisableEntityLogic.saveRevisableEntity(ibtMaterialRevObj);\n\t\t\n\t\t// masterModel.save();\n\t\t\n\t\t//createRevEntity=ibtRevEntityModel.getBusinessObject();\n\t\t//LCSLog.debug(\"slave created : -- \" + ibtMaterialRevObj);\n\t\t\n\t\tLCSLog.debug(CLASSNAME+\"createRevisableEntry(),Calling setBOMMOARows()\");\n\t\tLFIBTUtil.setBOMMOARows(ibtMaterialRev, \"lfIBTBOMDetails\", bomMOAStringColl, \"create\");\n\t\tLCSLog.debug(CLASSNAME+\"createRevisableEntry(),slave created : -- \" + ibtMaterialRev);\n return ibtMaterialRev;\n\t}", "private FormatRevision<TargetType, ReaderType> get(int revisionId) {\n return revisionId < this.revisions.size() ? this.revisions.get(revisionId) : null;\n }", "public VCSFileProxy getFileRevision(VCSFileProxy base, String revision) throws IOException {\n return getFileRevision(base, revision, Setup.REVISION_BASE);\n }", "@Nonnull\n private Observable<String> beginRevision() {\n JsonObject revision = new JsonObject()\n .put(Revision.DATE, Instant.now())\n .put(Revision.STATE, Revision.State.PENDING)\n .put(Revision.CHANGES, new JsonArray());\n\n return doCreate(REVISIONS_CNAME, revision);\n }", "@Test\n public void multipleVersions() {\n repo.addDocument(\"test1\", \"{\\\"test\\\":1}\", \"arthur\", \"test version 1\", false);\n repo.addDocument(\"test1\", \"{\\\"test\\\":2}\", \"arthur\", \"this is version 2\", false);\n\n String result = repo.getDocument(\"test1\");\n assertEquals(\"{\\\"test\\\":2}\", result);\n }", "public String getRevisionReference();", "public long load(Map<Token,Long> revisions) throws IOException {\n long rev = -1;\n \n readBytes(13);\n readHeader(buffer);\n version = readVersion(buffer);\n int bufferSize = buffer.getInt();\n\n ByteBuffer uncompressedBuffer = ByteBuffer.allocate(bufferSize);\n byte[] compressedBuffer = new byte[bufferSize];\n \n int compressedLength = 0;\n while ((compressedLength = readCompressedChunk(compressedBuffer)) != 0) {\n \n // uncompress the chunk\n uncompressedBuffer.clear();\n int size = Snappy.uncompress(compressedBuffer, 0, compressedLength, uncompressedBuffer.array(), 0);\n uncompressedBuffer.position(size);\n uncompressedBuffer.flip();\n \n // load the database from the uncompressed buffer\n while (uncompressedBuffer.hasRemaining()) {\n Storable s = readType(uncompressedBuffer);\n if (s == revision) {\n revision.deserialize(uncompressedBuffer, version);\n rev = revision.getValue();\n continue;\n }\n \n Long expirationTime = null;\n if (s == expires) {\n expires.deserialize(uncompressedBuffer, version);\n expirationTime = expires.getExpires();\n s = readType(uncompressedBuffer);\n }\n \n Token key = new Token();\n key.deserialize(uncompressedBuffer, version);\n \n Model model = (Model) s;\n model.deserialize(uncompressedBuffer, version);\n if (expirationTime != null) {\n model.setExpirationTime(expirationTime);\n }\n Database.put(key, model);\n revisions.put(key, rev);\n }\n }\n \n return rev;\n }", "long currentRevision();", "public abstract long getRevision(int lineNumber);", "@Test\r\n public void testRevision() {\r\n InputStream inputstream = getClass().getClassLoader().getResourceAsStream(\"sample.json\");\r\n assert inputstream != null;\r\n Reader reader = new InputStreamReader(inputstream);\r\n JsonParser parser = new JsonParser();\r\n JsonElement rootElement = parser.parse(reader);\r\n\r\n RevisionParser revisionParser = new RevisionParser();\r\n List<Revision> revisionList = revisionParser.parse(rootElement);\r\n\r\n for (Revision r: revisionList) {\r\n System.out.println(r);\r\n }\r\n Assert.assertEquals(revisionList.get(0).toString(), \"Name: Monkbot\tTimeStamp: Fri Sep 13 11:10:41 EDT 2019\");\r\n }", "@Override\n public DocumentServiceEntry createDocument(String title, String contents) throws DocumentServiceException {\n DocsService svc = getDocsService();\n DocumentEntry newDocument = new DocumentEntry();\n newDocument.setTitle(new PlainTextConstruct(title));\n DocumentEntry entry;\n try {\n MediaByteArraySource source = new MediaByteArraySource(contents.getBytes(\"UTF8\"), \"text/plain\");\n newDocument.setMediaSource(source);\n entry = svc.insert(new URL(DOCS_SCOPE + \"default/private/full\"), newDocument);\n } catch (Exception e) {\n e.printStackTrace();\n throw new DocumentServiceException(e.getMessage());\n }\n return getDocumentReference(entry);\n }", "public VersionedContent retrieveLatest(String namespace, String id) throws StageException;", "DocumentContent createDocumentContent(byte[] bytes);", "private DataFetcherResult<NodeContent> baseNodeFetcher(DataFetchingEnvironment env) {\n\t\tContentDao contentDao = Tx.get().contentDao();\n\t\tGraphQLContext gc = env.getContext();\n\t\tHibProject project = env.getSource();\n\t\tHibNode node = project.getBaseNode();\n\t\tgc.requiresPerm(node, READ_PERM, READ_PUBLISHED_PERM);\n\t\tList<String> languageTags = getLanguageArgument(env);\n\t\tContainerType type = getNodeVersion(env);\n\n\t\tHibNodeFieldContainer container = contentDao.findVersion(node, gc, languageTags, type);\n\t\treturn NodeTypeProvider.createNodeContentWithSoftPermissions(env, gc, node, languageTags, type, container);\n\t}", "@Override\n public APIRevision getAPIRevision(String revisionUUID) throws APIManagementException {\n return apiMgtDAO.getRevisionByRevisionUUID(revisionUUID);\n }", "List<Content> getContentListForApproval();", "public AutomatizacionrevisionFactoryImpl() {\r\n\t\tsuper();\r\n\t}", "public interface DocumentContentFactory {\n\n /**\n * Creates a DocumentContent object for given byte array\n * @param bytes Input byte array - file content\n * @return DocumentContent object\n */\n DocumentContent createDocumentContent(byte[] bytes);\n}", "public String getParsedContent(String contextRoot, CmsPageRevision cmsPageRevision) throws InstantiationException, IllegalAccessException, ClassNotFoundException {\n\t\treturn this.getContent();\n\t}", "private void createView(Tab tab, VMFile file, PostProcessHandler handler) {\n editResourceService.getFileContent(file.getId(), new AsyncCallback<byte[]>() {\n\n @Override\n public void onFailure(Throwable caught) {\n SC.warn(caught.getMessage());\n }\n\n @Override\n public void onSuccess(byte[] result) {\n BinaryResourceImpl r = new BinaryResourceImpl();\n ByteArrayInputStream bi = new ByteArrayInputStream(result);\n AbstractRootElement root = null;\n try {\n if (file.getExtension() != Extension.TXT && file.getExtension() != Extension.LSC && file.getExtension() != Extension.CSC) {\n r.load(bi, EditOptions.getDefaultLoadOptions());\n root = (AbstractRootElement) r.getContents().get(0);\n }\n } catch (IOException e) {\n SC.warn(e.getMessage());\n }\n Editor editor;\n if (file.getExtension() == null) {\n editor = new TextEditor(tab, file, editResourceService);\n editor.create();\n } else\n switch (file.getExtension()) {\n\n case ARC:\n editor = new ARCEditor((ARCRoot) root, projectId, editResourceService);\n editor.create();\n clickNewStateMachine((ARCEditor) editor, file);\n clickOpenFile((ARCEditor) editor);\n break;\n case FM:\n editor = new FMEditor((FMRoot) root, projectId, file.getId(), editResourceService);\n editor.create();\n clickOpenFile((FMEditor) editor);\n clickCreateChildModel((FMEditor) editor, file);\n setFileNameToReferenceNode((FMEditor) editor);\n break;\n case FMC:\n editor = new FMCEditor((FMCRoot) root, file.getId(), projectId, editResourceService);\n editor.create();\n break;\n case FSM:\n editor = new FSMEditor((FSMDStateMachine) root, file.getId());\n editor.create();\n break;\n case SCD:\n editor = new SCDEditor((SCDRoot) root, tab, projectId, ModelingProjectView.this, editResourceService);\n editor.create();\n clickOpenFile((SCDEditor) editor);\n break;\n case SPQL:\n editor = new SPQLEditor((SPQLRoot) root, tab, projectId, editResourceService);\n editor.create();\n clickOpenFile((SPQLEditor) editor);\n break;\n case TC:\n editor = new TCEditor((TCRoot) root, projectId, file.getName(), editResourceService);\n editor.create();\n break;\n case BPS:\n editor = new BPSEditor((BPSRoot) root, ModelingProjectView.this, projectId, file.getId(), editResourceService);\n editor.create();\n break;\n case BP:\n editor = new BPEditor((BPRoot) root, projectId, file, editResourceService);\n editor.create();\n break;\n case FPS:\n editor = new TPSEditor((TPSRoot) root, ModelingProjectView.this, projectId, file.getId(), editResourceService);\n editor.create();\n break;\n case FP:\n editor = new TPViewer((TPRoot) root, projectId, file, editResourceService);\n editor.create();\n break;\n case CSC:\n editor = new CSCEditor(tab, file, editResourceService);\n editor.create();\n break;\n case SCSS:\n editor = new CBEditor((CBRoot) root, ModelingProjectView.this, projectId, file.getId(), editResourceService);\n editor.create();\n break;\n case SCS:\n editor = new SCSEditor((SCSRoot) root, ModelingProjectView.this, projectId, file, editResourceService);\n editor.create();\n break;\n case CSCS:\n editor = new CSCSEditor((CSCSRoot) root, projectId, file);\n editor.create();\n break;\n default:\n editor = new TextEditor(tab, file, editResourceService);\n editor.create();\n }\n createTabMenu(tab, editor.getSaveItem());\n clickSaveFile(editor, tab);\n\n if (editor instanceof NodeArrangeInterface) {\n NodeArrange.add((NodeArrangeInterface) editor);\n }\n tab.setPane(editor.getLayout());\n tab.setAttribute(EDITOR, editor);\n editorTabSet.addTab(tab);\n editorTabSet.selectTab(tab.getAttributeAsString(\"UniqueId\"));\n if (handler != null) {\n handler.execute();\n }\n }\n });\n }", "public abstract String getNewContent();", "long recalculateRevision();", "default void loadRevisionFileDataIntoMemory(AsyncCache<Integer, RevisionFileData> cache) {\n if (!cache.asMap().isEmpty()) {\n return;\n }\n\n final UberPage uberPage;\n if (exists()) {\n final Reader reader = createReader();\n final PageReference firstRef = reader.readUberPageReference();\n uberPage = (UberPage) firstRef.getPage();\n\n final var revisionNumber = uberPage.getRevisionNumber();\n final var revisionNumbers = new ArrayList<Integer>(revisionNumber);\n\n for (int i = 1; i <= revisionNumber; i++) {\n revisionNumbers.add(i);\n }\n\n cache.getAll(revisionNumbers, keys -> {\n final Map<Integer, RevisionFileData> result = new HashMap<>();\n keys.forEach(key -> result.put(key, reader.getRevisionFileData(key)));\n reader.close();\n return result;\n });\n }\n }", "protected abstract Content newContent();", "public OraRevision(ResultSet rs) throws SQLException {\n\t\trev_id = rs.getInt(\"rev_id\");\n\t\trev_page = rs.getInt(\"rev_page\");\n\t\trev_text_id = rs.getInt(\"rev_text_id\");\n\t\trev_timestamp = rs.getTimestamp(\"rev_timestamp\");\n\t\trev_comment = rs.getString(\"rev_comment\");\n\t\trev_user_text = rs.getString(\"user_name\");\n\t\t\n\t\tdbc = rs.getStatement().getConnection();\n\t}", "public OraRevision(Connection d, int id) {\n\t\tdbc = d;\n\t\trev_id = id;\n\t\ttext = null;\n\t\trev_page = -1;\n\t\trev_text_id = -1;\n\t\trev_comment = null;\n\t\trev_user_text = null;\n\t}", "@Override\n public void createContent(OutputStream out) throws Exception {\n\n // make sure we have the path to load from\n IParameterProvider request = parameterProviders.get( \"request\" ); //$NON-NLS-1$\n String fullPath = request.getStringParameter(\"filepath\", null); //$NON-NLS-1$\n if( fullPath == null ) {\n errorMessage( Messages.getErrorString(\"SolutionRepo.ERROR_0001_NO_FILEPATH\"), out ); //$NON-NLS-1$\n return;\n }\n\n ActionInfo info = ActionInfo.parseActionString( fullPath );\n if( info == null ) {\n errorMessage( Messages.getErrorString(\"SolutionRepo.ERROR_0003_BAD_PATH\", fullPath), out ); //$NON-NLS-1$\n return;\n }\n \n ISolutionRepository repo = PentahoSystem.get(ISolutionRepository.class, userSession);\n\n // try to get the file from the repository\n// Document doc = repo.getResourceAsDocument(fullPath, ISolutionRepository.ACTION_EXECUTE);\n Document doc = repo.getNavigationUIDocument(null, fullPath, ISolutionRepository.ACTION_EXECUTE);\n\n if( doc != null ) {\n Element stateNode = (Element) doc.selectSingleNode( \"state-file/state\" ); //$NON-NLS-1$\n if( stateNode != null ) {\n // write the loaded state to the output stream\n out.write( stateNode.getText().getBytes( ) );\n return;\n }\n }\n \n out.write( Messages.getErrorString(\"SolutionRepo.ERROR_0001_LOAD_FAILED\", fullPath).getBytes() ); //$NON-NLS-1$\n \n }", "@Nonnull\n private static JsonObject createDocumentForRevisionId(@Nonnull JsonArray changes,\n @Nonnull String targetRevisionId) throws RevisionNotFound {\n Objects.requireNonNull(changes, \"missing changes\");\n Objects.requireNonNull(targetRevisionId, \"missing revision target\");\n\n JsonObject result = new JsonObject();\n boolean found = false;\n final int size = changes.size();\n JsonObject change;\n for (int i = 0; i < size; i++) {\n change = changes.getJsonObject(i);\n result = applyDiff(change.getJsonArray(DocChange.DIFFS), result);\n if (change.getString(DocChange.REV).equals(targetRevisionId)) {\n found = true;\n break;\n }\n }\n\n if (!found) {\n throw new RevisionNotFound(\n String.format(\"Canno't found revision with id %s\", targetRevisionId));\n }\n return result;\n }", "@Test\n\tpublic void getIdWithRevision() throws Exception {\n\t\tRepository repo = new FileRepository(testRepo);\n\t\tRevCommit commit = add(\"d1/f1.txt\", \"content\");\n\t\tassertNull(TreeUtils.getId(repo, Constants.MASTER, \"d2/f1.txt\"));\n\t\tassertNull(TreeUtils.getId(repo, Constants.MASTER, \"d1/f1.txt\"));\n\t\tObjectId treeId = TreeUtils.getId(repo, Constants.MASTER, \"d1\");\n\t\tassertNotNull(treeId);\n\t\tassertFalse(treeId.equals(commit.getTree()));\n\t\tassertNull(BlobUtils.getId(repo, commit, \"d1\"));\n\t\tassertFalse(treeId.equals(BlobUtils.getId(repo, commit, \"d1/f1.txt\")));\n\t}", "private LCSRevisableEntity createEntries(String selectedId) {\n\t\t\n\t\tLCSRevisableEntity revEntity=null;\n\n\t\tLCSProduct product = null;\n\t\tLCSSKU lcsSku = null;\n\t\tString sizedefVR = \"\";\n\t\tString prodVR = \"\";\n\t\tString colorwayVR = \"\";\n\t\tString reventityVR = \"\";\n\t\t\n\t\tLCSLog.debug(\"****************Inside createEntries ***********************\");\n\t\t/*\n\t\t * is found in the request object.\n\t\t */\n\t\t// get division code from request.\n\t\tString divcode = this.requesttable.get(selectedId + \"_DIVISION_CODE\");\n\t\t// get material number from request\n\t\tString materialNumber = divcode\n\t\t\t\t+ this.requesttable.get(selectedId + \"_MATERIALNUMBER\");\n\t\t// get nrf code from request\n\t\tString nrfCode = \"\";\n\t\t// this.requesttable.get(selectedId + \"_NRF_CODE\");\n\t\t// get sourceVersion from request\n\t\tString sourceVersion = this.requesttable.get(selectedId + \"_SOURCE\");\n\t\t// get costsheetVersion from request\n\t\tString costsheetVersion = this.requesttable.get(selectedId + \"_COST\");\n\t\t\n\t\tString specVersion = this.requesttable.get(selectedId + \"_SPEC\");\n\t\t\n\t\tString bomRequestParam = this.requesttable.get(\"BOM\"+selectedId + \"_BOM\");\n\t\tLCSLog.debug(\"bomRequestParam = \"+bomRequestParam);\n\n\t\tString sourceName = \"\";\n\t\tString costName = \"\";\n\t\tString specName = \"\";\n\t\tString IBTINSTOREMONTH = \"\";\n\n\t\ttry {\n\t\t\t// get all the information from sourceVersion and costsheetVersion\n\t\t\tMap<String, String> map = LFIBTUtil.formatSourceOrCostsheetData(\n\t\t\t\t\tsourceVersion, costsheetVersion, specVersion);\n\t\t\t\n\t\t\t// source name\n\t\t\tsourceName = map.get(\"sourceNameKey\");\n\t\t\t// versionId\n\t\t\tsourceVersion = map.get(\"sourceVersionKey\"); \n\t\t\tLCSLog.debug(\"sourceName --- \" + sourceName);\n\t\t\t// costsheet name\n\t\t\tcostName = map.get(\"costNameKey\");\n\n\t\t\t// costsheetId\n\t\t\tcostsheetVersion = map.get(\"costsheetVersionKey\");\n\t\t\tLCSLog.debug(\"costName --- \" + costName);\n\t\t\t\n\t\t\tspecName = map.get(\"specNameKey\");\n\n\t\t\t// costsheetId\n\t\t\tspecVersion = map.get(\"specVersionKey\");\n\t\t\tLCSLog.debug(\"costName --- \" + costName);\t\t\t\n\n\t\t\tCollection<String> bomMOAStringColl = new ArrayList<String>();\n\t\t\tbomMOAStringColl = LFIBTUtil.formatBOMMultiChoiceValues(bomRequestParam);\n\t\t\t\n\t\t\tList<String> idList = LFIBTUtil.getObjects(selectedId);\n\n\t\t\t// parse and get all data\n\t\t\tMap<String, String> idMap = LFIBTUtil\n\t\t\t\t\t.createCustomMapFromList(idList);\n\t\t\t// get product ID\n\t\t\tprodVR = idMap.get(\"prodVR\");\n\n\t\t\tLCSLog.debug(\"prodVR : --\" + prodVR);\n\t\t\t// get the product object from productVR\n\t\t\tproduct = (LCSProduct) LCSProductQuery\n\t\t\t\t\t.findObjectById(\"VR:com.lcs.wc.product.LCSProduct:\"\n\t\t\t\t\t\t\t+ prodVR);\n\n\t\t\tLCSLog.debug(\"product : --\" + product);\n\n\t\t\t// size definition VR\n\t\t\tsizedefVR = idMap.get(\"sizedefVR\");\n\t\t\tLCSLog.debug(\"sizedefVR -- \" + sizedefVR);\n\n\t\t\t// colorway VR\n\t\t\tcolorwayVR = idMap.get(\"colorwayVR\");\n\t\t\tLCSLog.debug(\"colorwayVR : --\" + colorwayVR);\n\t\t\tlcsSku = (LCSSKU) LCSProductQuery\n\t\t\t\t\t.findObjectById(\"VR:com.lcs.wc.product.LCSSKU:\"\n\t\t\t\t\t\t\t+ colorwayVR);\n\n\t\t\t// NRF Code -- Build 5.16\n\t\t\tDouble d = 0.00;\n\t\t\td = (Double) lcsSku.getValue(\"lfNrfColorCode\");\n\t\t\tnrfCode = StringUtils.substringBeforeLast(Double.toString(d), \".\");\n\n\t\t\t/**\n\t\t\t * Build 5.16_3 -> START\n\t\t\t * Formatting NRF code to 3 digits before sending it to SAP\n\t\t\t */\n\t\t\t// getting length of code value\n\t\t\tint nrfCodeValueLength = nrfCode.length();\n\t\t\t// TRUE - if length is 1 or 2 digit\n\t\t\tif (nrfCodeValueLength == 2 || nrfCodeValueLength == 1) {\n\t\t\t\t// converting the value from double to integer\n\t\t\t\tint y = d.intValue();\n\t\t\t\t// formatting the value to be 3 digit always.\n\t\t\t\t// if not, append 0 to left\n\t\t\t\tnrfCode = (String.format(\"%03d\", y)).toString();\n\t\t\t}\n\t\t\t/**\n\t\t\t * Build 5.16_3 -> END\n\t\t\t */\n\n\t\t\t// get the revisable entity VR if applicable\n\t\t\treventityVR = idMap.get(\"reventityVR\");\n\n\t\t\t// Added for Build 6.14\n\t\t\t// ITC-START\n\t\t\tString materialDescription = this.requesttable.get(selectedId\n\t\t\t\t\t+ \"_MATERIALDESC\");\n\t\t\tIBTINSTOREMONTH = this.requesttable.get(selectedId + \"_INSTOREMONTH\");\n\t\t\tString styleNumber = this.requesttable.get(selectedId + \"_STYLE\");\n\t\t\t// ITC-END\n\t\t\t\n\t\t\t//MM : changes : Start ----\n\t\t\tif(!FormatHelper.hasContent(reventityVR))\n\t\t\t\treventityVR = LFIBTMaterialNumberValidator.getExistingMaterialRecords(materialNumber,false);\n\t\t\t//MM : changes : End ----\n\t\t\t/*\n\t\t\t * If the revisable entity VR exists then update the revisable\n\t\t\t * entity else create a new one.\n\t\t\t */\n\t\t\tif (reventityVR != null) \n\t\t\t{\n\t\t\t\tLCSLog.debug(\"sourceVersion -- \" + sourceVersion\n\t\t\t\t\t\t+ \" costsheetVersion - \" + costsheetVersion\n\t\t\t\t\t\t+ \" nrfCode -- \" + nrfCode\n\t\t\t\t\t\t+ \" materialDescription --\" + materialDescription\n\t\t\t\t\t\t+ \" IBTINSTOREMONTH--\" + IBTINSTOREMONTH\n\t\t\t\t\t\t+ \" style Number----\" + styleNumber);\n\n\t\t\t\t// API call to update the revisable entitity with new\n\t\t\t\t// source and cost details.\n\n\t\t\t\t// Updated for Build 6.14\n\t\t\t\tLCSLog.debug(CLASSNAME+\"createEntries()\"+\"calling updateRevisableEntry()\");\n\t\t\t\trevEntity=updateRevisableEntry(reventityVR, sourceVersion,\n\t\t\t\t\t\tcostsheetVersion,specVersion, nrfCode, materialDescription,\n\t\t\t\t\t\tsourceName, costName,specName, IBTINSTOREMONTH, styleNumber,bomMOAStringColl);\n\t\t\t\t\n\t\t\t\tLCSLog.debug(CLASSNAME+\"update revEntity---->\" +revEntity);\n\t\t\t}\n\t\t\telse {\n\t\t\t\t// API call to create fresh revisable entities.\n\n\t\t\t\t// Updated for Build 6.14\n\t\t\t\t\n\t\t\t\tLCSLog.debug(CLASSNAME+\"createEntries()\"+\"calling createRevisableEntry()\");\n\t\t\t\trevEntity=createRevisableEntry(product, lcsSku, materialNumber,\n\t\t\t\t\t\tsizedefVR, sourceVersion, costsheetVersion, specVersion, sourceName,\n\t\t\t\t\t\tcostName, specName, nrfCode, styleNumber, materialDescription,\n\t\t\t\t\t\tIBTINSTOREMONTH,bomMOAStringColl);\n\t\t\t\t\n\t\t\t\tLCSLog.debug(CLASSNAME+\"create revEntity---->\" +revEntity);\n\n\t\t\t}\n\t\t\t\n\n\t\t}\n\t\tcatch (WTException e) {\n\t\t\tLCSLog.error(\"WTException occurred!! \" + e.getMessage());\n\t\t}\n\t\tcatch (WTPropertyVetoException e) {\n\t\t\tLCSLog.error(\"WTPropertyVetoException occurred!! \" + e.getMessage());\n\t\t}\n\t\t\t\t\n\t\treturn revEntity;\n\n\t}", "private InputStream getInputStream (SvnClient client, SVNUrl url, String revision, String pegRevision) throws SVNClientException {\n InputStream in = null;\n try {\n in = client.getContent(url, SvnUtils.toSvnRevision(revision), SvnUtils.toSvnRevision(pegRevision));\n } catch (SVNClientException e) {\n if (SvnClientExceptionHandler.isFileNotFoundInRevision(e.getMessage()) ||\n SvnClientExceptionHandler.isPathNotFound(e.getMessage())) {\n in = new ByteArrayInputStream(new byte[]{});\n } else {\n throw e;\n }\n }\n return in;\n }", "@GetMapping(\"/revisions\")\n @Timed\n @Secured({RoleAuthority.SYS_ADMIN_AUTHORITY})\n public ResponseEntity<List<RevisionInfoDTO>> getRevisions(\n @PageableDefault(page = 0, size = Integer.MAX_VALUE) Pageable pageable) {\n log.debug(\"REST request to get page of revisions\");\n Page<RevisionInfoDTO> page = revisionService.getRevisions(pageable);\n return new ResponseEntity<>(page.getContent(), PaginationUtil\n .generatePaginationHttpHeaders(page, \"/api/revisions\"), HttpStatus.OK);\n }", "public RevisionDTO getRevision(Integer revision);", "private List<Integer> replaceRevisionRecords(boolean preview,\n PreparedStatement insert, ResultSet rs, Timestamp now, int revision)\n throws PSStringTemplateException, SQLException, NamingException\n {\n List<Integer> rval = new ArrayList<Integer>();\n Logger l = LogManager.getLogger(getClass());\n int nextid = getNextIdBlock(20, \"CONTENTSTATUSHISTORY\", preview);\n int end = nextid + 20 - 1;\n while (rs.next())\n {\n if (nextid >= end)\n {\n nextid = getNextIdBlock(20, \"CONTENTSTATUSHISTORY\", preview);\n end = nextid + 20 - 1;\n }\n int contentid = rs.getInt(1);\n if (!preview)\n {\n String title = rs.getString(2);\n int workflowappid = rs.getInt(3);\n l.debug(\"Inserting revision record for content id \" + contentid\n + \" rev \" + revision);\n insertContentStatusRecord(insert, now, \"RxFix\", null, \"Draft\",\n title, \"RxFix Inserted Revision History\", false,\n workflowappid, nextid++, contentid, revision);\n }\n else\n {\n l.debug(\"Would insert revision record for content id \" + contentid\n + \" rev \" + revision);\n }\n rval.add(new Integer(contentid));\n }\n return rval;\n }", "public Editor getEditor(String idRevista){\n Editor editor = null;\n String id, nome;\n\n try{\n connection = con.connect();\n PreparedStatement stm = connection.prepareStatement(\"SELECT Editor.* FROM Editor \" +\n \"INNER JOIN Revista \" +\n \"ON Revista.Editor_ID = Editor.ID \" +\n \"WHERE Revista.ID = \" + idRevista);\n ResultSet rs = stm.executeQuery();\n if(rs.next()){\n id = rs.getString(\"ID\");\n nome = rs.getString(\"Nome\");\n editor = new Editor(id,nome);\n }\n }\n catch (Exception e){\n e.getMessage();\n }\n finally {\n con.close(connection);\n }\n return editor;\n }", "public OraRevision nextRevision() throws SQLException {\n\t\tloadFromDB();\n\t\tPreparedStatement stmt = dbc.prepareStatement(\n\t\t\t\t\"SELECT rev_id FROM revision WHERE rev_id > ? AND rev_page = ? \" +\n\t\t\t\t\"ORDER BY rev_id ASC\"); \n\t\tstmt.setFetchSize(1);\n\t\tstmt.setInt(1, rev_id);\n\t\tstmt.setInt(2, rev_page);\n\t\tstmt.execute();\n\t\tResultSet rs = stmt.getResultSet();\n\t\tOraRevision r = null;\n\t\tif (rs.next())\n\t\t\tr = new OraRevision(dbc, rs.getInt(1));\n\t\trs.close();\n\t\tstmt.close();\n\t\treturn r;\n\t}", "public static String getBuildRevision(String... varargs) {\n\t\t// setting the default value when argument's value is omitted\n\t\tString pmaCoreURL = varargs.length > 0 ? varargs[0] : pmaCoreLiteURL;\n\t\tString url = PMA.join(pmaCoreURL, \"api/json/GetBuildRevision\");\n\t\tString version = null;\n\t\tif (PMA.debug) {\n\t\t\tSystem.out.println(url);\n\t\t}\n\t\ttry {\n\t\t\tURL urlResource = new URL(url);\n\t\t\tHttpURLConnection con;\n\t\t\tif (url.startsWith(\"https\")) {\n\t\t\t\tcon = (HttpsURLConnection) urlResource.openConnection();\n\t\t\t} else {\n\t\t\t\tcon = (HttpURLConnection) urlResource.openConnection();\n\t\t\t}\n\t\t\tcon.setRequestMethod(\"GET\");\n\t\t\tString jsonString = PMA.getJSONAsStringBuffer(con).toString();\n\t\t\tif (PMA.isJSONObject(jsonString)) {\n\t\t\t\tJSONObject jsonResponse = PMA.getJSONObjectResponse(jsonString);\n\t\t\t\tif (jsonResponse.has(\"Code\")) {\n\t\t\t\t\tif (PMA.logger != null) {\n\t\t\t\t\t\tPMA.logger.severe(\"getBuildRevision failed : \" + jsonResponse.get(\"Message\"));\n\t\t\t\t\t}\n\t\t\t\t\tthrow new Exception(\"getBuildRevision failed : \" + jsonResponse.get(\"Message\"));\n\t\t\t\t} else if (jsonResponse.has(\"d\")) {\n\t\t\t\t\tversion = jsonResponse.getString(\"d\");\n\t\t\t\t} else {\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tversion = jsonString.replaceAll(\"\\\"$|^\\\"\", \"\");\n\t\t\t}\n\t\t\treturn version;\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t\tif (PMA.logger != null) {\n\t\t\t\tStringWriter sw = new StringWriter();\n\t\t\t\te.printStackTrace(new PrintWriter(sw));\n\t\t\t\tPMA.logger.severe(sw.toString());\n\t\t\t}\n\t\t\treturn null;\n\t\t}\n\t}", "protected void createContents() {\n\n\t}", "public String getRevision() {\n return revision;\n }", "@RequestMapping(value = \"/currentRevisions/{id}\", method = RequestMethod.GET, produces = MediaType.APPLICATION_JSON_VALUE)\n\t@Timed\n\tpublic ResponseEntity<CurrentRevision> get(@PathVariable Long id, HttpServletResponse response) {\n\t\tlog.debug(\"REST request to get CurrentRevision : {}\", id);\n\t\tCurrentRevision currentRevision = currentRevisionRepository.findOne(id);\n\t\tif (currentRevision == null) {\n\t\t\treturn new ResponseEntity<>(HttpStatus.NOT_FOUND);\n\t\t}\n\t\treturn new ResponseEntity<>(currentRevision, HttpStatus.OK);\n\t}", "public Revision(String revision) throws UnsupportedEncodingException{\n if (revision == null){\n throw new NullPointerException(\"Null revisons not allowed\");\n }\n this.revision = MessageLibrary.toBytes(revision);\n }", "FileContent createFileContent();", "private void fetchPart(int i,int start, int step){\n //Commented for Server compile \n String currentFile = this.XmlFolderPath + \"\\\\\" + db + (fileCount++) + \".\" + this.retFormat;\n //Uncommented for Server compile \n // String currentFile = this.XmlFolderPath + \"/\" + db + (fileCount++) + \".xml\";\n\n // Log printing\n if(debugMode) {\n System.out.println(\" \" + new Date().toString() + \" \" + db + \" Fetch > Fetching articles \" \n + start + \" to \" + ( start + step )\n + \" \\n\\t writing to : \" + currentFile);\n }\n try {\n //write here response from Pubmed\n writer = new BufferedWriter(new FileWriter(currentFile));\n \n //assemble the esearch URL\n String base = \"https://eutils.ncbi.nlm.nih.gov/entrez/eutils/\";\n\n String url = base + \"efetch.fcgi?db=\"+db+\"&query_key=\" + queryKeys.get(i)\n + \"&WebEnv=\" + webEnvs.get(i) + \"&usehistory=y&rettype=\" + retFormat + \"&retmode=\" + retFormat\n + \"&retstart=\" + start + \"&retmax=\" + step;\n // Log printing\n if(debugMode) {\n System.out.println(\" \" + db + \" Search > Fetch url : \" + url);\n }\n \n // send GET request\n RequestConfig globalConfig = RequestConfig.custom().setCookieSpec(CookieSpecs.IGNORE_COOKIES).build();\n CloseableHttpClient client = HttpClients.custom().setDefaultRequestConfig(globalConfig).build();\n\n HttpGet request = new HttpGet(url);\n request.addHeader(base, base);\n\n HttpResponse response;\n response = client.execute(request);\n BufferedReader rd = new BufferedReader( new InputStreamReader(response.getEntity().getContent()));\n StringBuffer result = new StringBuffer();\n String line = \"\";\n\n while ((line = rd.readLine()) != null) {\n writer.append(line);\n writer.newLine();\n }\n \n writer.flush();\n writer.close(); \n } catch (IOException ex) {\n // Log printing\n if(debugMode) {\n System.out.println(\" \" + new Date().toString() + \" \" + db + \" Fetch > IO Exception \" + ex.getMessage());\n }\n } \n }", "abstract public InputStream retrieveContent( String path )\r\n throws Exception;", "TContent createContent(byte[] bytes, ContentFactory<TContent> contentFactory);", "@Override\n\tpublic GetContentResponse listContents() {\n\t\tLOGGER.debug(\"LIST ALL CONTENTS\");\n\t\t\n\t\tClientConfig clientConfig = new ClientConfig();\n\t\t \n\t HttpAuthenticationFeature feature = HttpAuthenticationFeature.basic(env.getProperty(\"liferay.user.id\"), env.getProperty(\"liferay.user.key\"));\n\t clientConfig.register( feature) ;\n\t \n\t clientConfig.register(JacksonFeature.class);\n\t\t\n\t\tClient client = ClientBuilder.newClient(clientConfig);\n\t\tWebTarget webTarget = client.target(env.getProperty(\"liferay.api.rootpath\")).path(\"article-id/0/content-type/tagtest\");\n\t\t \n\t\tInvocation.Builder invocationBuilder = webTarget.request(MediaType.APPLICATION_JSON);\n\t\n\t\tResponse response = invocationBuilder.get();\n\t\t \n\t\tGetContentResponse content = response.readEntity(GetContentResponse.class);\n\t\t\n\t\t\n\t\n\t\t \n\t\tLOGGER.info(\"status::\"+response.getStatus());\n\t\t\n\t\t\n\t\t\n\t\tcontent.setStatusCode(200);\n\t\tcontent.setStatusMessage(\"Content List\");\n\t\n\t\treturn content;\n\t}", "Blog read(int id);", "public ArrayList<LCSRevisableEntity> prepareToCreateEntries(String strActivity) \n\t{\n\t\tLCSLog.debug(CLASSNAME+\"prepareToCreateEntries(),:\"+\"ACTIVITY:\" +strActivity);\n ArrayList<LCSRevisableEntity> listOfRev=new ArrayList<LCSRevisableEntity>();\n LCSRevisableEntity entries=null;\n\t\t\n String selectedcolors = this.requesttable.get(\"selectedcolors\");\n\tLCSLog.debug(CLASSNAME+\"prepareToCreateEntries *************1**************\");\n\t\ttry {\n\t\t\tif (FormatHelper.hasContent(selectedcolors)) {\n\t\t\tLCSLog.debug(\"prepareToCreateEntries *************2**************\");\n\t\t\t\tCollection stagingItems = MOAHelper\n\t\t\t\t\t\t.getMOACollection(selectedcolors);\n\t\t\tLCSLog.debug(CLASSNAME+\"prepareToCreateEntries *************3**************\");\n\t\t\t\tLCSLog.debug(CLASSNAME+\"stagingItems.size() -- \" + stagingItems.size());\n\t\t\t\tIterator checkboxListIter = stagingItems.iterator();\n\t\t\t\twhile (checkboxListIter.hasNext()) \n\t\t\t\t{\n\t\t\t\t\t\n\t\t\t\t\tString id = (String) checkboxListIter.next();\n\t\t\t\t\tLCSLog.debug(CLASSNAME+\"prepareToCreateEntries\"+\"Calling createEntries()\");\n\t\t\t\t\tentries=createEntries(id);\n\t\t\t\t\t\n\t\t\t\t\tLCSLog.debug(CLASSNAME+\"ENTRIES::--->\" +entries);\n\t\t\t\t\tlistOfRev.add(entries);\n\t\t\t\t LCSLog.debug(CLASSNAME+\"It is sucesess of the creat revesiable entity\" +listOfRev.size());\t\n\t\t\t\t}\n\t\t\t\tLCSLog.debug(\"prepareToCreateEntries *************4**************\");\n\t\t\t\tLCSRevisableEntityClientModel masterModel = new LCSRevisableEntityClientModel();\n\t\t\t\tLCSLog.debug(\"prepareToCreateEntries *************5**************\");\n\t\t\t\tmasterModel.load(FormatHelper.getObjectId(this.masterRevEntity));\n\t\t\t\t\t\tLCSLog.debug(\"prepareToCreateEntries *************6**************\");\n\t\t\t\tmasterModel.setValue(LFIBTConstants.IBTMASTERUPDATECHECK,\n\t\t\t\t\t\tBoolean.TRUE);\n\t\t\t//Added for 7.6//\n\t\t\t\tif(strActivity.equalsIgnoreCase(\"COSTSHEET\")){\n\t\t\t\t\tmasterModel.setValue(LFIBTConstants.IBTACTIVITYSTATUS,\n\t\t\t\t\t\t\"COSTSHEET\");\n\t\t\t\t}else{\n\t\t\t\t\tmasterModel.setValue(LFIBTConstants.IBTACTIVITYSTATUS,\n\t\t\t\t\t\t\"PERSIST\");\n\t\t\t\t}\t\t\t\t\n\t\t\t\t//Added for 7.6//\n\t\t\t\t\t\tLCSLog.debug(CLASSNAME+\"prepareToCreateEntries *************7**************\");\n\t\t\t\tmasterModel.save();\n\n\t\t\t}\n\t\t\t\n\t\t}\n\t\tcatch (WTException exp) \n\t\t{\n\t\t\tLCSLog.error(\"WTException occurred!! \" + exp.getMessage());\n\n\t\t}\n\t\tcatch (WTPropertyVetoException exp) {\n\t\t\tLCSLog.error(\"WTPropertyVetoException occurred!!\");\n\n\t\t}\n\t\treturn listOfRev;\n\n\t}", "private RevObject getRevObject(ObjectId anId)\n{\n RevWalk rwalk = new RevWalk(getRepo());\n try { return rwalk.parseAny(anId); }\n catch(Exception e) { throw new RuntimeException(e); }\n}", "public String getRevisionId() {\n return revisionId;\n }", "public void store(String namespace, String id, long version, String content) throws StageException;", "public interface ContentRepository {\n /**\n * Stores content of a stream with the given name. Does not override the content with the same name.\n * Implementations can either rename the content and return the name; or throw an AlreadyExistentException\n *\n * @param is the content to store; the caller has to close the stream\n * @param name name to attach to the stored content on server\n * @param meta optional properties to be added next to the content\n * @return The name used to identify the stored content on server\n * @throws AlreadyExistentException if the implementation cannot support dynamic renaming of the content in case the name is already present\n * @throws java.io.IOException\n */\n String store(InputStream is, String name, Properties meta) throws AlreadyExistentException, IOException;\n}", "@Test\n public void testRelRevSupport() throws RepositoryException {\n assertExtract(\"/html/rdfa/rel-rev.html\");\n logger.debug(dumpModelToTurtle());\n\n assertContains(baseIRI, RDFUtils.iri(\"http://bob.example.com/cite\"),\n RDFUtils.iri(\"http://www.example.com/books/the_two_towers\"));\n assertContains(RDFUtils.iri(\"http://path/to/chapter\"), RDFUtils.iri(\"http://bob.example.com/isChapterOf\"),\n baseIRI);\n }", "ContentLoader getContentLoader(ClientRequestContext context);", "protected File getDocument(String dql, String ext) {\r\n\t\tlog.error(\"====================FUN��O getDocument NA CLASSE DocumentumCoreServicesImpl==================\");\r\n\t\tlog.error(\"====================PARAMETROS RECEBIDOS================== DQL \"\r\n\t\t\t\t+ dql + \" ================== ext \" + ext);\r\n\t\tFile fileReturn = null;\r\n\r\n\t\tContentProfile contentProfile = new ContentProfile();\r\n\r\n\t\tcontentProfile.setFormatFilter(FormatFilter.SPECIFIED);\r\n\r\n\t\tcontentProfile.setFormat(ext);\r\n\t\tlog.error(\"======================= contentProfile.setFormat====== \"\r\n\t\t\t\t+ ext);\r\n\t\tcontentProfile.setContentReturnType(FileContent.class);\r\n\r\n\t\tOperationOptions operationOptions = new OperationOptions();\r\n\r\n\t\toperationOptions.setContentProfile(contentProfile);\r\n\t\tlog.error(\"======================= operationOptions.setContentProfile====== \"\r\n\t\t\t\t+ contentProfile);\r\n\t\tContentTransferProfile transferProfile = new ContentTransferProfile();\r\n\r\n\t\toperationOptions.setContentTransferProfile(transferProfile);\r\n\r\n\t\tQualification qualification1 = new Qualification(dql);\r\n\r\n\t\tObjectIdentity targetObjectIdentity1 = new ObjectIdentity(\r\n\t\t\t\tqualification1, REPOSITORY_NAME);\r\n\t\tlog.error(\"======================= targetObjectIdentity1 (qualification1, REPOSITORY_NAME)====== \"\r\n\t\t\t\t+ targetObjectIdentity1);\r\n\t\tObjectIdentitySet objIdSet = new ObjectIdentitySet();\r\n\r\n\t\tobjIdSet.addIdentity(targetObjectIdentity1);\r\n\r\n\t\tDataPackage dataPackage;\r\n\r\n\t\ttry {\r\n\r\n\t\t\tdataPackage = this.objectService.get(objIdSet,\r\n\t\t\t\t\toperationOptions);\r\n\t\t\tlog.error(\"======================= objIdSet ====== \" + objIdSet);\r\n\t\t\tlog.error(\"======================= operationOptions ====== \"\r\n\t\t\t\t\t+ operationOptions);\r\n\r\n\t\t\tDataObject dataObject = dataPackage.getDataObjects().get(0);\r\n\t\t\tlog.error(\"======================= dataObject ====== \"\r\n\t\t\t\t\t+ dataPackage.getDataObjects().get(0));\r\n\t\t\tContent resultContent = dataObject.getContents().get(0);\r\n\t\t\tlog.error(\"======================= resultContent ====== \"\r\n\t\t\t\t\t+ dataObject.getContents().get(0));\r\n\r\n\t\t\tFileContent fileContent = (FileContent) resultContent;\r\n\t\t\tfileReturn = fileContent.getAsFile();\r\n\r\n\t\t} catch (CoreServiceException e) {\r\n\t\t\tSystem.out.println(\"CoreServiceException \\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\");\r\n\t\t\tSystem.out.println(e.getMessage());\r\n\t\t\tlogger.error(ERROR_REPOSITORIO_EMC.concat(e.getLocalizedMessage()));\r\n\t\t\tSystem.out.println(\"\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n CoreServiceException\");\r\n\t\t} catch (ServiceException e) {\r\n\t\t\tSystem.out.println(\"ServiceException \\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\");\r\n\t\t\tSystem.out.println(e.getMessage());\r\n\t\t\tlogger.error(ERROR_SERVICO_EMC.concat(e.getLocalizedMessage()));\r\n\t\t\tSystem.out.println(\"\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n ServiceException\");\r\n\r\n\t\t}\r\n\t\tlog.error(\"==================== FIM FUN��O getDocument NA CLASSE DocumentumCoreServicesImpl==================\");\r\n\r\n\t\t/*\r\n\t\t * File source = new File(fileReturn.getPath()); File dest = new\r\n\t\t * File(\"D:\\\\Temp\\\\file2.docx\"); try { FileUtils.copyFile(source, dest);\r\n\t\t * } catch (IOException e) { e.printStackTrace(); }\r\n\t\t */\r\n\r\n\t\treturn fileReturn;\r\n\r\n\t}", "public interface ContentRepository {\n\n List<Content> findContentList(int bbsId, int pageNum, int perPage, int searchMode, String searchContent);\n\n long findContentCount(int bbsId, int searchMode, String searchContent);\n\n void saveContent(Content content);\n\n Content findContentById(int contentId);\n\n void updateContent(Content content);\n\n void deleteContent(int contentId, String userid);\n\n List<Content> getBbsNoticeThumnailList(int bbsId);\n\n}", "GitBlob(RevBlob aRB, String aPath) { _rev = aRB; _path = aPath; }", "public void getCache(int docid){\n try {\n FileReader fr;\n String file_name = ServerThread.collection_path+docid+\".html\";\n fr = new FileReader(file_name);\n BufferedReader file_input = new BufferedReader(fr);\n String line;\n String file_content=\"\";\n while ((line = file_input.readLine()) != null) {\n file_content += line;\n }\n fr.close(); \n send(file_content);\n //System.out.println(file_content); \n } \n catch (IOException ex) {\n Logger.getLogger(ServerThread.class.getName()).log(Level.SEVERE, null, ex);\n System.out.println(\"Could not access file: \"+docid);\n } \n }", "@Test\r\n public void wholeThingTest() {\r\n String inputString = \"Obama\";\r\n// listView.getItems().add(\"some new element\");\r\n URL url = null;\r\n try {\r\n url = new URL(\"https://en.wikipedia.org/w/api.php?action=query&format=json&prop=revisions&titles=\" + URLEncoder.encode(inputString,(\"utf-8\")) + \"&rvprop=timestamp|user&rvlimit=24&redirects\");\r\n } catch (MalformedURLException e) {\r\n e.printStackTrace();\r\n } catch (UnsupportedEncodingException e) {\r\n e.printStackTrace();\r\n }\r\n URLConnection connection = null;\r\n try {\r\n connection = url.openConnection();\r\n } catch (IOException e) {\r\n e.printStackTrace();\r\n }\r\n InputStream in = null;\r\n try{\r\n in = connection.getInputStream();\r\n } catch (IOException e) {\r\n e.printStackTrace();\r\n }\r\n Reader reader = new InputStreamReader(in);\r\n JsonParser jsonParser = new JsonParser();\r\n JsonElement rootElement = jsonParser.parse(reader);\r\n\r\n RevisionParser parser = new RevisionParser();\r\n List<Revision> revisions = parser.parse(rootElement);\r\n\r\n for (Revision r: revisions) {\r\n System.out.println(r);\r\n }\r\n }", "@Override\n public String getCurrentRevision(String id) {\n return \"\\\"\" + documentService.getCurrentRevision(id) + \"\\\"\";\n }", "public List<RevistaJE> getListaRevistasJE(String vusuario, String vsenha) throws ClassNotFoundException, SQLException{\r\n\r\n\t\t\r\n\t\tParametros parametros = new Parametros(new ListaAmbiente().mostraAmbiente(vusuario, vsenha));\r\n\t\tConnection conexao = new ConnectionFactory().getConnection(parametros.getBanco(), vusuario, vsenha);\r\n\t\t\r\n\t\tList<RevistaJE> documentos = new ArrayList<RevistaJE>();\r\n\t\t\r\n\t\t\r\n\t\tint idArea = 74; //Área correspondente a Revista JE\r\n\t\t\r\n\r\n\t\tString vsql = \"SELECT To_Char(a.data_inclusao,'dd/mm/yyyy') as data, To_Char(a.data_inclusao,'HH24:mi:ss') as hora, a.descricao, c.observacao as obs, a.publicado as edital, a.id_arquivo, a.id_conteudo, \" +\r\n\t\t\t\t\"c.logon_usuario_criacao AS usuario_publicador, decode(Sign(c.data_ult_alteracao-a.data_inclusao),-1,'-',0,'-',NULL,'-',To_Char(c.data_ult_alteracao,'dd.mm.yyyy HH24:mi')) AS ultima_alteracao, \" +\r\n\t\t\t\t\"decode(Sign(c.data_ult_alteracao-a.data_inclusao),-1,'-',0,'-',NULL,'-',c.logon_usuario_ult_alteracao) AS usuario_alteracao, To_Char(a.data_inclusao,'mm') AS mes \" + \r\n\t\t\t\t\"FROM gecoi.arquivo a, gecoi.conteudo c, gecoi.conteudo_area ca \" +\r\n\t\t\t\t\"WHERE c.id_conteudo=ca.id_conteudo AND a.id_conteudo=c.id_conteudo \" +\r\n\t\t\t\t\"and a.ordem=0 AND ca.id_area=?\";\r\n\t\t\r\n\t\tPreparedStatement pstm = conexao.prepareStatement(vsql);\r\n\t\tpstm.setInt(1, idArea);\r\n\r\n\t\tResultSet rs = pstm.executeQuery();\r\n\t\t\r\n\t\twhile (rs.next())\r\n\t\t{\r\n\t\t\tRevistaJE gecoi = new RevistaJE();\r\n\t\t\tgecoi.setDataPublicacao(rs.getString(\"data\"));\r\n\t\t\tgecoi.setHoraPublicacao(rs.getString(\"hora\"));\r\n\t\t\tgecoi.setDescricao_arquivo(rs.getString(\"descricao\"));\r\n\t\t\t//System.out.println(rs.getString(\"descricao\"));\r\n\t\t\t\r\n\t\t\tString[] descricao_completa = rs.getString(\"descricao\").split(\" \");\r\n\t\t\t\r\n\t\t\tif(descricao_completa.length == 17)\r\n\t\t\t{\r\n\t\t\t\tgecoi.setVolume(descricao_completa[7]);\r\n\t\t\t\tgecoi.setNumero(descricao_completa[10]);\r\n\t\t\t\tgecoi.setMes_inicial(descricao_completa[12]);\r\n\t\t\t\tgecoi.setMes_final(descricao_completa[14]);\r\n\t\t\t\tgecoi.setAno_final(descricao_completa[16]);\r\n\t\t\t\tgecoi.setAno_inicial(descricao_completa[16]);\r\n\t\t\t}\r\n\t\t\telse//Se o ano final for diferente do ano inicial\r\n\t\t\t{\r\n\t\t\t\tgecoi.setVolume(descricao_completa[7]);\r\n\t\t\t\tgecoi.setNumero(descricao_completa[10]);\r\n\t\t\t\tgecoi.setMes_inicial(descricao_completa[12]);\r\n\t\t\t\tgecoi.setAno_inicial(descricao_completa[14]);\r\n\t\t\t\tgecoi.setMes_final(descricao_completa[16]);\r\n\t\t\t\tgecoi.setAno_final(descricao_completa[18]);\r\n\t\t\t\t\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tgecoi.setIdArquivo(rs.getInt(\"id_arquivo\"));\r\n\t\t\tgecoi.setIdConteudo(rs.getInt(\"id_conteudo\"));\r\n\t\t\tgecoi.setUsuario(rs.getString(\"usuario_publicador\"));\r\n\t\t\tgecoi.setDataAlteracao(rs.getString(\"ultima_alteracao\"));\r\n\t\t\tgecoi.setUsuario_ateracao(rs.getString(\"usuario_alteracao\"));\r\n\t\t\tgecoi.setMes(rs.getString(\"usuario_alteracao\"));\r\n\t\t\tgecoi.setMes(rs.getString(\"mes\"));\r\n\t\t\tdocumentos.add(gecoi);\r\n\t\t}\r\n\t\trs.close();\r\n\t\tconexao.close();\r\n\t\treturn documentos;\r\n\r\n\t}", "@Override\n public synchronized Response getDocByModule(final String module, final String revision, final UriInfo uriInfo) {\n final ApiDeclaration doc;\n if (isNew(uriInfo)) {\n doc = apiDocGeneratorRFC8040.getApiDeclaration(module, revision, uriInfo);\n } else {\n doc = apiDocGeneratorDraft02.getApiDeclaration(module, revision, uriInfo);\n }\n\n return Response.ok(doc).build();\n }", "CopySearchResult find(ContentQuery query) throws ResourceAccessException;", "protected abstract byte[] getEntity(EntityType entityType, String entityName, int entityVersion) throws IOException;", "@Override\r\n public String update(final String id, final String xmlData) throws ContentModelNotFoundException,\r\n OptimisticLockingException, SystemException, ReadonlyVersionException, MissingAttributeValueException,\r\n InvalidXmlException, InvalidContentException {\r\n \r\n setContentModel(id);\r\n final DateTime startTimestamp = getContentModel().getLastFedoraModificationDate();\r\n checkLatestVersion();\r\n \r\n // parse incomming XML\r\n final StaxParser sp = new StaxParser();\r\n // check optimistic locking criteria! and ID in root element?\r\n sp.addHandler(new OptimisticLockingHandler(getContentModel().getId(), Constants.CONTENT_MODEL_OBJECT_TYPE,\r\n getContentModel().getLastModificationDate()));\r\n // get name and description\r\n final ContentModelPropertiesHandler cmph = new ContentModelPropertiesHandler(sp);\r\n sp.addHandler(cmph);\r\n // get md-record definitions\r\n final MdRecordDefinitionHandler mrdh =\r\n new MdRecordDefinitionHandler(sp, \"/content-model/md-record-definitions\");\r\n sp.addHandler(mrdh);\r\n // get resource definitions\r\n final ResourceDefinitionHandler rdh = new ResourceDefinitionHandler(sp, \"/content-model/resource-definitions\");\r\n sp.addHandler(rdh);\r\n // get content-streams\r\n final ContentStreamsHandler csh = new ContentStreamsHandler(sp, \"/content-model/content-streams\");\r\n sp.addHandler(csh);\r\n \r\n try {\r\n sp.parse(xmlData);\r\n }\r\n catch (final WebserverSystemException e) {\r\n throw e;\r\n }\r\n catch (final MissingAttributeValueException e) {\r\n throw e;\r\n }\r\n catch (final InvalidXmlException e) {\r\n throw e;\r\n }\r\n catch (final InvalidContentException e) {\r\n throw e;\r\n }\r\n catch (final OptimisticLockingException e) {\r\n throw e;\r\n }\r\n catch (final Exception e) {\r\n XmlUtility.handleUnexpectedStaxParserException(null, e);\r\n }\r\n \r\n final String description = getContentModel().getDescription() != null ? getContentModel().getDescription() : \"\";\r\n \r\n if (!getContentModel().getTitle().equals(cmph.getProperties().getObjectProperties().getTitle())\r\n || !description.equals(cmph.getProperties().getObjectProperties().getDescription())) {\r\n // update DC (title, description)\r\n final Datastream dc = getContentModel().getDc();\r\n final StaxParser dcParser = new StaxParser();\r\n \r\n final TreeMap<String, StartElementWithText> updateElementsDc = new TreeMap<String, StartElementWithText>();\r\n \r\n updateElementsDc.put(Elements.ELEMENT_DC_TITLE, new StartElementWithText(Elements.ELEMENT_DC_TITLE,\r\n Constants.DC_NS_URI, Constants.DC_NS_PREFIX, cmph.getProperties().getObjectProperties().getTitle(),\r\n null));\r\n \r\n updateElementsDc.put(Elements.ELEMENT_DC_DESCRIPTION, new StartElementWithText(\r\n Elements.ELEMENT_DC_DESCRIPTION, Constants.DC_NS_URI, Constants.DC_NS_PREFIX, cmph\r\n .getProperties().getObjectProperties().getDescription(), null));\r\n \r\n final DcUpdateHandler dcUpdateHandler = new DcUpdateHandler(updateElementsDc, dcParser);\r\n \r\n dcParser.addHandler(dcUpdateHandler);\r\n final HashMap<String, String> extractPathes = new HashMap<String, String>();\r\n final MultipleExtractor me = new MultipleExtractor(extractPathes, dcParser);\r\n extractPathes.put(\"/dc\", null);\r\n dcParser.addHandler(me);\r\n final byte[] dcNewBytes;\r\n try {\r\n dcParser.parse(dc.getStream());\r\n final ByteArrayOutputStream dcUpdated = (ByteArrayOutputStream) me.getOutputStreams().get(\"dc\");\r\n dcNewBytes = dcUpdated.toByteArray();\r\n }\r\n catch (final Exception e) {\r\n throw new XmlParserSystemException(e);\r\n }\r\n final String dcNew;\r\n try {\r\n dcNew = new String(dcNewBytes, XmlUtility.CHARACTER_ENCODING);\r\n }\r\n catch (final UnsupportedEncodingException e) {\r\n throw new EncodingSystemException(e);\r\n }\r\n \r\n final Datastream newDs;\r\n try {\r\n newDs =\r\n new Datastream(\"DC\", getContentModel().getId(), dcNew.getBytes(XmlUtility.CHARACTER_ENCODING),\r\n MimeTypes.TEXT_XML);\r\n }\r\n catch (final UnsupportedEncodingException e) {\r\n throw new WebserverSystemException(e);\r\n }\r\n getContentModel().setDc(newDs);\r\n \r\n }\r\n \r\n final String sdexIdMidfix = getContentModel().getId().replaceAll(\":\", Constants.COLON_REPLACEMENT_PID) + '-';\r\n final String sdefIdPrefix = \"sdef:\" + sdexIdMidfix;\r\n // String sdepIdPrefix = \"sdep:\" + sdexIdMidfix;\r\n final Map<String, ResourceDefinitionCreate> resourceDefinitions = rdh.getResourceDefinitions();\r\n \r\n // update RELS-EXT\r\n // FIXME store operation names in ContentModel and remove and add\r\n // services in one pass or just remove if really gone\r\n \r\n // delete service entries which are in Fedora but not send\r\n final Map<String, List<StartElementWithChildElements>> deleteFromRelsExt =\r\n new HashMap<String, List<StartElementWithChildElements>>();\r\n final List<StartElementWithChildElements> deleteElementList = new ArrayList<StartElementWithChildElements>();\r\n \r\n for (final ResourceDefinitionCreate resourceDefinition : getContentModel().getResourceDefinitions().values()) {\r\n if (!resourceDefinitions.containsKey(resourceDefinition.getName())) {\r\n final StartElementWithChildElements element =\r\n new StartElementWithChildElements(\"hasService\", Constants.FEDORA_MODEL_NS_URI, null, null, null,\r\n null);\r\n element.addAttribute(new Attribute(\"resource\", Constants.RDF_NAMESPACE_URI, null, resourceDefinition\r\n .getFedoraId(getContentModel().getId())));\r\n deleteElementList.add(element);\r\n }\r\n }\r\n deleteFromRelsExt.put(\"/RDF/Description/hasService\", deleteElementList);\r\n final byte[] tmpRelsExt = Utility.updateRelsExt(null, deleteFromRelsExt, null, getContentModel(), null);\r\n \r\n // add services to RELS-EXT\r\n final List<StartElementWithChildElements> addToRelsExt = new ArrayList<StartElementWithChildElements>();\r\n for (final ResourceDefinitionCreate resourceDefinition : resourceDefinitions.values()) {\r\n // FIXME do update existing resource definitions\r\n if (!getContentModel().getResourceDefinitions().containsKey(resourceDefinition.getName())) {\r\n final StartElementWithChildElements hasServiceElement = new StartElementWithChildElements();\r\n hasServiceElement.setLocalName(\"hasService\");\r\n hasServiceElement.setPrefix(Constants.FEDORA_MODEL_NS_PREFIX);\r\n hasServiceElement.setNamespace(Constants.FEDORA_MODEL_NS_URI);\r\n final Attribute resource =\r\n new Attribute(\"resource\", Constants.RDF_NAMESPACE_URI, Constants.RDF_NAMESPACE_PREFIX,\r\n Constants.IDENTIFIER_PREFIX + sdefIdPrefix + resourceDefinition.getName());\r\n hasServiceElement.addAttribute(resource);\r\n addToRelsExt.add(hasServiceElement);\r\n }\r\n }\r\n \r\n // TODO remove services from RELS-EXT\r\n // (<hasService\r\n // rdf:resource=\"info:fedora/sdef:escidoc_9003-trans\"\r\n // xmlns=\"info:fedora/fedora-system:def/model#\"/>)\r\n getContentModel().setRelsExt(Utility.updateRelsExt(addToRelsExt, null, tmpRelsExt, getContentModel(), null));\r\n \r\n // Metadata Record Definitions\r\n final List<MdRecordDefinitionCreate> mdRecordDefinitions = mrdh.getMdRecordDefinitions();\r\n // update DS-COMPOSITE\r\n final Map<String, Object> valueMap = new HashMap<String, Object>();\r\n valueMap.put(\"MD_RECORDS\", mdRecordDefinitions);\r\n final String dsCompositeModelContent =\r\n ContentModelFoXmlProvider.getInstance().getContentModelDsComposite(valueMap);\r\n getContentModel().setDsCompositeModel(dsCompositeModelContent);\r\n // TODO create, delete, update *_XSD datastreams\r\n for (final MdRecordDefinitionCreate mdRecordDefinition : mdRecordDefinitions) {\r\n final String name = mdRecordDefinition.getName();\r\n final String xsdUrl = mdRecordDefinition.getSchemaHref();\r\n getContentModel().setOtherStream(\r\n name + \"_xsd\",\r\n new Datastream(name + \"_xsd\", getContentModel().getId(), xsdUrl,\r\n de.escidoc.core.common.business.fedora.Constants.STORAGE_EXTERNAL_MANAGED, MimeTypes.TEXT_XML));\r\n }\r\n \r\n // Resource Definitions\r\n // services are already added to RELS-EXT\r\n // TODO delete sdef+sdep\r\n // create service definitions and deployments or update xslt\r\n \r\n for (final ResourceDefinitionCreate resourceDefinition : resourceDefinitions.values()) {\r\n final String sdefId = sdefIdPrefix + resourceDefinition.getName();\r\n if (this.tripleStoreUtility.exists(sdefId)) {\r\n // check if href for xslt is changed\r\n // /cmm/content-model/escidoc:40013/resource-\\\r\n // definitions/resource-definition/trans/xslt\r\n if (resourceDefinition.getXsltHref().equalsIgnoreCase(\r\n \"/cmm/content-model/\" + getContentModel().getId() + \"/resource-definitions/resource-definition/\"\r\n + resourceDefinition.getName() + \"/xslt/content\")) {\r\n if (LOGGER.isDebugEnabled()) {\r\n LOGGER.debug(\"Do not update xslt.\");\r\n }\r\n }\r\n else {\r\n final ModifiyDatastreamPathParam path = new ModifiyDatastreamPathParam(sdefId, \"xslt\");\r\n final ModifyDatastreamQueryParam query = new ModifyDatastreamQueryParam();\r\n query.setDsLabel(\"Transformation instructions for operation '\" + resourceDefinition.getName()\r\n + \"'.\");\r\n query.setMimeType(MimeTypes.TEXT_XML);\r\n query.setDsLocation(resourceDefinition.getXsltHref());\r\n this.fedoraServiceClient.modifyDatastream(path, query, null);\r\n }\r\n }\r\n else {\r\n // create\r\n final String sdefFoxml = getSDefFoXML(resourceDefinition);\r\n final IngestPathParam path = new IngestPathParam();\r\n final IngestQueryParam query = new IngestQueryParam();\r\n this.fedoraServiceClient.ingest(path, query, sdefFoxml);\r\n final String sdepFoxml = getSDepFoXML(resourceDefinition);\r\n this.fedoraServiceClient.ingest(path, query, sdepFoxml);\r\n }\r\n }\r\n \r\n // Content Streams\r\n final List<ContentStreamCreate> contentStreams = csh.getContentStreams();\r\n setContentStreams(contentStreams);\r\n \r\n /*\r\n * \r\n */\r\n \r\n // check if modified\r\n final String updatedXmlData;\r\n final DateTime endTimestamp = getContentModel().getLastFedoraModificationDate();\r\n if (!startTimestamp.isEqual(endTimestamp) || getContentModel().isNewVersion()) {\r\n // object is modified\r\n getUtility().makeVersion(\"ContentModelHandler.update()\", null, getContentModel());\r\n getContentModel().persist();\r\n \r\n updatedXmlData = retrieve(getContentModel().getId());\r\n fireContentModelModified(getContentModel().getId(), updatedXmlData);\r\n }\r\n else {\r\n updatedXmlData = render();\r\n }\r\n \r\n return updatedXmlData;\r\n }", "@Override\n @GET\n @Path(\"/{id}\")\n public Author get (@PathParam(\"id\") int id) {\n EntityManager em = PersistenceUtil.getEntityManagerFactory().createEntityManager();\n AuthorDao authorDao = new AuthorDao(em);\n Author a = authorDao.get(Author.class, id);\n a.getWorks().size();//it's needed to initialize session\n em.close();\n return a;\n }", "@Override\r\n public Loader<Cursor> onCreateLoader(int id, Bundle bundle) {\n String[] projections = {RecipeEntry._ID,\r\n RecipeEntry.COLUMN_RECIPE_NAME,\r\n RecipeEntry.COLUMN_RECIPE_TYPE,\r\n RecipeEntry.COLUMN_RECIPE_SERVINGS,\r\n RecipeEntry.COLUMN_RECIPE_VALUES,\r\n };\r\n\r\n //this code will execute the content provided\r\n return new CursorLoader(this, currentRecipeUri, projections, null, null, null);\r\n }", "@SuppressWarnings(\"unchecked\")\n private Revisions<Integer, T> getEntitiesForRevisions(Collection<Integer> revisionNumbers, ID id, AuditReader reader) {\n\n Class<T> type = entityInformation.getJavaType();\n Class<T> revisionEntityClass = (Class<T>) revisionEntityInformation.getRevisionEntityClass();\n Map<Number, T> revisionEntities = reader.findRevisions(revisionEntityClass, new HashSet<>(revisionNumbers));\n\n Map<Integer, T> revisions = revisionNumbers.stream()\n .collect(\n Collectors.toMap(\n number -> number,\n number -> reader.find(type, id, number),\n (a, b) -> b,\n () -> new HashMap<>(revisionNumbers.size())\n )\n );\n\n return Revisions.of(this.toRevisions(revisions, revisionEntities));\n }", "@Test\r\n public void testRevisionParser() {\r\n JsonParser parser = new JsonParser();\r\n InputStream inputstream = getClass().getClassLoader().getResourceAsStream(\"sample.json\");\r\n assert inputstream != null;\r\n Reader reader = new InputStreamReader(inputstream);\r\n JsonElement rootElement = parser.parse(reader);\r\n JsonObject rootObject = rootElement.getAsJsonObject();\r\n JsonObject pages = rootObject.getAsJsonObject(\"query\").getAsJsonObject(\"pages\");\r\n JsonArray array = null;\r\n for (Map.Entry<String, JsonElement> entry : pages.entrySet()) {\r\n JsonObject entryObject = entry.getValue().getAsJsonObject();\r\n array = entryObject.getAsJsonArray(\"revisions\");\r\n Assert.assertNotNull(array);\r\n }\r\n System.out.println(array);\r\n\r\n }", "public VersionDownload() {\n }", "public VersionedOntology(SwoopModel swoopModel, VersionControl controlHandler, URI repURI, Description[] verDesc) {\r\n\r\n\t\tinit(swoopModel, controlHandler);\r\n\t\t\r\n\t\tthis.repositoryURI = repURI;\r\n\t\tthis.versionDescriptions = verDesc;\r\n\t\t// parse version Description array\r\n\t\ttry {\r\n\t\t\t// first parse header\r\n\t\t\tDescription header = versionDescriptions[0];\r\n\r\n\t\t\t// parse header description to get author, date, baseOntologyURI\r\n\t\t\tthis.repositoryAuthor = header.getAuthor();\r\n\t\t\tthis.reposityCreatedDate = header.getCreated();\r\n\t\t\tthis.baseOntologyURI = new URI(header.getAnnotatedEntityDefinition());\r\n\t\t\t// and headVersionNumber\r\n\t\t\tthis.headVersionNumber = Integer.parseInt(header.getBody());\r\n\t\t\t\r\n\t\t\t// also get actual URL location of annotation\r\n\t\t\tthis.repHeaderLoc = header.getLocation();\r\n\t\t\t\r\n\t\t\t// set UI accordingly\r\n\t\t\tthis.repURLFld.setText(this.repositoryURI.toString());\r\n\t\t\tthis.repAuthorFld.setText(this.repositoryAuthor);\r\n\t\t\tthis.repDateFld.setText(this.reposityCreatedDate);\r\n\t\t\tthis.repBaseOntFld.setText(this.baseOntologyURI.toString());\r\n\t\t\tthis.toggleRepOptions(false);\r\n\t\t\r\n\t\t\t// now for each version, parse and add node to repRoot\r\n\t\t\tfor (int ctr=1; ctr<=this.headVersionNumber; ctr++) {\r\n\t\t\t\tDescription version = versionDescriptions[ctr];\r\n\t\t\t\tTreeTableNode mainNode = this.parseSingleCommit(version);\r\n\t\t\t\t// set params on mainNode\r\n\t\t\t\tmainNode.swoopChange.isOnRepository = true;\r\n\t\t\t\tmainNode.location = version.getLocation();\r\n\t\t\t\tversionNodes[ctr] = mainNode;\r\n\t\t\t}\r\n\t\t\t// again set UI accordingly\r\n\t\t\tthis.refreshRepTreeTable(true);\r\n\t\t\t\r\n\t\t}\r\n\t\tcatch (Exception ex) {\r\n\t\t\tex.printStackTrace();\r\n\t\t}\r\n\t}", "public interface ContentUpgradeDao extends EntityObjectDao{\r\n\t/**\r\n\t * 新建时检测是否名字重复\r\n\t * @param name\r\n\t * @return\r\n\t */\r\n\tboolean obtainNameExists(String name);\r\n\t\r\n\t/**\r\n\t * 更新时检测是否有重复\r\n\t * @param name\r\n\t * @param uuid\r\n\t * @return\r\n\t */\r\n\tboolean obtainNameExists(String name, String uuid);\r\n\r\n\t/**\r\n\t * 获取指定关键词和分页信息的内容升级列表\r\n\t * @param keyword 查找的关键词\r\n\t * @param startPosition 起始位置\r\n\t * @param size 获取大小\r\n\t * @return\r\n\t */\r\n\tList<ContentUpgrade> loadContentUpgrades(String keyword, int startPosition, int size);\r\n\t\r\n\t/**\r\n\t * 获取指定关键词的数量\r\n\t * @param keyword 指定关键词\r\n\t * @return\r\n\t */\r\n\tint loadAmount(String keyword);\r\n\t\r\n\t\r\n\tList<ContentUpgrade> loadAllContentUpgrades();\r\n}", "public long getRevision() {\n\n return revision;\n }", "public GitFileSite(GitCommit aGC) { _cmt = aGC; setURL(createURL()); }", "@Override\r\n public String create(final String xmlData) throws InvalidContentException, MissingAttributeValueException,\r\n SystemException, XmlCorruptedException {\r\n \r\n final ContentModelCreate contentModel = parseContentModel(xmlData);\r\n \r\n // check that the objid was not obtained from the representation\r\n contentModel.setObjid(null);\r\n \r\n contentModel.setIdProvider(getIdProvider());\r\n validate(contentModel);\r\n contentModel.persist(true);\r\n final String objid = contentModel.getObjid();\r\n final String resultContentModel;\r\n try {\r\n resultContentModel = retrieve(objid);\r\n }\r\n catch (final ResourceNotFoundException e) {\r\n final String msg =\r\n \"The Content Model with id '\" + objid + \"', which was just created, \"\r\n + \"could not be found for retrieve.\";\r\n throw new IntegritySystemException(msg, e);\r\n }\r\n fireContentModelCreated(objid, resultContentModel);\r\n return resultContentModel;\r\n }", "public static String createFeedVersion (Request req, Response res) throws IOException, ServletException {\n\n Auth0UserProfile userProfile = req.attribute(\"user\");\n FeedSource feedSource = requestFeedSourceById(req, \"manage\");\n FeedVersion latestVersion = feedSource.retrieveLatest();\n FeedVersion newFeedVersion = new FeedVersion(feedSource);\n newFeedVersion.retrievalMethod = FeedSource.FeedRetrievalMethod.MANUALLY_UPLOADED;\n\n\n // FIXME: Make the creation of new GTFS files generic to handle other feed creation methods, including fetching\n // by URL and loading from the editor.\n File newGtfsFile = new File(DataManager.getConfigPropertyAsText(\"application.data.gtfs\"), newFeedVersion.id);\n try {\n // Bypass Spark's request wrapper which always caches the request body in memory that may be a very large\n // GTFS file. Also, the body of the request is the GTFS file instead of using multipart form data because\n // multipart form handling code also caches the request body.\n ServletInputStream inputStream = ((ServletRequestWrapper) req.raw()).getRequest().getInputStream();\n FileOutputStream fileOutputStream = new FileOutputStream(newGtfsFile);\n // Guava's ByteStreams.copy uses a 4k buffer (no need to wrap output stream), but does not close streams.\n ByteStreams.copy(inputStream, fileOutputStream);\n fileOutputStream.close();\n inputStream.close();\n // Set last modified based on value of query param. This is determined/supplied by the client\n // request because this data gets lost in the uploadStream otherwise.\n Long lastModified = req.queryParams(\"lastModified\") != null ? Long.valueOf(req.queryParams(\"lastModified\")) : null;\n if (lastModified != null) newGtfsFile.setLastModified(lastModified);\n LOG.info(\"Last modified: {}\", new Date(newGtfsFile.lastModified()));\n LOG.info(\"Saving feed from upload {}\", feedSource);\n } catch (Exception e) {\n LOG.error(\"Unable to open input stream from uploaded file\", e);\n haltWithError(400, \"Unable to read uploaded feed\");\n }\n\n // TODO: fix FeedVersion.hash() call when called in this context. Nothing gets hashed because the file has not been saved yet.\n // newFeedVersion.hash();\n newFeedVersion.hash = HashUtils.hashFile(newGtfsFile);\n\n // Check that the hashes of the feeds don't match, i.e. that the feed has changed since the last version.\n // (as long as there is a latest version, i.e. the feed source is not completely new)\n if (latestVersion != null && latestVersion.hash.equals(newFeedVersion.hash)) {\n // Uploaded feed matches latest. Delete GTFS file because it is a duplicate.\n LOG.error(\"Upload version {} matches latest version {}.\", newFeedVersion.id, latestVersion.id);\n newGtfsFile.delete();\n LOG.warn(\"File deleted\");\n\n // There is no need to delete the newFeedVersion because it has not yet been persisted to MongoDB.\n haltWithError(304, \"Uploaded feed is identical to the latest version known to the database.\");\n }\n\n newFeedVersion.setName(newFeedVersion.formattedTimestamp() + \" Upload\");\n // TODO newFeedVersion.fileTimestamp still exists\n\n // Must be handled by executor because it takes a long time.\n ProcessSingleFeedJob processSingleFeedJob = new ProcessSingleFeedJob(newFeedVersion, userProfile.getUser_id());\n DataManager.heavyExecutor.execute(processSingleFeedJob);\n\n return processSingleFeedJob.jobId;\n }", "public Observable<RevisionResponse> fetchQuestionsAndSubmitRevision(final RevisionResponsePost revisionResponsePost) {\n\n return Observable.create(new ObservableOnSubscribe<RevisionResponse>() {\n @Override\n public void subscribe(ObservableEmitter<RevisionResponse> e) throws Exception {\n\n Call<RevisionResponse> call = mNetworkModel.fetchQuestionsAndSubmitRevision(revisionResponsePost);\n Response<RevisionResponse> response = call.execute();\n\n if (response != null && response.isSuccessful()) {\n RevisionResponse body = response.body();\n Log.e(\"QAndSRevision1--\", \"Successful\");\n e.onNext(body);\n } else if (response.code() == 404) {\n throw new Exception(mContext.getString(R.string.messageQuestionFetchFailed));\n } else if ((response.code() == 401) && SyncServiceHelper.refreshToken(mContext)) {\n Response<RevisionResponse> response2 = call.clone().execute();\n if (response2 != null && response2.isSuccessful()) {\n RevisionResponse body = response2.body();\n Log.e(\"QAndSRevision2--\", \"Successful\");\n e.onNext(body);\n } else if ((response2.code() == 401)) {\n mContext.startActivity(LoginActivity.getUnauthorizedIntent(mContext));\n } else if (response2.code() == 404) {\n throw new Exception(mContext.getString(R.string.messageQuestionFetchFailed));\n } else {\n Log.e(\"QAndSRevision2--\", \"Failed\");\n throw new Exception(mContext.getString(R.string.messageQuestionFetchFailed));\n }\n } else {\n Log.e(\"QAndSRevision1--\", \"Failed\");\n throw new Exception(mContext.getString(R.string.messageQuestionFetchFailed));\n }\n\n e.onComplete();\n }\n });\n }", "private void createRecipeFromFile() {\n Intent intent = new Intent(Intent.ACTION_OPEN_DOCUMENT);\n\n // Filter to only show results that can be \"opened\", such as a\n // file (as opposed to a list of contacts or timezones)\n intent.addCategory(Intent.CATEGORY_OPENABLE);\n\n // Filter to show only images, using the image MIME data type.\n // If one wanted to search for ogg vorbis files, the type would be \"audio/ogg\".\n // To search for all documents available via installed storage providers,\n // it would be \"*/*\".\n intent.setType(\"*/*\");\n\n startActivityForResult(intent, READ_REQUEST_CODE);\n }", "public interface ContentsService {\n\n /**\n * Add the given data as a new media contents entry.\n *\n * @param name of the contents file to add\n * @param payload byte array to add\n */\n void addMediaContent(String name, byte[] payload);\n\n\n /**\n * Fetch the media content data for the given identifier.\n *\n * @param id predicate, used to resolve the media content to fetch\n *\n * @return the media object found, never {@code null}\n */\n Map<String, Object> getMediaContent(String id);\n}", "public Repository (Application application, Activity activity){\n VideoDatabase database=VideoDatabase.getInstance(application);\n myDAO=database.myDAO();\n allChapters=myDAO.getAllChapter();\n allLecture=myDAO.getAllLecture();\n this.activity=activity;\n //allChapterJson=myDAO.getAllChapterJson();\n //allLectureJson=myDAO.getAllLectureJson();\n }", "public \n OfflineExtFactory\n (\n String workUser, \n TreeMap<String,TreeSet<VersionID>> versions\n ) \n {\n super(workUser, versions); \n }", "PagingLoadResult<GWTJahiaContentHistoryEntry> getContentHistory(String nodeIdentifier, int offset, int limit) throws GWTJahiaServiceException;" ]
[ "0.65259135", "0.58321375", "0.57523465", "0.57022417", "0.5643828", "0.55171496", "0.5512838", "0.5494943", "0.54823184", "0.54367954", "0.5424831", "0.53870416", "0.53791755", "0.5340878", "0.53267694", "0.52901286", "0.5242121", "0.5211951", "0.5204682", "0.5184567", "0.51714414", "0.51656127", "0.5163495", "0.5154153", "0.5138747", "0.5135154", "0.51192063", "0.50994354", "0.50956047", "0.5080952", "0.50723237", "0.5067524", "0.504977", "0.5047877", "0.5037333", "0.50289965", "0.5019698", "0.50142604", "0.50037974", "0.4992856", "0.49782604", "0.49674696", "0.4965002", "0.49573252", "0.49467587", "0.49403083", "0.4933948", "0.49283484", "0.49072942", "0.49066892", "0.49045298", "0.4898997", "0.48831037", "0.48827437", "0.48809564", "0.48660392", "0.48549113", "0.4849403", "0.48466298", "0.48424745", "0.484047", "0.4830216", "0.48162192", "0.48108298", "0.48076025", "0.48072913", "0.47991556", "0.4781509", "0.4779696", "0.47794038", "0.47786933", "0.4776388", "0.47718728", "0.47568572", "0.47426632", "0.47327247", "0.47257993", "0.47154424", "0.471029", "0.47050816", "0.47039056", "0.4695739", "0.46950975", "0.46836925", "0.4672985", "0.46641994", "0.4658677", "0.4657636", "0.4650434", "0.46503434", "0.46501505", "0.46499217", "0.4648956", "0.46440595", "0.46355358", "0.46334985", "0.4631441", "0.46299836", "0.46218026", "0.46189362" ]
0.7029575
0
Load version history for all files in project and all subprojects
private void loadHistory(VssProject vssProject) { if (!incrementalWarning) checkDirHistory(vssProject); for (Iterator i = vssProject.getFiles().iterator(); i.hasNext();) { VssFile file = (VssFile) i.next(); loadHistory(file); } for (Iterator i = vssProject.getSubprojects().iterator(); i.hasNext();) { VssProject project = (VssProject) i.next(); loadHistory(project); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "List<ChangedFile> getChangedFiles(Project project);", "void findHistory(File f,IvyXmlWriter xw)\n{\n StringCommand cmd = new StringCommand(cvs_command + \" log \" + getRelativePath(f));\n String rslt = cmd.getContent();\n\n StringTokenizer tok = new StringTokenizer(rslt,\"\\n\");\n String rev = null;\n Date d = null;\n String auth = null;\n String msg = null;\n BvcrFileVersion prior = null;\n Collection<BvcrFileVersion> fvs = new ArrayList<BvcrFileVersion>();\n String headversion = null;\n\n while (tok.hasMoreTokens()) {\n String ln = tok.nextToken();\n if (rev == null) {\n\t if (ln.startsWith(\"revision \")) rev = ln.substring(9).trim();\n\t else if (ln.startsWith(\"head: \")) {\n\t headversion = ln.substring(6);\n\t }\n }\n else {\n\t if (ln.startsWith(\"date: \")) {\n\t StringTokenizer ltok = new StringTokenizer(ln,\";\");\n\t while (ltok.hasMoreTokens()) {\n\t String itm = ltok.nextToken();\n\t int idx = itm.indexOf(\":\");\n\t if (idx >= 0) {\n\t\t String what = itm.substring(0,idx).trim();\n\t\t String cnts = itm.substring(idx+1).trim();\n\t\t if (what.equals(\"date\")) {\n\t\t try {\n\t\t\td = CVS_DATE.parse(cnts);\n\t\t }\n\t\t catch (ParseException e) { }\n\t\t }\n\t\t else if (what.equals(\"author\")) auth = cnts;\n\t\t}\n\t }\n\t }\n\t else if (ln.startsWith(\"----------------------------\") ||\n\t\t ln.startsWith(\"===================================================\")) {\n\t if (auth != null && d != null) {\n\t BvcrFileVersion fv = new BvcrFileVersion(f,rev,d,auth,msg);\n\t if (headversion != null && headversion.equals(rev)) {\n\t\t fv.addAlternativeName(\"HEAD\");\n\t\t}\n\t if (prior != null) prior.addPriorVersion(fv);\n\t prior = fv;\n\t fvs.add(fv);\n\t }\n\t rev = null;\n\t d = null;\n\t msg = null;\n\t auth = null;\n\t }\n\t else if (msg == null) msg = ln;\n\t else msg = msg + \"\\n\" + ln;\n }\n }\n\n xw.begin(\"HISTORY\");\n xw.field(\"FILE\",f.getPath());\n for (BvcrFileVersion fv : fvs) {\n fv.outputXml(xw);\n }\n xw.end(\"HISTORY\");\n}", "private void loadHistory(VssFile vssFile) {\r\n \tif(config.useComApi)\r\n {\r\n \t\tgetVss().getComApiFileHistory(vssFile);\r\n }\r\n \telse\r\n \t{\r\n File historyFile = getVss().getFileHistory(vssFile);\r\n VssHistoryParser p = new VssHistoryParser(config);\r\n p.parseFileHistory(historyFile, vssFile);\r\n \t}\r\n }", "private void checkDirHistory(VssProject project) {\r\n try {\r\n File dirHistory = getVss().getDirHistory(project);\r\n BufferedReader r = Util.openReader(dirHistory, config.getLogEncoding());\r\n try {\r\n String s;\r\n while ((s = r.readLine()) != null) {\r\n if (s.endsWith(\" recovered\")\r\n || s.endsWith(\" destroyed\")\r\n || s.endsWith(\" branched\")\r\n || s.endsWith(\" shared\")\r\n || s.indexOf(\" renamed to \") != -1\r\n ) {\r\n incrementalWarning = true;\r\n break;\r\n }\r\n }\r\n } finally {\r\n r.close();\r\n }\r\n } catch (IOException e) {\r\n throw new VssException(e);\r\n }\r\n }", "Collection<ComponentState> getVersions();", "protected void resolveProjectDependencies() {\n // Create a set of old and new artifacts.\n final Set<String> oldReferences = new HashSet<String>();\n final Set<String> newReferences = new HashSet<String>();\n for (PropertyInfo pi:properties.values()) {\n if (pi != null) {\n if (pi.getPropertyDescriptor().getPropertyParser() == DefaultPropertyParsers.PATH_PARSER) {\n // Get original artifacts\n final List oldList = (List)pi.getOldValue();\n if ( oldList != null ) {\n final Iterator it = oldList.iterator();\n while (it.hasNext()) oldReferences.add(((VisualClassPathItem)it.next()).getRawText());\n }\n \n // Get artifacts after the edit\n final List newList = (List)pi.getValue();\n if ( newList != null ) {\n final Iterator it = newList.iterator();\n while (it.hasNext()) newReferences.add(((VisualClassPathItem)it.next()).getRawText());\n }\n } else if (pi.getPropertyDescriptor().getPropertyParser() == DefaultPropertyParsers.FILE_REFERENCE_PARSER) {\n oldReferences.add(pi.getOldRawValue());\n newReferences.add(pi.getRawValue());\n }\n }\n }\n \n // Create set of removed artifacts and remove them\n final Set<String> removed = new HashSet<String>( oldReferences );\n removed.removeAll( newReferences );\n final Set<String> added = new HashSet<String>(newReferences);\n added.removeAll(oldReferences);\n \n // 1. first remove all project references. The method will modify\n // project property files, so it must be done separately\n for ( String reference : removed ) {\n if (reference != null && !reference.startsWith(LIBS)) { //NOI18N\n refHelper.destroyReference(reference);\n }\n }\n \n // 2. now read project.properties and modify rest\n final EditableProperties ep = antProjectHelper.getProperties(AntProjectHelper.PROJECT_PROPERTIES_PATH);\n boolean changed = false;\n \n for( final String reference:removed) {\n if (reference != null && reference.startsWith(LIBS)) { //NOI18N\n // remove helper property pointing to library jar if there is any\n ep.remove(reference.substring(2, reference.length()-1));\n changed = true;\n }\n }\n final File projDir = FileUtil.toFile(antProjectHelper.getProjectDirectory());\n for( String reference:added ) {\n if (reference != null && reference.startsWith(LIBS)) { //NOI18N\n // add property to project.properties pointing to relativized\n // library jar(s) if possible\n reference = reference.substring(2, reference.length()-1);\n final String value = relativizeLibraryClasspath(reference, projDir);\n if (value != null) {\n ep.setProperty(reference, value);\n ep.setComment(reference, new String[]{\n NbBundle.getMessage(J2MEProjectProperties.class, \"DESC_J2MEProps_CommentLine1\", reference), //NOI18N\n NbBundle.getMessage(J2MEProjectProperties.class, \"DESC_J2MEProps_CommentLine2\")}, false); //NOI18N\n changed = true;\n }\n }\n }\n if (changed) {\n antProjectHelper.putProperties(AntProjectHelper.PROJECT_PROPERTIES_PATH, ep);\n }\n \n }", "public Map<String,List<RevisionFile>> getSourceFiles();", "public void testViewHistory() throws Exception {\n System.out.print(\".. Testing history information of a file ..\");\n String filesystem = \"VSS \" + workingDirectory + File.separator + \"Work\";\n Node filesystemNode = new Node(new ExplorerOperator().repositoryTab().getRootNode(), filesystem);\n Node A_FileNode = new Node( filesystemNode, \"A_File [Current]\");\n new Action(VERSIONING_MENU + \"|\" + HISTORY, HISTORY).perform(A_FileNode);\n MainWindowOperator.getDefault().waitStatusText(\"Command History finished.\");\n VCSCommandsOutputOperator outputWindow = new VCSCommandsOutputOperator(\"History\");\n outputWindow.btClose();\n Thread.sleep(5000);\n String currentContents = outputWindow.txtStandardOutput().getText();\n outputWindow.close();\n String goldenContents = \"History of $/A_File.java ...\\n\\n***************** Version 2 *****************\\nUser: \" + userName + \" Date:\";\n if (currentContents.indexOf(goldenContents) < 0) captureScreen(\"Error: Incorrect history contents. Golden: |\" + goldenContents + \"|\" + currentContents + \"|\");\n goldenContents = \"Checked in $/\\nComment: Three lines have changed.\\n\\n***************** Version 1 *****************\\nUser: \" + userName + \" Date\";\n if (currentContents.indexOf(goldenContents) < 0) captureScreen(\"Error: Incorrect history contents. Golden: |\" + goldenContents + \"|\" + currentContents + \"|\");\n goldenContents = \"Created\\nComment: Generated A_File class.\\n\";\n if (currentContents.indexOf(goldenContents) < 0) captureScreen(\"Error: Incorrect history contents. Golden: |\" + goldenContents + \"|\" + currentContents + \"|\");\n new Action(VERSIONING_MENU + \"|\" + PROPERTIES, PROPERTIES).perform(A_FileNode);\n MainWindowOperator.getDefault().waitStatusText(\"Command Properties finished.\");\n outputWindow = new VCSCommandsOutputOperator(\"Properties\");\n outputWindow.btClose();\n Thread.sleep(5000);\n currentContents = outputWindow.txtStandardOutput().getText();\n outputWindow.close();\n goldenContents = \"File: $/A_File.java\\nType: Text\\nSize: 91 bytes 5 lines\\nStore only latest version: No\\nLatest: \\n Version: 2 \\n Date:\";\n if (currentContents.indexOf(goldenContents) < 0) captureScreen(\"Error: Incorrect properties contents. Golden: |\" + goldenContents + \"|\" + currentContents + \"|\");\n goldenContents = \"Comment: Generated A_File class.\";\n if (currentContents.indexOf(goldenContents) < 0) captureScreen(\"Error: Incorrect properties contents. Golden: |\" + goldenContents + \"|\" + currentContents + \"|\");\n System.out.println(\". done !\");\n }", "Collection<String> getVersions();", "List<Project> getProjectsWithChanges(List<Project> projects);", "private static List<UserData> getLastCommittedPageVersions() throws IOException {\n File transactionDir = new File(\"logdata\");\n\n File[] files = transactionDir.listFiles();\n\n if (files == null) {\n System.out.println(\"error reading logdata files\");\n System.exit(1);\n }\n\n //all committed transaction ids\n List<Integer> committedTransactionIds = new ArrayList<>();\n\n //first collect committed transaction ids\n for (File file : files) {\n int LSN = Integer.parseInt(file.getName());\n\n //read the first line of the page file\n BufferedReader reader = new BufferedReader(new FileReader(file));\n String[] contentParts = reader.readLine().split(\",\");\n\n //only collect committed transaction ids\n if (Objects.equals(contentParts[1], \"commit\")) {\n committedTransactionIds.add(Integer.parseInt(contentParts[0]));\n }\n }\n\n HashMap<Integer, UserData> map = new HashMap<>();\n //now collect the last page contents for each page\n for (File file : files) {\n int LSN = Integer.parseInt(file.getName());\n\n //read the first line of the page file\n BufferedReader reader = new BufferedReader(new FileReader(file));\n String[] contentParts = reader.readLine().split(\",\");\n\n //ignore commits\n if (!Objects.equals(contentParts[1], \"commit\")) {\n int transactionId = Integer.parseInt(contentParts[0]);\n int pageId = Integer.parseInt(contentParts[1]);\n\n //only consider committed transactions\n if (committedTransactionIds.contains(transactionId)) {\n\n if (map.containsKey(pageId)) {\n //check if current file has newer version\n if (map.get(pageId).getLSN() < LSN) {\n map.put(pageId, new UserData(pageId, contentParts[2], LSN));\n }\n } else {\n map.put(pageId, new UserData(pageId, contentParts[2], LSN));\n }\n }\n }\n }\n return new ArrayList<>(map.values());\n }", "public BuildHistory(){\n buildHistory = new ArrayList<Build>();\n }", "private void importAll() {\n\t\tfinal JFileChooser chooser = new JFileChooser(System.getProperty(\"user.home\"));\n\t\tint returnVal = chooser.showOpenDialog(null);\n\t\tif(returnVal == JFileChooser.APPROVE_OPTION) {\n\t\t\tFile file = chooser.getSelectedFile();\n\t\t\tdeserializeFile(file);\n\t\t\t // imported the projects for this application from a file, so update what should be persisted on close\n\t\t\tupdatePersistence();\n\t\t}\n\t}", "List<HistoryData> loadAllHistoryData();", "@Test\r\n public void testRevision() {\r\n InputStream inputstream = getClass().getClassLoader().getResourceAsStream(\"sample.json\");\r\n assert inputstream != null;\r\n Reader reader = new InputStreamReader(inputstream);\r\n JsonParser parser = new JsonParser();\r\n JsonElement rootElement = parser.parse(reader);\r\n\r\n RevisionParser revisionParser = new RevisionParser();\r\n List<Revision> revisionList = revisionParser.parse(rootElement);\r\n\r\n for (Revision r: revisionList) {\r\n System.out.println(r);\r\n }\r\n Assert.assertEquals(revisionList.get(0).toString(), \"Name: Monkbot\tTimeStamp: Fri Sep 13 11:10:41 EDT 2019\");\r\n }", "public void showVersionHistory(ArrayList<Version> versions)\n\t{\n\t\tfor(int i=0; i<versions.size(); i++)\n\t\t{\n\t\t\tshowVersionHistory(versions.get(i));\n\t\t}\n\t}", "protected abstract void declareVersions();", "public void globalLog() {\n\t\tIterator iter = myCommit.entrySet().iterator();\n\t\twhile (iter.hasNext()) {\n\t\t\tMap.Entry entry = (Map.Entry) iter.next();\n\t\t\tVersion currVersion = (Version) entry.getValue();\n\t\t\tcurrVersion.log();\n\t\t}\n\t}", "private void loadProjects() {\n\t\tprojectsList.clear();\n\t\t\n\t\tArrayList<Job> projects = jdbc.getProjects();\n\t\tfor (Job j : projects) {\n\t\t\tprojectsList.addElement(j.jobname);\n\t\t}\n\t}", "default void loadRevisionFileDataIntoMemory(AsyncCache<Integer, RevisionFileData> cache) {\n if (!cache.asMap().isEmpty()) {\n return;\n }\n\n final UberPage uberPage;\n if (exists()) {\n final Reader reader = createReader();\n final PageReference firstRef = reader.readUberPageReference();\n uberPage = (UberPage) firstRef.getPage();\n\n final var revisionNumber = uberPage.getRevisionNumber();\n final var revisionNumbers = new ArrayList<Integer>(revisionNumber);\n\n for (int i = 1; i <= revisionNumber; i++) {\n revisionNumbers.add(i);\n }\n\n cache.getAll(revisionNumbers, keys -> {\n final Map<Integer, RevisionFileData> result = new HashMap<>();\n keys.forEach(key -> result.put(key, reader.getRevisionFileData(key)));\n reader.close();\n return result;\n });\n }\n }", "public List<ModuleDependency> getModuleDependencyForDiffWithPaging(BuildParams buildParams, String offset, String limit) {\n ResultSet rs = null;\n ResultSet rsDep = null;\n ResultSet rsDepCompared = null;\n List<ModuleDependency> dependencies = new ArrayList<>();\n Map<String, ModuleDependency> moduleDependencyMap = new HashMap<>();\n try {\n StringBuilder builder = new StringBuilder(getBaseDependencyQuery(buildParams));\n Object[] diffParams = getBuildDependencyParams(buildParams);\n /// update query with specific conditions\n updateQueryWithSpecificConditions(buildParams, builder);\n String buildQuery = builder.toString();\n rs = jdbcHelper.executeSelect(buildQuery, diffParams);\n Map<String, String> tempDependencyMap = new HashMap<>();\n StringBuilder inClauseBuilder = new StringBuilder();\n inClauseBuilder.append(\"(\");\n while (rs.next()) {\n String sha1 = rs.getString(3);\n if (tempDependencyMap.get(sha1) == null) {\n tempDependencyMap.put(sha1, sha1);\n ModuleDependency dependency = new ModuleDependency(null, null, rs.getString(1),\n rs.getString(2), rs.getString(4), sha1);\n dependency.setStatus(rs.getString(5));\n if (buildParams.isAllArtifact()) {\n dependency.setModule(rs.getString(6));\n }\n dependencies.add(dependency);\n }\n inClauseBuilder.append(\"'\" + sha1 + \"'\").append(\",\");\n }\n String inClause = inClauseBuilder.toString();\n inClause = inClause.substring(0, inClause.length() - 1);\n inClause = inClause + \")\";\n // update dependencies repo path data\n if (!dependencies.isEmpty()) {\n rsDep = getModuleDependencyNodes(moduleDependencyMap, inClause);\n if (buildParams.isAllArtifact()) {\n rsDepCompared = getModuleDependencyNodes(moduleDependencyMap, inClause);\n }\n dependencies.forEach(dependency -> {\n ModuleDependency moduleDependency = moduleDependencyMap.get(dependency.getSha1());\n if (moduleDependency != null) {\n dependency.setRepoKey(moduleDependency.getRepoKey());\n String path = moduleDependency.getPath();\n String name = moduleDependency.getName();\n if (path != null) {\n dependency.setPath(path.equals(\".\") ? name : path + \"/\" + name);\n }\n }\n });\n }\n } catch (SQLException e) {\n log.error(e.toString());\n } finally {\n DbUtils.close(rsDep);\n DbUtils.close(rsDepCompared);\n DbUtils.close(rs);\n }\n return dependencies;\n }", "public void log() {\n\t\tVersion currVersion = myHead;\n\t\twhile (currVersion.getParent() != null) {\n\t\t\tcurrVersion.log();\n\t\t\tcurrVersion = currVersion.getParent();\n\t\t}\n\t\tmyCommit.get(0).log();\n\t}", "List<ChangedFile> addUntrackedFilesToIndex(Map<Project, List<ChangedFile>> files);", "void replaceWithHEADRevision(Collection<ChangedFile> changedFiles);", "public void init() {\n- newProject = new Project();\n- newProject.setDefaultInputStream(getProject().getDefaultInputStream());\n+ newProject = getProject().createSubProject();\n newProject.setJavaVersionProperty();\n }", "public static void status() {\n Set branchSet = commitPointers.readBranches().keySet();\n ArrayList<String> sortedBranches = (ArrayList) branchSet.stream().sorted().collect(Collectors.toList());\n String currBranch = commitPointers.readHeadCommit()[0];\n System.out.println(\"=== Branches ===\");\n for (String branch: sortedBranches) {\n if (currBranch.equals(branch)) {\n System.out.println(\"*\" + currBranch);\n } else {\n System.out.println(branch);\n }\n }\n stagingArea = Utils.readObject(STAGING_FILE, HashMap.class);\n\n ArrayList<String> sortedStaged = (ArrayList) stagingArea.keySet().stream().sorted().collect(Collectors.toList());\n System.out.println();\n System.out.println(\"=== Staged Files ===\");\n for (String staged : sortedStaged) {\n System.out.println(staged);\n }\n\n System.out.println();\n System.out.println(\"=== Removed Files ===\");\n stagingRemoveArea = Utils.readObject(STAGING_REMOVE_FILE, HashMap.class);\n ArrayList<String> sortedRemoved = (ArrayList) stagingRemoveArea.keySet().stream().sorted().collect(Collectors.toList());\n for (String removed : sortedRemoved) {\n System.out.println(removed);\n }\n System.out.println();\n\n System.out.println(\"=== Modifications Not Staged For Commit ===\");\n\n Commit Head = Utils.readObject(Utils.join(Commit.COMMIT_FOLDER, commitPointers.readHeadCommit()[1] + \".txt\"), Commit.class);\n //File blobs contains a SHAID + file name\n\n HashMap<String, String> modUntracked = new HashMap<>();\n\n //iterates through head Blobs\n for (HashMap.Entry<String, String> headfileBlob : Head.fileBlobs.entrySet()) {\n\n File cwdBFile = Utils.join(CWD, headfileBlob.getKey());\n\n if (!cwdBFile.exists() && !stagingRemoveArea.containsKey(headfileBlob.getKey())) {\n modUntracked.put(headfileBlob.getKey(), \"(deleted)\");\n }\n else if (cwdBFile.exists()){\n\n Blob tempBlob = new Blob(headfileBlob.getKey(), cwdBFile);\n String tempBlobId = Utils.sha1(Utils.serialize(tempBlob));\n\n\n if(!tempBlobId.equals(headfileBlob.getValue())) {\n //if not in staging area\n if (!stagingArea.containsKey(headfileBlob.getKey())) {\n modUntracked.put(headfileBlob.getKey(), \"(modified)\");\n }\n //TODO: IS THIS PART NECCESARY?\n else if (stagingArea.containsKey(headfileBlob.getKey()) && !stagingArea.get(headfileBlob.getKey()).equals(headfileBlob.getValue())) {\n modUntracked.put(headfileBlob.getKey(), \"(modified)\");\n }\n }\n }\n }\n\n ArrayList<String> sortedModNames = (ArrayList) modUntracked.keySet().stream().sorted().collect(Collectors.toList());\n for (String modFileName : sortedModNames){\n System.out.println(modFileName + \" \" + modUntracked.get(modFileName));\n }\n System.out.println();\n\n\n\n ArrayList<String> untracked = new ArrayList<>();\n System.out.println(\"=== Untracked Files ===\");\n for (String cwdfile : CWD.list()) {\n if(!cwdfile.equals(\".gitlet\")) {\n File currfile = Utils.join(CWD, cwdfile);\n if (currfile.exists() && !Head.fileBlobs.containsKey(cwdfile)) {\n untracked.add(cwdfile);\n }\n }\n }\n\n untracked = (ArrayList) untracked.stream().sorted().collect(Collectors.toList());\n\n for (String untrackedName : untracked){\n System.out.println(untrackedName);\n }\n }", "private void expungeAllHistoricFiles()\r\n {\r\n debug(\"expungeAllHistoricFiles() - Delete ALL HISTORIC Files\");\r\n\r\n java.io.File fileList = new java.io.File(\"./\");\r\n String rootName = getString(\"WatchListTableModule.edit.historic_details_basic_name\");\r\n String[] list = fileList.list(new MyFilter(rootName));\r\n for (int i = 0; i < list.length; i++)\r\n {\r\n StockMarketUtils.expungeListsFile(list[i]);\r\n }\r\n debug(\"expungeAllHistoricFiles() - Delete ALL HISTORIC Files - complete\");\r\n\r\n }", "public HistoryGraph() {\n revisions = new HashSet<Revision>();\n orderedRevisions = new ArrayList<Revision>();\n }", "@Transactional(value = Transactional.TxType.MANDATORY)\n public RubricHistory getHistory(Long projectId) {\n RubricHistoryLinker linker = rubricHistoryLinkerRepository.findById(projectId).orElse(null);\n return getRubricHistoryFromLinker(linker);\n }", "@Test\n public void testCreateDependencyTree3() {\n Map<String, Integer> expected = new HashMap<>() {{\n put(\"github.com/test/subproject:0.0.0-00010101000000-000000000000\", 1);\n }};\n try {\n Path projectDir = GO_ROOT.resolve(\"project3\");\n GoTreeBuilder treeBuilder = new GoTreeBuilder(null, projectDir, projectDir.resolve(\"go.mod\").toString(), null, log);\n DepTree dt = treeBuilder.buildTree();\n validateDependencyTreeResults(expected, dt);\n } catch (IOException ex) {\n fail(ExceptionUtils.getStackTrace(ex));\n }\n }", "Collection<String> createVersion(Workspace workspace, Collection<String> paths) throws RepositoryException;", "@Test\r\n public void testGetChangedFileList() throws IOException {\n helper.exportRevChangedFiles(PJ_ROOT, 1, LOCAL_ROOT);\r\n helper.exportRevChangedFiles(PJ_ROOT, 4, LOCAL_ROOT);\r\n //helper.exportRevChangedFiles(PJ_ROOT, -1, LOCAL_ROOT);\r\n //helper.exportRevChangedFiles(9, 9, true);\r\n }", "private String getPreviousRevision(final Project project) {\n List<Measure> measures = getPreviousMeasures(project, CoreMetrics.SCM_REVISION, CoreMetrics.SCM_LAST_COMMIT_DATE);\n if (measures.size()==2) {\n for (Measure measure : measures) {\n if (measure.getMetric().equals(CoreMetrics.SCM_REVISION)) {\n return measure.getData();\n }\n }\n }\n return null;\n }", "@Override\n\tpublic void readAGBVersionsWithLineNumbers() {\n\t\t\n\t\tString lineVersion1 = null;\n\t\tString lineVersion2 = null;\n\t\t\n\t\ttry \n\t\t{\n BufferedReader br1 = new BufferedReader(new FileReader(\"AGB1-SelectedVersion.txt\"));\n \n while ((lineVersion1 = br1.readLine()) != null) \n {\n \tversion1WithLineNumbers.add(lineVersion1);\n //System.out.println(line);\n }\n } \n\t\tcatch (IOException e) \n\t\t{\n e.printStackTrace();\n }\n\t\t\n\t\ttry \n\t\t{\n BufferedReader br2 = new BufferedReader(new FileReader(\"AGB2-SelectedVersion.txt\"));\n \n while ((lineVersion2 = br2.readLine()) != null) \n {\n \tversion2WithLineNumbers.add(lineVersion2);\n //System.out.println(line);\n }\n } \n\t\tcatch (IOException e) \n\t\t{\n e.printStackTrace();\n }\n\t\t\n\t\t\n\t}", "private void collectDependencies() throws Exception {\n backupModAnsSumFiles();\n CommandResults goGraphResult = goDriver.modGraph(true);\n String cachePath = getCachePath();\n String[] dependenciesGraph = goGraphResult.getRes().split(\"\\\\r?\\\\n\");\n for (String entry : dependenciesGraph) {\n String moduleToAdd = entry.split(\" \")[1];\n addModuleDependencies(moduleToAdd, cachePath);\n }\n restoreModAnsSumFiles();\n }", "private static ArrayList<String> fetchHistory() {\n\t\tScanner s;\n\t\tint count = 0;\n\t\tArrayList<String> historyList = new ArrayList<String>();\n\t\ttry {\n\t\t\ts = new Scanner(new File(\"History.txt\"));\n\t\t\twhile (s.hasNext()) {\n\t\t\t\thistoryList.add(s.next());\n\t\t\t\tcount += 1;\n\t\t\t}\n\t\t\tSystem.out.println(\"Number of converted urls fetched: \" + count);\n\t\t\ts.close();\n\t\t} catch (FileNotFoundException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn historyList;\n\t}", "public void resolveRevisionStates() {\r\n\t\tboolean first = true;\r\n\t\tfor (Iterator i = getRevisions().iterator(); i.hasNext();) {\r\n\t\t\tPvcsRevision revision = (PvcsRevision) i.next();\r\n\t\t\tif (first) {\r\n\t\t\t\trevision.setState(PvcsRevisionState.ADD);\r\n\t\t\t\tfirst = false;\r\n\t\t\t} else {\r\n\t\t\t\trevision.setState(PvcsRevisionState.CHANGE);\r\n\t\t\t}\r\n\t\t}\r\n\t}", "private static void addToHistory() {\n\t\tFileInputStream fis = null;\n\t\tFileOutputStream fos = null;\n\t\tFileChannel resultChannel = null;\n\t\tFileChannel historyChannel = null;\n\t\ttry {\n\t\t\tfis = new FileInputStream(new File(\"result.txt\"));\n\t\t\tfos = new FileOutputStream(new File(\"history.txt\"), true);\n\t\t\t\n\t\t\tfos.write(\"\\n\\n\".getBytes(\"utf-8\"));\n\t\t\tfos.flush();\n\t\t\t\n\t\t\tresultChannel = fis.getChannel();\n\t\t\thistoryChannel = fos.getChannel();\n\n\t\t\tresultChannel.transferTo(0, resultChannel.size(), historyChannel);\n\t\t} catch (FileNotFoundException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t} catch (IOException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t} finally {\n\t\t\ttry {\n\t\t\t\tif (fis != null) {\n\t\t\t\t\tfis.close();\n\t\t\t\t}\n\t\t\t\tif (fos != null) {\n\t\t\t\t\tfos.close();\n\t\t\t\t}\n\t\t\t\tif(resultChannel != null) {\n\t\t\t\t\tresultChannel.close();\n\t\t\t\t}\n\t\t\t\tif(historyChannel != null) {\n\t\t\t\t\thistoryChannel.close();\n\t\t\t\t}\n\t\t\t} catch (IOException e) {\n\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t}", "public BuildHistory(ArrayList<Build> buildHistory) {\n this.buildHistory = buildHistory;\n }", "void reloadInternal()\r\n {\r\n final ArrayList<Workspace> newWorkspaces = new ArrayList<Workspace>();\r\n\r\n final File[] files = FileUtil.getFiles(new File(FileUtil.getGenericPath(WORKSPACE_PATH)), new FileFilter()\r\n {\r\n @Override\r\n public boolean accept(File file)\r\n {\r\n // only accept xml file\r\n return FileUtil.getFileExtension(file.getPath(), true).toLowerCase().equals(EXT);\r\n }\r\n }, true, false, false);\r\n\r\n for (File file : files)\r\n {\r\n final Workspace workspace = new Workspace(file);\r\n\r\n // don't load the specific system workspace\r\n if (!workspace.getName().equals(Workspace.WORKSPACE_SYSTEM_NAME))\r\n {\r\n // empty workspace ?\r\n if (workspace.isEmpty())\r\n {\r\n // don't show this message for default workspace\r\n // if (!workspace.getName().equals(Workspace.WORKSPACE_DEFAULT_NAME))\r\n System.err.println(\"Empty workspace '\" + workspace.getName() + \"' is not loaded\");\r\n }\r\n else\r\n newWorkspaces.add(workspace);\r\n }\r\n }\r\n\r\n // sort list\r\n Collections.sort(newWorkspaces);\r\n\r\n // set workspace list\r\n workspaces = newWorkspaces;\r\n\r\n // notify change\r\n changed();\r\n }", "public void load() {\r\n\t\t\r\n\t\t//-- Clean\r\n\t\tthis.repositories.clear();\r\n\t\t\r\n\t\tloadInternal();\r\n\t\tloadExternalRepositories();\r\n\t\t\r\n\t}", "public static void init() {\n File dir = new File(\".gitlet\");\n if (dir.exists()) {\n System.out.println(\"a gitlet version-control system already exists in the current directory.\");\n return;\n } else {\n dir.mkdir();\n File next = new File(\".gitlet/heads/master.ser\");\n File currentBranch = new File(\".gitlet/current\");\n File heads = new File(\".gitlet/heads\");\n File currentname = new File(\".gitlet/current/master.ser\");\n File staged = new File(\".gitlet/staged\");\n File commits = new File(\".gitlet/commits\");\n File unstaged = new File(\".gitlet/unstaged\");\n File blobs = new File(\".gitlet/blobs\");\n try {\n heads.mkdir();\n staged.mkdir();\n commits.mkdir();\n unstaged.mkdir();\n currentBranch.mkdir();\n blobs.mkdir();\n Commit initial = new Commit(\"initial commit\", null, null);\n FileOutputStream fileOut = new FileOutputStream(next);\n ObjectOutputStream objectOut = new ObjectOutputStream(fileOut);\n objectOut.writeObject(initial);\n Files.copy(next.toPath(), currentname.toPath());\n } catch (IOException e) {\n return;\n }\n }}", "public SortedSet<ReleaseJira> retriveReleases() throws IOException, ParseException{\n\t\t\n\t\tString url = basicUrl + \"project/\" + this.projectName + \"/version\";\n\t\tTreeSet<ReleaseJira> releases = new TreeSet<>((o1,o2) -> o1.getReleaseDate().compareTo(o2.getReleaseDate()));\n\t\t\n\t\tJSONObject json = JSONTools.readJsonFromUrl(url);\n JSONArray versions = json.getJSONArray(\"values\");\n \n for (Integer i = 0; i < versions.length(); i++ ) {\n JSONObject version = versions.getJSONObject(i);\n \t\n if (version.has(\"releaseDate\") && version.has(\"name\") && version.has(\"id\")) {\n \treleases.add(new ReleaseJira(version.getInt(\"id\"), version.getString(\"name\"), new SimpleDateFormat(\"yyyy-MM-dd\").parse(version.getString(\"releaseDate\"))));\t\n }\n }\n return releases;\n\t}", "@Override\n public List<Number> getRevisionHistory(Long id) {\n return null;\n }", "private void scanProject() {\n ProjectResources resources = ResourceManager.getInstance().getProjectResources(mProject);\n if (resources != null) {\n Collection<ResourceItem> layouts = resources.getResourceItemsOfType(LAYOUT);\n for (ResourceItem layout : layouts) {\n List<ResourceFile> sources = layout.getSourceFileList();\n for (ResourceFile source : sources) {\n updateFileIncludes(source, false);\n }\n }\n\n return;\n }\n }", "long recalculateRevision();", "long getCurrentRevision();", "@Test\n public void testVersions() throws Exception {\n for (String name : new String[]{\n //\"LibreOfficeBase_odb_1.3.odb\",\n \"LibreOfficeCalc_ods_1.3.ods\",\n \"LibreOfficeDraw_odg_1.3.odg\",\n \"LibreOfficeImpress_odp_1.3.odp\",\n \"LibreOfficeWriter_odt_1.3.odt\",\n }) {\n List<Metadata> metadataList = getRecursiveMetadata(\"/versions/\" + name);\n Metadata metadata = metadataList.get(0);\n assertEquals(\"1.3\", metadata.get(OpenDocumentMetaParser.ODF_VERSION_KEY), \"failed on \" + name);\n }\n }", "private static GetRevisionHistoryOptions getRevisionHistoryOptions() {\n\tGetRevisionHistoryOptions options = new GetRevisionHistoryOptions();\n\toptions.setIncludeInherited(true);\n\toptions.setLongOutput(true);\n\toptions.setMaxRevs(1000);\n\toptions.setOmitNonContributaryIntegrations(true);\n\treturn options;\n }", "@Override\n\tpublic List<String> getVersionDifferences() {\n\t\t\n\t\t\n\t\treturn versionDifferences;\n\t}", "public static final void logModuleBuildVersion() {\n try {\n InputStream is = RadiusServiceStarter.class.getResourceAsStream(\"/META-INF/openam-radius-version.txt\");\n if (is != null) {\n int bytesRead = 0;\n\n byte[] bytes = new byte[256];\n try {\n bytesRead = is.read(bytes);\n cLog.log(Level.INFO, \"Loaded \" + new String(bytes, 0, bytesRead));\n } catch (IOException e) {\n cLog.log(Level.WARNING, \"----> Unable to load openam-auth-smsotp module's version information.\", e);\n }\n }\n } catch (Throwable t) {\n cLog.log(Level.SEVERE, \"----> Unable to load openam-auth-smsotp module's version information.\", t);\n }\n }", "public void initAllHistory() {\n\t\t// firstly tell the view clear its history content.\n\t\tview.clearHistoryTableContent();\n\n\t\tArrayList<Integer> scores = selectedLesson.getTestResultScores();\n\t\tArrayList<String> times = selectedLesson.getTestResultTimes();\n\n\t\tint count = times.size();\n\t\tfor (int i = 0; i < count; ++i) {\n\t\t\tview.addHistory(times.get(i), scores.get(i));\n\t\t}\n\t}", "void submoduleSync() throws GitException, InterruptedException;", "List<ChangedFile> resetChangedFiles(Map<Project, List<ChangedFile>> files);", "@Test\r\n public void testRevisionParser() {\r\n JsonParser parser = new JsonParser();\r\n InputStream inputstream = getClass().getClassLoader().getResourceAsStream(\"sample.json\");\r\n assert inputstream != null;\r\n Reader reader = new InputStreamReader(inputstream);\r\n JsonElement rootElement = parser.parse(reader);\r\n JsonObject rootObject = rootElement.getAsJsonObject();\r\n JsonObject pages = rootObject.getAsJsonObject(\"query\").getAsJsonObject(\"pages\");\r\n JsonArray array = null;\r\n for (Map.Entry<String, JsonElement> entry : pages.entrySet()) {\r\n JsonObject entryObject = entry.getValue().getAsJsonObject();\r\n array = entryObject.getAsJsonArray(\"revisions\");\r\n Assert.assertNotNull(array);\r\n }\r\n System.out.println(array);\r\n\r\n }", "public List<JiraVersion> getProjectVersions(String token, String projectKey) throws JiraManagerException {\r\n Util.logEnter(log, \"getProjectVersions\", token, projectKey);\r\n Util.checkString(log, \"token\", token);\r\n Util.checkString(log, \"projectKey\", projectKey);\r\n\r\n try {\r\n List<JiraVersion> result = getJiraManagementServicePort().getProjectVersions(token, projectKey);\r\n Util.logExit(log, \"getProjectVersions\", result);\r\n return result;\r\n } catch (JiraServiceException e) {\r\n throw processError(e);\r\n }\r\n }", "public void updateHashedVersions() {\n for (IndexEntry indexEntry : ClientUtils.getIndexEntries(indexWave)) {\n ClientWaveView wave = backend.getWave(indexEntry.getWaveId());\n if ((wave != null) && (ClientUtils.getConversationRoot(wave) != null)) {\n lastSeenVersions.put(wave, wave.getWaveletVersion(ClientUtils.getConversationRootId(wave)));\n }\n }\n }", "@Test\n public void testCreateDependencyTree4() {\n Map<String, Integer> expected = new HashMap<>() {{\n put(\"github.com/test/subproject:0.0.0-00010101000000-000000000000\", 1);\n }};\n try {\n Path projectDir = GO_ROOT.resolve(\"project4\");\n GoTreeBuilder treeBuilder = new GoTreeBuilder(null, projectDir, projectDir.resolve(\"go.mod\").toString(), null, log);\n DepTree dt = treeBuilder.buildTree();\n validateDependencyTreeResults(expected, dt);\n } catch (IOException ex) {\n fail(ExceptionUtils.getStackTrace(ex));\n }\n }", "public List getModifications(Date lastBuild, Date now) {\n //(PENDING) extract buildHistoryCommand, execHistoryCommand\n // See CVSElement\n \n \t\t//call vss, write output to intermediate file\n String[] cmdArray = {\"ss.exe\", \"history\", ssdir, \"-R\", \"-Vd\" +\n formatDateForVSS(now) + \"~\" + formatDateForVSS(lastBuild),\n \"-Y\" + login, \"-I-N\", \"-O\" + VSS_TEMP_FILE};\n \t\ttry {\n \t\t\tProcess p = Runtime.getRuntime().exec(cmdArray);\n \t\t\tp.waitFor();\n \n \t\t\tBufferedReader reader = new BufferedReader(new FileReader(\n new File(VSS_TEMP_FILE)));\n \n \t\t\tString currLine = reader.readLine();\n \t\t\twhile (currLine != null) {\n \t\t\t\tif (currLine.startsWith(\"***** \")) {\n \t\t\t\t\tArrayList vssEntry = new ArrayList();\n \t\t\t\t\tvssEntry.add(currLine);\n \t\t\t\t\tcurrLine = reader.readLine();\n \t\t\t\t\twhile (currLine != null && !currLine.startsWith(\"***** \")) {\n \t\t\t\t\t\tvssEntry.add(currLine);\n \t\t\t\t\t\tcurrLine = reader.readLine();\n \t\t\t\t\t}\n Modification mod = handleEntry(vssEntry);\n if(mod != null)\n modifications.add(mod);\n \t\t\t\t} else {\n \t\t\t\t\tcurrLine = reader.readLine();\n \t\t\t\t}\n \t\t\t}\n \n \t\t\treader.close();\n \t\t\tnew File(VSS_TEMP_FILE).delete();\n \t\t} catch (Exception e) {\n \t\t\te.printStackTrace();\n \t\t}\n \n \t\tif (_property != null && modifications.size() > 0) {\n _properties.put(_property, \"true\");\n \t\t}\n \n \t\treturn modifications;\n \t}", "void projectsFound( String key ) {\n developer.projects = new ArrayList<>();\n }", "@Test(dataProvider = \"doFetchInSeparateProcess\", dataProviderClass = FetchOptionsDataProvider.class)\n public void testConcurrentCollectBuildChanges(boolean fetchInSeparateProcess) throws Exception {\n System.setProperty(\"teamcity.git.fetch.separate.process\", String.valueOf(fetchInSeparateProcess));\n \n final GitVcsSupport support = getSupport();\n final List<Exception> errors = Collections.synchronizedList(new ArrayList<Exception>());\n \n Runnable r1 = new Runnable() {\n public void run() {\n try {\n // ensure that all revisions reachable from master are fetched\n final VcsRoot root = getRoot(\"master\");\n final List<ModificationData> ms = support.collectChanges(root, VERSION_TEST_HEAD, CUD1_VERSION, new CheckoutRules(\"\"));\n assertEquals(2, ms.size());\n ModificationData m2 = ms.get(1);\n assertEquals(\"The second commit\\n\", m2.getDescription());\n assertEquals(3, m2.getChanges().size());\n for (VcsChange ch : m2.getChanges()) {\n assertEquals(VcsChange.Type.ADDED, ch.getType());\n assertEquals(\"dir/\", ch.getFileName().substring(0, 4));\n }\n ModificationData m1 = ms.get(0);\n assertEquals(\"more changes\\n\", m1.getDescription());\n assertEquals(CUD1_VERSION, m1.getVersion());\n assertEquals(3, m1.getChanges().size());\n VcsChange ch10 = m1.getChanges().get(0);\n assertEquals(\"dir/a.txt\", ch10.getFileName());\n assertEquals(CUD1_VERSION, ch10.getAfterChangeRevisionNumber());\n assertEquals(m2.getVersion(), ch10.getBeforeChangeRevisionNumber());\n assertEquals(VcsChange.Type.CHANGED, ch10.getType());\n VcsChange ch11 = m1.getChanges().get(1);\n assertEquals(\"dir/c.txt\", ch11.getFileName());\n assertEquals(VcsChange.Type.ADDED, ch11.getType());\n VcsChange ch12 = m1.getChanges().get(2);\n assertEquals(\"dir/tr.txt\", ch12.getFileName());\n assertEquals(VcsChange.Type.REMOVED, ch12.getType());\n } catch (Exception e) {\n errors.add(e);\n }\n }\n };\n \n Runnable r2 = new Runnable() {\n public void run() {\n try {\n // now check merge commit relatively to the branch\n final VcsRoot root = getRoot(\"master\");\n final List<ModificationData> mms0 = support.collectChanges(root, MERGE_BRANCH_VERSION, MERGE_VERSION, new CheckoutRules(\"\"));\n assertEquals(2, mms0.size());\n } catch (Exception e) {\n errors.add(e);\n }\n }\n };\n \n Runnable r3 = new Runnable() {\n public void run() {\n try {\n // no check the merge commit relatively to the fork\n final VcsRoot root = getRoot(\"master\");\n final List<ModificationData> mms1 = support.collectChanges(root, CUD1_VERSION, MERGE_VERSION, new CheckoutRules(\"\"));\n assertEquals(3, mms1.size());\n ModificationData md1 = mms1.get(0);\n assertFalse(md1.isCanBeIgnored());\n assertEquals(\"merge commit\\n\", md1.getDescription());\n assertEquals(MERGE_VERSION, md1.getVersion());\n assertEquals(3, md1.getChanges().size());\n VcsChange ch20 = md1.getChanges().get(0);\n assertEquals(\"dir/a.txt\", ch20.getFileName());\n assertEquals(VcsChange.Type.REMOVED, ch20.getType());\n VcsChange ch21 = md1.getChanges().get(1);\n assertEquals(\"dir/b.txt\", ch21.getFileName());\n assertEquals(VcsChange.Type.CHANGED, ch21.getType());\n VcsChange ch22 = md1.getChanges().get(2);\n assertEquals(\"dir/q.txt\", ch22.getFileName());\n assertEquals(VcsChange.Type.ADDED, ch22.getType());\n ModificationData md2 = mms1.get(1);\n assertTrue(md2.isCanBeIgnored());\n assertEquals(\"b-mod, d-add\\n\", md2.getDescription());\n assertEquals(MERGE_BRANCH_VERSION, md2.getVersion());\n assertEquals(2, md2.getChanges().size());\n ModificationData md3 = mms1.get(2);\n assertEquals(\"a-mod, c-rm\\n\", md3.getDescription());\n assertEquals(2, md3.getChanges().size());\n } catch (Exception e) {\n errors.add(e);\n }\n }\n };\n \n Runnable r4 = new Runnable() {\n public void run() {\n try {\n // check the case with broken commit\n final VcsRoot root = getRoot(\"master\");\n String missing = GitUtils.makeVersion(GitUtils.versionRevision(CUD1_VERSION).replace('0', 'f'), GitUtils.versionTime(CUD1_VERSION));\n final List<ModificationData> mms2 = support.collectChanges(root, missing, MERGE_VERSION, new CheckoutRules(\"\"));\n assertEquals(4, mms2.size());\n ModificationData mb3 = mms2.get(3);\n assertEquals(GitServerUtil.SYSTEM_USER, mb3.getUserName());\n assertEquals(0, mb3.getChanges().size());\n } catch (Exception e) {\n errors.add(e);\n }\n }\n };\n \n for (int i = 0; i < 50; i++) {\n BaseTestCase.runAsync(4, r1, r2, r3, r4);\n }\n \n if (!errors.isEmpty()) {\n throw errors.get(0);\n }\n }", "public FileHistory getFileHistory() {\n\t\treturn theFileHistory;\n\t}", "protected void refreshFromProject() {\r\n\t\r\n\t\tif (fTreeViewer != null) {\r\n\t\t\tfTreeViewer.setInput(null);\r\n\t\t}\t\t\r\n\t\t\r\n\t\tif (fProjectObjects == null ) {\r\n\t\t\tResource resource = modelObject.eResource();\r\n\t\t\tIFile file = BPELUtil.getFileFromURI(resource.getURI());\t\t\t\t\t\r\n\t\t\tfProjectObjects = resourceContentProvider.getElements( file.getProject() );\t\t\t\r\n\t\t}\r\n\t\t\r\n\t\tif (fFilteredList != null) {\r\n\t\t\t\r\n\t\t\tfFilteredList.setEnabled(true);\r\n\t\t\tfFilteredList.setAllowDuplicates(showDuplicates);\r\n\t\t\tfFilteredList.setElements( contentProvider.getElements( fProjectObjects ) );\r\n\t\t\t\r\n\t\t\tif (contentProvider.getElements( fProjectObjects ) != null && contentProvider.getElements( fProjectObjects ).length > 0) {\r\n\t\t\t\tupdateLowerViewWidget(fFilteredList.getSelection());\r\n\t\t\t}\t\t\r\n\t\t}\t\t\r\n\t}", "private static void readHistoryData()\n throws FileNotFoundException {\n File file = new File(HISTORY_FILE_PATH);\n Scanner scanner = new Scanner(file); // create a Scanner using the File as the source\n StringBuilder message = new StringBuilder();\n int index = 1;\n while (scanner.hasNext()) {\n String line = scanner.nextLine();\n message.append(\"\\n\\t\" + index + \". \" + line);\n index++;\n }\n scanner.close();\n\n history = message.toString();\n }", "static void processSVNFiles(final ThreadContext context, final Repository repository, final Configuration config, final String path, final long previousRevision, long latestRevision) throws SVNException\r\n {\r\n /*\r\n * Gets the contents of the directory specified by path at the latest\r\n * revision (for this purpose -1 is used here as the revision number to\r\n * mean HEAD-revision) getDir returns a Collection of SVNDirEntry\r\n * elements. SVNDirEntry represents information about the directory\r\n * entry. Here this information is used to get the entry name, the name\r\n * of the person who last changed this entry, the number of the revision\r\n * when it was last changed and the entry type to determine whether it's\r\n * a directory or a file. If it's a directory listEntries steps into a\r\n * next recursion to display the contents of this directory. The third\r\n * parameter of getDir is null and means that a user is not interested\r\n * in directory properties. The fourth one is null, too - the user\r\n * doesn't provide its own Collection instance and uses the one returned\r\n * by getDir.\r\n */\r\n\r\n SVNRepository svnRepository = context.getSVNRepository();\r\n final RendererMap renderers = config.getRenderers();\r\n\r\n //noinspection unchecked\r\n List<SVNDirEntry> entries = new ArrayList<>(svnRepository.getDir(path, -1, null, (Collection) null));\r\n Collections.sort(entries);\r\n List<String> directories = new ArrayList<>(entries.size());\r\n\r\n for (final SVNDirEntry entry : entries)\r\n {\r\n if (entry.getKind() == SVNNodeKind.FILE)\r\n {\r\n String name = entry.getName();\r\n int index = name.lastIndexOf('.');\r\n\r\n final String extension = index != -1 ? name.substring(index).toLowerCase() : \"\"; // No extension case\r\n final String filePath = createFilePath(path, name);\r\n\r\n if (!renderers.containsKey(extension) || !config.isAllowedFile(filePath))\r\n {\r\n addFile(_skippedFileCounts, extension);\r\n continue;\r\n }\r\n else\r\n {\r\n addFile(_checkedFileCounts, extension);\r\n }\r\n\r\n LicenseRenderer renderer = renderers.get(extension);\r\n\r\n try\r\n {\r\n svnRepository.log(new String[]{filePath}, previousRevision, latestRevision, false, false, 1, svnLogEntry -> {\r\n File file = new File(repository.getSourceDir(), filePath);\r\n Extractor extractor = config.getExtractor(context);\r\n Date createDate = extractor.getYear1(filePath, svnLogEntry);\r\n String year2 = context.getYear(extractor.getYear2(filePath, entry));\r\n String author = extractor.getAuthor(filePath, svnLogEntry);\r\n\r\n readRepoFile(file, filePath, renderer, createDate, year2, author, context, repository);\r\n });\r\n }\r\n catch(Exception e)\r\n {\r\n e.printStackTrace();\r\n }\r\n }\r\n else if (entry.getKind() == SVNNodeKind.DIR)\r\n {\r\n String filePath = createFilePath(path, entry.getName());\r\n\r\n if (config.isAllowedDirectory(filePath))\r\n directories.add(filePath);\r\n }\r\n }\r\n\r\n for (String directory : directories)\r\n exec.execute(new SVNLicenseRunnable(repository, config, directory, previousRevision, latestRevision));\r\n }", "private void findCvsRoot()\n{\n File f = new File(for_project.getSourceDirectory());\n for ( ; ; ) {\n File fp = f.getParentFile();\n File fp1 = new File(fp,\"CVS\");\n if (!fp1.exists()) break;\n f = fp;\n }\n cvs_root = f;\n}", "public void extractAndSaveMetricsFromAllFilesInProjectRevisions(SoftwareProject project, OceanoUser oceanoUser, List<MetricManager> metricsToExtract) throws ServiceException {\r\n loadMetrics(metricsToExtract);\r\n\r\n Output.println(\"Pegando usuário... \");\r\n ProjectUser projectUser = projectUserService.getByProjectAndOceanoUser(project, oceanoUser);\r\n Output.println(\"Login: <\" + projectUser.getLogin() + \">\");\r\n\r\n String revisionsPath = null;\r\n try {\r\n Output.println(\"Pegando revisões de : \" + project.getRepositoryUrl());\r\n Set<Revision> revisions = vCSService.getRevisions(project, projectUser);\r\n\r\n Output.println(\"Processando \" + revisions.size() + \" revisões\");\r\n\r\n if (revisions.size() < getRevisionThreshold()) {\r\n Output.println(\"<<< This Project has less than \" + getRevisionThreshold() + \" revisions. Will be Skipped. >>>\");\r\n return;\r\n }\r\n\r\n int count = 0;\r\n String lastRevisionPath = \"\";\r\n Boolean firstRevision = true;\r\n for (Revision revision : revisions) {\r\n count++;\r\n Output.clearLog();\r\n Output.println(\"Revision \" + revision.getNumber());\r\n Output.println(\"Comitted files: \" + (revision.getChangedFiles() != null ? revision.getChangedFiles().size() : 0));\r\n\r\n Output.println(\"WARNING: stopping at 20 revisions\");\r\n if(count==20)break;\r\n \r\n //Dont save revisions without alterations at source files\r\n if (!RevisionUtil.get().hasSourceFileInChangedFiles(revision)) {\r\n Output.println(\" Revision has no changed source files\");\r\n continue;\r\n }\r\n\r\n processRevision(revision);\r\n\r\n if (hasMeasuredMetrics(revision)) {\r\n Output.println(\" Metrics extracted. Skipping to next revision.\");\r\n continue;\r\n }\r\n\r\n try {\r\n Output.println(DateUtil.format(Calendar.getInstance()) + \" [\" + count + \"/\" + revisions.size() + \"]>>Checking revision \" + revision + \"... \");\r\n\r\n Output.println(\"Identifying metrics to extract...\");\r\n\r\n final Set<MetricManager> fontMetricsToExtract = new HashSet<MetricManager>();\r\n final Set<MetricManager> compiledMetricsToExtract = new HashSet<MetricManager>();\r\n prepareMetricsToExtract(revision, fontMetricsToExtract, compiledMetricsToExtract);\r\n\r\n if (compiledMetricsToExtract.isEmpty() && fontMetricsToExtract.isEmpty()) {\r\n Output.println(\" All metrics have been extracted from this revision. Skipping to next revision.\");\r\n continue;\r\n }\r\n\r\n if (!revisionShouldBeMeasured(revision, fontMetricsToExtract, compiledMetricsToExtract)) {\r\n Output.println(\"Skipping to next revision. \");\r\n continue;\r\n }\r\n Output.println(\"\");\r\n\r\n ////////////////////////////////////////////////////////////////\r\n //TODO preparing the workspace should be a method, not this.\r\n boolean tryAgain = false;\r\n boolean failToTryAgain = false;\r\n int timesTrying = 0;\r\n do {\r\n timesTrying++;\r\n\r\n try {\r\n if (firstRevision) {\r\n String path = revision.getProject().getConfigurationItem().getName().replace(\" \", \"_\");\r\n path = PathUtil.getWellFormedPath(ApplicationConstants.DIR_BASE_CHECKOUTS, path);\r\n revision.setLocalPath(path);\r\n PathUtil.mkDirs(path);\r\n vCSService.doCheckout(revision, projectUser, false);\r\n revisionsPath = revision.getLocalPath();\r\n Output.println(\"revisionsPath = \" + revisionsPath);\r\n firstRevision = false;\r\n\r\n } else {\r\n if (isUsingUpdateRevision()) {\r\n revision.setLocalPath(revisionsPath);\r\n vCSService.doUpdate(revision, projectUser, false);\r\n } else {\r\n FileUtils.deleteDirectory(lastRevisionPath);\r\n //TODO path shoulb the same always\r\n //TODO not saving the path for new loop to delete\r\n String path = revision.getProject().getConfigurationItem().getName().replace(\" \", \"_\") + \"-r\" + revision.getNumber();\r\n path = PathUtil.getWellFormedPath(ApplicationConstants.DIR_BASE_CHECKOUTS, path);\r\n revision.setLocalPath(path); \r\n vCSService.doCheckout(revision, projectUser, false);\r\n }\r\n }\r\n } catch (VCSException ex) {\r\n Output.println(\"\");\r\n if (timesTrying < 2) {\r\n Output.println(\" (!) There was a problem getting the code. Lets try again...\");\r\n //clean and try again\r\n if (FileUtils.deleteDirectory(ApplicationConstants.DIR_BASE_CHECKOUTS)) {\r\n //its the first revision again\r\n firstRevision = true;\r\n }\r\n Output.println(\" trying one more time...\");\r\n tryAgain = true;\r\n\r\n } else {\r\n failToTryAgain = true;\r\n Output.println(\" (!) There was a problem getting the code. And the problem happened again in the second time. Skipping to next revision...\");\r\n }\r\n }\r\n } while (isRetryingCheckout() && tryAgain && timesTrying == 1);\r\n if (failToTryAgain) {\r\n continue;\r\n }\r\n //finished preparing workspace\r\n ////////////////////////////////////////////////////////////////\r\n\r\n extractAndSaveMetricsForRevision(revision, fontMetricsToExtract, compiledMetricsToExtract);\r\n\r\n Output.println(\"OK. Metrics extracted sucessfully.\");\r\n\r\n } catch (ServiceException ex) {\r\n Output.println(ex.getMessage());\r\n\r\n if (CONTINUE_TO_NEXT_REVISION_IF_THROWS_EXCEPTION) {\r\n Output.println(\"===========================> Service Exception: \" + ex.getClass() + \" : \" + ex.getMessage());\r\n\r\n boolean cleaned = FileUtils.deleteDirectory(ApplicationConstants.DIR_BASE_CHECKOUTS);\r\n if (cleaned) {\r\n //its the first revision again\r\n firstRevision = true;\r\n }\r\n continue;\r\n } else {\r\n throw new ServiceException(ex);\r\n }\r\n } finally {\r\n logService.log(revision, Output.getLog().toString());\r\n }\r\n lastRevisionPath = revision.getLocalPath();\r\n }\r\n\r\n } catch (Exception ex) {\r\n throw new ServiceException(ex);\r\n }\r\n\r\n if (revisionsPath != null) {\r\n FileUtils.deleteDirectory(revisionsPath);\r\n }\r\n }", "public void load() throws IOException {\r\n\t\tFile file = new File(projectDir, TERN_PROJECT);\r\n\t\tif (file.exists()) {\r\n\t\t\tJSONParser parser = new JSONParser();\r\n\t\t\ttry {\r\n\t\t\t\tJSONObject result = (JSONObject) parser.parse(new FileReader(\r\n\t\t\t\t\t\tfile));\r\n\t\t\t\tsuper.putAll(result);\r\n\t\t\t} catch (ParseException e) {\r\n\t\t\t\te.printStackTrace();\r\n\t\t\t}\r\n\t\t}\r\n\t}", "void syncFrom(final UserProjectCache cache);", "void init() {\n List<Artifact> artifacts = null;\n final List<RepositoryInfo> infos = RepositoryPreferences.getInstance().getRepositoryInfos();\n for (final RepositoryInfo info : infos) {\n if (info.isLocal()) {\n final File localrepo = new File(info.getRepositoryPath() + File.separator\n + DEFAULT_GID_PREFIX.replace('.', '/'));\n if (localrepo.exists()) {\n artifacts = resolveArtifacts(new File(info.getRepositoryPath()), localrepo);\n }\n }\n }\n\n if (artifacts == null) {\n artifacts = new ArrayList<Artifact>(1);\n }\n\n populateLocalTree(artifacts);\n populateAppPane(model.getApps());\n }", "public void storeFileHistory() {\n\t\ttheFileHistory.store(theConfiguration);\n\t}", "public static void main (String []args){\n\t\tString root = \"/home/weslley/ArtigoGroundHog2015/LogProjetos2015\";\n\t\tString rootCompleto = \"/home/weslley/mestrado2014/FinalProjects\";\n\t\t//String listaProjetosSemData = \"/home/weslley/ArtigoGroundHog2015/projectsNames2015.txt\";\n\n\t\t//Para alguns projetos nao datados\n/*\t\tVector<String> listaProjetosNaoDatados = null;\n\t\ttry {\n\t\t\tlistaProjetosNaoDatados = readProjectsNames();\n\t\t} catch (IOException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n*/\n\t\tFile folder = new File(root);\n\t\tFile folderCompleto = new File(rootCompleto);\n\n\t\tint x = 0;\n\t\tFile firstLevel[] = folder.listFiles();\n\t\tFile firstLevelCompleto[] = folderCompleto.listFiles();\n\n\t\tboolean completed = true;\n\n\t\tfor (int i = 0; i < firstLevel.length; i++){\n\n\t\t\t//if(listaProjetosNaoDatados.contains(firstLevel[i].getName())){\n\n\t\t\t\tFile projetoDatado=null;\n\t\t\t\ttry {\n\t\t\t\t\tprojetoDatado = findFile(firstLevelCompleto, firstLevel[i].getName());\n\t\t\t\t} catch (IOException e) {\n\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\n\t\t\t\tif(projetoDatado!=null){\n\n\t\t\t\t\tFile secondLevel[] = firstLevel[i].listFiles();\n\t\t\t\t\t//System.out.println(firstLevel[i].getName());\n\t\t\t\t\tif (secondLevel != null){\n\t\t\t\t\t\tfor(int j = 0; j < secondLevel.length && completed; j++){\n\t\t\t\t\t\t\t//System.out.println(secondLevel[j].getName());\n\t\t\t\t\t\t\tif (secondLevel[j].getName().compareTo(\".DS_Store\") != 0){\n\t\t\t\t\t\t\t\tFile thirdLevel[] = secondLevel[j].listFiles();\n\t\t\t\t\t\t\t\tx++;\n\t\t\t\t\t\t\t\tfor (int k = 0;thirdLevel!=null && k < thirdLevel.length && completed; k++){\n\t\t\t\t\t\t\t\t\tif (thirdLevel[k].getName().compareTo(\".DS_Store\") != 0){\n\t\t\t\t\t\t\t\t\t\tif (!(thirdLevel[k].getName().startsWith(\"[\") && thirdLevel[k].getName().contains(\"]\"))){\n\n\t\t\t\t\t\t\t\t\t\t\t//File secondLevelCompleto[] = projetoDatado.listFiles();\n\t\t\t\t\t\t\t\t\t\t\tFile secondLevelCompletoAuxiliar;\n\t\t\t\t\t\t\t\t\t\t\tFile thirdLevelCompletoAuxiliar;\n\t\t\t\t\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\t\t\t\t\tsecondLevelCompletoAuxiliar = findFile(projetoDatado.listFiles(), secondLevel[j].getName());\n\t\t\t\t\t\t\t\t\t\t\t\tif(secondLevelCompletoAuxiliar!=null){\n\t\t\t\t\t\t\t\t\t\t\t\t\tthirdLevelCompletoAuxiliar = findFile(secondLevelCompletoAuxiliar.listFiles(), thirdLevel[k].getName());\n\n\t\t\t\t\t\t\t\t\t\t\t\t\tif (thirdLevelCompletoAuxiliar!=null && thirdLevelCompletoAuxiliar.getName().startsWith(\"[\") && thirdLevelCompletoAuxiliar.getName().contains(\"]\")){\n\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tif(thirdLevelCompletoAuxiliar!=null && (thirdLevelCompletoAuxiliar.getName().endsWith(thirdLevel[k].getName()) || (compararProjetoSemExtensao(thirdLevelCompletoAuxiliar.getName(),thirdLevel[k].getName() )))){\n\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tFile rename = new File(thirdLevel[k].getParent() + \"/\" + thirdLevelCompletoAuxiliar.getName());\n\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tthirdLevel[k].renameTo(rename);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tString novoNome = thirdLevel[k].getName();\n\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t}catch (IOException e) {\n\t\t\t\t\t\t\t\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\t\t\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}//System.out.println(\"asdasd\" + x);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t//}\n\n\t\t\t}\n\t\t}\n\t}", "public void loadCache() {\n if (!directory.exists()) {\n directory.mkdirs();\n }\n File[] files = this.directory.listFiles();\n if (files == null) {\n return;\n }\n for (File file : files) {\n if (file.getName().endsWith(\".json\")) {\n cache.put(file.getName().split(\".json\")[0], new JsonDocument(file));\n }\n }\n }", "GitFile[] getFilesImpl() throws Exception\n {\n TreeWalk twalk = new TreeWalk(getRepo()); twalk.addTree(_rev);\n List <GitFile> files = new ArrayList();\n while(twalk.next()) {\n ObjectId id = twalk.getObjectId(0);\n RevObject rid = getRevObject(id);\n String path = _path + (_path.length()>1? \"/\" : \"\") + twalk.getNameString();\n GitFile child = rid instanceof RevTree? new GitTree((RevTree)rid, path) : new GitBlob((RevBlob)rid, path);\n files.add(child);\n }\n return files.toArray(new GitFile[files.size()]);\n }", "private void addReferences() throws BuildException {\n Hashtable thisReferences\n = (Hashtable) getProject().getReferences().clone();\n Hashtable newReferences = newProject.getReferences();\n Enumeration e;\n if (references.size() > 0) {\n for (e = references.elements(); e.hasMoreElements();) {\n Reference ref = (Reference) e.nextElement();\n String refid = ref.getRefId();\n if (refid == null) {\n throw new BuildException(\"the refid attribute is required\"\n + \" for reference elements\");\n }\n if (!thisReferences.containsKey(refid)) {\n log(\"Parent project doesn't contain any reference '\"\n + refid + \"'\",\n Project.MSG_WARN);\n continue;\n }\n \n thisReferences.remove(refid);\n String toRefid = ref.getToRefid();\n if (toRefid == null) {\n toRefid = refid;\n }\n copyReference(refid, toRefid);\n }\n }\n \n // Now add all references that are not defined in the\n // subproject, if inheritRefs is true\n if (inheritRefs) {\n for (e = thisReferences.keys(); e.hasMoreElements();) {\n String key = (String) e.nextElement();\n if (newReferences.containsKey(key)) {\n continue;\n }\n copyReference(key, key);\n }\n }\n }", "@Override\n public Path getProjectListFilePath() {\n return projectListStorage.getProjectListFilePath();\n }", "long currentRevision();", "public void store() {\n \n try {\n ProjectManager.mutex().writeAccess(new Mutex.ExceptionAction<Object>() {\n public Object run() {\n \n resolveProjectDependencies();\n \n // Some properties need special handling e.g. if the\n // property changes the project.xml files\n for(final PropertyInfo pi:properties.values()) {\n pi.encode();\n }\n \n final ProjectConfiguration configs[] = configHelper.getConfigurations().toArray(new ProjectConfiguration[0]);\n final HashSet<ProjectConfiguration> newConfigs = new HashSet<ProjectConfiguration>(Arrays.asList(devConfigs));\n for (int i=0; i<configs.length; i++) {\n if (!newConfigs.remove(configs[i])) {\n configHelper.removeConfiguration(configs[i]);\n }\n }\n for (ProjectConfiguration cfg:newConfigs) {\n configHelper.addConfiguration(cfg.getDisplayName());\n }\n \n \n // Reread the properties. It may have changed when\n // e.g. when setting references to another projects\n EditableProperties sharedProps = antProjectHelper.getProperties(AntProjectHelper.PROJECT_PROPERTIES_PATH);\n EditableProperties privateProps = antProjectHelper.getProperties(AntProjectHelper.PRIVATE_PROPERTIES_PATH);\n\n // Set the changed properties\n for( final PropertyInfo pi:properties.values()) {\n final PropertyDescriptor pd = pi.getPropertyDescriptor();\n if (pd != null && pi.isModified()) {\n final String newValueEncoded = pi.getNewValueEncoded();\n if ( newValueEncoded != null ) {\n (pd.isShared() ? sharedProps : privateProps).setProperty( pd.getName(), newValueEncoded );\n } else {\n // remove property\n (pd.isShared() ? sharedProps : privateProps).remove(pd.getName());\n }\n }\n }\n \n // Store the property changes into the project\n antProjectHelper.putProperties(AntProjectHelper.PROJECT_PROPERTIES_PATH, sharedProps);\n antProjectHelper.putProperties(AntProjectHelper.PRIVATE_PROPERTIES_PATH, privateProps);\n \n // Invoke this method to perform cyclic dependencies check and potentionally show warning dilalog\n CustomizerGeneral cg = new CustomizerGeneral();\n cg.initValues(J2MEProjectProperties.this, null);\n cg.getSortedSubprojectsList();\n \n //storing global default encoding by dcurrent project (see issue #97855)\n String enc = sharedProps.getProperty(DefaultPropertiesDescriptor.JAVAC_ENCODING);\n if (enc != null) FileEncodingQuery.setDefaultEncoding(Charset.forName(enc));\n \n // save the project under write lock\n try {\n ProjectManager.getDefault().saveProject(project);\n } catch (IOException ex) {\n ErrorManager.getDefault().notify(ex);\n }\n\n return null;\n }\n });\n } catch (MutexException e) {\n ErrorManager.getDefault().notify(e.getException());\n }\n \n }", "com.clarifai.grpc.api.InstalledModuleVersion getInstalledModuleVersions(int index);", "@Test\n public void testCreateDraftWithParent()\n {\n if (projects.size() > 0)\n {\n Project project = projects.get(0);\n Assert.assertNotNull(project);\n\n Set<Resource> all = resourcesManager.getDraftResources(project\n .getId());\n Assert.assertNotNull(all);\n\n if (all.isEmpty())\n {\n resourcesManager.createResource(project.getId(), -1,\n builder.buildResource(ResourceKind.FOLDER));\n all = resourcesManager.getResources(project.getId());\n }\n\n Resource parent = all.iterator().next();\n Assert.assertNotNull(parent);\n\n if (parent.getKind().equals(ResourceKind.FOLDER))\n {\n Set<Resource> childs = parent.getChilds();\n Assert.assertNotNull(childs);\n\n Resource newResource = builder.buildResource(ResourceKind.FILE);\n Assert.assertNotNull(newResource);\n\n Resource created = resourcesManager.createResource(\n project.getId(), parent.getId(), newResource);\n\n Assert.assertNotNull(created);\n Assert.assertNotNull(created.getId());\n Assert.assertNotNull(created.getUrl());\n\n Set<Resource> allNow = resourcesManager\n .getDraftResources(project.getId());\n\n Assert.assertNotNull(allNow);\n Assert.assertEquals(all.size(), allNow.size());\n\n parent = created.getParent();\n Assert.assertNotNull(parent);\n\n Assert.assertEquals(childs.size() + 1, parent.getChilds()\n .size());\n\n log.info(\"Check subversion url :\" + created.getUrl());\n }\n }\n else\n {\n fail(\"There is not projects.\");\n }\n\n }", "public void loadExternalRepositories() {\n\t\tString envExternalRepsString = System.getenv(\"ODFI_DOCBOOK_STYLESHEETS_REPS\");\r\n\t\tif (envExternalRepsString!=null) {\r\n\t\t\tString[] externalEnvReps = envExternalRepsString.split(\"\"+File.pathSeparatorChar);\r\n\t\t\tfor (String rep : externalEnvReps) {\r\n\t\t\t\ttry {\r\n\t\t\t\t\tthis.loadRepository(rep);\r\n\t\t\t\t} catch (Exception e) {\r\n\t\t\t\t\t// Remove wrong URL\r\n\t\t\t\t\t//it.remove();\r\n\t\t\t\t\te.printStackTrace();\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\t/*\r\n\t\t// Load Preferences with Environment variable if there is one, otherwise don't touch it\r\n\t\t//---------------------\r\n\t\tString envExternalReps = System.getenv(DocbookPlugin.ENV_EXTERNAL_REPS);\r\n\t\tif (envExternalReps!=null) {\r\n\t\t\tDocbookPlugin.getDefault().getPreferenceStore().setDefault(\"reps.external.env\", envExternalReps);\r\n\t\t}\r\n\t\t\r\n\t\t// Do we have any manually added stylesheets repositories?\r\n\t\t//-----------------------\r\n\t\tString externalAddedRepsString = DocbookPlugin.getDefault().getPreferenceStore().getString(\"reps.external.added\");\r\n\t\tString externalEnvRepsString = DocbookPlugin.getDefault().getPreferenceStore().getString(\"reps.external.env\");\r\n\r\n\t\t\r\n\t\t// Parse the repositories\r\n\t\t//----------------------------------\r\n\t\tString[] externalEnvReps = externalEnvRepsString.split(\";\");\r\n\t\tArrayIterator<String> it = new ArrayIterator<String>(externalEnvReps);\r\n\t\twhile (it.hasNext()) {\r\n\t\t\tString rep = it.next();\r\n\t\t\ttry {\r\n\t\t\t\tthis.loadRepository(rep);\r\n\t\t\t} catch (Exception e) {\r\n\t\t\t\t// Remove wrong URL\r\n\t\t\t\t//it.remove();\r\n\t\t\t\te.printStackTrace();\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\tString[] externalAddedReps = externalAddedRepsString.split(\";\");\r\n\t\tit = new ArrayIterator<String>(externalAddedReps);\r\n\t\twhile (it.hasNext()) {\r\n\t\t\tString rep = it.next();\r\n\t\t\ttry {\r\n\t\t\t\tthis.loadRepository(rep);\r\n\t\t\t} catch (Exception e) {\r\n\t\t\t\t// Remove wrong URL\r\n\t\t\t\t//it.remove();\r\n\t\t\t\te.printStackTrace();\r\n\t\t\t} \r\n\t\t}\r\n\t\t\r\n\t\t// Resave in case we cleaned them\r\n\t\t//-------------------------------------\r\n\t\t*/\r\n\t\t\r\n\t\t\r\n\t}", "public void projectBuildDirChanged() { }", "public void projectBuildDirChanged() { }", "public void loadRecentPaneFiles() {\r\n // create streams\r\n \r\n boolean exists = (new File(fileWithFileListOfPaneRecentFiles)).exists();\r\nif (exists) {\r\n \r\n try {\r\n // open the file containing the stored list of recent files\r\n FileInputStream input = new FileInputStream(fileWithFileListOfPaneRecentFiles);\r\n \r\n //create reader stream\r\n BufferedReader recentsReader= new BufferedReader(new InputStreamReader(input));\r\n\r\n recentPaneFiles.clear(); // clear the Vector of recent files\r\n String currentLine; // refill it from disk\r\n while ((currentLine = recentsReader.readLine()) != null)\r\n if (recentPaneFiles.indexOf(currentLine) == -1) // file not already in list\r\n recentPaneFiles.add(currentLine);\r\n\r\n recentsReader.close();\r\n input.close();\r\n updateRecentPaneFilesMenu(); // update the recent files menu\r\n\r\n }\r\n catch(java.io.IOException except)\r\n {\r\n System.out.println(\"IO exception in readRecentsFiles. File: \"+fileWithFileListOfPaneRecentFiles+\" not found\");\r\n recentPaneFilesMenu.removeAll(); // clear previous menu items\r\n clearRecentFilesJMenuItem = new JMenuItem(\"Clear the list of recent files\");\r\n clearRecentFilesJMenuItem.addActionListener(new ActionListener() {\r\n\r\n public void actionPerformed(ActionEvent e) {\r\n recentPaneFiles.clear();\r\n recentPaneFilesMenu.removeAll();\r\n }\r\n });\r\n\r\n recentPaneFilesMenu.add(clearRecentFilesJMenuItem);\r\n mainJMenuBar.add(recentPaneFilesMenu); // finally add the recent files menu to the main menu bar\r\n \r\n }\r\n }\r\n }", "Object getRelativeToChangelogFile();", "String getWorkfileRevisionString();", "private void update() {\n\n\t\tthis.projects.clear();\n\n\t\tfor (Project p : INSTANCE.getProjects()) {\n\t\t\tif (p instanceof Infrastructure) {\n\t\t\t\tthis.projects.addElement(p);\n\t\t\t}\n\t\t}\n\n\t\tfor (Project p : INSTANCE.getProjects()) {\n\t\t\tif (p instanceof Social) {\n\t\t\t\tthis.projects.addElement(p);\n\t\t\t}\n\t\t}\n\t}", "public static void main(String[] args) {\n try{\n Properties props = new Properties();\n props.load(new FileInputStream(\"transform.properties\"));\n String outputFileName = props.getProperty(\"harpurOutput\");\n String inputFileName = props.getProperty(\"harpurInput\");\n projectId = props.getProperty(\"harpurProjectId\");\n CSVReader reader = new CSVReader(new FileReader(inputFileName));\n String [] nextLine;\n //Work no.,Work title,Version no.,Date,First line of version,Title of version,Source,Bib. details\n //0 Work no., 1 Work title,2 Version no.,3 Year, 4 Date,5 First line of version,6 Blank, 7 Title of version,8 Source,9 Page no, 10 Notes, 11 Series, 12 lines, 13 ms, 14 url\n String versTitle, workTitle=\"\";\n HashMap<String,String> currentWork = null;\n ArrayList<String> currentVersions = new ArrayList<String>();\n boolean firstLine = true;\n int rowNumber = 0;\n while ((nextLine = reader.readNext()) != null) {\n if (!firstLine){\n rowNumber++;\n // If this line represents a new work, create a work record\n if (!nextLine[0].equals(\"\")){\n // add list of versions accumulated so far to previous work and then reset\n if (currentVersions.size() != 0 && currentWork != null){\n StringBuffer cVers = new StringBuffer();\n cVers.append(\"[\");\n Iterator<String> it = currentVersions.iterator();\n while(it.hasNext()){\n cVers.append(\"\\\"\" + it.next() + \"\\\"\");\n if (it.hasNext()){\n cVers.append(\", \");\n }\n }\n cVers.append(\"]\");\n // for each in currentVersions add new ObjectId(currentVersions[i]) to cVers array\n currentWork.put(\"versions\", cVers.toString());\n currentVersions.clear();\n }\n currentWork = new HashMap<String,String>();\n currentWork.put(\"name\",nextLine[0]);\n workTitle = nextLine[1];\n currentWork.put(\"workTitle\", replaceStupidCharacters(workTitle));\n workList.add(currentWork);\n }\n //if (!nextLine[2].equals(\"\")){\n // Create a version (don't worry about issues, Harpur project only has to deal with one issue per version)\n HashMap<String,String> v = new HashMap<String,String>();\n String versionId = new ObjectId().toString();\n v.put(\"importRowNumber\", rowNumber + \"\");\n v.put(\"_id\", \"{ \\\"$oid\\\" : \\\"\" + versionId + \"\\\"}\");\n // push version id to currentVersions for later linking from work\n currentVersions.add(versionId);\n String hnum = nextLine[2];\n v.put(\"name\",hnum);\n v.put(\"date\", (!nextLine[4].equals(\"\")? nextLine[4] + \" \": \"\") + nextLine[3]);\n v.put(\"lines\", nextLine[11]);\n v.put(\"firstLine\", replaceStupidCharacters(nextLine[5]));\n versTitle = nextLine[6];\n if (versTitle.startsWith(\"^\")){\n versTitle = workTitle;\n } else if (versTitle.trim().equals(\"-\")){\n versTitle = \"Untitled\";\n }\n v.put(\"versionTitle\", replaceStupidCharacters(versTitle));\n versionList.add(v);\n \n //if (nextLine[2] == null || !nextLine[9].equals(\"\")){\n // Create an Artefact (part) for each version\n //8 Source,9 Page no, 10 Notes, 11 Series, 12 Version no, 13 lines, 14 ms, 15 url\n HashMap<String,String> a = new HashMap<String,String>();\n String artefactId = new ObjectId().toString();\n String source = nextLine[7].trim();\n String pageNumbers = nextLine[8].trim();\n a.put(\"importRowNumber\", rowNumber + \"\");\n a.put(\"_id\",\"{ \\\"$oid\\\" : \\\"\" + artefactId + \"\\\"}\");\n a.put(\"source\", source + (!pageNumbers.equals(\"\") ? \" p\" + pageNumbers: \"\"));\n a.put(\"pageNumbers\", pageNumbers);\n a.put(\"description\", nextLine[9]); // actually notes field\n a.put(\"series\", nextLine[10]);\n a.put(\"date\", (!nextLine[4].equals(\"\")? nextLine[4] + \" \": \"\") + nextLine[3]);\n artefactList.add(a);\n \n // add source,artefact id to artefact parts map\n if (!source.equals(\"\")){\n if (artefactParts.containsKey(source)){\n artefactParts.get(source).add(artefactId);\n } else {\n ArrayList<String> parts = new ArrayList<String>();\n parts.add(artefactId);\n artefactParts.put(source, parts);\n }\n }\n // Create temporary mappings that will be used later to match uploaded images with artefacts\n HashMap<String,String> t = new HashMap<String,String>();\n t.put(\"hnum\", hnum);\n t.put(\"artefact\",artefactId);\n t.put(\"version\", versionId);\n t.put(\"ms\", nextLine[12]);\n t.put(\"imageUrl\", nextLine[13]);\n mappingList.add(t);\n \n // generate link from version to artefact\n v.put(\"artefacts\", \"[\\\"\" + artefactId + \"\\\"]\");\n if (!nextLine[0].equals(\"\")){\n // composition event for each work\n HashMap<String,String> e = new HashMap<String,String>();\n e.put(\"artefacts\", \"[\\\"\" + artefactId + \"\\\"]\");\n e.put(\"startDate\", nextLine[3]);\n \n e.put(\"eventType\", \"composition\");\n e.put(\"eventtags\", \"[\\\"composition\\\"]\");\n \n e.put(\"name\", \"\\\\\\\"\" + replaceStupidCharacters(workTitle) + \"\\\\\\\"\");\n eventList.add(e);\n }\n //}\n //}\n } else {\n firstLine = false;\n }\n }\n // versions for last work\n if (currentVersions.size() != 0 && currentWork != null){\n StringBuffer cVers = new StringBuffer();\n cVers.append(\"[\");\n Iterator<String> it = currentVersions.iterator();\n while(it.hasNext()){\n cVers.append(\"\\\"\" + it.next() + \"\\\"\");\n if (it.hasNext()){\n cVers.append(\", \");\n }\n }\n cVers.append(\"]\");\n // for each in currentVersions add new ObjectId(currentVersions[i]) to cVers array\n currentWork.put(\"versions\", cVers.toString());\n }\n \n // iterate over artefact parts, if number of parts is more than 1, add an artefact to represent the source\n for (String k : artefactParts.keySet()) {\n ArrayList<String> parts = artefactParts.get(k);\n if (parts.size() > 1){\n String artefactsString = \"[\";\n for (int j=0; j<parts.size();j++){\n artefactsString += \"\\\"\" + parts.get(j) + \"\\\"\";\n if (j < (parts.size() -1)) {\n artefactsString += \",\";\n }\n }\n artefactsString += \"]\";\n HashMap<String,String> a = new HashMap<String,String>();\n String artefactId = new ObjectId().toString();\n a.put(\"_id\",\"{ \\\"$oid\\\" : \\\"\" + artefactId + \"\\\"}\");\n a.put(\"source\",k);\n a.put(\"artefacts\", artefactsString);\n artefactList.add(a);\n }\n }\n // write works to file\n File outputFile = new File(outputFileName + WORK_COLLECTION + \".json\");\n outputFile.delete();\n outputFile = new File(outputFileName + ARTEFACT_COLLECTION + \".json\");\n outputFile.delete();\n outputFile = new File(outputFileName + VERSION_COLLECTION + \".json\");\n outputFile.delete();\n outputFile = new File(outputFileName + MAPPING_COLLECTION + \".json\");\n outputFile.delete();\n outputFile = new File(outputFileName + EVENT_COLLECTION + \".json\");\n outputFile.delete();\n \n BufferedWriter bw = new BufferedWriter(new OutputStreamWriter(\n new FileOutputStream(outputFileName + WORK_COLLECTION + \".json\"), \"UTF-8\"));\n for (HashMap<String,String> w : workList) {\n bw.write(mapToString(w) + \"\\n\");\n }\n bw.close();\n \n bw = new BufferedWriter(new OutputStreamWriter(\n new FileOutputStream(outputFileName + VERSION_COLLECTION + \".json\"), \"UTF-8\"));\n for (HashMap<String,String> v : versionList) {\n bw.write(mapToString(v) + \"\\n\");\n }\n bw.close();\n \n bw = new BufferedWriter(new OutputStreamWriter(\n new FileOutputStream(outputFileName + ARTEFACT_COLLECTION + \".json\"), \"UTF-8\"));\n for (HashMap<String,String> a : artefactList) {\n bw.write(mapToString(a) + \"\\n\");\n }\n bw.close();\n \n bw = new BufferedWriter(new OutputStreamWriter(\n new FileOutputStream(outputFileName + MAPPING_COLLECTION + \".json\"), \"UTF-8\"));\n for (HashMap<String,String> t : mappingList) {\n bw.write(mapToString(t) + \"\\n\");\n }\n bw.close();\n \n bw = new BufferedWriter(new OutputStreamWriter(\n new FileOutputStream(outputFileName + EVENT_COLLECTION + \".json\"), \"UTF-8\"));\n for (HashMap<String,String> e : eventList) {\n bw.write(mapToString(e) + \"\\n\");\n }\n bw.close();\n\n } catch (IOException e) {\n e.printStackTrace();\n }\n }", "private static void addProjectFiles(IProject newProject){\n \t//add README file\n \taddProjectFile(newProject , README_FILE_NAME , \"\" );\n \t//add ProviderClass\n \taddProjectFile(newProject , PROVIDER_SCRIPT_FILE_NAME , CLASSES_FOLDER+\"/\" );\n }", "@SuppressWarnings(\"unchecked\")\n\tpublic List<String> openDiffs() {\n\t\tString path = getCurrentPath()+slash+\"diffs.xml\";\n\t\tList<String> diffs = (List<String>) JavaIO.getObjectFromXML(path);\n\t\treturn diffs;\n\t}", "private void loadPropertyFiles() {\n if ( _sax_panel != null ) {\n _property_files = ( ( SAXTreeModel ) _sax_panel.getModel() ).getPropertyFiles();\n if ( _property_files == null )\n return ;\n HashMap filelist = new HashMap();\n ArrayList resolved = new ArrayList();\n Iterator it = _property_files.keySet().iterator();\n while ( it.hasNext() ) {\n Object o = it.next();\n if ( o == null )\n continue;\n File f = null;\n if ( o instanceof File ) {\n f = ( File ) o;\n Long lastModified = ( Long ) _property_files.get( f );\n filelist.put( f, lastModified );\n }\n else if ( _project != null ) {\n String value = o.toString();\n String filename = value;\n if ( value.startsWith( \"${\" ) && value.endsWith( \"}\" ) ) {\n filename = filename.substring( 2, filename.length() - 1 );\n }\n filename = _project.getProperty( filename );\n if ( filename != null )\n f = new File( filename );\n if ( f != null && !f.exists() ) {\n f = new File( _project.getBaseDir(), filename );\n }\n if ( f != null && f.exists() ) {\n filelist.put( f, new Long( f.lastModified() ) );\n resolved.add( value );\n }\n // see issue #21, Ant standard is to quietly ignore files not found\n //else\n // _logger.warning( \"Unable to find property file for \" + value );\n }\n }\n it = resolved.iterator();\n while ( it.hasNext() ) {\n filelist.remove( it.next() );\n }\n _property_files = filelist;\n }\n }", "public void notifyNewProject(URI project) {\n\t\tDebug.log(\"Loading uninitialized project \", project);\n\t\tnotifyNewProjectFiles(new File(project));\n\t}", "private void buildTree(String projectPath, VssProject vssProject) {\r\n \tif(config.useComApi)\r\n {\r\n \t\tgetVss().getComApiDirProject(vssProject);\r\n }\r\n \telse\r\n \t{\r\n \t\tFile file = getVss().listFilesInProject(projectPath);\r\n\r\n\t BufferedReader in = Util.openReader(file, config.getLogEncoding());\r\n\t try {\r\n\t parseTree(in, vssProject);\r\n\t } finally {\r\n\t Util.close(in);\r\n\t }\r\n \t}\r\n \t\r\n for (Iterator i = vssProject.getSubprojects().iterator(); i.hasNext();) {\r\n VssProject subproject = (VssProject) i.next();\r\n String path = projectPath + \"/\" + subproject.getName();\r\n buildTree(path, subproject);\r\n }\r\n }", "public static void log() {\n String branch = commitPointers.readHeadCommit()[0];\n String currName = commitPointers.readHeadCommit()[1];\n File cFile = Utils.join(Commit.COMMIT_FOLDER, currName + \".txt\");\n Commit curr = Utils.readObject(cFile, Commit.class);\n\n while (currName != null) {\n System.out.println(\"===\");\n System.out.println(\"commit \" + curr.commitID);\n if (curr.parentID.size() == 2) {\n System.out.println(\"Merge: \" + curr.parentID.get(0).substring(0, 7) + \" \" + curr.parentID.get(1).substring(0, 7));\n }\n System.out.println(\"Date: \" + curr.timeStamp.format(myFormatObj) + \" -0800\");\n System.out.println(curr.message);\n System.out.println();\n\n currName = curr.parentID.get(0);\n\n if (currName != null) {\n File newcFile = Utils.join(Commit.COMMIT_FOLDER, currName + \".txt\");\n curr = Utils.readObject(newcFile, Commit.class);\n }\n }\n }", "@Override\r\n public void refresh(@NotNull final Project project) {\n ChangeListManager.getInstance(project).ensureUpToDate(true);\r\n }", "TrackerListVersion loadTrackerListVersion(final Integer id);", "public void setProjectVersions(List<Version> projectVersions) {\n\n // It is possible that the Versions associated to the issue are not\n // retrieved from the Database query.\n Set<Version> joinedSet = new TreeSet<>(new ReleaseDateComparator());\n joinedSet.addAll(projectVersions);\n joinedSet.addAll(Arrays.asList(issue.getVersions()));\n joinedSet.addAll(Arrays.asList(issue.getFixVersions()));\n\n this.projectVersions = joinedSet;\n }", "void updateBranch(Commit newt) {\n String nextBranch = null;\n Commit theNext = null;\n File parent = new File(\".gitlet/current\");\n for (File file : parent.listFiles()) {\n nextBranch = file.getName();\n }\n try {\n File getHead = new File(\".gitlet/heads/\" + nextBranch);\n FileOutputStream fieOut = new FileOutputStream(getHead);\n ObjectOutputStream obetOut = new ObjectOutputStream(fieOut);\n obetOut.writeObject(newt);\n } catch (IOException e) {\n System.out.println(\"Didn't work.\");\n }\n try {\n File hideous = new File(\".gitlet/current/\" + nextBranch);\n FileOutputStream ieOut = new FileOutputStream(hideous);\n ObjectOutputStream betOut = new ObjectOutputStream(ieOut);\n betOut.writeObject(newt);\n } catch (IOException e) {\n System.out.println(\"Didn't work.\");\n }\n }", "@SuppressWarnings(\"unchecked\")\n\t@Override\n\tpublic void refreshModules()\n\t{\n\t\t// Scan each directory in turn to find JAR files\n\t\t// Subdirectories are not scanned\n\t\tList<File> jarFiles = new ArrayList<>();\n\n\t\tfor (File dir : moduleDirectories) {\n\t\t\tfor (File jarFile : dir.listFiles(jarFileFilter)) {\n\t\t\t\tjarFiles.add(jarFile);\n\t\t\t}\n\t\t}\n\n\t\t// Create a new class loader to ensure there are no class name clashes.\n\t\tloader = new GPIGClassLoader(jarFiles);\n\t\tfor (String className : loader.moduleVersions.keySet()) {\n\t\t\ttry {\n\t\t\t\t// Update the record of each class\n\t\t\t\tClass<? extends Interface> clz = (Class<? extends Interface>) loader.loadClass(className);\n\t\t\t\tClassRecord rec = null;\n\t\t\t\tfor (ClassRecord searchRec : modules.values()) {\n\t\t\t\t\tif (searchRec.clz.getName().equals(className)) {\n\t\t\t\t\t\trec = searchRec;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif (rec != null) {\n\t\t\t\t\t// This is not an upgrade, ignore it\n\t\t\t\t\tif (rec.summary.moduleVersion >= loader.moduleVersions.get(className)) continue;\n\n\t\t\t\t\t// Otherwise update the version number stored\n\t\t\t\t\trec.summary.moduleVersion = loader.moduleVersions.get(className);\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\trec = new ClassRecord();\n\t\t\t\t\trec.summary = new ModuleSummary(IDGenerator.getNextID(), loader.moduleVersions.get(className),\n\t\t\t\t\t\t\tclassName);\n\t\t\t\t\tmodules.put(rec.summary.moduleID, rec);\n\t\t\t\t}\n\t\t\t\trec.clz = clz;\n\n\t\t\t\t// Update references to existing objects\n\t\t\t\tfor (StrongReference<Interface> ref : instances.values()) {\n\t\t\t\t\tif (ref.get().getClass().getName().equals(className)) {\n\t\t\t\t\t\tConstructor<? extends Interface> ctor = clz.getConstructor(Object.class);\n\t\t\t\t\t\tref.object = ctor.newInstance(ref.get());\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tcatch (NoSuchMethodException e) {\n\t\t\t\t// Thrown when trying to find a suitable constructor\n\t\t\t\tSystem.err.println(\"Discovered class which has no available upgrade constructor: \" + className + \"\\n\\t\"\n\t\t\t\t\t\t+ e.getLocalizedMessage());\n\t\t\t}\n\t\t\tcatch (InstantiationException | IllegalAccessException | IllegalArgumentException\n\t\t\t\t\t| InvocationTargetException e) {\n\t\t\t\t// All thrown by the instantiate call\n\t\t\t\tSystem.err.println(\"Unable to create new instance of class: \" + className + \"\\n\\t\"\n\t\t\t\t\t\t+ e.getLocalizedMessage());\n\t\t\t}\n\t\t\tcatch (ClassNotFoundException e) {\n\t\t\t\t// Should never occur but required to stop the compiler moaning\n\t\t\t\tSystem.err.println(\"Discovered class which has no available upgrade constructor: \" + className + \"\\n\\t\"\n\t\t\t\t\t\t+ e.getLocalizedMessage());\n\t\t\t}\n\t\t}\n\t}", "@Test(dataProvider = \"doFetchInSeparateProcess\", dataProviderClass = FetchOptionsDataProvider.class)\n public void testCollectBuildChangesSubmodules(boolean fetchInSeparateProcess) throws Exception {\n System.setProperty(\"teamcity.git.fetch.separate.process\", String.valueOf(fetchInSeparateProcess));\n GitVcsSupport support = getSupport();\n VcsRoot root = getRoot(\"patch-tests\", true);\n final List<ModificationData> ms =\n support.collectChanges(root, BEFORE_SUBMODULE_ADDED_VERSION, SUBMODULE_ADDED_VERSION, new CheckoutRules(\"\"));\n assertEquals(1, ms.size());\n ModificationData m1 = ms.get(0);\n assertEquals(\"added submodule\\n\", m1.getDescription());\n assertEquals(2, m1.getChanges().size());\n VcsChange ch11 = m1.getChanges().get(0);\n assertEquals(VcsChange.Type.ADDED, ch11.getType());\n assertEquals(\".gitmodules\", ch11.getFileName());\n VcsChange ch12 = m1.getChanges().get(1);\n assertEquals(\"submodule/file.txt\", ch12.getFileName());\n assertEquals(VcsChange.Type.ADDED, ch12.getType());\n final List<ModificationData> ms2 =\n support.collectChanges(root, SUBMODULE_ADDED_VERSION, SUBMODULE_MODIFIED_VERSION, new CheckoutRules(\"\"));\n assertEquals(1, ms.size());\n ModificationData m2 = ms2.get(0);\n assertEquals(\"submodule updated\\n\", m2.getDescription());\n assertEquals(1, m2.getChanges().size());\n VcsChange ch21 = m2.getChanges().get(0);\n assertEquals(\"submodule/new file.txt\", ch21.getFileName());\n assertEquals(VcsChange.Type.ADDED, ch21.getType());\n }" ]
[ "0.5921563", "0.5703528", "0.5610158", "0.55175424", "0.5502812", "0.54604644", "0.5455955", "0.53698266", "0.5355211", "0.53486747", "0.52663136", "0.5265018", "0.52583313", "0.51863056", "0.5147649", "0.5134528", "0.51300734", "0.51052636", "0.5050498", "0.5012914", "0.5004302", "0.4995325", "0.4988685", "0.49839225", "0.49544188", "0.4949117", "0.49385566", "0.49032685", "0.4893593", "0.48776895", "0.48664752", "0.4858888", "0.48541814", "0.4853867", "0.48318318", "0.4817315", "0.4816965", "0.4812932", "0.48129168", "0.48070994", "0.47999027", "0.4790668", "0.47899562", "0.4787506", "0.47736055", "0.477298", "0.4771814", "0.4770837", "0.47396243", "0.4730415", "0.4723414", "0.47212562", "0.4707896", "0.4698529", "0.46953332", "0.4687041", "0.4685516", "0.4684251", "0.46815047", "0.46773976", "0.46753302", "0.46743315", "0.4673069", "0.4663549", "0.46631083", "0.466059", "0.46603927", "0.46498862", "0.4646631", "0.46465245", "0.46386904", "0.46344084", "0.46341142", "0.4632167", "0.4628395", "0.46179405", "0.46170667", "0.4614935", "0.4606675", "0.46039948", "0.4596876", "0.45914558", "0.45914558", "0.4591121", "0.45864758", "0.4585938", "0.45853844", "0.45818025", "0.457753", "0.4570493", "0.45686337", "0.45611593", "0.4558815", "0.45556834", "0.45553115", "0.45530468", "0.4552596", "0.45500788", "0.45471895", "0.45433098" ]
0.7193224
0
Check project for existing of unsupported operations
private void checkDirHistory(VssProject project) { try { File dirHistory = getVss().getDirHistory(project); BufferedReader r = Util.openReader(dirHistory, config.getLogEncoding()); try { String s; while ((s = r.readLine()) != null) { if (s.endsWith(" recovered") || s.endsWith(" destroyed") || s.endsWith(" branched") || s.endsWith(" shared") || s.indexOf(" renamed to ") != -1 ) { incrementalWarning = true; break; } } } finally { r.close(); } } catch (IOException e) { throw new VssException(e); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "boolean hasProject();", "@Test\n public void testIsCreatingProjectIfMissing() throws Exception {\n assertThat(\"Expect true\", testling.isCreatingProjectIfMissing(), is(Boolean.TRUE));\n }", "String checkIfProjectExists(String projectKey, String projectName);", "@Override\r\n\t@Test(groups = {\"function\",\"setting\"} ) \r\n\tpublic boolean checkPlatform() {\n\t\tboolean flag = oTest.checkPlatform();\r\n\t\tAssertion.verifyEquals(flag, true);\r\n\t\treturn flag;\r\n\t}", "public boolean[] hasConflictsAndChanges(Project project);", "@Override\n protected Result check()\n {\n return this.gitLabModeInfos.isEmpty() ? Result.unhealthy(\"No GitLab modes available\") : Result.healthy();\n }", "boolean supportsExternalTool();", "protected boolean isNonJavaProject(ILaunchConfiguration configuration) throws CoreException {\n\t\tIJavaModel javaModel = JavaCore.create(ResourcesPlugin.getWorkspace().getRoot());\r\n\t\r\n\t\tboolean answer = false;\r\n\t\tString projectName = configuration.getAttribute(\r\n\t\t\t\tIJavaLaunchConfigurationConstants.ATTR_PROJECT_NAME,\r\n\t\t\t\t(String) null);\r\n\t\tif (projectName != null && projectName.trim().length() > 0) {\r\n\t\t\tIJavaProject javaProject = javaModel.getJavaProject(projectName);\r\n\t\t\t// IJavaProject javaProject =\r\n\t\t\t// JavaRuntime.getJavaProject(configuration);\r\n\t\t\tif (javaProject != null) {\r\n\t\t\t\t// lets see if it exists\r\n\t\t\t\tif (!javaProject.exists()) {\r\n\t\t\t\t\tanswer = true;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn answer;\r\n\t}", "public abstract boolean isDisable(Project project);", "protected void checkCanRun() throws BuildException {\n \n }", "private boolean containsOnlyNonProjects(IResource[] resources) {\r\n int types = getSelectedResourceTypes(resources);\r\n // check for empty selection\r\n if (types == 0) {\r\n return false;\r\n }\r\n // note that the selection may contain multiple types of resource\r\n return (types & IResource.PROJECT) == 0;\r\n }", "public static boolean isSupported() {\n boolean supported = false;\n\n try {\n Process process = new ProcessBuilder().command( \"svn\", \"help\" ).start();\n int exitCode = process.waitFor();\n\n supported = (exitCode == 0);\n\n } catch (Exception e) {\n // Ignore and return false\n }\n return supported;\n }", "boolean hasCreateTaskPack();", "private boolean containsOnlyProjects(IResource[] resources) {\r\n int types = getSelectedResourceTypes(resources);\r\n // note that the selection may contain multiple types of resource\r\n return types == IResource.PROJECT;\r\n }", "public boolean shouldExecuteOnProject(Project project)\n {\n return fs.hasFiles(fs.predicates().hasLanguage(\"ruby\"));\n }", "default void projectOpenFailed() {\n }", "boolean hasBuild();", "private void checkOperatingSystem()\n throws MojoExecutionException\n {\n final PtOperatingSystem opSystem = PtUserSniffer.getOS();\n final boolean isProperOpSystem = opSystem == PtOperatingSystem.MAC;\n\n this.logger.info( \"Checking operating system '\" + opSystem + \"' ... \" + ( isProperOpSystem ? \"ok\" : \"error\" ) );\n if ( isProperOpSystem == false )\n {\n throw new MojoExecutionException( \"Invalid Operating System '\" + opSystem + \"' (Mac OS X required)!\" );\n }\n }", "protected void checkIfConfigurationModificationIsAllowed() {\r\n\t\tif (isCompiled()) {\r\n\t\t\tthrow new InvalidDataAccessApiUsageException(\"Configuration can't be altered once the class has been compiled or used.\");\r\n\t\t}\r\n\t}", "void notSupported(String errorcode);", "public void testGetProjectByNameIllegalArguments() throws Exception {\r\n ProjectServiceRemote projectService = lookupProjectServiceRemoteWithUserRole();\r\n\r\n // null name\r\n try {\r\n projectService.getProjectByName(null, 1);\r\n fail(\"ProjectNotFoundFault expected.\");\r\n } catch (IllegalArgumentFault e) {\r\n // expected\r\n }\r\n\r\n // empty name\r\n try {\r\n projectService.getProjectByName(\" \", 1);\r\n fail(\"ProjectNotFoundFault expected.\");\r\n } catch (IllegalArgumentFault e) {\r\n // expected\r\n }\r\n\r\n // non-positive user id\r\n try {\r\n projectService.getProjectByName(\"abc\", 0);\r\n fail(\"ProjectNotFoundFault expected.\");\r\n } catch (IllegalArgumentFault e) {\r\n // expected\r\n }\r\n\r\n // non-positive user id\r\n try {\r\n projectService.getProjectByName(\"abc\", -1);\r\n fail(\"ProjectNotFoundFault expected.\");\r\n } catch (IllegalArgumentFault e) {\r\n // expected\r\n }\r\n }", "boolean canAccess(String workspaceName) throws NoSuchWorkspaceException, RepositoryException;", "public void check() throws XMLBuildException {\r\n\r\n\t}", "public void check() throws XMLBuildException {\r\n\r\n\t}", "@Test\n\tpublic void testExistsProjectInexistent() throws Exception {\n\t\tIRodinProject other = getRodinProject(\"Inexistent\");\n\t\tassertFalse(\"An existent project should not be open\",\n\t\t\t\tother.isOpen());\n\t\tassertNotExists(\"The Rodin project should not exist\", other);\n\t\tassertFalse(\"The existence test should not have opened the project\",\n\t\t\t\tother.isOpen());\n\t}", "boolean hasIsSupportComp();", "int checkPlatform(ArtifactCoords platform) {\n return checkQuarkusVersion(platform.getVersion());\n }", "boolean hasOperation();", "private void checkStatus()\n {\n // If the last command failed\n if(!project.getLastCommandStatus())\n {\n view.alert(\"Error: \" + project.getLastCommandStatusMessage());\n\t\t}\n\t\telse\n\t\t{\n\t\t\tCommand lastCmd = project.getLastCommand();\n\t\t\tif (lastCmd != null && lastCmd.hasOptionalState())\n\t\t\t{\n\t\t\t\tview.loadFromJSON(lastCmd.getOptionalState());\n\t\t\t\tview.onUpdate(project.getProjectSnapshot(), false);\n\t\t\t}\n\t\t}\n }", "@Test(groups = { \"wso2.esb\" }, description = \"agilezen {updateProject} integration test with negative case.\", dependsOnMethods = { \"testListProjectsWithMandatoryParameters\" })\n public void testUpdateProjectWithNegativeCase() throws IOException, JSONException {\n \n esbRequestHeadersMap.put(\"Action\", \"urn:updateProject\");\n RestResponse<JSONObject> esbRestResponse =\n sendJsonRestRequest(proxyUrl, \"POST\", esbRequestHeadersMap, \"esb_updateProject_negative.json\");\n \n final String apiEndPoint = apiRequestUrl + \"/projects/123456\";\n RestResponse<JSONObject> apiRestResponse = sendJsonRestRequest(apiEndPoint, \"PUT\", apiRequestHeadersMap);\n \n Assert.assertEquals(esbRestResponse.getHttpStatusCode(), 404);\n Assert.assertEquals(apiRestResponse.getHttpStatusCode(), 404);\n \n }", "@Test(groups = { \"wso2.esb\" }, description = \"agilezen {getProject} integration test with negative case.\", dependsOnMethods = { \"testListProjectsWithMandatoryParameters\" })\n public void testGetProjectWithNegativeCase() throws IOException, JSONException {\n \n esbRequestHeadersMap.put(\"Action\", \"urn:getProject\");\n RestResponse<JSONObject> esbRestResponse =\n sendJsonRestRequest(proxyUrl, \"POST\", esbRequestHeadersMap, \"esb_getProject_negative.json\");\n \n final String apiEndPoint = apiRequestUrl + \"/projects/123456\";\n RestResponse<JSONObject> apiRestResponse = sendJsonRestRequest(apiEndPoint, \"GET\", apiRequestHeadersMap);\n \n Assert.assertEquals(esbRestResponse.getHttpStatusCode(), 404);\n Assert.assertEquals(apiRestResponse.getHttpStatusCode(), 404);\n \n }", "@Test\n public void getLatestScanResults_nonexistentProject() {\n testMissingResultsCase(\"nonexistent-project-name\");\n }", "private void chk() {\n if (clist != null)\n throw new UnsupportedOperationException();\n }", "private static boolean validOperation(String op) {\n\t\tfor (String goodOp : validOps) {\n\t\t\tif (goodOp.equalsIgnoreCase(op)) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}", "@Test\n public void checkIfSupportedTest() {\n assertTrue(EngineController.checkIfSupported(\"getMaxRotateSpeed\"));\n assertTrue(EngineController.checkIfSupported(\"rotate 10 1\"));\n assertTrue(EngineController.checkIfSupported(\"orient\"));\n // check interface, that specific for engine\n assertTrue(EngineController.checkIfSupported(\"getMaxThrust\"));\n assertTrue(EngineController.checkIfSupported(\"getCurrentThrust\"));\n assertTrue(EngineController.checkIfSupported(\"setThrust 333\"));\n }", "private boolean solutionChecker() {\n\t\t// TODO\n\t\treturn false;\n\n\t}", "public void testGetProjectByNameDoesNotExist() throws Exception {\r\n ProjectServiceRemote projectService = lookupProjectServiceRemoteWithUserRole();\r\n\r\n // 1 is the user id\r\n try {\r\n projectService.getProjectByName(\"xxxxx\", 1);\r\n fail(\"ProjectNotFoundFault expected.\");\r\n } catch (ProjectNotFoundFault e) {\r\n // expected\r\n }\r\n }", "@CliAvailabilityIndicator({\"field reference\", \"field set\"})\n \tpublic boolean isJpaFieldManagementAvailable() {\n \t\treturn classpathOperations.isProjectAvailable();\n \t}", "@Test(expected = Exception.class)\n public void testDescUnSuportedContext() throws Throwable\n {\n testDescDeployment(\"unsupported\");\n }", "public void testGetProjectFlags() {\n String[] sTestCmdLine = { \"soscmd\", \"-command\", \"GetProject\", \"-recursive\",\n \"-label\", SRC_LABEL, \"-server\", SOS_SERVER_PATH, \"-name\", SOS_USERNAME,\n \"-password\", \"\", \"-database\", VSS_SERVER_PATH , \"-project\",\n \"$\"+VSS_PROJECT_PATH, \"\", \"\", \"-soshome\", SOS_HOME, \"-workdir\",\n project.getBaseDir().getAbsolutePath() };\n // Set up a SOSGet task\n sosGet.setProject(project);\n sosGet.setVssServerPath(VSS_SERVER_PATH);\n sosGet.setSosServerPath(SOS_SERVER_PATH);\n sosGet.setProjectPath(VSS_PROJECT_PATH);\n sosGet.setLabel(SRC_LABEL);\n sosGet.setUsername(SOS_USERNAME);\n sosGet.setSosHome(SOS_HOME);\n sosGet.setNoCache(true);\n sosGet.setNoCompress(false);\n sosGet.setVerbose(false);\n sosGet.setRecursive(true);\n\n commandline = sosGet.buildCmdLine();\n String[] sGeneratedCmdLine = commandline.getCommandline();\n\n int i = 0;\n while (i < sTestCmdLine.length) {\n try {\n assertEquals(\"GetProject arg # \" + String.valueOf(i),\n sTestCmdLine[i],\n sGeneratedCmdLine[i]);\n i++;\n } catch (ArrayIndexOutOfBoundsException aioob) {\n fail(\"GetProject missing arg\");\n }\n\n }\n if (sGeneratedCmdLine.length > sTestCmdLine.length) {\n // We have extra elements\n fail(\"GetProject extra args\");\n }\n }", "@Override\n public boolean isRemoteProject() {\n return true;\n }", "@Test\n\tpublic void testIsConsistentProjectNoOpen() throws Exception {\n\t\trodinProject.close();\n\t\tassertTrue(\"closed project should be consistent\", \n\t\t\t\trodinProject.isConsistent());\n\t\tassertFalse(\"project should not be open\", rodinProject.isOpen());\n\t}", "public void test_61277b() {\n \t\tIProject project1 = getProject(getUniqueString());\n \t\tIProject project2 = getProject(getUniqueString());\n \t\tensureExistsInWorkspace(new IResource[] {project1}, true);\n \t\tPreferences node = new ProjectScope(project1).getNode(ResourcesPlugin.PI_RESOURCES);\n \t\tnode.put(\"key\", \"value\");\n \t\tassertTrue(\"1.0\", !getFileInWorkspace(project1, ResourcesPlugin.PI_RESOURCES).exists());\n \t\ttry {\n \t\t\tnode.flush();\n \t\t} catch (BackingStoreException e) {\n \t\t\tfail(\"1.99\", e);\n \t\t}\n \t\tassertTrue(\"1.1\", getFileInWorkspace(project1, ResourcesPlugin.PI_RESOURCES).exists());\n \t\t// move project and ensures charsets settings are preserved\n \t\ttry {\n \t\t\tproject1.move(project2.getFullPath(), false, null);\n \t\t} catch (CoreException e) {\n \t\t\tfail(\"2.99\", e);\n \t\t}\n \t\tassertTrue(\"2.0\", getFileInWorkspace(project2, ResourcesPlugin.PI_RESOURCES).exists());\n \t\tnode = new ProjectScope(project2).getNode(ResourcesPlugin.PI_RESOURCES);\n \t\tassertEquals(\"2.1\", \"value\", node.get(\"key\", null));\n \t}", "boolean hasApikeyOpId();", "private boolean canDelete(IResource[] resources) {\r\n // allow only projects or only non-projects to be selected;\r\n // note that the selection may contain multiple types of resource\r\n if (!(containsOnlyProjects(resources) || containsOnlyNonProjects(resources))) {\r\n return false;\r\n }\r\n\r\n if (resources.length == 0) {\r\n return false;\r\n }\r\n // Return true if everything in the selection exists.\r\n for (IResource resource : resources) {\r\n if (resource.isPhantom()) {\r\n return false;\r\n }\r\n }\r\n return true;\r\n }", "public boolean isValidOperation(String srcClass, String targetClass, TaskType operation) throws InvalidOperationException\n\t{\n\t\treturn true;\n\t}", "@Test\n public void testDescSuportedContext() throws Throwable\n {\n testDescDeployment(\"supported\");\n }", "public void _reportUnsupportedOperation() {\n StringBuilder sb = new StringBuilder();\n sb.append(\"Operation not supported by parser of type \");\n sb.append(getClass().getName());\n throw new UnsupportedOperationException(sb.toString());\n }", "@Override\n public RefactoringStatus isValid(IProgressMonitor progress) throws CoreException,\n OperationCanceledException\n {\n return new RefactoringStatus();\n }", "@Override\n\tpublic boolean hasOperation() {\n\t\treturn false;\n\t}", "private boolean createProject() {\r\n ProjectOverviewerApplication app = (ProjectOverviewerApplication)getApplication();\r\n Projects projects = app.getProjects();\r\n String userHome = System.getProperty(\"user.home\");\r\n // master file for projects management\r\n File projectsFile = new File(userHome + \"/.hackystat/projectoverviewer/projects.xml\");\r\n \r\n // create new project and add it to the projects\r\n Project project = new Project();\r\n project.setProjectName(this.projectName);\r\n project.setOwner(this.ownerName);\r\n project.setPassword(this.password);\r\n project.setSvnUrl(this.svnUrl);\r\n for (Project existingProject : projects.getProject()) {\r\n if (existingProject.getProjectName().equalsIgnoreCase(this.projectName)) {\r\n return false;\r\n }\r\n }\r\n projects.getProject().add(project);\r\n \r\n try {\r\n // create the specific tm3 file and xml file for the new project\r\n File tm3File = new File(userHome + \r\n \"/.hackystat/projectoverviewer/\" + this.projectName + \".tm3\");\r\n File xmlFile = new File(userHome + \r\n \"/.hackystat/projectoverviewer/\" + this.projectName + \".xml\");\r\n tm3File.createNewFile();\r\n \r\n // initialize the data for the file\r\n SensorDataCollector collector = new SensorDataCollector(app.getSensorBaseHost(), \r\n this.ownerName, \r\n this.password);\r\n collector.getRepository(this.svnUrl, this.projectName);\r\n collector.write(tm3File, xmlFile);\r\n } \r\n catch (IOException e) {\r\n e.printStackTrace();\r\n return false;\r\n }\r\n // write the projects.xml file with the new project added\r\n String packageName = \"org.hackystat.iw.projectoverviewer.jaxb.projects\";\r\n return XmlConverter.objectToXml(projects, projectsFile, packageName);\r\n }", "public boolean insertProject(Project project) throws EmployeeManagementException;", "@Override\n public String validNameProject(String name, Integer project_Oid) {\n return null;\n }", "private void checkout() {\n throw new UnsupportedOperationException(\"Not yet implemented\");\n }", "public void checkRequirements() throws TNotFoundEx{\n\t\t\n\t\tArrayList<SimpleEntry> toolsCheck = new ArrayList<>();\n\t\t\n\t\t//adb\n\t\ttoolsCheck.add(new SimpleEntry<String, String>(\"adb\", \"adb devices\"));\n\t\t//sqlite3\n\t\ttoolsCheck.add(new SimpleEntry<String, String>(\"sqlite3\", \"sqlite3 -version\"));\n\t\t//strings\n\t\ttoolsCheck.add(new SimpleEntry<String, String>(\"strings\", \"strings -v\"));\n\t\t\n\t\tboolean pass = this.checkToolOnHost(toolsCheck);\n\t\t\n\t\tif (!pass)\n\t\t\tthrow new TNotFoundEx(\"Missing tools on host: Please install the missing tools and rerun the command\");\n\t}", "public void checkIfProgramsAccesible(List<String> programList);", "@Override\n public boolean addIdea(ProjectIdea newIdea) {\n int check = 0;\n try{\n check = super.create(newIdea);\n } catch(SQLException e){\n System.out.println(e.getMessage());\n }\n return check == 1;\n }", "public boolean updateProject(Project project);", "boolean isVersion3Allowed();", "public void testCheckinProjectFlags() {\n String[] sTestCmdLine = { \"soscmd\", \"-command\", \"CheckInProject\",\n \"-recursive\", \"-server\", SOS_SERVER_PATH, \"-name\", SOS_USERNAME,\n \"-password\", \"\", \"-database\", VSS_SERVER_PATH , \"-project\",\n \"$\"+VSS_PROJECT_PATH, \"\", \"\", \"-soshome\", SOS_HOME, \"-workdir\",\n project.getBaseDir().getAbsolutePath(), \"-log\", SRC_COMMENT, };\n\n // Set up a SOSCheckin task\n sosCheckin.setProject(project);\n sosCheckin.setVssServerPath(VSS_SERVER_PATH);\n sosCheckin.setSosServerPath(SOS_SERVER_PATH);\n sosCheckin.setProjectPath(VSS_PROJECT_PATH);\n sosCheckin.setComment(SRC_COMMENT);\n sosCheckin.setUsername(SOS_USERNAME);\n sosCheckin.setSosHome(SOS_HOME);\n sosCheckin.setNoCache(true);\n sosCheckin.setNoCompress(false);\n sosCheckin.setVerbose(false);\n sosCheckin.setRecursive(true);\n\n commandline = sosCheckin.buildCmdLine();\n String[] sGeneratedCmdLine = commandline.getCommandline();\n\n int i = 0;\n while (i < sTestCmdLine.length) {\n try {\n assertEquals(\"CheckInProject arg # \" + String.valueOf(i),\n sTestCmdLine[i],\n sGeneratedCmdLine[i]);\n i++;\n } catch (ArrayIndexOutOfBoundsException aioob) {\n fail(\"CheckInProject missing arg\");\n }\n\n }\n if (sGeneratedCmdLine.length > sTestCmdLine.length) {\n // We have extra elements\n fail(\"CheckInProject extra args\");\n }\n }", "int modifyProject(Project project) throws WrongIDException, WrongDurationException;", "@objid (\"004637e6-cc35-1ff2-a7f4-001ec947cd2a\")\n @Override\n public String isValid(final String newText) {\n if (!PROJECT_NAME_PATTERN.matcher(newText).matches()) {\n return AppProjectCore.I18N.getMessage(\"ProjectName.InvalidCharacters\");\n }\n // Check that the project name does not match an already existing\n // project we also have to look for a directory of the same name even if it is\n // not a real ProjectSpace\n File dir = new File(this.workspace.toFile(), newText);\n \n if (dir.exists()) {\n return AppProjectCore.I18N.getMessage(\"ProjectName.NameAlreadyUsed\");\n \n }\n return null;\n }", "private void unsupportedModule() {\n Log.e(\"Unsupported Module\", \"Selected module is not supported by your board!\");\n }", "public abstract ProjectBean getSystemProject();", "@Override\r\n\tpublic boolean hasCapability(String methodName, Object target,\r\n\t\t\tObject[] arguments) throws RepositoryException {\n\t\treturn false;\r\n\t}", "@Test\n public void testAccessControlIsOnlyCheckedWhenNoProdDeploymentExists() {\n List<Host> hosts = createHosts(18, \"6.0.0\");\n\n List<ModelFactory> modelFactories = List.of(createHostedModelFactory(Version.fromString(\"6.0.0\")),\n createHostedModelFactory(Version.fromString(\"6.1.0\")),\n createHostedModelFactory(Version.fromString(\"6.2.0\")));\n\n DeployTester tester = createTester(hosts, modelFactories, prodZone, Clock.systemUTC());\n ApplicationId applicationId = tester.applicationId();\n // Deploy with oldest version\n tester.deployApp(\"src/test/apps/hosted/\", \"6.0.0\");\n assertEquals(9, tester.getAllocatedHostsOf(applicationId).getHosts().size());\n\n // Deploy with version that does not exist on hosts and with app package that has no write access control,\n // validation of access control should not be done, since the app is already deployed in prod\n tester.deployApp(\"src/test/apps/hosted-no-write-access-control\", \"6.1.0\");\n assertEquals(9, tester.getAllocatedHostsOf(applicationId).getHosts().size());\n }", "@Test\n public void testAircraftPartNoNotApplicable777() throws Exception {\n\n String lTaskApplSqlLdesc = \"rootpart.part_no_oem <> 777\";\n\n // verify on wing engine 777 is not applicable\n int lResult = execute( ON_WING_ENGINE_777, lTaskApplSqlLdesc );\n assertEquals( 0, lResult );\n\n // verify on wing engine 787 is applicable\n lResult = execute( ON_WING_ENGINE_787, lTaskApplSqlLdesc );\n assertEquals( 1, lResult );\n\n // verify off wing engine is applicable\n lResult = execute( OFF_WING_ENGINE, lTaskApplSqlLdesc );\n assertEquals( 1, lResult );\n }", "public abstract boolean isNetbeansKenaiRegistered();", "private boolean isCDISupportEnabled(String projectName){\n\t\topenProjectProperties(projectName);\n\t\tnew DefaultTreeItem(\"CDI (Context and Dependency Injection) Settings\").select();\n\t\tboolean toReturn = new LabeledCheckBox(\"CDI support:\").isChecked();\n\t\tnew OkButton().click();\n\t\tnew WaitWhile(new ShellWithTextIsAvailable(\"Properties for \"+projectName));\n\t\treturn toReturn;\n\t}", "@Test\n public void testAnnoSuportedContext() throws Throwable\n {\n testAnnoDeployment(SupportedContextResourceAdapter.class);\n }", "boolean hasDeleteTaskPack();", "boolean isExecutableValidationEnabled();", "@Test\n public void getMissingProjectTest() throws Exception {// Covered user cases 6.1\n httpclient = HttpClients.createDefault();\n\n deleteUsers();\n \n String userId = createTestUser();\n\n //deleteProjects(userId);//all projects have already been deleted by server since deleteUsers();\n\n try {\n CloseableHttpResponse response = createProject(\"testProjectName1\", userId);\n // EntityUtils.consume(response.getEntity());\n String id1 = getIdFromResponse(response);\n response.close();\n\n response = createProject(\"testProjectName2\", userId);\n // EntityUtils.consume(response.getEntity());\n String id2 = getIdFromResponse(response);\n response.close();\n\n String missingId = \"1234\" + id1 + id2; // making sure the ID is not present\n\n response = getProject(userId, missingId);\n\n int status = response.getStatusLine().getStatusCode();\n Assert.assertEquals(404, status);\n\n EntityUtils.consume(response.getEntity());\n response.close();\n } finally {\n httpclient.close();\n }\n }", "public boolean isProjectOpen() {\n\t\treturn (projectFileIO != null);\n\t}", "boolean hasCloudRunConfig();", "default void showChanges() {\n\t\tthrow new UnsupportedVersionControlSystemSupportException();\n\t}", "@Test\n void shouldThrowExceptionWhenProjectWithGivenProjectNameDoesNotExists() {\n assertThrows(NotFoundException.class, () -> projectService.findProjectByProjectName(\"non-existing\"));\n }", "protected Availability availabilitySpringBootCommand() throws IOException {\n\t\tString str = \"O diretório de trabalho não é um projeto 'Spring Boot' válido. Use o comando 'use' para alterar o projeto de trabalho.\";\n\t\treturn workspace.isSpringBootProject() || workspace.isSpringBootNgProject() ? Availability.available() : Availability.unavailable(str);\n\t}", "public boolean isIdExist(int projectId) throws EmployeeManagementException;", "@Override\n\t\tpublic boolean isValidSolution() {\n\t\t\treturn super.isValidSolution();\n\t\t}", "public void testOk() throws Exception {\n assertEquals(\"No warnings.\", lintProject(manifest().minSdk(1), mTitles));\n }", "public InvalidProjectTypeException () {\r\n \t\tsuper();\r\n \t}", "private void handleTargetMiss() {\n\t\tthrow new UnsupportedOperationException(\n\t\t\t\t\"No responsible perspective found. Handling not implemented yet.\");\n\t}", "private static void notPossible () {\r\n\t\tSystem.out.println(\"This operation is not possible\");\r\n\t}", "@Test\n public void testAircraftPartNoNotApplicable787() throws Exception {\n\n String lTaskApplSqlLdesc = \"rootpart.part_no_oem <> 787\";\n\n // verify on wing engine 777 is applicable\n int lResult = execute( ON_WING_ENGINE_777, lTaskApplSqlLdesc );\n assertEquals( 1, lResult );\n\n // verify on wing engine 787 is not applicable\n lResult = execute( ON_WING_ENGINE_787, lTaskApplSqlLdesc );\n assertEquals( 0, lResult );\n\n // verify off wing engine is applicable\n lResult = execute( OFF_WING_ENGINE, lTaskApplSqlLdesc );\n assertEquals( 1, lResult );\n }", "public boolean hasAtLeastOneReference(Project project);", "public boolean performOk() {\n\t\ttry {\n\t\t\tProjectAdapter projectAdapter = getProjectAdapter();\n\t\t\tif (projectAdapter != null) {\n\t\t\t\tBuildProperties buildProperties = getBuildProperties();\n\t\t\t\tbuildProperties.setCustomInfoPListContent(_customInfoPListText.getText());\n\t\t\t\tbuildProperties.setServletDeployment(_servletDeploymentCheck.getSelection());\n\t\t\t\tbuildProperties.setWebXML(_generateWebXMLCheck.getSelection());\n\t\t\t\tbuildProperties.setWebXML_CustomContent(_customWebXMLText.getText());\n\n\t\t\t\tProjectFrameworkAdapter projectFrameworkAdapter = getProjectFrameworkAdapter();\n\t\t\t\tif (buildProperties.isServletDeployment()) {\n\t\t\t\t\tprojectFrameworkAdapter.addFrameworkNamed(\"JavaWOJSPServlet\");\n\t\t\t\t} else {\n\t\t\t\t\tprojectFrameworkAdapter.removeFrameworkNamed(\"JavaWOJSPServlet\");\n\t\t\t\t}\n\n\t\t\t\tfor (Root root : _embedButtons.keySet()) {\n\t\t\t\t\tButton embedButton = _embedButtons.get(root);\n\t\t\t\t\tboolean embed = buildProperties.isServletDeployment() || (embedButton.isEnabled() && embedButton.getSelection());\n\t\t\t\t\tbuildProperties.setEmbed(root, embed);\n\t\t\t\t}\n\n\t\t\t\tbuildProperties.setJavaClient(_javaClientButton.getSelection());\n\t\t\t\tbuildProperties.setJavaWebStart(_javaClientButton.getSelection() && _javaWebStartButton.getSelection());\n\t\t\t\tbuildProperties.save();\n\t\t\t}\n\t\t} catch (Exception up) {\n\t\t\tUIPlugin.getDefault().log(up);\n\t\t\treturn false;\n\t\t}\n\t\treturn true;\n\t}", "default boolean isAvailable(@Nonnull PsiFile file) {\n return true;\n }", "boolean hasCompatibilityState();", "protected abstract boolean isMigrationNecessary();", "public abstract boolean manipulateRepositories();", "private synchronized void verifyVariantsWithProblems() {\r\n\t\tthreadInExecId.remove(Thread.currentThread().getId());\r\n\t\tif (threadInExecId.isEmpty()) {\r\n\t\t\tfinal Display display = Display.getDefault();\r\n\t\t\tif (display == null) {\r\n\t\t\t\tthrow new NullPointerException(\"Display is null\");\r\n\t\t\t}\r\n\t\t\tdisplay.syncExec(new Runnable() {\r\n\t\t\t\tpublic void run() {\r\n\t\t\t\t\tInvalidProductViewController invalidProductViewController = InvalidProductViewController\r\n\t\t\t\t\t\t\t.getInstance();\r\n\t\t\t\t\tinvalidProductViewController.showInvalidProduct();\r\n\r\n\t\t\t\t\tif (!ProjectConfigurationErrorLogger.getInstance()\r\n\t\t\t\t\t\t\t.getProjectsList().isEmpty()) {\r\n\t\t\t\t\t\tList<InvalidProductViewLog> logs = new LinkedList<InvalidProductViewLog>();\r\n\t\t\t\t\t\tfor (String s : ProjectConfigurationErrorLogger\r\n\t\t\t\t\t\t\t\t.getInstance().getProjectsList()) {\r\n\t\t\t\t\t\t\tlogs.add(new InvalidProductViewLog(s));\r\n\t\t\t\t\t\t\tSystem.out.println(s);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\tinvalidProductViewController.adaptTo(logs\r\n\t\t\t\t\t\t\t\t.toArray(new InvalidProductViewLog[logs.size()]));\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\t// Clear view\r\n\t\t\t\t\t\tinvalidProductViewController.clear();\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t}\r\n\r\n\t\t\t});\r\n\r\n\t\t}\r\n\r\n\t}", "public boolean isUndoAvailable() throws ProvisioningException {\n return StateHistoryUtils.isUndoAvailable(home, log);\n }", "public void uiVerifyButtonUndoExist() {\n try {\n getLogger().info(\"Verify button Undo Todo exist.\");\n btnToDoUndo.getAttribute(\"class\");\n NXGReports.addStep(\"Verify button Undo Todo exist.\", LogAs.PASSED, null);\n } catch (Exception ex) {\n getLogger().info(ex);\n AbstractService.sStatusCnt++;\n NXGReports.addStep(\"verify button Undo Todo exist.\", LogAs.FAILED, new CaptureScreen(CaptureScreen.ScreenshotOf.BROWSER_PAGE));\n }\n }", "@Override\n\tpublic boolean isWorking(Role role, RoleBuild build) {\n\t\treturn false;\n\t}", "boolean hasUknown();", "private InternalFuture<Void> checkPermission(\n List<String> runIds, ModelDBActionEnum.ModelDBServiceActions action) {\n final var finalRunIds = runIds.stream().filter(s -> !s.isEmpty()).collect(Collectors.toList());\n if (finalRunIds.isEmpty()) {\n return InternalFuture.failedStage(\n new InvalidArgumentException(\"Experiment run IDs is missing\"));\n }\n\n var futureMaybeProjectIds =\n jdbi.withHandle(\n handle -> {\n try (var findQuery =\n handle.createQuery(\n \"SELECT project_id FROM experiment_run WHERE id IN (<ids>) AND deleted=:deleted\")) {\n return findQuery\n .bindList(\"ids\", finalRunIds)\n .bind(\"deleted\", 0)\n .mapTo(String.class)\n .list();\n }\n });\n\n return futureMaybeProjectIds.thenCompose(\n maybeProjectIds -> {\n if (maybeProjectIds.isEmpty()) {\n throw new NotFoundException(\"Project ids not found for given experiment runs\");\n }\n\n switch (action) {\n case DELETE:\n // TODO: check if we should using DELETE for the ER itself\n return getEntityPermissionBasedOnResourceTypes(\n maybeProjectIds,\n ModelDBActionEnum.ModelDBServiceActions.UPDATE,\n ModelDBServiceResourceTypes.PROJECT)\n .thenAccept(\n allowed -> {\n if (!allowed) {\n throw new PermissionDeniedException(ModelDBMessages.PERMISSION_DENIED);\n }\n },\n executor);\n default:\n return getEntityPermissionBasedOnResourceTypes(\n maybeProjectIds, action, ModelDBServiceResourceTypes.PROJECT)\n .thenAccept(\n allowed -> {\n if (!allowed) {\n throw new PermissionDeniedException(ModelDBMessages.PERMISSION_DENIED);\n }\n },\n executor);\n }\n },\n executor);\n }", "public void testJellyCompatibility() {\n try {\n assertTrue(\"SettingChildren class is public\", Modifier.isPublic(SettingChildren.class.getModifiers()));\n assertTrue(\"FileStateProperty class is public\", Modifier.isPublic(FileStateProperty.class.getModifiers()));\n try {\n new FileStateProperty(\"Modules-Layer\").getValue();\n } catch (NullPointerException npe) {}\n } catch (Exception e) {\n throw new AssertionFailedErrorException(\"JellyTools compatibility conflict, please contact QA or any JellyTools developer.\", e);\n }\n }", "public Project getProject(int projectId) throws EmployeeManagementException;", "@Override\n\tprotected void checkHardware() {\n\t\tsuper.checkHardware();\n\t}", "@Test\n void shouldThrowExceptionWhenUpdatedProjectWithTheEnteredUuidDoesNotExists() {\n assertThrows(NotFoundException.class, () -> projectService.updateProject(UUID.randomUUID(), projectUpdateForm));\n }" ]
[ "0.64552337", "0.6070144", "0.57539696", "0.57466084", "0.56822157", "0.5660121", "0.56209475", "0.560205", "0.56012815", "0.55882275", "0.5587505", "0.5536509", "0.55218023", "0.54927814", "0.5424886", "0.54048884", "0.5386012", "0.53713053", "0.5343062", "0.5333321", "0.5320295", "0.5290751", "0.52835983", "0.52835983", "0.528246", "0.52658963", "0.525145", "0.52277476", "0.5193672", "0.5185969", "0.5184848", "0.51712555", "0.51543653", "0.5153455", "0.514656", "0.51375496", "0.513536", "0.5134207", "0.51329106", "0.5119962", "0.5111546", "0.51066464", "0.5096711", "0.5088629", "0.50805676", "0.5079362", "0.50764513", "0.50654846", "0.50598025", "0.504996", "0.50450546", "0.5044985", "0.50373286", "0.5035612", "0.50308114", "0.5022138", "0.50218445", "0.50182474", "0.5008928", "0.500357", "0.49956065", "0.49947926", "0.49930972", "0.497784", "0.49714017", "0.49621785", "0.49477866", "0.4931879", "0.49316862", "0.49308446", "0.49083546", "0.4907935", "0.49034372", "0.49028143", "0.4902064", "0.4900837", "0.49002475", "0.48800886", "0.4877125", "0.48741865", "0.4869963", "0.48690307", "0.48670766", "0.48644966", "0.486092", "0.48604903", "0.48472092", "0.4844025", "0.48431858", "0.48429978", "0.48408425", "0.4833891", "0.4833571", "0.4832645", "0.48287925", "0.48216978", "0.48199537", "0.48183185", "0.48146188", "0.4812203", "0.48115772" ]
0.0
-1
Load version history for file
private void loadHistory(VssFile vssFile) { if(config.useComApi) { getVss().getComApiFileHistory(vssFile); } else { File historyFile = getVss().getFileHistory(vssFile); VssHistoryParser p = new VssHistoryParser(config); p.parseFileHistory(historyFile, vssFile); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private static void readHistoryData()\n throws FileNotFoundException {\n File file = new File(HISTORY_FILE_PATH);\n Scanner scanner = new Scanner(file); // create a Scanner using the File as the source\n StringBuilder message = new StringBuilder();\n int index = 1;\n while (scanner.hasNext()) {\n String line = scanner.nextLine();\n message.append(\"\\n\\t\" + index + \". \" + line);\n index++;\n }\n scanner.close();\n\n history = message.toString();\n }", "private void loadHistory(VssProject vssProject) {\r\n if (!incrementalWarning)\r\n checkDirHistory(vssProject);\r\n\r\n for (Iterator i = vssProject.getFiles().iterator(); i.hasNext();) {\r\n VssFile file = (VssFile) i.next();\r\n loadHistory(file);\r\n }\r\n for (Iterator i = vssProject.getSubprojects().iterator(); i.hasNext();) {\r\n VssProject project = (VssProject) i.next();\r\n loadHistory(project);\r\n }\r\n }", "public OperatorSelectionHistory loadHistory(String filename){\n OperatorSelectionHistory history = null;\n try(ObjectInputStream is = new ObjectInputStream( new FileInputStream( filename ))){\n history = (OperatorSelectionHistory)is.readObject();\n } catch (IOException ex) {\n Logger.getLogger(IOSelectionHistory.class.getName()).log(Level.SEVERE, null, ex);\n } catch (ClassNotFoundException ex) {\n Logger.getLogger(IOSelectionHistory.class.getName()).log(Level.SEVERE, null, ex);\n }\n return history;\n }", "void findHistory(File f,IvyXmlWriter xw)\n{\n StringCommand cmd = new StringCommand(cvs_command + \" log \" + getRelativePath(f));\n String rslt = cmd.getContent();\n\n StringTokenizer tok = new StringTokenizer(rslt,\"\\n\");\n String rev = null;\n Date d = null;\n String auth = null;\n String msg = null;\n BvcrFileVersion prior = null;\n Collection<BvcrFileVersion> fvs = new ArrayList<BvcrFileVersion>();\n String headversion = null;\n\n while (tok.hasMoreTokens()) {\n String ln = tok.nextToken();\n if (rev == null) {\n\t if (ln.startsWith(\"revision \")) rev = ln.substring(9).trim();\n\t else if (ln.startsWith(\"head: \")) {\n\t headversion = ln.substring(6);\n\t }\n }\n else {\n\t if (ln.startsWith(\"date: \")) {\n\t StringTokenizer ltok = new StringTokenizer(ln,\";\");\n\t while (ltok.hasMoreTokens()) {\n\t String itm = ltok.nextToken();\n\t int idx = itm.indexOf(\":\");\n\t if (idx >= 0) {\n\t\t String what = itm.substring(0,idx).trim();\n\t\t String cnts = itm.substring(idx+1).trim();\n\t\t if (what.equals(\"date\")) {\n\t\t try {\n\t\t\td = CVS_DATE.parse(cnts);\n\t\t }\n\t\t catch (ParseException e) { }\n\t\t }\n\t\t else if (what.equals(\"author\")) auth = cnts;\n\t\t}\n\t }\n\t }\n\t else if (ln.startsWith(\"----------------------------\") ||\n\t\t ln.startsWith(\"===================================================\")) {\n\t if (auth != null && d != null) {\n\t BvcrFileVersion fv = new BvcrFileVersion(f,rev,d,auth,msg);\n\t if (headversion != null && headversion.equals(rev)) {\n\t\t fv.addAlternativeName(\"HEAD\");\n\t\t}\n\t if (prior != null) prior.addPriorVersion(fv);\n\t prior = fv;\n\t fvs.add(fv);\n\t }\n\t rev = null;\n\t d = null;\n\t msg = null;\n\t auth = null;\n\t }\n\t else if (msg == null) msg = ln;\n\t else msg = msg + \"\\n\" + ln;\n }\n }\n\n xw.begin(\"HISTORY\");\n xw.field(\"FILE\",f.getPath());\n for (BvcrFileVersion fv : fvs) {\n fv.outputXml(xw);\n }\n xw.end(\"HISTORY\");\n}", "private static ArrayList<String> fetchHistory() {\n\t\tScanner s;\n\t\tint count = 0;\n\t\tArrayList<String> historyList = new ArrayList<String>();\n\t\ttry {\n\t\t\ts = new Scanner(new File(\"History.txt\"));\n\t\t\twhile (s.hasNext()) {\n\t\t\t\thistoryList.add(s.next());\n\t\t\t\tcount += 1;\n\t\t\t}\n\t\t\tSystem.out.println(\"Number of converted urls fetched: \" + count);\n\t\t\ts.close();\n\t\t} catch (FileNotFoundException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn historyList;\n\t}", "public void loadHistory(SyncedList<MSensor> history) {\n this.history = history;\n }", "private static void addToHistory() {\n\t\tFileInputStream fis = null;\n\t\tFileOutputStream fos = null;\n\t\tFileChannel resultChannel = null;\n\t\tFileChannel historyChannel = null;\n\t\ttry {\n\t\t\tfis = new FileInputStream(new File(\"result.txt\"));\n\t\t\tfos = new FileOutputStream(new File(\"history.txt\"), true);\n\t\t\t\n\t\t\tfos.write(\"\\n\\n\".getBytes(\"utf-8\"));\n\t\t\tfos.flush();\n\t\t\t\n\t\t\tresultChannel = fis.getChannel();\n\t\t\thistoryChannel = fos.getChannel();\n\n\t\t\tresultChannel.transferTo(0, resultChannel.size(), historyChannel);\n\t\t} catch (FileNotFoundException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t} catch (IOException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t} finally {\n\t\t\ttry {\n\t\t\t\tif (fis != null) {\n\t\t\t\t\tfis.close();\n\t\t\t\t}\n\t\t\t\tif (fos != null) {\n\t\t\t\t\tfos.close();\n\t\t\t\t}\n\t\t\t\tif(resultChannel != null) {\n\t\t\t\t\tresultChannel.close();\n\t\t\t\t}\n\t\t\t\tif(historyChannel != null) {\n\t\t\t\t\thistoryChannel.close();\n\t\t\t\t}\n\t\t\t} catch (IOException e) {\n\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t}", "public void storeFileHistory() {\n\t\ttheFileHistory.store(theConfiguration);\n\t}", "private void parsePreviousChangeVersion(final String line, final CVSChangeLogSet.File file, final CVSChangeLog change,\n final Map<String, String> branches, final List<CVSChangeLog> changes,\n final Map<String, CvsFile> files, final CvsRepositoryLocation location,\n final EnvVars envVars) {\n if (!line.startsWith(\"revision\")) {\n throw new IllegalStateException(\"Unexpected line from CVS log: \" + line);\n }\n\n final String revision = line.substring(9);\n file.setPrevrevision(revision);\n\n saveChange(file, change, branches, changes, files, location, envVars);\n\n file.setRevision(revision);\n }", "List<HistoryData> loadAllHistoryData();", "default void loadRevisionFileDataIntoMemory(AsyncCache<Integer, RevisionFileData> cache) {\n if (!cache.asMap().isEmpty()) {\n return;\n }\n\n final UberPage uberPage;\n if (exists()) {\n final Reader reader = createReader();\n final PageReference firstRef = reader.readUberPageReference();\n uberPage = (UberPage) firstRef.getPage();\n\n final var revisionNumber = uberPage.getRevisionNumber();\n final var revisionNumbers = new ArrayList<Integer>(revisionNumber);\n\n for (int i = 1; i <= revisionNumber; i++) {\n revisionNumbers.add(i);\n }\n\n cache.getAll(revisionNumbers, keys -> {\n final Map<Integer, RevisionFileData> result = new HashMap<>();\n keys.forEach(key -> result.put(key, reader.getRevisionFileData(key)));\n reader.close();\n return result;\n });\n }\n }", "public void loadRecentPaneFiles() {\r\n // create streams\r\n \r\n boolean exists = (new File(fileWithFileListOfPaneRecentFiles)).exists();\r\nif (exists) {\r\n \r\n try {\r\n // open the file containing the stored list of recent files\r\n FileInputStream input = new FileInputStream(fileWithFileListOfPaneRecentFiles);\r\n \r\n //create reader stream\r\n BufferedReader recentsReader= new BufferedReader(new InputStreamReader(input));\r\n\r\n recentPaneFiles.clear(); // clear the Vector of recent files\r\n String currentLine; // refill it from disk\r\n while ((currentLine = recentsReader.readLine()) != null)\r\n if (recentPaneFiles.indexOf(currentLine) == -1) // file not already in list\r\n recentPaneFiles.add(currentLine);\r\n\r\n recentsReader.close();\r\n input.close();\r\n updateRecentPaneFilesMenu(); // update the recent files menu\r\n\r\n }\r\n catch(java.io.IOException except)\r\n {\r\n System.out.println(\"IO exception in readRecentsFiles. File: \"+fileWithFileListOfPaneRecentFiles+\" not found\");\r\n recentPaneFilesMenu.removeAll(); // clear previous menu items\r\n clearRecentFilesJMenuItem = new JMenuItem(\"Clear the list of recent files\");\r\n clearRecentFilesJMenuItem.addActionListener(new ActionListener() {\r\n\r\n public void actionPerformed(ActionEvent e) {\r\n recentPaneFiles.clear();\r\n recentPaneFilesMenu.removeAll();\r\n }\r\n });\r\n\r\n recentPaneFilesMenu.add(clearRecentFilesJMenuItem);\r\n mainJMenuBar.add(recentPaneFilesMenu); // finally add the recent files menu to the main menu bar\r\n \r\n }\r\n }\r\n }", "@Override\n\tpublic void readAGBVersionsWithLineNumbers() {\n\t\t\n\t\tString lineVersion1 = null;\n\t\tString lineVersion2 = null;\n\t\t\n\t\ttry \n\t\t{\n BufferedReader br1 = new BufferedReader(new FileReader(\"AGB1-SelectedVersion.txt\"));\n \n while ((lineVersion1 = br1.readLine()) != null) \n {\n \tversion1WithLineNumbers.add(lineVersion1);\n //System.out.println(line);\n }\n } \n\t\tcatch (IOException e) \n\t\t{\n e.printStackTrace();\n }\n\t\t\n\t\ttry \n\t\t{\n BufferedReader br2 = new BufferedReader(new FileReader(\"AGB2-SelectedVersion.txt\"));\n \n while ((lineVersion2 = br2.readLine()) != null) \n {\n \tversion2WithLineNumbers.add(lineVersion2);\n //System.out.println(line);\n }\n } \n\t\tcatch (IOException e) \n\t\t{\n e.printStackTrace();\n }\n\t\t\n\t\t\n\t}", "private static List<UserData> getLastCommittedPageVersions() throws IOException {\n File transactionDir = new File(\"logdata\");\n\n File[] files = transactionDir.listFiles();\n\n if (files == null) {\n System.out.println(\"error reading logdata files\");\n System.exit(1);\n }\n\n //all committed transaction ids\n List<Integer> committedTransactionIds = new ArrayList<>();\n\n //first collect committed transaction ids\n for (File file : files) {\n int LSN = Integer.parseInt(file.getName());\n\n //read the first line of the page file\n BufferedReader reader = new BufferedReader(new FileReader(file));\n String[] contentParts = reader.readLine().split(\",\");\n\n //only collect committed transaction ids\n if (Objects.equals(contentParts[1], \"commit\")) {\n committedTransactionIds.add(Integer.parseInt(contentParts[0]));\n }\n }\n\n HashMap<Integer, UserData> map = new HashMap<>();\n //now collect the last page contents for each page\n for (File file : files) {\n int LSN = Integer.parseInt(file.getName());\n\n //read the first line of the page file\n BufferedReader reader = new BufferedReader(new FileReader(file));\n String[] contentParts = reader.readLine().split(\",\");\n\n //ignore commits\n if (!Objects.equals(contentParts[1], \"commit\")) {\n int transactionId = Integer.parseInt(contentParts[0]);\n int pageId = Integer.parseInt(contentParts[1]);\n\n //only consider committed transactions\n if (committedTransactionIds.contains(transactionId)) {\n\n if (map.containsKey(pageId)) {\n //check if current file has newer version\n if (map.get(pageId).getLSN() < LSN) {\n map.put(pageId, new UserData(pageId, contentParts[2], LSN));\n }\n } else {\n map.put(pageId, new UserData(pageId, contentParts[2], LSN));\n }\n }\n }\n }\n return new ArrayList<>(map.values());\n }", "public static ArrayList create_history(String file) throws IOException {\n todos.clear();\n file_reader = new FileReader(file);\n buffered_reader = new BufferedReader(file_reader);\n String line;\n String todo_string = \"\";\n\n while ((line = buffered_reader.readLine()) != null){\n if (!line.equals(\";\")){\n todo_string += line;\n }\n else{\n parse_todo(todo_string);\n todo_string = \"\";\n }\n }\n return todos;\n }", "public FileHistory getFileHistory() {\n\t\treturn theFileHistory;\n\t}", "public long load(Map<Token,Long> revisions) throws IOException {\n long rev = -1;\n \n readBytes(13);\n readHeader(buffer);\n version = readVersion(buffer);\n int bufferSize = buffer.getInt();\n\n ByteBuffer uncompressedBuffer = ByteBuffer.allocate(bufferSize);\n byte[] compressedBuffer = new byte[bufferSize];\n \n int compressedLength = 0;\n while ((compressedLength = readCompressedChunk(compressedBuffer)) != 0) {\n \n // uncompress the chunk\n uncompressedBuffer.clear();\n int size = Snappy.uncompress(compressedBuffer, 0, compressedLength, uncompressedBuffer.array(), 0);\n uncompressedBuffer.position(size);\n uncompressedBuffer.flip();\n \n // load the database from the uncompressed buffer\n while (uncompressedBuffer.hasRemaining()) {\n Storable s = readType(uncompressedBuffer);\n if (s == revision) {\n revision.deserialize(uncompressedBuffer, version);\n rev = revision.getValue();\n continue;\n }\n \n Long expirationTime = null;\n if (s == expires) {\n expires.deserialize(uncompressedBuffer, version);\n expirationTime = expires.getExpires();\n s = readType(uncompressedBuffer);\n }\n \n Token key = new Token();\n key.deserialize(uncompressedBuffer, version);\n \n Model model = (Model) s;\n model.deserialize(uncompressedBuffer, version);\n if (expirationTime != null) {\n model.setExpirationTime(expirationTime);\n }\n Database.put(key, model);\n revisions.put(key, rev);\n }\n }\n \n return rev;\n }", "private ResponseEntity<Resource> downloadFileHistory(final String fileName,\n final String version,\n final String file) {\n\n // load the specified file as a resource\n Resource resource = storageMutator.loadFileAsResourceHistory(fileName, version, file);\n String contentType = \"application/octet-stream\";\n\n // create a response with the content type, header and body with the file data\n return ResponseEntity.ok()\n .contentType(MediaType.parseMediaType(contentType))\n .header(HttpHeaders.CONTENT_DISPOSITION,\n \"attachment; filename=\\\"\" + resource.getFilename() + \"\\\"\")\n .body(resource);\n }", "public static History loadFromXML(String fileName) throws FileNotLoadedException {\n\t\ttry {\n\t\tJAXBContext context = JAXBContext.newInstance(History.class);\n\t\tUnmarshaller unmarshaller = context.createUnmarshaller();\n\t\t\n\t\t// Read from file\n\t\tHistory history = (History) unmarshaller.unmarshal(new File(fileName));\t\t\n\t\t\n\t\treturn history;\n\t\t} catch (JAXBException e) {\n\t\t\tSystem.err.println(e + \"/nFile not loaded!\");\n throw new FileNotLoadedException();\n\t\t} catch (IllegalArgumentException e) {\n\t\t\tSystem.err.println(\"File not found. Check that a file with the name '\" + fileName + \"' exists!\");\n throw new FileNotLoadedException();\n\t\t}\t\n\t}", "public void testViewHistory() throws Exception {\n System.out.print(\".. Testing history information of a file ..\");\n String filesystem = \"VSS \" + workingDirectory + File.separator + \"Work\";\n Node filesystemNode = new Node(new ExplorerOperator().repositoryTab().getRootNode(), filesystem);\n Node A_FileNode = new Node( filesystemNode, \"A_File [Current]\");\n new Action(VERSIONING_MENU + \"|\" + HISTORY, HISTORY).perform(A_FileNode);\n MainWindowOperator.getDefault().waitStatusText(\"Command History finished.\");\n VCSCommandsOutputOperator outputWindow = new VCSCommandsOutputOperator(\"History\");\n outputWindow.btClose();\n Thread.sleep(5000);\n String currentContents = outputWindow.txtStandardOutput().getText();\n outputWindow.close();\n String goldenContents = \"History of $/A_File.java ...\\n\\n***************** Version 2 *****************\\nUser: \" + userName + \" Date:\";\n if (currentContents.indexOf(goldenContents) < 0) captureScreen(\"Error: Incorrect history contents. Golden: |\" + goldenContents + \"|\" + currentContents + \"|\");\n goldenContents = \"Checked in $/\\nComment: Three lines have changed.\\n\\n***************** Version 1 *****************\\nUser: \" + userName + \" Date\";\n if (currentContents.indexOf(goldenContents) < 0) captureScreen(\"Error: Incorrect history contents. Golden: |\" + goldenContents + \"|\" + currentContents + \"|\");\n goldenContents = \"Created\\nComment: Generated A_File class.\\n\";\n if (currentContents.indexOf(goldenContents) < 0) captureScreen(\"Error: Incorrect history contents. Golden: |\" + goldenContents + \"|\" + currentContents + \"|\");\n new Action(VERSIONING_MENU + \"|\" + PROPERTIES, PROPERTIES).perform(A_FileNode);\n MainWindowOperator.getDefault().waitStatusText(\"Command Properties finished.\");\n outputWindow = new VCSCommandsOutputOperator(\"Properties\");\n outputWindow.btClose();\n Thread.sleep(5000);\n currentContents = outputWindow.txtStandardOutput().getText();\n outputWindow.close();\n goldenContents = \"File: $/A_File.java\\nType: Text\\nSize: 91 bytes 5 lines\\nStore only latest version: No\\nLatest: \\n Version: 2 \\n Date:\";\n if (currentContents.indexOf(goldenContents) < 0) captureScreen(\"Error: Incorrect properties contents. Golden: |\" + goldenContents + \"|\" + currentContents + \"|\");\n goldenContents = \"Comment: Generated A_File class.\";\n if (currentContents.indexOf(goldenContents) < 0) captureScreen(\"Error: Incorrect properties contents. Golden: |\" + goldenContents + \"|\" + currentContents + \"|\");\n System.out.println(\". done !\");\n }", "@Test\r\n public void testRevision() {\r\n InputStream inputstream = getClass().getClassLoader().getResourceAsStream(\"sample.json\");\r\n assert inputstream != null;\r\n Reader reader = new InputStreamReader(inputstream);\r\n JsonParser parser = new JsonParser();\r\n JsonElement rootElement = parser.parse(reader);\r\n\r\n RevisionParser revisionParser = new RevisionParser();\r\n List<Revision> revisionList = revisionParser.parse(rootElement);\r\n\r\n for (Revision r: revisionList) {\r\n System.out.println(r);\r\n }\r\n Assert.assertEquals(revisionList.get(0).toString(), \"Name: Monkbot\tTimeStamp: Fri Sep 13 11:10:41 EDT 2019\");\r\n }", "public void showVersionHistory(ArrayList<Version> versions)\n\t{\n\t\tfor(int i=0; i<versions.size(); i++)\n\t\t{\n\t\t\tshowVersionHistory(versions.get(i));\n\t\t}\n\t}", "TrackerHistory loadTrackerHistory(final Integer id);", "@Override\n public List<Number> getRevisionHistory(Long id) {\n return null;\n }", "public HistoryGraph() {\n revisions = new HashSet<Revision>();\n orderedRevisions = new ArrayList<Revision>();\n }", "public void fileReadGameHistory(String filename)\n {\n \t//ArrayList<GameObject> gameObject = new ArrayList<>();\n\t\tFileReader file = null;\n\t\ttry {\n\t\t\tfile = new FileReader(filename);\n\t\t} catch (FileNotFoundException e) {\n\n\t\t\te.printStackTrace();\n\t\t}\n\t\tSystem.out.println(filename);\n\t\tBufferedReader br = new BufferedReader(file);\n\t\tString s = \"\";\n\t\ttry\n\t\t{\n\t\t\twhile((s = br.readLine()) != null )\n\t\t\t{\n\t\t\t\tString[] prop1 = s.split(\"#\");\n\t\t\t\tSystem.out.println(prop1[0] + \" fgdfsgfds \" + prop1[1]);\n\t\t\t\tString indexOfList = prop1[0];\n\t\t\t\tString[] prop2 = prop1[1].split(\",\");\n\t\t\t\tString[] prop3;\n\t\t\t\tString[] prop4 = indexOfList.split(\";\");\n\t\t\t\t//gameObject.add(new GameObject(indexOfList));\n\t\t\t\tcount = count +1;\n\t\t\t\texistCount = existCount + 1;\n\t\t\t\tif (indexOfList.charAt(0) == 's')//when this line is data of a swimming game\n\t\t\t\t{\n\t\t\t\t\tSystem.out.println(prop4[0]);\n\t\t\t\t\tgames.add(new Swimming(prop4[1],\"Swimming\",prop4[0]));\n\t\t\t\t\tfor(int i = 0; i < Array.getLength(prop2); i++)\n\t\t\t\t\t{\n\t\t\t\t\t\tprop3 = prop2[i].split(\":\");\n\t\t\t\t\t\tgames.get(count - 1).addParticipant(prop3[0], Integer.parseInt(prop3[1]), 0);\n//\t\t\t\t\t\tgames.get(count-1).getResults().get(i).setId(prop3[0]);\n//\t\t\t\t\t\tgames.get(count-1).getResults().get(i).setRe(Integer.parseInt(prop3[1]));\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (indexOfList.charAt(0) == 'c')//when this line is data of a cycling game\n\t\t\t\t{\n\t\t\t\t\tgames.add(new Cycling(prop4[1],\"Cycling\",prop4[0]));\n\t\t\t\t\tfor(int i = 0; i < Array.getLength(prop2); i++)\n\t\t\t\t\t{\n\t\t\t\t\t\tprop3 = prop2[i].split(\":\");\n\t\t\t\t\t\tgames.get(count - 1).addParticipant(prop3[0], Integer.parseInt(prop3[1]), 0);\n//\t\t\t\t\t\tgames.get(count-1).getResults().get(i).setId(prop3[0]);\n//\t\t\t\t\t\tgames.get(count-1).getResults().get(i).setRe(Integer.parseInt(prop3[1]));\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (indexOfList.charAt(0) == 'r')//when this line is data of a running game\n\t\t\t\t{\n\t\t\t\t\tgames.add(new Running(prop4[1],\"Running\",prop4[0]));\n\t\t\t\t\tfor(int i = 0; i < Array.getLength(prop2); i++)\n\t\t\t\t\t{\n\t\t\t\t\t\tprop3 = prop2[i].split(\":\");\n\t\t\t\t\t\tgames.get(count - 1).addParticipant(prop3[0], Integer.parseInt(prop3[1]), 0);\n//\t\t\t\t\t\tgames.get(count-1).getResults().get(i).setId(prop3[0]);\n//\t\t\t\t\t\tgames.get(count-1).getResults().get(i).setRe(Integer.parseInt(prop3[1]));\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}catch (NumberFormatException | IOException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n }", "public void restore() {\n\t\ttry {\n\t\t\tFile latest = null;\n\t\t\t// restore the last file back into memory\n\t\t\tList<File> files = FindFile.find(getName(), \"shouts.*.js\", false, false);\n\n\t\t\tfor (int i = 0; i < files.size(); ++i) {\n\t\t\t\tFile f = files.get(i);\n\t\t\t\tif (latest == null) {\n\t\t\t\t\tlatest = f;\n\t\t\t\t}\n\t\t\t\tif (f.lastModified() > latest.lastModified()) {\n\t\t\t\t\tlatest = f;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif (latest == null) {\n\t\t\t\tlog.info(\"no files found to restore\");\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tinfo(\"loading latest file %s\", latest);\n\n\t\t\tString json = String.format(\"[%s]\", FileIO.fileToString(latest.getAbsoluteFile()));\n\n\t\t\tShout[] saved = Encoder.fromJson(json, Shout[].class);\n\n\t\t\tfor (int i = 0; i < saved.length; ++i) {\n\t\t\t\tshouts.add(saved[i]);\n\t\t\t}\n\n\t\t} catch (Exception e) {\n\t\t\tLogging.logError(e);\n\t\t}\n\t}", "public void getOldFile() throws FileNotFoundException, IOException, ClassNotFoundException{\r\n\t\tObjectInputStream ois = new ObjectInputStream(new FileInputStream(\"agenda.txt\"));\r\n\t\tArrayList<Artist> inputArtists = (ArrayList<Artist>) ois.readObject();\r\n\t\tArrayList<Stage> inputStages = (ArrayList<Stage>) ois.readObject();\r\n\t\tArrayList<Performance> inputPerformances = (ArrayList<Performance>) ois.readObject();\r\n\t\tartists.addAll(inputArtists);\r\n\t\tstages.addAll(inputStages);\r\n\t\tperformances.addAll(inputPerformances);\r\n\t}", "private void checkDirHistory(VssProject project) {\r\n try {\r\n File dirHistory = getVss().getDirHistory(project);\r\n BufferedReader r = Util.openReader(dirHistory, config.getLogEncoding());\r\n try {\r\n String s;\r\n while ((s = r.readLine()) != null) {\r\n if (s.endsWith(\" recovered\")\r\n || s.endsWith(\" destroyed\")\r\n || s.endsWith(\" branched\")\r\n || s.endsWith(\" shared\")\r\n || s.indexOf(\" renamed to \") != -1\r\n ) {\r\n incrementalWarning = true;\r\n break;\r\n }\r\n }\r\n } finally {\r\n r.close();\r\n }\r\n } catch (IOException e) {\r\n throw new VssException(e);\r\n }\r\n }", "TrackerListVersion loadTrackerListVersion(final Integer id);", "public Map<String,List<RevisionFile>> getSourceFiles();", "public void saveHistory() {\r\n\t\tJFileChooser jfc = new JFileChooser();\r\n\t\tjfc.setFileSelectionMode(JFileChooser.FILES_ONLY);\r\n\t\tjfc.setDialogTitle(\"Save \" + curveName + \" history\");\r\n\t\tjfc.setSelectedFile(new File(\".txt\"));\r\n\t\tint returnVal = jfc.showSaveDialog(getRootPane());\r\n\t\tif(returnVal == JFileChooser.APPROVE_OPTION) {\r\n\t\t\tif (!cancelBecauseFileExist(jfc.getSelectedFile())) {\r\n\t\t\t\ttry {\r\n\t\t\t\t\thistory.save(jfc.getSelectedFile());\r\n\t\t\t\t} catch (IOException e) {\r\n\t\t\t\t\tJOptionPane.showMessageDialog(getRootPane(), \"Error while saving the history\", \"Error\", JOptionPane.ERROR_MESSAGE);\r\n\t\t\t\t\te.printStackTrace();\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}", "public void reload() {\n\t\tif (file.lastModified() <= fileModified)\n\t\t\treturn;\n\t\n\t\treadFile();\n\t}", "public List<String[]> readStockHistory(String path) throws IOException {\r\n\t\tFileReader fileReader = null;\r\n\t\tCSVReader csvReader = null;\r\n\t\tList<String[]> stockRecordList = null;\r\n\t\ttry {\r\n\t\t\tfileReader = new FileReader(path);\r\n\t\t\tcsvReader = new CSVReader(fileReader);\r\n\t\t\tstockRecordList = csvReader.readAll();\r\n\t\t} finally {\r\n\t\t\tif (csvReader!=null) { \r\n\t\t\t\tcsvReader.close();\r\n\t\t\t}\r\n\t\t\tif (fileReader!=null) { \r\n\t\t\t\tfileReader.close();\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn stockRecordList;\r\n\t}", "private History() {}", "public File getFileRevision(SVNUrl repoUrl, SVNUrl url, String revision, String pegRevision, String fileName) throws IOException {\n boolean canUseRevisionsCache = true;\n try {\n canUseRevisionsCache = SVNRevision.getRevision(revision).getKind() == SVNRevision.Kind.number\n && SVNRevision.getRevision(pegRevision).getKind() == SVNRevision.Kind.number;\n } catch (ParseException ex) {\n }\n try {\n Context context = new Context(VCSFileProxy.createFileProxy(fileSystem.getRoot()));\n if (!canUseRevisionsCache || \"false\".equals(System.getProperty(\"versioning.subversion.historycache.enable\", \"true\"))) { //NOI18N\n SvnClient client = Subversion.getInstance().getClient(context, repoUrl);\n InputStream in = getInputStream(client, url, revision, pegRevision);\n return createContent(fileName, in);\n } else {\n String rootUrl = repoUrl.toString();\n String resourceUrl = url.toString() + \"@\" + pegRevision; //NOI18N\n Storage cachedVersions = StorageManager.getInstance().getStorage(rootUrl);\n File cachedFile = cachedVersions.getContent(resourceUrl, fileName, revision);\n if (cachedFile.length() == 0) { // not yet cached\n SvnClient client = Subversion.getInstance().getClient(context, repoUrl);\n InputStream in = getInputStream(client, url, revision, pegRevision);\n cachedFile = createContent(fileName, in);\n if (cachedFile.length() != 0) {\n cachedVersions.setContent(resourceUrl, revision, cachedFile);\n }\n }\n return cachedFile;\n }\n } catch (SVNClientException ex) {\n throw new IOException(\"Can not load: \" + url + \" in revision: \" + revision, ex); //NOI18N\n }\n }", "public static void loadHistoricalStats(Player player) throws FileNotFoundException {\n historicalStatsReader = new BufferedReader(new FileReader(\"src/main/resources/stats/historicalstats.txt\"));\n try {\n player.getHistoricalStats().setWins(Integer.parseInt(historicalStatsReader.readLine()));\n player.getHistoricalStats().setLosses(Integer.parseInt(historicalStatsReader.readLine()));\n player.getHistoricalStats().setGamesPlayed(Integer.parseInt(historicalStatsReader.readLine()));\n player.getHistoricalStats().setTimePlayed(Integer.parseInt(historicalStatsReader.readLine()));\n player.getHistoricalStats().setKills(Integer.parseInt(historicalStatsReader.readLine()));\n player.getHistoricalStats().setGamesLeft(Integer.parseInt(historicalStatsReader.readLine()));\n\n } catch (IOException ex) {\n Logger.getLogger(StatsLoader.class.getName()).log(Level.SEVERE, \"Cannot find specificed stats file\", ex);\n }\n }", "private void readHistoricalData() {\n /*\n r4 = this;\n r1 = r4.mInstanceLock;\n monitor-enter(r1);\n r0 = r4.mCanReadHistoricalData;\t Catch:{ all -> 0x0028 }\n if (r0 == 0) goto L_0x000b;\n L_0x0007:\n r0 = r4.mHistoricalRecordsChanged;\t Catch:{ all -> 0x0028 }\n if (r0 != 0) goto L_0x000d;\n L_0x000b:\n monitor-exit(r1);\t Catch:{ all -> 0x0028 }\n L_0x000c:\n return;\n L_0x000d:\n r0 = 0;\n r4.mCanReadHistoricalData = r0;\t Catch:{ all -> 0x0028 }\n r0 = 1;\n r4.mReadShareHistoryCalled = r0;\t Catch:{ all -> 0x0028 }\n r0 = r4.mHistoryFileName;\t Catch:{ all -> 0x0028 }\n r0 = android.text.TextUtils.isEmpty(r0);\t Catch:{ all -> 0x0028 }\n if (r0 != 0) goto L_0x0026;\n L_0x001b:\n r0 = SERIAL_EXECUTOR;\t Catch:{ all -> 0x0028 }\n r2 = new com.actionbarsherlock.widget.ActivityChooserModel$HistoryLoader;\t Catch:{ all -> 0x0028 }\n r3 = 0;\n r2.<init>();\t Catch:{ all -> 0x0028 }\n r0.execute(r2);\t Catch:{ all -> 0x0028 }\n L_0x0026:\n monitor-exit(r1);\t Catch:{ all -> 0x0028 }\n goto L_0x000c;\n L_0x0028:\n r0 = move-exception;\n monitor-exit(r1);\t Catch:{ all -> 0x0028 }\n throw r0;\n */\n throw new UnsupportedOperationException(\"Method not decompiled: com.actionbarsherlock.widget.ActivityChooserModel.readHistoricalData():void\");\n }", "public synchronized String getHistory() {\r\n\t\tString log = new String();\r\n\t\ttry {\r\n\t\t\tFile logFile = new File(\"serverlogs.log\");\r\n\t\t\tBufferedReader logReader = new BufferedReader(new InputStreamReader(new FileInputStream(logFile)));\r\n\t\t\tString line;\r\n\t\t\twhile((line = logReader.readLine()) != null) {\r\n\t\t\t\tlog += (line + \"\\n\");\r\n\t\t\t}\r\n\t\t\tlogReader.close();\r\n\t\t} catch (IOException e) {\r\n\t\t\tgui.acknowledge(\"Error : logs are not available\");\r\n\t\t\tstop();\r\n\t\t}\r\n\t\tif(log.equals(\"\\n\")) {\r\n\t\t\tlog = new String();\r\n\t\t}\r\n\t\treturn log;\r\n\t}", "public BuildHistory(){\n buildHistory = new ArrayList<Build>();\n }", "public void showVersionHistory(Version version)\n\t{\n\t\tArrayList<Description> descriptions = version.getListDescriptions();\n\t\t\n\t\t// Show version\n\t\ttextAreaVersions.append(\"Version \" + version.getVersion() + \":\");\n\t\ttextAreaVersions.append(\"\\n\");\n\t\t\n\t\t// Show version descriptions\n\t\tfor(int i=0; i<descriptions.size(); i++)\n\t\t{\n\t\t\ttextAreaVersions.append(\"- \" + descriptions.get(i).getDescription());\n\t\t\ttextAreaVersions.append(\"\\n\");\n\t\t}\n\t\t\n\t\ttextAreaVersions.append(\"\\n\");\n\t}", "private static HashMap<Integer, Integer> getLastPageVersions() throws IOException {\n File transactionDir = new File(\"userdata\");\n\n File[] files = transactionDir.listFiles();\n\n if (files == null) {\n System.out.println(\"error reading userdata files\");\n System.exit(1);\n }\n\n //maps PageId to LSN\n HashMap<Integer, Integer> map = new HashMap<>();\n\n for (File file : files) {\n int pageId = Integer.parseInt(file.getName());\n\n //read the first line of the page file\n BufferedReader reader = new BufferedReader(new FileReader(file));\n String content = reader.readLine();\n\n int lsn = Integer.parseInt(content.split(\",\")[0]);\n map.put(pageId, lsn);\n }\n return map;\n }", "@Override\n\tpublic void onCreate(Bundle savedInstanceState)\n\t{\n\t\tsuper.onCreate(savedInstanceState);\n\n\t\ttry {\n\t\t\tpstate = PersistentState.load(new InputStreamReader(openFileInput(\"history.txt\"), \"UTF-8\"));\n\t\t} catch (FileNotFoundException x) {\n\t\t} catch (UnsupportedEncodingException x) {\n\t\t\tLog.e(\"LunchFundActivity\", \"onCreate\", x);\n\t\t}\n\t\tif (pstate == null)\n\t\t\tpstate = new PersistentState();\n\t\tpstate.clearModified();\n\n\t\tif (getResources().getConfiguration().orientation == Configuration.ORIENTATION_LANDSCAPE)\n\t\t\tsetContentView(R.layout.landscape);\n\t\telse\n\t\t\tsetContentView(R.layout.main);\n\t\tredraw();\n\t}", "void replaceWithHEADRevision(Collection<ChangedFile> changedFiles);", "public RecordSet loadExpHistoryInfo(Record inputRecord);", "@SuppressWarnings(\"unused\") \n public void testBigFile() {\n URL resource = getResource(\"/junit-stats.xml\"); // a big file\n String folder = \"\\\\\\\\dev1\\\\c$\\\\tcs_build\\\\archive\";\n long originalLastModified = getOrginalFileLastModified(resource);\n HistoricalTestStatisticsFileManager manager = new HistoricalTestStatisticsFileManager(folder, resource.getFile(), Long.MAX_VALUE);\n verifyRevisionsLoaded(manager, 65);\n verifyRevisionListSize(manager, 65);\n List<String> orginalRevisionList = manager.getRevisionList();\n manager.run();\n assertEquals(\"you didn't clone the list correctly\", 65, orginalRevisionList.size());\n List<String> updatedRevisionList = manager.getRevisionList();\n File updatedFile = new File(resource.getFile());\n assertTrue(\"failed to update the file\", updatedFile.lastModified() != originalLastModified); \n }", "private void loadFromFile() {\n\t\ttry {\n\t\t\tFileInputStream fis = openFileInput(FILENAME);\n\t\t\tBufferedReader in = new BufferedReader(new InputStreamReader(fis));\n\t\t\tString line = in.readLine();\n\t\t\tGson gson = new Gson();\n\t\t\twhile (line != null) {\n\t\t\t\tCounterModel counter = gson.fromJson(line, CounterModel.class);\n\t\t\t\tif (counterModel.getCounterName().equals(counter.getCounterName())) {\n\t\t\t\t\tcounterListModel.addCounterToList(counterModel);\n\t\t\t\t\tcurrentCountTextView.setText(Integer.toString(counterModel.getCount()));\n\t\t\t\t} else {\n\t\t\t\t\tcounterListModel.addCounterToList(counter);\n\t\t\t\t}\n\t\t\t\tline = in.readLine();\n\t\t\t} \n\t\t\tfis.close();\n\t\t} catch (FileNotFoundException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t} catch (IOException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t}", "public void loadWorkflow(String filename);", "public synchronized void readLog() {\n MemoryCache instance = MemoryCache.getInstance();\n try (Stream<String> stream = Files.lines(Paths.get(path)).skip(instance.getSkipLine())) {\n stream.forEach(s -> {\n Result result = readEachLine(s);\n instance.putResult(result);\n instance.setSkipLine(instance.getSkipLine() + 1);\n });\n } catch (IOException e) {\n logger.error(\"error during reading file \" + e.getMessage());\n }\n }", "public Load(String[] args) {\n\n\t\ttry {\n\t\t\tRandomAccessFile raf = new RandomAccessFile(new File(args[0]), \"rw\");\n\t\t\tthis.sfMap = raf.getChannel();\n\t\t\tthis.stataFile = sfMap.map(FileChannel.MapMode.READ_WRITE, 0, sfMap.size());\n\t\t\tthis.fileHeader = checkVersion(this.stataFile);\n\t\t\tif (this.release >= 113 && this.release <= 115) {\n\t\t\t\tthis.headerData = OldFormats.readHeader(stataFile, fileHeader);\n\t\t\t} else {\n\t\t\t\tthis.headerData = NewFormats.readHeader(stataFile, fileHeader);\n\t\t\t}\n\t\t\tparseHeader();\n\t\t\tif (this.release == 118) {\n\t\t\t\tthis.versionedFile = FileFormats.getVersion(this.sfMap, this.release,\n\t\t\t\t\t\tthis.endian, this.K, (Long) this.headerData.get(3),\n\t\t\t\t\t\tthis.datasetLabel, this.datasetTimeStamp, this.mapOffset);\n\t\t\t} else {\n\t\t\t\tthis.versionedFile = FileFormats.getVersion(this.sfMap, this.release,\n\t\t\t\t\t\tthis.endian, this.K, (Integer) this.headerData.get(3),\n\t\t\t\t\t\tthis.datasetLabel, this.datasetTimeStamp, this.mapOffset);\n\t\t\t}\n\t\t} catch (IOException | DtaCorrupt e) {\n\t\t\tSystem.out.println(String.valueOf(e));\n\t\t}\n\n\t}", "public static void loadDictionaryByVersion(String versionkey)\r\n\t{\r\n\t\tSyntaxDictionary dic = getDictionaryByVersion(versionkey);\r\n\t\t\r\n\t\tif(dic == null){\r\n\t\t\tthrow new IllegalArgumentException(\"Problem loading version node \"+versionkey+\" from dictionaryconfig.xml\");\r\n\t\t}\r\n\t\t//add finally add them to the cache\r\n\t\taddDictionaryToCache(versionkey, dic);\r\n\t}", "private JMenuItem createLoadHistoryMenuItem() {\r\n\t\tJMenuItem loadHistory = new JMenuItem(\"Load History\");\r\n\t\tloadHistory.setMnemonic('l');\r\n\t\tloadHistory.setVisible(true);\r\n\t\tloadHistory.addActionListener(new ActionListener() {\r\n\t\t\tpublic void actionPerformed(ActionEvent e) {\r\n\t\t\t\t// stop animation temporarily if it was on\r\n\t\t\t\tVariable animateVar = Variable\r\n\t\t\t\t\t\t.getVariable(Grapher2DConstants.Grapher2DAnimateFlag);\r\n\t\t\t\tanimateVar.set(new BooleanValue(false));\r\n\r\n\t\t\t\t// load the script\r\n\t\t\t\tExpressionConsoleHistory history = ActionScriptLoadUtilities\r\n\t\t\t\t\t\t.promptUserToLoadScript();\r\n\r\n\t\t\t\tMap<String, String> initialSymbolTable = history\r\n\t\t\t\t\t\t.getInitialSymbolTableSnapshot();\r\n\r\n\t\t\t\tMap<String, Variable> currentSymbolTable = Variable\r\n\t\t\t\t\t\t.getSymbolTable();\r\n\r\n\t\t\t\tExpressionConsoleModel console = ExpressionConsoleModel\r\n\t\t\t\t\t\t.getInstance();\r\n\r\n\t\t\t\tRecursiveDescentParser parser = console.getParser();\r\n\r\n\t\t\t\t// initialize the symbol table\r\n\t\t\t\tfor (Iterator<Entry<String, Variable>> it = currentSymbolTable\r\n\t\t\t\t\t\t.entrySet().iterator(); it.hasNext();) {\r\n\t\t\t\t\tEntry<String, Variable> currentEntry = it.next();\r\n\t\t\t\t\tString newValue = initialSymbolTable.get(currentEntry\r\n\t\t\t\t\t\t\t.getKey());\r\n\t\t\t\t\tString expressionToEvaluate = currentEntry.getKey() + \" = \"\r\n\t\t\t\t\t\t\t+ (newValue == null ? \"0\" : newValue);\r\n\t\t\t\t\tparser.parse(expressionToEvaluate).evaluate();\r\n\t\t\t\t}\r\n\r\n\t\t\t\t// step through all events\r\n\t\t\t\tList<ExpressionConsoleHistoryEntry> historyList = history\r\n\t\t\t\t\t\t.getExpressionList();\r\n\r\n\t\t\t\tfor (Iterator<ExpressionConsoleHistoryEntry> it = historyList\r\n\t\t\t\t\t\t.iterator(); it.hasNext();) {\r\n\t\t\t\t\tExpressionConsoleHistoryEntry currentEntry = it.next();\r\n\t\t\t\t\tif (currentEntry.getType() == ExpressionConsoleHistoryEntry.INPUT)\r\n\t\t\t\t\t\tconsole.enterExpression(currentEntry.getString());\r\n\t\t\t\t}\r\n\r\n\t\t\t\t// restart animation if it was on before\r\n\t\t\t\t// animateVar.set(oldAnimateValue);\r\n\t\t\t}\r\n\t\t});\r\n\r\n\t\treturn loadHistory;\r\n\t}", "@Override\n public void updateHistory(Command c) {\n }", "public void updateFrom(int age) {\n\t\tif(age == -1) {\n\t\t\tupdateVersion();\n\t\t\treturn;\n\t\t}\n\t\t//Version 0.4 and later stuff\n\t\tif(age <= 1) {\n\t\t\tlog.info(\"Version 0.4 of FirstLastSeen contained a bug affecting only Unix based servers, there may have been some data duplication.\");\n\t\t}\n\t\t//Version 0.5 and later stuff\n\t\tif(age <= 2) {\n\t\t\tString[] updateStr = new String[5];\n\n\t\t\tprop.clear();\n\t\t\tFileInputStream updatein;\n\t\t\ttry {\n\t\t\t\tupdatein = new FileInputStream(language);\n\t\t\t\tprop.load(updatein);\n\t\t\t\tupdatein.close();\n\t\t\t} catch (FileNotFoundException ex) {\n\t\t\t\tex.printStackTrace();\n\t\t\t} catch (IOException ex) {\n\t\t\t\tex.printStackTrace();\n\t\t\t}\n\n\t\t\tupdateStr[0] = prop.getProperty(\"norecordfor\");\n\t\t\tupdateStr[1] = prop.getProperty(\"norecord\");\n\t\t\tupdateStr[2] = prop.getProperty(\"firstseen\");\n\t\t\tupdateStr[3] = prop.getProperty(\"lastseen\");\n\t\t\tupdateStr[4] = \"Welcome <player> to the server!\";\n\n\t\t\tprop.clear();\n\t\t\ttry {\n\t\t\t\tlanguage.createNewFile();\n\t\t\t\tFileOutputStream out = new FileOutputStream(language);\n\t\t\t\tprop.put(\"norecordfor\", updateStr[0]);\n\t\t\t\tprop.put(\"norecord\", updateStr[1]);\n\t\t\t\tprop.put(\"firstseen\", updateStr[2]);\n\t\t\t\tprop.put(\"lastseen\", updateStr[3]);\n\t\t\t\tprop.put(\"firstseennotify\", updateStr[4]);\n\t\t\t\tprop.store(out, \"Loaclization.\");\n\t\t\t\tout.flush();\n\t\t\t\tout.close();\n\t\t\t} catch (IOException ex) {\n\t\t\t\tex.printStackTrace();\n\t\t\t}\n\t\t\tlog.info(\"Version 0.6 of FirstLastSeen adds a new line in the language file for when a player first joins the server!\");\n\t\t\tlog.info(\"Simply set it to an empty string to disable this feature.\");\n\t\t}\n\t\tif(age <= 3) {\n\t\t\tlog.info(\"FirstLastSeen can now support color codes in the lang file!\");\n\t\t}\n\t\tupdateVersion();\n\t}", "private synchronized void loadHistoricData(StockData sd)\r\n {\r\n debug(\"loadHistoricData(\" + sd.getSymbol().getDataSz() + \") called - \");\r\n if (DEMO_MODE)\r\n {\r\n debug(\"loadHistoricData() - is considered to be refreshed - DEMO_MODE\");\r\n }\r\n else\r\n {\r\n\r\n String fileName = getString(\"WatchListTableModule.edit.historic_details_basic_name\") + sd.getSymbol().getDataSz();\r\n //Spawn a new thread on the Util event Thread as to provide a smooth transition\r\n //into our new thread proicessing.and to Load Historic Stock Data\r\n HistoricStockDataLoaderTask downloadTask = new HistoricStockDataLoaderTask(sd);\r\n Timer timer = new Timer(true); // Deamon\r\n timer.schedule(downloadTask, ONE_SECOND);\r\n\r\n if (DEBUG)\r\n {\r\n System.out.println(\"Results from: \" + sd);\r\n System.out.println(\"StockData[\" + sd.getSymbol().getDataSz() + \"] = \" + sd);\r\n }\r\n }\r\n\r\n }", "@NonNull\n static ChangeRecords load(File file) throws IOException {\n ChangeRecords changeRecords = new ChangeRecords();\n List<String> rawRecords = Files.readLines(file, Charsets.UTF_8);\n for (String rawRecord : rawRecords) {\n StringTokenizer st = new StringTokenizer(rawRecord, \",\");\n if (st.countTokens() != 2) {\n throw new IOException(\"Invalid incremental change record : \" + rawRecord);\n }\n changeRecords.add(Status.valueOf(st.nextToken()), st.nextToken());\n }\n return changeRecords;\n }", "public abstract long getRevision(int lineNumber);", "@Override\n public void addLoadHistoryHeader(boolean showLoader) throws RemoteException {\n }", "public static void loadFileHash(String path) throws IOException{\n\t\t\n\t\tHashMap<String, List<String>> map = new HashMap<String, List<String>>();\n BufferedReader in = new BufferedReader(new FileReader(path));\n String line = \"\";\n while ((line = in.readLine()) != null) {\n String parts[] = line.split(\":\");\n List<String> docIdLen = new ArrayList<String>();\n docIdLen.add(parts[1]);\n docIdLen.add(parts[2]);\n map.put(parts[0], docIdLen);\n }\n in.close();\n \n printDocHash(map);\n\t}", "public UpdateHistory() {\n this(\"update_history\", null);\n }", "private void ifHistoryContains( String not, String version ) {\r\n\t\tboolean c = dbVersion.logContains( version );\r\n\t\tif( not != null ) {\r\n\t\t\tc = !c;\r\n\t\t}\r\n\t\tcontext.skip( !c );\r\n\t}", "public void loadState() throws IOException, ClassNotFoundException {\n\t\tFile f = new File(workingDirectory() + File.separator + id() + FILE_EXTENSION);\n\t\t\n\t\t// load client state from file\n\t\tObjectInputStream is = new ObjectInputStream(new FileInputStream(f));\n\t\tTrackerDaemon client = (TrackerDaemon) is.readObject();\n\t\tis.close();\n\t\t\n\t\t// copy attributes\n\t\tthis.peerRecord = client.peerRecord();\n\t\t\n\t}", "public String getHistory () {\r\n\t\treturn history;\r\n\t}", "public String getHistory () {\r\n\t\treturn history;\r\n\t}", "private void reloadData() throws IOException\n {\n /* Reload data from file, if it is modified after last scan */\n long mtime = loader.getModificationTime();\n if (mtime < lastKnownMtime) {\n return;\n }\n lastKnownMtime = mtime;\n\n InputStream in = loader.getInputStream();\n BufferedReader bin = new BufferedReader(new InputStreamReader(in));\n cache.clear();\n String line;\n while ((line = bin.readLine()) != null) {\n try {\n Map<String, Object> tuple = reader.readValue(line);\n updateLookupCache(tuple);\n } catch (JsonProcessingException parseExp) {\n logger.info(\"Unable to parse line {}\", line);\n }\n }\n IOUtils.closeQuietly(bin);\n IOUtils.closeQuietly(in);\n }", "public static String getVersion() {\n\n try {\n //Open file\n ClassLoader classLoader = new ResourceLoader().getClass().getClassLoader();\n File file = new File(classLoader.getResource(RELEASE_NOTES).getFile());\n //Read File Content\n String content = new String(Files.readAllBytes(file.toPath()));\n content = content.split(\"VERSION \")[1]; //version number comes after VERSION\n content = content.split(\"\\n\")[0]; //and before the next new line\n return content;\n } catch (IOException ex) {\n Logger.getLogger(ResourceLoader.class.getName()).log(Level.SEVERE, null, ex);\n return null;\n }\n\n }", "public void reload(String filename) throws IOException, RemoteException, Error;", "@Override\n public List<RevisionMetadata> getRevisionHistoryMetadata(Object id) {\n return null;\n }", "@Override\n public void loadState(@Nonnull Element element) {\n final Element state = element.clone();\n StartupManager.getInstance(myProject).runWhenProjectIsInitialized((DumbAwareRunnable)() -> {\n for (Element e : state.getChildren(HistoryEntry.TAG)) {\n try {\n addEntry(HistoryEntry.createHeavy(myProject, e));\n }\n catch (InvalidDataException | ProcessCanceledException e1) {\n // OK here\n }\n catch (Exception anyException) {\n LOG.error(anyException);\n }\n }\n trimToSize(UISettings.getInstance());\n });\n }", "public void updateHistoTabs(boolean readFromFiles, boolean rebuildTrails) {\r\n\t\tupdateHistoTabs(readFromFiles ? RebuildStep.B_HISTOVAULTS : rebuildTrails ? RebuildStep.C_TRAILRECORDSET : RebuildStep.E_USER_INTERFACE, true);\r\n\t}", "private void loadLegitimateFollowers(String l_file) {\n\t\tL = new ArrayList<String>();\n\t\t\n\t\tFile inFile = new File(l_file);\n\n\t\tif (!inFile.isFile()) {\n\t\t\tSystem.out.println(\"Parameter is not an existing file\");\n\t\t\treturn;\n\t\t}\n\n\t\tBufferedReader br = null;\n\t\ttry {\n\t\t\tbr = new BufferedReader(new FileReader(l_file));\n\t\t} catch (FileNotFoundException e1) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te1.printStackTrace();\n\t\t}\n\n\t\tString line = null;\n\n\t\t//Read from the original file and write to the new\n\t\t//unless content matches data to be removed.\n\t\ttry {\n\t\t\twhile ((line = br.readLine()) != null) {\n\t\t\t\tString[] followers = line.split(\",\");\n\t\t\t\tthis.L.add(followers[0]);\n\t\t\t}\n\t\t\tbr.close();\n\t\t} catch (IOException e) {\n\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t}", "protected Modification handleEntry(List historyEntry) {\n // Ignore unusual labels of directories which cause parsing errors that \n // look like this:\n //\n // ***** built *****\n // Version 4\n // Label: \"autobuild_test\"\n // User: Etucker Date: 6/26/01 Time: 11:53a\n // Labeled\n if ((historyEntry.size() > 4) && \n (((String) historyEntry.get(4)).startsWith(\"Labeled\"))) {\n return null;\n }\n \n \t\tModification mod = new Modification();\n String nameAndDateLine = (String) historyEntry.get(2);\n \t\tmod.userName = parseUser(nameAndDateLine);\n \t\tmod.modifiedTime = parseDate(nameAndDateLine);\n \n String folderLine = (String) historyEntry.get(0);\n String fileLine = (String) historyEntry.get(3);\n \t\tif (fileLine.startsWith(\"Checked in\")) {\n \t\t\tmod.type = \"checkin\";\n \t\t\tmod.comment = parseComment(historyEntry);\n \t\t\tmod.fileName = folderLine.substring(7, folderLine.indexOf(\" *\"));\n \t\t\tmod.folderName = fileLine.substring(12);\n \t\t} else if (fileLine.endsWith(\"Created\")) {\n mod.type = \"create\";\n } else {\n \t\t\tmod.folderName = folderLine.substring(7, folderLine.indexOf(\" *\"));\n int lastSpace = fileLine.lastIndexOf(\" \");\n if ( lastSpace != -1 ) {\n mod.fileName = fileLine.substring(0, lastSpace);\n } else {\n mod.fileName = fileLine;\n }\n \n if (fileLine.endsWith(\"added\")) {\n \t\t\t\tmod.type = \"add\";\n \t\t\t} else if (fileLine.endsWith(\"deleted\")) {\n \t\t\t\tmod.type = \"delete\";\n \t\t\t} else if (fileLine.endsWith(\"recovered\")) {\n \t\t\t\tmod.type = \"recover\";\n \t\t\t} else if (fileLine.endsWith(\"shared\")) {\n mod.type = \"branch\";\n }\n \t\t}\n \n \t\tif (_propertyOnDelete != null && \"delete\".equals(mod.type)) {\n _properties.put(_propertyOnDelete, \"true\");\n \t\t}\n \n if (_property != null) {\n \t\t_properties.put(_property, \"true\");\n }\n \n return mod;\n \t}", "public BuildHistory(ArrayList<Build> buildHistory) {\n this.buildHistory = buildHistory;\n }", "public String getHistory () {\n\t\treturn history;\n\t}", "private void updateHistory() {\n if(isHistoryUpdated == false) {\n preloader.launch();\n final Timer networkTimeoutTimer = new Timer();\n networkTimeoutTimer.schedule(new TimerTask() {\n @Override\n public void run() {\n ChatActivity.this.runOnUiThread(new Runnable() {\n @Override\n public void run() {\n preloader.done();\n showNetWorkAlertDialog();\n }\n });\n }\n }, 15000);\n textViewTop.setText(currDialogObject.name);\n ImageLoader.getInstance().displayImage(currDialogObject.avatarUrl, imageAvatar);\n int dialogId = currDialogObject.dialogId;\n SocketWorker.getInstance().getDialogHistory(dialogId, new IOAcknowledge() {\n @Override\n public void ack(Object... args) {\n networkTimeoutTimer.cancel();\n final JSONObject ackJson = (JSONObject) args[0];\n ChatActivity.this.runOnUiThread(new Runnable() {\n public void run() {\n if (GlobalHelper.successStatusFromJson(ackJson, true, null)) {\n parseHistory(ackJson);\n\n } else {\n networkTimeoutTimer.cancel();\n preloader.cancel(getString(R.string.error), getString(R.string.message_network_error));\n }\n }\n });\n }\n });\n }\n\t}", "private void loadFromFile() {\n try {\n /* Load in the data from the file */\n FileInputStream fIn = openFileInput(FILENAME);\n BufferedReader inRead = new BufferedReader(new InputStreamReader(fIn));\n\n /*\n * access from the GSON file\n * Taken from lonelyTwitter lab code\n */\n Gson gson = new Gson();\n Type listType = new TypeToken<ArrayList<Counter>>() {}.getType();\n counters = gson.fromJson(inRead, listType);\n\n } catch (FileNotFoundException e) {\n counters = new ArrayList<Counter>();\n } catch (IOException e) {\n throw new RuntimeException(e);\n }\n }", "public interface Revision extends Comparable<Revision> {\n \n /**\n * Compares the revision to the given version string. Behaves like\n * {@link Comparable#compareTo(Object)}.\n */\n public int compareTo(String version);\n \n /**\n * Returns a string representation of the version of this revision. The\n * version is used by {@link #compareTo(String)} as well as to\n * serialize/deserialize revision information. Therefore it must be self\n * descriptive as well as be able to identify one revision from another.\n */\n public String getVersion();\n \n /**\n * Returns the files that comprise this revision, as a mapping from a source\n * to a list of files.\n */\n public Map<String,List<RevisionFile>> getSourceFiles();\n \n /**\n * Returns an {@link IndexInput} for the given fileName and source. It is the\n * caller's responsibility to close the {@link IndexInput} when it has been\n * consumed.\n */\n public InputStream open(String source, String fileName) throws IOException;\n \n /**\n * Called when this revision can be safely released, i.e. where there are no\n * more references to it.\n */\n public void release() throws IOException;\n \n}", "private void loadFromFile(){\n try {\n FileInputStream fis = openFileInput(FILENAME);\n BufferedReader in = new BufferedReader(new InputStreamReader(fis));\n Gson gson = new Gson();\n Type listType = new TypeToken<ArrayList<Countbook>>() {}.getType();\n countbookList = gson.fromJson(in, listType);\n } catch (FileNotFoundException e) {\n countbookList = new ArrayList<Countbook>();\n }\n }", "public static void clearHistoryData() {\n try {\n clearFile(HISTORY_FILE_PATH);\n } catch (Exception e) {\n StorageSavingException exception = new StorageSavingException(e);\n Ui.printExceptionMessage(exception);\n }\n }", "public ScriptHistory getScriptHistory() {\n return scriptHistory;\n }", "private void persistHistoricalData() {\n /*\n r4 = this;\n r1 = r4.mInstanceLock;\n monitor-enter(r1);\n r0 = r4.mReadShareHistoryCalled;\t Catch:{ all -> 0x000f }\n if (r0 != 0) goto L_0x0012;\n L_0x0007:\n r0 = new java.lang.IllegalStateException;\t Catch:{ all -> 0x000f }\n r2 = \"No preceding call to #readHistoricalData\";\n r0.<init>(r2);\t Catch:{ all -> 0x000f }\n throw r0;\t Catch:{ all -> 0x000f }\n L_0x000f:\n r0 = move-exception;\n monitor-exit(r1);\t Catch:{ all -> 0x000f }\n throw r0;\n L_0x0012:\n r0 = r4.mHistoricalRecordsChanged;\t Catch:{ all -> 0x000f }\n if (r0 != 0) goto L_0x0018;\n L_0x0016:\n monitor-exit(r1);\t Catch:{ all -> 0x000f }\n L_0x0017:\n return;\n L_0x0018:\n r0 = 0;\n r4.mHistoricalRecordsChanged = r0;\t Catch:{ all -> 0x000f }\n r0 = 1;\n r4.mCanReadHistoricalData = r0;\t Catch:{ all -> 0x000f }\n r0 = r4.mHistoryFileName;\t Catch:{ all -> 0x000f }\n r0 = android.text.TextUtils.isEmpty(r0);\t Catch:{ all -> 0x000f }\n if (r0 != 0) goto L_0x0031;\n L_0x0026:\n r0 = SERIAL_EXECUTOR;\t Catch:{ all -> 0x000f }\n r2 = new com.actionbarsherlock.widget.ActivityChooserModel$HistoryPersister;\t Catch:{ all -> 0x000f }\n r3 = 0;\n r2.<init>();\t Catch:{ all -> 0x000f }\n r0.execute(r2);\t Catch:{ all -> 0x000f }\n L_0x0031:\n monitor-exit(r1);\t Catch:{ all -> 0x000f }\n goto L_0x0017;\n */\n throw new UnsupportedOperationException(\"Method not decompiled: com.actionbarsherlock.widget.ActivityChooserModel.persistHistoricalData():void\");\n }", "protected void loadFile(String s) {\n\t\tpush();\n\t\tfile.load(s, curves);\n\t\trecalculateCurves();\n\t\tpushNew();\n\t}", "private void loadSettings() {\n//\t\tSharedPreferences prefs = this.getSharedPreferences(Defs.PREFS_NAME, 0);\n//\t\t\n//\t\tString fileData = prefs.getString(Defs.PREFS_KEY_PREV_RATES_FILE, \"\");\n//\t\tLog.d(TAG, \"Loaded last \" + fileData);\n//\t\tif ( fileData.length() > 0 ) {\n//\t\t\tByteArrayInputStream bias = new ByteArrayInputStream(fileData.getBytes());\n//\t\t\t_oldRates = new ExchangeRate();\n//\t\t\tparseRates(bias, _oldRates);\n//\t\t}\n\t}", "private void refreshList() {\n setTitle(this.path.get(this.path.size() - 1));\n\n // Read all files sorted into the values-array\n values.clear();\n File dir = new File(this.path.get(this.path.size() - 1));\n if (!dir.canRead()) {\n setTitle(getTitle() + \" (inaccessible)\");\n }\n String[] list = dir.list();\n if (list != null) {\n for (String file : list) {\n if (!file.startsWith(\".\")) {\n values.add(file);\n }\n }\n }\n Collections.sort(values);\n }", "public void loadCache() {\n if (!directory.exists()) {\n directory.mkdirs();\n }\n File[] files = this.directory.listFiles();\n if (files == null) {\n return;\n }\n for (File file : files) {\n if (file.getName().endsWith(\".json\")) {\n cache.put(file.getName().split(\".json\")[0], new JsonDocument(file));\n }\n }\n }", "public static void status() {\n Set branchSet = commitPointers.readBranches().keySet();\n ArrayList<String> sortedBranches = (ArrayList) branchSet.stream().sorted().collect(Collectors.toList());\n String currBranch = commitPointers.readHeadCommit()[0];\n System.out.println(\"=== Branches ===\");\n for (String branch: sortedBranches) {\n if (currBranch.equals(branch)) {\n System.out.println(\"*\" + currBranch);\n } else {\n System.out.println(branch);\n }\n }\n stagingArea = Utils.readObject(STAGING_FILE, HashMap.class);\n\n ArrayList<String> sortedStaged = (ArrayList) stagingArea.keySet().stream().sorted().collect(Collectors.toList());\n System.out.println();\n System.out.println(\"=== Staged Files ===\");\n for (String staged : sortedStaged) {\n System.out.println(staged);\n }\n\n System.out.println();\n System.out.println(\"=== Removed Files ===\");\n stagingRemoveArea = Utils.readObject(STAGING_REMOVE_FILE, HashMap.class);\n ArrayList<String> sortedRemoved = (ArrayList) stagingRemoveArea.keySet().stream().sorted().collect(Collectors.toList());\n for (String removed : sortedRemoved) {\n System.out.println(removed);\n }\n System.out.println();\n\n System.out.println(\"=== Modifications Not Staged For Commit ===\");\n\n Commit Head = Utils.readObject(Utils.join(Commit.COMMIT_FOLDER, commitPointers.readHeadCommit()[1] + \".txt\"), Commit.class);\n //File blobs contains a SHAID + file name\n\n HashMap<String, String> modUntracked = new HashMap<>();\n\n //iterates through head Blobs\n for (HashMap.Entry<String, String> headfileBlob : Head.fileBlobs.entrySet()) {\n\n File cwdBFile = Utils.join(CWD, headfileBlob.getKey());\n\n if (!cwdBFile.exists() && !stagingRemoveArea.containsKey(headfileBlob.getKey())) {\n modUntracked.put(headfileBlob.getKey(), \"(deleted)\");\n }\n else if (cwdBFile.exists()){\n\n Blob tempBlob = new Blob(headfileBlob.getKey(), cwdBFile);\n String tempBlobId = Utils.sha1(Utils.serialize(tempBlob));\n\n\n if(!tempBlobId.equals(headfileBlob.getValue())) {\n //if not in staging area\n if (!stagingArea.containsKey(headfileBlob.getKey())) {\n modUntracked.put(headfileBlob.getKey(), \"(modified)\");\n }\n //TODO: IS THIS PART NECCESARY?\n else if (stagingArea.containsKey(headfileBlob.getKey()) && !stagingArea.get(headfileBlob.getKey()).equals(headfileBlob.getValue())) {\n modUntracked.put(headfileBlob.getKey(), \"(modified)\");\n }\n }\n }\n }\n\n ArrayList<String> sortedModNames = (ArrayList) modUntracked.keySet().stream().sorted().collect(Collectors.toList());\n for (String modFileName : sortedModNames){\n System.out.println(modFileName + \" \" + modUntracked.get(modFileName));\n }\n System.out.println();\n\n\n\n ArrayList<String> untracked = new ArrayList<>();\n System.out.println(\"=== Untracked Files ===\");\n for (String cwdfile : CWD.list()) {\n if(!cwdfile.equals(\".gitlet\")) {\n File currfile = Utils.join(CWD, cwdfile);\n if (currfile.exists() && !Head.fileBlobs.containsKey(cwdfile)) {\n untracked.add(cwdfile);\n }\n }\n }\n\n untracked = (ArrayList) untracked.stream().sorted().collect(Collectors.toList());\n\n for (String untrackedName : untracked){\n System.out.println(untrackedName);\n }\n }", "public SortedMap<String, File> download() {\n Set<String> versionsToCheck = getAvailableVersions();\n\n SortedMap<String, File> versionMap = new TreeMap<>(new VersionStringComparator());\n\n System.out.print(ansi().saveCursorPosition());\n\n int i = 1;\n for (String ver : versionsToCheck) {\n String filename = \"checkstyle-\" + ver + \".jar\";\n File f = new File(csBinaries, filename);\n if (!f.exists()) {\n if (print)\n System.out.print(ansi()\n .eraseLine()\n .restoreCursorPosition()\n .a(MessageFormat.format(res.getString(\"downloadprogmsg\"),\n i++, versionsToCheck.size(), ver)));\n try {\n FileUtils.copyURLToFile(new URL(res.getString(\"mavenCheckstyleURL\") + ver + \"/\" + filename), f);\n versionMap.put(ver, f);\n } catch (IOException e) {\n System.err.print(\"Failed: \");\n System.err.println(e.getMessage());\n System.err.println(\"Skipping...\");\n }\n } else {\n versionMap.put(ver, f);\n }\n }\n\n if (print)\n System.out.println();\n\n return versionMap;\n }", "public void readHistory()throws Exception {\n int currentline = 0;\n File myObj = new File(\"order_history.txt\");\n Scanner myReader = new Scanner(myObj);\n outputHistoryObj = new Order[1];\n while (myReader.hasNextLine()) {\n Pizza[] list = new Pizza[1];\n String[] commentparts = null; //This is superstitious, sorry\n String[] fullparts = myReader.nextLine().split(\" // \");\n String[] pizzaparts = fullparts[1].split(\" , \");\n for(int i=0; i<=pizzaparts.length-1; i++){\n if(pizzaparts[i].contains(\" & \")){\n commentparts = pizzaparts[i].split(\" & \");\n list[i] = new Pizza(Menu.list[Integer.parseInt(commentparts[0])-1].getName(), Menu.list[Integer.parseInt(commentparts[0])-1].getIngredients(), commentparts[1], Integer.parseInt(commentparts[0]), Menu.list[Integer.parseInt(commentparts[0])-1].getPrice());\n } else {\n list[i] = new Pizza(Menu.list[Integer.parseInt(pizzaparts[i])-1].getName(), Menu.list[Integer.parseInt(pizzaparts[i])-1].getIngredients(), \"\", Integer.parseInt(pizzaparts[i]), Menu.list[Integer.parseInt(pizzaparts[i])-1].getPrice());\n }\n list = Arrays.copyOf(list, list.length + 1); //Resize name array by one more\n }\n SimpleDateFormat format = new SimpleDateFormat(\"yyyy-MM-dd HH:mm:ss.SSS\");\n Date parsed = format.parse(fullparts[3]);\n java.sql.Timestamp timestamp = new java.sql.Timestamp(parsed.getTime());\n outputHistoryObj[currentline] = new Order(fullparts[0], Integer.parseInt(fullparts[2]), timestamp, list);\n outputHistoryObj = Arrays.copyOf(outputHistoryObj, outputHistoryObj.length + 1); //Resize name array by one more\n currentline++;\n }\n myReader.close();\n }", "long getCurrentRevision();", "long recalculateRevision();", "public static String getVersion() {\n\t\t String data = \"\";\n\t\ttry {\n\t\t File myObj = new File(rootdir+\"/version.txt\");\n\t Scanner myReader = new Scanner(myObj);\n\t while (myReader.hasNextLine()) {\n\t data = myReader.nextLine();\n\t break;\n\t }\n\t myReader.close();\n\t return data;\n\t } catch (FileNotFoundException e) {\n\t \tSystem.out.println(\"An error occurred.\");\n\t \te.printStackTrace();\n\t }\n\t\treturn null;\n\t}", "public void switchToHistory() {\r\n\t\thistoryPane.addEditTabs(editTabs);\r\n\t\tlayout.show(this, \"historyPane\");\r\n\t\trevalidate();\r\n\t\trepaint();\r\n\t}", "public void cache(){\n\t\t\n\t\t/*\n\t\t * second, check if there is a cache file\n\t\t * if yes, then check date\n\t\t * if no, then create a cache file \n\t\t*/\n\t\tif(cacheExist()){\n\t\t\t//check date and decide which file to update\n\t\t\tSystem.out.println(\" hahahaha, cache already there! \");\n\t\t\t\n\t\t\tFile cache = new File(\"./cache.txt\");\n\t\t\tsource = readFile(\"./cache.txt\",source);\n\t\t\tSystem.out.println(\"the size of source hashmap : \"+ source.size());\n\t\t\t\n\t\t\tfor(int i = 1; i < fileList.length;i++){\n\t\t\t\t//if this file need to be updated, write the data to source array\n\t\t\t\tif(needToUpdate(fileList[i], cache)){\n\t\t\t\t\tSimpleDateFormat sdf = new SimpleDateFormat(\"MM/dd/yyyy HH:mm:ss\");\n\t\t\t\t\tSystem.out.println(\"S: \"+ sdf.format(fileList[i].lastModified()) + \" c: \"+ sdf.format(cache.lastModified()));\n\t\t\t\t\tsource = readFile(fileList[i].getPath(), source);\n\t\t\t\t}\n\t\t\t}\n\t\t\t//after checking the whole source file and add the new data to source array\n\t\t\t//then sort the source array and write it to cache\n\t\t\tsort(source);\n\t\t\ttry\n\t\t\t{\n\t\t\t String filename= \"./cache.txt\";\n\t\t\t FileWriter fw = new FileWriter(filename,true); //the true will append the new data\n\t\t\t for(int j = 0; j < writeList.size(); j++){\n\t\t\t\t\tfw.write(writeList.get(j));\n\t\t\t\t}\n\t\t\t fw.close();\n\t\t\t}\n\t\t\tcatch(IOException ioe)\n\t\t\t{\n\t\t\t System.err.println(\"IOException: \" + ioe.getMessage());\n\t\t\t}\n\t\t\t\t\n\t\t}\n\t\t//there are is no cache, need to create a cache file\n\t\telse{\n\t\t\tSystem.out.println(\" create new cache file !\");\n\t\t\t//create cache file and copy sort the data from source file\n\t\t\t//1. read all the source file and store the data to an arrayList\n\t\t\tfor(int i = 1; i < fileList.length; i++){\n\t\t\t\tsource = readFile(fileList[i].getPath(), source);\t\t\t\n\t\t\t}\n\t\t\tsort(source);\n//\t\t\tSystem.out.println(source);\n\t\t\t\n\t\t\t//2.write the data to the cache file\n\t\t\tPrintWriter writer;\n\t\t\ttry {\n\t\t\t\twriter = new PrintWriter(\"cache.txt\", \"UTF-8\");\t\t\t\n\t\t\t\twriter.println(writeList.size());\n\t\t\t\tfor(int j = 0; j < writeList.size(); j++){\n\t\t\t\t\twriter.println(writeList.get(j));\n\t\t\t\t}\n\t\t\t\twriter.close();\n\t\t\t\t\n\t\t\t} catch (FileNotFoundException e) {\n\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\te.printStackTrace();\n\t\t\t} catch (UnsupportedEncodingException e) {\n\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t \n\t\t\n\t}", "public List getModifications(Date lastBuild, Date now) {\n //(PENDING) extract buildHistoryCommand, execHistoryCommand\n // See CVSElement\n \n \t\t//call vss, write output to intermediate file\n String[] cmdArray = {\"ss.exe\", \"history\", ssdir, \"-R\", \"-Vd\" +\n formatDateForVSS(now) + \"~\" + formatDateForVSS(lastBuild),\n \"-Y\" + login, \"-I-N\", \"-O\" + VSS_TEMP_FILE};\n \t\ttry {\n \t\t\tProcess p = Runtime.getRuntime().exec(cmdArray);\n \t\t\tp.waitFor();\n \n \t\t\tBufferedReader reader = new BufferedReader(new FileReader(\n new File(VSS_TEMP_FILE)));\n \n \t\t\tString currLine = reader.readLine();\n \t\t\twhile (currLine != null) {\n \t\t\t\tif (currLine.startsWith(\"***** \")) {\n \t\t\t\t\tArrayList vssEntry = new ArrayList();\n \t\t\t\t\tvssEntry.add(currLine);\n \t\t\t\t\tcurrLine = reader.readLine();\n \t\t\t\t\twhile (currLine != null && !currLine.startsWith(\"***** \")) {\n \t\t\t\t\t\tvssEntry.add(currLine);\n \t\t\t\t\t\tcurrLine = reader.readLine();\n \t\t\t\t\t}\n Modification mod = handleEntry(vssEntry);\n if(mod != null)\n modifications.add(mod);\n \t\t\t\t} else {\n \t\t\t\t\tcurrLine = reader.readLine();\n \t\t\t\t}\n \t\t\t}\n \n \t\t\treader.close();\n \t\t\tnew File(VSS_TEMP_FILE).delete();\n \t\t} catch (Exception e) {\n \t\t\te.printStackTrace();\n \t\t}\n \n \t\tif (_property != null && modifications.size() > 0) {\n _properties.put(_property, \"true\");\n \t\t}\n \n \t\treturn modifications;\n \t}", "public FileVersion(int owner, int version, int revision) {\n this.owner = owner;\n this.version = version;\n this.revision = revision;\n }", "void loadSet() {\n int returnVal = fc.showOpenDialog(this);\n if (returnVal != JFileChooser.APPROVE_OPTION) {\n System.out.println(\"Open command cancelled by user.\");\n return;\n }\n file = fc.getSelectedFile();\n System.out.println(\"Opening: \" + file.getName());\n closeAllTabs();\n try {\n FileInputStream fis = new FileInputStream(file);\n ObjectInputStream ois = new ObjectInputStream(fis);\n //loopButton.setSelected( ois.readObject() ); \n ArrayList l = (ArrayList) ois.readObject();\n System.out.println(\"read \"+l.size()+\" thingies\");\n ois.close();\n for(int i=0; i<l.size(); i++) {\n HashMap m = (HashMap) l.get(i);\n openNewTab();\n getCurrentTab().paste(m);\n }\n } catch(Exception e) {\n System.out.println(\"Open error \"+e);\n }\n }", "@Override\n public List<History> getHistories(Long id) {\n return historyRepository.findByProposalIdOrderByCreatedDateDesc(id);\n }", "public HistoryFileManager() {\n super(HistoryFileManager.class.getName());\n }", "public static final void logModuleBuildVersion() {\n try {\n InputStream is = RadiusServiceStarter.class.getResourceAsStream(\"/META-INF/openam-radius-version.txt\");\n if (is != null) {\n int bytesRead = 0;\n\n byte[] bytes = new byte[256];\n try {\n bytesRead = is.read(bytes);\n cLog.log(Level.INFO, \"Loaded \" + new String(bytes, 0, bytesRead));\n } catch (IOException e) {\n cLog.log(Level.WARNING, \"----> Unable to load openam-auth-smsotp module's version information.\", e);\n }\n }\n } catch (Throwable t) {\n cLog.log(Level.SEVERE, \"----> Unable to load openam-auth-smsotp module's version information.\", t);\n }\n }", "public void stockLoad() {\n try {\n File file = new File(stockPath);\n Scanner scanner = new Scanner(file);\n while (scanner.hasNextLine()) {\n String data = scanner.nextLine();\n String[] userData = data.split(separator);\n Stock stock = new Stock();\n stock.setProductName(userData[0]);\n int stockCountToInt = Integer.parseInt(userData[1]);\n stock.setStockCount(stockCountToInt);\n float priceToFloat = Float.parseFloat(userData[2]);\n stock.setPrice(priceToFloat);\n stock.setBarcode(userData[3]);\n\n stocks.add(stock);\n }\n } catch (FileNotFoundException e) {\n e.printStackTrace();\n }\n }" ]
[ "0.6552139", "0.6549593", "0.64660543", "0.63887537", "0.61489093", "0.60268795", "0.59898144", "0.5851957", "0.58199006", "0.5689449", "0.5662529", "0.5509813", "0.5482704", "0.5463437", "0.54471433", "0.5445846", "0.54303694", "0.5428895", "0.5397362", "0.53946686", "0.53919965", "0.53616333", "0.53099424", "0.5256898", "0.5250417", "0.5239094", "0.5238119", "0.52070415", "0.51968646", "0.5143259", "0.5139704", "0.5131794", "0.5129962", "0.51265", "0.50792384", "0.50733584", "0.50502646", "0.50450325", "0.50412506", "0.50323397", "0.5023772", "0.50236994", "0.5021297", "0.49987617", "0.49847847", "0.49845335", "0.49740294", "0.4973539", "0.49723086", "0.49395618", "0.49372518", "0.49343684", "0.49276984", "0.4924111", "0.4917024", "0.49085146", "0.4905832", "0.48906654", "0.48817924", "0.48733705", "0.48464063", "0.4833189", "0.4827644", "0.4827644", "0.4823476", "0.4819035", "0.4814592", "0.47967994", "0.47863424", "0.4784623", "0.4776766", "0.47767574", "0.4771961", "0.47699058", "0.47689694", "0.47663513", "0.47551155", "0.47369543", "0.47321656", "0.47309527", "0.47231928", "0.47172004", "0.4715756", "0.47138932", "0.47130144", "0.47105628", "0.47090864", "0.47009397", "0.46923718", "0.4686575", "0.4685649", "0.4679496", "0.4678819", "0.46772128", "0.46545935", "0.46496135", "0.4642334", "0.46422303", "0.46407583", "0.46335858" ]
0.74591637
0
Build project tree (tree of VssProject objects)
private void buildTree(String projectPath, VssProject vssProject) { if(config.useComApi) { getVss().getComApiDirProject(vssProject); } else { File file = getVss().listFilesInProject(projectPath); BufferedReader in = Util.openReader(file, config.getLogEncoding()); try { parseTree(in, vssProject); } finally { Util.close(in); } } for (Iterator i = vssProject.getSubprojects().iterator(); i.hasNext();) { VssProject subproject = (VssProject) i.next(); String path = projectPath + "/" + subproject.getName(); buildTree(path, subproject); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void parseTree(BufferedReader in, VssProject vssProject) {\r\n try {\r\n String line;\r\n boolean start = false;\r\n while ((line = in.readLine()) != null) {\r\n if (!start) {\r\n if (line.startsWith(\"$\") && line.endsWith(\":\")) {\r\n start = true;\r\n continue;\r\n }\r\n } else {\r\n if (line.length() == 0)\r\n break;\r\n if (line.startsWith(\"$\")) {\r\n \t\r\n String projectName = line.substring(1);\r\n if ( config.getProjectsToIgnore().contains( projectName ) )\r\n \t\t\t\t\t{\r\n \t\t\t\t\t\t// Ignore list!\r\n \t\t\t\t\t\tLOG.warn( \"Ignore project \" + projectName + \" found in : \" + vssProject.getVssPath() );\r\n \t\t\t\t\t\tcontinue;\r\n \t\t\t\t\t}\r\n \r\n VssProject newProject = new VssProject();\r\n newProject.setName(projectName);\r\n newProject.setParent(vssProject);\r\n vssProject.addSubproject(newProject);\r\n \r\n } else \r\n {\r\n if (line.startsWith(\"No items found under $\")) {\r\n continue;\r\n } \r\n String filename = line;\r\n String parent = vssProject.getVssPath().substring(config.getProject().length());\r\n if (parent.length() > 0) {\r\n if (parent.startsWith(\"/\"))\r\n parent = parent.substring(1);\r\n if (!parent.endsWith(\"/\"))\r\n parent += \"/\";\r\n }\r\n String path = parent + filename;\r\n VssFile newFile = new VssFile(path, filename);\r\n newFile.setParent(vssProject);\r\n vssProject.addFile(newFile);\r\n }\r\n }\r\n }\r\n } catch (IOException e) {\r\n throw new VssException(\"readLine\", e);\r\n }\r\n }", "Project createProject();", "Project createProject();", "Project createProject();", "public BuildTree createBuildTree() {\n BuildTree buildTree = new BuildTree();\n createBuildTree(0, buildTree);\n return buildTree;\n }", "protected void createProject(IProgressMonitor monitor)\n {\n monitor.beginTask(\"Creating the Totori project\", 50);\n try\n {\n IWorkspaceRoot root = ResourcesPlugin.getWorkspace().getRoot();\n monitor.subTask(\"Defining the nature of the project\");\n IProject project = root.getProject(page.getProjectName());\n IProjectDescription description = ResourcesPlugin.getWorkspace().newProjectDescription(project.getName());\n if(!Platform.getLocation().equals(page.getLocationPath()))\n description.setLocation(page.getLocationPath());\n project.create(description,monitor);\n monitor.worked(10);\n project.open(monitor);\n description = project.getDescription();\n description.setNatureIds(new String[] { TotoriNature.NATURE_ID });\n project.setDescription(description,new SubProgressMonitor(monitor,10));\n monitor.subTask(\"Creating subdirectories\");\n createFolderHelper(root.getFolder(project.getFullPath().append(\"config\")), monitor);\n createFolderHelper(root.getFolder(project.getFullPath().append(\"ext\")), monitor);\n createFolderHelper(root.getFolder(project.getFullPath().append(\"ext\").append(\"nircmd\")), monitor);\n createFolderHelper(root.getFolder(project.getFullPath().append(\"features\")), monitor);\n createFolderHelper(root.getFolder(project.getFullPath().append(\"features\").append(\"plugins\")), monitor);\n createFolderHelper(root.getFolder(project.getFullPath().append(\"features\").append(\"steps\")), monitor);\n createFolderHelper(root.getFolder(project.getFullPath().append(\"features\").append(\"support\")), monitor);\n createFolderHelper(root.getFolder(project.getFullPath().append(\"reports\")), monitor);\n createFolderHelper(root.getFolder(project.getFullPath().append(\"reports\").append(\"assets\")), monitor);\n createFolderHelper(root.getFolder(project.getFullPath().append(\"reports\").append(\"screens\")), monitor);\n project.setDescription(description,new SubProgressMonitor(monitor,10));\n monitor.subTask(\"Creating files\");\n Vector<String> assets = new Vector<String>();\n assets.add(\"config/myconfig.yml\");\n assets.add(\"ext/nircmd/nircmd.chm\");\n assets.add(\"ext/nircmd/nircmd.exe\");\n assets.add(\"ext/nircmd/nircmdc.exe\");\n assets.add(\"features/support/env.rb\");\n assets.add(\"features/support/functions.rb\");\n assets.add(\"features/support/screenshots.rb\");\n assets.add(\"features/support/totori_formatter.rb\");\n assets.add(\"reports/assets/jquery-1.4.1.min.js\");\n assets.add(\"reports/assets/jquery.lightbox-0.5.css\");\n assets.add(\"reports/assets/jquery.lightbox-0.5.min.js\");\n assets.add(\"reports/assets/jquery.thumbs.js\");\n assets.add(\"reports/assets/lightbox-blank.gif\");\n assets.add(\"reports/assets/lightbox-btn-close.gif\");\n assets.add(\"reports/assets/lightbox-btn-next.gif\");\n assets.add(\"reports/assets/lightbox-btn-prev.gif\");\n assets.add(\"reports/assets/lightbox-ico-loading.gif\");\n assets.add(\"reports/assets/search.png\");\n assets.add(\"reports/assets/thumbs.css\");\n assets.add(\"reports/assets/totori.css\");\n for(String asset : assets) {\n \t String resource = \"/assets/\"+asset;\n \t InputStream stream = this.getClass().getResourceAsStream(resource);\n \t System.out.println(resource + \" : \" + stream);\n IPath path = project.getFullPath();\n for(String dir : asset.split(\"/\")) {\n \t path = path.append(dir);\n }\n IFile file = root.getFile(path);\n //file.getFullPath().toFile().mkdirs();\n //file.setCharset(\"utf-8\", monitor);\n file.create(stream, false, monitor);\n }\n monitor.worked(20);\n }\n catch(CoreException x)\n {\n reportError(x);\n }\n finally\n {\n monitor.done();\n }\n }", "@Test\n public void testCreateDependencyTree4() {\n Map<String, Integer> expected = new HashMap<>() {{\n put(\"github.com/test/subproject:0.0.0-00010101000000-000000000000\", 1);\n }};\n try {\n Path projectDir = GO_ROOT.resolve(\"project4\");\n GoTreeBuilder treeBuilder = new GoTreeBuilder(null, projectDir, projectDir.resolve(\"go.mod\").toString(), null, log);\n DepTree dt = treeBuilder.buildTree();\n validateDependencyTreeResults(expected, dt);\n } catch (IOException ex) {\n fail(ExceptionUtils.getStackTrace(ex));\n }\n }", "public void createProject(Project newProject);", "public static ElementTreeSelectionDialog createHaxeProjectsDialog(\r\n\t\t\tShell shell) {\r\n\r\n\t\tElementTreeSelectionDialog dialog = new ElementTreeSelectionDialog(\r\n\t\t\t\tshell, new HaxeElementsLabelProvider(),\r\n\t\t\t\tnew HaxeElementsContentProvider(new HaxeElementFilter(\r\n\t\t\t\t\t\tShowElement.Project)));\r\n\r\n\t\tdialog.setTitle(\"haXe Project\");\r\n\t\tdialog.setMessage(\"Choose a haXe project:\");\r\n\t\tdialog.setHelpAvailable(false);\r\n\r\n\t\t// Sets haXe workspace as a root of the resource tree\r\n\t\tdialog.setInput(EclihxCore.getDefault().getHaxeWorkspace());\r\n\r\n\t\treturn dialog;\r\n\t}", "@Override\r\n\tpublic List<TreeNodeTo> prepareSprintTreeNodes(String projectId) {\n\t\tTreeNodeTo rootNode=prepareRootNode();\r\n\t\tList sprintNodes=new ArrayList<TreeNodeTo>();\r\n\t\tsprintNodes.add(rootNode);\r\n\t\tList<SprintTo> sprints=sprintDao.getSprintForProject(projectId);\r\n\t\tif(sprints!=null&&sprints.size()>0){\r\n\t\t\tfor(SprintTo sprint : sprints){\r\n\t\t\t\tTreeNodeTo node=new TreeNodeTo();\r\n\t\t\t\tnode.setId(sprint.getId());\r\n\t\t\t\tnode.setName(\"<Strong>\"+sprint.getName()+\"</Strong>\"+\" : \"+dateFormat.format(sprint.getStartTime())+\"--\"+dateFormat.format(sprint.getEndTime()));\r\n\t\t\t\tif(sprint.getParentSprint()==null){\r\n\t\t\t\t\tnode.setpId(\"0\");\r\n\t\t\t\t\tnode.setOpen(true);\r\n\t\t\t\t}\t\t\t\t\t\r\n\t\t\t\telse {\r\n\t\t\t\t\tnode.setpId(sprint.getParentSprint().getId());\r\n\t\t\t\t\tnode.setOpen(false);\r\n\t\t\t\t}\r\n\t\t\t\tsprintNodes.add(node);\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn sprintNodes;\r\n\t}", "public Project build() {\n return new Project(descriptor.build());\n }", "public void querySubProjects() {\r\n\t\t// Create a task\r\n\t\tProject master = new Project();\r\n\t\tmaster.setName(\"INFRASTRUCTURE\");\r\n\t\tmaster.setDisplayName(\"Infrastructure\");\r\n\t\tmaster.setDescription(\"Project to setup the new infrastructure\");\r\n\t\tmaster = (Project) aggregateService.create(master, new Settings());\t\r\n\r\n\t\t// Create 2 dependents\r\n\t\tProject A = new Project();\r\n\t\tA.setName(\"SETUP_NETWORK\");\r\n\t\tA.setDisplayName(\"Setup network\");\r\n\t\tA.setDescription(\"Project to lay the network cables and connect to routers\");\r\n\t\tA = (Project) aggregateService.create(A, new Settings());\r\n\r\n\t\tProject B = new Project();\r\n\t\tB.setName(\"SETUP_TELEPHONE\");\r\n\t\tB.setDisplayName(\"Setup telephone\");\r\n\t\tB.setDescription(\"Setup the telephone at each employee desk\");\r\n\t\tB = (Project) aggregateService.create(B, new Settings());\r\n\r\n\t\tMap<String, Project> subProjects = new HashMap<String, Project>();\r\n\t\tsubProjects.put(A.getName(), A);\r\n\t\tsubProjects.put(B.getName(), B);\r\n\t\tmaster.setSubProjects(subProjects);\r\n\t\tmaster = (Project) aggregateService.read(master, getSettings());\t\t\r\n\r\n\t\t// query the task object\r\n\t\tSettings settings = new Settings();\r\n\t\tsettings.setView(aggregateService.getView(\"SUBPROJECTS\"));\t\t\r\n\t\tList<?> toList = aggregateService.query(master, settings);\r\n\r\n\t\tassert(toList.size() == 1);\t\t\r\n\r\n\t\tObject obj = toList.get(0);\r\n\t\tassert(Project.class.isAssignableFrom(obj.getClass()));\r\n\r\n\t\tProject root = (Project) obj;\r\n\t\tassert(root.getSubProjects() != null && root.getSubProjects().size() == 2);\r\n\t\tassert(root.getSubProjects().get(\"SETUP_NETWORK\").getName().equals(\"SETUP_NETWORK\"));\r\n\t\tassert(root.getSubProjects().get(\"SETUP_TELEPHONE\").getName().equals(\"SETUP_TELEPHONE\"));\t\t\r\n\t}", "@Test\n public void testCreateDependencyTree3() {\n Map<String, Integer> expected = new HashMap<>() {{\n put(\"github.com/test/subproject:0.0.0-00010101000000-000000000000\", 1);\n }};\n try {\n Path projectDir = GO_ROOT.resolve(\"project3\");\n GoTreeBuilder treeBuilder = new GoTreeBuilder(null, projectDir, projectDir.resolve(\"go.mod\").toString(), null, log);\n DepTree dt = treeBuilder.buildTree();\n validateDependencyTreeResults(expected, dt);\n } catch (IOException ex) {\n fail(ExceptionUtils.getStackTrace(ex));\n }\n }", "private void findCvsRoot()\n{\n File f = new File(for_project.getSourceDirectory());\n for ( ; ; ) {\n File fp = f.getParentFile();\n File fp1 = new File(fp,\"CVS\");\n if (!fp1.exists()) break;\n f = fp;\n }\n cvs_root = f;\n}", "private void createProjectComposite() {\r\n\t\tGridLayout gridLayout2 = new GridLayout();\r\n\t\tgridLayout2.numColumns = 2;\r\n\t\tprojectComposite = new Composite(composite, SWT.NONE);\r\n\t\tprojectComposite.setLayout(gridLayout2);\r\n\t\tprojectComposite.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true));\r\n\t\toutputChooserTreeViewer = new TreeViewer(projectComposite, SWT.BORDER);\r\n\t\toutputChooserTreeViewer.getControl().setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true));\r\n\t\toutputChooserTreeViewer.setContentProvider(new ProjectContentProvider());\r\n\t\toutputChooserTreeViewer.setLabelProvider(new DecoratingLabelProvider(\r\n\t\t\t\t\t\t\t\tnew WorkbenchLabelProvider(), \r\n\t\t\t\t\t\t\t\tPlatformUI.getWorkbench().getDecoratorManager().getLabelDecorator()));\r\n\t\toutputChooserTreeViewer.setInput(ResourcesPlugin.getWorkspace().getRoot());\r\n\t\toutputChooserTreeViewer.getTree().addSelectionListener(new SelectionListener() {\r\n\r\n\t\t\tpublic void widgetDefaultSelected(SelectionEvent arg0) {\r\n\t\t\t}\r\n\r\n\t\t\tpublic void widgetSelected(SelectionEvent arg0) {\t\r\n\t\t\t\tvalidatePage();\r\n\t\t\t}\r\n\t\t});\r\n\t\toutputChooserTreeViewer.addSelectionChangedListener(new ISelectionChangedListener() {\r\n\r\n\t\t\tpublic void selectionChanged(SelectionChangedEvent arg0) {\r\n\t\t\t\tTreeSelection selection = (TreeSelection) outputChooserTreeViewer.getSelection();\r\n\t\t\t\tif (selection != null) {\r\n\t\t\t\t\tObject selected = selection.getFirstElement();\r\n\t\t\t\t\tif (selected != null) {\r\n\t\t\t\t\t\tif (selected instanceof IContainer) {\r\n\t\t\t\t\t\t\tNewPIWizardSettings.getInstance().outputContainer = (IContainer) selected;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t});\r\n\r\n\t\tcreateButtonComposite();\r\n\t}", "void build(String name, Project project);", "public static void newProject() {\n\n //create the arena representation\n //populateBlocks();\n //populateSensors();\n }", "private void initializeProject() {\n newProject.setInputHandler(getProject().getInputHandler());\n \n Iterator iter = getBuildListeners();\n while (iter.hasNext()) {\n newProject.addBuildListener((BuildListener) iter.next());\n }\n \n if (output != null) {\n File outfile = null;\n if (dir != null) {\n outfile = FILE_UTILS.resolveFile(dir, output);\n } else {\n outfile = getProject().resolveFile(output);\n }\n try {\n out = new PrintStream(new FileOutputStream(outfile));\n DefaultLogger logger = new DefaultLogger();\n logger.setMessageOutputLevel(Project.MSG_INFO);\n logger.setOutputPrintStream(out);\n logger.setErrorPrintStream(out);\n newProject.addBuildListener(logger);\n } catch (IOException ex) {\n log(\"Ant: Can't set output to \" + output);\n }\n }\n-\n- getProject().initSubProject(newProject);\n-\n // set user-defined properties\n getProject().copyUserProperties(newProject);\n \n if (!inheritAll) {\n // set Java built-in properties separately,\n // b/c we won't inherit them.\n newProject.setSystemProperties();\n \n } else {\n // set all properties from calling project\n addAlmostAll(getProject().getProperties());\n }\n \n Enumeration e = propertySets.elements();\n while (e.hasMoreElements()) {\n PropertySet ps = (PropertySet) e.nextElement();\n addAlmostAll(ps.getProperties());\n }\n }", "public void loadProjectTree(Long id) {\n rootId = id;\n editResourceService.getResources(id, new AsyncCallback<List<VMResource>>() {\n @Override\n public void onFailure(Throwable caught) {\n SC.warn(caught.getMessage());\n }\n\n @Override\n public void onSuccess(List<VMResource> result) {\n if (rootId == id) {\n VMDirectory rootDir = new VMDirectory();\n rootDir.setId(rootId);\n rootDir.setName(\"/\");\n fileTreeNodeFactory.setRootDirectory(rootDir);\n }\n TreeNode[] nodes = fileTreeNodeFactory.getFileTreeNodes(id, result);\n tree = new Tree();\n tree.setDefaultIsFolder(true);\n tree.setShowRoot(true);\n tree.setModelType(TreeModelType.CHILDREN);\n tree.setNameProperty(\"fullName\");\n tree.setData(nodes);\n treeGrid.setData(tree);\n treeGrid.sort();\n }\n });\n }", "Builder forProjectDirectory(File projectDir);", "public SCMLProject load(Element root)\n\t{\n\t\tthis.currentProject = new SCMLProject();\n\n\t\tloadAssets(root.getChildrenByName(\"folder\"));\n\t\tloadEntities(root.getChildrenByName(\"entity\"));\n\n\t\treturn currentProject;\n\t}", "public JSONArray build_src_vs_tree() {\r\n\t\treturn getRootValueSets(true, true);\r\n\t}", "LectureProject createLectureProject();", "protected void makeTheTree(){\n\n structure.getRootNode().branchList.add(structure.getNode11());\n structure.getRootNode().branchList.add(structure.getNode12());\n structure.getRootNode().branchList.add(structure.getNode13());\n\n structure.getNode11().branchList.add(structure.getNode111());\n structure.getNode11().branchList.add(structure.getNode112());\n structure.getNode11().branchList.add(structure.getNode113());\n\n structure.getNode13().branchList.add(structure.getNode131());\n\n structure.getNode112().branchList.add(structure.getNode1121());\n\n }", "@Test\n public void testCreateDependencyTree1() {\n Map<String, Integer> expected = new HashMap<>() {{\n put(\"github.com/jfrog/jfrog-cli-core:1.9.0\", 11);\n put(\"github.com/jfrog/jfrog-client-go:0.26.1\", 9);\n }};\n\n try {\n Path projectDir = GO_ROOT.resolve(\"project1\");\n GoTreeBuilder treeBuilder = new GoTreeBuilder(null, projectDir, projectDir.resolve(\"go.mod\").toString(), null, log);\n DepTree dt = treeBuilder.buildTree();\n validateDependencyTreeResults(expected, dt);\n } catch (IOException ex) {\n fail(ExceptionUtils.getStackTrace(ex));\n }\n }", "private void createProjectGroup(Composite parent) {\n int col = 0;\n\n // project name\n String tooltip = \"The Android Project where the new resource file will be created.\";\n Label label = new Label(parent, SWT.NONE);\n label.setText(\"Project\");\n label.setToolTipText(tooltip);\n ++col;\n\n mProjectTextField = new Text(parent, SWT.BORDER);\n mProjectTextField.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));\n mProjectTextField.setToolTipText(tooltip);\n mProjectTextField.addModifyListener(new ModifyListener() {\n public void modifyText(ModifyEvent e) {\n onProjectFieldUpdated();\n }\n });\n ++col;\n\n mProjectBrowseButton = new Button(parent, SWT.NONE);\n mProjectBrowseButton.setText(\"Browse...\");\n mProjectBrowseButton.setToolTipText(\"Allows you to select the Android project to modify.\");\n mProjectBrowseButton.addSelectionListener(new SelectionAdapter() {\n @Override\n public void widgetSelected(SelectionEvent e) {\n onProjectBrowse();\n }\n });\n mProjectChooserHelper = new ProjectChooserHelper(parent.getShell(), null /*filter*/);\n ++col;\n\n col = padWithEmptyCells(parent, col);\n\n // file name\n tooltip = \"The name of the resource file to create.\";\n label = new Label(parent, SWT.NONE);\n label.setText(\"File\");\n label.setToolTipText(tooltip);\n ++col;\n\n mFileNameTextField = new Text(parent, SWT.BORDER);\n mFileNameTextField.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));\n mFileNameTextField.setToolTipText(tooltip);\n mFileNameTextField.addModifyListener(new ModifyListener() {\n public void modifyText(ModifyEvent e) {\n validatePage();\n }\n });\n ++col;\n\n padWithEmptyCells(parent, col);\n }", "private boolean createProject() {\r\n ProjectOverviewerApplication app = (ProjectOverviewerApplication)getApplication();\r\n Projects projects = app.getProjects();\r\n String userHome = System.getProperty(\"user.home\");\r\n // master file for projects management\r\n File projectsFile = new File(userHome + \"/.hackystat/projectoverviewer/projects.xml\");\r\n \r\n // create new project and add it to the projects\r\n Project project = new Project();\r\n project.setProjectName(this.projectName);\r\n project.setOwner(this.ownerName);\r\n project.setPassword(this.password);\r\n project.setSvnUrl(this.svnUrl);\r\n for (Project existingProject : projects.getProject()) {\r\n if (existingProject.getProjectName().equalsIgnoreCase(this.projectName)) {\r\n return false;\r\n }\r\n }\r\n projects.getProject().add(project);\r\n \r\n try {\r\n // create the specific tm3 file and xml file for the new project\r\n File tm3File = new File(userHome + \r\n \"/.hackystat/projectoverviewer/\" + this.projectName + \".tm3\");\r\n File xmlFile = new File(userHome + \r\n \"/.hackystat/projectoverviewer/\" + this.projectName + \".xml\");\r\n tm3File.createNewFile();\r\n \r\n // initialize the data for the file\r\n SensorDataCollector collector = new SensorDataCollector(app.getSensorBaseHost(), \r\n this.ownerName, \r\n this.password);\r\n collector.getRepository(this.svnUrl, this.projectName);\r\n collector.write(tm3File, xmlFile);\r\n } \r\n catch (IOException e) {\r\n e.printStackTrace();\r\n return false;\r\n }\r\n // write the projects.xml file with the new project added\r\n String packageName = \"org.hackystat.iw.projectoverviewer.jaxb.projects\";\r\n return XmlConverter.objectToXml(projects, projectsFile, packageName);\r\n }", "private void updateStructure()\r\n {\r\n int id = 1;\r\n Integer outlineLevel = Integer.valueOf(1);\r\n for (Task task : m_project.getChildTasks())\r\n {\r\n id = updateStructure(id, task, outlineLevel);\r\n }\r\n }", "public interface ICMakeProject extends IUnaryComparator<ICMakeProject>, IJsonSerialization {\n /**\n * Gets the name of the project.\n */\n String getName();\n\n /**\n * Gets the path of the root of the project.\n */\n Path getRootPath();\n\n /**\n * Gets the list of the modules.\n */\n List<ICMakeModule> getModules();\n}", "public void initSubprojects(){\n\t\tArrayList<SubprojectField> fieldsFirestation=new ArrayList<SubprojectField>(Arrays.asList(\n\t\t\t\tnew SubprojectField(10, false, false),\n\t\t\t\tnew SubprojectField(10, false, false),\n\t\t\t\tnew SubprojectField(50, true, false),\n\t\t\t\tnew SubprojectField(10, false, false),\n\t\t\t\tnew SubprojectField(20, false, false),\n\t\t\t\tnew SubprojectField(30, false, false),\n\t\t\t\tnew SubprojectField(40, true, false),\n\t\t\t\tnew SubprojectField(20, false, false),\n\t\t\t\tnew SubprojectField(50, false, true)));\n\t\tprojectsAvailable.add(new Subproject(\"Feuerwache\",fieldsFirestation,0));\n\t\tArrayList<SubprojectField> fieldsNorthStreet=new ArrayList<SubprojectField>(Arrays.asList(\n\t\t\t\tnew SubprojectField(10, false, false),\n\t\t\t\tnew SubprojectField(30, false, false),\n\t\t\t\tnew SubprojectField(10, false, false),\n\t\t\t\tnew SubprojectField(20, false, false),\n\t\t\t\tnew SubprojectField(50, false, false),\n\t\t\t\tnew SubprojectField(20, true, false),\n\t\t\t\tnew SubprojectField(10, false, false),\n\t\t\t\tnew SubprojectField(30, true, false),\n\t\t\t\tnew SubprojectField(30, false, true)));\n\t\tprojectsAvailable.add(new Subproject(\"Landebahn Nord\",fieldsNorthStreet,1));\n\t\tArrayList<SubprojectField> fieldsSouthStreet=new ArrayList<SubprojectField>(Arrays.asList(\n\t\t\t\tnew SubprojectField(20, false, false),\n\t\t\t\tnew SubprojectField(10, false, false),\n\t\t\t\tnew SubprojectField(20, true, false),\n\t\t\t\tnew SubprojectField(10, false, false),\n\t\t\t\tnew SubprojectField(50, false, false),\n\t\t\t\tnew SubprojectField(50, false, false),\n\t\t\t\tnew SubprojectField(10, true, false),\n\t\t\t\tnew SubprojectField(20, false, false),\n\t\t\t\tnew SubprojectField(40, false, true)));\n\t\tprojectsAvailable.add(new Subproject(\"Landebahn S�d\",fieldsSouthStreet,2));\n\t\tArrayList<SubprojectField> fieldsTerminalA=new ArrayList<SubprojectField>(Arrays.asList(\n\t\t\t\tnew SubprojectField(20, false, false),\n\t\t\t\tnew SubprojectField(20, false, false),\n\t\t\t\tnew SubprojectField(10, true, false),\n\t\t\t\tnew SubprojectField(30, false, false),\n\t\t\t\tnew SubprojectField(10, true, false),\n\t\t\t\tnew SubprojectField(50, false, true)));\n\t\tprojectsAvailable.add(new Subproject(\"Terminal A\",fieldsTerminalA,3));\n\t\tArrayList<SubprojectField> fieldsTerminalB=new ArrayList<SubprojectField>(Arrays.asList(\n\t\t\t\tnew SubprojectField(20, false, false),\n\t\t\t\tnew SubprojectField(10, false, false),\n\t\t\t\tnew SubprojectField(30, true, false),\n\t\t\t\tnew SubprojectField(10, false, false),\n\t\t\t\tnew SubprojectField(10, false, false),\n\t\t\t\tnew SubprojectField(50, true, false),\n\t\t\t\tnew SubprojectField(20, false, false),\n\t\t\t\tnew SubprojectField(50, false, true)));\n\t\tprojectsAvailable.add(new Subproject(\"Terminal B\",fieldsTerminalB,4));\n\t\tArrayList<SubprojectField> fieldsMainTerminal=new ArrayList<SubprojectField>(Arrays.asList(\n\t\t\t\tnew SubprojectField(20, false, false),\n\t\t\t\tnew SubprojectField(10, true, false),\n\t\t\t\tnew SubprojectField(30, false, false),\n\t\t\t\tnew SubprojectField(10, false, false),\n\t\t\t\tnew SubprojectField(10, false, false),\n\t\t\t\tnew SubprojectField(20, true, false),\n\t\t\t\tnew SubprojectField(50, true, false),\n\t\t\t\tnew SubprojectField(10, false, false),\n\t\t\t\tnew SubprojectField(50, false, true)));\n\t\tprojectsAvailable.add(new Subproject(\"Hauptterminal\",fieldsMainTerminal,5));\n\t\tArrayList<SubprojectField> fieldsParkStation=new ArrayList<SubprojectField>(Arrays.asList(\n\t\t\t\tnew SubprojectField(50, false, false),\n\t\t\t\tnew SubprojectField(50, false, false),\n\t\t\t\tnew SubprojectField(50, true, false),\n\t\t\t\tnew SubprojectField(20, false, false),\n\t\t\t\tnew SubprojectField(20, true, false),\n\t\t\t\tnew SubprojectField(20, false, false),\n\t\t\t\tnew SubprojectField(50, false, false),\n\t\t\t\tnew SubprojectField(20, false, true)));\n\t\tprojectsAvailable.add(new Subproject(\"Parkplatz\",fieldsParkStation,6));\n\t\tArrayList<SubprojectField> fieldsPreStation=new ArrayList<SubprojectField>(Arrays.asList(\n\t\t\t\tnew SubprojectField(20, false, false),\n\t\t\t\tnew SubprojectField(10, false, false),\n\t\t\t\tnew SubprojectField(50, true, false),\n\t\t\t\tnew SubprojectField(20, false, false),\n\t\t\t\tnew SubprojectField(50, false, false),\n\t\t\t\tnew SubprojectField(20, false, true)));\n\t\tprojectsAvailable.add(new Subproject(\"Vorfeld\",fieldsPreStation,7));\n\t}", "public void testProjectsView() {\n ProjectsTabOperator.invoke();\n // needed for slower machines\n JemmyProperties.setCurrentTimeout(\"JTreeOperator.WaitNextNodeTimeout\", 30000); // NOI18N\n SourcePackagesNode sourcePackagesNode = new SourcePackagesNode(SAMPLE_PROJECT_NAME);\n Node sample1Node = new Node(sourcePackagesNode, SAMPLE1_PACKAGE_NAME);\n Node sampleClass1Node = new Node(sample1Node, SAMPLE1_FILE_NAME);\n // test pop-up menu actions\n // \"Copy\"\n CopyAction copyAction = new CopyAction();\n copyAction.perform(sampleClass1Node);\n // \"Paste\"\n PasteAction pasteAction = new PasteAction();\n // \"Refactor\"\n String refactorItem = Bundle.getStringTrimmed(\"org.netbeans.modules.refactoring.spi.impl.Bundle\", \"LBL_Action\");\n // \"Copy...\"\n String copyItem = Bundle.getStringTrimmed(\"org.netbeans.modules.refactoring.spi.impl.Bundle\", \"LBL_CopyAction\");\n new ActionNoBlock(null, pasteAction.getPopupPath() + \"|\" + refactorItem + \" \" + copyItem).perform(sample1Node);\n\n String copyClassTitle = Bundle.getString(\"org.netbeans.modules.refactoring.java.ui.Bundle\", \"LBL_CopyClass\");\n NbDialogOperator copyClassDialog = new NbDialogOperator(copyClassTitle);\n // \"Refactor\"\n String refactorLabel = Bundle.getStringTrimmed(\"org.netbeans.modules.refactoring.spi.impl.Bundle\", \"CTL_Finish\");\n new JButtonOperator(copyClassDialog, refactorLabel).push();\n // refactoring is done asynchronously => need to wait until dialog dismisses\n copyClassDialog.waitClosed();\n\n Node newClassNode = new Node(sample1Node, \"SampleClass11\"); // NOI18N\n // \"Cut\"\n CutAction cutAction = new CutAction();\n cutAction.perform(newClassNode);\n // package created by default when the sample project was created\n Node sampleProjectPackage = new Node(sourcePackagesNode, SAMPLE_PROJECT_NAME.toLowerCase());\n // \"Move...\"\n String moveItem = Bundle.getStringTrimmed(\"org.netbeans.modules.refactoring.spi.impl.Bundle\", \"LBL_MoveAction\");\n new ActionNoBlock(null, pasteAction.getPopupPath() + \"|\" + refactorItem + \" \" + moveItem).perform(sampleProjectPackage);\n new EventTool().waitNoEvent(1000);\n // confirm refactoring\n // \"Move Class\"\n String moveClassTitle = Bundle.getString(\"org.netbeans.modules.refactoring.java.ui.Bundle\", \"LBL_MoveClass\");\n NbDialogOperator moveClassDialog = new NbDialogOperator(moveClassTitle);\n new JButtonOperator(moveClassDialog, refactorLabel).push();\n // refactoring is done asynchronously => need to wait until dialog dismisses\n try {\n moveClassDialog.waitClosed();\n } catch (TimeoutExpiredException e) {\n // try it once more\n moveClassDialog = new NbDialogOperator(moveClassTitle);\n new JButtonOperator(moveClassDialog, refactorLabel).push();\n }\n // \"Delete\"\n newClassNode = new Node(sampleProjectPackage, \"SampleClass11\"); // NOI18N\n new EventTool().waitNoEvent(2000);\n new DeleteAction().perform(newClassNode);\n DeleteAction.confirmDeletion();\n }", "private void setup(){\n buildTree(2);\n }", "Project getProject();", "@SuppressWarnings(\"synthetic-access\")\n\t\tpublic GitHubProject build() {\n\t\t\treturn new GitHubProject(this);\n\t\t}", "void createProjectForExercise(ProgrammingExercise programmingExercise) throws VersionControlException;", "public void init() {\n- newProject = new Project();\n- newProject.setDefaultInputStream(getProject().getDefaultInputStream());\n+ newProject = getProject().createSubProject();\n newProject.setJavaVersionProperty();\n }", "@Override\r\n\tpublic TreeNode getRootProject() {\n\t\treturn null;\r\n\t}", "private Project compileProject() {\n\t\t\tProject p = null;\n\t\t\t\n\t\t\tif(pType.equals(\"o\")) {\n\t\t\t\ttry {\n\t\t\t\t\tp = new OngoingProject(pCode.getText(), pName.getText(), dateFormat.parse(pSDate.getText()),pClient.getText(), dateFormat.parse(pDeadline.getText()), Double.parseDouble(pBudget.getText()), Integer.parseInt(pCompletion.getText()));\n\t\t\t\t} catch (NumberFormatException e) {\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t} catch (ParseException e) {\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t} else if(pType.equals(\"f\")) {\n\t\t\t\ttry {\n\t\t\t\t\tp = new FinishedProject(pCode.getText(), pName.getText(), dateFormat.parse(pSDate.getText()),pClient.getText(), dateFormat.parse(pEndDate.getText()), Double.parseDouble(pTotalCost.getText()));\n\t\t\t\t} catch (NumberFormatException e) {\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t} catch (ParseException e) {\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t}\n\t\t\t\t\t\n\t\t\treturn p;\n\t\t}", "IClassDefinition[] resolveAncestry(ICompilerProject project);", "public ISvnModel buildSvnModel() {\r\n VssModel vssModel = buildVssModel();\r\n if (incrementalWarning)\r\n LOG.warn(\"unsupported operations(delete,rename,share,branch) detected in project, incremental dump can be broken\");\r\n VssTransform tr = new VssTransform(this);\r\n SvnModel svnModel = tr.transform(vssModel);\r\n LOG.info(\"Svn model has been created\");\r\n LOG.info(\"total number of revisions in svn model: \" + svnModel.getRevisions().size());\r\n return svnModel;\r\n }", "public static void buildStage2 ()\r\n {\r\n \r\n lgt.findParent(); //4\r\n lgt.findChild(0); //6\r\n lgt.insert(12);\r\n lgt.findParent();\r\n lgt.insert(13);\r\n lgt.findParent();\r\n lgt.insert(14);\r\n \r\n lgt.findRoot();\r\n lgt.findChild(0);//2\r\n lgt.findChild(0);//5\r\n lgt.insert(8);\r\n lgt.findParent();\r\n lgt.insert(9);\r\n lgt.findParent();\r\n lgt.insert(10);\r\n lgt.findParent();\r\n lgt.insert(11);\r\n \r\n }", "public List<Project> getAllProjects();", "@Test\n public void testCreateResourceWithParent()\n {\n if (projects.size() > 0)\n {\n Project project = projects.get(0);\n Assert.assertNotNull(project);\n\n Set<Resource> all = resourcesManager.getResources(project.getId());\n Assert.assertNotNull(all);\n\n if (all.isEmpty())\n {\n resourcesManager.createResource(project.getId(), -1,\n builder.buildResource(ResourceKind.FOLDER));\n all = resourcesManager.getResources(project.getId());\n }\n\n Resource parent = all.iterator().next();\n Assert.assertNotNull(parent);\n\n if (parent.getKind().equals(ResourceKind.FOLDER))\n {\n Set<Resource> childs = parent.getChilds();\n Assert.assertNotNull(childs);\n\n Resource newResource = builder.buildResource(ResourceKind.FILE);\n Assert.assertNotNull(newResource);\n\n Resource created = resourcesManager.createResource(\n project.getId(), parent.getId(), newResource);\n\n Assert.assertNotNull(created);\n Assert.assertNotNull(created.getId());\n Assert.assertNotNull(created.getUrl());\n\n Set<Resource> allNow = resourcesManager.getResources(project\n .getId());\n\n Assert.assertNotNull(allNow);\n Assert.assertEquals(all.size(), allNow.size());\n\n parent = created.getParent();\n Assert.assertNotNull(parent);\n\n Assert.assertEquals(childs.size() + 1, parent.getChilds()\n .size());\n\n log.info(\"Check subversion url :\" + created.getUrl());\n }\n\n }\n else\n {\n fail(\"There is not projects.\");\n }\n }", "private void createTree() {\n DefaultMutableTreeNode topNode = new DefaultMutableTreeNode(\"The World\");\n myTree = new JTree(topNode);\n\n DefaultMutableTreeNode mainPortNode = new DefaultMutableTreeNode(\"Sea Ports\");\n topNode.add(mainPortNode);\n\n for(SeaPort mySeaPort : world.getPorts()) {\n DefaultMutableTreeNode individualPortNode = new DefaultMutableTreeNode(mySeaPort.getName());\n mainPortNode.add(individualPortNode);\n\n DefaultMutableTreeNode peopleNode = new DefaultMutableTreeNode(\"People\");\n individualPortNode.add(peopleNode);\n for(Person myPerson : mySeaPort.getPersons()) {\n DefaultMutableTreeNode individualPeopleNode = new DefaultMutableTreeNode(myPerson.getName());\n peopleNode.add(individualPeopleNode);\n }\n\n DefaultMutableTreeNode dockNode = new DefaultMutableTreeNode(\"Docks\");\n individualPortNode.add(dockNode);\n for(Dock myDock : mySeaPort.getDocks()) {\n DefaultMutableTreeNode individualDockNode = new DefaultMutableTreeNode(myDock.getName());\n dockNode.add(individualDockNode);\n if(myDock.getShip() != null) {\n DefaultMutableTreeNode dockedShip = new DefaultMutableTreeNode(myDock.getShip().getName());\n individualDockNode.add(dockedShip);\n for(Job myJob : myDock.getShip().getJobs()) {\n DefaultMutableTreeNode dockedShipJob = new DefaultMutableTreeNode(myJob.getName());\n dockedShip.add(dockedShipJob);\n }\n }\n }\n\n DefaultMutableTreeNode portQueNode = new DefaultMutableTreeNode(\"Ship Queue\");\n individualPortNode.add(portQueNode);\n for(Ship myShip : mySeaPort.getQue()) {\n DefaultMutableTreeNode quedShip = new DefaultMutableTreeNode(myShip.getName());\n portQueNode.add(quedShip);\n for(Job myJob : myShip.getJobs()) {\n DefaultMutableTreeNode quedShipJob = new DefaultMutableTreeNode(myJob.getName());\n quedShip.add(quedShipJob);\n }\n }\n\n } //end of initial for loop inside createTree() method\n\n /*This method call is added in case a user reads a new data file after they\n have already read one or more data files.\n */\n myTreePanel.removeAll();\n\n //Add everything to the myTreePanel\n JScrollPane myTreeScroll = new JScrollPane(myTree);\n myTreePanel.add(myTreeScroll, BorderLayout.CENTER);\n validate();\n }", "@Test\n public void testCreateDraftWithParent()\n {\n if (projects.size() > 0)\n {\n Project project = projects.get(0);\n Assert.assertNotNull(project);\n\n Set<Resource> all = resourcesManager.getDraftResources(project\n .getId());\n Assert.assertNotNull(all);\n\n if (all.isEmpty())\n {\n resourcesManager.createResource(project.getId(), -1,\n builder.buildResource(ResourceKind.FOLDER));\n all = resourcesManager.getResources(project.getId());\n }\n\n Resource parent = all.iterator().next();\n Assert.assertNotNull(parent);\n\n if (parent.getKind().equals(ResourceKind.FOLDER))\n {\n Set<Resource> childs = parent.getChilds();\n Assert.assertNotNull(childs);\n\n Resource newResource = builder.buildResource(ResourceKind.FILE);\n Assert.assertNotNull(newResource);\n\n Resource created = resourcesManager.createResource(\n project.getId(), parent.getId(), newResource);\n\n Assert.assertNotNull(created);\n Assert.assertNotNull(created.getId());\n Assert.assertNotNull(created.getUrl());\n\n Set<Resource> allNow = resourcesManager\n .getDraftResources(project.getId());\n\n Assert.assertNotNull(allNow);\n Assert.assertEquals(all.size(), allNow.size());\n\n parent = created.getParent();\n Assert.assertNotNull(parent);\n\n Assert.assertEquals(childs.size() + 1, parent.getChilds()\n .size());\n\n log.info(\"Check subversion url :\" + created.getUrl());\n }\n }\n else\n {\n fail(\"There is not projects.\");\n }\n\n }", "private static void addToProjectStructure(IProject newProject, String[] paths) throws CoreException {\n for (String path : paths) {\n IFolder etcFolders = newProject.getFolder(path);\n createFolder(etcFolders);\n }\n }", "public void testNewJavaProject() {\n NewProjectWizardOperator.invoke().cancel();\n NewProjectWizardOperator npwo = NewProjectWizardOperator.invoke();\n // \"Standard\"\n String standardLabel = Bundle.getStringTrimmed(\"org.netbeans.modules.java.j2seproject.ui.wizards.Bundle\", \"Templates/Project/Standard\");\n npwo.selectCategory(standardLabel);\n // \"Java Application\"\n String javaApplicationLabel = Bundle.getStringTrimmed(\"org.netbeans.modules.java.j2seproject.ui.wizards.Bundle\", \"template_app\");\n npwo.selectProject(javaApplicationLabel);\n npwo.next();\n NewJavaProjectNameLocationStepOperator npnlso = new NewJavaProjectNameLocationStepOperator();\n npnlso.txtProjectName().setText(SAMPLE_PROJECT_NAME);\n npnlso.txtProjectLocation().setText(System.getProperty(\"netbeans.user\")); // NOI18N\n npnlso.btFinish().pushNoBlock();\n npnlso.getTimeouts().setTimeout(\"ComponentOperator.WaitStateTimeout\", 120000);\n npnlso.waitClosed();\n // wait project appear in projects view\n new ProjectsTabOperator().getProjectRootNode(SAMPLE_PROJECT_NAME);\n\n //disable the compile on save:\n ProjectsTabOperator.invoke().getProjectRootNode(SAMPLE_PROJECT_NAME).properties();\n // \"Project Properties\"\n String projectPropertiesTitle = Bundle.getStringTrimmed(\"org.netbeans.modules.java.j2seproject.ui.customizer.Bundle\", \"LBL_Customizer_Title\");\n NbDialogOperator propertiesDialogOper = new NbDialogOperator(projectPropertiesTitle);\n // select \"Compile\" category\n String buildCategoryTitle = Bundle.getStringTrimmed(\"org.netbeans.modules.java.j2seproject.ui.customizer.Bundle\", \"LBL_Config_BuildCategory\");\n String compileCategoryTitle = Bundle.getStringTrimmed(\"org.netbeans.modules.java.j2seproject.ui.customizer.Bundle\", \"LBL_Config_Build\");\n new Node(new Node(new JTreeOperator(propertiesDialogOper), buildCategoryTitle), compileCategoryTitle).select();\n // actually disable the quick run:\n String compileOnSaveLabel = Bundle.getStringTrimmed(\"org.netbeans.modules.java.j2seproject.ui.customizer.Bundle\", \"CustomizerCompile.CompileOnSave\");\n JCheckBox cb = JCheckBoxOperator.waitJCheckBox((Container) propertiesDialogOper.getSource(), compileOnSaveLabel, true, true);\n if (cb.isSelected()) {\n cb.doClick();\n }\n // confirm properties dialog\n propertiesDialogOper.ok();\n\n // wait classpath scanning finished\n PerfWatchProjects.waitScanFinished();\n }", "@Test\n public void testCreateDependencyTree2() {\n Map<String, Integer> expected = new HashMap<>() {{\n put(\"github.com/jfrog/gocmd:0.1.12\", 2);\n }};\n try {\n Path projectDir = GO_ROOT.resolve(\"project2\");\n GoTreeBuilder treeBuilder = new GoTreeBuilder(null, projectDir, projectDir.resolve(\"go.mod\").toString(), null, log);\n DepTree dt = treeBuilder.buildTree();\n validateDependencyTreeResults(expected, dt);\n } catch (IOException ex) {\n fail(ExceptionUtils.getStackTrace(ex));\n }\n }", "public CreateProject() {\n\t\tsuper();\n\t}", "public SelectProjectWizardPage build() {\r\n return new SelectProjectWizardPage(this);\r\n }", "private Project(){}", "public static void main (String []args){\n\t\tString root = \"/home/weslley/ArtigoGroundHog2015/LogProjetos2015\";\n\t\tString rootCompleto = \"/home/weslley/mestrado2014/FinalProjects\";\n\t\t//String listaProjetosSemData = \"/home/weslley/ArtigoGroundHog2015/projectsNames2015.txt\";\n\n\t\t//Para alguns projetos nao datados\n/*\t\tVector<String> listaProjetosNaoDatados = null;\n\t\ttry {\n\t\t\tlistaProjetosNaoDatados = readProjectsNames();\n\t\t} catch (IOException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n*/\n\t\tFile folder = new File(root);\n\t\tFile folderCompleto = new File(rootCompleto);\n\n\t\tint x = 0;\n\t\tFile firstLevel[] = folder.listFiles();\n\t\tFile firstLevelCompleto[] = folderCompleto.listFiles();\n\n\t\tboolean completed = true;\n\n\t\tfor (int i = 0; i < firstLevel.length; i++){\n\n\t\t\t//if(listaProjetosNaoDatados.contains(firstLevel[i].getName())){\n\n\t\t\t\tFile projetoDatado=null;\n\t\t\t\ttry {\n\t\t\t\t\tprojetoDatado = findFile(firstLevelCompleto, firstLevel[i].getName());\n\t\t\t\t} catch (IOException e) {\n\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\n\t\t\t\tif(projetoDatado!=null){\n\n\t\t\t\t\tFile secondLevel[] = firstLevel[i].listFiles();\n\t\t\t\t\t//System.out.println(firstLevel[i].getName());\n\t\t\t\t\tif (secondLevel != null){\n\t\t\t\t\t\tfor(int j = 0; j < secondLevel.length && completed; j++){\n\t\t\t\t\t\t\t//System.out.println(secondLevel[j].getName());\n\t\t\t\t\t\t\tif (secondLevel[j].getName().compareTo(\".DS_Store\") != 0){\n\t\t\t\t\t\t\t\tFile thirdLevel[] = secondLevel[j].listFiles();\n\t\t\t\t\t\t\t\tx++;\n\t\t\t\t\t\t\t\tfor (int k = 0;thirdLevel!=null && k < thirdLevel.length && completed; k++){\n\t\t\t\t\t\t\t\t\tif (thirdLevel[k].getName().compareTo(\".DS_Store\") != 0){\n\t\t\t\t\t\t\t\t\t\tif (!(thirdLevel[k].getName().startsWith(\"[\") && thirdLevel[k].getName().contains(\"]\"))){\n\n\t\t\t\t\t\t\t\t\t\t\t//File secondLevelCompleto[] = projetoDatado.listFiles();\n\t\t\t\t\t\t\t\t\t\t\tFile secondLevelCompletoAuxiliar;\n\t\t\t\t\t\t\t\t\t\t\tFile thirdLevelCompletoAuxiliar;\n\t\t\t\t\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\t\t\t\t\tsecondLevelCompletoAuxiliar = findFile(projetoDatado.listFiles(), secondLevel[j].getName());\n\t\t\t\t\t\t\t\t\t\t\t\tif(secondLevelCompletoAuxiliar!=null){\n\t\t\t\t\t\t\t\t\t\t\t\t\tthirdLevelCompletoAuxiliar = findFile(secondLevelCompletoAuxiliar.listFiles(), thirdLevel[k].getName());\n\n\t\t\t\t\t\t\t\t\t\t\t\t\tif (thirdLevelCompletoAuxiliar!=null && thirdLevelCompletoAuxiliar.getName().startsWith(\"[\") && thirdLevelCompletoAuxiliar.getName().contains(\"]\")){\n\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tif(thirdLevelCompletoAuxiliar!=null && (thirdLevelCompletoAuxiliar.getName().endsWith(thirdLevel[k].getName()) || (compararProjetoSemExtensao(thirdLevelCompletoAuxiliar.getName(),thirdLevel[k].getName() )))){\n\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tFile rename = new File(thirdLevel[k].getParent() + \"/\" + thirdLevelCompletoAuxiliar.getName());\n\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tthirdLevel[k].renameTo(rename);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tString novoNome = thirdLevel[k].getName();\n\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t}catch (IOException e) {\n\t\t\t\t\t\t\t\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\t\t\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}//System.out.println(\"asdasd\" + x);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t//}\n\n\t\t\t}\n\t\t}\n\t}", "@Override\r\n\tpublic void buildTree() {\r\n\t\t\r\n\t\t// root level \r\n\t\trootNode = new TreeNode<String>(\"\");\r\n\t\t\r\n\t\t//first level\r\n\t\tinsert(\".\", \"e\");\r\n\t\tinsert(\"-\", \"t\");\r\n\t\t\r\n\t\t//second level\r\n\t\t\r\n\t\tinsert(\". .\", \"i\");\r\n\t\tinsert(\".-\", \"a\");\r\n\t\tinsert(\"-.\", \"n\"); \r\n\t\tinsert(\"--\", \"m\");\r\n\t\t\r\n\t\t//third level\r\n\t\tinsert(\"...\", \"s\");\r\n\t\tinsert(\"..-\", \"u\");\r\n\t\tinsert(\".-.\", \"r\");\r\n\t\tinsert(\".--\", \"w\");\r\n\t\tinsert(\"-..\", \"d\");\r\n\t\tinsert(\"-.-\", \"k\");\r\n\t\tinsert(\"--.\", \"g\");\r\n\t\tinsert(\"---\", \"o\");\r\n\t\t\r\n\t\t//fourth level\r\n\t\tinsert(\"....\", \"h\");\r\n\t\tinsert(\"...-\", \"v\");\r\n\t\tinsert(\"..-.\", \"f\");\r\n\t\tinsert(\".-..\", \"l\");\r\n\t\tinsert(\".--.\", \"p\");\r\n\t\tinsert(\".---\", \"j\");\r\n\t\tinsert(\"-...\", \"b\");\r\n\t\tinsert(\"-..-\", \"x\");\r\n\t\tinsert(\"-.-.\", \"c\");\r\n\t\tinsert(\"-.--\", \"y\");\r\n\t\tinsert(\"--..\", \"z\");\r\n\t\tinsert(\"--.-\", \"q\");\r\n\t\t\r\n\t}", "public void testVerifyExpectedParentStructure()\n throws CycleDetectedException, DuplicateProjectException\n {\n ProjectDependencyGraph graph = threeProjectsDependingOnASingle();\n final List<MavenProject> sortedProjects = graph.getSortedProjects();\n assertEquals( aProject, sortedProjects.get( 0 ) );\n assertEquals( depender1, sortedProjects.get( 1 ) );\n assertEquals( depender2, sortedProjects.get( 2 ) );\n assertEquals( depender3, sortedProjects.get( 3 ) );\n }", "public BuildTree createBuildTree(int maxElements) {\n BuildTree buildTree = new BuildTree();\n createBuildTree(0, buildTree, maxElements);\n return buildTree;\n }", "public void getProject(){\n\t\n\t String getList[] = clientFacade.GetProjects().split(\"\\n\");\n\t DefaultComboBoxModel addPro = new DefaultComboBoxModel();\n\t\tfor(int i=1; i<getList.length; i+=2) \n\t\t\t addPro.addElement(getList[i]);\n\t\t\t \n\t\tcPro.setModel(addPro);\t\n\t}", "public void testBuildTreeDeepStructure() {\n TreeNode root = buildRootNodeFromFile(\"testWihManyLevels.js\");\n\n // Ensure the hierarchy is correct.\n assertEquals(\"suite1\", root.getNodeValue().getTestText());\n assertEquals(4, root.getChildCount());\n }", "List<EclipseProject> getProjects() {\n return getFlattenedProjects(selectedProjects);\n }", "public Project() {\n\t\t\n\t}", "public IProject getProject();", "private void crearTree(){\n tree= new Tree(\"PROGRAMAS\");\r\n tree.setImmediate(true);\r\n\r\n // Set tree to show the 'name' property as caption for items\r\n tree.setItemCaptionPropertyId(\"nombre\");\r\n \r\n tree.addValueChangeListener(e -> Notification.show(\"Value changed:\",String.valueOf(e.getProperty().getValue()),Type.TRAY_NOTIFICATION));\r\n\t}", "void subprojects(Action<? super ProjectPluginDependenciesSpec> configuration);", "void createProject(IProjectDescription description, IProject proj,\n\t\t\tIProgressMonitor monitor) throws CoreException,\n\t\t\tOperationCanceledException {\n\t\ttry {\n\n\t\t\tmonitor.beginTask(\"\", 2000);\n\n\t\t\tproj.create(description, new SubProgressMonitor(monitor, 1000));\n\n\t\t\tif (monitor.isCanceled()) {\n\t\t\t\tthrow new OperationCanceledException();\n\t\t\t}\n\n\t\t\tproj.open(IResource.BACKGROUND_REFRESH, new SubProgressMonitor(\n\t\t\t\t\tmonitor, 1000));\n\n\t\t\t/*\n\t\t\t * Okay, now we have the project and we can do more things with it\n\t\t\t * before updating the perspective.\n\t\t\t */\n\t\t\tIContainer container = (IContainer) proj;\n\n\t\t\t/* Add an XHTML file */\n\t\t\t/*addFileToProject(container, new Path(\"index.html\"),\n\t\t\t\t\tJ15NewModel.openContentStream(\"Welcome to \"\n\t\t\t\t\t\t\t+ proj.getName(),\"5\"),monitor);*/\n\n\t\t\t/* Create the admin folder */\n\t\t\tfinal IFolder adminFolder = container.getFolder(new Path(\"admin\"));\n\t\t\tadminFolder.create(true, true, monitor);\n\t\t\t\n\t\t\tfinal IFolder adminModels = adminFolder.getFolder(new Path(\"models\"));\n\t\t\tadminModels.create(true, true, monitor);\n\t\t\t\n\t\t\tfinal IFolder adminControllers = adminFolder.getFolder(new Path(\"controllers\"));\n\t\t\tadminControllers.create(true, true, monitor);\n\t\t\t\n\t\t\tfinal IFolder adminViews = adminFolder.getFolder(new Path(\"views\"));\n\t\t\tadminViews.create(true, true, monitor);\n\t\t\t\n\t\t\tfinal IFolder adminTables = adminFolder.getFolder(new Path(\"tables\"));\n\t\t\tadminTables.create(true, true, monitor);\n\t\t\t\n\t\t\t/* Create the site folder */\n\t\t\tfinal IFolder siteFolder = container.getFolder(new Path(\"site\"));\n\t\t\tsiteFolder.create(true, true, monitor);\n\t\t\t\n\t\t\tfinal IFolder siteModels = siteFolder.getFolder(new Path(\"models\"));\n\t\t\tsiteModels.create(true, true, monitor);\n\t\t\t\n\t\t\tfinal IFolder siteViews = siteFolder.getFolder(new Path(\"views\"));\n\t\t\tsiteViews.create(true, true, monitor);\n\n\t\t\tInputStream resourceStream = this.getClass().getResourceAsStream(\n\t\t\t\t\t\"templates/blank-html.template\");\n\n\t\t\t/* Add blank HTML Files */\n\t\t\t\n\t\t\t/* Admin Folders first */\n\t\t\taddFileToProject(container, new Path(adminFolder.getName()\n\t\t\t\t\t+ Path.SEPARATOR + \"index.html\"),\n\t\t\t\t\tresourceStream, monitor);\n\t\t\t\n\t\t\tresourceStream.close();\n\t\t\tresourceStream = this.getClass().getResourceAsStream(\n\t\t\t\t\"templates/blank-html.template\");\n\t\t\t\n\t\t\taddFileToProject(container, new Path(adminFolder.getName()\n\t\t\t\t\t+ Path.SEPARATOR + adminModels.getName()\n\t\t\t\t\t+ Path.SEPARATOR + \"index.html\"),\n\t\t\t\t\tresourceStream, monitor);\n\t\t\t\n\t\t\tresourceStream.close();\n\t\t\tresourceStream = this.getClass().getResourceAsStream(\n\t\t\t\t\"templates/blank-html.template\");\n\t\t\t\n\t\t\taddFileToProject(container, new Path(adminFolder.getName()\n\t\t\t\t\t+ Path.SEPARATOR + adminControllers.getName()\n\t\t\t\t\t+ Path.SEPARATOR + \"index.html\"),\n\t\t\t\t\tresourceStream, monitor);\n\t\t\t\n\t\t\tresourceStream.close();\n\t\t\tresourceStream = this.getClass().getResourceAsStream(\n\t\t\t\t\"templates/blank-html.template\");\n\t\t\t\n\t\t\taddFileToProject(container, new Path(adminFolder.getName()\n\t\t\t\t\t+ Path.SEPARATOR + adminViews.getName()\n\t\t\t\t\t+ Path.SEPARATOR + \"index.html\"),\n\t\t\t\t\tresourceStream, monitor);\n\t\t\t\n\t\t\tresourceStream.close();\n\t\t\tresourceStream = this.getClass().getResourceAsStream(\n\t\t\t\t\"templates/blank-html.template\");\n\t\t\t\n\t\t\taddFileToProject(container, new Path(adminFolder.getName()\n\t\t\t\t\t+ Path.SEPARATOR + adminTables.getName()\n\t\t\t\t\t+ Path.SEPARATOR + \"index.html\"),\n\t\t\t\t\tresourceStream, monitor);\n\t\t\t\n\t\t\tresourceStream.close();\n\t\t\tresourceStream = this.getClass().getResourceAsStream(\n\t\t\t\t\"templates/blank-html.template\");\n\t\t\t\n\t\t\t/* Now the site folders */\n\t\t\taddFileToProject(container, new Path(siteFolder.getName()\n\t\t\t\t\t+ Path.SEPARATOR + \"index.html\"),\n\t\t\t\t\tresourceStream, monitor);\n\t\t\t\n\t\t\tresourceStream.close();\n\t\t\tresourceStream = this.getClass().getResourceAsStream(\n\t\t\t\t\"templates/blank-html.template\");\n\t\t\t\n\t\t\taddFileToProject(container, new Path(siteFolder.getName()\n\t\t\t\t\t+ Path.SEPARATOR + siteModels.getName()\n\t\t\t\t\t+ Path.SEPARATOR + \"index.html\"),\n\t\t\t\t\tresourceStream, monitor);\n\t\t\t\n\t\t\tresourceStream.close();\n\t\t\tresourceStream = this.getClass().getResourceAsStream(\n\t\t\t\t\"templates/blank-html.template\");\n\n\t\t\taddFileToProject(container, new Path(siteFolder.getName()\n\t\t\t\t\t+ Path.SEPARATOR + siteViews.getName()\n\t\t\t\t\t+ Path.SEPARATOR + \"index.html\"),\n\t\t\t\t\tresourceStream, monitor);\n\t\t\t\n\t\t\tresourceStream.close();\n\n\t\t\t/* All over! */\n\t\t} catch (IOException ioe) {\n\t\t\tIStatus status = new Status(IStatus.ERROR, \"J15Wizard\", IStatus.OK,\n\t\t\t\t\tioe.getLocalizedMessage(), null);\n\t\t\tthrow new CoreException(status);\n\t\t} finally {\n\t\t\tmonitor.done();\n\t\t}\n\t}", "public Map<String, ArrayList<CodeInfo>> getProjectNodes(final String esResultJson) {\n JsonArray hitsArray = getJsonElements(esResultJson);\n\n Map<String, ArrayList<CodeInfo>> projectNodes = new HashMap<String, ArrayList<CodeInfo>>();\n for (JsonElement hits : hitsArray) {\n JsonObject hitObject = hits.getAsJsonObject();\n JsonObject sourceObject = hitObject.getAsJsonObject(SOURCE);\n String fileName = sourceObject.getAsJsonPrimitive(\"file\").getAsString();\n //Extracting repoIds for future use\n int repoId = sourceObject.getAsJsonPrimitive(REPO_ID).getAsInt();\n if(repoId < 0){\n continue;\n }\n String project = getProjectName(fileName);\n if (!windowObjects.getRepoNameIdMap().containsKey(project)) {\n windowObjects.getRepoNameIdMap().put(project, repoId);\n }\n\n String methodUrl = sourceObject.getAsJsonPrimitive(\"method\").getAsString();\n String linesRange = methodUrl.split(\"#\")[1];\n String[] startEnd= linesRange.split(\"-\");\n String start = startEnd[0].substring(1);\n String end = startEnd[1];\n\n ArrayList<CodeInfo> projectCodeInfos = projectNodes.get(project);\n if(projectCodeInfos == null){\n projectCodeInfos = new ArrayList<CodeInfo>();\n projectNodes.put(project, projectCodeInfos);\n }\n projectCodeInfos.add(new CodeInfo(fileName, Integer.parseInt(start), Integer.parseInt(end)));\n }\n return projectNodes;\n }", "public static void build ()\r\n {\r\n lgt.insert(1);\r\n lgt.insert(2);\r\n lgt.insert(5);\r\n \r\n lgt.findRoot();\r\n lgt.insert(3);\r\n \r\n lgt.findRoot();\r\n lgt.insert(4);\r\n \r\n lgt.insert(6);\r\n lgt.findParent();\r\n lgt.insert(7);\r\n \r\n }", "private void browseProject()\n {\n List<FileFilter> filters = new ArrayList<>();\n filters.add(new FileNameExtensionFilter(\"Bombyx3D project file\", \"yml\"));\n\n File directory = new File(projectPathEdit.getText());\n File selectedFile = FileDialog.chooseOpenFile(this, BROWSE_DIALOG_TITLE, directory, filters);\n if (selectedFile != null) {\n projectDirectory = selectedFile.getParentFile();\n projectPathEdit.setText(projectDirectory.getPath());\n projectPathEdit.selectAll();\n }\n }", "default void buildMainBuildModules() {\n var main = bach().project().spaces().main();\n var modules = main.declarations();\n if (modules.isEmpty()) {\n log(\"Main module list is empty, nothing to build here.\");\n return;\n }\n var s = modules.size() == 1 ? \"\" : \"s\";\n say(\"Build %d main module%s: %s\", modules.size(), s, modules.toNames(\", \"));\n\n var release = main.release();\n var feature = release != 0 ? release : Runtime.version().feature();\n var classes = bach().folders().workspace(\"classes-main-\" + feature);\n\n var workspaceModules = bach().folders().workspace(\"modules\");\n Paths.deleteDirectories(workspaceModules);\n if (feature == 8) {\n bach().run(buildMainJavac(9, classes)).requireSuccessful();\n buildMainSpaceClassesForJava8(classes);\n } else {\n bach().run(buildMainJavac(release, classes)).requireSuccessful();\n }\n\n Paths.createDirectories(workspaceModules);\n var jars = new ArrayList<Jar>();\n var javacs = new ArrayList<Javac>();\n for (var declaration : modules.map().values()) {\n for (var folder : declaration.sources().list()) {\n if (!folder.isTargeted()) continue;\n javacs.add(buildMainJavac(declaration, folder, classes));\n }\n jars.add(buildMainJar(declaration, classes));\n }\n if (!javacs.isEmpty()) bach().run(javacs.stream()).requireSuccessful();\n bach().run(jars.stream()).requireSuccessful();\n }", "private void buildRoot() {\n this.root = new GPRootTreeNode(this.tree);\n }", "protected void createTree() {\n\n\t\tint nextPlayer = opponent;\n\n\t\tQueue<Node> treeQueue = new LinkedList<Node>();\n\t\tWinChecker winCheck = new WinChecker();\n\n\t\ttreeQueue.add(parent);\n\n\t\twhile (!treeQueue.isEmpty()) {\n\t\t\tNode currentNode = treeQueue.poll();\n\n\t\t\tif (currentNode.getMove().Row != -1\n\t\t\t\t\t&& currentNode.getMove().Col != -1) {\n\t\t\t\tgb.updateBoard(currentNode.getMove());\n\n\t\t\t\tif (winCheck.getWin(gb) >= 0) {\n\t\t\t\t\tgb.revertBoard(currentNode.getMove());\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\tgb.revertBoard(currentNode.getMove());\n\t\t\t}\n\n\t\t\t// Restricting the depth to which we will create the tree\n\t\t\tif (currentNode.getPly() > 2) {\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tfor (List<Hexagon> tempList : this.gb.getBoard()) {\n\t\t\t\tfor (Hexagon tempHex : tempList) {\n\n\t\t\t\t\tif (tempHex == null) {\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\n\t\t\t\t\tif (tempHex.getValue() == EMPTY) {\n\n\t\t\t\t\t\tif (currentNode.getPly() % 2 == 0) {\n\t\t\t\t\t\t\tnextPlayer = opponent;\n\t\t\t\t\t\t} else if (currentNode.getPly() % 2 == 1) {\n\t\t\t\t\t\t\tnextPlayer = player;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tMove nextMove = new Move(nextPlayer, false,\n\t\t\t\t\t\t\t\ttempHex.getRow(), tempHex.getColumn());\n\n\t\t\t\t\t\tNode newNode = new Node(currentNode.getPly() + 1,\n\t\t\t\t\t\t\t\tnextMove);\n\t\t\t\t\t\tnewNode.setParent(currentNode);\n\n\t\t\t\t\t\tcurrentNode.children.add(newNode);\n\n\t\t\t\t\t\ttreeQueue.add(newNode);\n\t\t\t\t\t\ttempHex.setValue(EMPTY);\n\t\t\t\t\t}// End of if statement\n\n\t\t\t\t}// End of inner ForLoop\n\t\t\t}// End of outer ForLoop\n\n\t\t\t// currentNode.printChildren();\n\n\t\t}// End of While Loop\n\n\t}", "public static List<ProjectVersion1> convertProjects(List<ProjectView> projectViewList) {\n List<ProjectVersion1> returnProjects = new ArrayList<ProjectVersion1>();\n if (projectViewList != null) {\n Iterator<ProjectView> projectViewIterator = projectViewList.iterator();\n while (projectViewIterator.hasNext()) {\n ProjectView projectView = projectViewIterator.next();\n returnProjects.add(new ProjectWrapper(projectView));\n }\n }\n\n return returnProjects;\n }", "private Node buildIntraGroupTree(int groupId, int index) {\n Set<Integer> executorsHostingTask = getExecutorsHostingTask(groupId);\n List<Integer> executorIds = rotateList(\n new ArrayList<>(executorsHostingTask), index);\n\n if (executorIds.size() == 0) {\n return null;\n }\n // sort the taskIds to make sure everybody creating the same tree\n Collections.sort(executorIds);\n // now check weather root is part of this group\n int rootExecutor = logicalPlan.getWorkerForForLogicalId(root);\n if (executorIds.contains(rootExecutor)) {\n // move the executor to 0\n executorIds.remove(new Integer(rootExecutor));\n executorIds.add(0, rootExecutor);\n }\n\n int execLevel = 0;\n // create the root of the tree\n Node rootNode = createTreeNode(groupId, executorIds.get(0), index);\n rootNode.setExecLevel(execLevel);\n // now lets create the tree\n Queue<Node> queue = new LinkedList<>();\n Node current = rootNode;\n int i = 1;\n while (i < executorIds.size()) {\n if (current.getChildren().size() < intraNodeDegree) {\n // create a tree node and add it to the current node as a child\n Node e = createTreeNode(groupId, executorIds.get(i), index);\n current.addChild(e);\n e.setParent(current);\n e.setExecLevel(execLevel);\n queue.add(e);\n i++;\n } else {\n execLevel++;\n // the current node is filled, lets move to the next\n current = queue.poll();\n }\n }\n\n if (execLevel > maxLevelsAtExecutor) {\n maxLevelsAtExecutor = execLevel;\n }\n\n return rootNode;\n }", "public Project() {\n\t}", "public Project() {\n\t}", "public GraphQLObjectType createType(HibProject project) {\n\t\tBuilder root = newObject();\n\t\troot.name(PROJECT_TYPE_NAME);\n\t\tinterfaceTypeProvider.addCommonFields(root);\n\n\t\t// .name\n\t\troot.field(newFieldDefinition().name(\"name\").description(\"The name of the project\").type(GraphQLString));\n\n\t\t// .rootNode\n\t\troot.field(\n\t\t\tnewFieldDefinition()\n\t\t\t\t.name(\"rootNode\")\n\t\t\t\t.description(\"The root node of the project\")\n\t\t\t\t.type(new GraphQLTypeReference(NODE_TYPE_NAME))\n\t\t\t\t.argument(createLanguageTagArg(true))\n\t\t\t\t.argument(createNodeVersionArg())\n\t\t\t\t.dataFetcher(this::baseNodeFetcher));\n\n\t\treturn root.build();\n\t}", "public ProjectViewController(){\n InputStream request = appController.httpRequest(\"http://localhost:8080/project/getProject\", \"GET\");\n try {\n String result = IOUtils.toString(request, StandardCharsets.UTF_8);\n Gson gson = new Gson();\n this.projectModel = gson.fromJson(result, ProjectModel.class);\n } catch (IOException e) {\n e.printStackTrace();\n }\n }", "public void assignAndStartInitialProjects() {\n\t\tfor(Player p:players) {\n\t\t\tSubproject sp=drawProject();\n\t\t\tSubprojectField result=sp.setChip(p.removeChip());\n\t\t\tp.raiseScore(result.getAmountSZT());\n\t\t}\n\t}", "@Override\n\tpublic List<ProjectInfo> findAllProject() {\n\t\treturn sqlSession.selectList(\"cn.sep.samp2.project.findAllProject\");\n\t}", "public static ElementTreeSelectionDialog createHaxeSourceFoldersDialog(\r\n\t\t\tShell shell, IHaxeProject project) {\r\n\r\n\t\tif (project == null) {\r\n\t\t\tthrow new NullPointerException(\"Project parameter can't be null\");\r\n\t\t}\r\n\r\n\t\tElementTreeSelectionDialog dialog = createHaxeSourceFoldersDialog(shell);\r\n\r\n\t\t// Redefine root element\r\n\t\tdialog.setInput(project);\r\n\r\n\t\treturn dialog;\r\n\t}", "public Project createProjectFromPRJ() {\n\n\t\tSystem.out.println(\"Trying to load prj file with : \" + data_path + \" \" + projectName + \" \" + conceptName + \" \");\n\n\t\tProject project = null;\n\n\t\ttry {\n\n\t\t\tproject = new Project(data_path + projectName);\n\n\t\t\t// Sehr wichtig hier das Warten einzubauen, sonst gibts leere\n\t\t\t// Retrieval Results, weil die Faelle noch nicht geladen sind wenn\n\t\t\t// das\n\t\t\t// Erste Retrieval laueft\n\t\t\twhile (project.isImporting()) {\n\t\t\t\tThread.sleep(1000);\n\t\t\t\tSystem.out.print(\".\");\n\t\t\t}\n\t\t\tSystem.out.print(\"\\n\"); // console pretty print\n\t\t} catch (Exception ex) {\n\n\t\t\tSystem.out.println(\"Error when loading the project\");\n\t\t}\n\t\treturn project;\n\t}", "private Collection<EclipseProject> allProjects() {\n Collection<EclipseProject> all = new HashSet<EclipseProject>(selectedProjects);\n all.addAll(requiredProjects);\n return all;\n }", "GradleBuild create();", "private void generateSolution() {\n\t\t// TODO\n\n\t}", "public void constructHierarchy(){\n\t\t// populate parents for the globally defined param specs\n\t\tfor (ListIterator<ParamSpec> iterator = m_paramSpecs.listIterator(m_paramSpecs.size()); iterator.hasPrevious();) {\n\t\t\tParamSpec ps = iterator.previous();\n\t\t\tpopulateParent(ps);\n\t\t}\n\t\t// populate values for the globally defined param specs\n\t\tfor (ListIterator<ParamSpec> iterator = m_paramSpecs.listIterator(m_paramSpecs.size()); iterator.hasPrevious();) {\n\t\t\tParamSpec ps = iterator.previous();\n\t\t\tps.lookupValues();\n\t\t}\n\t\t\n\t\t// populate parents for the command specs and their contained param specs\n\t\tfor (CommandSpec cs : m_commandSpecs){\n\t\t\tpopulateParent(cs);\n\t\t\tif (cs.getParamSpecs() != null){\n\t\t\t\tfor (ParamSpec ps : cs.getParamSpecs()){\n\t\t\t\t\tpopulateParent(ps);\n\t\t\t\t}\n\t\t\t\tfor (ParamSpec ps : cs.getParamSpecs()){\n\t\t\t\t\tps.lookupValues();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "private void newProject()\n\t{\n\t\tnew FenetreCreationProjet();\n\t}", "public void buildClassTree() {\n\t\twriter.writeClassTree();\n\t}", "public RepositoryArtifact createProject(RepositoryConnector connector, String rootFolderId, String projectName, String processDefinitionXml) {\r\n RepositoryArtifact result = null;\r\n try {\r\n ZipInputStream projectTemplateInputStream = new ZipInputStream(getProjectTemplate());\r\n ZipEntry zipEntry = null;\r\n \r\n String rootSubstitution = null;\r\n \r\n while ((zipEntry = projectTemplateInputStream.getNextEntry()) != null) {\r\n String zipName = zipEntry.getName();\r\n if (zipName.endsWith(\"/\")) {\r\n zipName = zipName.substring(0, zipName.length() - 1);\r\n }\r\n String path = \"\";\r\n String name = zipName;\r\n if (zipName.contains(\"/\")) {\r\n path = zipName.substring(0, zipName.lastIndexOf(\"/\"));\r\n name = zipName.substring(zipName.lastIndexOf(\"/\") + 1);\r\n }\r\n if (\"\".equals(path)) {\r\n // root folder is named after the project, not like the\r\n // template\r\n // folder name\r\n rootSubstitution = name;\r\n name = projectName;\r\n } else {\r\n // rename the root folder in all other paths as well\r\n path = path.replace(rootSubstitution, projectName);\r\n }\r\n String absolutePath = rootFolderId + \"/\" + path;\r\n boolean isBpmnModel = false;\r\n if (zipEntry.isDirectory()) {\r\n connector.createFolder(absolutePath, name);\r\n } else {\r\n Content content = new Content();\r\n \r\n if (\"template.bpmn20.xml\".equals(name)) {\r\n // This file shall be replaced with the process\r\n // definition\r\n content.setValue(processDefinitionXml);\r\n name = projectName + \".bpmn20.xml\";\r\n isBpmnModel = true;\r\n log.log(Level.INFO, \"Create processdefinition from Signavio process model \" + projectName);\r\n } else {\r\n byte[] bytes = IoUtil.readInputStream(projectTemplateInputStream, \"ZIP entry '\" + zipName + \"'\");\r\n String txtContent = new String(bytes).replaceAll(REPLACE_STRING, projectName).replaceAll(\"@@ACTIVITI.HOME@@\", ACTIVITI_HOME_PATH);\r\n content.setValue(txtContent);\r\n }\r\n log.log(Level.INFO, \"Create new artifact from zip entry '\" + zipEntry.getName() + \"' in folder '\" + absolutePath + \"' with name '\" + name + \"'\");\r\n RepositoryArtifact artifact = connector.createArtifact(absolutePath, name, null, content);\r\n if (isBpmnModel) {\r\n result = artifact;\r\n }\r\n }\r\n projectTemplateInputStream.closeEntry();\r\n }\r\n projectTemplateInputStream.close();\r\n } catch (IOException ex) {\r\n throw new RepositoryException(\"Couldn't create maven project due to IO errors\", ex);\r\n }\r\n return result;\r\n }", "private <X extends Jgxx> X buildTree(X root) {\n\t\tList<X> list = this.extendedModelProvider.find(EXTEND_MODEL_XTGL_ZHGL_JGXX_CODE, Jgxx.class, SELECT_PRE_SQL + \" WHERE J.LFT BETWEEN ? AND ? AND J.DELETED = 0 ORDER BY J.LFT\",\n\t\t\t\troot.getLft(), root.getRgt());\n\t\tStack<X> rightStack = new Stack<X>();\n\t\tfor (X node : list) {\n\t\t\tif (!rightStack.isEmpty()) {\n\t\t\t\twhile (rightStack.lastElement().getRgt() < node.getRgt()) {\n\t\t\t\t\trightStack.pop();\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (!rightStack.isEmpty()) {\n\t\t\t\trightStack.lastElement().addChild(node);\n\t\t\t}\n\t\t\trightStack.push(node);\n\t\t}\n\t\treturn rightStack.firstElement();\n\t}", "public Project() { }", "private static void addProjectFiles(IProject newProject){\n \t//add README file\n \taddProjectFile(newProject , README_FILE_NAME , \"\" );\n \t//add ProviderClass\n \taddProjectFile(newProject , PROVIDER_SCRIPT_FILE_NAME , CLASSES_FOLDER+\"/\" );\n }", "public ProjectsPage() {\n\t\tthis.driver = DriverManager.getDriver();\n\t\tElementFactory.initElements(driver, this);\n\t\t// sets the name of the project to add, with a random integer ending for slight\n\t\t// ease on multiple test runs\n\t\tnameOfProject = \"testz2018\" + (int) Math.random() * 500;\n\t}", "public Project() {\n\n }", "protected IProject[] build(int kind, Map args, IProgressMonitor monitor) throws CoreException {\n \t\targuments = args;\n \t\tsuper.build(kind, args, monitor);\n \t\ttriggerForLastBuild = kind;\n \t\tIResourceDelta delta = getDelta(getProject());\n \t\trecordChangedResources(delta);\n \t\twasDeltaNull = delta == null;\n \n \t\tif (delta == null || kind == IncrementalProjectBuilder.FULL_BUILD) {\n \t\t\tfullBuild();\n \t\t} else {\n \t\t\ttry {\n \t\t\t\tincrementalBuild(delta);\n \t\t\t} catch (Exception e) {\n \t\t\t\tthrow new CoreException(new Status(IStatus.ERROR, \"tests\", IResourceStatus.BUILD_FAILED, \"Incremental build failed due to internal error\", e));\n \t\t\t}\n \t\t}\n \t\t//forget last built state if requested to do so\n \t\tif (requestForgetState) {\n \t\t\trequestForgetState = false;\n \t\t\tforgetLastBuiltState();\n \t\t}\n \t\tString project = (String) arguments.get(INTERESTING_PROJECT);\n \t\tif (project != null) {\n \t\t\treturn new IProject[] {getProject().getWorkspace().getRoot().getProject(project)};\n \t\t} else {\n \t\t\treturn new IProject[0];\n \t\t}\n \t}", "public String makeTree() {\r\n // Create a stack to store the files/directories in the tree\r\n Stack<DirectoryTreeNode> itemStack = new Stack<>();\r\n // Initialize a string variable to store the tree diagram\r\n String tree = \"\";\r\n // Push the root directory into the stack\r\n itemStack.push(this.rootDir);\r\n\r\n // Loop through the items in the Stack until all the items have been\r\n // traversed (this is similar to the pre-order traversal of the tree)\r\n while (!itemStack.isEmpty()) {\r\n // Get the item on the top of the stack and store it in current\r\n DirectoryTreeNode current = (DirectoryTreeNode) itemStack.pop();\r\n // Get the number of tabs required in the output for this item\r\n int numTabs = this.getNumberOfAncestors((E) current);\r\n // Get the string of tabs needed to put before current's name\r\n String tabs = this.getNumberOfTabs(numTabs);\r\n // Add the required number of tabs, the current item's of name and a\r\n // newline\r\n tree += tabs + current.getName() + \"\\n\";\r\n\r\n // Check if current is a Directory (in which case it may have\r\n // sub directories and files)\r\n if (current instanceof Directory) {\r\n // Get the list of files and directories of current directory\r\n ArrayList<DirectoryTreeNode> contents =\r\n ((Directory) current).getContents();\r\n // Loop through the contents of current and add them to the stack\r\n for (int i = contents.size() - 1; i >= 0; i--) {\r\n itemStack.add(contents.get(i));\r\n }\r\n }\r\n }\r\n // Return the generated tree diagram\r\n return tree;\r\n }", "private ObservableList<TreeItem<Path>> buildChildren() {\r\n if (Files.isDirectory(getValue())) {\r\n try {\r\n\r\n return Files.list(getValue())\r\n .map(FileTreeItem::new)\r\n .collect(Collectors.toCollection(() -> FXCollections.observableArrayList()));\r\n\r\n } catch (IOException e) {\r\n e.printStackTrace();\r\n return FXCollections.emptyObservableList();\r\n } \r\n }\r\n\r\n return FXCollections.emptyObservableList();\r\n }", "void kickProjectSourceGroups() {\n AntlrConfiguration config = AntlrConfiguration.forProject(project);\n Path path = FileUtil.toFile(dir).toPath();\n FoldersLookupStrategyImplementationFactory.evict(path);\n Sources src = ProjectUtils.getSources(project);\n if (src != null) {\n src.getSourceGroups(\"java\");\n src.getSourceGroups(\"antlr\");\n }\n LogicalViewProvider log = project.getLookup().lookup(LogicalViewProvider.class);\n Node view = log.createLogicalView();\n Children kids = view.getChildren();\n kids.getNodes(true);\n }", "private MavenModuleSet createMavenProject() throws IOException {\n MavenModuleSet mavenModuleSet = j.jenkins.createProject(MavenModuleSet.class, \"test\"+j.jenkins.getItems().size());\n mavenModuleSet.setRunHeadless(true);\n return mavenModuleSet;\n }", "@Test\n @org.junit.Ignore\n public void testProject_1()\n throws Exception {\n\n Project result = new Project();\n\n assertNotNull(result);\n assertEquals(null, result.getName());\n assertEquals(null, result.getWorkloadNames());\n assertEquals(null, result.getProductName());\n assertEquals(null, result.getComments());\n assertEquals(null, result.getCreator());\n assertEquals(0, result.getId());\n assertEquals(null, result.getModified());\n assertEquals(null, result.getCreated());\n }", "@Override\r\n protected void doCreate(boolean update) throws IOException, ServletException, Descriptor.FormException, InvalidProjectFileException {\r\n // Read the manage project file\r\n FileItem fileItem = getRequest().getFileItem(\"manageProject\");\r\n if (fileItem == null) {\r\n return;\r\n }\r\n\r\n manageFile = fileItem.getString();\r\n manageProject = new ManageProject(manageFile);\r\n manageProject.parse();\r\n\r\n getTopProject().setDescription(\"Top-level multi job to run the manage project: \" + getManageProjectName());\r\n String tmpLabel = getNodeLabel();\r\n if (tmpLabel == null || tmpLabel.isEmpty()) {\r\n tmpLabel = \"master\";\r\n }\r\n Label label = new LabelAtom(tmpLabel);\r\n getTopProject().setAssignedLabel(label);\r\n \r\n // Build actions...\r\n addSetup(getTopProject());\r\n // Add multi-job phases\r\n // Building...\r\n List<PhaseJobsConfig> phaseJobs = new ArrayList<>();\r\n \r\n projectsAdded = new ArrayList<>();\r\n projectsNeeded = new ArrayList<>();\r\n projectsExisting = new ArrayList<>();\r\n \r\n projectsAdded.add(getTopProject().getFullName());\n \r\n String baseName = getBaseName();\r\n if (getJobName() != null && !getJobName().isEmpty()) {\r\n baseName = getJobName();\r\n }\r\n\n String folderName = getTopProject().getParent().getFullName();\n if (folderName != null && !folderName.isEmpty()) {\n folderName = folderName + \"/\";\n }\n\n for (MultiJobDetail detail : manageProject.getJobs()) {\r\n String name = folderName + baseName + \"_\" + detail.getProjectName();\n projectsNeeded.add(name);\r\n PhaseJobsConfig phase = new PhaseJobsConfig(name, \r\n /*jobproperties*/\"\", \r\n /*currParams*/true, \r\n /*configs*/null, \r\n PhaseJobsConfig.KillPhaseOnJobResultCondition.NEVER, \r\n /*disablejob*/false, \r\n /*enableretrystrategy*/false, \r\n /*parsingrulespath*/null, \r\n /*retries*/0, \r\n /*enablecondition*/false, \r\n /*abort*/false, \r\n /*condition*/\"\", \r\n /*buildonly if scm changes*/false,\r\n /*applycond if no scm changes*/false);\r\n phaseJobs.add(phase);\r\n }\r\n MultiJobBuilder multiJobBuilder = new MultiJobBuilder(\"Build, Execute and Report\", phaseJobs, MultiJobBuilder.ContinuationCondition.COMPLETED);\r\n getTopProject().getBuildersList().add(multiJobBuilder);\r\n\r\n // Copy artifacts per building project\r\n for (MultiJobDetail detail : manageProject.getJobs()) {\r\n String name = folderName + baseName + \"_\" + detail.getProjectName();\n String tarFile = \"\";\r\n if (isUsingSCM()) {\r\n tarFile = \", \" + getBaseName() + \"_\" + detail.getProjectName() + \"_build.tar\";\r\n }\r\n CopyArtifact copyArtifact = new CopyArtifact(name);\r\n copyArtifact.setOptional(true);\r\n copyArtifact.setFilter(\"**/*_rebuild*,\" +\r\n \"execution/*.html, \" +\r\n \"management/*.html, \" +\r\n \"xml_data/**\" +\r\n tarFile);\r\n copyArtifact.setFingerprintArtifacts(false);\r\n BuildSelector bs = new WorkspaceSelector();\r\n copyArtifact.setSelector(bs);\r\n getTopProject().getBuildersList().add(copyArtifact);\r\n }\r\n addMultiJobBuildCommand();\r\n \r\n // Post-build actions if doing reporting\r\n if (getOptionUseReporting()) {\r\n addArchiveArtifacts(getTopProject());\r\n addXunit(getTopProject());\r\n addVCCoverage(getTopProject());\r\n addGroovyScriptMultiJob();\r\n }\r\n \r\n getTopProject().save();\r\n \r\n for (MultiJobDetail detail : manageProject.getJobs()) {\r\n String name = baseName + \"_\" + detail.getProjectName();\n createProjectPair(name, detail, update);\r\n }\r\n }", "public void build() {\r\n\tfDoingBatchBuild = true;\r\n\tfNotifier = new BuildNotifier(fDC, true);\r\n\tgetBuilderEnvironment().setNotifier(fNotifier);\r\n\tfNotifier.begin();\r\n\ttry {\r\n\t\tfNewState.readClassPath();\r\n\t\tfNotifier.subTask(Util.bind(\"build.scrubbingOutput\"/*nonNLS*/));\r\n\t\tfNewState.getBinaryOutput().scrubOutput();\r\n\t\tfNotifier.updateProgressDelta(0.05f);\r\n\t\tfNotifier.subTask(Util.bind(\"build.analyzingPackages\"/*nonNLS*/));\r\n\t\tfNewState.buildInitialPackageMap();\r\n\t\tfNotifier.updateProgressDelta(0.05f);\r\n\r\n\t\t/* Force build all in build context */\r\n\t\tfNotifier.subTask(Util.bind(\"build.analyzingSources\"/*nonNLS*/));\r\n\t\tIPackage[] pkgs = fNewState.getPackageMap().getAllPackagesAsArray();\r\n\t\tfor (int i = 0; i < pkgs.length; ++i) {\r\n\t\t\tfNotifier.checkCancel();\r\n\t\t\tSourceEntry[] entries = fNewState.getSourceEntries(pkgs[i]);\r\n\t\t\tif (entries != null) {\r\n\t\t\t\tfor (int j = 0; j < entries.length; ++j) {\r\n\t\t\t\t\tSourceEntry sEntry = entries[j];\r\n\t\t\t\t\tif (sEntry.isSource()) {\r\n\t\t\t\t\t\tPackageElement element = fNewState.packageElementFromSourceEntry(sEntry);\r\n\t\t\t\t\t\tfWorkQueue.add(element);\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\tfNotifier.updateProgressDelta(0.05f);\r\n\t\tVector vToCompile = fWorkQueue.getElementsToCompile();\r\n\t\tif (vToCompile.size() > 0) {\r\n\t\t\tfNotifier.setProgressPerCompilationUnit(0.75f / vToCompile.size());\r\n\t\t\tcompile(vToCompile);\r\n\t\t}\r\n\t\t/* Copy resources to binary output */\r\n\t\tnew ProjectResourceCopier(fNewState.getJavaProject(), fDC, fNotifier, 0.10f).copyAllResourcesOnClasspath();\r\n\t\t\r\n\t\tfNotifier.done();\r\n\t} finally {\r\n\t\tcleanUp();\r\n\t}\r\n}", "public GantBuilder ( final Project project ) { super ( project ) ; }" ]
[ "0.6242489", "0.6107362", "0.6107362", "0.6107362", "0.59571457", "0.5896064", "0.5841707", "0.57942164", "0.5755461", "0.57446057", "0.5735816", "0.5723281", "0.56952864", "0.5640102", "0.5623557", "0.561614", "0.56032634", "0.5594273", "0.5581402", "0.55710644", "0.55465966", "0.5546041", "0.554577", "0.5526672", "0.5493254", "0.54743063", "0.5450457", "0.5420631", "0.5395752", "0.536666", "0.5360475", "0.5344233", "0.53439105", "0.53327566", "0.53183097", "0.53163886", "0.5311094", "0.5307606", "0.52891403", "0.5244541", "0.5243187", "0.5227894", "0.5224721", "0.52052474", "0.5196151", "0.51946276", "0.51499367", "0.51491475", "0.51467675", "0.51436025", "0.513695", "0.5133749", "0.5123329", "0.5106501", "0.5091694", "0.50679", "0.5065115", "0.50366306", "0.50219125", "0.50035506", "0.5001324", "0.49982923", "0.49949163", "0.4993795", "0.49858195", "0.49843234", "0.49660182", "0.49626884", "0.4955124", "0.4950829", "0.4947093", "0.49354827", "0.49354827", "0.49338034", "0.49320891", "0.49255165", "0.49171737", "0.49105844", "0.49087176", "0.49020863", "0.4900475", "0.48991594", "0.4891791", "0.48886886", "0.48820195", "0.48804578", "0.48753494", "0.48721355", "0.48667064", "0.4865901", "0.4857099", "0.48455334", "0.48453027", "0.4844395", "0.48396745", "0.48388657", "0.4838125", "0.48253396", "0.48208404", "0.48199773" ]
0.7621011
0
Parse output of "ss.exe dir" command
private void parseTree(BufferedReader in, VssProject vssProject) { try { String line; boolean start = false; while ((line = in.readLine()) != null) { if (!start) { if (line.startsWith("$") && line.endsWith(":")) { start = true; continue; } } else { if (line.length() == 0) break; if (line.startsWith("$")) { String projectName = line.substring(1); if ( config.getProjectsToIgnore().contains( projectName ) ) { // Ignore list! LOG.warn( "Ignore project " + projectName + " found in : " + vssProject.getVssPath() ); continue; } VssProject newProject = new VssProject(); newProject.setName(projectName); newProject.setParent(vssProject); vssProject.addSubproject(newProject); } else { if (line.startsWith("No items found under $")) { continue; } String filename = line; String parent = vssProject.getVssPath().substring(config.getProject().length()); if (parent.length() > 0) { if (parent.startsWith("/")) parent = parent.substring(1); if (!parent.endsWith("/")) parent += "/"; } String path = parent + filename; VssFile newFile = new VssFile(path, filename); newFile.setParent(vssProject); vssProject.addFile(newFile); } } } } catch (IOException e) { throw new VssException("readLine", e); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public String dir() throws IOException {\n sendCommand(\"PWD\");\n String dir = null;\n String response = reader.readLine();\n if (response.startsWith(\"257 \")) {\n int firstQuote = response.indexOf('\\\"');\n int secondQuote = response.indexOf('\\\"', firstQuote + 1);\n if (secondQuote > 0) {\n dir = response.substring(firstQuote + 1, secondQuote);\n }\n }\n return dir;\n }", "public static ArrayList<String> command(final String cmdline,\n final String directory) {\n try {\n Process process = \n new ProcessBuilder(new String[] {\"bash\", \"-c\", cmdline})\n .redirectErrorStream(true)\n .directory(new File(directory))\n .start();\n\n ArrayList<String> output = new ArrayList<String>();\n BufferedReader br = new BufferedReader(\n new InputStreamReader(process.getInputStream()));\n String line = null;\n while ( (line = br.readLine()) != null ){\n\t\t\t\t//System.out.println(line);\n\t\t\t\toutput.add(line);\n\t\t\t}\n \n\n //There should really be a timeout here.\n if (0 != process.waitFor())\n return null;\n\n return output;\n\n } catch (Exception e) {\n //Warning: doing this is no good in high quality applications.\n //Instead, present appropriate error messages to the user.\n //But it's perfectly fine for prototyping.\n\n return null;\n }\n }", "public static String exec(String cmd, String dir) throws IOException {\n Logger.getInstance(SourcegraphUtil.class).debug(\"exec cmd='\" + cmd + \"' dir=\"+dir);\n\n // Create the process.\n Process p = Runtime.getRuntime().exec(cmd, null, new File(dir));\n BufferedReader stdout = new BufferedReader(new InputStreamReader(p.getInputStream()));\n BufferedReader stderr = new BufferedReader(new InputStreamReader(p.getErrorStream()));\n\n // Log any stderr output.\n Logger logger = Logger.getInstance(SourcegraphUtil.class);\n String s;\n while ((s = stderr.readLine()) != null) {\n logger.debug(s);\n }\n\n String out = \"\";\n //noinspection StatementWithEmptyBody\n for (String l; (l = stdout.readLine()) != null; out += l + \"\\n\");\n return out;\n }", "public Directory parseDirectory() {\n\n\t// Create a buffer for the result.\n\tDirectory result = new DirectoryImpl( this);\n\n\t// The track and sector pos of the currency directory sector.\n\tint trackIndex = 18;\n\tint sectorIndex = 1;\n\n\t// The directory starts at track 18, sector 1 and normally continues to sector 18.\n\twhile( ( trackIndex != 0) && (sectorIndex != 0)) {\n\n\t // Get the data of the current sector.\n\t byte [] sectorData = getSector( trackIndex, sectorIndex).getDataBytes();\n\n\t // Parse the directory entries in this sector.\n\t for( int currentEntry = 0; currentEntry < 8; ++currentEntry) {\n\n\t\t// Calculate the byte, where the directory entry starts.\n\t\tint entryOffset = 32 * currentEntry;\n\n\t\t// Check, if this entry is a deleted file.\n\t\tif( sectorData[ entryOffset + 2] == 0) { \n\n\t\t continue; // This entry is deleted.\n\t\t}\n\n\t\t// Get the name of the filename.\n\t\tStringBuffer filenameBuffer = new StringBuffer();\n\n\t\tfor( int filenameIndex = 5; filenameIndex <= 14; ++filenameIndex) {\n\n\t\t // Get the current byte of the filename.\n\t\t byte currentFilenameChar = sectorData[ entryOffset + filenameIndex];\n\n\t\t if( currentFilenameChar == 0xa0) { // This is a padding byte. Filename is complete.\n\t\t\t\n\t\t\tbreak;\n\n\t\t } else { // Convert this petscii char and add it to the filename.\n\t\t\t\n\t\t\tfilenameBuffer.append( CharsetUtils.getInstance().petscii2ascii( currentFilenameChar));\n\t\t }\n\t\t}\n\n\t\t// Get the type of the file.\n\t\tbyte currentFileType = (byte)( sectorData[ entryOffset + 2] & (byte)7);\n\t\tString currentFileTypeName = \"\";\n\n\t\tswitch( currentFileType) {\n\t\tcase 1: currentFileTypeName = \"SEQ\"; break;\n\t\tcase 2: currentFileTypeName = \"PRG\"; break;\n case 3: currentFileTypeName = \"USR\"; break;\n\t\tcase 4: currentFileTypeName = \"REL\"; break;\n\t\t}\n\n\t\t// Try to approximate the filesize. The c64 only stores blocks of 254 bytes and not \n\t\t// the actual filesize in bytes.\n\t\tint filesize = sectorData[ entryOffset + 0x1e] + ( 256 * sectorData[ entryOffset + 0x1f]);\n\t\t\n\t\t// Create a directory entry and add it to the result.\n\t\tresult.addDirectoryEntry( new D64DirectoryEntry( filenameBuffer.toString()\n\t\t\t\t\t\t\t\t , filesize\n\t\t\t\t\t\t\t\t , currentFileTypeName\n\t\t\t\t\t\t\t\t , sectorData[ entryOffset + 3] // Track index of the first sector.\n\t\t\t\t\t\t\t\t , sectorData[ entryOffset + 4] // Sector index of the first sector.\n\t\t\t\t\t\t\t\t , result));\n\t }\n\n\t // Get the track and sector of the next directory sector from the current sector;\n\t trackIndex = sectorData[ 0];\n\t sectorIndex = sectorData[ 1];\n\t}\n\n\t// Return the parsed directory.\n\treturn result;\n }", "private ShellStatus getCmdOutput() {\n ShellStatus status = RUNNING;\n\n while (!stdOut.buffer.isEmpty()) {\n String line = stdOut.buffer.remove(0);\n LOG.trace(String.format(\"lockId=%s, shell line:=%s \", lockId, line));\n\n if (\"END_OF_SCRIPT\".equals(line)) {\n if (!hasErrors()) {\n status = SUCCESS;\n } else {\n status = PSSHELL_ERROR;\n }\n } else {\n command.addOutputLine(line);\n }\n }\n\n if (!stdErr.buffer.isEmpty()) {\n while (!stdErr.buffer.isEmpty()) {\n String errorLine = stdErr.buffer.remove(0);\n LOG.trace(\"CallerId: \" + lockId + \" error line: \" + errorLine);\n command.addErrorLine(errorLine);\n }\n status = PSSHELL_ERROR;\n }\n\n command.setReturnCode(status);\n return status;\n }", "@Override\r\n\tpublic String ShowListCMD() {\n\t\treturn \"dir\";\r\n\t}", "public void setSsDir(String ssdir) {\n \t\tthis.ssdir = \"$\" + ssdir;\n \t}", "public void ParseDir(String dirname)\n\t{\n\t\ttry {\n\t\t\tfor(File f: getFileListing(new File(dirname)))\n\t\t\t{\n\t\t\t\tString s = readFileAsString(f.getAbsolutePath());\n\t\t\t\ts = filterComments(s);\n\t\t\t\tdna.setParser(this);\n\t\t\t\tdna.createFromString(s);\n\t\t\t}\n\t\t} catch (FileNotFoundException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\n\t}", "private Command parseCommand(String s) {\n\t\tif (constantMatch.matcher(s).matches()) {\n\t\t\treturn new Constant(Double.parseDouble(s));\n\t\t}\n\t\tif (variableMatch.matcher(s).matches()) {\n\t\t\treturn myDictionary.getVariable(s);\n\t\t}\n\t\tif (s.equals(START_LIST)) {\n\t\t\treturn createListCommand();\n\t\t}\n\t\tif(s.equals(START_GROUP)) {\n\t\t\tCommand c = getCommandOrFunction(codeReader.next());\n\t\t\tif(c.howManyArguments() <= 0) {\n\t\t\t\tthrow new SLogoException(\"Attempting to group command that takes no arguments\");\n\t\t\t}\n\t\t\tcreateGroupCommand(c); \n\t\t\treturn c;\n\t\t}\n\t\treturn findTrueCommand(s);\n\t}", "public String[] listDirectory( String directory, FileType type );", "public String parseSrc() throws Exception{\n\t\tr = new FileReader(userArg); \r\n\t\tst = new StreamTokenizer(r);\r\n\t\t st.eolIsSignificant(true);\r\n\t\t st.commentChar(46);\r\n\t\t st.whitespaceChars(9, 9);\r\n\t\t st.whitespaceChars(32, 32);\r\n\t\t st.wordChars(39, 39);\r\n\t\t st.wordChars(44, 44);\r\n\t\t \r\n\t\t //first we check for a specified start address\r\n\t\t while (InstructionsRead < 2) {\r\n\t\t \tif (st.sval != null) {\r\n\t\t \t\tInstructionsRead++;\r\n\t\t \t\tif (st.sval.equals(\"START\")) {\r\n\t\t \t\twhile(st.ttype != StreamTokenizer.TT_NUMBER) {\r\n\t\t \t\t\tst.nextToken();\r\n\t\t \t\t}\r\n\t\t \t\tDDnval = st.nval;\r\n\t\t \t\tstartAddress = Integer.parseInt(\"\" + DDnval.intValue(), 16);\r\n\t\t \t\tlocctr = startAddress;\r\n\t\t \t\tsLocctr = Integer.toHexString(locctr.intValue());\r\n\t\t \t\tif (sLocctr.length() == 1) {\r\n\t\t \t\t\tSystem.out.println(\"locctr: 000\" + Integer.toHexString(locctr.intValue()));\r\n\t\t \t\t}\r\n\t\t \t\telse if (sLocctr.length() == 2) {\r\n\t\t \t\t\tSystem.out.println(\"locctr: 00\" + Integer.toHexString(locctr.intValue()));\r\n\t\t \t\t}\r\n\t\t \t\telse if (sLocctr.length() == 3 ) {\r\n\t\t \t\t\tSystem.out.println(\"locctr: 0\" + Integer.toHexString(locctr.intValue()));\r\n\t\t \t\t}\r\n\t\t \t\telse {\r\n\t\t \t\t\tSystem.out.println(\"locctr: \" + Integer.toHexString(locctr.intValue()));\r\n\t\t \t\t}\r\n\t\t \t\t//writer.write(\"\" + locctr); //should write to IF, not working yet 2/15/2011\r\n\t\t \t\tstartSpecified = true;\r\n\t\t \t\t}\r\n\t\t \t\telse if (!st.sval.equals(\"START\") && InstructionsRead < 2) { //this should be the program name, also could allow for label here potentially...\r\n\t\t \t\t\t//this is the name of the program\r\n\t\t \t\t\t//search SYMTAB for label etc. \r\n\t\t \t\t\tname = st.sval;\r\n\t\t \t\t}\r\n\t\t \t}\r\n\t\t st.nextToken();\r\n\t\t }\r\n\t\t if (!startSpecified) {\r\n\t\t \tstartAddress = 0;\r\n\t\t \tlocctr = startAddress;\r\n\t\t }\r\n\t\t startAddress2 = startAddress;\r\n\t\t /*\r\n\t\t ATW = Integer.toHexString(startAddress2.intValue());\r\n\t\t \r\n\t\t for (int i = 0; i<(6-ATW.length()); i++){\r\n\t\t \tmyWriter.write(\"0\");\r\n\t\t }\r\n\t\t myWriter.write(ATW);\r\n\t\t myWriter.newLine();//end of line for now; in ReadIF when this line is read and translated to object code, the program length will be tacked on the end\r\n\t\t */\r\n\t\t \r\n\t\t //Now that startAddress has been established, we move on to the main parsing loop\r\n\t\t while (st.ttype != StreamTokenizer.TT_EOF) { //starts parsing to end of file\r\n\t\t \t//System.out.println(\"Stuck in eof\");\r\n\t\t \t//iLocctr = locctr.intValue();\r\n\t\t \tinstFound = false;\r\n\t\t \topcodeDone = false;\r\n\t\t \tlabelDone = false;\r\n\t\t \tmoveOn = true;\r\n\t\t \t//constantCaseW = false;\r\n\t\t \tconstantCaseB = false;\r\n\t\t \txfound = false;\r\n\t\t \tcfound = false;\r\n\t\t \t\r\n\t\t \tInstructionsRead = 0; //init InsRead to 0 at the start of each line\r\n\t\t \tSystem.out.println(\"new line\");\r\n\t\t \tSystem.out.println(\"Ins read: \" + InstructionsRead);\r\n\t\t \tsLocctr = Integer.toHexString(locctr.intValue());\r\n\t \t\tif (sLocctr.length() == 1) {\r\n\t \t\t\tSystem.out.println(\"locctr: 000\" + Integer.toHexString(locctr.intValue()));\r\n\t \t\t}\r\n\t \t\telse if (sLocctr.length() == 2) {\r\n\t \t\t\tSystem.out.println(\"locctr: 00\" + Integer.toHexString(locctr.intValue()));\r\n\t \t\t}\r\n\t \t\telse if (sLocctr.length() == 3 ) {\r\n\t \t\t\tSystem.out.println(\"locctr: 0\" + Integer.toHexString(locctr.intValue()));\r\n\t \t\t}\r\n\t \t\telse {\r\n\t \t\t\tSystem.out.println(\"locctr: \" + Integer.toHexString(locctr.intValue()));\r\n\t \t\t}\r\n\t\t \tif (foundEnd()) {\r\n\t\t \t\tbreak;\r\n\t\t \t}\r\n\t\t \twhile (st.ttype != StreamTokenizer.TT_EOL) {//breaks up parsing by lines so that InstructionsRead will be a useful count\r\n\t\t \t\t\r\n\t\t \t\tmoveOn = true;\r\n\t\t \t\tif (st.ttype == StreamTokenizer.TT_WORD) { \r\n\t\t \t\t\tInstructionsRead++;\r\n\t\t \t\t\tSystem.out.println(st.sval);\r\n\t\t \t\t\tSystem.out.println(\"Instructions Read: \" + InstructionsRead);\r\n\t\t \t\t\tif (foundEnd()) {\r\n\t\t \t\t\t\tbreak;\r\n\t\t \t\t\t}\r\n\t\t \t\t\t/*\r\n\t\t \t\t\t * The whole instructinsread control architecture doesn't quite work, because\r\n\t\t \t\t\t * the ST doesn't count the whitespace it reads in. This is by design because\r\n\t\t \t\t\t * the prof specified that whitespace is non-regulated and thus we cannot\r\n\t\t \t\t\t * predict exactly how many instances of char dec value 32 (space) will appear\r\n\t\t \t\t\t * before and/or between the label/instruction/operand 'fields'. \r\n\t\t \t\t\t * \r\n\t\t \t\t\t * What we could try alternatively is to structure the control around'\r\n\t\t \t\t\t * the optab, since it it static and populated pre-runtime. The schema might\r\n\t\t \t\t\t * go something like this: first convert whatever the sval or nval is to string.\r\n\t\t \t\t\t * Then call the optab.searchOpcode method with the resultant string as the input\r\n\t\t \t\t\t * parameter. If the string is in optab then it is an instruction and the ST is in the\r\n\t\t \t\t\t * instruction 'field' and boolean foundInst is set to true. If it is not in optab AND a boolean variable foundInst which resets to\r\n\t\t \t\t\t * false at the beginning of each new line is still false, then it is a label being declared in the label 'field'\r\n\t\t \t\t\t * If it is not in the optab AND foundInst is true, then the ST is at the operand 'field'.\r\n\t\t \t\t\t * This should work even if the prof has a crappy line with just a label declaration and no instruction or operand, because there\r\n\t\t \t\t\t * definitely cannot be an operand without an instruction...\r\n\t\t \t\t\t */\r\n\t\t \t\t\tif (instFound){\r\n\t\t \t\t\t\tprocessOperand(st);\r\n\t\t \t\t\t}\r\n\t\t \t\t\tif (!instFound) {//this is either label or instruction field\r\n\t\t \t\t\t\t//before anything, search optab to see if this might be the opcode\r\n\t\t \t\t\t\t//if it is an opcode, send it to the opcode processing function\r\n\t\t \t\t\t\tif (st.sval.equals(\"WORD\") || st.sval.equals(\"BYTE\")){//these are the directives... not technically instructions, but they go in the instruction field\r\n\t\t \t\t\t\t\tresCount = 0;\r\n\t\t \t\t\t\t\tif (st.sval.equals(\"WORD\")){\r\n\t\t \t\t\t\t\t\tif (hexDigitCount >= 55){\r\n\t\t \t\t\t\t\t\t\tnewTHandle();\r\n\t\t \t\t\t\t\t\t}\r\n\t\t \t\t\t\t\t\thexDigitCount += 6;\r\n\t\t \t\t\t\t\t}\r\n\t\t \t\t\t\t\tif (st.sval.equals(\"BYTE\")){\r\n\t\t \t\t\t\t\t\tconstantCaseB = true;\r\n\t\t \t\t\t\t\t}\r\n\t\t \t\t\t\t\tinstFound = true;\r\n\t\t \t\t\t\t\tprocessOpcode(st);\r\n\t\t \t\t\t\t}\r\n\t\t \t\t\t\telse if (st.sval.equals(\"RESW\") || st.sval.equals(\"RESB\")){//these are the directives... not technically instructions, but they go in the instruction field\r\n\t\t \t\t\t\t\tresCount++;\r\n\t\t \t\t\t\t\tnewTHandle();\r\n\t\t \t\t\t\t\tinstFound = true;\r\n\t\t \t\t\t\t\tprocessOpcode(st);\r\n\t\t \t\t\t\t}\r\n\t\t \t\t\t\telse if (optab.searchOpcode(st.sval)) {//if true this is the instruction\r\n\t\t \t\t\t\t\tresCount = 0;\r\n\t\t \t\t\t\t\tif (hexDigitCount >= 55){\r\n\t \t\t\t\t\t\t\tnewTHandle();\r\n\t \t\t\t\t\t\t}\r\n\t\t \t\t\t\t\thexDigitCount += 6;\r\n\t\t \t\t\t\t\tinstFound = true;\r\n\t\t \t\t\t\t\tprocessOpcode(st);\r\n\t\t \t\t\t\t\t//InstructionsRead++;\r\n\t\t \t\t\t\t}\r\n\t\t \t\t\t\telse {//otherwise this is the label\r\n\t\t \t\t\t\t\tprocessLabel(st);\r\n\t\t \t\t\t\t}\r\n\t\t \t\t\t\t\r\n\t\t \t\t\t\t\r\n\t\t \t\t\t\t\r\n\t\t \t\t\t}\r\n\t\t \t\t\t//else{ //if instFound is true, this must be the operand field\r\n\t\t \t\t\t\t\r\n\t\t \t\t\t\t//processOperand(st);\r\n\t\t \t\t\t//}\r\n\t\t \t\t\t//if (InstructionsRead == 3) {//this is the operand field\r\n\t\t \t\t\t\t//processOperand();\r\n\t\t \t\t\t\t\r\n\t\t \t\t\t//}\r\n\t\t \t\t}\r\n\t\t \t\t\r\n\t\t \t\tif (st.ttype == StreamTokenizer.TT_NUMBER) {\r\n\t\t \t\t\tInstructionsRead++;\r\n\t\t \t\t\tif (!instFound) {//this is either label or instruction field\r\n\t\t \t\t\t\t//before anything, search optab to see if this might be the opcode\r\n\t\t \t\t\t\t//if it is an opcode, send it to the opcode processing function\r\n\t\t \t\t\t\tif (NtoString(st.nval).equals(\"WORD\") || NtoString(st.nval).equals(\"BYTE\")){//these are the directives... not technically instructions, but they go in the instruction field\r\n\t\t \t\t\t\t\tresCount = 0;\r\n\t\t \t\t\t\t\tif (NtoString(st.nval).equals(\"WORD\")){\r\n\t\t \t\t\t\t\t\tif (hexDigitCount >= 55){\r\n\t\t \t\t\t\t\t\t\tnewTHandle();\r\n\t\t \t\t\t\t\t\t}\r\n\t\t \t\t\t\t\t\thexDigitCount += 6;\r\n\t\t \t\t\t\t\t}\r\n\t\t \t\t\t\t\tif (NtoString(st.nval).equals(\"BYTE\")){\r\n\t\t \t\t\t\t\t\tconstantCaseB = true;\r\n\t\t \t\t\t\t\t}\r\n\t\t \t\t\t\t\tinstFound = true;\r\n\t\t \t\t\t\t\tprocessOpcodeN(st);\r\n\t\t \t\t\t\t}\r\n\t\t \t\t\t\tif (NtoString(st.nval).equals(\"RESW\") || NtoString(st.nval).equals(\"RESB\")){//these are the directives... not technically instructions, but they go in the instruction field\r\n\t\t \t\t\t\t\tresCount++;\r\n\t\t \t\t\t\t\tnewTHandle();\r\n\t\t \t\t\t\t\tinstFound = true;\r\n\t\t \t\t\t\t\tprocessOpcodeN(st);\r\n\t\t \t\t\t\t}\r\n\t\t \t\t\t\telse if (optab.searchOpcode(\"\" + st.nval)) {\r\n\t\t \t\t\t\t\tresCount = 0;\r\n\t\t \t\t\t\t\tif (hexDigitCount >= 55){\r\n\t \t\t\t\t\t\t\tnewTHandle();\r\n\t \t\t\t\t\t\t}\r\n\t\t \t\t\t\t\thexDigitCount += 6;\r\n\t\t \t\t\t\t\tinstFound = true;\r\n\t\t \t\t\t\t\tprocessOpcodeN(st);\r\n\t\t \t\t\t\t\t//InstructionsRead++;\r\n\t\t \t\t\t\t}\r\n\t\t \t\t\t\telse {\r\n\t\t \t\t\t\t\tprocessLabelN(st);\r\n\t\t \t\t\t\t}\r\n\t\t \t\t\t\t\r\n\t\t \t\t\t}\r\n\t\t \t\t\telse{ //this is the operand field\r\n\t\t \t\t\t\tprocessOperandN(st);\r\n\t\t \t\t\t}\r\n\t\t \t\t}\r\n\t\t \t\t\r\n\t\t \tif (moveOn){\r\n\t\t \tst.nextToken(); //read next token in current line\r\n\t\t \t}\r\n\t\t \t}\r\n\t\t \t////write line just finished to IF eventually\r\n\t\t if (moveOn){\r\n\t\t st.nextToken(); //read first token of next line\t\r\n\t\t }\r\n\t\t }\r\n\t\t programLength = (locctr - startAddress); \r\n\t\t programLength2 = programLength;\r\n\t\t System.out.println(\" !!prgmlngth2:\" + Integer.toHexString(programLength2.intValue()));\r\n\t\t /*\r\n\t\t sProgramLength = Integer.toHexString(programLength2.intValue());\r\n\t\t for (int i = 0; i<(6-sProgramLength.length()); i++){\r\n\t\t \tmyWriter.write(\"0\");\r\n\t\t }\r\n\t\t myWriter.write(sProgramLength);\r\n\t\t myWriter.close();\r\n\t\t ////myWriter.close();\r\n\t\t \r\n\t\t */\r\n\t\t r.close();\r\n\t\t System.out.println(\"?????!?!?!?!?ALPHA?!?!?!?!?!??!?!?!\");\r\n\t\t if (hexDigitCount/2 < 16){\r\n\t\t \tlineLength.add(\"0\" + Integer.toHexString(hexDigitCount/2));\r\n\t\t }\r\n\t\t else{\r\n\t\t lineLength.add(Integer.toHexString(hexDigitCount/2));\r\n\t\t }\r\n\t\t for (int i = 0; i<lineLength.size(); i++){\r\n\t\t System.out.println(lineLength.get(i));\r\n\t\t }\r\n\t\t // System.out.println(hexDigitCount);\r\n\t\t ReadIF pass2 = new ReadIF(this.optab,this.symtab,this.startAddress2,this.programLength2,this.name,this.lineLength,this.userArg);\r\n\t\t return st.sval;\r\n\t\t \r\n\t\t\r\n\r\n\t}", "static ParsedCommand parseCommand(String cmdline) {\n ParsedCommand res = new ParsedCommand();\n cmdline = cmdline.trim();\n String[] split = cmdline.split(\"\\\\/([-]?[a-zA-Z]*)\");\n List<String> args = new ArrayList<>();\n for (int i = 0; i < split.length; i++) {\n String[] tmp = split[i].split(\" \");\n for (int j = 0; j < tmp.length; j++) {\n if (tmp[j].length() > 0) {\n args.add(tmp[j]);\n }\n }\n }\n if (args.size() == 0) return null;\n res.argv.addAll(args);\n Pattern p = Pattern.compile(\"\\\\/([-]?[a-zA-Z]*)\");\n Matcher m = p.matcher(cmdline);\n while (m.find()) {\n String cur = m.group(1);\n if (cur.startsWith(\"-\")) {\n for (int i = 1; i < cur.length(); i++) {\n res.switches.remove(String.valueOf(cur.charAt(i)).toUpperCase());\n }\n } else {\n for (int i = 0; i < cur.length(); i++) {\n res.switches.add(String.valueOf(cur.charAt(i)).toUpperCase());\n }\n }\n }\n\n return res;\n }", "private String[] nlstHelper(String args) {\n // Construct the name of the directory to list.\n String filename = currDirectory;\n if (args != null) {\n filename = filename + fileSeparator + args;\n }\n\n // Now get a File object, and see if the name we got exists and is a\n // directory.\n File f = new File(filename);\n\n if (f.exists() && f.isDirectory()) {\n return f.list();\n } else if (f.exists() && f.isFile()) {\n String[] allFiles = new String[1];\n allFiles[0] = f.getName();\n return allFiles;\n } else {\n return null;\n }\n }", "private static String[] collectInput() {\n\t\tString command = sc.next();\n\t\tString i = sc.next();\n\t\tString destination = sc.next();\n\t\treturn new String[] { command, destination };\n\t\t\n\t}", "public interface CLIResult {\n\n /**\n * Enumeration for the different types of streams to get output for,\n * including STDOUT and STDERR.\n */\n enum STREAM {\n STDOUT, STDERR;\n }\n\n /**\n * Get the output for the specified stream.\n * @param stream The {@link STREAM} to get output from.\n * @return A single String of the output.\n */\n String getOutput(STREAM stream);\n\n /**\n * Get standard output.\n * @return the standard output.\n */\n String getOutput();\n\n /**\n * Get the output for the specified stream split by lines.\n * @param stream The {@link STREAM} to get output from.\n * @return A List of Strings of output, one list item per line.\n */\n List<String> getOutputByLine(STREAM stream);\n\n /**\n * Get the exit value of the process that was run.\n * @return The exit value of the program that was run.\n */\n int exitValue();\n}", "public String[] do_dir(String pathOnServer) throws RemoteException {\r\n\t\tString sDir = pathOnServer;\r\n\t\tFile dir = new File(sDir);\r\n\t\tif (dir.isDirectory() && dir.exists()) {\r\n\t\t\tSystem.out.println(\"directory path found\");\t\r\n\t\t}\r\n\t\telse {\r\n\t\t\tSystem.out.println(\"directory path is not a directory path or doesn't exist\");\t\r\n\t\t}\r\n\t\treturn dir.list();\r\n\t}", "public CommandResult execute(String command, String directory) {\n CommandResult cr = new CommandResult();\n BufferedReader in = null;\n try {\n Process process = Runtime.getRuntime().exec(command, null, new File(directory));\n cr.ret = process.waitFor();\n\n in = new BufferedReader(new InputStreamReader(process.getInputStream()));\n String line = null;\n while ((line = in.readLine()) != null) {\n cr.console.strings.add(line);\n }\n } catch (IOException e) {\n e.printStackTrace();\n } catch (InterruptedException e) {\n e.printStackTrace();\n } finally {\n if (in != null) {\n try {\n in.close();\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n }\n\n return cr;\n }", "public String getResultingString(IDirectory toLsDir) {\r\n // get sub-directories and files\r\n String result = \"\";\r\n // Check if the path is valid\r\n if (toPrint) {\r\n // Get the sub-directories and files\r\n ArrayList<DirectoryTreeNode> contents = toLsDir.getContents();\r\n\r\n // check if contents is empty or not\r\n if (!contents.isEmpty()) {\r\n // get the names of all the sub-directories\r\n for (DirectoryTreeNode content : contents) {\r\n result += content.getName() + \"\\n\";\r\n }\r\n }\r\n // If the path is not valid then return an appropriate message\r\n } else {\r\n if (toRedirect) {\r\n System.out.println(\"Error: Cannot access path.\\n\");\r\n } else\r\n result = \"Cannot access path \\n\";\r\n }\r\n // return the result\r\n return result;\r\n }", "private List<String> processDirectory(Path path) {\n\t\treturn null;\r\n\t}", "String ls(String pRoot) throws RemoteException;", "Map<String, Set<String>> stat(String arg);", "public String formatDirectoryListing(FileSystemEntry fileSystemEntry);", "public void setShDir(String s) {\n\n\t\tthis.shDir = s;\n\n\t}", "protected abstract void parseExecResult(BufferedReader lines) throws IOException;", "List<File> list(String directory) throws FindException;", "private void parseCommand(String spokenString) {\n\t\tRuleParse parse = null;\n\t\ttry {\n\t\t\tparse = rules.parse(spokenString, null);\n\t\t} catch (GrammarException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\tString[] result = parse.getTags();\n\n\t\tfor(String r:result){\n\t\t\tSystem.out.println(r);\n\t\t}\n\t}", "public static String parse(String command) throws IOException {\n assert tasks.size() >= 0;\n\n if (command.equals(\"bye\")) {\n return executeExit();\n } else if (command.equals(\"list\")) {\n return executeList();\n } else if (command.equals(\"yes\") || command.equals(\"no\")) {\n return executeDuplicateHandling(command);\n } else if (command.startsWith(\"done\")) {\n return executeDone(command);\n } else if (command.startsWith(\"delete\")) {\n return executeDelete(command);\n } else if (command.startsWith(\"find\")) {\n return executeFind(command);\n } else {\n return executeTask(command);\n }\n }", "public static Object[] mkdir(String soption_, Object classInfo_,\r\n Paths[] pathss_, boolean calledByOtherCmds_, Shell shell_)\r\n {\r\n CommandOption option_ = new CommandOption(soption_,\r\n false/*dont expand*/);\r\n if (pathss_ == null || pathss_.length == 0) {\r\n if (!option_.quiet) {\r\n if (classInfo_ instanceof String\r\n && ((String)classInfo_).indexOf('/') > 0)\r\n // classInfo_ is a path!\r\n shell_.println(\"Error: no class name or Java object\"\r\n + \" is given.\");\r\n else\r\n shell_.println(\"Error: no path is specified.\");\r\n }\r\n return null;\r\n }\r\n if (classInfo_ == null) {\r\n if (!option_.quiet)\r\n shell_.println(\"Error: no class class name or Java object\"\r\n + \" is given.\");\r\n return null;\r\n }\r\n\r\n // get the class information from classInfo_\r\n Class class_ = null;\r\n Component comp_ = null; // component or component wrapper\r\n Port port_ = null;\r\n Object object_ = null; // wrapped object\r\n try {\r\n if (classInfo_ instanceof String) {\r\n // class name\r\n class_ = Class.forName((String)classInfo_);\r\n object_ = class_.newInstance();\r\n }\r\n else {\r\n object_ = classInfo_;\r\n class_ = object_.getClass();\r\n }\r\n \r\n if (object_ instanceof Component) {\r\n comp_ = (Component)object_;\r\n object_ = null;\r\n }\r\n else if (object_ instanceof Port) {\r\n port_ = (Port)object_;\r\n object_ = null;\r\n }\r\n else {\r\n comp_ = new WrapperComponent();\r\n ((WrapperComponent)comp_).setObject(object_);\r\n }\r\n }\r\n catch (Exception e_) {\r\n shell_.println(\"classInfo: \" + classInfo_);\r\n if (!option_.quiet) shell_.println(e_.toString());\r\n return null;\r\n }\r\n \r\n option_.recordID = true;\r\n Vector v_ = __common__(option_, pathss_, false, shell_);\r\n \r\n Vector vresult_ = new Vector();\r\n boolean firstTime_ = true;\r\n for (int i=0; i<v_.size(); i++) {\r\n Directory d_ = (Directory)v_.elementAt(i);\r\n if (d_ == null\r\n || ((d_.child == null || d_.child.length == 0)\r\n && d_.ids == null)) continue;\r\n \r\n if (d_.ids != null) { // have id information\r\n // error\r\n if (d_.ids[0] == Common.STOP_RESOLUTION_COMPONENT\r\n && port_ != null) {\r\n if (!option_.quiet)\r\n shell_.println(\"Warning: cannot make a port with\"\r\n + \" a component id (\" + d_.parent\r\n + \"/\" + d_.ids[1] + \").\");\r\n continue;\r\n }\r\n if (d_.ids[0] == Common.STOP_RESOLUTION_PORT\r\n && comp_ != null) {\r\n if (!option_.quiet)\r\n shell_.println(\"Warning: cannot make a component\"\r\n + \" with a port id (\" + d_.parent\r\n + \"/\" + d_.ids[1] + \").\");\r\n continue;\r\n }\r\n if (d_.ids[0] == Common.STOP_RESOLUTION_COMPONENT\r\n && d_.trailingSlash) {\r\n if (!option_.quiet) {\r\n shell_.println(\"Warning: invalid path '\" + d_.parent\r\n + \"/\" + d_.ids[1] + \"/.\");\r\n shell_.println(\"Remove the trailing slash maybe?\");\r\n }\r\n continue;\r\n }\r\n \r\n // everything is normal\r\n if (comp_ != null) {\r\n // make component(s)\r\n for (int j=2; j<d_.ids.length; j++) {\r\n Component new_ = firstTime_? comp_:\r\n (Component)comp_.clone();\r\n new_.setID(d_.ids[j]);\r\n d_.parent.addComponent(new_, !option_.keepRuntime);\r\n vresult_.addElement(new_);\r\n firstTime_ = false;\r\n }\r\n }\r\n else {\r\n // make port(s)\r\n for (int j=2; j<d_.ids.length; j++) {\r\n Port new_ = firstTime_? port_: (Port)port_.clone();\r\n String tmp_ = d_.ids[j];\r\n int index_ = tmp_.indexOf('@');\r\n String gid_ = index_ >= tmp_.length() -1?\r\n \"\": tmp_.substring(index_+1);\r\n d_.parent.addPort(new_, gid_,\r\n tmp_.substring(0, index_));\r\n vresult_.addElement(new_);\r\n firstTime_ = false;\r\n }\r\n }\r\n continue;\r\n } // end if (d_.ids != null)\r\n \r\n // else we have no id info unless object_ has id info in it\r\n\r\n Object[] oo_ = d_.child;\r\n for (int j=0; j<oo_.length; j++) {\r\n if (oo_[j] instanceof Component) {\r\n // handling wrapper component\r\n if (object_ != null) {\r\n if (oo_[j] instanceof WrapperComponent) {\r\n WrapperComponent parent_ = (WrapperComponent)oo_[j];\r\n if (parent_.getObject() != null) {\r\n if (!option_.quiet)\r\n shell_.println(\"Warning: \" + parent_\r\n + \" contains other\"\r\n + \" wrapped object.\");\r\n continue;\r\n }\r\n Component new_ = firstTime_? comp_:\r\n (Component)comp_.clone();\r\n parent_.setObject(\r\n ((WrapperComponent)new_).getObject());\r\n vresult_.addElement(parent_.getObject());\r\n firstTime_ = false;\r\n continue;\r\n }\r\n else {\r\n // error no matter whether there's a trailing slash\r\n if (!option_.quiet) {\r\n if (d_.trailingSlash)\r\n shell_.println(\"Warning: component ID\"\r\n + \" should be given to make a\"\r\n + \" wrapper component under \"\r\n + oo_[j] + \".\");\r\n else\r\n shell_.println(\"Warning: \" + oo_[j]\r\n + \" is not a wrapper component.\");\r\n }\r\n continue;\r\n }\r\n }\r\n \r\n // check no id error\r\n if (comp_ != null) {\r\n if (!d_.trailingSlash) {\r\n if (!option_.quiet) {\r\n // XX: write onto the component?\r\n shell_.println(\"Warning: \" + oo_[j]\r\n + \" already exists.\");\r\n shell_.println(\"Add a trailing slash maybe?\");\r\n }\r\n continue;\r\n }\r\n else if (comp_.getID() == null) {\r\n if (!option_.quiet)\r\n shell_.println(\"Warning: component ID should\"\r\n + \" be given to make a component\"\r\n + \" under \" + oo_[j] + \".\");\r\n continue;\r\n }\r\n }\r\n if (port_ != null && port_.getID() == null) {\r\n if (!option_.quiet)\r\n shell_.println(\"Warning: port ID should be given\"\r\n + \" to make a port under \" + oo_[j] + \".\");\r\n continue;\r\n }\r\n \r\n if (comp_ != null) {\r\n // make a component\r\n Component new_ = firstTime_? comp_:\r\n (Component)comp_.clone();\r\n Component parent_ = (Component)oo_[j];\r\n if (!parent_.containsComponent(new_.getID())) {\r\n parent_.addComponent(new_, !option_.keepRuntime);\r\n vresult_.addElement(new_);\r\n firstTime_ = false;\r\n }\r\n else {\r\n if (new_.getParent() != null) {\r\n if (!option_.quiet) {\r\n shell_.println(\"Warning: source '\" + new_ \r\n + \"' is not a standalone\"\r\n + \" component.\");\r\n }\r\n break;\r\n }\r\n if (!option_.quiet) {\r\n // error\r\n if (parent_.getComponent(new_.getID()) != null){\r\n shell_.println(\"Warning: '\" + parent_ \r\n + \"' already contains a child\"\r\n + \" with ID '\"\r\n + new_.getID() + \"'.\");\r\n }\r\n else {\r\n shell_.println(\"Unknown error when adding \"\r\n + new_ + \" to \" + parent_ + \".\");\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // make a port\r\n Port new_ = firstTime_? port_: (Port)port_.clone();\r\n Component parent_ = (Component)oo_[j];\r\n if (parent_.addPort(new_, new_.getGroupID(),\r\n new_.getID()) != null) {\r\n vresult_.addElement(new_);\r\n firstTime_ = false;\r\n }\r\n else {\r\n if (new_.getHost() != null) {\r\n if (!option_.quiet) {\r\n shell_.println(\"Warning: source '\" + new_ \r\n + \"' is not a standalone port.\");\r\n }\r\n break;\r\n }\r\n if (!option_.quiet) {\r\n // error\r\n if (parent_.getPort(new_.getGroupID(),\r\n new_.getID()) != null) {\r\n shell_.println(\"Warning: '\" + parent_ \r\n + \"' already contains a port '\"\r\n + new_.getID() + \"@\"\r\n + new_.getGroupID() + \"'.\");\r\n }\r\n else {\r\n shell_.println(\"Unknown error when adding \"\r\n + new_ + \" to \" + parent_ + \".\");\r\n }\r\n }\r\n }\r\n }\r\n } // end if (oo_[j] is component)\r\n else {\r\n // error\r\n if (!option_.quiet)\r\n shell_.println(\"Warning: cannot make things under \"\r\n + oo_[j] + \"!\");\r\n }\r\n } // end loop i, index to v_\r\n }\r\n if (vresult_.size() == 0) {\r\n if (!option_.quiet && !calledByOtherCmds_)\r\n shell_.println(\"Nothing is created.\");\r\n return null;\r\n }\r\n //if (vresult_.size() == 1) return vresult_.firstElement();\r\n Object[] result_ = new Object[vresult_.size()];\r\n vresult_.copyInto(result_);\r\n return result_;\r\n }", "public static Command parseCommand(String response) {\n String[] command = response.split(\" \", 10);\n switch (command[0]) {\n case \"list\":\n return new ListCommand(command);\n case \"done\":\n case \"undo\":\n return new DoneUndoCommand(command);\n case \"remove\":\n return new RemoveCommand(command);\n case \"add\":\n return new AddCommand(command, response);\n case \"bye\":\n return new ByeCommand();\n case \"help\":\n return new HelpCommand();\n case \"find\":\n return new FindCommand(command, response);\n case \"update\":\n return new UpdateCommand(command);\n default:\n System.out.println(\"Im sorry i did not catch that maybe these instructions below will help\"\n + System.lineSeparator() + Interface.lineBreak);\n return new HelpCommand();\n }\n }", "@Override\n protected String parseURI()\n throws IOException {\n command = parseCommand();\n\n System.out.println(\"Command parsed as: \" + command.toString());\n\n // 2. Parse the modified URI.\n switch (command) {\n case GET_ALL_BUCKETS:\n // A. If we get all buckets we need the user path\n // User path == /root/user/\n modifiedURI = s3HdfsPath.getHdfsRootUserPath();\n break;\n case LIST_PARTS:\n // B. If we get all the parts we need the root upload path\n // Upload path == /root/user/bucket/object/version/upload/\n modifiedURI = s3HdfsPath.getHdfsRootUploadPath();\n break;\n case LIST_VERSIONS:\n // B. If we get all the parts we need the root upload path\n // Upload path == /root/user/bucket/object/version/upload/\n modifiedURI = s3HdfsPath.getHdfsRootBucketPath();\n break;\n case GET_VERSIONING:\n // C. If we get versioning configuration we need bucket meta path\n // Bucket meta path == /root/user/bucket/\"bucketmeta\"\n modifiedURI = s3HdfsPath.getFullHdfsBucketMetaPath();\n break;\n case GET_BUCKET:\n // D. If we get a bucket we need the bucket path\n // Bucket path == /root/user/bucket/\n modifiedURI = s3HdfsPath.getHdfsRootBucketPath();\n break;\n case GET_OBJECT:\n // E. If we get an object we need the full path\n // Full path == /root/user/bucket/object/version/\"file\"\n modifiedURI = s3HdfsPath.getFullHdfsObjPath();\n break;\n default:\n throw new IOException(\"Unknown command: \" + command);\n }\n\n // 3. Set the modified URI.\n modifiedURI = ADD_WEBHDFS(modifiedURI);\n return modifiedURI;\n }", "private String collectResultFromProcess(Process proc)\r\n\t{\r\n\t\tStringBuilder sb_result = new StringBuilder();\r\n\t\t\r\n BufferedReader stdInput = new BufferedReader(new InputStreamReader(proc.getInputStream()));\r\n BufferedReader stdError = new BufferedReader(new InputStreamReader(proc.getErrorStream()));\r\n String result_line = null;\r\n \r\n try\r\n {\r\n\t while ((result_line = stdInput.readLine()) != null) \r\n\t {\r\n\t sb_result.append(result_line);\r\n\t sb_result.append(\"\\n\");\r\n\t }\r\n\t \r\n\t while ((result_line = stdError.readLine()) != null) \r\n\t {\r\n\t sb_result.append(result_line);\r\n\t sb_result.append(\"\\n\");\r\n\t }\r\n } catch(IOException ioe)\r\n {\r\n \tioe.printStackTrace();\r\n }\r\n \r\n return sb_result.toString();\r\n\t}", "public String execute() {\n String output = \"\";\n String tempOut = \"\";\n FSElement file;\n ArrayList<FSElement> recfiles;\n for (String fileName : dirArray) {\n file = Traverse.accessFS(fileName, root);\n if (file != null) {\n if (file instanceof File) {\n tempOut = getContent((File) file);\n if (!(output.contains(tempOut))) {\n output += tempOut;\n }\n } else if (subdir) {\n recfiles = Traverse.getAllDirs((Directory) file);\n for (FSElement temp : recfiles) {\n if (temp instanceof File) {\n tempOut = getContent((File) temp);\n if (!(output.contains(tempOut))) {\n output += tempOut;\n }\n }\n }\n }\n } else {\n Output.pathIncorrect(fileName);\n }\n }\n if (!(output.equals(\"\"))) {\n output = output.substring(0, output.length() - 2);\n return output;\n } else {\n Output.NoFilesFound();\n return null;\n }\n }", "private String collectResultFromProcess(Process proc) {\n StringBuilder sb_result = new StringBuilder();\n\n BufferedReader stdInput = new BufferedReader(new InputStreamReader(proc.getInputStream()));\n BufferedReader stdError = new BufferedReader(new InputStreamReader(proc.getErrorStream()));\n String result_line = null;\n\n try {\n while ((result_line = stdInput.readLine()) != null) {\n sb_result.append(result_line);\n sb_result.append(\"\\n\");\n }\n\n while ((result_line = stdError.readLine()) != null) {\n sb_result.append(result_line);\n sb_result.append(\"\\n\");\n }\n } catch (IOException ioe) {\n ioe.printStackTrace();\n }\n\n return sb_result.toString();\n }", "private void getDirectoryContents() {\n\t File directory = Utilities.prepareDirectory(\"Filtering\");\n\t if(directory.exists()) {\n\t FilenameFilter filter = new FilenameFilter() {\n\t public boolean accept(File dir, String filename) {\n\t return filename.contains(\".pcm\") || filename.contains(\".wav\");\n\t }\n\t };\n\t fileList = directory.list(filter);\n\t }\n\t else {\n\t fileList = new String[0];\n\t }\n\t}", "private ParsedDottedName parseTokens(ArrayList tokenList, String command,\n String dottedName) throws MalformedNameException {\n Properties props = new Properties();\n props.put(ObjectNames.kTypeKeyName, ObjectNames.kMonitoringType);\n props.put(ObjectNames.kNameKeyName, ObjectNames.kMonitoringRootClass);\n props.put(ObjectNames.kMonitoringClassName,\n ObjectNames.kMonitoringRootClass);\n props.put(ObjectNames.kServerInstanceKeyName, instanceName);\n int count = tokenList.size();\n MonitoredObjectType type = null;\n // 1st token is name of the instance, ignore.\n // Process 2nd token onwards - either singleton-type or type.name. The\n // last token is a special case because it can be a wildcard or\n // attribute name for get command, a type or name for list command\n int tokenCount = count;\n if (command.equals(CLI_COMMAND_GET) || command.equals(CLI_COMMAND_SET)) {\n tokenCount = count - 1;\n }\n boolean processType = true;\n for (int i = 1; i < tokenCount; i++) {\n String token = (String)tokenList.get(i);\n if (processType) {\n type = MonitoredObjectType.getMonitoredObjectTypeOrNull(token);\n if (type == null) {\n\t\t\t\t\tString msg = localStrings.getString( \"admin.monitor.invalid_entry\", dottedName, token );\n throw new MalformedNameException( msg );\n }\n String typeName = type.getTypeName();\n if (type.isSingleton()) {\n swapNameType(props, typeName, typeName);\n processType = true;\n type = null;\n } else {\n processType = false;\n }\n } else {\n swapNameType(props, type.getTypeName(), token);\n processType = true;\n type = null;\n }\n }\n ParsedDottedName result = new ParsedDottedName();\n try {\n result.objectName = new ObjectName(ObjectNames.kDefaultIASDomainName,\n props);\n } catch (MalformedObjectNameException ione) {\n throw new MalformedNameException(ione.getMessage());\n }\n // type != null -- Means that a name was expected in parsing. For\n // LIST command implies list of objects of this type. For GET command\n // implies all specified attribute(or wildcard) of on specified type of\n // objects.\n if (type != null) {\n result.monitoredObjectType = type;\n }\n if (command.equals(CLI_COMMAND_GET)) {\n result.attributeName = (String)tokenList.get(count -1);\n } else if (command.equals(CLI_COMMAND_SET))\n result.operationName = (String)tokenList.get(count -1);\n \n return result;\n }", "public static int execute(final File dir, String[] command) throws IOException, InterruptedException {\n\n class Rewriter extends Thread {\n private BufferedReader bufferedReader;\n private PrintStream printStream;\n\n public Rewriter(InputStream is, PrintStream printStream) {\n this.bufferedReader = new BufferedReader(new InputStreamReader(is));\n this.printStream = printStream;\n }\n\n public void run() {\n try {\n String s;\n while ((s = bufferedReader.readLine()) != null)\n printStream.println(s);\n } catch (IOException e) {\n e.printStackTrace(System.err);\n }\n }\n }\n\n final Process proc = Runtime.getRuntime().exec(command, null, dir);\n final Thread stdThread = new Rewriter(proc.getInputStream(), System.out);\n final Thread errThread = new Rewriter(proc.getErrorStream(), System.err);\n stdThread.start();\n errThread.start();\n stdThread.join();\n errThread.join();\n proc.waitFor();\n return proc.exitValue();\n }", "public int parse(String inputString) {\n manager.init();\n\n Map<String, List<String>> commandMap = new HashMap<>();\n List<String> blocks = Arrays.asList(inputString.split(\" \"));\n commandMap.put(blocks.get(0), blocks.size() > 1 ? blocks.subList(1, blocks.size()) : Collections.EMPTY_LIST);\n\n // item properties\n if (commandMap.containsKey(\"ip\")) {\n List<String> params = commandMap.get(\"ip\");\n if (params.size() > 0) {\n // set item properties\n manager.setItemParams(params);\n manager.prettyPrint(\"Successfully set Item Properties to: \" + params);\n } else {\n // get item properties\n manager.printItemParams();\n }\n }\n\n // channel properties\n if (commandMap.containsKey(\"cp\")) {\n List<String> params = commandMap.get(\"fp\");\n if (params.size() > 0) {\n // set channel properties\n manager.setChannelParams(params);\n manager.prettyPrint(\"Successfully set Channel Properties to: \" + params);\n } else {\n // get channel properties\n manager.printChannelParams();\n }\n }\n\n // rss\n if (commandMap.containsKey(\"rss\")) {\n List<String> params = commandMap.get(\"rss\");\n if (params.size() > 0) {\n switch (params.get(0)) {\n case \"add\": {\n if (params.size() != 3) {\n throw new IllegalArgumentException(\"Not enough params for -rss add\");\n }\n String rssLink = params.get(1);\n String file = params.get(2);\n manager.createFileIfNotExists(file);\n manager.associateRssToFile(rssLink, file);\n manager.prettyPrint(\n \"Successfully added new RSS Feed: \" + rssLink,\n \"Associated file is: \" + file\n );\n break;\n }\n case \"del\": {\n if (params.size() != 2) {\n throw new IllegalArgumentException(\"Not enough params for -rss del\");\n }\n String rssLink = params.get(1);\n manager.diassociateRss(rssLink);\n manager.prettyPrint(\"Successfully removed new RSS Feed: \" + rssLink);\n break;\n }\n case \"on\": {\n if (params.size() != 2) {\n throw new IllegalArgumentException(\"Not enough params for -rss on\");\n }\n String rssLink = params.get(1);\n manager.turnRSSOn(rssLink);\n manager.prettyPrint(\"Successfully turned RSS Feed \" + rssLink + \" on\");\n break;\n }\n case \"off\": {\n if (params.size() != 2) {\n throw new IllegalArgumentException(\"Not enough params for -rss off\");\n }\n String rssLink = params.get(1);\n manager.turnRSSOff(rssLink);\n manager.prettyPrint(\"Successfully turned RSS Feed \" + rssLink + \" off\");\n break;\n }\n }\n } else {\n manager.printRss();\n }\n } else if (commandMap.containsKey(\"time\")) {\n List<String> params = commandMap.get(\"time\");\n if (params.size() > 0) {\n if (params.size() != 1) {\n throw new IllegalArgumentException(\"Not enough params for -time\");\n }\n String newTimeToPoll = params.get(0);\n manager.setTimeToPoll(Long.valueOf(newTimeToPoll));\n manager.prettyPrint(\"Successfully set polling time to \" + newTimeToPoll);\n\n } else {\n manager.printTimeToPoll();\n }\n } else if (commandMap.containsKey(\"h\")) {\n manager.printHelp();\n } else if (commandMap.containsKey(\"exit\")) {\n return 1;\n }\n return 0;\n }", "private static String getDirectory() {\n System.out.println(\"Please enter a directory: \");\n Scanner dirScanner = new Scanner(System.in);\n return dirScanner.nextLine();\n }", "public static void main(String[] args) { String dirname = \"/home/diego/IdeaProjects/JAVAStuff/src/tmp/dirTest.txt\";\n// File d = new File(dirname);\n// d.mkdirs();\n//\n File file = null;\n String[] paths;\n\n try {\n file = new File(\"/home/diego/IdeaProjects/JAVAStuff/src\");\n paths = file.list();\n\n for(String s: paths) {\n System.out.println(s);\n }\n } catch (Exception e) {\n e.printStackTrace();\n }\n\n\n }", "private void cmdInfo(String line) throws NoSystemException {\n StringTokenizer tokenizer = new StringTokenizer(line);\n try {\n String subCmd = tokenizer.nextToken();\n if (subCmd.equals(\"class\")) {\n String arg = tokenizer.nextToken();\n cmdInfoClass(arg);\n } else if (subCmd.equals(\"model\")) {\n cmdInfoModel();\n } else if (subCmd.equals(\"state\")) {\n cmdInfoState();\n } else if (subCmd.equals(\"opstack\")) {\n cmdInfoOpStack();\n } else if (subCmd.equals(\"prog\")) {\n cmdInfoProg();\n } else if (subCmd.equals(\"vars\")) {\n cmdInfoVars();\n } else\n Log.error(\"Syntax error in info command. Try `help'.\");\n } catch (NoSuchElementException ex) {\n Log.error(\"Missing argument to `info' command. Try `help'.\");\n }\n }", "public ViewScheCommand(String line) throws DukeException {\n String[] arrOfStr = line.split(\"\\\\s+\");\n\n this.option = arrOfStr[0].trim();\n if (option.equals(\"/all\")) {\n if (arrOfStr.length > 1) {\n this.date = Parser.parseDate(arrOfStr[1].trim());\n sortByDate = true;\n }\n } else if (option.equals(\"/member\")) {\n this.memberName = arrOfStr[1].trim();\n if (arrOfStr.length > 2) {\n this.date = Parser.parseDate(arrOfStr[2].trim());\n sortByDate = true;\n }\n }\n }", "private static void getResults() {\n\t\t//Variables\n\t\tFile directoryOfChunks = new File(\"output\");\n\t\tFile[] files = directoryOfChunks.listFiles();\n\t\tArrayList<String> filesInFolder = new ArrayList<>();\n\t\tArrayList<String> chunkResults = new ArrayList<>();\n\t\tBufferedReader br = null;\n\t\tReadFromFile rf = new ReadFromFile();\n\n\t\t//Get files from output folder\n\t\tif(directoryOfChunks.exists() && directoryOfChunks.isDirectory()){\n\t\t\tdirectoryName = \"output\";\n\t\t\t//Copy file names into arraylist\n\t\t\tfor (File f: files) {\n\t\t\t\t//Save file names into arraylist.\n\t\t\t\tfilesInFolder.add(f.getName());\n\t\t\t}\n\t\t}\n\t\t//if not a file or directory print error message\n\t\telse{\n\t\t\tSystem.out.println(\"No such file/directory: \" + directoryOfChunks);\n\t\t}\n\n\t\t//for loop to open and read each individual file\n\t\tfor (String file : filesInFolder) {\n\t\t\ttry {\n\n\t\t\t\tFileReader reader = new FileReader(directoryName + \"\\\\\" + file);\n\t\t\t\tbr = new BufferedReader(reader);\n\t\t\t} catch (FileNotFoundException e1) {\n\t\t\t\te1.printStackTrace();\n\t\t\t}\n\t\t\tchunkResults.addAll(rf.readFromChunk(br));\n\t\t}\n\n\t\t//Call sanitizeAndSplit\n\t\tsanitizeAndSplit(chunkResults);\n\t}", "private static Params parseCLI(String[] args) {\n Params params = new Params();\n\n if(args.length>1) {\n int paramIndex = 0;\n for(int i=0; i<args.length; i++) {\n String arg = args[i];\n OutputType type = OutputType.getOutputType(arg);\n if(type!=null) {\n params.outputType = type;\n paramIndex = i;\n break;\n } else if(\"-help\".equals(arg)) {\n usage();\n System.exit(0);\n }\n }\n\n params.inputFile = args[paramIndex+1];\n if(args.length>paramIndex+2) {\n params.outputFile = args[paramIndex+2];\n }\n\n } else if(args.length == 1 && \"-help\".equals(args[0])) {\n usage();\n System.exit(0);\n\n } else {\n \n System.err.println(\"Error, incorrect usage\");\n usage();\n System.exit(-1);\n\n }\n\n return params;\n }", "public void readCommand(Scanner s) throws WrongCommandFormatException {\n String next = s.next();\n if (next.equals(\"/by\")) {\n throw new WrongCommandFormatException(\"Wrong keyword used. Please try again with /at\");\n } else if (next.equals(\"/at\")) {\n parseTimeframe(s);\n } else {\n this.description += next + \" \";\n }\n }", "DiscDirectoryInfo getDirectoryInfo(String path) throws IOException;", "public IDirectory executeCommand(String[] arguments, int numArgs,\r\n IDirectory currentDir, FileSystem dirTree, History history, Pushd pushd,\r\n Popd popd) {\r\n if (numArgs == 0) {\r\n // check there is not directory or path given\r\n String result = this.printFromDirectory(currentDir);\r\n System.out.println(result);\r\n } else if (numArgs > 0) {\r\n ArrayList returnArguments = checkRedirectArguments(arguments);\r\n // check if redirecting ls command result or not\r\n if ((boolean) returnArguments.remove(0)) {\r\n this.redirectingLS(dirTree, currentDir, returnArguments);\r\n } else {\r\n this.nonredirectingLS(dirTree, currentDir, arguments);\r\n }\r\n }\r\n return currentDir;\r\n }", "private static void listar(Path a){\n File dir = new File(a.toString());\n if(dir.isDirectory()){\n String[] dirContents = dir.list();\n for(int i =0; i < dirContents.length; i++){\n System.out.println(dirContents[i]);\n }\n }\n }", "CParserResult getParserResult();", "private DirectoryParser() {\n this.parsedFiles = new TreeMap<>();\n }", "public void parse() {\n if (commandSeparate.length == 1) {\n parseTaskType();\n } else if (commandSeparate.length == 2) {\n parseTaskType();\n index = commandSeparate[1];\n taskName = commandSeparate[1];\n } else {\n parseTaskType();\n parseTaskName();\n parseTaskDate();\n }\n }", "public static void main(String[] args) {\n File directoryPath = new File(\"C:\\\\Users\\\\jarek\\\\Downloads\");\n //List of all files and directories\n String[] contents = directoryPath.list();\n\n Pattern p= Pattern.compile(\"zip$\");\n Matcher m;\n Vector<String> lis = new Vector<>();\n for(int i = 0; i< Objects.requireNonNull(contents).length; i++){\n m=p.matcher(contents[i]);\n if(m.find()) lis.addElement(contents[i]);\n }\n System.out.println(\"List of files and directories in the specified directory:\");\n for (String content : contents) {\n System.out.println(content);\n }\n }", "private ConsoleCommand mapConsoleCommand( String[] parsedString ){\r\n\t\t\r\n\t\tFileSystemService fileSysSrv = new FileSystemService();\r\n\t\tStringBuilder errorSB = new StringBuilder();\r\n\t\tConsoleCommand consoleCommand = new ConsoleCommand();\r\n\t\t\r\n\t\tconsoleCommand.setCommand( parsedString[ AppConstanst.COMMAND_IDX ] );\r\n\t\t\t\t\r\n\t\tif ( parsedString.length < AppConstanst.MIN_SCAN_PARAM ){\r\n\t\t\terrorSB.append( AppConstanst.NOT_ALL_REQ_COMMAND_SET ) ;\r\n\t\t} else {\r\n\t\t\t// VALIDATE INPUTDIR COMMAND\r\n\t\t\tconsoleCommand.setInputDir( parsedString[ AppConstanst.INPUT_DIR_IDX ] );\r\n\t\t\tif ( !AppConstanst.SCAN_INPUT_DIR.equals( consoleCommand.getInputDir() ) ){\r\n\t\t\t\terrorSB.append( AppConstanst.WRONG_REQ_COMMAND+\" \"+consoleCommand.getInputDir()+AppConstanst.MUST_BE+AppConstanst.SCAN_INPUT_DIR+\"\\n\" );\r\n\t\t\t}\r\n\t\t\tconsoleCommand.setInputDirValue( parsedString[ AppConstanst.INPUT_DIR_VALUE_IDX ] );\r\n\t\t\tif ( ! consoleCommand.getInputDirValue().matches( AppConstanst.ABS_PATH) ){\r\n\t\t\t\terrorSB.append( AppConstanst.ILLEGAL_INPUT_PATH + consoleCommand.getInputDirValue()+\"\\n\");\r\n\t\t\t}\r\n\t\t\t//CHECK IS INPUT DIR EXIST, IF NOT TRY CREATE IT\r\n\t\t if ( !fileSysSrv.isDirectoryExist( consoleCommand.getInputDirValue() ) ){\r\n\t\t \tif ( !fileSysSrv.makeDirectory( consoleCommand.getInputDirValue() ) ){\r\n\t\t \t\terrorSB.append( AppConstanst.INPUT_DIR_NOT_EXISTS + consoleCommand.getInputDirValue()+\"\\n\");\r\n\t\t \t};\r\n\t\t }\r\n\t\t\t// VALIDATE OUTPUTDIR COMMAND\r\n\t\t\tconsoleCommand.setOutPutDir( parsedString[ AppConstanst.OUTPUT_DIR_IDX ] );\r\n\t\t\tif ( !AppConstanst.SCAN_OUTPUT_DIR.equals( consoleCommand.getOutPutDir() ) ){\r\n\t\t\t\terrorSB.append( AppConstanst.WRONG_REQ_COMMAND+\" \"+consoleCommand.getOutPutDir()+AppConstanst.MUST_BE+AppConstanst.SCAN_OUTPUT_DIR+\"\\n\" );\r\n\t\t\t}\r\n\t\t\tconsoleCommand.setOutPutDirValue( parsedString[ AppConstanst.OUTPUT_DIR_VALUE_IDX ] );\r\n\t\t\tif ( ! consoleCommand.getOutPutDirValue().matches( AppConstanst.ABS_PATH) ){\r\n\t\t\t\terrorSB.append( AppConstanst.ILLEGAL_OUTPUT_PATH + consoleCommand.getOutPutDirValue()+\"\\n\" );\r\n\t\t\t}\r\n\t\t\t//CHECK IS OUTPUT DIR EXIST, IF NOT TRY CREATE IT\r\n\t\t if ( !fileSysSrv.isDirectoryExist( consoleCommand.getOutPutDirValue() ) ){\r\n\t\t \tif ( !fileSysSrv.makeDirectory( consoleCommand.getOutPutDirValue() ) ){\r\n\t\t \t\terrorSB.append( AppConstanst.OUTPUT_DIR_NOT_EXISTS + consoleCommand.getOutPutDirValue()+\"\\n\");\r\n\t\t \t};\r\n\t\t }\r\n\t\t\t// VALIDATE MASK COMMAND\r\n\t\t\tconsoleCommand.setMask( parsedString[ AppConstanst.MASK_IDX ] );\r\n\t\t\tif ( !AppConstanst.SCAN_MASK.equals( consoleCommand.getMask() ) ){\r\n\t\t\t\terrorSB.append( AppConstanst.WRONG_REQ_COMMAND+\" \"+consoleCommand.getMask()+AppConstanst.MUST_BE+AppConstanst.SCAN_MASK+\"\\n\" );\r\n\t\t\t}\r\n\t\t\tconsoleCommand.setMaskValue( parsedString[ AppConstanst.MASK_VALUE_IDX ]);\r\n\t\t\tif ( ! AppUtils.isMaskCorrect( consoleCommand.getMaskValue() ) ){\r\n\t\t\t\terrorSB.append( AppConstanst.ILLEGAL_MASK + consoleCommand.getMaskValue()+\"\\n\" );\r\n\t\t\t}\r\n\t\t\t// VALIDATE WAIT INTERVAL COMMAND\r\n\t\t\tconsoleCommand.setWaitInterval( parsedString[ AppConstanst.WAIT_INTERVAL_IDX ] );\r\n\t\t\tif ( !AppConstanst.SCAN_WAIT_INTERVAL.equals( consoleCommand.getWaitInterval() ) ){\r\n\t\t\t\terrorSB.append( AppConstanst.WRONG_REQ_COMMAND+\" \"+consoleCommand.getWaitInterval()+AppConstanst.MUST_BE+AppConstanst.SCAN_WAIT_INTERVAL+\"\\n\" );\r\n\t\t\t}\r\n\t\t\tLong interval= null;\r\n\t\t\ttry{\r\n\t\t\t\tinterval = Long.parseLong( parsedString[ AppConstanst.WAIT_INTERVAL_VALUE_IDX ] );\r\n\t\t\t} catch (NumberFormatException e) {} \r\n\t\t\tconsoleCommand.setWaitIntervalValue( interval );\r\n\t\t\tif ( interval == null || interval < 0){\r\n\t\t\t\terrorSB.append( AppConstanst.INCORECT_WAIT_INTERVAL + parsedString[ AppConstanst.WAIT_INTERVAL_VALUE_IDX ]+AppConstanst.POSITIVE_INT+\"\\n\" );\r\n\t\t\t}\r\n\t\t\t// VALIDATE NOT REQUIRED COMMAND\r\n\t\t\t\r\n\t\t\t\tfor (int idx = AppConstanst.MIN_SCAN_PARAM+1; idx < parsedString.length; idx += 2){\r\n\t\t\t\t\tif ( AppConstanst.SCAN_INCLUDE_SUB.equals( parsedString[ idx ] ) ){\r\n\t\t\t\t\t\tconsoleCommand.setIncludeSubs( parsedString[ idx ] );\r\n\t\t\t\t\t\tconsoleCommand.setIncludeSubsValue( parsedString[ idx+1 ] );\r\n\t\t\t\t\t\tif ( !AppConstanst.TRUE.equals( parsedString[ idx+1 ]) && !AppConstanst.FALSE.equals( parsedString[ idx+1 ] ) ){\r\n\t\t\t\t\t\t\terrorSB.append( AppConstanst.INCORECT_INCLUDE_SUBFOLDERS+\" \"+parsedString[ idx+1 ]+AppConstanst.TRUE_OR_FALSE+\"\\n\" );\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif ( AppConstanst.SCAN_AUTO_DELETE.equals( parsedString[ idx ] ) ){\r\n\t\t\t\t\t\tconsoleCommand.setAutoDelete( parsedString[ idx ] );\r\n\t\t\t\t\t\tconsoleCommand.setAutoDeleteValue( parsedString[ idx+1 ] );\r\n\t\t\t\t\t\tif ( !AppConstanst.TRUE.equals( parsedString[ idx+1 ]) && !AppConstanst.FALSE.equals( parsedString[ idx+1 ] ) ){\r\n\t\t\t\t\t\t\terrorSB.append( AppConstanst.INCORECT_AUTODELETE+\" \"+parsedString[ idx+1 ]+AppConstanst.TRUE_OR_FALSE+\"\\n\" );\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t}\r\n\t\tif ( errorSB.length() > 0 ){\r\n\t\t\tSystem.out.println(AppConstanst.ERROR_IN_SCAN_COMMAND+ errorSB.toString());\r\n\t\t\tconsoleCommand.setCommand( AppConstanst.UNKNOWN);\r\n\t\t} \r\n\t\treturn consoleCommand;\r\n\t}", "public Command parse(String command) throws DukeException {\n String[] commandSplit = command.split(\"\\\\s+\", 2);\n String commandWord = commandSplit[0].toLowerCase();\n String desc = \"\";\n if (commandSplit.length == 2) {\n desc = commandSplit[1];\n }\n\n switch (commandWord) {\n case DoneCommand.COMMAND_WORD:\n return doneParse(desc);\n\n case ListCommand.COMMAND_WORD:\n return new ListCommand();\n\n case ToDoCommand.COMMAND_WORD:\n return toDoParse(desc);\n\n case DeadlineCommand.COMMAND_WORD:\n return deadlineParse(desc);\n\n case EventCommand.COMMAND_WORD:\n return eventParse(desc);\n\n case DeleteCommand.COMMAND_WORD:\n return deleteParse(desc);\n\n case FindCommand.COMMAND_WORD:\n return new FindCommand(desc);\n case UpdateCommand.COMMAND_WORD:\n return new UpdateParser(desc).parse();\n case ByeCommand.COMMAND_WORD:\n return new ByeCommand();\n default:\n throw new DukeException(INVALID_COMMAND_MESSAGE);\n }\n }", "public RSTTreeNode readParseOutput(String s, JCas jCas)\n {\n // first: dry run\n RSTTreeNode result = readParseOutput(s, jCas, true);\n\n // now iterate over the tree again and set proper relation name and nucleus/satellite\n fixRelationTypeAndUnitType((DiscourseRelation) result);\n\n // test whether boundaries of EDU are mappable to their respective boundary tokens\n boolean isMappable = mapTokensToEDUUnits(result, jCas);\n\n // map it\n if (isMappable) {\n result = readParseOutput(s, jCas, false);\n fixRelationTypeAndUnitType((DiscourseRelation) result);\n mapTokensToEDUUnits(result, jCas);\n }\n\n // and for all nodes\n mapBoundariesRecursive(result);\n\n return result;\n }", "public static void displayPrompt() throws DirectoryNameNotSpecifiedException, DirectoryExistsException\r\n {\r\n Directory rootDirectory = new Directory(\"R:\");\r\n listOfDirectories.add(rootDirectory);\r\n Scanner scanner = new Scanner(System.in);\r\n System.out.println(\"--------Welcome to Virtual Command Prompt--------\");\r\n String currentPath = \"R:\\\\\";\r\n Directory currentDirectory = rootDirectory;\r\n \r\n while(true)\r\n {\r\n System.out.print(currentPath + \">\");\r\n String command = scanner.nextLine();\r\n String[] commandWords = command.split(\" \");\r\n \r\n switch(commandWords[0])\r\n {\r\n \tcase \"mkdir\" : if(commandWords.length == 1)\r\n \t\t\t\t \t\tthrow new DirectoryNameNotSpecifiedException(NAME_NOT_SPECIFIED_ERROR_MESSAGE);\r\n \t\r\n \t\t\t for(Directory subDirectory: currentDirectory.getListOfSubDirectories())\r\n \t\t\t {\r\n \t\t\t\t if(subDirectory.getName().equals(commandWords[1]))\r\n \t\t\t\t\t throw new DirectoryExistsException(DIRECTORY_EXISTS_ERROR_MESSAGE);\r\n \t\t\t }\r\n \t\t\t Directory newDirectory = new Directory(commandWords[1]);\r\n \t\t\t listOfDirectories.add(newDirectory);\r\n \t\t\t currentDirectory.getListOfSubDirectories().add(newDirectory);\r\n \t\t\t break;\r\n \r\n \r\n \tcase \"cd\"\t: if(isPresent(currentDirectory, commandWords[1]))\r\n \t\t \t {\r\n \t \t for(Directory directory: listOfDirectories)\r\n \t \t {\r\n \t \t \t if(directory.getName().equals(commandWords[1]))\r\n \t \t \t {\r\n \t \t \t\t currentDirectory = directory;\r\n \t \t \t\t if(currentPath.charAt(currentPath.length() - 1) != '\\\\')\r\n \t \t \t\t\t currentPath += \"\\\\\";\r\n\r\n \t \t \t\t currentPath += currentDirectory.getName();\r\n \t \t \t\t break;\r\n \t \t \t }\r\n \t \t }\r\n \t\t \t }\r\n \t\t\t\t else\r\n \t\t\t\t \t\tSystem.out.println(currentPath + \"> No such directory exists\");\r\n \t\t\t\t break;\r\n \r\n \tcase \"bk\"\t: String[] directories = currentPath.split(\"\\\\\\\\\");\r\n \t\t\t\t for(Directory directory: listOfDirectories)\r\n \t\t\t\t {\r\n \t\t\t\t\t if(directory.getName().equals(directories[directories.length - 2]))\r\n \t\t\t\t\t\t currentDirectory = directory;\r\n \t\t\t\t }\r\n \r\n \t\t\t\t currentPath = \"R:\";\r\n \t\t\t\t for(int i = 1; i < directories.length - 1; i++)\r\n \t\t\t\t\t currentPath += \"\\\\\" + directories[i];\r\n \t\t\t\t break;\r\n \r\n \tcase \"ls\" : for(Directory subDirectory: currentDirectory.getListOfSubDirectories())\r\n \t\t\t\t {\r\n \t\t\t System.out.println(subDirectory.getDateOfCreation() + \"\\t\" + subDirectory.getName());\r\n \t\t\t\t }\r\n \t\t\t\t \tSystem.out.println(currentDirectory.getListOfSubDirectories().size() + \" Folder(s)\"); \r\n \t\t\t\t \tbreak;\r\n \r\n \tcase \"find\" : path = \".\\\\\";\r\n \t\t\t\t String directoryPath = findPath(currentDirectory, commandWords[1]);\r\n \t\t\t\t if(directoryPath != null)\r\n \t\t\t\t {\r\n \t\t\t\t \tStringBuilder pathToFind = new StringBuilder(directoryPath);\r\n \t\t\t\t \tpathToFind.deleteCharAt(pathToFind.length() - 1);\r\n \t\t\t\t \tSystem.out.println(pathToFind);\r\n \t\t\t\t }\r\n \t\t\t\t else\r\n \t\t\t\t \tSystem.out.println(currentPath + \">Directory not found\");\r\n \t\t\t\t break;\r\n \r\n \tcase \"tree\"\t : System.out.println(\".\");\r\n \t\t\t\t\tString spacing = \"\\t\";\r\n \t\t\t printTree(currentDirectory, spacing);\r\n \t\t\t break;\r\n\r\n \tcase \"exit\"\t : System.exit(0);\r\n } \r\n } \r\n }", "public String getShDir() {\n\n\t\treturn this.shDir;\n\n\t}", "private ArrayList<SimplifyResult> parseResult(String executionResult) throws IOException {\n\t\t// create buffer readers\n\t\tStringReader stringReader = new StringReader(executionResult);\n\t\tBufferedReader bufferedReader = new BufferedReader(stringReader);\t\t\t\t\n\t\t\n\t\tString line;\n\t\tArrayList<SimplifyResult> results = new ArrayList<SimplifyResult>();\n\t\t\n\t\twhile ((line = bufferedReader.readLine()) != null) {\n\t\t\tif (line.indexOf(\"Invalid\") != -1) {\n\t\t\t\tresults.add(new SimplifyResult(line, SimplifyResult.INVALID));\n\t\t\t}\n\t\t\telse if (line.indexOf(\"Valid\") != -1) {\n\t\t\t\tresults.add(new SimplifyResult(line, SimplifyResult.VALID));\n\t\t\t}\n\t\t\telse if (line.indexOf(\"Unable to open file\") != -1) {\n\t\t\t\tresults.add(new SimplifyResult(line, SimplifyResult.UNABLE_TO_OPEN_FILE));\n\t\t\t}\n\t\t\telse if (line.indexOf(\"Bad input\") != -1) {\n\t\t\t\tresults.add(new SimplifyResult(line, SimplifyResult.BAD_INPUT));\n\t\t\t}\n\t\t\telse if (line.indexOf(\"Sx.ReadError in file\") != -1) {\n\t\t\t\tresults.add(new SimplifyResult(line, SimplifyResult.SYNTAX_ERROR));\n\t\t\t}\n\t\t\tline = bufferedReader.readLine();\n\t\t}\t\t\n\t\t\n\t\treturn results;\n\t}", "public String listPath(List<String> arg) {\n String output = \"\";\n for (int path = 0; path < arg.size(); path++) {\n Directory tDir = Directory.getDir(arg.get(path));\n if (tDir == null) {\n output +=\n \"Error: The input path \" + arg.get(path) + \" doesn't exist!\\n\\n\";\n } else if (tDir.isFile) {\n output += tDir.getName();\n } else {\n for (int j = 0; j < tDir.getSubContent().size(); j++) {\n if (!tDir.getSubContent().get(j).isFile) {\n output += tDir.getSubContent().get(j).getName();\n Directory dir = tDir.getSubContent().get(j);\n if (!dir.getSubContent().isEmpty()) {\n output += \" : \";\n for (int k = 0; k < tDir.getSubContent().get(j).getSubContent()\n .size(); k++) {\n if (k != tDir.getSubContent().get(j).getSubContent().size()\n - 1) {\n output += tDir.getSubContent().get(j).getSubContent().get(k)\n .getName() + \", \";\n } else {\n output += tDir.getSubContent().get(j).getSubContent().get(k)\n .getName() + \"\\n\";\n }\n }\n } else {\n output += \"\\n\";\n }\n } else {\n output += tDir.getSubContent().get(j).getName() + \"\\n\";\n }\n }\n }\n }\n return output;\n }", "public Scanner getScanner(){\n\t\t\n\t\tString filename = \"\";\n\t\tfor(int i = 0; i<argList.size(); i++ ){\n\t\t\tif(argList.get(i).equals(\"-f\")){\n\t\t\t\tfilename = argList.get(i+1);\n\t\t\t\t//DIFFERENT FROM OTHER INIT FILE!\n\t\t\t\tfilename = filename.trim().replace(\".s230\", \".S230\");\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(System.getProperty(\"user.dir\") + \" ... \" + filename);\n\t\tString dirName = System.getProperty(\"user.dir\");\n\t\tdirName = dirName.replace(\"\\\\Program_Files\\\\source\",\"\\\\\").trim();\n\t\tdirName = dirName.replace(\"\\\\Program_Files\\\\classes\",\"\\\\\").trim();\n\t\tdirName = dirName.concat(\"\\\\InputOutputFolder\\\\\");\n\t\tSystem.out.println(dirName+filename);\n\t\tFile file = new File(dirName, filename);\n\t\tScanner toReturn = null;\n\t\ttry {\n\t\t\ttoReturn = new Scanner(file);\n\t\t} catch (FileNotFoundException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn toReturn;\n\t}", "public void parseCommandLine(String[] args) {\r\n\t\t// define command line options\r\n\t\tOptions options = new Options();\r\n\t\t// refresh:\r\n\t\toptions.addOption(new Option(\r\n\t\t \"refresh\", \r\n\t\t \"Tell Argus to start refreshing all files after Minstrel startup.\"));\r\n\t\t// port:\r\n\t\tOptionBuilder.withArgName(\"port\");\r\n\t\tOptionBuilder.hasArg();\r\n\t\tOptionBuilder.withDescription( \"Run NanoHTTPD on this port instead of default 8000.\" );\r\n\t\toptions.addOption(OptionBuilder.create(\"port\"));\r\n\t\t// argus:\r\n\t\tOptionBuilder.withArgName(\"url\");\r\n\t\tOptionBuilder.hasArg();\r\n\t\tOptionBuilder.withDescription( \"Use Argus at <url> instead of default localhost:8008.\" );\r\n\t\toptions.addOption(OptionBuilder.create(\"argus\"));\r\n\t\t// vlc:\r\n\t\tOptionBuilder.withArgName(\"url\");\r\n\t\tOptionBuilder.hasArg();\r\n\t\tOptionBuilder.withDescription(\"Use VLC at <url> instead of default localhost:8080.\");\r\n\t\toptions.addOption(OptionBuilder.create(\"vlc\"));\r\n\t\t// wwwroot:\r\n\t\tOptionBuilder.withArgName(\"path\");\r\n\t\tOptionBuilder.hasArg();\r\n\t\tOptionBuilder.withDescription(\"Have NanoHTTPD serve files from <path> instead of default ./wwwroot.\");\r\n\t\toptions.addOption(OptionBuilder.create(\"wwwroot\"));\r\n\t\t\r\n\t\t// parse command line options and adjust accordingly\r\n\t\tCommandLineParser parser = new GnuParser();\r\n\t\ttry {\r\n\t\t\tCommandLine line = parser.parse(options, args);\r\n\r\n\t\t\tif (line.hasOption(\"refresh\")) {\r\n\t\t\t\trefresh = new Date();\r\n\t\t\t}\r\n\t\t\tif (line.hasOption(\"port\")) {\r\n\t\t\t\ttry {\r\n\t\t\t\t\tport = Integer.parseInt( line.getOptionValue(\"port\"));\r\n\t\t\t\t} catch (NumberFormatException e) {\r\n\t\t\t\t\tSystem.err.println(\"Badly formatted port number, defaulting to 8000. Reason: \" + e.getMessage());\r\n\t\t\t\t\tport = 8000;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tif (line.hasOption(\"argus\")) {\r\n\t\t\t\targusURL = line.getOptionValue(\"argus\");\r\n\t\t\t}\r\n\t\t\tif (line.hasOption(\"vlc\")) {\r\n\t\t\t\tvlcURL = line.getOptionValue(\"vlc\");\r\n\t\t\t}\r\n\t\t\tif (line.hasOption(\"wwwroot\")) {\r\n\t\t\t\twwwroot = line.getOptionValue(\"wwwroot\");\r\n\t\t\t}\r\n\t\t} catch (ParseException e) {\r\n\t\t\tSystem.err.println(\"Command line parsing failed. Reason: \" + e.getMessage());\r\n\t\t}\r\n\t}", "public static Command parse(String str) throws DukeException {\n\n String[] arr = str.split(\" \", 2);\n if (arr.length < 1) {\n throw new DukeException(\"No command was given.\");\n }\n String firstWord = arr[0];\n if (str.equalsIgnoreCase(\"bye\")) {\n return new ExitCommand();\n } else if (str.equalsIgnoreCase(\"list\")) {\n return new ListCommand();\n } else {\n Action action = parseFirstWord(firstWord.toLowerCase());\n\n if (arr.length < 2 && (action == Action.Done || action == Action.Delete)) {\n throw new DukeException(\"duke.task.Task number for \" + firstWord + \" is not given.\");\n } else if (arr.length < 2 || arr[1].isBlank()) {\n throw new DukeException(\"The description of \" + firstWord + \" cannot be empty\");\n } else {\n return actionToCommand(action, arr[1]);\n }\n }\n }", "public void parseBlastOutput(String output) ;", "private static List<String> readOutput(Process process) throws IOException {\n\t\tBufferedReader reader = new BufferedReader(new InputStreamReader(process.getInputStream()));\n\t\tString line;\n\t\tList<String> lines = new ArrayList<>();\n\t\twhile ((line = reader.readLine()) != null) {\n\t\t\tlines.add(line);\n\t\t}\n\t\treturn lines;\n\t}", "public List<String> ls(String path) {\n\t\treturn getDirectory(path, directory).stringy();\n\t}", "public void redirectingLS(FileSystem dirTree, IDirectory currentDir,\r\n ArrayList returnArguments) {\r\n\r\n String resultList = \"\";\r\n boolean incorrectRecursiveFormat = false;\r\n this.toRedirect = true;\r\n if (returnArguments.size() == 2) {\r\n // if there is not path or directory given with the ls command\r\n resultList = this.printFromDirectory(currentDir);\r\n } else {\r\n // if we are recursively listing or not\r\n String[] arguments = (String[]) returnArguments.remove(0);\r\n int numberOccurenceOfR = numberOccurenceOfR(Arrays.asList(arguments));\r\n int index = Arrays.asList(arguments).indexOf(\"-R\");\r\n\r\n if (index == -1 && numberOccurenceOfR == 0)\r\n resultList = this.nonrecursivePrinting(arguments, dirTree, currentDir);\r\n else if (index == 0 && numberOccurenceOfR == 1)\r\n resultList = this.recursivePrinting(arguments, dirTree, currentDir);\r\n else if (numberOccurenceOfR > 1) {\r\n incorrectRecursiveFormat = true;\r\n System.out.print(\"Error: Incorrect format for recursive ls. \\n\");\r\n } else\r\n resultList =\r\n listNonRecursiveAndRecursive(dirTree, currentDir, arguments, index);\r\n }\r\n // only redirect the resulting list if the arguments given are valid\r\n if (!incorrectRecursiveFormat) {\r\n returnArguments.add(0, resultList);\r\n this.checkRedirection(dirTree, returnArguments, currentDir);\r\n }\r\n }", "private static void console (String path) {\n boolean ERROR = false;\n while (true) {\n if (!ERROR) {\n System.out.println(\"Directory: \" + path);\n\n System.out.println(\"====================================\");\n long startTime = System.currentTimeMillis();\n DirectoryData root = hashmap.get(path);\n System.out.println(\"Directories in hashmap: \" + hashmap.size());\n System.out.println(\"Time taken to get data: \" + (System.currentTimeMillis() - startTime) + \"ms\");\n System.out.println(\"====================================\");\n\n System.out.println(\"Inside: \");\n\n if (root.getFileList().size() == 0) {\n System.out.println(\"(Empty Directory)\");\n }\n\n String leftAlignFormat = \"|%-1s | %-100s | %-10s |%n\";\n\n System.out.format(\"+---+------------------------------------------------------------------------------------------------------+------------+%n\");\n System.out.format(\"| | Name | Size |%n\");\n System.out.format(\"+---+------------------------------------------------------------------------------------------------------+------------+%n\");\n\n for (FileData subFile : root.getFileList()) {\n if (subFile.isDirectory()) {\n if (hashmap.get(subFile.getFullPath()) == null)\n System.out.format(leftAlignFormat, \" d\", subFile.getFilename(),\n size_string(null));\n else\n System.out.format(leftAlignFormat, \" d\", subFile.getFilename(),\n size_string(hashmap.get(subFile.getFullPath()).getSize()));\n } else {\n System.out.format(leftAlignFormat, \" -\", subFile.getFilename(),\n size_string(subFile.getSize()));\n }\n }\n System.out.format(\"+---+------------------------------------------------------------------------------------------------------+------------+%n\");\n }\n\n ERROR = false;\n\n System.out.print(\"\\n> \");\n Scanner in = new Scanner(System.in);\n String next_dir = in.nextLine();\n String next_path = path;\n\n if (next_dir.equals(\"..\")) {\n String[] path_arr = next_path.split(\"\\\\\\\\\");\n next_path = String.join(\"\\\\\", Arrays.copyOfRange(path_arr, 0, path_arr.length-1));\n\n if (path.charAt(path.length()-2) == ':') {\n System.out.println(\"Directory: \" + path);\n System.out.println(\"Already in root\");\n //path = TraversalConsole.path;\n ERROR = true;\n continue;\n }\n\n if (next_path.charAt(next_path.length()-1) == ':')\n next_path += '\\\\';\n\n if (!hashmap.containsKey(next_path)) {\n System.out.println(\"Directory: \" + path + \"\\\\\");\n System.out.println(\"Already in root\");\n ERROR = true;\n continue;\n } else {\n path = next_path;\n continue;\n }\n }\n\n if (path.charAt(path.length() - 1) != '\\\\') {\n next_path += \"\\\\\" + next_dir;\n } else {\n next_path += next_dir;\n }\n\n if (next_dir.equals(\"exit\")) {\n break;\n }\n\n if (hashmap.containsKey(next_path)) {\n path = next_path;\n continue;\n } else {\n System.out.println(\"Wrong Input or [\" + next_dir + \"] is a file\");\n ERROR = true;\n continue;\n }\n }\n }", "public static String parseCommand(String command) {\n String keyWord = \"\";\n if (command.startsWith(\"list\")) {\n keyWord = \"list\";\n } else if (command.startsWith(\"notes\")) {\n keyWord = \"notes\";\n } else if (command.startsWith(\"done\")) {\n keyWord = \"done\";\n } else if (command.startsWith(\"delete note\")) {\n keyWord = \"delete note\";\n } else if (command.startsWith(\"delete\")) {\n keyWord = \"delete\";\n } else if (command.startsWith(\"todo\")) {\n keyWord = \"todo\";\n } else if (command.startsWith(\"deadline\")) {\n keyWord = \"deadline\";\n } else if (command.startsWith(\"event\")) {\n keyWord = \"event\";\n } else if (command.startsWith(\"today\")) {\n keyWord = \"today\";\n } else if (command.startsWith(\"find\")) {\n keyWord = \"find\";\n } else if (command.startsWith(\"bye\")) {\n keyWord = \"bye\";\n } else if (command.startsWith(\"note\")) {\n keyWord = \"note\";\n }\n return keyWord;\n }", "static Vector __common__(CommandOption option_, Paths[] pathss_,\r\n boolean sort_, Shell shell_)\r\n {\r\n option_.sort = sort_;\r\n Vector v_ = new Vector(); // store Directory\r\n for (int i=0; i<pathss_.length; i++) {\r\n // append \"*\" if a path ends with \"/\"\r\n if (pathss_[i].paths != null && option_.expand)\r\n // expand used here??\r\n for (int j=0; j<pathss_[i].paths.length; j++) {\r\n String path_ = pathss_[i].paths[j];\r\n if (path_.length() > 1 && path_.charAt(path_.length()-1)\r\n == '/')\r\n pathss_[i].paths[j] = path_ + \"*\";\r\n }\r\n Directory[] tmp_ = Common.resolveOnePaths(pathss_[i], option_,\r\n shell_);\r\n \r\n if (tmp_ == null) continue;\r\n for (int j=0; j<tmp_.length; j++) {\r\n v_.addElement(tmp_[j]);\r\n }\r\n }\r\n return v_;\r\n }", "private void processDir(){\n // get the location of ISAW code base\n String isaw_home=SharedData.getProperty(\"ISAW_HOME\");\n if(isaw_home==null)\n throw new InstantiationError(\"Could not find directory:ISAW_HOME is null\");\n isaw_home=FilenameUtil.setForwardSlash(isaw_home+\"/\");\n\n // get the name of the directory to check\n String dir=FilenameUtil.setForwardSlash(isaw_home\n +\"DataSetTools/parameter/\");\n\n // check that the directory is okay to work with\n if(DEBUG) System.out.println(\"Looking in \"+dir);\n File paramDir=new File(dir);\n if( !(paramDir.exists()) || !(paramDir.isDirectory()) )\n throw new InstantiationError(\"Could not find directory \" + dir);\n\n // get the list of all possible classes\n File[] files=paramDir.listFiles();\n String filename=null;\n for( int i=0 ; i<files.length ; i++ ){\n filename=checkName(files[i].toString(),isaw_home.length());\n if(filename!=null) addParameter(filename);\n }\n \n \n\n dir=FilenameUtil.setForwardSlash(isaw_home\n +\"gov/anl/ipns/Parameters/\");\n\n // check that the directory is okay to work with\n if(DEBUG) System.out.println(\"Looking in \"+dir);\n paramDir=new File(dir);\n if( !(paramDir.exists()) || !(paramDir.isDirectory()) )\n throw new InstantiationError(\"Could not find directory \" + dir);\n\n // get the list of all possible classes\n files=paramDir.listFiles();\n filename=null;\n for( int i=0 ; i<files.length ; i++ ){\n filename=checkName(files[i].toString(),isaw_home.length());\n if(filename!=null) addParameter(filename);\n }\n\n }", "abstract protected void execute(String dir);", "List<CmdletInfo> listCmdletInfo(long ruleID, CmdletState cmdletState) throws IOException;", "private List<String> applySSA() {\n\t\t//String content = Utility.getStringFromFile(filePath);\n\t\tList<String> ssa = new ArrayList<String>();\n\t\tInputStream stream = new ByteArrayInputStream(source.getBytes());\n\t\ttry {\n\t\t\tANTLRInputStream input = new ANTLRInputStream(stream);\n\t\t\tEntryLexer lexer = new EntryLexer(input);\n\t\t\tCommonTokenStream tokens = new CommonTokenStream(lexer);\n\t\t\tEntryParser parser = new EntryParser(tokens);\n\t\t\tProgContext prog = parser.prog();\n\t\t\tconvertToSSAString(prog, ssa);\n\t\t\treturn ssa;\n\t\t} catch (IOException e) {\n\t\t\t//\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn null;\n\t}", "@Override\n\tpublic Command parse(String[] s) {\n\t\tif (s.length==1 && s[0].equalsIgnoreCase(\"HELP\"))\n\t\t\treturn new Help(); \n\t\telse return null;\n\t}", "private RSTTreeNode readParseOutput(String s, JCas jCas, boolean dryRun)\n {\n String[] lines = s.split(\"\\n\");\n Queue<String> inputQueue = new ArrayDeque<>();\n\n for (String line : lines) {\n // this is a one-liner -- split it!\n // e.g.: (Elaboration[N][S] _!The friends!_ _!I had!_)\n String trim = line.trim();\n if (trim.startsWith(\"(\") && trim.endsWith(\")\")) {\n String[] split = trim.split(\"_!\");\n\n // (Elaboration[N][S]\n inputQueue.add(split[0]);\n\n // _!The friends!_\n inputQueue.add(\"_!\" + split[1]);\n\n // _!I had!_)\n inputQueue.add(\"_!\" + split[2]);\n }\n else {\n // otherwise add the whole line\n inputQueue.add(trim);\n }\n }\n\n // stack\n Stack<RSTTreeNode> stack = new Stack<>();\n\n // final root node\n RSTTreeNode result = null;\n\n while (!inputQueue.isEmpty()) {\n // process line (and remove leading whitespaces)\n String line = inputQueue.poll().trim();\n\n // the new RST tree node\n RSTTreeNode treeNode;\n\n // if starts with \"(\", it's a relation\n if (line.startsWith(\"(\")) {\n treeNode = new DiscourseRelation(jCas);\n // temporarily; need to adjust on the next run\n ((DiscourseRelation) treeNode).setRelationType(line);\n\n }\n // or it's a text - EDU\n else if (line.startsWith(\"_!\")) {\n treeNode = new EDU(jCas);\n // temporarily; need to map to tokens later\n ((EDU) treeNode).setOriginalText(line);\n }\n else {\n throw new IllegalStateException(\"Unknown line type: \" + line);\n }\n\n // add to indexes in jcas\n if (!dryRun) {\n treeNode.addToIndexes();\n }\n\n // now connect it to the parent relation\n if (!stack.isEmpty()) {\n DiscourseRelation parent = (DiscourseRelation) stack.peek();\n\n // is it the first or the second argument?\n if (parent.getArg1() == null) {\n parent.setArg1(treeNode);\n }\n else if (parent.getArg2() == null) {\n parent.setArg2(treeNode);\n }\n else {\n throw new IllegalStateException(\"Parent already has arg1 and arg2\");\n }\n }\n\n // and, in case of relation, add it to the stack\n if (treeNode instanceof DiscourseRelation) {\n stack.push(treeNode);\n }\n\n // now check, whether the current line closes some parent relations (and pop them\n // out of the stack)\n while (line.endsWith(\")\")) {\n // System.out.println(line);\n result = stack.pop();\n line = line.substring(0, line.length() - 1);\n }\n }\n\n return result;\n }", "public String[] nextCommand() {\r\n String[] result = null;\r\n if (sc.hasNextLine()) {\r\n String temp = sc.next();\r\n if (temp.equals(\"insert\")) {\r\n result = new String[3];\r\n result[0] = \"insert\";\r\n temp = sc.nextLine().trim();\r\n result[1] = temp.split(\"<SEP>\")[0];\r\n result[2] = temp.split(\"<SEP>\")[1];\r\n }\r\n else if (temp.equals(\"remove\")) {\r\n result = new String[3];\r\n result[0] = \"remove\";\r\n result[1] = sc.next();\r\n result[2] = sc.nextLine().trim();\r\n }\r\n else if (temp.equals(\"print\")) {\r\n result = new String[2];\r\n result[0] = \"print\";\r\n result[1] = sc.nextLine().trim();\r\n }\r\n else {\r\n sc.nextLine();\r\n }\r\n return result;\r\n }\r\n return null;\r\n }", "private static List<Scenario> parseScenario(String[] args){\n\t\targs = new String[]{\"software_manage/software_search.scenario\"};\n\t\tList<Scenario> list = new LinkedList<Scenario>();\n\t\tfor(String arg : args)\n\t\t\tlist.add(new Scenario(arg));\n\t\t\n\t\treturn list;\n\t}", "public void getResults()\n\t{\n\t\tThread mOutReader = new Thread()\n\t\t{\n\t\t\tpublic void run()\n\t\t\t{\n\t\t\t\ttry\n\t\t\t\t{\n\t\t\t\t\tBufferedReader br = new BufferedReader(new InputStreamReader(mProcess.getInputStream()));\n\t\t\t\t\tString line = br.readLine();\n\t\t\t\t\twhile ((!isInterrupted() && line != null))\n\t\t\t\t\t{\n\t\t\t\t\t\tline = line.trim();\n\t\t\t\t\t\tmResults.add(line);\n\t\t\t\t\t\tline = br.readLine();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tcatch (InterruptedIOException e)\n\t\t\t\t{\n\t\t\t\t}\n\t\t\t\tcatch (Exception e)\n\t\t\t\t{\n\t\t\t\t}\n\t\t\t}\n\t\t};\n\n\t\t//we will process the error stream just in case\n\t\tThread mErrReader = new Thread()\n\t\t{\n\t\t\tpublic void run()\n\t\t\t{\n\t\t\t\ttry\n\t\t\t\t{\n\t\t\t\t\tBufferedReader br = new BufferedReader(new InputStreamReader(mProcess.getErrorStream()));\n\t\t\t\t\tString line = br.readLine();\n\t\t\t\t\twhile ((!isInterrupted() && line != null))\n\t\t\t\t\t{\n\t\t\t\t\t\tline = line.trim();\n\t\t\t\t\t\tSystem.out.println(line);\n\t\t\t\t\t\tline = br.readLine();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tcatch (InterruptedIOException e)\n\t\t\t\t{\n\t\t\t\t}\n\t\t\t\tcatch (Exception e)\n\t\t\t\t{\n\t\t\t\t}\n\t\t\t}\n\t\t};\n\n\t\tmOutReader.start();\n\t\tmErrReader.start();\n\n\t\t//wait for process to end.\n\t\ttry\n\t\t{\n\t\t\tmProcess.waitFor();\n\t\t}\n\t\tcatch (Exception e)\n\t\t{\n\t\t\tSystem.err.println(\"process exception\");\n\t\t}\n\t\tmFinished = true;\n\t}", "public static String parseOutput(String output) {\r\n\t\treturn output.replaceAll(\"\\n\", \"\\n\" + OUT_SYMBOL); //TODO ugly, fix this\r\n\t}", "public List<ACL> parseACL(String cmd) {\r\n\t\taccessList = new ArrayList<ACL>();\r\n\t\t\r\n\t\tACL aclObj;\r\n\t\tcmd = cmd.trim();\r\n\t\tString regex = \"(?<=%%) (\" + ACESS_LIST_TYPE + \") IP access list (\" + IP_ACCESS_LIST_NUM\r\n\t\t\t\t+ \").*?(\\\\d.*?)(?=%%|$)\";\r\n\r\n\t\tPattern pattern = Pattern.compile(regex);\r\n\t\tMatcher matcher = pattern.matcher(cmd);\r\n\r\n\t\twhile (matcher.find()) {\r\n\t\t\tipAccessListType = matcher.group(1);\r\n\t\t\tipAccessListNum = Integer.parseInt(matcher.group(2));\r\n\t\t\tString regex1 = \"(\" + ACCESS_LIST_MODE_NUMBER + \") \" + ACCESS_LIST_MODE + \"(\" + SOURCE_IP + \") {0,1}(\"\r\n\t\t\t\t\t+ WILDCARD_SOURCE_IP + \") {0,1}(\" + DES_IP + \") {0,1}(\" + WILDCARD_DES_IP + \")\";\r\n\t\t\tPattern pattern1 = Pattern.compile(regex1);\r\n\t\t\tMatcher matcher1 = pattern1.matcher(matcher.group(3));\r\n\r\n\t\t\twhile (matcher1.find()) {\r\n\t\t\t\tmodeNum = Integer.parseInt(matcher1.group(1));\r\n\t\t\t\tsourceIP = matcher1.group(2);\r\n\t\t\t\twildCardSourceIP = matcher1.group(3);\r\n\t\t\t\tdesIP = matcher1.group(4);\r\n\t\t\t\twildCardDesIP = matcher1.group(5);\r\n\t\t\t\taclObj = new ACL(ipAccessListType, ipAccessListNum, modeNum, sourceIP, wildCardSourceIP, desIP,\r\n\t\t\t\t\t\twildCardDesIP);\r\n\t\t\t\taccessList.add(aclObj);\r\n\t\t\t\t//collect interface info\r\n\t\t\t\t//interfacesMap.get(aclObj.getInterfaceName()).addAcl(aclObj);\r\n\t\t\t\t\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn accessList;\r\n\t}", "public void parse()\n\t{\n\t\ttry\n\t\t{\n\t\t\tstatus = program();\n\t\t}\n\t\tcatch(Exception e)\n\t\t{\n\t\t\t\n\t\t}\n\t}", "public static DirectoryParser getParser() {\n return DirectoryParser.INSTANCE;\n }", "private USBInfo[] getValidUsbDir() {\r\n String directoryList;\r\n StringTokenizer tokens;\r\n String pathEntry;\r\n USBInfo usbInfos[];\r\n USBInfo singleInfo;\r\n Vector entries;\r\n File f;\r\n int idxSeparator;\r\n\r\n entries = new Vector();\r\n directoryList = Config.getStringProperty(\"UsbDirectoryList\", PathConfigUtils.createUSBPath(0, false));\r\n tokens = new StringTokenizer(directoryList, \";\");\r\n while (tokens.hasMoreElements()) {\r\n pathEntry = tokens.nextToken();\r\n idxSeparator = pathEntry.indexOf(\"|\");\r\n singleInfo = new USBInfo();\r\n singleInfo.usbPath = pathEntry.substring(0, idxSeparator);\r\n singleInfo.displayName = pathEntry.substring(idxSeparator + 1);\r\n f = new File(singleInfo.usbPath);\r\n if (f.exists() && f.isDirectory()) {\r\n entries.addElement(singleInfo);\r\n }\r\n }\r\n usbInfos = new USBInfo[entries.size()];\r\n for (int i = 0; i < entries.size(); i++) {\r\n usbInfos[i] = (USBInfo) entries.elementAt(i);\r\n }\r\n return usbInfos;\r\n }", "public ArrayList<Command> parseCommand(String command) throws InvalidCommandException {\n\n\n\t\tArrayList<Command> cmds = new ArrayList<Command>();\n\t\tString cmd;\n\t\tString[] text;\n\n\t\tArrayList<Parameter> parameters = new ArrayList<Parameter>();\n\n\t\tint indexOfFirstSpace = 0;\n\t\tint indexOfFirstInvertedSlash = 0;\n\t\tboolean passFirstSpace = false;\n\n\t\t// check and find the first space and slash.\n\t\tfor (int i = 0; i < command.length(); i++) {\n\t\t\tif (command.charAt(i) == ' ' && !passFirstSpace) {\n\t\t\t\tindexOfFirstSpace = i;\n\t\t\t\tpassFirstSpace = true;\n\t\t\t} else if (command.charAt(i) == INVERTED_SLASH) {\n\t\t\t\tindexOfFirstInvertedSlash = i;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\n\t\tindexOfFirstSpace = getEquivalentIndexForCommandWithoutParameter(command, indexOfFirstSpace);\n\n\t\tif (indexOfFirstSpace == 0) {\n\t\t\treturn null;\n\t\t}\n\n\t\tcmd = command.substring(0, indexOfFirstSpace);\n\t\tint cmdType = mapCommandType(cmd);\n\n\t\tif (cmdType == ERROR_COMMAND_TYPE) {\n\t\t\tthrow new InvalidCommandException(command);\n\t\t}\n\n\t\tif (!command.contains(VERTICAL_DASH)) {\n\t\t\tperformSmartParsing(command, parameters);\n\t\t}\n\n\t\ttext = extractTextAndPerformParameterParsing(command, parameters, indexOfFirstSpace, indexOfFirstInvertedSlash);\n\t\tif (text != null) {\n\t\t\tfor (String textEntry : text) {\n\t\t\t\tcmds.add(new Command(cmdType, trimOffDateIfAny(textEntry), parameters));\n\n\t\t\t}\n\t\t} else {\n\t\t\tcmds.add(new Command(cmdType, \"\", parameters));\n\t\t}\n\n\t\treturn cmds;\n\t}", "private static void parseCommandLine(String[] command) {\r\n\t\tint i = 0;\r\n\t\t\r\n\t\twhile (i < command.length) {\r\n\t\t\tif (command[i].equals(\"-f\")) { // input file\r\n\t\t\t\tdataFileName = command[i+1];\r\n\t\t\t\ti += 2;\r\n\t\t\t}\r\n\t\t\telse if (command[i].equals(\"-s\")) { // data split\r\n\t\t\t\tif (command[i+1].equals(\"simple\")) {\r\n\t\t\t\t\tevaluationMode = DataSplitManager.SIMPLE_SPLIT;\r\n\t\t\t\t\ttestRatio = Double.parseDouble(command[i+2]);\r\n\t\t\t\t}\r\n\t\t\t\telse if (command[i+1].equals(\"pred\")) {\r\n\t\t\t\t\tevaluationMode = DataSplitManager.PREDEFINED_SPLIT;\r\n\t\t\t\t\tsplitFileName = command[i+2].trim();\r\n\t\t\t\t}\r\n\t\t\t\telse if (command[i+1].equals(\"kcv\")) {\r\n\t\t\t\t\tevaluationMode = DataSplitManager.K_FOLD_CROSS_VALIDATION;\r\n\t\t\t\t\tfoldCount = Integer.parseInt(command[i+2]);\r\n\t\t\t\t}\r\n\t\t\t\telse if (command[i+1].equals(\"rank\")) {\r\n\t\t\t\t\tevaluationMode = DataSplitManager.RANK_EXP_SPLIT;\r\n\t\t\t\t\tuserTrainCount = Integer.parseInt(command[i+2]);\r\n\t\t\t\t\tminTestCount = 10;\r\n\t\t\t\t}\r\n\t\t\t\ti += 3;\r\n\t\t\t}\r\n\t\t\telse if (command[i].equals(\"-a\")) { // algorithm\r\n\t\t\t\trunAllAlgorithms = false;\r\n\t\t\t\talgorithmCode = command[i+1];\r\n\t\t\t\t\r\n\t\t\t\t// parameters for the algorithm:\r\n\t\t\t\tint j = 0;\r\n\t\t\t\twhile (command.length > i+2+j && !command[i+2+j].startsWith(\"-\")) {\r\n\t\t\t\t\tj++;\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\talgorithmParameters = new String[j];\r\n\t\t\t\tSystem.arraycopy(command, i+2, algorithmParameters, 0, j);\r\n\t\t\t\t\r\n\t\t\t\ti += (j + 2);\r\n\t\t\t}\r\n\t\t}\r\n\t}", "private static List<TokenInfo> parsePara(String args) {\n\t\tList<TokenInfo> tokens = new ArrayList<TokenInfo>();\n\t\tStringBuffer token = new StringBuffer();\n\t\tint status = 0;\n\t\tfor_bp: for (int i = 0; i < args.length(); i++) {\n\t\t\tchar c = args.charAt(i);\n\t\t\tswitch (c) {\n\t\t\tcase ' ': {\n\t\t\t\tswitch (status) {\n\t\t\t\tcase 0:\n\t\t\t\t\tbreak;\n\t\t\t\tcase 2:\n\t\t\t\t\ttokenIn(tokens, token, status);\n\t\t\t\t\tstatus = 0;\n\t\t\t\t\tbreak;\n\t\t\t\tcase 3:\n\t\t\t\t\ttokenIn(tokens, token, status);\n\t\t\t\t\tstatus = 0;\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\tstatus = -1;\n\t\t\t\t\tbreak for_bp;\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tcase '-': {\n\t\t\t\tswitch (status) {\n\t\t\t\tcase 0:\n\t\t\t\t\tstatus = 1;\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\tstatus = -1;\n\t\t\t\t\tbreak for_bp;\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tcase 'a':\n\t\t\tcase 'b':\n\t\t\tcase 'c':\n\t\t\tcase 'd':\n\t\t\tcase 'e':\n\t\t\tcase 'f':\n\t\t\tcase 'g':\n\t\t\tcase 'h':\n\t\t\tcase 'i':\n\t\t\tcase 'j':\n\t\t\tcase 'k':\n\t\t\tcase 'l':\n\t\t\tcase 'm':\n\t\t\tcase 'n':\n\t\t\tcase 'o':\n\t\t\tcase 'p':\n\t\t\tcase 'q':\n\t\t\tcase 'r':\n\t\t\tcase 's':\n\t\t\tcase 't':\n\t\t\tcase 'u':\n\t\t\tcase 'v':\n\t\t\tcase 'w':\n\t\t\tcase 'x':\n\t\t\tcase 'y':\n\t\t\tcase 'z':\n\t\t\tcase 'A':\n\t\t\tcase 'B':\n\t\t\tcase 'C':\n\t\t\tcase 'D':\n\t\t\tcase 'E':\n\t\t\tcase 'F':\n\t\t\tcase 'G':\n\t\t\tcase 'H':\n\t\t\tcase 'I':\n\t\t\tcase 'J':\n\t\t\tcase 'K':\n\t\t\tcase 'L':\n\t\t\tcase 'M':\n\t\t\tcase 'N':\n\t\t\tcase 'O':\n\t\t\tcase 'P':\n\t\t\tcase 'Q':\n\t\t\tcase 'R':\n\t\t\tcase 'S':\n\t\t\tcase 'T':\n\t\t\tcase 'U':\n\t\t\tcase 'V':\n\t\t\tcase 'W':\n\t\t\tcase 'X':\n\t\t\tcase 'Y':\n\t\t\tcase 'Z': {\n\t\t\t\tswitch (status) {\n\t\t\t\tcase 1:\n\t\t\t\tcase 2:\n\t\t\t\t\ttoken.append(c);\n\t\t\t\t\tstatus = 2;\n\t\t\t\t\tbreak;\n\t\t\t\tcase 0:\n\t\t\t\tcase 3:\n\t\t\t\t\ttoken.append(c);\n\t\t\t\t\tstatus = 3;\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\tstatus = -1;\n\t\t\t\t\tbreak for_bp;\n\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tcase '0':\n\t\t\tcase '1':\n\t\t\tcase '2':\n\t\t\tcase '3':\n\t\t\tcase '4':\n\t\t\tcase '5':\n\t\t\tcase '6':\n\t\t\tcase '7':\n\t\t\tcase '8':\n\t\t\tcase '9': {\n\t\t\t\tswitch (status) {\n\t\t\t\tcase 0:\n\t\t\t\t\ttoken.append(c);\n\t\t\t\t\tstatus = 3;\n\t\t\t\t\tbreak;\n\t\t\t\tcase 1:\n\t\t\t\t\ttoken.append('-');\n\t\t\t\t\ttoken.append(c);\n\t\t\t\t\tstatus = 3;\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\ttoken.append(c);\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\tdefault: {\n\t\t\t\tswitch (status) {\n\t\t\t\tcase 0:\n\t\t\t\t\ttoken.append(c);\n\t\t\t\t\tstatus = 3;\n\t\t\t\t\tbreak;\n\t\t\t\tcase 2:\n\t\t\t\tcase 3:\n\t\t\t\t\ttoken.append(c);\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\tstatus = -1;\n\t\t\t\t\tbreak for_bp;\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\ttokenIn(tokens, token, status);\n\n\t\treturn tokens;\n\t}", "public abstract List<String> getDirs( );", "private static String optionsListing() {\n\t\tString result = \"\\nUsage: java -jar comtor.jar -dir dirname\\n\\n\";\n\t\tresult += \"Options:\\n\";\n\t\t\n\t\tresult += \"-dir dirname\\t\\tSpecified the pathname of the directory in which COMTOR will \"; \n\t\tresult += \"search for Java source code\\n\\t\\t\\tfiles (packaged and non-packaged).\\n\\n\";\n\t\t\n\t\tresult += \"-help | --help\\t\\tThis help message\\n\";\n\t\tresult += \"\\n\\n\";\n\t\treturn result;\n\t}", "int commandFor(String s) throws AmbiguousException\t\t\t{ return determineCommand(g_commandArray, s, CMD_UNKNOWN);\t}", "private static TaskResultAnalysis extractArguments(String[] args) {\r\n\t\tif (args == null || args.length < 1)\r\n\t\t\treturn null;\r\n\t\tFile directory = null;\r\n\t\tFile output = null;\r\n\t\tString workflow = null;\r\n\t\tString header = null;\r\n\t\tboolean printTasks = false;\r\n\t\tfor (int i=0; i<args.length; i++) {\r\n\t\t\tString argument = args[i];\r\n\t\t\tif (argument == null)\r\n\t\t\t\treturn null;\r\n\t\t\telse if (argument.equals(\"-printTasks\"))\r\n\t\t\t\tprintTasks = true;\r\n\t\t\telse {\r\n\t\t\t\ti++;\r\n\t\t\t\tif (i >= args.length)\r\n\t\t\t\t\treturn null;\r\n\t\t\t\tString value = args[i];\r\n\t\t\t\tif (argument.equals(\"-directory\"))\r\n\t\t\t\t\tdirectory = new File(value);\r\n\t\t\t\telse if (argument.equals(\"-output\"))\r\n\t\t\t\t\toutput = new File(value);\r\n\t\t\t\telse if (argument.equals(\"-workflow\"))\r\n\t\t\t\t\tworkflow = value;\r\n\t\t\t\telse if (argument.equals(\"-header\"))\r\n\t\t\t\t\theader = value;\r\n\t\t\t\telse return null;\r\n\t\t\t}\r\n\t\t}\r\n\t\ttry {\r\n\t\t\treturn new TaskResultAnalysis(\r\n\t\t\t\toutput, directory, workflow, header, printTasks);\r\n\t\t} catch (Throwable error) {\r\n\t\t\tSystem.err.println(error.getMessage());\r\n\t\t\treturn null;\r\n\t\t}\r\n\t}", "Status stat() throws IOException {\n Protocol protocol = this;\n synchronized (protocol) {\n Status status;\n String string2;\n Response response = this.simpleCommand(\"STAT\");\n status = new Status();\n if (response.ok && (string2 = response.data) != null) {\n try {\n StringTokenizer stringTokenizer = new StringTokenizer(response.data);\n status.total = Integer.parseInt((String)stringTokenizer.nextToken());\n status.size = Integer.parseInt((String)stringTokenizer.nextToken());\n }\n catch (Exception exception) {}\n }\n return status;\n }\n }", "public static void main(String[] args) {\n\t\t\n\t\t\n String directoryListing = \"dir1\\n dir11\\n dir1111\\n picture.gif\\n text1.txt\\n dir112\\n sample1.jpeg\\n dir12\\n sample2.gif\";\n\t\t//String directoryListing = \"dir1\\n dir11\\n dir111\\n picture.gif\\n\";\n\t \n\t\tSystem.out.println(\"\\nThe total length of the Absolute paths containing the images is: \"+getLengthOfAbsolutePathsForImages(directoryListing));\n\n\t\t\n\t}", "public String startAgentServer(short sid,\n File dir) throws Exception {\n StringTokenizer st = new StringTokenizer(a3config.getJvmArgs(sid));\n int nb = st.countTokens();\n String[] jvmargs = new String[nb];\n for (int i=0; i<nb; i++){\n jvmargs[i] = st.nextToken();\n }\n\n return scadmin.startAgentServer(sid, dir, jvmargs);\n }", "public final VecMathParser.prog_return prog() throws RecognitionException {\n VecMathParser.prog_return retval = new VecMathParser.prog_return();\n retval.start = input.LT(1);\n\n Object root_0 = null;\n\n VecMathParser.stat_return stat1 = null;\n\n\n\n try {\n // /Users/parrt/research/book/TPDSL/Book/code/walking/tree-grammar/VecMath.g:8:5: ( ( stat )+ )\n // /Users/parrt/research/book/TPDSL/Book/code/walking/tree-grammar/VecMath.g:8:7: ( stat )+\n {\n root_0 = (Object)adaptor.nil();\n\n // /Users/parrt/research/book/TPDSL/Book/code/walking/tree-grammar/VecMath.g:8:7: ( stat )+\n int cnt1=0;\n loop1:\n do {\n int alt1=2;\n int LA1_0 = input.LA(1);\n\n if ( (LA1_0==ID||LA1_0==9) ) {\n alt1=1;\n }\n\n\n switch (alt1) {\n \tcase 1 :\n \t // /Users/parrt/research/book/TPDSL/Book/code/walking/tree-grammar/VecMath.g:8:7: stat\n \t {\n \t pushFollow(FOLLOW_stat_in_prog34);\n \t stat1=stat();\n\n \t state._fsp--;\n\n \t adaptor.addChild(root_0, stat1.getTree());\n\n \t }\n \t break;\n\n \tdefault :\n \t if ( cnt1 >= 1 ) break loop1;\n EarlyExitException eee =\n new EarlyExitException(1, input);\n throw eee;\n }\n cnt1++;\n } while (true);\n\n\n }\n\n retval.stop = input.LT(-1);\n\n retval.tree = (Object)adaptor.rulePostProcessing(root_0);\n adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop);\n\n }\n catch (RecognitionException re) {\n reportError(re);\n recover(input,re);\n \tretval.tree = (Object)adaptor.errorNode(input, retval.start, input.LT(-1), re);\n\n }\n finally {\n }\n return retval;\n }", "public Command parse(String inputCommand) {\n Matcher matcher = BASIC_COMMAND_FORMAT.matcher(inputCommand.trim());\n if (!matcher.matches()) {\n return new IncorrectCommand(\"This is a incorrect format, \"\n + \" you may type the list to see all the commands.\"\n + \" the command should not contain the separator '|'\");\n }\n\n String commandWord = matcher.group(\"commandWord\");\n String arguments = matcher.group(\"arguments\");\n\n switch (commandWord) {\n case AddCommand.COMMAND_WORD:\n return prepareAdd(arguments);\n case ListCommand.COMMAND_WORD:\n return prepareList(arguments);\n\n case DoneCommand.COMMAND_WORD:\n return prepareDone(arguments);\n case DueCommand.COMMAND_WORD:\n return prepareDue(arguments);\n case DeleteCommand.COMMAND_WORD:\n return prepareDelete(arguments);\n\n case SetCommand.COMMAND_WORD:\n return prepareSet(arguments);\n\n case ExitCommand.COMMAND_WORD:\n return new ExitCommand();\n\n case ProjModeCommand.COMMAND_WORD:\n return new ProjModeCommand();\n\n // case HelpCommand.COMMAND_WORD:\n // default:\n // return new HelpCommand();\n\n default:\n return new IncorrectCommand(\"IncorrectCommand\");\n }\n\n }", "@Override\n\tpublic String[] query() {\n\t\t// Return an array of (decoded) filenames\n\t\tif (!serviceDir.exists()) {\n\t\t\treturn new String[0];\n\t\t}\n\t\tFile[] files = serviceDir.listFiles();\n\t\tString[] addrs = new String[files.length];\n\t\tfor (int i = 0; i < addrs.length; ++i) {\n\t\t\taddrs[i] = decode(files[i].getName());\n\t\t}\n\t\treturn addrs;\n\t}", "public Path parsePath(final String s) {\n setString(s);\n p = preparePath();\n\n setString(s);\n\n currentX = 0;\n currentY = 0;\n smoothQCenterX = 0;\n smoothQCenterY = 0;\n smoothCCenterX = 0;\n smoothCCenterY = 0;\n\n current = read();\n skipSpaces();\n\n // Multiple coordinate pairs after a moveto\n // are like a moveto followed by lineto\n switch(current) {\n case 'm':\n parsem();\n parsel();\n break;\n case 'M':\n parseM();\n parseL();\n break;\n\tcase -1:\n \t //an empty path is valid.\n \t break; \n default:\n throw new IllegalArgumentException();\n }\n\n loop: for (;;) {\n switch (current) {\n case 0xD:\n case 0xA: \n case 0x20:\n case 0x9:\n current = read();\n break;\n case 'z':\n case 'Z':\n current = read();\n p.close();\n currentX = lastMoveToX;\n currentY = lastMoveToY;\n break;\n case 'm':\n parsem();\n case 'l':\n parsel();\n break;\n case 'M':\n parseM();\n case 'L':\n parseL();\n break;\n case 'h':\n parseh();\n break;\n case 'H':\n parseH();\n break;\n case 'v':\n parsev();\n break;\n case 'V':\n parseV();\n break;\n case 'c':\n parsec();\n break;\n case 'C':\n parseC();\n break;\n case 'q':\n parseq();\n break;\n case 'Q':\n parseQ();\n break;\n case 's':\n parses();\n break;\n case 'S':\n parseS();\n break;\n case 't':\n parset();\n break;\n case 'T':\n parseT();\n break;\n case -1:\n break loop;\n default:\n throw new IllegalArgumentException();\n }\n \n }\n\n skipSpaces();\n if (current != -1) {\n throw new IllegalArgumentException();\n }\n\n return p;\n }", "void parse(String[] args);", "public Output(boolean status, String entry, String cmdType) {\n\t\tthis._status = status;\n\t\tthis._entry = entry;\n\t\tthis._results = new ArrayList<Task>();\n\t\tthis._cmdType = cmdType;\n\t}", "public static Command parse(String command) throws DukeException {\n // remove trailing/leading whitespace and split by whitespace(s)\n command = command.strip();\n String[] commands = command.split(\"[ ]+\");\n String[] args = Arrays.copyOfRange(commands, 1, commands.length);\n\n assert args.length == commands.length - 1 : \"Incorrect array copy\";\n\n switch (commands[0]) {\n case \"todo\":\n return parseTodoCommand(args);\n case \"event\":\n return parseEventCommand(args);\n case \"deadline\":\n return parseDeadlineCommand(args);\n case \"find\":\n return parseFindCommand(args);\n case \"done\":\n return parseDoneCommand(args);\n case \"delete\":\n return parseDeleteCommand(args);\n case \"list\":\n return parseListCommand(args);\n case \"remindme\":\n return parseRemindCommand(args);\n case \"bye\":\n return parseBye(args);\n default:\n throw new DukeMissingDescriptionException(\"Hmm... I'm sorry, but I don't know what that means...\");\n }\n }", "public ViewStorageCommand parse(String args) throws ParseException {\n String trimmedArgs = args.trim();\n if (trimmedArgs.isEmpty()) {\n throw new ParseException(\n String.format(MESSAGE_INVALID_COMMAND_FORMAT, ViewStorageCommand.MESSAGE_USAGE));\n }\n Matcher matcher = ViewStorageCommand_Argument_Format.matcher(trimmedArgs);\n if (!matcher.matches()) {\n throw new ParseException(\n String.format(MESSAGE_INVALID_COMMAND_FORMAT, ViewStorageCommand.MESSAGE_USAGE)\n );\n }\n String[] path = matcher.group(\"rawpath\").split(\"\\\\\\\\\");\n return new ViewStorageCommand(path);\n }", "public Command parse(String[] s) {\n\t\t\n\t\tif(s.length == 1 && s[0].equalsIgnoreCase(\"RUN\"))\n\t\t\treturn new Run();\n\t\telse return null;\n\t}" ]
[ "0.5189179", "0.5159227", "0.50037456", "0.49648675", "0.4951047", "0.49499956", "0.480178", "0.47724304", "0.47695878", "0.47284392", "0.4695947", "0.46897447", "0.46638253", "0.46442732", "0.4608855", "0.46076885", "0.45501542", "0.45424944", "0.45219547", "0.44964194", "0.448884", "0.4482035", "0.44779935", "0.44778284", "0.44758773", "0.44669548", "0.4458763", "0.44442874", "0.4416913", "0.43975443", "0.43734673", "0.43729904", "0.43677604", "0.43630412", "0.43581042", "0.4342431", "0.43408945", "0.43372077", "0.43296057", "0.43272987", "0.4315871", "0.4309866", "0.43096685", "0.43039727", "0.42884985", "0.42850187", "0.42832568", "0.42807662", "0.4271726", "0.42697707", "0.42676103", "0.4264412", "0.42590052", "0.42539108", "0.42531502", "0.42528528", "0.42351288", "0.42318478", "0.42281187", "0.4225933", "0.4216178", "0.4213238", "0.42022038", "0.41956624", "0.4188009", "0.41850328", "0.41791984", "0.41486636", "0.41478908", "0.41464376", "0.41409668", "0.41371658", "0.41367814", "0.41354963", "0.41321144", "0.4131073", "0.41310006", "0.41248944", "0.41241395", "0.41227114", "0.41217163", "0.41212228", "0.41143653", "0.41079804", "0.4099795", "0.40981904", "0.40966025", "0.4092924", "0.40896213", "0.40851206", "0.40828142", "0.4081859", "0.40800607", "0.4077876", "0.40777668", "0.40731394", "0.40717587", "0.4068653", "0.40683603", "0.40644228", "0.40634927" ]
0.0
-1
/ renamed from: c
public i getItem(int position) { ArrayList<MenuItemImpl> items = this.f205e ? this.f202b.z() : this.f202b.E(); int i = this.f203c; if (i >= 0 && position >= i) { position++; } return (i) items.get(position); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "void mo5289a(C5102c c5102c);", "public static void c0() {\n\t}", "void mo57278c();", "private static void cajas() {\n\t\t\n\t}", "void mo5290b(C5102c c5102c);", "void mo80457c();", "void mo12638c();", "void mo28717a(zzc zzc);", "void mo21072c();", "@Override\n\tpublic void ccc() {\n\t\t\n\t}", "public void c() {\n }", "void mo17012c();", "C2451d mo3408a(C2457e c2457e);", "void mo88524c();", "void mo86a(C0163d c0163d);", "void mo17021c();", "public abstract void mo53562a(C18796a c18796a);", "void mo4874b(C4718l c4718l);", "void mo4873a(C4718l c4718l);", "C12017a mo41088c();", "public abstract void mo70702a(C30989b c30989b);", "void mo72114c();", "public void mo12628c() {\n }", "C2841w mo7234g();", "public interface C0335c {\n }", "public void mo1403c() {\n }", "public static void c3() {\n\t}", "public static void c1() {\n\t}", "void mo8712a(C9714a c9714a);", "void mo67924c();", "public void mo97906c() {\n }", "public abstract void mo27385c();", "String mo20731c();", "public int c()\r\n/* 74: */ {\r\n/* 75:78 */ return this.c;\r\n/* 76: */ }", "public interface C0939c {\n }", "void mo1582a(String str, C1329do c1329do);", "void mo304a(C0366h c0366h);", "void mo1493c();", "private String getString(byte c) {\n\t\treturn c==1? \"$ \": \" \";\n\t}", "java.lang.String getC3();", "C45321i mo90380a();", "public interface C11910c {\n}", "void mo57277b();", "String mo38972c();", "static int type_of_cnc(String passed){\n\t\treturn 1;\n\t}", "public static void CC2_1() {\n\t}", "static int type_of_cc(String passed){\n\t\treturn 1;\n\t}", "public interface C7654b {\n /* renamed from: a */\n C7904c mo24084a();\n\n /* renamed from: b */\n C7716a mo24085b();\n }", "public void mo56167c() {\n }", "public interface C0136c {\n }", "private void kk12() {\n\n\t}", "abstract String mo1748c();", "public abstract void mo70710a(String str, C24343db c24343db);", "public interface C0303q extends C0291e {\n /* renamed from: a */\n void mo1747a(int i);\n\n /* renamed from: a */\n void mo1749a(C0288c cVar);\n\n /* renamed from: a */\n void mo1751a(byte[] bArr);\n\n /* renamed from: b */\n void mo1753b(int i);\n\n /* renamed from: c */\n void mo1754c(int i);\n\n /* renamed from: d */\n void mo1755d(int i);\n\n /* renamed from: e */\n int mo1756e(int i);\n\n /* renamed from: g */\n int mo1760g();\n\n /* renamed from: g */\n void mo1761g(int i);\n\n /* renamed from: h */\n void mo1763h(int i);\n}", "C3577c mo19678C();", "public abstract int c();", "public abstract int c();", "public final void mo11687c() {\n }", "byte mo30283c();", "private java.lang.String c(java.lang.String r7) {\n /*\n r6 = this;\n r2 = \"\";\n r0 = r6.e;\t Catch:{ FileNotFoundException -> 0x0052 }\n if (r0 == 0) goto L_0x0050;\n L_0x0006:\n r0 = new java.lang.StringBuilder;\t Catch:{ FileNotFoundException -> 0x0052 }\n r1 = java.lang.String.valueOf(r7);\t Catch:{ FileNotFoundException -> 0x0052 }\n r0.<init>(r1);\t Catch:{ FileNotFoundException -> 0x0052 }\n r1 = \".\";\n r0 = r0.append(r1);\t Catch:{ FileNotFoundException -> 0x0052 }\n r1 = r6.e;\t Catch:{ FileNotFoundException -> 0x0052 }\n r0 = r0.append(r1);\t Catch:{ FileNotFoundException -> 0x0052 }\n r0 = r0.toString();\t Catch:{ FileNotFoundException -> 0x0052 }\n L_0x001f:\n r1 = r6.d;\t Catch:{ FileNotFoundException -> 0x0052 }\n r1 = r1.openFileInput(r0);\t Catch:{ FileNotFoundException -> 0x0052 }\n L_0x0025:\n r3 = new java.io.BufferedReader;\n r4 = new java.io.InputStreamReader;\n r0 = r1;\n r0 = (java.io.InputStream) r0;\n r5 = \"UTF-8\";\n r5 = java.nio.charset.Charset.forName(r5);\n r4.<init>(r0, r5);\n r3.<init>(r4);\n r0 = new java.lang.StringBuffer;\n r0.<init>();\n L_0x003d:\n r4 = r3.readLine();\t Catch:{ IOException -> 0x0065, all -> 0x0073 }\n if (r4 != 0) goto L_0x0061;\n L_0x0043:\n r0 = r0.toString();\t Catch:{ IOException -> 0x0065, all -> 0x0073 }\n r1 = (java.io.InputStream) r1;\t Catch:{ IOException -> 0x007d }\n r1.close();\t Catch:{ IOException -> 0x007d }\n r3.close();\t Catch:{ IOException -> 0x007d }\n L_0x004f:\n return r0;\n L_0x0050:\n r0 = r7;\n goto L_0x001f;\n L_0x0052:\n r0 = move-exception;\n r0 = r6.d;\t Catch:{ IOException -> 0x005e }\n r0 = r0.getAssets();\t Catch:{ IOException -> 0x005e }\n r1 = r0.open(r7);\t Catch:{ IOException -> 0x005e }\n goto L_0x0025;\n L_0x005e:\n r0 = move-exception;\n r0 = r2;\n goto L_0x004f;\n L_0x0061:\n r0.append(r4);\t Catch:{ IOException -> 0x0065, all -> 0x0073 }\n goto L_0x003d;\n L_0x0065:\n r0 = move-exception;\n r1 = (java.io.InputStream) r1;\t Catch:{ IOException -> 0x0070 }\n r1.close();\t Catch:{ IOException -> 0x0070 }\n r3.close();\t Catch:{ IOException -> 0x0070 }\n r0 = r2;\n goto L_0x004f;\n L_0x0070:\n r0 = move-exception;\n r0 = r2;\n goto L_0x004f;\n L_0x0073:\n r0 = move-exception;\n r1 = (java.io.InputStream) r1;\t Catch:{ IOException -> 0x007f }\n r1.close();\t Catch:{ IOException -> 0x007f }\n r3.close();\t Catch:{ IOException -> 0x007f }\n L_0x007c:\n throw r0;\n L_0x007d:\n r1 = move-exception;\n goto L_0x004f;\n L_0x007f:\n r1 = move-exception;\n goto L_0x007c;\n */\n throw new UnsupportedOperationException(\"Method not decompiled: com.tencent.a.b.b.c(java.lang.String):java.lang.String\");\n }", "@Override\n\tpublic void compile(CodeBlock c, CompilerEnvironment environment) {\n\n\t}", "public interface C3196it extends C3208jc {\n /* renamed from: a */\n void mo30275a(long j);\n\n /* renamed from: b */\n C3197iu mo30281b(long j);\n\n /* renamed from: b */\n boolean mo30282b();\n\n /* renamed from: c */\n byte mo30283c();\n\n /* renamed from: c */\n String mo30285c(long j);\n\n /* renamed from: d */\n void mo30290d(long j);\n\n /* renamed from: e */\n int mo30291e();\n\n /* renamed from: f */\n long mo30295f();\n}", "public static void mmcc() {\n\t}", "java.lang.String getCit();", "public abstract C mo29734a();", "C15430g mo56154a();", "void mo41086b();", "@Override\n public void func_104112_b() {\n \n }", "public interface C9223b {\n }", "public abstract String mo11611b();", "void mo27952b(C5379a c5379a, int i, C46650a c46650a, C7620bi c7620bi);", "String getCmt();", "interface C30585a {\n /* renamed from: b */\n void mo27952b(C5379a c5379a, int i, C46650a c46650a, C7620bi c7620bi);\n }", "interface C2578d {\n}", "public interface C1803l extends C1813t {\n /* renamed from: b */\n C1803l mo7382b(C2778au auVar);\n\n /* renamed from: f */\n List<C1700ar> mo7233f();\n\n /* renamed from: g */\n C2841w mo7234g();\n\n /* renamed from: q */\n C1800i mo7384q();\n}", "double fFromC(double c) {\n return (c * 9 / 5) + 32;\n }", "void mo72113b();", "void mo1749a(C0288c cVar);", "public interface C0764b {\n}", "void mo41083a();", "String[] mo1153c();", "C1458cs mo7613iS();", "public interface C0333a {\n }", "public abstract int mo41077c();", "public interface C8843g {\n}", "public abstract void mo70709a(String str, C41018cm c41018cm);", "void mo28307a(zzgd zzgd);", "public static void mcdc() {\n\t}", "public interface C2459d {\n /* renamed from: a */\n C2451d mo3408a(C2457e c2457e);\n}", "C1435c mo1754a(C1433a c1433a, C1434b c1434b);", "public interface C0389gj extends C0388gi {\n}", "C5727e mo33224a();", "C12000e mo41087c(String str);", "public abstract String mo118046b();", "public interface C11113o {\n /* renamed from: a */\n void mo37759a(String str);\n }", "public interface C0938b {\n }", "void mo80455b();", "public interface C0385a {\n }", "public interface C5527c {\n /* renamed from: a */\n int mo4095a(int i);\n\n /* renamed from: b */\n C5537g mo4096b(int i);\n}", "public interface C32231g {\n /* renamed from: a */\n void mo8280a(int i, int i2, C1207m c1207m);\n}", "public interface C11994b {\n /* renamed from: a */\n C11996a mo41079a(String str);\n\n /* renamed from: a */\n C11996a mo41080a(String str, C11997b bVar, String... strArr);\n\n /* renamed from: a */\n C11998c mo41081a(String str, C11999d dVar, String... strArr);\n\n /* renamed from: a */\n C12000e mo41082a(String str, C12001f fVar, String... strArr);\n\n /* renamed from: a */\n void mo41083a();\n\n /* renamed from: a */\n void mo41084a(C12018b bVar, ConnectionState... connectionStateArr);\n\n /* renamed from: b */\n C11996a mo41085b(String str);\n\n /* renamed from: b */\n void mo41086b();\n\n /* renamed from: c */\n C12000e mo41087c(String str);\n\n /* renamed from: c */\n C12017a mo41088c();\n\n /* renamed from: d */\n void mo41089d(String str);\n\n /* renamed from: e */\n C11998c mo41090e(String str);\n\n /* renamed from: f */\n C12000e mo41091f(String str);\n\n /* renamed from: g */\n C11998c mo41092g(String str);\n}" ]
[ "0.64592767", "0.644052", "0.6431582", "0.6418656", "0.64118475", "0.6397491", "0.6250796", "0.62470585", "0.6244832", "0.6232792", "0.618864", "0.61662376", "0.6152657", "0.61496663", "0.6138441", "0.6137171", "0.6131197", "0.6103783", "0.60983956", "0.6077118", "0.6061723", "0.60513836", "0.6049069", "0.6030368", "0.60263443", "0.60089093", "0.59970635", "0.59756917", "0.5956231", "0.5949343", "0.5937446", "0.5911776", "0.59034705", "0.5901311", "0.5883238", "0.5871533", "0.5865361", "0.5851141", "0.581793", "0.5815705", "0.58012", "0.578891", "0.57870495", "0.5775621", "0.57608724", "0.5734331", "0.5731584", "0.5728505", "0.57239383", "0.57130504", "0.57094604", "0.570793", "0.5697671", "0.56975955", "0.56911296", "0.5684489", "0.5684489", "0.56768984", "0.56749034", "0.5659463", "0.56589085", "0.56573", "0.56537443", "0.5651912", "0.5648272", "0.5641736", "0.5639226", "0.5638583", "0.56299245", "0.56297386", "0.56186295", "0.5615729", "0.56117755", "0.5596015", "0.55905765", "0.55816257", "0.55813104", "0.55723965", "0.5572061", "0.55696625", "0.5566985", "0.55633485", "0.555888", "0.5555646", "0.55525774", "0.5549722", "0.5548184", "0.55460495", "0.5539394", "0.5535825", "0.55300397", "0.5527975", "0.55183905", "0.5517322", "0.5517183", "0.55152744", "0.5514932", "0.55128884", "0.5509501", "0.55044043", "0.54984957" ]
0.0
-1
assertion: all files are different
public static Map<Module, List<VirtualFile>> buildModuleToFilesMap(final CompileContext context, final List<VirtualFile> files) { final Map<Module, List<VirtualFile>> map = new THashMap<Module, List<VirtualFile>>(); ApplicationManager.getApplication().runReadAction(new Runnable() { public void run() { for (VirtualFile file : files) { final Module module = context.getModuleByFile(file); if (module == null) { continue; // looks like file invalidated } List<VirtualFile> moduleFiles = map.get(module); if (moduleFiles == null) { moduleFiles = new ArrayList<VirtualFile>(); map.put(module, moduleFiles); } moduleFiles.add(file); } } }); return map; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Test\n public void equalsDifferentName(){\n\n InputStream url1= getClass().getClassLoader().getResourceAsStream(\"backupTest/backup_1.json\");\n InputStream url1h= getClass().getClassLoader().getResourceAsStream(\"backupTest/backup_1h.json\");\n\n Backup backup_a = Backup.initFromFile(url1);\n Backup backup_b = Backup.initFromFile(url1h);\n\n assertNotEquals(backup_a, backup_b);\n }", "@Test\n public void equalsBetweenBackupsFromIdenticalFiles(){\n //backup_1 and backup_1b contain exactly the same text\n InputStream url= getClass().getClassLoader().getResourceAsStream(\"backupTest/backup_1.json\");\n\n Backup backup_a = Backup.initFromFile(url);\n Backup backup_b = Backup.initFromFile(getClass().getClassLoader().getResourceAsStream(\"backupTest/backup_1.json\"));\n\n assertEquals(backup_a, backup_b);\n assertTrue(backup_a.equals(backup_b));\n }", "@Test\n public void equalsDifferentDamageList(){\n\n InputStream url1= getClass().getClassLoader().getResourceAsStream(\"backupTest/backup_1.json\");\n InputStream url1g= getClass().getClassLoader().getResourceAsStream(\"backupTest/backup_1g.json\");\n\n Backup backup_a = Backup.initFromFile(url1);\n Backup backup_b = Backup.initFromFile(url1g);\n\n assertNotEquals(backup_a, backup_b);\n }", "@Test\n public void equalsBetweenDifferentBackups(){\n //backup_1 and backup_1b differs from\n InputStream url1= getClass().getClassLoader().getResourceAsStream(\"backupTest/backup_1.json\");\n InputStream url1b= getClass().getClassLoader().getResourceAsStream(\"backupTest/backup_1b.json\");\n\n Backup backup_a = Backup.initFromFile(url1);\n Backup backup_b = Backup.initFromFile(url1b);\n\n assertNotEquals(backup_a, backup_b);\n }", "@Test\n public void equalsDifferentOrder(){\n //backup_1e contains many things in different order, but it is equal to backup_1\n\n InputStream url1= getClass().getClassLoader().getResourceAsStream(\"backupTest/backup_1.json\");\n InputStream url1e= getClass().getClassLoader().getResourceAsStream(\"backupTest/backup_1e.json\");\n\n Backup backup_a = Backup.initFromFile(url1);\n Backup backup_b = Backup.initFromFile(url1e);\n\n assertEquals(backup_a, backup_b);\n }", "@Test //same file\n\t\t\tpublic void SameFileDifferentInstances() throws PizzaException, LogHandlerException{\n\t\t\t\tArrayList<Pizza> pizzaArr1;\n\t\t\t\tArrayList<Pizza> pizzaArr2;\n\n\t\t\t\tPath currentRelativePath = Paths.get(\"\");\n\t\t\t\tString s = currentRelativePath.toAbsolutePath().toString();\n\t\t\t\tString path = s + \"\\\\logs\\\\20170101.txt\";\n\t\t\t\t\n\t\t\t\t\n\t\t\t\tpizzaArr2 = LogHandler.populatePizzaDataset(path);\n\t\t\t\tpizzaArr1 = LogHandler.populatePizzaDataset(path);\n\t\t\t\tassertNotEquals(pizzaArr2.hashCode(), pizzaArr1.hashCode());\n\t\t\t}", "private void assertOutputFiles(Path outputDir) throws Exception {\n\n assertThat(outputDir.exists()).isTrue();\n assertThat(outputDir.getRelative(REGULAR_FILE_NAME).exists()).isTrue();\n assertThat(outputDir.getRelative(REGULAR_FILE_NAME).getFileSize()).isNotEqualTo(0);\n assertThat(outputDir.getRelative(REGULAR_FILE_NAME).isSymbolicLink()).isFalse();\n assertThat(outputDir.getRelative(HARD_LINK_FILE_NAME).exists()).isTrue();\n assertThat(outputDir.getRelative(HARD_LINK_FILE_NAME).getFileSize()).isNotEqualTo(0);\n assertThat(outputDir.getRelative(HARD_LINK_FILE_NAME).isSymbolicLink()).isFalse();\n assertThat(outputDir.getRelative(RELATIVE_SYMBOLIC_LINK_FILE_NAME).exists()).isTrue();\n assertThat(outputDir.getRelative(RELATIVE_SYMBOLIC_LINK_FILE_NAME).getFileSize())\n .isNotEqualTo(0);\n assertThat(outputDir.getRelative(RELATIVE_SYMBOLIC_LINK_FILE_NAME).isSymbolicLink()).isTrue();\n assertThat(outputDir.getRelative(ABSOLUTE_SYMBOLIC_LINK_FILE_NAME).exists()).isTrue();\n assertThat(outputDir.getRelative(ABSOLUTE_SYMBOLIC_LINK_FILE_NAME).getFileSize())\n .isNotEqualTo(0);\n assertThat(outputDir.getRelative(ABSOLUTE_SYMBOLIC_LINK_FILE_NAME).isSymbolicLink()).isTrue();\n assertThat(\n Files.isSameFile(\n java.nio.file.Paths.get(outputDir.getRelative(REGULAR_FILE_NAME).toString()),\n java.nio.file.Paths.get(outputDir.getRelative(HARD_LINK_FILE_NAME).toString())))\n .isTrue();\n assertThat(\n Files.isSameFile(\n java.nio.file.Paths.get(outputDir.getRelative(REGULAR_FILE_NAME).toString()),\n java.nio.file.Paths.get(\n outputDir.getRelative(RELATIVE_SYMBOLIC_LINK_FILE_NAME).toString())))\n .isTrue();\n assertThat(\n Files.isSameFile(\n java.nio.file.Paths.get(outputDir.getRelative(REGULAR_FILE_NAME).toString()),\n java.nio.file.Paths.get(\n outputDir.getRelative(ABSOLUTE_SYMBOLIC_LINK_FILE_NAME).toString())))\n .isTrue();\n }", "private static void equalFiles(String fileOK, String fileToTest) throws IOException, EasyAcceptException { \n \t\t\n \tLineNumberReader lineReaderOK = null;\n \tLineNumberReader lineReaderToTest = null;\n \ttry {\n \t Reader readerOK = new FileReader( new File(fileOK) );\n \t lineReaderOK = new LineNumberReader( readerOK );\n \t \n \t Reader readerToTest = new FileReader( new File(fileToTest) );\n \t lineReaderToTest = new LineNumberReader( readerToTest );\n \t \n \t\tString lineOK = lineReaderOK.readLine();\n \t\tString lineToTest = lineReaderToTest.readLine();\n \n \t\twhile( (lineOK != null) && (lineToTest!= null) ){ \n \t\t\tif ( ! (lineOK.trim().equals(lineToTest.trim())) ) {\n \t\t\t\n \t\t\t\tthrow new EasyAcceptException( \"File diferences at line \"+ lineReaderOK.getLineNumber()+\". Expected <\"\n + lineOK.trim()+ \">, but was \"\n + \"<\"+lineToTest.trim()+\">\"); \n \t\t\t}\n \t\t\tlineOK = lineReaderOK.readLine();\n \t lineToTest = lineReaderToTest.readLine();\n \t }\n \t\tif (lineOK == null && lineToTest != null) {\n \t\t\tthrow new EasyAcceptException( \"File diferences at line \"+ lineReaderOK.getLineNumber()+\". Expected the end of file was but\"\n \t\t\t\t\t+\" extra line was found \"+\"< \"+lineToTest.trim()+\">\");\n \t}else if (lineOK != null && lineToTest == null) {\n \t\t\tthrow new EasyAcceptException( \"File diferences at line \"+ lineReaderOK.getLineNumber()+\". Expected <\"+\n lineOK.trim()+\">, but the end of file was found. \");\n \t}else if (lineOK == null && lineToTest == null) {\n \t\t }\n \t} finally{\n \t\t\tif(lineReaderOK!= null){\n \t\t\t\tlineReaderOK.close();\n \t\t\t}\n \t\t\tif(lineReaderToTest != null){\n \t\t\t\tlineReaderToTest.close();\n \t\t\t}\n \t}\n \t}", "@Test\n public void equalsPlayerDifferentOrder(){\n\n InputStream url1= getClass().getClassLoader().getResourceAsStream(\"backupTest/backup_1.json\");\n InputStream url1f= getClass().getClassLoader().getResourceAsStream(\"backupTest/backup_1f.json\");\n\n Backup backup_a = Backup.initFromFile(url1);\n Backup backup_b = Backup.initFromFile(url1f);\n\n assertNotEquals(backup_a, backup_b);\n }", "@Test\n public void anotherEqualsTest(){\n //another 'random' equals test\n\n InputStream url2a= getClass().getClassLoader().getResourceAsStream(\"backupTest/backup_2a.json\");\n InputStream url2b= getClass().getClassLoader().getResourceAsStream(\"backupTest/backup_2b.json\");\n\n Backup backup_a = Backup.initFromFile(url2a);\n Backup backup_b = Backup.initFromFile(url2b);\n\n assertEquals(backup_a, backup_b);\n }", "@Test\n\tpublic void sameModificationDate() throws IOException {\n\t\tFile firstFile = File.createTempFile(\"junit\", null);\n\t\tFile secondFile = File.createTempFile(\"junit\", null);\n\t\tsecondFile.setLastModified(firstFile.lastModified());\n\n\t\tFileTuple firstTuple = new FileTuple(firstFile, firstFile);\n\t\tFileTuple secondTuple = new FileTuple(secondFile, secondFile);\n\n\t\tassertThat(COMPARATOR.compare(firstTuple, secondTuple)).isZero();\n\t}", "@Test\n public void equalsWeaponsDifferentlyLoaded(){\n //backup_1 and backup_1d differs by the state of load of weapons\n //that is relevant, therefore they are not equal\n\n InputStream url1= getClass().getClassLoader().getResourceAsStream(\"backupTest/backup_1.json\");\n InputStream url1d= getClass().getClassLoader().getResourceAsStream(\"backupTest/backup_1d.json\");\n\n Backup backup_a = Backup.initFromFile(url1);\n Backup backup_b = Backup.initFromFile(url1d);\n\n assertNotEquals(backup_a, backup_b);\n }", "@Test\n public void equalsWeaponsInDifferentOrder(){\n //backup_1 and backup_1c differs by the order of weapons in players\n //weapons order is not relevant, therefore they are equal\n\n InputStream url1= getClass().getClassLoader().getResourceAsStream(\"backupTest/backup_1.json\");\n InputStream url1c= getClass().getClassLoader().getResourceAsStream(\"backupTest/backup_1c.json\");\n\n Backup backup_a = Backup.initFromFile(url1);\n Backup backup_b = Backup.initFromFile(url1c);\n\n assertEquals(backup_a, backup_b);\n }", "public void checkWithCorrectResults() {\n\t\tFile correctDir = new File (correctDir() + \"/\" + assignmentNo());\r\n\r\n//\t\tFile testDir = new File (\"Test Data/Test 110 F13 Assignments/Assignment3\");\r\n\t\tFile testDir = new File (testDir() + \"/\" + assignmentNo());\r\n\r\n\t\tString[] ignoreSuffixesArray = {\".zip\", \".ini\", \".json\", \"Submission attachment(s)\"};\r\n//\t\tString[] ignoreSuffixesArray = {\".zip\", \".ini\", \".json\"};\r\n\r\n\t\tList<String> ignoreSuffixesList = Arrays.asList(ignoreSuffixesArray);\r\n\t\tSystem.out.println(DirectoryUtils.compare (correctDir, testDir, ignoreSuffixesList));\r\n\t}", "@Test\n\tpublic void testHalDTOsEquality() throws IOException {\n\t\tString xml1 = FileUtils.readFileToString(new File(\"src/test/resources/META-INF/xml/halDTOxml1.xml\"), \"utf-8\");\n\t\tString xml2 = FileUtils.readFileToString(new File(\"src/test/resources/META-INF/xml/halDTOxml2.xml\"), \"utf-8\");\n\t\tAssert.assertTrue(xml1.equals(xml2));\n\t}", "@Override\n\tpublic boolean compareFiles(int f1, int f2) {\n\t\treturn false;\n\t}", "@Test(timeout = 4000)\n public void test18() throws Throwable {\n FileUtil fileUtil0 = new FileUtil();\n EvoSuiteFile evoSuiteFile0 = new EvoSuiteFile(\"/S_RYNHV)!DEYJP^3IL$.XML\");\n FileSystemHandling.createFolder(evoSuiteFile0);\n File file0 = fileUtil0.getSimilarItems(\"RYnHv)!DEyJP^3il$\", \"\");\n assertEquals(\"/S_RYNHV)!DEYJP^3IL$.XML\", file0.toString());\n assertFalse(file0.isFile());\n assertNotNull(file0);\n }", "private static boolean equalFile(String expectedFileName, String actualFileName)\n\t{\n\t\tboolean equal;\n\t BufferedReader bExpected;\n\t BufferedReader bActual;\n\t String expectedLine ;\n\t String actualLine ;\n\n\t equal = false;\n\t bExpected = null ;\n\t bActual = null ;\n\n\t try {\n\t bExpected = new BufferedReader(new FileReader(expectedFileName));\n\t bActual = new BufferedReader(new FileReader(actualFileName));\n\n\t if ((bExpected != null) && (bActual != null)) {\n\t expectedLine = bExpected.readLine() ;\n\t actualLine = bActual.readLine() ;\n\n\t if(((expectedLine != null) && expectedLine.equals(actualLine)) || ((expectedLine == null) && (actualLine == null)) )\n\t \tequal=true;\n\n\t while(expectedLine != null && equal)\n\t {\n\t expectedLine = bExpected.readLine() ;\n\t actualLine = bActual.readLine() ; \n\t equal = expectedLine.equals(actualLine) ;\n\t }\n\t }\n\t } \n\t catch (Exception e) {} \n\t finally {\n\t try {\n\t if (bExpected != null) {\n\t bExpected.close();\n\t }\n\t if (bActual != null) {\n\t bActual.close();\n\t }\n\t } catch (Exception e) {}\n\t }\n\t return equal; \n\t}", "private void areEquals(FileInfo a, FileInfo b)\n\t{\n\t\t// will test a subset for now\n\n\t\tassertEquals(a.width,b.width);\n\t\tassertEquals(a.height,b.height);\n\t\tassertEquals(a.nImages,b.nImages);\n\t\tassertEquals(a.whiteIsZero,b.whiteIsZero);\n\t\tassertEquals(a.intelByteOrder,b.intelByteOrder);\n\t\tassertEquals(a.pixels,b.pixels);\n\t\tassertEquals(a.pixelWidth,b.pixelWidth,Assert.DOUBLE_TOL);\n\t\tassertEquals(a.pixelHeight,b.pixelHeight,Assert.DOUBLE_TOL);\n\t\tassertEquals(a.unit,b.unit);\n\t\tassertEquals(a.pixelDepth,b.pixelDepth,Assert.DOUBLE_TOL);\n\t\tassertEquals(a.frameInterval,b.frameInterval,Assert.DOUBLE_TOL);\n\t\tassertEquals(a.calibrationFunction,b.calibrationFunction);\n\t\tAssert.assertDoubleArraysEqual(a.coefficients,b.coefficients,Assert.DOUBLE_TOL);\n\t\tassertEquals(a.valueUnit,b.valueUnit);\n\t\tassertEquals(a.fileType,b.fileType);\n\t\tassertEquals(a.lutSize,b.lutSize);\n\t\tassertArrayEquals(a.reds,b.reds);\n\t\tassertArrayEquals(a.greens,b.greens);\n\t\tassertArrayEquals(a.blues,b.blues);\n\t}", "@Test\n public void testCompareEqual() {\n System.out.println(\"compare\");\n FileNameComparator instance = new FileNameComparator();\n int expResult = 0;\n int result = instance.compare(testFileA, testFileA);\n Assert.assertEquals(expResult, result);\n }", "@Test\n\tpublic void testIsConsistentModifiedFile() throws Exception {\n\t\tIRodinFile rodinFile = createRodinFile(\"P/x.test\");\n\t\tRodinTestRoot root = (RodinTestRoot) rodinFile.getRoot();\n\t\tcreateNEPositive(root, \"foo\", null);\n\t\tassertFalse(\"modified file should not be consistent\", \n\t\t\t\trodinFile.isConsistent());\n\n\t\t// Should report the same after closing the file.\n\t\trodinFile.close();\n\t\tassertFalse(\"modified file should not be consistent\", \n\t\t\t\trodinFile.isConsistent());\n\t}", "private void checkFileCreation(String name) throws IOException {\n byte[] buff = \"some bytes\".getBytes();\n writeFile(name, buff);\n assertTrue(Arrays.equals(buff, readFile(name, buff.length)));\n }", "private void compareFirstPass() {\n this.oldFileNoMatch = new HashMap<String, SubsetElement>();\r\n Iterator<String> iter = this.oldFile.keySet().iterator();\r\n while (iter.hasNext()) {\r\n final String key = iter.next();\r\n if (!this.newFile.containsKey(key)) {\r\n final String newKey = this.oldFile.get(key).getSubsetCode()\r\n + this.oldFile.get(key).getConceptCode();\r\n this.oldFileNoMatch.put(newKey, this.oldFile.get(key));\r\n }\r\n }\r\n\r\n // Now repeat going the other way, pulling all new file no matches into\r\n // newFileNoMatch\r\n this.newFileNoMatch = new HashMap<String, SubsetElement>();\r\n iter = this.newFile.keySet().iterator();\r\n while (iter.hasNext()) {\r\n final String key = iter.next();\r\n if (!this.oldFile.containsKey(key)) {\r\n final String newKey = this.newFile.get(key).getSubsetCode()\r\n + this.newFile.get(key).getConceptCode();\r\n this.newFileNoMatch.put(newKey, this.newFile.get(key));\r\n }\r\n }\r\n\r\n // dump the initial large HashMaps to reclaim some memory\r\n this.oldFile = null;\r\n this.newFile = null;\r\n }", "private boolean compareFiles(String file1, String file2)\r\n throws IOException {\r\n \r\n BufferedReader reader1 = new BufferedReader(new FileReader(file1));\r\n BufferedReader reader2 = new BufferedReader(new FileReader(file2));\r\n \r\n\r\n String line1 = reader1.readLine();\r\n String line2 = reader2.readLine();\r\n\r\n boolean areEqual = true;\r\n\r\n int lineNum = 1;\r\n\r\n while (line1 != null || line2 != null) {\r\n if (line1 == null || line2 == null) {\r\n areEqual = false;\r\n break;\r\n }\r\n \r\n else if (!line1.equals(line2)) {\r\n areEqual = false;\r\n break;\r\n }\r\n\r\n line1 = reader1.readLine();\r\n line2 = reader2.readLine();\r\n\r\n lineNum++;\r\n }\r\n reader1.close();\r\n reader2.close();\r\n\r\n if (areEqual) { \r\n return true;\r\n }\r\n else { \r\n System.out.println(\r\n \"Two files have different content. They differ at line \"\r\n + lineNum);\r\n return false;\r\n }\r\n\r\n \r\n }", "@Test\n\tpublic void testSameLibDiffLocs() \n\t{\n\t\tString id = \"diffHomeLoc\";\n\t\tassertLCVol1NotLopped(id);\n\t\tassertLCVol2NotLopped(id);\n\t\tassertNoLoppedLC(id);\n\t}", "@Test\n public void testStoreFile() {\n\n File file1 = new File(\"file1\");\n File file2 = new File(\"file2\");\n parent.storeFile(file1);\n parent.storeFile(file2);\n ArrayList<File> output = parent.getStoredFiles();\n ArrayList<File> expected = new ArrayList<File>();\n expected.add(file1);\n expected.add(file2);\n assertEquals(output, expected);\n }", "public final void mo14831s() {\n Iterator it = ((ArrayList) mo14817d()).iterator();\n while (it.hasNext()) {\n File file = (File) it.next();\n if (file.listFiles() != null) {\n m6739b(file);\n long c = m6740c(file, false);\n if (((long) this.f6567b.mo14797a()) != c) {\n try {\n new File(new File(file, String.valueOf(c)), \"stale.tmp\").createNewFile();\n } catch (IOException unused) {\n f6563c.mo14884b(6, \"Could not write staleness marker.\", new Object[0]);\n }\n }\n for (File b : file.listFiles()) {\n m6739b(b);\n }\n }\n }\n }", "@Test\n\tpublic void testSameLibSameLocDiffScheme() \n\t{\n\t\tString id = \"diffScheme\";\n\t\tassertLCVol1NotLopped(id);\n\t\tassertNoLoppedLC(id);\n\t\tassertDeweyVol1NotLopped(id);\n\t\tassertNoLoppedDewey(id);\n\t}", "public void testCompare() throws Exception {\n\n Object testData[][] = {\n { \"aaa\", \"bbb\", -1 },\n { \"aaa\", \"aaa\", 0 },\n { \"bbb\", \"aaa\", 1 },\n { \"aaa\", \"aaa_L1_bbb.lsm\", -1 },\n { \"aaa_L1_bbb.lsm\", \"aaa_L1_bbb.lsm\", 0 },\n { \"aaa_L1_bbb.lsm\", \"aaa\", 1 },\n { \"aaa_L1_bbb.lsm\", \"aaa_L10_bbb.lsm\", -1 },\n { \"aaa_L10_bbb.lsm\", \"aaa_L1_bbb.lsm\", 1 },\n { \"aaa_La_bbb.lsm\", \"aaa_L1_bbb.lsm\", 1 },\n { \"aaa_L2_bbb.lsm\", \"aaa_L10_bbb.lsm\", -1 }\n };\n\n LNumberComparator comparator = new LNumberComparator();\n\n for (Object[] testRow : testData) {\n String name1 = (String) testRow[0];\n String name2 = (String) testRow[1];\n File file1 = new File(name1);\n File file2 = new File(name2);\n int expectedResult = (Integer) testRow[2];\n int actualResult = comparator.compare(new FileTarget(file1),\n new FileTarget(file2));\n\n boolean isValid = ((expectedResult > 0) && (actualResult > 0)) ||\n ((expectedResult < 0) && (actualResult < 0)) ||\n ((expectedResult == 0) && (actualResult == 0));\n\n assertTrue(name1 + \" compared to \" + name2 +\n \" returned invalid result of \" + actualResult +\n \" (should have same sign as \" + expectedResult + \")\",\n isValid);\n }\n\n }", "private void assertCompareTwoXML(String path1, String path2){\n\t\tFile f1 = new File(path1);\n\t\tFile f2 = new File(path2);\n\t\tassertTrue(\"Le fichier \"+path1+\" n'existe pas.\",f1.exists());\n\t\tassertTrue(\"Le fichier \"+path2+\" n'existe pas.\",f2.exists());\n\t\t\n\t\ttry {\n\t\t\tDocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();\n\t\t\tDocumentBuilder builder = factory.newDocumentBuilder();\n\t\t\tDocument doc1 = builder.parse(f1);\n\t\t\t\n\t\t\tDocumentBuilderFactory factory2 = DocumentBuilderFactory.newInstance();\n\t\t\tDocumentBuilder builder2 = factory2.newDocumentBuilder();\n\t\t\tDocument doc2 = builder2.parse(f2);\n\n\t\t\tElement root1 = doc1.getDocumentElement(); //<tds> </tds>\n\t\t\tElement root2 = doc2.getDocumentElement();\n\t\t\t\n\t\t\t//Checking symboles\n\t\t\tNodeList symbs1 = root1.getElementsByTagName(\"sym\"); //Getting all <function>\n\t\t\tNodeList symbs2 = root2.getElementsByTagName(\"sym\"); //Getting all <function>\n\t\t\tUtilitaire.assertT(\"Les fichiers n'ont pas le meme nombre de symboles\",symbs1.getLength() == symbs2.getLength());\n\t\t\t\n\t\t\tfor(int symbIndex=0; symbIndex < symbs1.getLength();symbIndex++){\n\t\t\t\tboolean sameSymb = false;\n\t\t\t\tString sym1 = ((Element) symbs1.item(symbIndex)).getTextContent();\n\t\t\t\tfor(int symbIndex2=0; symbIndex2 < symbs2.getLength();symbIndex2++){\n\t\t\t\t\tString sym2 = ((Element) symbs2.item(symbIndex2)).getTextContent();\n\t\t\t\t\tif(sym1.equals(sym2)) sameSymb = true;\n\t\t\t\t}\n\t\t\t\tUtilitaire.assertT(\"Les symboles ne sont pas les memes.\",sameSymb);\n\t\t\t}\n\t\t\t\n\t\t\t//Checking functions\n\t\t\tNodeList functions1 = root1.getElementsByTagName(\"function\"); //Getting all <function>\n\t\t\tNodeList functions2 = root2.getElementsByTagName(\"function\"); //Getting all <function>\n\t\t\tUtilitaire.assertT(\"Les fichiers n'ont pas le meme nombre de fonctions\",functions1.getLength() == functions2.getLength());\n\t\t\t\t//Checking each function\n\t\t\tfor(int tmp = 0; tmp < functions1.getLength();tmp++){\n\t\t\t\tNode node1 = functions1.item(tmp);\n\t\t\t\tNode node2 = null;\n\t\t\t\t//Checking function name\n\t\t\t\tString funName1 = ((Element) node1).getElementsByTagName(\"name\").item(0).getTextContent();\n\t\t\t\tString funName2 = null;\n\t\t\t\tboolean sameFunName = false;\n\t\t\t\t//Iterate over the second file to find (eventually) the same function node\n\t\t\t\tfor(int tmp2 = 0; (tmp2 < functions2.getLength()) && !sameFunName ;tmp2++){\n\t\t\t\t\tnode2 = functions2.item(tmp2);\n\t\t\t\t\tfunName2 = ((Element) node2).getElementsByTagName(\"name\").item(0).getTextContent();\n\t\t\t\t\tif(funName1.equals(funName2)) sameFunName = true;\n\t\t\t\t\t//If a same node if found, the following tests will be with node1's function = node2's function\n\t\t\t\t}\n\t\t\t\t//If there is no node with the same function name -> fail\n\t\t\t\tassertTrue(\"Deux fonctions n'ont pas le meme nom : \"+funName1, sameFunName);\n\t\t\t\t\n\t\t\t\tNodeList vars1 = ((Element) node1).getElementsByTagName(\"var\"); //Getting <var>\n\t\t\t\tNodeList vars2 = ((Element) node2).getElementsByTagName(\"var\");\n\t\t\t\tUtilitaire.assertT(\"Il n'y a pas le meme nombre de variables pour la fonction \"+funName1,vars1.getLength() == vars2.getLength());\n\t\t\t\tfor(int varIndex = 0; varIndex < vars1.getLength();varIndex++){\n\t\t\t\t\tboolean sameVarsName = false;\n\t\t\t\t\tNode varNode1 = vars1.item(varIndex);\n\t\t\t\t\t//Checking vars name\n\t\t\t\t\tString varName1 = ((Element) varNode1).getElementsByTagName(\"vname\").item(0).getTextContent(); //Writing vars names\n\t\t\t\t\t//Iterate through the vars of the second file to see if there is a same as varName1\n\t\t\t\t\tfor(int varIndex2 = 0; varIndex2 < vars2.getLength();varIndex2++){\n\t\t\t\t\t\tString varName2 = ((Element) vars2.item(varIndex2)).getElementsByTagName(\"vname\").item(0).getTextContent(); //Writing vars names\n\t\t\t\t\t\tif(varName1.equals(varName2)) sameVarsName = true;\n\t\t\t\t\t}\n\t\t\t\t\tUtilitaire.assertT(\"Les variables n'ont pas le meme nom : \"+varName1, sameVarsName);\n\t\t\t\t\t//Checking vars value\n\t\t\t\t\tboolean sameVarsValue = false;\n\t\t\t\t\t//Iterate through the vars of the second file to see if there is a same as varValue1\n\t\t\t\t\tString varValue1 = ((Element) varNode1).getElementsByTagName(\"value\").item(0).getTextContent(); //Writing vars names\n\t\t\t\t\tfor(int varIndex2 = 0; varIndex2 < vars2.getLength();varIndex2++){\n\t\t\t\t\t\tString varValue2 = ((Element) vars2.item(varIndex2)).getElementsByTagName(\"value\").item(0).getTextContent(); //Writing vars names\n\t\t\t\t\t\tif(varValue1.equals(varValue2)) sameVarsValue = true;\n\t\t\t\t\t}\n\t\t\t\t\tUtilitaire.assertT(\"Les variables n'ont pas les mÍmes valeurs : \"+varValue1, sameVarsValue);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t//Checking calls\n\t\t\t\tNodeList calls1 = ((Element) node1).getElementsByTagName(\"f\");\n\t\t\t\tNodeList calls2 = ((Element) node2).getElementsByTagName(\"f\");\n\t\t\t\tUtilitaire.assertT(\"Le nombre d'appels de fonctions ne sont pas les memes.\",calls1.getLength() == calls2.getLength());\n\t\t\t\t\n\t\t\t\tfor(int callIndex = 0; callIndex < calls1.getLength(); callIndex++){\n\t\t\t\t\tboolean sameCalls = false;\n\t\t\t\t\tString callValue1 = ((Element) calls1.item(callIndex)).getTextContent();\n\t\t\t\t\t//Iterate through the calls of the second file to see if there is a same as callValue1\n\t\t\t\t\tfor(int callIndex2 = 0; callIndex2 < calls2.getLength(); callIndex2++){\n\t\t\t\t\t\tString callValue2 = ((Element) calls2.item(callIndex2)).getTextContent();\n\t\t\t\t\t\tif(callValue1.equals(callValue2)) sameCalls = true;\n\t\t\t\t\t}\n\t\t\t\t\tUtilitaire.assertT(\"Les functions appellees ne sont pas les memes : \"+callValue1, sameCalls);\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t} catch (ParserConfigurationException e) {\n\t\t\te.printStackTrace();\n\t\t} catch (FileNotFoundException e) {\n\t\t\te.printStackTrace();\n\t\t} catch (SAXException e) {\n\t\t\te.printStackTrace();\n\t\t} catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t}", "public static synchronized void initializeApacheCompareTestArchiveFiles() {\n System.out.println(Thread.currentThread().getName() + \"********************************************************* TestHelper.initializeApacheCompareTestArchiveFiles\");\n\n File oneaSourceFile = new File(System.getProperty(USER_DIR) + File.separator + \"CompareTest1a.uyu\");\n File onebSourceFile = new File(System.getProperty(USER_DIR) + File.separator + \"CompareTest1b.uyu\");\n\n File twoaSourceFile = new File(System.getProperty(USER_DIR) + File.separator + \"CompareTest2a.uyu\");\n File twobSourceFile = new File(System.getProperty(USER_DIR) + File.separator + \"CompareTest2b.uyu\");\n\n File threeaSourceFile = new File(System.getProperty(USER_DIR) + File.separator + \"CompareTest3a.uyu\");\n File threebSourceFile = new File(System.getProperty(USER_DIR) + File.separator + \"CompareTest3b.uyu\");\n\n File fouraSourceFile = new File(System.getProperty(USER_DIR) + File.separator + \"CompareTest4a.uyu\");\n File fourbSourceFile = new File(System.getProperty(USER_DIR) + File.separator + \"CompareTest4b.uyu\");\n\n File fiveaSourceFile = new File(System.getProperty(USER_DIR) + File.separator + \"CompareTest5a.uyu\");\n File fivebSourceFile = new File(System.getProperty(USER_DIR) + File.separator + \"CompareTest5b.uyu\");\n\n File sixaSourceFile = new File(System.getProperty(USER_DIR) + File.separator + \"CompareTest6a.uyu\");\n File sixbSourceFile = new File(System.getProperty(USER_DIR) + File.separator + \"CompareTest6b.uyu\");\n\n File sevenaSourceFile = new File(System.getProperty(USER_DIR) + File.separator + \"CompareTest7a.uyu\");\n File sevenbSourceFile = new File(System.getProperty(USER_DIR) + File.separator + \"CompareTest7b.uyu\");\n\n File eightaSourceFile = new File(System.getProperty(USER_DIR) + File.separator + \"CompareTest8a.uyu\");\n File eightbSourceFile = new File(System.getProperty(USER_DIR) + File.separator + \"CompareTest8b.uyu\");\n\n File nineaSourceFile = new File(System.getProperty(USER_DIR) + File.separator + \"CompareTest9a.uyu\");\n File ninebSourceFile = new File(System.getProperty(USER_DIR) + File.separator + \"CompareTest9b.uyu\");\n\n File tenaSourceFile = new File(System.getProperty(USER_DIR) + File.separator + \"CompareTest10a.uyu\");\n File tenbSourceFile = new File(System.getProperty(USER_DIR) + File.separator + \"CompareTest10b.uyu\");\n\n File twelveaSourceFile = new File(System.getProperty(USER_DIR) + File.separator + \"CompareTest12a.uyu\");\n File twelvebSourceFile = new File(System.getProperty(USER_DIR) + File.separator + \"CompareTest12b.uyu\");\n\n String destinationDirName = System.getProperty(USER_DIR)\n + File.separator\n + QVCSConstants.QVCS_PROJECTS_DIRECTORY\n + File.separator\n + getTestProjectName();\n\n File firstDestinationDirectory = new File(destinationDirName);\n firstDestinationDirectory.mkdirs();\n\n File oneaDestinationFile = new File(destinationDirName + File.separator + \"CompareTest1a.uyu\");\n File onebDestinationFile = new File(destinationDirName + File.separator + \"CompareTest1b.uyu\");\n\n File twoaDestinationFile = new File(destinationDirName + File.separator + \"CompareTest2a.uyu\");\n File twobDestinationFile = new File(destinationDirName + File.separator + \"CompareTest2b.uyu\");\n\n File threeaDestinationFile = new File(destinationDirName + File.separator + \"CompareTest3a.uyu\");\n File threebDestinationFile = new File(destinationDirName + File.separator + \"CompareTest3b.uyu\");\n\n File fouraDestinationFile = new File(destinationDirName + File.separator + \"CompareTest4a.uyu\");\n File fourbDestinationFile = new File(destinationDirName + File.separator + \"CompareTest4b.uyu\");\n\n File fiveaDestinationFile = new File(destinationDirName + File.separator + \"CompareTest5a.uyu\");\n File fivebDestinationFile = new File(destinationDirName + File.separator + \"CompareTest5b.uyu\");\n\n File sixaDestinationFile = new File(destinationDirName + File.separator + \"CompareTest6a.uyu\");\n File sixbDestinationFile = new File(destinationDirName + File.separator + \"CompareTest6b.uyu\");\n\n File sevenaDestinationFile = new File(destinationDirName + File.separator + \"CompareTest7a.uyu\");\n File sevenbDestinationFile = new File(destinationDirName + File.separator + \"CompareTest7b.uyu\");\n\n File eightaDestinationFile = new File(destinationDirName + File.separator + \"CompareTest8a.uyu\");\n File eightbDestinationFile = new File(destinationDirName + File.separator + \"CompareTest8b.uyu\");\n\n File nineaDestinationFile = new File(destinationDirName + File.separator + \"CompareTest9a.uyu\");\n File ninebDestinationFile = new File(destinationDirName + File.separator + \"CompareTest9b.uyu\");\n\n File tenaDestinationFile = new File(destinationDirName + File.separator + \"CompareTest10a.uyu\");\n File tenbDestinationFile = new File(destinationDirName + File.separator + \"CompareTest10b.uyu\");\n\n File twelveaDestinationFile = new File(destinationDirName + File.separator + \"CompareTest12a.uyu\");\n File twelvebDestinationFile = new File(destinationDirName + File.separator + \"CompareTest12b.uyu\");\n\n try {\n ServerUtility.copyFile(oneaSourceFile, oneaDestinationFile);\n ServerUtility.copyFile(onebSourceFile, onebDestinationFile);\n\n ServerUtility.copyFile(twoaSourceFile, twoaDestinationFile);\n ServerUtility.copyFile(twobSourceFile, twobDestinationFile);\n\n ServerUtility.copyFile(threeaSourceFile, threeaDestinationFile);\n ServerUtility.copyFile(threebSourceFile, threebDestinationFile);\n\n ServerUtility.copyFile(fouraSourceFile, fouraDestinationFile);\n ServerUtility.copyFile(fourbSourceFile, fourbDestinationFile);\n\n ServerUtility.copyFile(fiveaSourceFile, fiveaDestinationFile);\n ServerUtility.copyFile(fivebSourceFile, fivebDestinationFile);\n\n ServerUtility.copyFile(sixaSourceFile, sixaDestinationFile);\n ServerUtility.copyFile(sixbSourceFile, sixbDestinationFile);\n\n ServerUtility.copyFile(sevenaSourceFile, sevenaDestinationFile);\n ServerUtility.copyFile(sevenbSourceFile, sevenbDestinationFile);\n\n ServerUtility.copyFile(eightaSourceFile, eightaDestinationFile);\n ServerUtility.copyFile(eightbSourceFile, eightbDestinationFile);\n\n ServerUtility.copyFile(nineaSourceFile, nineaDestinationFile);\n ServerUtility.copyFile(ninebSourceFile, ninebDestinationFile);\n\n ServerUtility.copyFile(tenaSourceFile, tenaDestinationFile);\n ServerUtility.copyFile(tenbSourceFile, tenbDestinationFile);\n\n ServerUtility.copyFile(twelveaSourceFile, twelveaDestinationFile);\n ServerUtility.copyFile(twelvebSourceFile, twelvebDestinationFile);\n\n } catch (IOException ex) {\n Logger.getLogger(TestHelper.class.getName()).log(Level.SEVERE, null, ex);\n }\n }", "@Test\r\n public void testGetChangedFileList() throws IOException {\n helper.exportRevChangedFiles(PJ_ROOT, 1, LOCAL_ROOT);\r\n helper.exportRevChangedFiles(PJ_ROOT, 4, LOCAL_ROOT);\r\n //helper.exportRevChangedFiles(PJ_ROOT, -1, LOCAL_ROOT);\r\n //helper.exportRevChangedFiles(9, 9, true);\r\n }", "@Test\n\tpublic void keepYoungestFirst() throws IOException {\n\t\tZonedDateTime now = ZonedDateTime.now();\n\n\t\tFile firstFile = File.createTempFile(\"junit\", null);\n\t\tFile secondFile = File.createTempFile(\"junit\", null);\n\t\tfirstFile.setLastModified(now.toEpochSecond());\n\t\tsecondFile.setLastModified(now.minus(1, ChronoUnit.DAYS).toEpochSecond());\n\n\t\tFileTuple firstTuple = new FileTuple(firstFile, firstFile);\n\t\tFileTuple secondTuple = new FileTuple(secondFile, secondFile);\n\n\t\tassertThat(COMPARATOR.compare(firstTuple, secondTuple)).isNegative();\n\n\t}", "private void checkFileContents(String name) throws IOException {\n byte[] buff = \"some bytes\".getBytes();\n assertTrue(Arrays.equals(buff, readFile(name, buff.length)));\n }", "public void mo83570c() {\n File[] listFiles;\n File file = new File(this.f60297d);\n if (file.isDirectory() && (listFiles = file.listFiles()) != null && listFiles.length >= this.f60294a) {\n Arrays.sort(listFiles, this.f60295b);\n for (int i = 0; i < listFiles.length && listFiles.length >= this.f60294a; i++) {\n File file2 = listFiles[i];\n if (!this.f60299f.contains(file2)) {\n ArgusLogger.m85574b(String.format(C6969H.m41409d(\"G4D8AC619BE22AF20E809D047FEE1C6C47DC3D008AD3FB969E71DD05BE6EAD1D26DC3D008AD3FB969EA079D41E6A5D1D26880DD1FBB70E36CF547\"), file2.getPath()));\n mo83569b(Collections.singleton(file2));\n }\n }\n }\n }", "@Test\n\tpublic void testDiffLibs() \n\t{\n\t\tString id = \"diffLib\";\n\t\tassertLCVol1NotLopped(id);\n\t\tassertLCVol2NotLopped(id);\n\t\tassertNoLoppedLC(id);\n\t}", "@Test\n public void testStoreFileAlphabetical() {\n\n File file1 = new File(\"c\");\n File file2 = new File(\"b\");\n File file3 = new File(\"a\");\n parent.storeFile(file1);\n parent.storeFile(file2);\n parent.storeFile(file3);\n ArrayList<File> output = parent.getStoredFiles();\n ArrayList<File> expected = new ArrayList<File>();\n expected.add(file3);\n expected.add(file2);\n expected.add(file1);\n assertEquals(output, expected);\n }", "@Test\n @Ignore\n public void testFileTimestampChangeForManualTest() {\n \t// prepare test folder\n \tFile srcFolder = new File(\"C:\\\\bitlocker\\\\job_test\");\n \tFile targetFolder = new File(\"C:\\\\bitlocker\\\\job\");\n \ttry {\n \t\tif (targetFolder.exists()) FileUtils.cleanDirectory(targetFolder);\n\t\t\tFileUtils.copyDirectory(srcFolder, targetFolder);\n\t\t} catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t}\n \tassertThat(targetFolder.exists(), is(true));\n \t\n \tint retentionDays = findAssetRetentionDays(META_INBOUNDFILE);\n \tassertThat(retentionDays, is(14));\n \t\n \t// change last modified date for testing files\n Date testingFileDate = getRetentionDate(retentionDays+1);\t// 1 day older\n for (File file: targetFolder.listFiles()) {\n \tfile.setLastModified(testingFileDate.getTime()); // update date\n }\n }", "@Test\n\tpublic void testGenerateCodeAndOverwriteFormattedButUnchangedFile() throws IOException {\n\t\tFile tmpFile = File.createTempFile(\"junit\", \".tmp\");\n\t\ttmpFile.deleteOnExit();\n\n\t\tFile tmpDir = new File(tmpFile.getParentFile(), UUID.randomUUID().toString());\n\t\ttry {\n\t\t\tString filename = \"sample.xml\";\n\t\t\tFile realDir = new File(tmpDir, \"real\");\n\t\t\tFile targetDir = new File(tmpDir, \"target\");\n\t\t\tFile realFile = new File(realDir, filename);\n\n\t\t\t// generate sample1\n\t\t\tcodeGenerator.generateCode(CodeOverwritePolicy.OVERWRITE_IF_UNCHANGED, new HashMap<String, Object>(),\n\t\t\t\t\trealDir, targetDir, \"sample1.vm\", filename);\n\n\t\t\t// assert that sample1 was written\n\t\t\tAssert.assertTrue(FileUtils.readFileToString(realFile).contains(\"This is sample1\"),\n\t\t\t\t\t\"Sample 1 was not written successfully, expected text not found in the written file\");\n\n\t\t\tlong creationTime = realFile.lastModified();\n\n\t\t\tcodeGenerator.generateCode(CodeOverwritePolicy.OVERWRITE_IF_UNCHANGED, new HashMap<String, Object>(),\n\t\t\t\t\trealDir, targetDir, \"sample1-formatted.vm\", filename);\n\n\t\t\tlong lastModified = realFile.lastModified();\n\n\t\t\t// assert that sample1 was not written\n\t\t\tAssert.assertTrue(lastModified == creationTime,\n\t\t\t\t\t\"File should not have been changed because only formatting changed\");\n\t\t} finally {\n\t\t\tFileUtils.deleteDirectory(tmpDir);\n\t\t}\n\t}", "@Test\n public void loadFromFileWithWrongConnects() throws Exception{\n fileInOut.setFilePath(\"src/wrongConnects\");\n fileInOut.loadFromFile();\n }", "protected boolean sameFile(URL paramURL1, URL paramURL2) {\n/* 400 */ if (paramURL1.getProtocol() != paramURL2.getProtocol() && (paramURL1\n/* 401 */ .getProtocol() == null || \n/* 402 */ !paramURL1.getProtocol().equalsIgnoreCase(paramURL2.getProtocol()))) {\n/* 403 */ return false;\n/* */ }\n/* */ \n/* 406 */ if (paramURL1.getFile() != paramURL2.getFile() && (paramURL1\n/* 407 */ .getFile() == null || !paramURL1.getFile().equals(paramURL2.getFile()))) {\n/* 408 */ return false;\n/* */ }\n/* */ \n/* */ \n/* 412 */ int i = (paramURL1.getPort() != -1) ? paramURL1.getPort() : paramURL1.handler.getDefaultPort();\n/* 413 */ int j = (paramURL2.getPort() != -1) ? paramURL2.getPort() : paramURL2.handler.getDefaultPort();\n/* 414 */ if (i != j) {\n/* 415 */ return false;\n/* */ }\n/* */ \n/* 418 */ if (!hostsEqual(paramURL1, paramURL2)) {\n/* 419 */ return false;\n/* */ }\n/* 421 */ return true;\n/* */ }", "public static void verifyFileContentsSame(String stream, @Nullable File actual, @Nullable File expected)\n throws IOException {\n LinkedList<String> actualLines =\n actual == null ? new LinkedList<String>() : readFileIntoLines(actual);\n LinkedList<String> expectedLines =\n expected == null ? new LinkedList<String>() : readFileIntoLines(expected);\n for (int lineNum = 1;; lineNum++) {\n String actualLine = actualLines.poll();\n String expectedLine = expectedLines.poll();\n if ((actualLine == null) && (expectedLine == null)) {\n break;\n }\n assertEquals(stream + \" line \" + lineNum + \" differs\", actualLine, expectedLine);\n }\n }", "public static boolean compareFilesChecksum(String path1, String path2) {\n \t\tfinal String checksum1 = getMD5Checksum(path1);\n \t\tfinal String checksum2 = getMD5Checksum(path2);\n \t\t\n \t\tif (!TextUtils.isEmpty(checksum1) && !TextUtils.isEmpty(checksum2)) {\n \t\t\treturn checksum1.equals(checksum2);\n \t\t}\n \t\t\n \t\treturn false;\n \t}", "@Test\n\tpublic void testIsConsistentModifiedFileSave() throws Exception {\n\t\tIRodinFile rodinFile = createRodinFile(\"P/x.test\");\n\t\tRodinTestRoot root = (RodinTestRoot) rodinFile.getRoot();\n\t\tcreateNEPositive(root, \"foo\", null);\n\t\trodinFile.save(null, false);\n\t\tassertTrue(\"saved file should be consistent\", \n\t\t\t\trodinFile.isConsistent());\n\t}", "private static void task45() {\n String path1, path2;\n path1 = \"d:\\\\common\\\\java\\\\w3resource\\\\src\\\\basicPart1\\\\test.txt\";\n path2 = \"d:\\\\common\\\\java\\\\w3resource\\\\src\\\\basicPart1\\\\test-text.txt\";\n File file = new File(\"test.txt\");\n\n File file2 = new File(\"d:\\\\common\\\\java\\\\w3resource\\\\src\\\\basicPart1\\\\test-text.txt\");\n long size1 = file.length();\n long size2 = file2.length();\n\n System.out.println(\"d:\\\\common\\\\java\\\\w3resource\\\\src\\\\basicPart1\\\\test.txt \" + size1 + \" bites\");\n System.out.println(\"d:\\\\common\\\\java\\\\w3resource\\\\src\\\\basicPart1\\\\test-text.txt \" + size2 + \" bites\");\n }", "@Test\n public void testDiff() throws Exception {\n String newVersionJarPath = \"data/sample/jar/change4.jar\";\n String oldVersionJarPath = \"data/sample/jar/change3.jar\";\n String changePath = \"data/sample/changes_change4_change3.txt\";\n\n// RelationInfo relationInfoForChangedPart = new RelationInfo(newVersionCodePath, oldVersionCodePath, changePath, false);\n// RelationInfo relationInfoForChangedPart = new RelationInfo(newVersionJarPath, oldVersionJarPath, changePath, false);\n// CallRelationGraph callGraphForChangedPart = new CallRelationGraph(relationInfoForChangedPart);\n//\n// double thresholdForInitialRegion = 0.35;\n// RelationInfo oldRelationInfo = new RelationInfo(newVersionJarPath,false);\n// oldRelationInfo.setPruning(thresholdForInitialRegion);\n// RelationInfo newRelationInfo = new RelationInfo(oldVersionJarPath,false);\n// newRelationInfo.setPruning(thresholdForInitialRegion);\n//\n// CallRelationGraph oldCallGraph = new CallRelationGraph(oldRelationInfo);\n// CallRelationGraph newCallGraph = new CallRelationGraph(newRelationInfo);\n//\n// ChangedArtifacts changedArtifacts = new ChangedArtifacts();\n// changedArtifacts.parse(changePath);\n//\n// InitialRegionFetcher fetcher = new InitialRegionFetcher(changedArtifacts, newCallGraph, oldCallGraph);\n//\n// ExportInitialRegion exporter = new ExportInitialRegion(fetcher.getChangeRegion());\n\n }", "public void testCleanFile() {\n shouldCleanFile(\"jasmine1/jasmineTestBefore.js\");\n\n // Given a jasmine file with a fdescribe() and an fit().\n shouldCleanFile(\"jasmine2/jasmineTestBefore.js\");\n }", "@Test(timeout = 4000)\n public void test02() throws Throwable {\n FileUtil fileUtil0 = new FileUtil();\n fileUtil0.downloadKeywordSearchFile(\"9\", \"9\", \"9\", \"9\");\n String string0 = \"\";\n fileUtil0.downloadBlendedSearchFile(\"\", \"9\");\n fileUtil0.isAgeGood((File) null);\n fileUtil0.fetchThirdPartySearchFile(\"9\", \"9\", \"9\", \"9\");\n String string1 = \"^m1KLI\\\\nb8]!B*(2\";\n String string2 = null;\n fileUtil0.downloadBrowseNodeFile(\"^m1KLI\\nb8]!B*(2\", \"9\", (String) null, \"<X;R[f!MO\");\n String string3 = \"-tT-6\";\n fileUtil0.fetchThirdPartySearchFile(\"^m1KLI\\nb8]!B*(2\", \"^m1KLI\\nb8]!B*(2\", \"^m1KLI\\nb8]!B*(2\", \"-tT-6\");\n ArrayList<Object> arrayList0 = new ArrayList<Object>();\n Object object0 = new Object();\n Object object1 = new Object();\n arrayList0.add(object1);\n arrayList0.add(object0);\n fileUtil0.downloadAccessoriesFile(\"9\", arrayList0, \"\");\n String string4 = \"associateID\";\n String string5 = null;\n // Undeclared exception!\n try { \n fileUtil0.renameFile(\"associateID\", (String) null);\n fail(\"Expecting exception: NullPointerException\");\n \n } catch(NullPointerException e) {\n //\n // no message in exception (getMessage() returned null)\n //\n verifyException(\"java.io.File\", e);\n }\n }", "@Test\n\tpublic void testIsConsistentModifiedFileRevert() throws Exception {\n\t\tIRodinFile rodinFile = createRodinFile(\"P/x.test\");\n\t\tRodinTestRoot root = (RodinTestRoot) rodinFile.getRoot();\n\t\tcreateNEPositive(root, \"foo\", null);\n\t\trodinFile.makeConsistent(null);\n\t\tassertTrue(\"reverted file should be consistent\", \n\t\t\t\trodinFile.isConsistent());\n\t}", "@SuppressWarnings(\"unused\") \n public void testBigFile() {\n URL resource = getResource(\"/junit-stats.xml\"); // a big file\n String folder = \"\\\\\\\\dev1\\\\c$\\\\tcs_build\\\\archive\";\n long originalLastModified = getOrginalFileLastModified(resource);\n HistoricalTestStatisticsFileManager manager = new HistoricalTestStatisticsFileManager(folder, resource.getFile(), Long.MAX_VALUE);\n verifyRevisionsLoaded(manager, 65);\n verifyRevisionListSize(manager, 65);\n List<String> orginalRevisionList = manager.getRevisionList();\n manager.run();\n assertEquals(\"you didn't clone the list correctly\", 65, orginalRevisionList.size());\n List<String> updatedRevisionList = manager.getRevisionList();\n File updatedFile = new File(resource.getFile());\n assertTrue(\"failed to update the file\", updatedFile.lastModified() != originalLastModified); \n }", "private static void assertEqual(List<byte[]> actual, List<byte[]> expected) {\n if (actual.size() != expected.size()) {\n throw new AssertionError(String.format(\"Different amount of chunks, expected %d actual %d\", expected.size(), actual.size()));\n }\n for (int i = 0; i < actual.size(); i++) {\n byte[] act = actual.get(i);\n byte[] exp = expected.get(i);\n if (act.length != exp.length) {\n throw new AssertionError(String.format(\"Chunks #%d differed in length, expected %d actual %d\", i, exp.length, act.length));\n }\n for (int j = 0; j < act.length; j++) {\n if (act[j] != exp[j]) {\n throw new AssertionError(String.format(\"Chunks #%d differed at index %d, expected %d actual %d\", i, j, exp[j], act[j]));\n }\n }\n }\n }", "@Test\n @Ignore\n\tpublic void compareCPPFiles() throws IOException \n\t{\n\t\tFile javaDir = new File(\"bigTest/java\");\n\t\tFile cppDir = new File(\"bigTest/cpp\");\n\n\t\tjavaDir.mkdirs();\n\t\tcppDir.mkdirs();\n\n\t\tint nCpp = 0;\n\t\tfor (File f : cppDir.listFiles())\n\t\t\tif (f.isFile() && GeoTessModel.isGeoTessModel(f))\n\t\t\t\t++nCpp;\n\n\t\tArrayList<String> files = new ArrayList<String>(100);\n\n\t\tfor (File javaFile : javaDir.listFiles())\n\t\t\tif (javaFile.isFile() && GeoTessModel.isGeoTessModel(javaFile))\n\t\t\t\tfiles.add(javaFile.getCanonicalPath());\n\n\t\tCollections.sort(files);\n\n\t\tint nCompared = 0;\n\n\t\tfor (String s : files)\n\t\t{\n\t\t\tFile javaFile = new File(s);\n\t\t\tFile cppFile = new File(cppDir, javaFile.getName());\n\t\t\t\n\t\t\t//System.out.println(javaFile.getCanonicalPath());\n\t\t\t\n\t\t\tif (cppFile.exists())\n\t\t\t{\n\t\t\t\tGeoTessModel javamodel = new GeoTessModel(javaFile, \"../../resources/permanent_files/\",\n\t\t\t\t\t\tOptimizationType.MEMORY);\n\n\t\t\t\tGeoTessModel cppmodel = new GeoTessModel(cppFile, \"../../resources/permanent_files/\",\n\t\t\t\t\t\tOptimizationType.MEMORY);\n\n\t\t\t\tboolean eq = javamodel.equals(cppmodel);\n\n\t\t\t\t//System.out.printf(\"Comparing files %s and %s%n\", javaFile.getCanonicalFile(), cppFile.getCanonicalPath());\n\n\t\t\t\tif (!eq)\n\t\t\t\t\tSystem.out.printf(\"File %s are not equal%n\", s);\n\n\t\t\t\tassertTrue(eq);\n\n\t\t\t\t++nCompared;\n\t\t\t}\n\n\t\t}\n\n//\t\tSystem.out.printf(\" compareCPPFiles(): Njava=%d Ncpp=%d Ncomparisons=%d%n\", \n//\t\t\t\tfiles.size(), nCpp, nCompared);\n\t}", "@Test(timeout = 4000)\n public void test04() throws Throwable {\n EvoSuiteFile evoSuiteFile0 = new EvoSuiteFile(\"/S_[.XML\");\n FileSystemHandling.appendStringToFile(evoSuiteFile0, \"\\\",\");\n FileUtil fileUtil0 = new FileUtil();\n File file0 = fileUtil0.getSimilarItems(\"[\", \"\");\n assertEquals(2L, file0.length());\n assertNotNull(file0);\n }", "public static void assertFiles(File refrFile, File testFile)\n throws IOException {\n\n /* Both files must exist */\n assertTrue(\"Reference file \" + refrFile, refrFile.exists());\n assertTrue(\"Tested file \" + testFile, refrFile.exists());\n /* Test streams */\n assertStreams(new FileInputStream(refrFile), new FileInputStream(testFile));\n }", "public void testBug72337() {\n IWorkspace workspace = ResourcesPlugin.getWorkspace();\n IPath path = new Path(\"/foo/bar.txt\");\n IFile fileA = workspace.getRoot().getFile(path);\n FileEditorInput inputA1 = new FileEditorInput(fileA);\n OtherFileEditorInput inputA2 = new OtherFileEditorInput(fileA);\n assertTrue(inputA1.equals(inputA2));\n assertTrue(inputA2.equals(inputA1));\n }", "private void checkFileNames(DSpaceRunnable dSpaceRunnable, List<MultipartFile> files) {\n List<String> fileNames = new LinkedList<>();\n for (MultipartFile file : files) {\n String fileName = file.getOriginalFilename();\n if (fileNames.contains(fileName)) {\n throw new UnprocessableEntityException(\"There are two files with the same name: \" + fileName);\n } else {\n fileNames.add(fileName);\n }\n }\n\n List<String> fileNamesFromOptions = dSpaceRunnable.getFileNamesFromInputStreamOptions();\n if (!fileNames.containsAll(fileNamesFromOptions)) {\n throw new UnprocessableEntityException(\"Files given in properties aren't all present in the request\");\n }\n }", "public void compDirFiles(String dir1,String dir2) throws Exception{\n\t\tFile file1=new File(dir1);\n\t\tFile file2=new File(dir2);\n\t\tif(!file1.isDirectory()){\n\t\t\tSystem.out.println(dir1+\" is not a directory!\");\n\t\t\tSystem.exit(-1);\n\t\t}\n\t\tif(!file2.isDirectory()){\n\t\t\tSystem.out.println(dir2+\" is not a directory!\");\n\t\t\tSystem.exit(-1);\n\t\t}\n\n\t\tHashMap map=compare(file1,file2);\n\t\tmap.put(\"templateFtl\", \"fileList.html.ftl\");\n\t\tint noExistsFiles=((HashMap)map.get(\"noExistsMap\")).keySet().size();\n\t\tint noEqualFiles=((HashMap)map.get(\"diffMap\")).keySet().size();\n\t\tSystem.out.println(noExistsFiles);\n\t\tSystem.out.println(noEqualFiles);\n\t\tif(((HashMap)map.get(\"noExistsMap\")).keySet().size()==0){\n\t\t\tSystem.out.println(\"测试文件夹所有文件都在生成文件夹中存在!\");\n\t//\t\tSystem.exit(0);\n\t\t}\n\t\tSystem.out.println(\"测试文件夹中以下文件在生成文件夹中不存在!\");\n\t\t\n\t\tHashMap diffMap=(HashMap)map.get(\"diffMap\");\n\t\tIterator diffIter=diffMap.keySet().iterator();\n\t\twhile(diffIter.hasNext()){\n\t\t\tString fileName=(String)diffIter.next();\n\t\t\tString fileName2=dir2+fileName.substring(dir1.length());\n\t\t\t\n\t\t\t\n\t\t\tFileDiff.getDiffResultFile(fileName, fileName2);\n\t\t}\n \tHtmlFileReport.printResultHtml(map);\n \t\n \t\n\t}", "@Test\n public void testFileInDirectoryFileDoesNotExists() {\n\n assertFalse(parent.fileInDirectory(\"file1\"));\n }", "@Test\n public void testCompareTest8b() {\n helperMethodb(\"CompareTest8a.txt\", \"CompareTest8b.txt\");\n }", "@Test\n public void checkIfFileHasBeenRenamedOrNot(){\n boolean actual = rename.renameFile(\"jazz\",\"tomsmith\");\n assertTrue(actual);\n }", "@Test\n\tpublic void testIsConsistentFileNoOpen() throws Exception {\n\t\tIRodinFile rodinFile = createRodinFile(\"P/x.test\");\n\t\trodinFile.close();\n\t\tassertTrue(\"closed file should be consistent\", \n\t\t\t\trodinFile.isConsistent());\n\t\tassertFalse(\"file should not be open\", rodinFile.isOpen());\n\t}", "@Test(timeout = 4000)\n public void test01() throws Throwable {\n FileUtil fileUtil0 = new FileUtil();\n File file0 = MockFile.createTempFile(\"ShoppingCart=get&f=xml&dev-t=\", \"\");\n file0.delete();\n boolean boolean0 = fileUtil0.isAgeGood(file0);\n assertFalse(boolean0);\n }", "@Test\n\tpublic void testFileSystemSingleton() {\n\t\ttry {\n\t\t\tFileSystem f1 = FileSystem.getFileSystem();\n\t\t\tFileSystem f2 = FileSystem.getFileSystem();\n\t\t\tassertSame(f1, f2);\n\t\t}\n\t\tcatch (RuntimeException e) {\n\t\t\tfail();\n\t\t}\n\t}", "public void testTestInputOutput() {\n String fileName = \"file_with_invalid_uri_in_setting_xml.docx\";\n String file1 = inputDirectory + fileName;\n String expectedResult = expectedDirectory + fileName;\n ZipFile zipFileSource1;\n try {\n zipFileSource1 = new ZipFile(file1);\n File destFile = new File(outputDirectory + fileName);\n if (logger.isDebugEnabled()) {\n logger.debug(\"reading and saving\" + file1);\n }\n Package packSource1 = Package.open(zipFileSource1, PackageAccess.ReadWrite);\n WordDocument docxSource1 = new WordDocument(packSource1);\n assertTrue(docxSource1.save(destFile));\n OpenXmlAssert.assertEquals(new File(outputDirectory + fileName), new File(expectedResult));\n } catch (IOException e) {\n logger.error(e);\n fail(\"cannot open:\" + file1);\n } catch (OpenXML4JException e) {\n logger.error(e);\n fail(\"cannot open:\" + file1);\n }\n }", "@Test\n public void checkFilename(){\n boolean actual = rename.renameFile(\"jazz\",\"tomsmith\");\n assertTrue(actual);\n }", "protected abstract boolean copyCheckedFiles();", "private void compareSecondPass() {\n final int arraySize = this.oldFileNoMatch.size()\r\n + this.newFileNoMatch.size();\r\n this.compareArray = new SubsetElement[arraySize][2];\r\n final Iterator<String> oldIter = this.oldFileNoMatch.keySet()\r\n .iterator();\r\n int i = 0;\r\n while (oldIter.hasNext()) {\r\n final String key = oldIter.next();\r\n final SubsetElement oldElement = this.oldFileNoMatch.get(key);\r\n SubsetElement newElement = null;\r\n if (this.newFileNoMatch.containsKey(key)) {\r\n newElement = this.newFileNoMatch.get(key);\r\n }\r\n this.compareArray[i][0] = oldElement;\r\n this.compareArray[i][1] = newElement;\r\n i++;\r\n }\r\n // now go through the new elements and check for any that have no match.\r\n // these will be new elements with no corresponding old element\r\n final SubsetElement oldElement = null;\r\n final Iterator<String> newIter = this.newFileNoMatch.keySet()\r\n .iterator();\r\n while (newIter.hasNext()) {\r\n final String key = newIter.next();\r\n if (!this.oldFileNoMatch.containsKey(key)) {\r\n final SubsetElement newElement = this.newFileNoMatch.get(key);\r\n this.compareArray[i][0] = oldElement;\r\n this.compareArray[i][1] = newElement;\r\n i++;\r\n }\r\n\r\n }\r\n\r\n }", "public void testCompareViaSort() throws Exception {\n\n String correctlySortedNames[] = {\n \"0000_aaa\",\n \"0000_bbb\",\n \"1111DC_U_022107_L99_Sum.lsm\",\n \"6325DC_U_022107_L0_Sum.lsm\",\n \"6325DC_U_022107_L1_Sum.lsm\",\n \"6325DC_U_022107_L2_Sum.lsm\",\n \"6325DC_U_022107_L8_Sum.lsm\",\n \"6325DC_U_022107_L9_Sum.lsm\",\n \"6325DC_U_022107_L10_Sum.lsm\",\n \"6325DC_U_022107_L11_Sum.lsm\",\n \"6325DC_U_022107_L20_Sul.lsm\",\n \"6325DC_U_022107_L20_Sum.lsm\",\n \"6325DC_U_022107_L20_Sun.lsm\",\n \"6325DC_U_022107_L21_Sum.lsm\",\n \"6325DC_U_022107_L22_Sum.lsm\",\n \"6325DC_U_022107_L99_Sum.lsm\",\n \"6325DC_U_022107_L111_Sum.lsm\",\n \"6325DC_U_022107_L222_Sum.lsm\",\n \"7777DC_U_022107_L22_Sum.lsm\",\n \"9999_aaa\",\n \"9999_bbb\" \n };\n\n FileTarget[] targets = new FileTarget[correctlySortedNames.length];\n\n int index = 0;\n for (String name : correctlySortedNames) {\n int reverseOrder = targets.length - 1 - index;\n File file = new File(name);\n targets[reverseOrder] = new FileTarget(file);\n index++;\n }\n\n Arrays.sort(targets, new LNumberComparator());\n\n index = 0;\n for (FileTarget target : targets) {\n assertEquals(\"name \" + index + \" of \" + targets.length +\n \" was not sorted correctly\",\n correctlySortedNames[index], target.getName());\n index++;\n }\n }", "public String fileCompare(){\n\t\tresponseFilePath = AssertionsUtil.responseFilePath;\n\t\texpectedFilePath = AssertionsUtil.expectedFilesPath;\n\t\tString expectedJson = readJsonResponse(expectedFilePath);\n\t\tString responseJson = readJsonResponse(responseFilePath);\n\t\ttry {\n\t\t\tresponseJson = JsonPath.read(responseJson, \"$.content.text\");\n\t\t\tJSONCompareResult result = JSONCompare.compareJSON(expectedJson, responseJson, JSONCompareMode.STRICT);\n\t\t\tif(result.failed()){\n\t\t\t\treportObj.AddDataToTestReport(\"File Compare Assertion: Failed. Following are the differences between expected and actual reponse: \"+result.toString(), false);\n\t\t\t\treturn result.toString();\n\t\t\t}\n\t\t\telse{\n\t\t\t\treportObj.AddDataToTestReport(\"File Compare Assertion: Expected and Actual reponse are same\", true);\n\t\t\t\treturn \"Response File matches with the expected repsonse file\";\n\t\t\t}\n\t\t} catch (InvalidJsonException e) {\n\t\t\treportObj.AddDataToTestReport(\"FileCompare Assertion: Invalid JSON in response file : \"+e.getMessage(), false);\n\t\t\treturn \"Invalid JSON format received\";\n\t\t}\n\t\tcatch (Exception e) {\n\t\t\treportObj.AddDataToTestReport(\"FileCompare Assertion: Exception : \"+e.getMessage(), false);\n\t\t\treturn \"Invalid JSON format received\";\n\t\t}\n\t}", "@Test\n public void testCompareTest3b() {\n helperMethodb(\"CompareTest3a.txt\", \"CompareTest3b.txt\");\n }", "@Test\n public void testCompareTest6b() {\n helperMethodb(\"CompareTest6a.txt\", \"CompareTest6b.txt\");\n }", "@Test\n\tpublic void reorderIfOldestIsFirst() throws IOException {\n\t\tZonedDateTime now = ZonedDateTime.now();\n\n\t\tFile firstFile = File.createTempFile(\"junit\", null);\n\t\tFile secondFile = File.createTempFile(\"junit\", null);\n\t\tfirstFile.setLastModified(now.minus(1, ChronoUnit.DAYS).toEpochSecond());\n\t\tsecondFile.setLastModified(now.toEpochSecond());\n\n\t\tFileTuple firstTuple = new FileTuple(firstFile, firstFile);\n\t\tFileTuple secondTuple = new FileTuple(secondFile, secondFile);\n\n\t\tassertThat(COMPARATOR.compare(firstTuple, secondTuple)).isPositive();\n\t}", "@Test\n\tvoid test() throws IOException\n\t{\n\t\t\tFile f1=new File(\"testcase1.txt\");\n\t\t\tf1.createNewFile();\n\t\t\tFileWriter fileWriter;\n\t\t\tfileWriter = new FileWriter(f1.getPath());\n\t\t\tString str1=\"I am a test string and number one two three four five six seven eight nine ten eleven twelve.\";\n\t\t\tfileWriter.write(str1);\n\t\t fileWriter.close();\n\n\t\t /**\n\t\t * TO-DO\n\t\t * call formatter to get actual.txt\n\t\t */\n\t\t \n\t\t File f2=new File(\"expected1.txt\");\n\t\t\tf2.createNewFile();\n\t\t\tFileWriter fileWriter2 = new FileWriter(f2.getPath());\n\t\t\tString str2=\"I am a test string and number one two three four five six seven eight nine ten\\neleven twelve.\";\n\t\t\tfileWriter2.write(str2);\n\t\t fileWriter2.close();\n\t\t \t\t \n\t\t\tassertFalse(equalFile(\"testcase1.txt\",\"expected1.txt\"));\t\n\t}", "@Test\n\tpublic void validFileTest() {\n\t\t// Test valid file with full file path\n\t\tworkDir = new File(workingDir);\n\t\texpected = validFile.getAbsolutePath();\n\t\tactual = Helper.isValidFile(workDir, validFile.getAbsolutePath());\n\t\tassertEquals(expected, actual.getAbsolutePath());\n\n\t\t// Test valid file with only file name\n\t\texpected = workDir.getAbsolutePath() + pathSep + fileName; // Bugs: OS\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// compatible \\\\\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// changed to /\n\t\tactual = Helper.isValidFile(workDir, fileName);\n\t\tassertEquals(expected, actual.getAbsolutePath());\n\t}", "public static boolean compareFilesByteForByte(File file1, File file2) throws FileNotFoundException, IOException {\n System.out.println(Thread.currentThread().getName() + \"********************************************************* TestHelper.compareFilesByteForByte\");\n boolean compareResult = true;\n if (file1.exists() && file2.exists()) {\n if (file1.length() == file2.length()) {\n FileInputStream file2InputStream;\n try (FileInputStream file1InputStream = new FileInputStream(file1)) {\n BufferedInputStream buffered1InputStream = new BufferedInputStream(file1InputStream);\n file2InputStream = new FileInputStream(file2);\n BufferedInputStream buffered2InputStream = new BufferedInputStream(file2InputStream);\n byte[] file1Buffer = new byte[(int) file1.length()];\n byte[] file2Buffer = new byte[(int) file2.length()];\n buffered1InputStream.read(file1Buffer);\n buffered2InputStream.read(file2Buffer);\n for (int i = 0; i < file1.length(); i++) {\n if (file1Buffer[i] != file2Buffer[i]) {\n compareResult = false;\n break;\n }\n }\n }\n file2InputStream.close();\n } else {\n compareResult = false;\n }\n } else if (file1.exists() && !file2.exists()) {\n compareResult = false;\n } else {\n compareResult = file1.exists() || !file2.exists();\n }\n return compareResult;\n }", "public void expectFiles(Path[] files)\n {\n expect_files = files;\n }", "private boolean acceptAsExpected()\n {\n return saveExpectedDir_ != null;\n }", "@Test\n public void testCompareTest7b() {\n helperMethodb(\"CompareTest7a.txt\", \"CompareTest7b.txt\");\n }", "public void testImportFile() throws Exception {\n File file = new File(\"./bin/repository.xml\");\n jt.setAllowCreate(true);\n \n sessionControl.replay();\n sfControl.replay();\n \n try {\n jt.importFile(null, null);\n fail(\"expected exception\");\n } catch (IllegalArgumentException e) {\n // it's okay\n }\n sfControl.verify();\n sessionControl.verify();\n \n sfControl.reset();\n sessionControl.reset();\n \n sfControl.expectAndReturn(sf.getSession(), session);\n // create a node mock\n MockControl nodeCtrl = MockControl.createControl(Node.class);\n Node node = (Node) nodeCtrl.getMock();\n \n MockControl fileNodeCtrl = MockControl.createControl(Node.class);\n Node fileNode = (Node) fileNodeCtrl.getMock();\n \n // we need a nice control to get pass the FileStream comparison\n MockControl resNodeCtrl = MockControl.createNiceControl(Node.class);\n Node resNode = (Node) resNodeCtrl.getMock();\n \n nodeCtrl.expectAndReturn(node.addNode(file.getName(), \"nt:file\"), fileNode);\n nodeCtrl.replay();\n \n fileNodeCtrl.expectAndReturn(fileNode.addNode(\"jcr:content\", \"nt:resource\"), resNode);\n fileNodeCtrl.replay();\n \n String mimeType = MimeTable.getDefaultTable().getContentTypeFor(file.getName());\n if (mimeType == null)\n mimeType = \"application/octet-stream\";\n \n resNodeCtrl.expectAndReturn(resNode.setProperty(\"jcr:mimeType\", mimeType), null);\n resNodeCtrl.expectAndReturn(resNode.setProperty(\"jcr:encoding\", \"\"), null);\n Calendar lastModified = Calendar.getInstance();\n lastModified.setTimeInMillis(file.lastModified());\n resNodeCtrl.expectAndReturn(resNode.setProperty(\"jcr:lastModified\", lastModified), null);\n resNodeCtrl.replay();\n \n sessionControl.expectAndReturn(session.getRootNode(), node);\n session.save();\n session.logout();\n \n sfControl.replay();\n sessionControl.replay();\n \n jt.importFile(null, file);\n \n nodeCtrl.verify();\n fileNodeCtrl.verify();\n resNodeCtrl.verify();\n }", "@Test\n public void testCompareTest4b() {\n helperMethodb(\"CompareTest4a.txt\", \"CompareTest4b.txt\");\n }", "public void testGetFileObject23() throws IOException {\n File workDir = getWorkDir();\n assertGC(\"NamingFactory not cleared.\", new WeakReference<FileNaming>(NamingFactory.fromFile(workDir)));\n File rootFile = null;\n Stack<String> stack = new Stack<String>();\n while (workDir != null) {\n stack.push(workDir.getName());\n rootFile = workDir;\n workDir = workDir.getParentFile();\n }\n String relativePath = \"\";\n while (!stack.empty()) {\n relativePath += stack.pop() + \"/\";\n }\n FileObject root = FileUtil.toFileObject(rootFile);\n monitor.reset();\n assertNotNull(root.getFileObject(relativePath));\n monitor.getResults().assertResult(2, StatFiles.ALL);\n }", "@Test\n public void testCompareLess() {\n System.out.println(\"compare\");\n FileNameComparator instance = new FileNameComparator();\n int expResult = -1;\n int result = instance.compare(testFileA, testFileB);\n Assert.assertEquals(expResult, result);\n }", "@Test\r\n\tpublic void testSampleFile() {\r\n\r\n\t\tRaceList rl = null;\r\n\t\trl = WolfResultsReader.readRaceListFile(\"test-files/sample.md\");\r\n\t\tassertEquals(2, rl.size());\r\n\r\n\t}", "@Test\n public void testConsolidatedSchema() throws IOException {\n BufferedReader br =\n new BufferedReader(new FileReader(OUTPUT_DIRECTORY + File.separator + FILENAME_CONSOLIDATED));\n StringBuilder builder = new StringBuilder();\n String lineContents;\n while ((lineContents = br.readLine()) != null) {\n // The new lines are stripped via FileReader\n builder.append(lineContents);\n builder.append(System.lineSeparator());\n }\n br.close();\n\n // These definitions exist in the test schema file. Ordering is random hence the contains way of testing\n final String schemaFileContents = builder.toString();\n MatcherAssert.assertThat(schemaFileContents, CoreMatchers.containsString(SCHEMA_NAMESPACE));\n MatcherAssert.assertThat(schemaFileContents, CoreMatchers.containsString(SCHEMA_ENUM_USERSTATE));\n MatcherAssert.assertThat(schemaFileContents, CoreMatchers.containsString(SCHEMA_ENUM_CALLTYPE));\n MatcherAssert.assertThat(schemaFileContents, CoreMatchers.containsString(SCHEMA_TABLE_REQUEST));\n MatcherAssert.assertThat(schemaFileContents, CoreMatchers.containsString(SCHEMA_TABLE_RESPONSE));\n MatcherAssert.assertThat(schemaFileContents, CoreMatchers.containsString(SCHEMA_TABLE_WALLET));\n MatcherAssert.assertThat(schemaFileContents, CoreMatchers.containsString(SCHEMA_TABLE_LOOKUP_ERROR));\n MatcherAssert.assertThat(schemaFileContents, not(CoreMatchers.containsString(TABLE_PROPERTY_WALLET_WITH_NAMESPACE)));\n MatcherAssert.assertThat(schemaFileContents, not(CoreMatchers.containsString(TABLE_PROPERTY_LOOKUP_ERROR_WITH_NAMESPACE)));\n MatcherAssert.assertThat(schemaFileContents, not(CoreMatchers.containsString(TABLE_PROPERTY_REQUEST_CALLTYPE_WITH_NAMESPACE)));\n MatcherAssert.assertThat(schemaFileContents, CoreMatchers.containsString(TABLE_PROPERTY_LOOKUP_ERROR_WITHOUT_NAMESPACE));\n MatcherAssert.assertThat(schemaFileContents, CoreMatchers.containsString(TABLE_PROPERTY_REQUEST_CALLTYPE_WITHOUT_NAMESPACE));\n }", "public void compareFiles() {\n\t \n\t\tprepareLinesFile(fileName1, linesFile1);\n\t\tprepareLinesFile(fileName2, linesFile2);\n\t\t\n\t\t//If both files have the same number of lines then we compare each line\n\t if (linesFile1.size() == linesFile2.size()) {\n\t \t \tfor (int i = 0; i < linesFile1.size(); i++) {\n\t \t\tcompareLines(i);\t\t\t\t\n\t\t\t}\n\t }\n\t \n\t //Otherwise\n\t else {\n\t \t//We distinguish the files by their number of lines\n\t \tfinal ArrayList<String> linesLongerFile;\n\t \tfinal ArrayList<String> linesShorterFile;\n\t \t\n\t \t\n\t \tif (linesFile1.size() > linesFile2.size()) {\n\t \t\tlinesLongerFile = linesFile1;\n\t \t\tlinesShorterFile = linesFile2;\n\t \t}\n\t \t\n\t \telse {\n\t \t\tlinesLongerFile = linesFile2;\n\t \t\tlinesShorterFile = linesFile1;\n\t \t}\n\t \t\n\t \tint counter = 0;\n\t \t//We compare each line a number of times equals to the number of the shortest file lines\n\t \tfor (int i = 0; i < linesShorterFile.size(); i++) {\n\t \t\tcompareLines(i);\n\t \t\tcounter = i;\n\t \t}\n\t \t\n\t \t//We show the remaining lines to add into the first file\n\t \tfor (int i = counter+1; i < linesLongerFile.size(); i++) {\n\t \t\t\n\t \t\t//If the second file is the longest then we show the remaining lines to add into the first file\n\t \t\tif (linesLongerFile.size() == linesFile2.size()) {\n\t \t\t\tSystem.out.println(\"+ \"+linesLongerFile.get(i));\n\t \t\t}\n\t \t\t\n\t \t\t//If the first file is the longest then we show the remaining lines to delete \n\t \t\telse {\n\t \t\t\tSystem.out.println(\"- \"+linesLongerFile.get(i));\n\t \t\t}\n\t \t\t\n\t \t}\n\t }\t\t\n\t}", "@Test\n public void testRemoveFileRemovesFile(){\n \n FileStorageService fss = DatabaseServiceTestTool.createFileStorageService();\n \n String user1 = DatabaseServiceTestTool.usernames[0];\n String user2 = DatabaseServiceTestTool.usernames[1];\n \n assertTrue(fss.getFilesFor(user1).size() == 0);\n assertTrue(fss.getFilesFor(user2).size() == 0);\n \n try {\n InputStream is1 = prepareRandomInputStream();\n fss.addFile(user1, \"hello.pgn\", is1);\n is1.close();\n \n InputStream is2 = prepareRandomInputStream();\n fss.addFile(user2, \"hello.pgn\", is2);\n is2.close();\n \n } catch (IOException e) {\n e.printStackTrace();\n fail();\n }\n \n assertTrue(fss.getFilesFor(user1).size() == 1);\n assertTrue(fss.getFilesFor(user2).size() == 1);\n \n assertEquals(fss.getFilesFor(user1).get(0), \"hello.pgn\");\n assertEquals(fss.getFilesFor(user2).get(0), \"hello.pgn\");\n \n try {\n fss.removeFile(user1, \"hello.pgn\");\n } catch (Exception e1) {\n e1.printStackTrace();\n fail();\n }\n \n assertTrue(fss.getFilesFor(user1).size() == 0);\n \n //testing for side-effects now\n assertTrue(fss.getFilesFor(user2).size() == 1);\n assertEquals(fss.getFilesFor(user2).get(0), \"hello.pgn\");\n \n DatabaseServiceTestTool.destroyFileStorageService(fss);\n }", "@Test\n\tpublic void convertingWithEqualsSourceAndDatabaseFileTest() throws FileNotFoundException\n\t{\n\t\t/*try\n\t\t {\n\t\t OsmXmlToSQLiteDatabaseConverter converter = new OsmXmlToSQLiteDatabaseConverter();\n\t\t converter.convert(IOTester.TEST_FILE_NAME, IOTester.TEST_FILE_NAME, new TestMapObjectsIdentifiersFinder());\n\t\t fail();\n\t\t }\n\t\t catch (IllegalArgumentException ex)\n\t\t {\n\t\t // ok\n\t\t }*/\n\t}", "@Test\n\tpublic void invalidFileTest() {\n\t\t// Test error handling: invalid file\n\t\tfileName = \"invalid.txt\";\n\t\tactual = Helper.isValidFile(workDir, fileName);\n\t\tassertNull(actual);\n\n\t\t// Test error handling: invalid file\n\t\tfileName = \"./misc/secondinvalid.txt\";\n\t\tactual = Helper.isValidFile(workDir, fileName);\n\t\tassertNull(actual);\n\n\t\t// Test error handling: invalid file name with numbers\n\t\tfileName = \"12345\";\n\t\tactual = Helper.isValidFile(workDir, fileName);\n\t\tassertNull(actual);\n\n\t\t// Test error handling: invalid file name with spaces\n\t\tfileName = \"not a file\";\n\t\tactual = Helper.isValidFile(workDir, fileName);\n\t\tassertNull(actual);\n\n\t\t// Test error handling: blank file\n\t\tfileName = \"\";\n\t\tactual = Helper.isValidFile(workDir, fileName);\n\t\tassertNull(actual);\n\n\t\tfileName = \" \";\n\t\tactual = Helper.isValidFile(workDir, fileName);\n\t\tassertNull(actual);\n\n\t\tfileName = null;\n\t\tactual = Helper.isValidFile(workDir, fileName);\n\t\tassertNull(actual);\n\n\t}", "@Test(timeout = 4000)\n public void test15() throws Throwable {\n FileUtil fileUtil0 = new FileUtil();\n fileUtil0.getBrowseNodeFile(\"\", \"\", \"j<+3\");\n fileUtil0.downloadGenericSearchFile(\"\", \"An5`a`*.Ij*xzXGWlJ@\", \"plW6%,D \", \"plW6%,D \", \"\", \"j<+3\");\n EvoSuiteFile evoSuiteFile0 = new EvoSuiteFile(\"/S_ML/WZON.XML\");\n FileSystemHandling.createFolder(evoSuiteFile0);\n fileUtil0.fetchGenericSearchFile(\"d3\", \"d3\", \"d3\", \"d3\", \"d3\", \"d3\");\n fileUtil0.downloadThirdPartySearchFile(\"d3\", \"d3\", \"d3\", \"d3\");\n fileUtil0.downloadOneASINFile(\"plW6%,D \", \"An5`a`*.Ij*xzXGWlJ@\", \"plW6%,D \", \"\", \"An5`a`*.Ij*xzXGWlJ@\");\n fileUtil0.getSimilarItems(\"ML/wzOn\", \"ML/wzOn\");\n fileUtil0.isAgeGood((File) null);\n fileUtil0.downloadBrowseNodeFile(\"\", \"d3\", \"d3\", \"ML/wzOn\");\n Random.setNextRandom(1689);\n FileInputStream fileInputStream0 = fileUtil0.fetchSimilarItems(\"ML/wzOn\", \"\");\n assertNull(fileInputStream0);\n }", "private void checkDuplicateOfFile(Iterable<FileInfo> files, DuplicateDataDTO data) {\n for(FileInfo nextFile: files) {\n for(FileInfo nextFile2: files) {\n if(nextFile.duplicate(nextFile2)) {\n LOG.info(\"Duplicate - {}\", nextFile);\n\n processDuplicate(nextFile,data);\n }\n }\n }\n }", "public void testMutators() throws Exception {\n\n FileChangeSet fcs = new FileChangeSet();\n\n /*\n * Not the greatest test fixture ever. Overcome lack of accessors\n * returning Sets\n */\n FileChangeSet added = new FileChangeSet();\n added.fileAdded(\"file-1.html\");\n\n FileChangeSet modified = new FileChangeSet();\n modified.fileModified(\"file-2.html\");\n\n FileChangeSet deleted = new FileChangeSet();\n deleted.fileDeleted(\"file-3.html\");\n\n FileChangeSet targetDeleted = new FileChangeSet();\n targetDeleted.targetFileDeleted(\"file-4.html\");\n\n FileChangeSet targetAdded = new FileChangeSet();\n targetAdded.targetFileAdded(\"file-5.html\");\n\n assertEquals(\"size of ADDED correct\", 0, fcs.getAdded().size());\n assertEquals(\"size of MODIFIED correct\", 0, fcs.getModified().size());\n assertEquals(\"size of DELETED correct\", 0, fcs.getDeleted().size());\n assertEquals(\"size of TARGET FILE DELETED correct\", 0, fcs.getTargetDeleted().size());\n assertEquals(\"size of TARGET FILE ADDED correct\", 0, fcs.getTargetAdded().size());\n\n fcs.fileAdded(\"file-1.html\");\n\n assertEquals(\"size of ADDED correct\", 1, fcs.getAdded().size());\n assertEquals(\"content of ADDED correct\", added, fcs.getAdded());\n assertEquals(\"size of MODIFIED correct\", 0, fcs.getModified().size());\n assertEquals(\"size of DELETED correct\", 0, fcs.getDeleted().size());\n assertEquals(\"size of TARGET FILE DELETED correct\", 0, fcs.getTargetDeleted().size());\n assertEquals(\"size of TARGET FILE ADDED correct\", 0, fcs.getTargetAdded().size());\n\n fcs.fileModified(\"file-2.html\");\n\n assertEquals(\"size of ADDED correct\", 1, fcs.getAdded().size());\n assertEquals(\"content of ADDED correct\", added, fcs.getAdded());\n assertEquals(\"size of MODIFIED correct\", 1, fcs.getModified().size());\n assertEquals(\"content of MODIFIED correct\", modified, fcs.getModified());\n assertEquals(\"size of DELETED correct\", 0, fcs.getDeleted().size());\n assertEquals(\"size of TARGET FILE DELETED correct\", 0, fcs.getTargetDeleted().size());\n assertEquals(\"size of TARGET FILE ADDED correct\", 0, fcs.getTargetAdded().size());\n\n fcs.fileDeleted(\"file-3.html\");\n\n assertEquals(\"size of ADDED correct\", 1, fcs.getAdded().size());\n assertEquals(\"content of ADDED correct\", added, fcs.getAdded());\n assertEquals(\"size of MODIFIED correct\", 1, fcs.getModified().size());\n assertEquals(\"content of MODIFIED correct\", modified, fcs.getModified());\n assertEquals(\"size of DELETED correct\", 1, fcs.getDeleted().size());\n assertEquals(\"content of DELETED correct\", deleted, fcs.getDeleted());\n assertEquals(\"size of TARGET FILE DELETED correct\", 0, fcs.getTargetDeleted().size());\n assertEquals(\"size of TARGET FILE ADDED correct\", 0, fcs.getTargetAdded().size());\n\n fcs.targetFileDeleted(\"file-4.html\");\n\n assertEquals(\"size of ADDED correct\", 1, fcs.getAdded().size());\n assertEquals(\"content of ADDED correct\", added, fcs.getAdded());\n assertEquals(\"size of MODIFIED correct\", 1, fcs.getModified().size());\n assertEquals(\"content of MODIFIED correct\", modified, fcs.getModified());\n assertEquals(\"size of DELETED correct\", 1, fcs.getDeleted().size());\n assertEquals(\"content of DELETED correct\", deleted, fcs.getDeleted());\n assertEquals(\"size of TARGET FILE DELETED correct\", 1, fcs.getTargetDeleted().size());\n assertEquals(\"content of TARGET FILE DELETED correct\", targetDeleted, fcs.getTargetDeleted());\n assertEquals(\"size of TARGET FILE ADDED correct\", 0, fcs.getTargetAdded().size());\n\n fcs.targetFileAdded(\"file-5.html\");\n assertEquals(\"size of ADDED correct\", 1, fcs.getAdded().size());\n assertEquals(\"content of ADDED correct\", added, fcs.getAdded());\n assertEquals(\"size of MODIFIED correct\", 1, fcs.getModified().size());\n assertEquals(\"content of MODIFIED correct\", modified, fcs.getModified());\n assertEquals(\"size of DELETED correct\", 1, fcs.getDeleted().size());\n assertEquals(\"content of DELETED correct\", deleted, fcs.getDeleted());\n assertEquals(\"size of TARGET FILE DELETED correct\", 1, fcs.getTargetDeleted().size());\n assertEquals(\"content of TARGET FILE DELETED correct\", targetDeleted, fcs.getTargetDeleted());\n assertEquals(\"size of TARGET FILE ADDED correct\", 1, fcs.getTargetAdded().size());\n assertEquals(\"content of TARGET FILE ADDED correct\", targetAdded, fcs.getTargetAdded());\n\n }", "@Test\n public void testCompareTest9b() {\n helperMethodb(\"CompareTest9a.txt\", \"CompareTest9b.txt\");\n }", "public static boolean isFilesIdentical(File sourceFile,File destFile) throws Exception {\n\t\ttry {\n\t\t\tScanner sourceFileScanner = new Scanner(sourceFile);\n\t\t\tScanner destFileScanner = new Scanner(destFile);\n\t\t\t\n\t\t\twhile(sourceFileScanner.hasNext() ) {\n\t\t\t\t// If source file is having next token then destination file also should have next token , \n\t\t\t\t// else they are not identical.\n\t\t\t\tif(!destFileScanner.hasNext())\n\t\t\t\t\treturn false;\n\t\t\t\t\n\t\t\t\tif(!sourceFileScanner.next().equals(destFileScanner.next()))\n\t\t\t\t\treturn false;\n\t\t\t}\n\t\t\t\n\t\t\t// Handling the case where source file is empty and destination file is having text\n\t\t\tif(destFileScanner.hasNext())\n\t\t\t\treturn false;\n\t\t\telse\n\t\t\t\treturn true;\n\t\t} catch(Exception e) {\n\t\t\te.printStackTrace();\n\t\t\tthrow e;\n\t\t}\n\t}", "@Test(timeout = 4000)\n public void test08() throws Throwable {\n FileUtil fileUtil0 = new FileUtil();\n fileUtil0.getASINFile(\"1\", \"1\", \"1\", \"1\");\n fileUtil0.fetchThirdPartySearchFile(\"1\", \"WUxhir]B2oD]Dx&@F5=\", \"\", \"cacheLife\");\n boolean boolean0 = fileUtil0.isAgeGood((File) null);\n assertFalse(boolean0);\n \n fileUtil0.fetchSimilarItems(\"6>3}a\", \"+IH0H`oBX\");\n fileUtil0.deleteFile(\"\");\n fileUtil0.renameFile(\"1\", \"1\");\n fileUtil0.downloadThirdPartySearchFile(\"\", \"\", \"\", \"q~nQd=Y#z)~:!\");\n File file0 = fileUtil0.getBrowseNodeFile(\"@GQB)@MopBAw*\", (String) null, (String) null);\n assertNull(file0);\n \n fileUtil0.downloadBrowseNodeFile(\"1\", \"\", \"\", \"\");\n boolean boolean1 = fileUtil0.downloadOneASINFile(\"e-?P\", \"+IH0H`oBX\", \"q~nQd=Y#z)~:!\", (String) null, \"+IH0H`oBX\");\n assertTrue(boolean1 == boolean0);\n }", "@Test\n public void testCompareTest5b() {\n helperMethodb(\"CompareTest5a.txt\", \"CompareTest5b.txt\");\n }", "public static boolean filesContentEqual(String testOut, String testExp)\n\t{\n\n\t\ttry\n\t\t{\n\t\t\tString testOutStr = fileToString(testOut);\n\t\t\tString testExpStr = fileToString(testExp);\n\n\t\t\tif (testOutStr.equalsIgnoreCase(testExpStr)) return true;\n\t\t}\n\t\tcatch (FileNotFoundException fnfEx)\n\t\t{\n\t\t\tSystem.out.print(\"\\nFILE NOT FOUND: \" + testOut + \" \");\n\t\t}\n\n\t\treturn false;\n\t}", "@Test\n public void testDeleteAllContentButNotFile() throws IOException, PatchFailedException {\n Path oldFile = scratch.file(\"/root/oldfile\", \"I'm an old file\", \"bye, world\");\n Path patchFile =\n scratch.file(\n \"/root/patchfile\",\n \"--- a/oldfile\",\n \"+++ b/oldfile\",\n \"@@ -1,2 +0,0 @@\",\n \"-I'm an old file\",\n \"-bye, world\");\n PatchUtil.apply(patchFile, 1, root);\n assertThat(oldFile.exists()).isTrue();\n assertThat(FileSystemUtils.readLines(oldFile, UTF_8)).isEmpty();\n }", "@Test\n public void testFileInDirectoryFileExists() {\n\n File file1 = new File(\"file1\");\n parent.storeFile(file1);\n assertTrue(parent.fileInDirectory(\"file1\"));\n }", "@Test(timeout = 4000)\n public void test07() throws Throwable {\n FileUtil fileUtil0 = new FileUtil();\n boolean boolean0 = fileUtil0.downloadSimilaritesFile(\"\", \"\", \"\");\n assertFalse(boolean0);\n }", "@Test\n \tpublic void testEqual() {\n \t\tAssert.assertTrue(f1.equals(f1));\n \t}", "@Test\n\tpublic void testHasUnsavedChangesModifiedFile() throws Exception {\n\t\tIRodinFile rodinFile = createRodinFile(\"P/x.test\");\n\t\tRodinTestRoot root = (RodinTestRoot) rodinFile.getRoot();\n\t\tcreateNEPositive(root, \"foo\", null);\n\t\tassertUnsavedChanges(rodinFile, true);\n\n\t\t// Should report the same after closing the file.\n\t\trodinFile.close();\n\t\tassertUnsavedChanges(rodinFile, true);\n\t}" ]
[ "0.72179675", "0.7120177", "0.7066221", "0.7005286", "0.69739413", "0.69113183", "0.6859102", "0.6829292", "0.6805359", "0.6776583", "0.6769054", "0.67119044", "0.6600667", "0.6506092", "0.6471104", "0.6408512", "0.64065766", "0.6327112", "0.62860227", "0.6271978", "0.6265475", "0.62330127", "0.621876", "0.62093985", "0.6118428", "0.61046994", "0.60850525", "0.60363364", "0.6024711", "0.60131097", "0.6012453", "0.60082567", "0.59735566", "0.59734225", "0.5930484", "0.59189314", "0.58993214", "0.5871405", "0.58555156", "0.5852028", "0.58520186", "0.58406144", "0.58346707", "0.58149576", "0.5810296", "0.58074725", "0.5797898", "0.57967746", "0.57921326", "0.57844865", "0.577553", "0.57738674", "0.57680464", "0.5742074", "0.5736773", "0.57321596", "0.5729848", "0.5720904", "0.57159394", "0.5712946", "0.5710341", "0.5704935", "0.5703548", "0.57019955", "0.5701316", "0.56738985", "0.566919", "0.5664759", "0.5651411", "0.5649249", "0.5644165", "0.5623662", "0.56228137", "0.5622193", "0.5619693", "0.56134856", "0.5612108", "0.5610449", "0.56031895", "0.56029975", "0.56009144", "0.55962735", "0.559536", "0.5594277", "0.5591273", "0.55878985", "0.55764866", "0.5575018", "0.55742", "0.5571769", "0.5570668", "0.5570205", "0.5569464", "0.5566597", "0.5566097", "0.556476", "0.55579066", "0.55544186", "0.55499995", "0.5547699", "0.55416703" ]
0.0
-1
must not be called inside ReadAction
public static void refreshIOFiles(@NotNull final Collection<File> files) { final long start = System.currentTimeMillis(); try { for (File file1 : files) { final VirtualFile file = LocalFileSystem.getInstance().refreshAndFindFileByIoFile(file1); if (file != null) { file.refresh(false, false); } } } finally { ourRefreshTime += (System.currentTimeMillis() - start); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@SuppressWarnings(\"unused\")\n private void _read() {\n }", "@Override\n\tpublic void read() {\n\n\t}", "@Override\r\n\tpublic void read() {\n\r\n\t}", "public void ownRead();", "@Override\n protected boolean needReadActionToCreateState() {\n return false;\n }", "abstract void read();", "@Override\n\tpublic void readData() {\n\t\t\n\t}", "private void readObject() {\n\t\t/* default - does nothing empty block */}", "private void readObject() {/* default - does nothing empty block */\n\t}", "private void readObject() {}", "private void readObject() {}", "private void readObject() {}", "@Override\r\n\tpublic void reading() {\n\t\tSystem.out.println(\"reading\");\r\n\t}", "protected abstract Object read ();", "private void readObject() {/*default - does nothing empty block */}", "private void readObject() {/*default - does nothing empty block */}", "private void readObject() {/*default - does nothing empty block */}", "private void readObject() {/*default - does nothing empty block */}", "private void readObject() {/*default - does nothing empty block */}", "private void readObject() {/*default - does nothing empty block */}", "private void readObject() {/*default - does nothing empty block */}", "private void readObject() {/*default - does nothing empty block */}", "private void readObject() {/*default - does nothing empty block */}", "private void readObject() {/*default - does nothing empty block */}", "abstract protected boolean read();", "void confirmRead();", "private void readObject() {\n }", "public void read() {\n\t\tthis.isRead = true;\n\t}", "abstract void onReadable();", "protected void doBeginRead() throws Exception {}", "private void readItems() {\n }", "private void readObject() {/* default - does nothing empty block */\n }", "@Override\n\tpublic int read() {\n\t\treturn super.read();\n\t}", "Read createRead();", "org.naru.park.ParkController.CommonAction getSendReading();", "private void read() {\n\t\tticketint = preticketint.getInt(\"ticketint\", 0);\r\n\t\tLog.d(\"ticketint\", \"ticketint\" + \"read\" + ticketint);\r\n\t}", "private void readObject() {\n /*default - does nothing empty block */\n }", "@Override\n\tpublic void readCB(CB cb) {\n\t\t\n\t}", "@Override\n\tprotected void processInput() {\n\t}", "@Override\n public boolean isReadRequest() {\n return false;\n }", "protected abstract Reader read() throws IOException;", "@Override\n\tpublic void readMessage(Message message) {\n\t\t\n\t}", "public void execHandlerRead( Message msg ) {\n\t \t// create valid data bytes\n\t\tbyte[] buffer = (byte[]) msg.obj;\n\t\tint length = (int) msg.arg1;\n\t\tbyte[] bytes = new byte[ length ];\n\t\tfor ( int i=0; i < length; i++ ) {\n\t\t\tbytes[ i ] = buffer[ i ];\n\t\t}\n\t\t// debug\n\t\tString read = buildMsgBytes( \"r \", bytes );\n\t\tlog_d( read );\n\t\taddAndShowTextViewDebug( read );\n\t\tnotifyRead( bytes );\n\t}", "private void treatRead(SelectionKey key) throws IOException\n {\n EventHandler attach = (EventHandler) key.attachment();\n attach.processRead(key);\n }", "void read ();", "protected BiFunction<SelectionKey, Integer, Runnable> onReading() {\n return readable;\n }", "@Override\n public boolean hasReadAccess() {\n return true;\n }", "@Override\n protected void onTextData(Reader r) throws IOException {\n\n }", "abstract int read(TextInput ti) throws IOException;", "@Override\n public void onRead() {\n /*\n * It should be an error that the remote send something before we\n * pre-write.\n */\n throw new IllegalStateException();\n }", "boolean getRead();", "@Override\r\n\tpublic void read(Object id) {\n\t\t\r\n\t}", "@Override\r\n protected void readImpl() {\r\n _recipeId = readD();\r\n }", "protected void writeRead ()\n {\n stream.println (\" public void _read (org.omg.CORBA.portable.InputStream i)\");\n stream.println (\" {\");\n if (entry instanceof ValueBoxEntry)\n {\n TypedefEntry member = ((InterfaceState) ((ValueBoxEntry) entry).state ().elementAt (0)).entry;\n SymtabEntry mType = member.type ();\n if (mType instanceof StringEntry)\n stream.println (\" value = i.read_string ();\");\n\n else if (mType instanceof PrimitiveEntry)\n stream.println (\" value = \" + helperClass + \".read (i).value;\");\n\n else\n stream.println (\" value = \" + helperClass + \".read (i);\");\n }\n else\n stream.println (\" value = \" + helperClass + \".read (i);\");\n stream.println (\" }\");\n stream.println ();\n }", "@Override\n\tpublic void read(Object entidade) {\n\t\t\n\t}", "private void standByForMessages() throws IOException {\n if (reader.readLine() != null) {\n try {\n JSONObject j = (JSONObject) jps.parse(reader.readLine());\n sequence = Integer.valueOf(j.get(\"sequence\").toString());\n String cmd = (String) j.get(\"command\");\n JSONArray parameter = (JSONArray) j.get(\"parameter\");\n cmdHandler(parameter, cmd);\n } catch (ParseException ex) {\n }\n }\n }", "@Override\n\tpublic int[] read() {\n\t\treturn null;\n\t}", "@Override\n\tpublic int[] read() {\n\t\treturn null;\n\t}", "@Override\n\tpublic int[] read() {\n\t\treturn null;\n\t}", "public void setRead(){\n \tthis.isRead = true;\n }", "public String readInput() {\n\t\treturn null;\n\t}", "public abstract void read(DataInput input) throws IOException;", "@Override\n\tpublic void readClient(Client clt) {\n\t\t\n\t}", "private void read(){\n try {\n if (c != -1) c = r.read();\n } catch (IOException e){\n throw new IOError(e);\n }\n }", "@Override\r\n\tpublic void read(DataInput in) throws IOException {\n\t\t\r\n\t}", "protected void modelRead(){\r\n\t\tthis.model.read(in, null);\r\n\t\tSystem.out.println(\"\\n -- model read finished --\\n\");\r\n\t}", "@Override\n\tpublic void read(InStream inStream) {\n\t}", "@Override\n protected boolean usesNoRefReads() {\n return true;\n }", "boolean getForRead();", "protected final boolean didRead (boolean value) { return didRead = value;}", "@Override\r\n\tpublic void adminSelectRead() {\n\t\t\r\n\t}", "protected abstract int readInternal(int index);", "private void ensureRead() throws IOException, BadDescriptorException {\n if (reading) return;\n flushWrite();\n buffer.clear();\n buffer.flip();\n reading = true;\n }", "@Override\n\tpublic void input() {\n\t\t\n\t}", "public void readSysCall() {\n read = false;\n clientChannel.read(readBuffer, this, readCompletionHandler);\n }", "private void readObjectNoData() throws ObjectStreamException {}", "@Override\n\tprotected void channelRead0(ChannelHandlerContext ctx, WsClientMessage msg) throws Exception {\n\t}", "private void handleRead(SelectionKey key) throws IOException {\n\t\t\tSSLSocketChannel ssl_socket_channel = ((SSLClientSession)key.attachment()).getSSLSocketChannel();\n\t\t\tByteBuffer request = ssl_socket_channel.getAppRecvBuffer();\n\t\t\tint count = ssl_socket_channel.read();\n\t\t\t\n\t\t\tif (count < 0) {\n\t\t\t\t\n\t\t\t\tremoveKeyAndSession(key);\n\t\t\t\t\n\t\t\t} else if (request.position() > 0) {\n\t\t\t\t\n\t\t\t\ttry {\n\t\t\t\t\tString message = new String(request.array(),0,request.position());\n\t\t\t\t\t\n//\t\t\t\t\tOutputHandler.println(\"Server: read \"+message);\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t// Parse the JSON message\n\t\t\t\t\tJSONObject json = (JSONObject) parser.parse(message);\n\t\t\t\t\t\n\t\t\t\t\t// Process the message\n\t\t\t\t\tprocessNetworkMessage(json, key);\n\t\t\t\t\t\n\t\t\t\t\trequest.clear();\n\t\t\t\t} catch (ParseException e) {\n\t\t\t\t\tSystem.out.println(\"Invalid message format.\");\n\t\t\t\t}\n\t\t\t}\n\t\t}", "boolean hasForRead();", "public abstract byte[] read() throws IOException, IllegalArgumentException , IllegalStateException;", "private void doRead() throws IOException {\n\t\t\tvar res = sc.read(bb);\n\n\t\t\tif ( res == -1 ) {\n\t\t\t\tlogger.info(\"Connection closed with the client.\");\n\t\t\t\tclosed = true;\n\t\t\t}\n\n\t\t\tupdateInterestOps();\n\t\t}", "public boolean wasRead(){\n return isRead==null || isRead;\n }", "@Override\n public void action() {\n }", "@Override\n public void action() {\n }", "@Override\n public void action() {\n }", "@Override\r\n\tpublic void action() {\n\t\t\r\n\t}", "public String read();", "private void t3() {\n // write to a super region, read from a subregion: only keep write\n writeProtected();\n readDefault();\n }", "private void readForm() {\n }", "@Override\n\t\t\t\t\t\t\tpublic void onIOException(IOException e, Object state) {\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t}", "boolean hasRead();", "protected abstract Reader getReader() throws IOException;", "@Override\n public int read() throws IOException {\n return input.read();\n }", "private void readEvent() {\n\t\t\t\n\t\t\thandlePacket();\n\t\t\t\n\t\t}", "String read();", "String read();", "@Override\n\tpublic void onSkipInRead(Throwable t) {\n\t\t\n\t}", "protected void beforeConsume() {\n // Do nothing\n }", "protected Reaction() {/* intentionally empty block */}", "static String read ()\r\n \t{\r\n \t\tString sinput;\r\n \r\n \t\ttry\r\n \t\t{\r\n \t\t\tsinput = br.readLine();\r\n \t\t}\r\n \t\tcatch (IOException e)\r\n \t\t{\r\n \t\t\tErrorLog.addError(\"Input exception occured in command line interface!\");\r\n \t\t\treturn null; //Menu will exit when fed a null\r\n \t\t}\r\n \t\treturn sinput;\r\n \t}", "@Override\n\tpublic void channelRead(ChannelHandlerContext ctx, Object msg) throws Exception {\n\t\tLog.i(\"channelRead\", ((String) msg));\n\t\tsuper.channelRead(ctx, msg);\n\t}" ]
[ "0.7594123", "0.7191937", "0.716826", "0.6868894", "0.6822488", "0.6737658", "0.6607232", "0.6575627", "0.64620537", "0.63884115", "0.63884115", "0.63884115", "0.6368097", "0.6360403", "0.63573223", "0.63573223", "0.63573223", "0.63573223", "0.63573223", "0.63573223", "0.63573223", "0.63573223", "0.63573223", "0.63573223", "0.6342146", "0.63333565", "0.6319955", "0.63070774", "0.6281725", "0.6277872", "0.6259504", "0.6258819", "0.622927", "0.62280995", "0.62223333", "0.6182229", "0.61750144", "0.6156977", "0.60448956", "0.6026545", "0.5987627", "0.5983282", "0.5964123", "0.596264", "0.5948125", "0.5945679", "0.5924875", "0.5912984", "0.58937687", "0.58864087", "0.58804786", "0.58717275", "0.58615834", "0.5858461", "0.58232677", "0.58061624", "0.5774194", "0.5774194", "0.5774194", "0.5769888", "0.5754695", "0.57485926", "0.5734957", "0.57295203", "0.5713122", "0.5711559", "0.5687056", "0.567667", "0.5668012", "0.5665137", "0.56556594", "0.56440127", "0.5640403", "0.56363076", "0.56325674", "0.56281406", "0.5564326", "0.5556879", "0.5555971", "0.55387914", "0.55365425", "0.5527889", "0.55241066", "0.55241066", "0.55241066", "0.5520741", "0.550564", "0.5502106", "0.5499078", "0.5498778", "0.5498394", "0.5496194", "0.54938024", "0.5493749", "0.5490361", "0.5490361", "0.548163", "0.54764134", "0.54713315", "0.545563", "0.54546666" ]
0.0
-1
need to specify default encoding so that javac outputs messages in 'correct' language noinspection HardCodedStringLiteral
public static void addLocaleOptions(final List<String> commandLine, final boolean launcherUsed) { commandLine.add((launcherUsed? "-J" : "") + "-D" + CharsetToolkit.FILE_ENCODING_PROPERTY + "=" + CharsetToolkit.getDefaultSystemCharset().name()); // javac's VM should use the same default locale that IDEA uses in order for javac to print messages in 'correct' language //noinspection HardCodedStringLiteral final String lang = System.getProperty("user.language"); if (lang != null) { //noinspection HardCodedStringLiteral commandLine.add((launcherUsed? "-J" : "") + "-Duser.language=" + lang); } //noinspection HardCodedStringLiteral final String country = System.getProperty("user.country"); if (country != null) { //noinspection HardCodedStringLiteral commandLine.add((launcherUsed? "-J" : "") + "-Duser.country=" + country); } //noinspection HardCodedStringLiteral final String region = System.getProperty("user.region"); if (region != null) { //noinspection HardCodedStringLiteral commandLine.add((launcherUsed? "-J" : "") + "-Duser.region=" + region); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void setCharacterEncoding(String arg0) {\n\n }", "@Override\n public String getCharacterEncoding() {\n return null;\n }", "public String getJavaEncoding();", "public interface EncoderConstants\n{\n\t/**\n\t * The default charset string.\n\t */\n\tpublic static final String DEFAULT_CHARSET = \"ISO-8859-1\";\n}", "public void setEncoding (String encoding) {\n this.encoding = encoding;\n }", "String getEncoding();", "public String getDeclaredEncoding();", "public interface ExtraEncoding {\n \n /**\n * Converts an Unicode string to a byte array according to some encoding.\n * @param text the Unicode string\n * @param encoding the requested encoding. It's mainly of use if the same class\n * supports more than one encoding.\n * @return the conversion or <CODE>null</CODE> if no conversion is supported\n */ \n public byte[] charToByte(String text, String encoding);\n \n /**\n * Converts an Unicode char to a byte array according to some encoding.\n * @param char1 the Unicode char\n * @param encoding the requested encoding. It's mainly of use if the same class\n * supports more than one encoding.\n * @return the conversion or <CODE>null</CODE> if no conversion is supported\n */ \n public byte[] charToByte(char char1, String encoding);\n \n /**\n * Converts a byte array to an Unicode string according to some encoding.\n * @param b the input byte array\n * @param encoding the requested encoding. It's mainly of use if the same class\n * supports more than one encoding.\n * @return the conversion or <CODE>null</CODE> if no conversion is supported\n */\n public String byteToChar(byte b[], String encoding); \n}", "@Override\n\tpublic String getCharacterEncoding() {\n\t\treturn null;\n\t}", "protected static String guessXMLEncoding(String document){\r\n\t\tString encoding = \"UTF-8\";\r\n\t\t\r\n\t\tClassLoader saved = Thread.currentThread().getContextClassLoader();\r\n\t\ttry {\r\n\t\t\tlog.println(\"GUESSING ENCODING...\");\r\n\t\t\tString parts[] = document.split(\"\\\"\");\r\n\t\t\tfor(int i = 0; i < parts.length; i++){\r\n\t\t\t\tif(parts[i].equalsIgnoreCase(\" encoding=\")){\r\n\t\t\t\t\tencoding = parts[i + 1];\r\n\t\t\t\t\tlog.println(\"ENCODING FOUND TO BE: \" + encoding);\r\n\t\t\t\t\tbreak;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\tcatch(Throwable t){\r\n\t\t\tif (log != null) t.printStackTrace(log);\r\n\t\t}\r\n\t\tfinally{\r\n\t\t\tThread.currentThread().setContextClassLoader(saved);\r\n\t\t}\r\n\t\treturn encoding;\r\n\t}", "public String getDefaultCharset() {\n/* 359 */ return this.charset;\n/* */ }", "@Override\n\tpublic void setCharacterEncoding(String env) throws UnsupportedEncodingException {\n\t\t\n\t}", "@Override\n\t\tpublic String getCharacterEncoding() {\n\t\t\treturn null;\n\t\t}", "protected String getDefaultEncoding() {\n return DEFAULT_ENCODING;\n }", "private Encodings()\n {\n // nothing to do\n }", "@Override\n\t\tpublic void setCharacterEncoding(String env) throws UnsupportedEncodingException {\n\t\t\t\n\t\t}", "public String getEncoding() {\n \t return null;\n \t }", "public String getEncoding() {\n \t return null;\n \t }", "Charset getEncoding();", "public void setEncoding(String encoding) {\r\n this.encoding = encoding;\r\n }", "public static void main(String[] args) throws UnsupportedEncodingException {\n\r\n\t}", "public EncodeAndDecodeStrings() {}", "@Override\n public boolean isUnicode()\n {\n return true;\n }", "public PEASEncoder() {\n this(Charset.defaultCharset());\n }", "protected ISO8859_1()\r\n {\r\n }", "public void setEncoding(String encoding) {\n this.encoding = encoding;\n }", "public void setEncoding(String encoding) {\n this.encoding = encoding;\n }", "public void setEncoding(String encoding) {\n this.encoding = encoding;\n }", "public void setCharacterEncoding(String s) {\n\n\t}", "public String encode(String str, String charsetName) throws UnsupportedEncodingException {\n/* 230 */ if (str == null) {\n/* 231 */ return null;\n/* */ }\n/* 233 */ return StringUtils.newStringUsAscii(encode(str.getBytes(charsetName)));\n/* */ }", "public URLCodec() {\n/* 104 */ this(\"UTF-8\");\n/* */ }", "String getUseNativeEncoding();", "public void setEncoding(String e) {\n\t\tthis.encoding = e;\n\t}", "public void setFileEncoding(String s) {\n if (s == null) fileEncoding = \"\";\n else fileEncoding = s;\n }", "public boolean requiresCustomCodec()\n/* */ {\n/* 498 */ return false;\n/* */ }", "protected final void setEncoding( String encoding )\n throws SAXException\n {\n if ( _inputSource.getByteStream() != null ) {\n if ( ! encoding.equalsIgnoreCase( _inputSource.getEncoding() ) ) {\n _inputSource.setEncoding( encoding );\n try {\n _reader = new InputStreamReader( new BufferedInputStream( _inputSource.getByteStream() ), encoding );\n } catch ( UnsupportedEncodingException except ) {\n error( WELL_FORMED, format( \"Parser014\", encoding ) );\n }\n }\n }\n else\n if ( isWarning() && _inputSource.getEncoding() != null &&\n ! encoding.equalsIgnoreCase( _inputSource.getEncoding() ) )\n warning( format( \"Parser015\", _inputSource.getEncoding(), encoding ) ); \n }", "private static String guessAppropriateEncoding(CharSequence contents) {\n\t\tfor (int i = 0; i < contents.length(); i++) {\n\t\t\tif (contents.charAt(i) > 0xFF) {\n\t\t\t\treturn \"UTF-8\";\n\t\t\t}\n\t\t}\n\t\treturn null;\n\t}", "private static String guessAppropriateEncoding(CharSequence contents) {\n\t\tfor (int i = 0; i < contents.length(); i++) {\n\t\t\tif (contents.charAt(i) > 0xFF) {\n\t\t\t\treturn \"UTF-8\";\n\t\t\t}\n\t\t}\n\t\treturn null;\n\t}", "public URLCodec(String charset) {\n/* 114 */ this.charset = charset;\n/* */ }", "public void setEncoding(Encoding encoding) {\n this.encoding = encoding;\n }", "public void setInputEncoding(String inputEncoding) {\r\n this.inputEncoding = inputEncoding;\r\n }", "@Test\n\tpublic void testUnsafe()\n\t{\n\t\tString[] code = {\n\t\t\t\"var a\\n = 'Here is a unsafe character';\"\n\t\t};\n\t\t\n\t\tth.test(code, new LinterOptions().set(\"es3\", true));\n\t}", "public static void main(String[] args) throws UnsupportedEncodingException {\n test18();\n }", "public String getCharSet() throws VlException\n {\n return ResourceLoader.CHARSET_UTF8;\n }", "public void setEncoding(String encoding) {\n this.encoding = encoding;\n }", "public void setCharset(String string) {\n\t\t\r\n\t}", "private void suggestsUtF8CharsetWhenUsingPlatformDefaultCharset(OutputStream os) {\n OutputStreamWriter outputStreamWriter = new OutputStreamWriter(os, StandardCharsets.UTF_8);\n }", "private CharsetDecoder getJavaEncoding(String encoding) {\n Charset charset = Charset.forName(encoding);\n return charset.newDecoder();\n }", "public LintParser(final String defaultEncoding) {\n\t\tsuper(defaultEncoding);\n\t}", "public static void main(String[] args) {\nSystem.out.println(\"xin chào linh\");\n\n\n}", "static C2395k m11991j() {\n return new C2395k(\"Protocol message had invalid UTF-8.\");\n }", "@Test\n public void test084() throws Throwable {\n ErrorPage errorPage0 = new ErrorPage();\n // Undeclared exception!\n try {\n String string0 = errorPage0.encode(\"%k8|vhOy\");\n fail(\"Expecting exception: NullPointerException\");\n \n } catch(NullPointerException e) {\n //\n // no message in exception (getMessage() returned null)\n //\n }\n }", "public PEASEncoder(Charset charset) {\n if (charset == null) {\n throw new NullPointerException(\"charset\");\n }\n this.charset = charset;\n }", "@Test\r\n public void testValidEncodings() {\r\n assertThatInputIsValid(\"\");\r\n assertThatInputIsValid(\"UTF8\");\r\n assertThatInputIsValid(\"UTF-8\");\r\n assertThatInputIsValid(\"CP1252\");\r\n assertThatInputIsValid(\"ISO-8859-1\");\r\n assertThatInputIsValid(\"ISO-8859-5\");\r\n assertThatInputIsValid(\"ISO-8859-9\");\r\n }", "public String getEncoding() {\n return null;\n }", "public String getStringEncoding()\n\t{\n\t\treturn \"utf-8\";\n\t}", "public void setEncoding(String encoding) {\n\t\tthis.encoding = encoding;\n\t}", "@Test\n public void testEncode() {\n LOGGER.info(\"testEncode\");\n final String actual = new AtomString().encode();\n final String expected = \"0:\";\n assertEquals(expected, actual);\n }", "public default String getCharset() {\n return Constants.CHARSET_UTF8;\n }", "public String getEncoding() {\r\n return \"B\";\r\n }", "public void setCharset(String charset) {\n this.charset = charset;\n }", "public interface ConstString\n{\n\tString STRING_ENCODING_UTF8 = \"UTF-8\";\n\tString APPLICATION_XML = \"application/xml\";\n\tString APPLICATION_JSON = \"application/json\";\n\tString APP_JSON_UTF_8 = \"application/json;charset=UTF-8\";\n\tString APP_XML_UTF_8 = \"application/xml;charset=UTF-8\";\n}", "public interface FengJing {\n String zhongShanLing=\"中山陵\";\n}", "public String getEncoding () {\n return encoding;\n }", "public String getCharacterEncoding() {\n\t\treturn null;\n\t}", "@SuppressWarnings(\"unused\")\n public static void setRuntimeEncoding() throws IllegalAccessException, NoSuchFieldException {\n System.setProperty(\"file.encoding\", \"UTF-8\");\n Field charset = Charset.class.getDeclaredField(\"defaultCharset\");\n charset.setAccessible(true);\n charset.set(null, null);\n }", "String getCharset();", "Builder addEncoding(String value);", "static zzco m26833e() {\n return new zzco(\"Protocol message had invalid UTF-8.\");\n }", "public String encode(String str) throws EncoderException {\n/* 249 */ if (str == null) {\n/* 250 */ return null;\n/* */ }\n/* */ try {\n/* 253 */ return encode(str, getDefaultCharset());\n/* 254 */ } catch (UnsupportedEncodingException e) {\n/* 255 */ throw new EncoderException(e.getMessage(), e);\n/* */ } \n/* */ }", "String getSupportedEncoding(String acceptableEncodings);", "public QuotedPrintableCodec(String charset) {\n super();\n this.charset = charset;\n }", "public interface Encoding {\n\t/**\n\t * Encoding a string.\n\t * \n\t * @param source\n\t * @return The encoded string\n\t * @throws Exception\n\t */\n\tpublic String encode(String source) throws Exception;\n\n\t/**\n\t * Decoding a string.\n\t * \n\t * @param source\n\t * @return The decoded string\n\t * @throws Exception\n\t */\n\tpublic String decode(String source) throws Exception;\n\n}", "String getContentEncoding();", "private FormattedTextEncoder() {\r\n\t\tsuper();\r\n\t}", "private static CharsetEncoder getCoder(String charset) throws UnsupportedEncodingException\n\t{\n\t\tcharset = charset.toLowerCase();\t\t\n\t\tif (charset.equals(\"iso-8859-1\") || charset.equals(\"latin1\"))\t\t\t\n\t\t\treturn new Latin1Encoder();\n\t\tif (charset.equals(\"utf-8\") || charset.equals(\"utf8\"))\t\t\t\n\t\t\treturn new UTF8Encoder();\n\t\t\n\t\tthrow new UnsupportedEncodingException(\"unsupported encoding \"+charset);\n\t}", "public String encodeJava()\n {\n return '\"' + val + '\"';\n }", "public void testMarshalCodedTypeString() {\n System.out.println(\"marshal\");\n CodedType codedType = new CodedType(\"myCode\", \"myCodingSchema\");\n String elementName = \"language\";\n CodedTypeMarshaler instance = new CodedTypeMarshaler();\n String expResult = \"<language code=\\\"myCode\\\" codingScheme=\\\"myCodingSchema\\\"></language>\";\n String result = instance.marshal(codedType, elementName);\n assertEquals(expResult, result);\n }", "C11998c mo41090e(String str);", "public String getEncoding() {\n return encoding;\n }", "void mo1935c(String str);", "public CCPackedGSMCharset() {\n super(NAME,ALIASES,\n BYTE_TO_CHAR_CAPITAL_C_CEDILLA,BYTE_TO_CHAR_ESCAPED_DEFAULT,\n CHAR_TO_BYTE_CAPITAL_C_CEDILLA,CHAR_TO_BYTE_ESCAPED_DEFAULT);\n }", "@Test\r\n public void testInvalidEncodings() {\r\n assertThatInputIsInvalid(\"NIX\");\r\n assertThatInputIsInvalid(\"UTF-9\");\r\n assertThatInputIsInvalid(\"ISO-8859-42\");\r\n }", "EncodingEnum getEncoding();", "public interface Encoding {\n String encode(String encodeValue);\n String decode(String encodedValue);\n}", "void mo1934b(String str);", "@org.junit.Test\n public void jsString()\n {\n assertEquals(\"empty\", \"''\", Encodings.toJSString(\"\"));\n assertEquals(\"simple\", \"'test'\", Encodings.toJSString(\"test\"));\n assertEquals(\"escape\", \"'escape \\\\\\'\\\\\\\"strings\\\\\\\"\\\\''\",\n Encodings.toJSString(\"escape '\\\"strings\\\"'\"));\n }", "java.lang.String getS8();", "@Test\n public void testIntializerProvidesTheRequestedCharsetIfItIsValid()\n throws NoSuchMethodException, InvocationTargetException, IllegalAccessException, NoSuchFieldException\n {\n String goodCharsetName = \"UTF-16\";\n Charset goodCharset = Charset.forName(goodCharsetName);\n\n final DefaultCharset defaultCharsetInstance = setInternalDefaultCharset(goodCharsetName);\n final Charset charset = getCurrentCharsetFromDefaultCharsetInstance(defaultCharsetInstance);\n\n assertEquals(goodCharset.name(), charset.name());\n }", "public AsciiDataEncoder() {\n\t}", "private static void showJava(String string) { TODO Auto-generated method stub\n\t//\n\t\n}", "public interface UnicodeConstants {\n\n /** Refers to unnormalized Unicode: */\n static final byte NORM_UNNORMALIZED = 0;\n /** Refers to Normalization Form C: */\n static final byte NORM_NFC = 1;\n /** Refers to Normalization Form KC: */\n static final byte NORM_NFKC = 2;\n /** Refers to Normalization Form D: */\n static final byte NORM_NFD = 3;\n /** Refers to Normalization Form KD: */\n static final byte NORM_NFKD = 4;\n /** Refers to Normalization Form THDL, which is NFD except for\n <code>U+0F77</code> and <code>U+0F79</code>, which are\n normalized according to NFKD. This is the One True\n Normalization Form, as it leaves no precomposed codepoints and\n does not normalize <code>U+0F0C</code>. */\n static final byte NORM_NFTHDL = 5;\n\n\n /** for those times when you need a char to represent a\n non-existent codepoint */\n static final char EW_ABSENT = '\\u0000';\n\n\n //\n // the thirty consonants, in alphabetical order:\n //\n\n /** first letter of the alphabet: */\n static final char EWC_ka = '\\u0F40';\n\n static final char EWC_kha = '\\u0F41';\n static final char EWC_ga = '\\u0F42';\n static final char EWC_nga = '\\u0F44';\n static final char EWC_ca = '\\u0F45';\n static final char EWC_cha = '\\u0F46';\n static final char EWC_ja = '\\u0F47';\n static final char EWC_nya = '\\u0F49';\n static final char EWC_ta = '\\u0F4F';\n static final char EWC_tha = '\\u0F50';\n static final char EWC_da = '\\u0F51';\n static final char EWC_na = '\\u0F53';\n static final char EWC_pa = '\\u0F54';\n static final char EWC_pha = '\\u0F55';\n static final char EWC_ba = '\\u0F56';\n static final char EWC_ma = '\\u0F58';\n static final char EWC_tsa = '\\u0F59';\n static final char EWC_tsha = '\\u0F5A';\n static final char EWC_dza = '\\u0F5B';\n static final char EWC_wa = '\\u0F5D';\n static final char EWC_zha = '\\u0F5E';\n static final char EWC_za = '\\u0F5F';\n /** Note the irregular name. The Extended Wylie representation is\n <code>'a</code>. */\n static final char EWC_achung = '\\u0F60';\n static final char EWC_ya = '\\u0F61';\n static final char EWC_ra = '\\u0F62';\n static final char EWC_la = '\\u0F63';\n static final char EWC_sha = '\\u0F64';\n static final char EWC_sa = '\\u0F66';\n static final char EWC_ha = '\\u0F67';\n /** achen, the 30th consonant (and, some say, the fifth vowel) DLC NOW FIXME: rename to EWC_achen */\n static final char EWC_a = '\\u0F68';\n\n\n /** In the word for father, \"pA lags\", there is an a-chung (i.e.,\n <code>\\u0F71</code>). This is the constant for that little\n guy. */\n static final char EW_achung_vowel = '\\u0F71';\n\n\n /* Four of the five vowels, some say, or, others say, \"the four\n vowels\": */\n /** \"gi gu\", the 'i' sound in the English word keep: */\n static final char EWV_i = '\\u0F72';\n /** \"zhabs kyu\", the 'u' sound in the English word tune: */\n static final char EWV_u = '\\u0F74';\n /** \"'greng bu\" (also known as \"'greng po\", and pronounced <i>dang-bo</i>), the 'a' sound in the English word gate: */\n static final char EWV_e = '\\u0F7A';\n /** \"na ro\", the 'o' sound in the English word bone: */\n static final char EWV_o = '\\u0F7C';\n\n\n /** subscribed form of EWC_wa, also known as wa-btags */\n static final char EWSUB_wa_zur = '\\u0FAD';\n /** subscribed form of EWC_ya */\n static final char EWSUB_ya_btags = '\\u0FB1';\n /** subscribed form of EWC_ra */\n static final char EWSUB_ra_btags = '\\u0FB2';\n /** subscribed form of EWC_la */\n static final char EWSUB_la_btags = '\\u0FB3';\n}", "@org.junit.Test\n public void coverage()\n {\n new Encodings();\n }", "public void testInvalidTextValueWithBrokenUTF8() throws Exception\n {\n final byte[] input = readResource(\"/data/clusterfuzz-cbor-35979.cbor\");\n try (JsonParser p = MAPPER.createParser(input)) {\n assertToken(JsonToken.VALUE_STRING, p.nextToken());\n p.getText();\n fail(\"Should not pass\");\n } catch (StreamReadException e) {\n verifyException(e, \"Truncated UTF-8 character in Short Unicode Name (36 bytes)\");\n }\n\n }", "public static String guessAppropriateEncoding(CharSequence contents) {\n for (int i = 0; i < contents.length(); i++) {\n if (contents.charAt(i) > 0xFF) {\n return \"UTF-8\";\n }\n }\n return null;\n }", "@Test(timeout = 4000)\n public void test068() throws Throwable {\n StringReader stringReader0 = new StringReader(\"%Jo{\\\"m8'0fuS\");\n JavaCharStream javaCharStream0 = new JavaCharStream(stringReader0, 77, 77);\n JavaParserTokenManager javaParserTokenManager0 = new JavaParserTokenManager(javaCharStream0);\n Token token0 = javaParserTokenManager0.getNextToken();\n assertEquals(0, javaCharStream0.bufpos);\n assertEquals(\"%\", token0.toString());\n }", "public void setEncoding(String encoding) {\n this.encoding = encoding == null ? null : encoding.trim();\n }", "public void testSetEncoding_Normal() throws Exception {\n ByteArrayOutputStream aos = new ByteArrayOutputStream();\n StreamHandler h = new StreamHandler(aos, new MockFormatter());\n h.setEncoding(\"iso-8859-1\");\n assertEquals(\"iso-8859-1\", h.getEncoding());\n LogRecord r = new LogRecord(Level.INFO, \"\\u6881\\u884D\\u8F69\");\n h.publish(r);\n h.flush();\n\n byte[] bytes = encoder.encode(\n CharBuffer.wrap(\"MockFormatter_Head\" + \"\\u6881\\u884D\\u8F69\"))\n .array();\n assertTrue(Arrays.equals(bytes, aos.toByteArray()));\n }", "public void testSetEncoding_Unsupported() {\n StreamHandler h = new StreamHandler();\n try {\n h.setEncoding(\"impossible\");\n fail(\"Should throw UnsupportedEncodingException!\");\n } catch (UnsupportedEncodingException e) {\n // expected\n }\n assertNull(h.getEncoding());\n }", "@Test\n void test7BitEncoding() throws Exception {\n ascii_cp1251_lcid1049.guess7BitEncoding();\n ascii_cp1251_lcid1049.setReturnNullOnMissingChunk(true);\n ascii_utf_8_cp1252_lcid1031.guess7BitEncoding();\n ascii_utf_8_cp1252_lcid1031.setReturnNullOnMissingChunk(true);\n ascii_utf_8_cp1252_lcid1031_html.guess7BitEncoding();\n ascii_utf_8_cp1252_lcid1031_html.setReturnNullOnMissingChunk(true);\n htmlbodybinary_cp1251.guess7BitEncoding();\n htmlbodybinary_cp1251.setReturnNullOnMissingChunk(true);\n htmlbodybinary_utf_8.guess7BitEncoding();\n htmlbodybinary_utf_8.setReturnNullOnMissingChunk(true);\n\n assertEquals(\"Subject автоматически Subject\", ascii_cp1251_lcid1049.getSubject());\n assertEquals(\"Body автоматически Body\", ascii_cp1251_lcid1049.getTextBody());\n assertEquals(\"<!DOCTYPE html><html><meta charset=\\\\\\\"windows-1251\\\\\\\"><body>HTML автоматически</body></html>\", ascii_cp1251_lcid1049.getHtmlBody());\n\n assertEquals(\"Subject öäü Subject\", ascii_utf_8_cp1252_lcid1031.getSubject());\n assertEquals(\"Body öäü Body\", ascii_utf_8_cp1252_lcid1031.getTextBody());\n assertNull(ascii_utf_8_cp1252_lcid1031.getHtmlBody());\n\n assertEquals(\"Subject öäü Subject\", ascii_utf_8_cp1252_lcid1031_html.getSubject());\n assertEquals(\"Body öäü Body\", ascii_utf_8_cp1252_lcid1031_html.getTextBody());\n assertEquals(\"<!DOCTYPE html><html><meta charset=\\\\\\\"utf-8\\\\\\\"><body>HTML öäü</body></html>\", ascii_utf_8_cp1252_lcid1031_html.getHtmlBody());\n\n assertEquals(\"Subject öäü Subject\", htmlbodybinary_cp1251.getSubject());\n assertNull(htmlbodybinary_cp1251.getTextBody());\n assertEquals(\"<!DOCTYPE html><html><meta charset=\\\\\\\"utf-8\\\\\\\"><body>HTML автоматически</body></html>\", htmlbodybinary_cp1251.getHtmlBody());\n\n assertEquals(\"Subject öäü Subject\", htmlbodybinary_utf_8.getSubject());\n assertNull(htmlbodybinary_utf_8.getTextBody());\n assertEquals(\"<!DOCTYPE html><html><meta charset=\\\\\\\"utf-8\\\\\\\"><body>HTML öäü</body></html>\", htmlbodybinary_utf_8.getHtmlBody());\n }", "@Deprecated\n/* */ public String getEncoding() {\n/* 371 */ return this.charset;\n/* */ }" ]
[ "0.67238355", "0.6473887", "0.6302419", "0.620422", "0.60942495", "0.60735494", "0.60628694", "0.60595953", "0.6039346", "0.6010189", "0.59336066", "0.59238267", "0.5922099", "0.5905997", "0.5874209", "0.5865409", "0.58641326", "0.58641326", "0.5849782", "0.5849351", "0.58483183", "0.58366406", "0.5832772", "0.58171004", "0.5814873", "0.5811733", "0.5811733", "0.5811733", "0.57876545", "0.5781591", "0.57458746", "0.57406574", "0.5728892", "0.5724893", "0.5712558", "0.57112426", "0.57055855", "0.57055855", "0.56644833", "0.5648264", "0.562667", "0.5623661", "0.5618087", "0.5615053", "0.56132406", "0.5605394", "0.5596355", "0.55897903", "0.5588794", "0.5585105", "0.5575249", "0.5569442", "0.5565122", "0.5565079", "0.5560933", "0.55569816", "0.5556733", "0.5543012", "0.5527239", "0.5506395", "0.54982", "0.5495624", "0.5492817", "0.54779285", "0.5476456", "0.5476381", "0.5475281", "0.54698306", "0.5461278", "0.54587954", "0.54565823", "0.5449999", "0.5430059", "0.54211926", "0.5408917", "0.5407006", "0.5403234", "0.5399281", "0.53859377", "0.53849876", "0.53833324", "0.538247", "0.53774947", "0.53772265", "0.537294", "0.5369163", "0.5361499", "0.5358575", "0.53447187", "0.534385", "0.5324891", "0.5321474", "0.5319359", "0.53158057", "0.53097165", "0.5309226", "0.53080845", "0.53038913", "0.5303857", "0.53011596", "0.529789" ]
0.0
-1
TODO Autogenerated method stub
@Override public void b() { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\n public void perish() {\n \n }", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "@Override\n\tpublic void anular() {\n\n\t}", "@Override\n\tprotected void getExras() {\n\n\t}", "@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}", "@Override\n\tpublic void entrenar() {\n\t\t\n\t}", "@Override\n\tpublic void nadar() {\n\t\t\n\t}", "@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}", "@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}", "@Override\n\tprotected void interr() {\n\t}", "@Override\n\tpublic void emprestimo() {\n\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\n\tpublic void grabar() {\n\t\t\n\t}", "@Override\n\tpublic void gravarBd() {\n\t\t\n\t}", "@Override\r\n\tpublic void rozmnozovat() {\n\t}", "@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}", "@Override\n protected void getExras() {\n }", "@Override\r\n\tpublic void publierEnchere() {\n\t\t\r\n\t}", "@Override\n\tpublic void nefesAl() {\n\n\t}", "@Override\n\tpublic void ligar() {\n\t\t\n\t}", "@Override\n public void func_104112_b() {\n \n }", "@Override\n\tprotected void initdata() {\n\n\t}", "@Override\n\tpublic void nghe() {\n\n\t}", "@Override\n public void function()\n {\n }", "@Override\n public void function()\n {\n }", "public final void mo51373a() {\n }", "@Override\r\n\tpublic void stehReagieren() {\r\n\t\t//\r\n\t}", "@Override\n public void inizializza() {\n\n super.inizializza();\n }", "@Override\n\tprotected void initData() {\n\t\t\n\t}", "@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}", "@Override\n\tpublic void sacrifier() {\n\t\t\n\t}", "@Override\r\n\tprotected void InitData() {\n\t\t\r\n\t}", "public void designBasement() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}", "public void gored() {\n\t\t\n\t}", "@Override\r\n\tprotected void initData() {\n\r\n\t}", "@Override\n\tpublic void einkaufen() {\n\t}", "@Override\n protected void initialize() {\n\n \n }", "public void mo38117a() {\n }", "@Override\n\tprotected void getData() {\n\t\t\n\t}", "Constructor() {\r\n\t\t \r\n\t }", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "@Override\n\tpublic void one() {\n\t\t\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}", "private stendhal() {\n\t}", "@Override\n\tprotected void update() {\n\t\t\n\t}", "@Override\n\t\t\tpublic void ic() {\n\t\t\t\t\n\t\t\t}", "@Override\n\tprotected void initData() {\n\n\t}", "@Override\n\tprotected void initData() {\n\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n public void init() {\n\n }", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\n\tpublic void debite() {\n\t\t\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "public contrustor(){\r\n\t}", "@Override\n\tprotected void initialize() {\n\n\t}", "@Override\r\n\tpublic void dispase() {\n\r\n\t}", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "@Override\n\tpublic void dtd() {\n\t\t\n\t}", "@Override\n\tprotected void logic() {\n\n\t}", "@Override\n\tprotected void lazyLoad() {\n\t\t\n\t}", "public void mo4359a() {\n }", "@Override\r\n\tprotected void initialize() {\n\r\n\t}", "@Override\n public void memoria() {\n \n }", "@Override\n\t\tpublic void method() {\n\t\t\t\n\t\t}", "private RepositorioAtendimentoPublicoHBM() {\r\t}", "@Override\n protected void initialize() \n {\n \n }", "@Override\r\n\tpublic void getProposition() {\n\r\n\t}", "@Override\n\tpublic void particular1() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n protected void prot() {\n }", "@Override\r\n\tpublic void init()\r\n\t{\n\t}", "@Override\n\tprotected void initValue()\n\t{\n\n\t}", "public void mo55254a() {\n }" ]
[ "0.6671074", "0.6567672", "0.6523024", "0.6481211", "0.6477082", "0.64591026", "0.64127725", "0.63762105", "0.6276059", "0.6254286", "0.623686", "0.6223679", "0.6201336", "0.61950207", "0.61950207", "0.61922914", "0.6186996", "0.6173591", "0.61327106", "0.61285484", "0.6080161", "0.6077022", "0.6041561", "0.6024072", "0.6020252", "0.59984857", "0.59672105", "0.59672105", "0.5965777", "0.59485507", "0.5940904", "0.59239364", "0.5910017", "0.5902906", "0.58946234", "0.5886006", "0.58839184", "0.58691067", "0.5857751", "0.58503544", "0.5847024", "0.58239377", "0.5810564", "0.5810089", "0.5806823", "0.5806823", "0.5800025", "0.5792378", "0.5792378", "0.5792378", "0.5792378", "0.5792378", "0.5792378", "0.5790187", "0.5789414", "0.5787092", "0.57844025", "0.57844025", "0.5774479", "0.5774479", "0.5774479", "0.5774479", "0.5774479", "0.5761362", "0.57596046", "0.57596046", "0.575025", "0.575025", "0.575025", "0.5747959", "0.57337177", "0.57337177", "0.57337177", "0.5721452", "0.5715831", "0.57142824", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.57140535", "0.5711723", "0.57041645", "0.56991017", "0.5696783", "0.56881124", "0.56774884", "0.56734604", "0.56728", "0.56696945", "0.5661323", "0.5657007", "0.5655942", "0.5655942", "0.5655942", "0.56549734", "0.5654792", "0.5652974", "0.5650185" ]
0.0
-1
default / Melhores temas: start bluesky cupertino redmond humanity hotsneaks blitzer afternoon Botoes: delta start flick
@Override protected void init() { List<Configuracao> configs = servico.listarTodos(); if (!configs.isEmpty()) { entidade = configs.get(0); // deve haver apenas um registro } else { createConfiguracao(); } carregarTemas(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void start(float delta) {\n\t\t\n\t}", "private void start() {\n\n\t}", "@Override\n\tpublic void start() {\n\t\t\tSystem.out.println(\"BMW --- strart\");\n\t}", "public static void main(String[] args) {\n addTint(new DemoTint());\n // start script with filename and function registry\n start(\"demo.tea\");\n }", "public void start() {\n\t\t\n\t}", "public void start() {\n\t\t\n\t}", "public void start() {}", "public void start() {}", "void start();", "void start();", "void start();", "void start();", "void start();", "void start();", "void start();", "void start();", "void start();", "void start();", "void start();", "void start();", "void start();", "void start();", "void start();", "public void start() {\n\t\tSystem.out.println(\"BMW.........start!!!.\");\n\t}", "void start() {\n }", "public void start() {\n\n\t}", "public void starting();", "public static void main(String[] args){\n//\t\tnew Selection().start();\n//\t\tnew Selection().start();\n//\t\tnew Insertion().start();\n\t\tnew Insertion().start();\n\t\tnew Insertion().start();\n\t\tnew Insertion().start();\n\t}", "public void start() {\n\t\tSystem.out.println(\"BMW Slef-----start\");\n\t}", "public void start()\n {}", "public static void main(String[] args) {\n // start the animation. \n new Animate().startController(SIZE,SIZE+LINUX_MENU_BAR);\n }", "public void start();", "public void start();", "public void start();", "public void start();", "public void start();", "public void start();", "public void start();", "public void start();", "public void start();", "public void start();", "public void start();", "public void start();", "@Override\n\tpublic void start() {\n\t\tSystem.out.println(\"BMW -- start\");\n\t}", "void start ();", "public void start()\r\n\t{\n\tSystem.out.println(\"normal start method\");\r\n\t}", "public static void start() {\n \t\tMainGame.display.disp(\"What type of monster do you want to fight?:\");\r\n \t\t//Display the buttons for the choice of monster\r\n \t\tMainGame.display.Enable(MainGame.display.warriorM, MainGame.display.fighterM);\r\n \t}", "public void start() {\n \t\tgui.initialize();\n \t\t// DEBUG mode\n\t\tbman.get(0).boostSpeed(2);\n \n \t\tloop();\n \t}", "public void start() {\r\n\t\tSystem.out.println(\"start the car\");\r\n\t}", "public void start() {\n }", "@Override\n\tpublic void start() {\n\t\t\n\t}", "@Override\n\tpublic void start() {\n\t\t\n\t}", "@Override\n\tpublic void start() {\n\t\t\n\t}", "@Override\n\tpublic void start() {\n\t\t\n\t}", "public static void main(String[] args) {\r\n\r\n\t\tStartFrame.getInstance().showFrame();\r\n\t\tlogr.info(\"starting\");\r\n\r\n\t}", "@Override\n\tpublic void start() {\n\n\t}", "@Override\r\n\tpublic void start() {\n\t\t\r\n\t}", "Start createStart();", "void start(String name);", "public void start() {\n\n }", "@Override\r\n\tpublic void start() {\n\t\tsuper.start();\r\n\t\t\r\n\t}", "void doManualStart();", "public static void main(String[] args) {\n\t\tDisplay.openWorld(\"maps/pasture.map\");\n\n Display.setSize(15, 15);\n Display.setSpeed(7);\n Robot andre = new Wanderer(int i, int j);\n for(int n = 0; n<36; n++) {\n for(int k=0; k<36; k++) {\n andre.wander(); \n }\n explode();\n \n\t\t// TODO Create an instance of a Horse inside the pasture\n\t\t// TODO Have the horse wander for 36 steps with a timer of 7\n\t\t// TODO Have the horse explode()\n\t}\n\n}", "public static void main(String[] args) {\n\t\tJFrame frame=new JFrame();\n\t\tStart start=new Start();\n\t\tframe.add(start);\n\t\tframe.setSize(WIDTH, HEIGHT);\n\t\tframe.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n\t\tframe.setLocationRelativeTo(null);\n\t\tframe.addKeyListener(start.kl);\n\t\tframe.setVisible(true);\n\t\tstart.mos.add(start.sky);\n\t\tstart.mos.add(start.hero);\n\t\tstart.action();\n\n\t}", "public void start()\n {\n }", "@Override\n\tpublic void start() {\n\t}", "@Override\n\tpublic void start() {\n\t}", "public static void start() { \r\n\t\ttempo_inicial = System.nanoTime(); \r\n\t\ttempo_final = 0; \r\n\t\tdiftempo = 0; \r\n\t}", "public static void main(String[] args){\r\n\t\tstart();\r\n\t}", "public static void main(String[] args) {\n\t\tSystem.out.printf(\"炒青菜的第一个小游戏\");\n\t\tBallGame game=new BallGame();\n\t\tgame.launchFrame();\n\t\n\t\t\n\t\t\n\n\t}", "public void start(){\n }", "public static void main(String[] args) {\n\t\t// TODO Auto-generated method stub\n\t\t\n\t\t//Setting.SetSettings();\n\t\tMorse.start(\"Hello world\");\n\t\t/*\n\t\tDimensions.Init();\n\t\tDimensions.MoveY(50);\n\t\t\n\t\tDimensions.ChangeLine();\n\t\t*/\n\t\t/*\n\t\tDimensions.Init(20);\n\t\t\n\t\n\t\t amount = 90;\n\t\t speed = 20;\n\t\tDimensions.SetSpeedForThis(speed);\n\t\t//Dimensions.MoveY(500);\n\t\twhile(!Button.ESCAPE.isDown()){\n\t\t\tif(Button.DOWN.isDown()){\n\t\t\t\tDimensions.MoveY(amount);\n\t\t\t}else if(Button.UP.isDown()){\n\t\t\t\tDimensions.MoveY(-amount);\n\t\t\t}else if(Button.LEFT.isDown()){\n\t\t\t\tDelay.msDelay(5000);\n\t\t\t\tDimensions.MoveX(amount);\n\t\t\t}else if(Button.RIGHT.isDown()){\n\t\t\t\tDelay.msDelay(5000);\n\t\t\t\tDimensions.MoveX(-amount);\n\t\t\t}else if(Button.ENTER.isDown()){\n\t\t\t\tsetting();\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t\tDelay.msDelay(50);\n\t\t\t\n\t\t}\n\t\t*/\n\t}", "public static void main(String[] args) {\n\t\tIFroggerGraphics graphic = new FroggerGraphic(15, 15,true, false,false);\n\t\tgraphic.menuScreen();\n\t}", "public void start() {\n System.out.println(\"start\");\n }", "public static void vu0Start() { }", "@Override\n protected void start() {\n System.out.println(\"Bike Specific Brake\");\n }", "public void startup() {\n\t\tstart();\n }", "public void start() {\n\tanimator = new Thread(this);\n\tanimator.setName(\"erly_boid:::swarm intelligence\");\n\terlang =new Thread(co);\n\terlang.start();\n\tanimator.start();\n \n \n \t\n }", "private void spawnStart() {\n\t\tswitch (gameType) {\n\t\t\n\t\t}\n\t\tspawnCloud(10,1,0,0); //spawns base cloud\n\t\tspawnCloud(rng(7,10),6,rng(1,2),rng(2,3)); //spawns first clouds\n\t\tspawnCloud(rng(9,12),6,rng(1,2),rng(2,3));\n\t\t//spawnCloud(10,6,16,0);\n\t}", "public static void main(String[] args) {\n new BouncingSprites().panel.animate();\n }", "@Override\r\n public void start() {\r\n }", "public void sendeSpielStarten();", "public void startFight() {\r\n\t\tmenu.setVisible(false);\r\n\t\tmenu.setThreadSuspended(true);\r\n\t\tadd(new Fight(WIDTH, HEIGHT, gfh.loadBackground(\"london_nationalgallery.jpg\")));\r\n\t\tsetVisible(false);\r\n\t\tsetVisible(true);\r\n\t}", "@Override\n public void start() {\n }", "@Override\n public void start() {\n }", "@Override\n public void start() {\n }", "@Override\n public void start() {\n }", "@Override\n public void start() {\n }", "@Override\n public void start() {\n }", "@Override\n public void start() {\n }", "@Override\n public void start() { }", "abstract public void start();", "public static void start(){\n new Light(new Vector3f(getSIZE()*Chunk.getCHUNKSIZE()/2,getSIZE()*Chunk.getCHUNKSIZE()/2,getSIZE()*Chunk.getCHUNKSIZE()/2));\n Keyboard.enableRepeatEvents(true);\n createWindow();\n initGL();\n generateWorld();\n Game.gameLoop();\n }", "public void start()\n/* 354: */ {\n/* 355:434 */ onStartup();\n/* 356: */ }", "@Override\n\tvoid start() {\n\t\tSystem.out.println(\"starts\");\n\t}", "@Override\n public void start() {\n\n }", "@Override\n public void start() {\n\n }", "@Override\n public void start() {\n\n }", "@Override\n\tpublic void start() {\n\t\t\n\t\t_mode.init();\n\t\t\n\t\t_mode.start();\n\t}", "public static void main(final String[] args) {\n ManualStartUi.newStyleBuilder();\n }", "void start(String option);" ]
[ "0.6633777", "0.60345036", "0.5997874", "0.5959923", "0.5951824", "0.5951824", "0.59408486", "0.59408486", "0.5939597", "0.5939597", "0.5939597", "0.5939597", "0.5939597", "0.5939597", "0.5939597", "0.5939597", "0.5939597", "0.5939597", "0.5939597", "0.5939597", "0.5939597", "0.5939597", "0.5939597", "0.58982027", "0.58822024", "0.5871992", "0.5867835", "0.58675545", "0.58425325", "0.5811762", "0.5788553", "0.5786374", "0.5786374", "0.5786374", "0.5786374", "0.5786374", "0.5786374", "0.5786374", "0.5786374", "0.5786374", "0.5786374", "0.5786374", "0.5786374", "0.57666314", "0.5766268", "0.57519096", "0.57410455", "0.5737309", "0.5732412", "0.5719129", "0.5718933", "0.5718933", "0.5718933", "0.5718933", "0.57072693", "0.56843156", "0.56819093", "0.5660522", "0.5647072", "0.5647034", "0.5637039", "0.56307733", "0.5625846", "0.5618252", "0.5614794", "0.55862236", "0.55862236", "0.55851454", "0.5580239", "0.5578488", "0.5568125", "0.555049", "0.55486184", "0.5542512", "0.55392444", "0.5539233", "0.5531603", "0.5531488", "0.55299866", "0.55292535", "0.5522067", "0.5521854", "0.55186856", "0.55138916", "0.55138916", "0.55138916", "0.55138916", "0.55138916", "0.55138916", "0.55138916", "0.55007297", "0.54923886", "0.54859823", "0.54807186", "0.54756296", "0.54753876", "0.54753876", "0.54753876", "0.54603153", "0.54581183", "0.54575527" ]
0.0
-1
Created by Administrator on 2016/10/19.
@Singleton @Component(modules = {AppModule.class, AppClientModule.class}) public interface AppComponent { Application getApplication(); MainViewInteraction getWeatherInteractor(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private stendhal() {\n\t}", "@Override\n public void perish() {\n \n }", "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}", "@Override\n\tpublic void entrenar() {\n\t\t\n\t}", "@Override\n\tpublic void grabar() {\n\t\t\n\t}", "@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}", "@Override\n\tpublic void gravarBd() {\n\t\t\n\t}", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "@Override\n public void inizializza() {\n\n super.inizializza();\n }", "public final void mo51373a() {\n }", "@Override\n\tprotected void getExras() {\n\n\t}", "public void mo38117a() {\n }", "@Override\n\tpublic void anular() {\n\n\t}", "public void mo4359a() {\n }", "@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}", "@Override\n protected void initialize() {\n\n \n }", "@Override\r\n\tpublic void publierEnchere() {\n\t\t\r\n\t}", "@Override\n protected void initialize() \n {\n \n }", "private static void cajas() {\n\t\t\n\t}", "@Override\r\n\tpublic void rozmnozovat() {\n\t}", "Constructor() {\r\n\t\t \r\n\t }", "private Rekenhulp()\n\t{\n\t}", "@Override\n public void init() {\n\n }", "@Override\n public void memoria() {\n \n }", "public void designBasement() {\n\t\t\r\n\t}", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void gored() {\n\t\t\n\t}", "@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}", "protected MetadataUGWD() {/* intentionally empty block */}", "@Override\n\tpublic void create () {\n\n\t}", "@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}", "public void autoDetails() {\n\t\t\r\n\t}", "@Override\n public void settings() {\n // TODO Auto-generated method stub\n \n }", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "public Pitonyak_09_02() {\r\n }", "public contrustor(){\r\n\t}", "@Override\n\tpublic void create() {\n\t\t\n\t}", "@Override\n\tpublic void nadar() {\n\t\t\n\t}", "private TMCourse() {\n\t}", "public void verarbeite() {\n\t\t\r\n\t}", "Petunia() {\r\n\t\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n protected void getExras() {\n }", "private RepositorioAtendimentoPublicoHBM() {\r\t}", "@Override\n\tprotected void initialize() {\n\n\t}", "@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}", "public void mo55254a() {\n }", "public void mo6081a() {\n }", "@Override\n\tpublic void debite() {\n\t\t\n\t}", "@Override\n\tprotected void interr() {\n\t}", "private void init() {\n\n\t}", "public void create() {\n\t\t\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\n\tpublic void einkaufen() {\n\t}", "public void mo12930a() {\n }", "@Override\n void init() {\n }", "@Override\r\n\tprotected void initialize() {\n\r\n\t}", "@Override\n public void func_104112_b() {\n \n }", "@Override\n public void init() {\n }", "@Override\n\tpublic void nghe() {\n\n\t}", "@Override\n protected void init() {\n }", "@Override\n public void init() {\n\n }", "@Override\n public void init() {\n\n }", "@Override\n\tpublic void ligar() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "private void getStatus() {\n\t\t\n\t}", "@Override\r\n\tpublic void stehReagieren() {\r\n\t\t//\r\n\t}", "protected Doodler() {\n\t}", "@Override\n\tpublic void create() {\n\n\t}", "@Override\r\n\tpublic void create() {\n\r\n\t}", "@Override\n\tpublic void emprestimo() {\n\n\t}" ]
[ "0.6242293", "0.6133287", "0.6033158", "0.5985007", "0.5953132", "0.593938", "0.5902989", "0.5868517", "0.5866762", "0.5853025", "0.5853025", "0.58398914", "0.58398914", "0.5819075", "0.58106655", "0.5798139", "0.57799923", "0.5779239", "0.577476", "0.57350814", "0.5722325", "0.5719126", "0.56461847", "0.56389856", "0.5636401", "0.56246865", "0.5621551", "0.56205577", "0.5617699", "0.5616192", "0.5610263", "0.55939025", "0.55939025", "0.55939025", "0.55939025", "0.55939025", "0.55939025", "0.55939025", "0.5585675", "0.5584363", "0.5581258", "0.5580594", "0.5578744", "0.5568774", "0.556685", "0.5563783", "0.5563783", "0.5562419", "0.5562419", "0.5562419", "0.5562419", "0.5562419", "0.5562419", "0.5560542", "0.55583745", "0.55569845", "0.55501497", "0.55491304", "0.5541515", "0.5533557", "0.5527898", "0.5527898", "0.5527898", "0.5527898", "0.5527898", "0.55256236", "0.55231804", "0.5512627", "0.5509081", "0.55026305", "0.5498828", "0.5488619", "0.54850686", "0.5484942", "0.54829234", "0.54737836", "0.54737836", "0.54737836", "0.5473512", "0.5473512", "0.5473512", "0.54695547", "0.54695547", "0.5463868", "0.54600483", "0.5457622", "0.5456568", "0.54547477", "0.5448216", "0.54472107", "0.54472107", "0.5437902", "0.5428763", "0.5428763", "0.5428763", "0.54257184", "0.5425041", "0.5424969", "0.5424767", "0.5418766", "0.5414423" ]
0.0
-1
Equal method for the CustomerRouteTabuPosition.
@Override public boolean equals(Object obj) { if (obj == null) { return false; } try { final CustomerTabu other = (CustomerTabu) obj; if (this.getCustomer() != other.getCustomer()) { return false; } try { final CustomerRouteTabu other2 = (CustomerRouteTabu) obj; if (this.getRoute() != other2.getRoute()) { return false; } try { final CustomerRouteTabuPosition other3 = (CustomerRouteTabuPosition) obj; if (this.laterCustomer != other3.laterCustomer || this.previousCustomer != other3.previousCustomer) { return false; } return true; } catch (ClassCastException cce) { return true; } } catch (ClassCastException cce) { return true; } } catch (ClassCastException cce) { return false; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Test\n public void testPositionEquals(){\n assertEquals(Maze.position(0,0), Maze.position(0,0));\n assertThat(Maze.position(1, 0), not(Maze.position(0, 0)));\n assertThat(Maze.position(0,0), not(Maze.position(0,1)));\n }", "@Override\n public boolean equals(Object obj) {\n if (!(obj instanceof BoardPosition))\n return false;\n BoardPosition b = (BoardPosition) obj;\n return (this.getRow() == b.getRow()) && (this.getColumn() == b.getColumn()) && (this.getPlayer() == b.getPlayer());\n }", "public boolean equals(Object obj)\n {\n TAPosition taPosition;\n if(obj instanceof TAPosition)\n {\n taPosition = (TAPosition)obj;\n return position.equals(taPosition.getPosition());\n }\n else\n return false;\n }", "@Override\n\tpublic boolean equals(Object other)\n\t{\n if (other == this) \n {\n return true;\n }\n \n // Check if is an instance of this class:\n if (!(other instanceof RelativeLocation))\n {\n return false;\n }\n \n // Check if have same x and y values:\n RelativeLocation otherRelativeLocation = (RelativeLocation) other;\n \n return (this.getX() == otherRelativeLocation.getX()\n \t\t&& this.getY() == otherRelativeLocation.getY());\n\t\t\n\t}", "@Override\n public boolean equals(Object other) {\n if (other == null) {\n return false;\n }\n if (other == this) {\n return true;\n }\n if (!(other instanceof RunRoutePoint)) {\n return false;\n }\n\n // Other object is a RunRoutePoint and is not null.\n RunRoutePoint otherRunRoutePoint = (RunRoutePoint) other;\n return this.getLocation().equals(otherRunRoutePoint.getLocation()) && this.getDirection().equals(otherRunRoutePoint.getDirection());\n }", "@Override\n public boolean equals(Object inst) {\n if (inst == this)\n {\n return true;\n }\n if (!(inst instanceof BoardPosition))\n {\n return false;\n }\n BoardPosition pos = (BoardPosition) inst;\n return column == pos.column && row == pos.row;\n }", "public boolean equals (Position pos) // Creates an operator that compares two positions\n\t{\n\t\tif ((r == pos.r) && (c == pos.c))\n\t\t\treturn true;\n\t\telse\n\t\t\treturn false;\n\t}", "@Test\n public void testNullPositionEquals(){\n assertFalse(Maze.position(0,0).equals(null));\n }", "@Override\r\n public boolean equals(Object obj) {\r\n if (!(obj instanceof Position))\r\n return false;\r\n Position pos = (Position)obj;\r\n return ((pos.getRowIndex() == this.rowIndex) && (pos.getColumnIndex() == this.colIndex));\r\n }", "@Test\n void getLocations() {\n GPSObject n2 = new GPSObject(\"Centenary 1\");\n Location n1 = new Location(\"Centenary 1\",\"0\",n2);\n GPSObject n3 = new GPSObject(\"Thuto 1\");\n Location n4 = new Location(\"Thuto 1\",\"1\",n3);\n Locations loc = new Locations();\n Route roo = new Route(\"roo\", loc);\n assertTrue(roo.getLocations().equals(loc));\n }", "public boolean equals(Position other) {\n return (other.x == this.x && other.y == this.y);\r\n }", "@Override\r\n public boolean equals(Object object) {\n if (!(object instanceof Geocovarage)) {\r\n return false;\r\n }\r\n Geocovarage other = (Geocovarage) object;\r\n if ((this.planID == null && other.planID != null) || (this.planID != null && !this.planID.equals(other.planID))) {\r\n return false;\r\n }\r\n return true;\r\n }", "@Test\n\tpublic void testEquals2() {\n\t\tDistance d2 = new Distance();\n\t\tDistance d4 = new Distance(1, 1);\n\t\tassertEquals(true, d2.equals(d4));\n\t}", "public boolean isSameAs(Move comp){ \n return this.xFrom==comp.xFrom &&\n this.xTo==comp.xTo &&\n this.yFrom==comp.yFrom &&\n this.yTo==comp.yTo;\n }", "public boolean equals(Case c){\n\t\treturn (this.posX==c.getPosX() && this.posY==c.getPosY()); \n\t}", "private boolean compareLocation(Location location){\n return location.getBlockX()==this.location.getBlockX() && location.getBlockY()==this.location.getBlockY() && location.getBlockZ() == this.location.getBlockZ();\n }", "public void compareAddress()\n {\n Address a = new Address(\"Amapolas\",1500,\"Providencia\",\"Santiago\");\n Address b = new Address(\"amapolas\",1500, \"providencia\",\"santiago\");\n Address c = new Address(\"Hernando Aguirre\",1133,\"Providencia\", \"Santiago\");\n \n boolean d = a.equals(b); \n }", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof Locacao)) {\n return false;\n }\n Locacao other = (Locacao) object;\n if ((this.idLocacao == null && other.idLocacao != null) || (this.idLocacao != null && !this.idLocacao.equals(other.idLocacao))) {\n return false;\n }\n return true;\n }", "@Override\n public boolean equals(final Object o) {\n Position position = (Position) o;\n return posX == position.posX && posY == position.posY && Objects.equals(charAlg, position.charAlg);\n }", "@Override\r\n public boolean equals(Object object) {\n if (!(object instanceof RealscheduleliteLocation)) {\r\n return false;\r\n }\r\n RealscheduleliteLocation other = (RealscheduleliteLocation) object;\r\n if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {\r\n return false;\r\n }\r\n return true;\r\n }", "public boolean equals(ChessLocation cp)\r\n {\r\n if(cp.getRow() == this.row && cp.getCol() == this.col)\r\n {\r\n return true;\r\n }\r\n else\r\n {\r\n return false;\r\n }\r\n }", "@Override\n public boolean equals(Object o) {\n\t\tif(o==null)\n\t\t\treturn false;\n\t\tMove m = (Move) o;\n\t\tif(this.pieceRow == m.pieceRow && this.pieceCol == m.pieceCol &&\n\t\t\t\tthis.destRow == m.destRow && this.destCol == m.destCol)\n\t\t\treturn true;\n\t\treturn false;\n\t}", "public boolean equals(Solution sol) {\n if (this.route.length != sol.route.length){\n return false;\n }\n // Check the Distance\n else if (this.distance != sol.distance) {\n return false;\n }else{\n // Check the Route\n for (int index = 0; index < this.route.length; index++) {\n if (this.route[index] != sol.route[index]){\n return false;\n }\n }\n }\n return true;\n }", "private static boolean comparePlayerPosition(RSTile tile) {\n RSTile player_position = Player07.getPosition();\n if (tile == null || player_position == null) {\n return false;\n }\n return tile.equals(player_position);\n }", "private static boolean sameDestination(Reservation a, Reservation b){\n\t\tif( (a.seatOwner() == b.seatOwner() ) && ( a.seatDestination() == b.seatDestination() ) ){\n\t\t\treturn true;\n\t\t}else{\n\t\t\treturn false;\n\t\t}\n\t}", "public boolean equals(Location anotherLocation)\r\n\t{\r\n\t\treturn (this.getRow()==anotherLocation.getRow()) && (this.getColumn()==anotherLocation.getColumn());\r\n\t}", "@Test\n public void testNotPositionInstanceEquals(){\n Pillar p = new Pillar(0,0);\n assertFalse(Maze.position(0,0).equals(p));\n }", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof Route)) {\n return false;\n }\n Route other = (Route) object;\n if ((this.iDRoute == null && other.iDRoute != null) || (this.iDRoute != null && !this.iDRoute.equals(other.iDRoute))) {\n return false;\n }\n return true;\n }", "@Override\n boolean isSameTransitTrip(TransitNode transitNode) {\n if (transitNode instanceof SubwayStation) {\n return this.startLocation.getLine().equals(((SubwayStation) transitNode).getLine());\n }\n return false;\n }", "@Override\n\tpublic boolean equals(Object obj) {\n\t\tif (this == obj)\n\t\t\treturn true;\n\t\tif (obj == null)\n\t\t\treturn false;\n\t\tif (getClass() != obj.getClass())\n\t\t\treturn false;\n\t\tMove other = (Move) obj;\n\t\tif (col != other.col)\n\t\t\treturn false;\n\t\tif (row != other.row)\n\t\t\treturn false;\n\t\treturn true;\n\t}", "@Test\n\tpublic void testEquals1() {\n\t\tDistance d1 = new Distance(0, 0);\n\t\tDistance d2 = new Distance();\n\t\tassertEquals(false, d1.equals(d2));\n\t}", "@Override\r\n public boolean equals(Object object) {\n if (!(object instanceof ZoneGeographique)) {\r\n return false;\r\n }\r\n ZoneGeographique other = (ZoneGeographique) object;\r\n if ((this.codeZoneGeo == null && other.codeZoneGeo != null) || (this.codeZoneGeo != null && !this.codeZoneGeo.equals(other.codeZoneGeo))) {\r\n return false;\r\n }\r\n return true;\r\n }", "@Override\n public boolean equals(Object o) {\n if (o == this) { \n return true; \n } \n \n /* Check if o is an instance of Complex or not \n \"null instanceof [type]\" also returns false */\n if (!(o instanceof Path)) { \n return false; \n } \n \n // typecast o to Complex so that we can compare data members \n Path p = (Path) o; \n \n // Compare the data members and return accordingly \n return (this.startingPointIndex == p.startingPointIndex && this.distance == p.distance);\n }", "public boolean patchLocationEquals(Model patch1, Model patch2)\n {\n return super.patchLocationEquals(patch1, patch2);\n }", "@Override\n public boolean equals(Object obj) {\n if ( obj instanceof Position ) {\n return ((Position)obj).getTicker().equals(ticker);\n }\n return false;\n }", "public boolean equals(Object loc)\r\n {\r\n\r\n //if the location does not equal anything (null) and is of the same\r\n //class as the location.\r\n //\"this\" literally refers to the class...meaning this.x is referring\r\n //to the location class variable. If THIS location's class is equal to\r\n //this other location class, then it is equal and we return true;\r\n if (loc != null && this.getClass() == loc.getClass())\r\n {\r\n //we set point equal to the value in loc...we can cast it now\r\n //that we know that it is of the same class. We do this to\r\n //make sure it works correctly\r\n Location point = (Location)loc;\r\n //here we actually check the members of the point and see if they\r\n //are equal to the instance variable\r\n if (point.x() == this.x() && point.y() == this.y())\r\n {\r\n //return true if everything is equal\r\n return true;\r\n }\r\n\r\n }\r\n\r\n return false;\r\n }", "public boolean isEqual(Move m){\r\n\t\treturn m.getStartSquare()==start_sq&&m.getEndSquare()==end_sq&&(m.getModifier()==modifiers % 10);\r\n\t}", "@Override\n public boolean equals (Object obj) {\n if (obj instanceof OtherActivity) {\n return super.equals(obj)\n && location.equals(((OtherActivity)obj).location) ;\n } else {\n return false;\n }\n }", "boolean czaCompare(PARAM_ZONE pZone, CObject pHo)\r\n {\r\n if (pHo.hoX < pZone.x1 || pHo.hoX >= pZone.x2)\r\n {\r\n return false;\r\n }\r\n if (pHo.hoY < pZone.y1 || pHo.hoY >= pZone.y2)\r\n {\r\n return false;\r\n }\r\n return true;\r\n }", "public boolean equals(MC_Location loc) {\n\t\t if(x != loc.x) return false;\n\t\t if(y != loc.y) return false;\n\t\t if(z != loc.z) return false;\n\t\t if(dimension != loc.dimension) return false;\n\t\t if(Math.abs(yaw - loc.yaw) > 0.0001) return false;\n\t\t if(Math.abs(pitch - loc.pitch) > 0.0001) return false;\n\t\t return true;\n\t }", "public boolean equals(Line other) {\r\n // exactly the same line\r\n if (this.start.equals(other.start) && this.end.equals(other.end)) {\r\n return true;\r\n }\r\n // opossite lines\r\n if (this.start().equals(other.end) && this.end().equals(other.start)) {\r\n return true;\r\n }\r\n return false;\r\n }", "public boolean equals(Object o)\n\t{\n\t\tboolean ret = false;\n\t\tif(o instanceof Position)\n\t\t{\n\t\t\tPosition tmp = (Position)o;\n\t\t\tif(tmp.getX()==x && tmp.getY()==y)\n\t\t\t\tret = true;\n\t\t}\n\t\treturn ret;\n\t}", "public boolean equals(Object obj) {\n\n if (obj instanceof Location) {\n\n Location other = (Location) obj;\n\n return row == other.getRow() && col == other.getCol();\n\n } else {\n\n return false;\n\n }\n }", "public boolean equals(Object o) {\n\t\tif(this == o) return true;\n\t\tif(!(o instanceof Coordonnees)) return false;\n\t\tCoordonnees c = (Coordonnees) o;\n\t\treturn this.ligne == c.getLigne() && this.colonne == c.getColonne();\n\t}", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof Route)) {\n return false;\n }\n Route other = (Route) object;\n if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {\n return false;\n }\n return true;\n }", "@Override\n\tpublic boolean equals(Object obj) {\n\t\tif (obj == null)\n\t\t\treturn false;\n\n\t\tif (!(obj instanceof Location))\n\t\t\treturn false;\n\n\t\tif (obj == this)\n\t\t\treturn true;\n\n\t\tLocation that = (Location) obj;\n\n\t\treturn this.map == that.map && this.y() == that.y() && this.x() == that.x();\n\t}", "@Override\n public boolean equals(Object obj){\n if(this == obj){\n return true;\n }\n else if(!(obj instanceof Row)){\n return false;\n }\n\n Row row2 = (Row)obj;\n\n return this.index == row2.index && this.spaces.equals(row2.spaces);\n }", "@Test\n public void equals_trulyEqual() {\n SiteInfo si1 = new SiteInfo(\n Amount.valueOf(12000, SiteInfo.CUBIC_FOOT),\n Amount.valueOf(76, NonSI.FAHRENHEIT),\n Amount.valueOf(92, NonSI.FAHRENHEIT),\n Amount.valueOf(100, NonSI.FAHRENHEIT),\n Amount.valueOf(100, NonSI.FAHRENHEIT),\n 56,\n Damage.CLASS2,\n Country.USA,\n \"Default Site\"\n );\n SiteInfo si2 = new SiteInfo(\n Amount.valueOf(12000, SiteInfo.CUBIC_FOOT),\n Amount.valueOf(76, NonSI.FAHRENHEIT),\n Amount.valueOf(92, NonSI.FAHRENHEIT),\n Amount.valueOf(100, NonSI.FAHRENHEIT),\n Amount.valueOf(100, NonSI.FAHRENHEIT),\n 56,\n Damage.CLASS2,\n Country.USA,\n \"Default Site\"\n );\n\n Assert.assertEquals(si1, si2);\n }", "@Override\r\n public boolean equals(Object object) {\n if (!(object instanceof Movietime)) {\r\n return false;\r\n }\r\n Movietime other = (Movietime) object;\r\n if ((this.movietimePK == null && other.movietimePK != null) || (this.movietimePK != null && !this.movietimePK.equals(other.movietimePK))) {\r\n return false;\r\n }\r\n return true;\r\n }", "public boolean alreadyOwnsIdenticalRoute(){\n City city1 = mSelectedRoute.getCity1();\n City city2 = mSelectedRoute.getCity2();\n for(int i=0; i<mUser.getClaimedRoutes().size(); i++){\n City ownedCity1 = mUser.getClaimedRoutes().get(i).getCity1();\n City ownedCity2 = mUser.getClaimedRoutes().get(i).getCity2();\n if(city1.equals(ownedCity1) && city2.equals(ownedCity2))\n return true;\n }\n return false;\n }", "@Test\n void calculateRoute() {\n GPSObject n2 = new GPSObject(\"Centenary 2\");\n Location n1 = new Location(\"Centenary 2\",\"0\",n2);\n GPSObject n3 = new GPSObject(\"Thuto 1-5\");\n Location n4 = new Location(\"Thuto 1-5\",\"1\",n3);\n Locations loc = new Locations();\n assertNotNull(roo.calculateRoute(loc));\n }", "@SuppressWarnings(\"unlikely-arg-type\")\n @Test\n public void testEquals() {\n Order order = new Order(\"Test\", LocalTime.NOON, GridCoordinate.ZERO);\n Order same = new Order(\"Test\", LocalTime.NOON, GridCoordinate.ZERO);\n Order other = new Order(\"Test\", LocalTime.MIDNIGHT, GridCoordinate.ZERO);\n Order another = new Order(\"Test\", LocalTime.NOON, GridCoordinate.of(1, 1));\n Order more = new Order(\"Test2\", LocalTime.NOON, GridCoordinate.ZERO);\n\n Assert.assertTrue(\"Two objects with the same addresses should be equal.\", order.equals(order));\n Assert.assertFalse(\"Null check.\", order.equals(null));\n Assert.assertFalse(\"Type check.\", order.equals(\"\"));\n Assert.assertFalse(\"Different order times.\", order.equals(other));\n Assert.assertFalse(\"Different customer locations.\", order.equals(another));\n Assert.assertFalse(\"Different order IDs.\", order.equals(more));\n Assert.assertTrue(\"Same values.\", order.equals(same));\n }", "@Override\r\n public boolean equals(Object that) {\r\n if (this == that) {\r\n return true;\r\n }\r\n if (that == null) {\r\n return false;\r\n }\r\n if (getClass() != that.getClass()) {\r\n return false;\r\n }\r\n TabRpf other = (TabRpf) that;\r\n return (this.getRpfId() == null ? other.getRpfId() == null : this.getRpfId().equals(other.getRpfId()))\r\n && (this.getCzId() == null ? other.getCzId() == null : this.getCzId().equals(other.getCzId()))\r\n && (this.getFpNumber() == null ? other.getFpNumber() == null : this.getFpNumber().equals(other.getFpNumber()))\r\n && (this.getSpNumber() == null ? other.getSpNumber() == null : this.getSpNumber().equals(other.getSpNumber()))\r\n && (this.getFpl() == null ? other.getFpl() == null : this.getFpl().equals(other.getFpl()))\r\n && (this.getFpCb() == null ? other.getFpCb() == null : this.getFpCb().equals(other.getFpCb()))\r\n && (this.getSpCb() == null ? other.getSpCb() == null : this.getSpCb().equals(other.getSpCb()))\r\n && (this.getSjCb() == null ? other.getSjCb() == null : this.getSjCb().equals(other.getSjCb()))\r\n && (this.getTickettypesId() == null ? other.getTickettypesId() == null : this.getTickettypesId().equals(other.getTickettypesId()))\r\n && (this.getInDate() == null ? other.getInDate() == null : this.getInDate().equals(other.getInDate()))\r\n && (this.getAutoDate() == null ? other.getAutoDate() == null : this.getAutoDate().equals(other.getAutoDate()))\r\n && (this.getRpfBak1() == null ? other.getRpfBak1() == null : this.getRpfBak1().equals(other.getRpfBak1()))\r\n && (this.getRpfBak2() == null ? other.getRpfBak2() == null : this.getRpfBak2().equals(other.getRpfBak2()))\r\n && (this.getRpfBak3() == null ? other.getRpfBak3() == null : this.getRpfBak3().equals(other.getRpfBak3()));\r\n }", "@Override\n public boolean equals(Object that) {\n if (this == that) {\n return true;\n }\n if (that == null) {\n return false;\n }\n if (getClass() != that.getClass()) {\n return false;\n }\n SocMilesBasicZt other = (SocMilesBasicZt) that;\n return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))\n && (this.getCsVin() == null ? other.getCsVin() == null : this.getCsVin().equals(other.getCsVin()))\n && (this.getCsNumber() == null ? other.getCsNumber() == null : this.getCsNumber().equals(other.getCsNumber()))\n && (this.getRowNo() == null ? other.getRowNo() == null : this.getRowNo().equals(other.getRowNo()))\n && (this.getStartSoc() == null ? other.getStartSoc() == null : this.getStartSoc().equals(other.getStartSoc()))\n && (this.getEndSoc() == null ? other.getEndSoc() == null : this.getEndSoc().equals(other.getEndSoc()))\n && (this.getChangedSoc() == null ? other.getChangedSoc() == null : this.getChangedSoc().equals(other.getChangedSoc()))\n && (this.getStartMiles() == null ? other.getStartMiles() == null : this.getStartMiles().equals(other.getStartMiles()))\n && (this.getEndMiles() == null ? other.getEndMiles() == null : this.getEndMiles().equals(other.getEndMiles()))\n && (this.getStartTime() == null ? other.getStartTime() == null : this.getStartTime().equals(other.getStartTime()))\n && (this.getEndTime() == null ? other.getEndTime() == null : this.getEndTime().equals(other.getEndTime()))\n && (this.getPaceTimemills() == null ? other.getPaceTimemills() == null : this.getPaceTimemills().equals(other.getPaceTimemills()));\n }", "public boolean isEqual(Cell a) \r\n\t{\r\n\t\tCellTicTacToe xo=(CellTicTacToe)a;\r\n if(this.tav==xo.getTav())\r\n {\r\n \t return true;\r\n }\r\n else\r\n \t return false;\r\n\t}", "public boolean equals(final Object o) {\n\t\tif (o instanceof Position) {\n\t\t\tPosition p = (Position) o;\n\n\t\t\tif ((p.i == i) && (p.j == j)) {\n\t\t\t\treturn true;\n\t\t\t} else {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t} else {\n\t\t\tthrow new RuntimeException(\"Tried to compare a Position with a \"\n\t\t\t\t\t+ o.getClass().getCanonicalName());\n\t\t}\n\t}", "public boolean equals(Position p) {\n return p.xCoord == xCoord && p.yCoord == yCoord && p.zCoord == zCoord;\n }", "public boolean coordsAreEqual(Cell anotherCell){\n return (getI() == anotherCell.getI()) && (getJ() == anotherCell.getJ());\n }", "@Test\r\n void findRouteDifferentLine() {\r\n List<Station> route = model.findRoute(9, 60);\r\n assertNotNull(route);\r\n assertEquals(10, route.size());\r\n assertEquals(\"SuffolkDowns\", route.get(0).getName());\r\n assertEquals(\"Broadway\", route.get(9).getName());\r\n }", "@Test\n\tpublic void testEqualsVerdadeiro() {\n\t\t\n\t\tassertTrue(contato1.equals(contato3));\n\t}", "public boolean equals(Object object) {\n/* 4770 */ if (this == object)\n/* */ {\n/* 4772 */ return true;\n/* */ }\n/* 4774 */ if (object != null && object.getClass() == getClass()) {\n/* */ \n/* 4776 */ VolaTile tile = (VolaTile)object;\n/* 4777 */ return (tile.getTileX() == this.tilex && tile.getTileY() == this.tiley && tile.surfaced == this.surfaced);\n/* */ } \n/* 4779 */ return false;\n/* */ }", "public boolean equals( Object other ) {\n if ( super.equals( other ) && ( other instanceof Point ) ) {\n \tPoint p = (Point)other;\n boolean flagEq = Math.abs( getX() - p.getX() ) < mute &&\n \t \t\t\t Math.abs( getY() - p.getY() ) < mute;\n if ( getCoordinateDimension() == 3 ) {\n \tflagEq = flagEq && Math.abs( getZ() - p.getZ() ) < mute;\n }\n return flagEq;\n }\n\n return false;\n }", "public boolean equals(CustomTime that) {\n return this.hour == that.hour\n && this.minute == that.minute\n && this.second == that.second;\n }", "@Override\r\n public boolean equals(Object o)\r\n {\r\n items oo = (items)o;\r\n if(this.loc_index==oo.loc_index && this.rule_number==oo.rule_number)\r\n return true;\r\n return false;\r\n }", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof CtPhieuDt)) {\n return false;\n }\n CtPhieuDt other = (CtPhieuDt) object;\n if ((this.ctdtMa == null && other.ctdtMa != null) || (this.ctdtMa != null && !this.ctdtMa.equals(other.ctdtMa))) {\n return false;\n }\n return true;\n }", "public boolean equals(Object obj) {\n if (obj == null) {\n return false;\n }\n if (this == obj) {\n return true;\n }\n if (!(obj instanceof CursorAnchorInfo)) {\n return false;\n }\n CursorAnchorInfo that = (CursorAnchorInfo) obj;\n if (hashCode() != that.hashCode() || this.mSelectionStart != that.mSelectionStart || this.mSelectionEnd != that.mSelectionEnd || this.mInsertionMarkerFlags != that.mInsertionMarkerFlags || (areSameFloatImpl(this.mInsertionMarkerHorizontal, that.mInsertionMarkerHorizontal) ^ 1) != 0 || (areSameFloatImpl(this.mInsertionMarkerTop, that.mInsertionMarkerTop) ^ 1) != 0 || (areSameFloatImpl(this.mInsertionMarkerBaseline, that.mInsertionMarkerBaseline) ^ 1) != 0 || (areSameFloatImpl(this.mInsertionMarkerBottom, that.mInsertionMarkerBottom) ^ 1) != 0 || !Objects.equals(this.mCharacterBoundsArray, that.mCharacterBoundsArray) || this.mComposingTextStart != that.mComposingTextStart || (Objects.equals(this.mComposingText, that.mComposingText) ^ 1) != 0 || this.mMatrixValues.length != that.mMatrixValues.length) {\n return false;\n }\n for (int i = 0; i < this.mMatrixValues.length; i++) {\n if (this.mMatrixValues[i] != that.mMatrixValues[i]) {\n return false;\n }\n }\n return true;\n }", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof CustomerContacter)) {\n return false;\n }\n CustomerContacter other = (CustomerContacter) object;\n if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {\n return false;\n }\n return (this.pid == other.pid && this.seq == other.seq);\n }", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof Zeitschrift)) {\n return false;\n }\n Zeitschrift other = (Zeitschrift) object;\n if ((this.zeitschriftId == null && other.zeitschriftId != null) || (this.zeitschriftId != null && !this.zeitschriftId.equals(\n other.zeitschriftId))) {\n return false;\n }\n return true;\n }", "@Override\r\n public boolean equals(Object object) {\n if (!(object instanceof PlanSeccionDetallePK)) {\r\n return false;\r\n }\r\n PlanSeccionDetallePK other = (PlanSeccionDetallePK) object;\r\n if (this.codigoEstablecimiento != other.codigoEstablecimiento) {\r\n return false;\r\n }\r\n if (this.codTitulo != other.codTitulo) {\r\n return false;\r\n }\r\n if (this.codSeccion != other.codSeccion) {\r\n return false;\r\n }\r\n if (this.codSeccionDetalle != other.codSeccionDetalle) {\r\n return false;\r\n }\r\n return true;\r\n }", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof Zamowienia)) {\n return false;\n }\n Zamowienia other = (Zamowienia) object;\n if ((this.iDZamowienia == null && other.iDZamowienia != null) || (this.iDZamowienia != null && !this.iDZamowienia.equals(other.iDZamowienia))) {\n return false;\n }\n return true;\n }", "public boolean hasEqualMapping(ViewDetallesPagos valueObject) {\r\n\r\n if (valueObject.getIDCUENTACONTABLE() != this.IDCUENTACONTABLE) {\r\n return(false);\r\n }\r\n if (this.DECOMPARENDO == null) {\r\n if (valueObject.getDECOMPARENDO() != null)\r\n return(false);\r\n } else if (!this.DECOMPARENDO.equals(valueObject.getDECOMPARENDO())) {\r\n return(false);\r\n }\r\n if (this.CODIGOCUENTA == null) {\r\n if (valueObject.getCODIGOCUENTA() != null)\r\n return(false);\r\n } else if (!this.CODIGOCUENTA.equals(valueObject.getCODIGOCUENTA())) {\r\n return(false);\r\n }\r\n if (this.NOMBRECUENTA == null) {\r\n if (valueObject.getNOMBRECUENTA() != null)\r\n return(false);\r\n } else if (!this.NOMBRECUENTA.equals(valueObject.getNOMBRECUENTA())) {\r\n return(false);\r\n }\r\n if (valueObject.getVIGENCIAINICIAL() != this.VIGENCIAINICIAL) {\r\n return(false);\r\n }\r\n if (valueObject.getVIGENCIAFINAL() != this.VIGENCIAFINAL) {\r\n return(false);\r\n }\r\n if (this.FILTROPORFECHAS == null) {\r\n if (valueObject.getFILTROPORFECHAS() != null)\r\n return(false);\r\n } else if (!this.FILTROPORFECHAS.equals(valueObject.getFILTROPORFECHAS())) {\r\n return(false);\r\n }\r\n if (valueObject.getIDTARIFA() != this.IDTARIFA) {\r\n return(false);\r\n }\r\n if (valueObject.getIDCONCEPTO() != this.IDCONCEPTO) {\r\n return(false);\r\n }\r\n if (this.NOMBRECONCEPTO == null) {\r\n if (valueObject.getNOMBRECONCEPTO() != null)\r\n return(false);\r\n } else if (!this.NOMBRECONCEPTO.equals(valueObject.getNOMBRECONCEPTO())) {\r\n return(false);\r\n }\r\n if (valueObject.getIDITEM() != this.IDITEM) {\r\n return(false);\r\n }\r\n if (valueObject.getVALORPAGO() != this.VALORPAGO) {\r\n return(false);\r\n }\r\n if (this.FECHAPAGO == null) {\r\n if (valueObject.getFECHAPAGO() != null)\r\n return(false);\r\n } else if (!this.FECHAPAGO.equals(valueObject.getFECHAPAGO())) {\r\n return(false);\r\n }\r\n if (valueObject.getVIGENCIA() != this.VIGENCIA) {\r\n return(false);\r\n }\r\n\r\n return true;\r\n }", "@Override\n public boolean equals(Object o) {\n //if the other object is null, they're not equal\n if (o == null) { return false; }\n\n //check if it's a coordinate and if so, if it's a matching coordinate\n if (o instanceof Coordinate) {\n Coordinate other = (Coordinate) o;\n return col == other.col && row == other.row;\n }\n\n return false;\n }", "public boolean equals(Object o) {\r\n\t if(o instanceof Point) {\r\n\t\t Point temp = (Point) o;\r\n\t\t long x = ((Compare2D) o).getX();\r\n\t\t long y = ((Compare2D) o).getY();\r\n\t\t if(longitude == x && latitude == y)\r\n\t\t\t return true;\r\n\t }\r\n\t return false;\r\n }", "@Override\r\n public boolean equals(Object o){\r\n boolean equals=false;\r\n if (o!=null) {\r\n equals=(this.id==((Car)o).id)&&\r\n this.currentPosition.equals(((Car)o).currentPosition)\r\n &&this.orientation==((Car)o).orientation&&this.size==((Car)o).size;\r\n }\r\n return equals;\r\n }", "@Test\n public void testGetPosition() {\n assertEquals(r1.getPosition(), new Position2D(50, 75));\n assertEquals(r2.getPosition(), new Position2D(-50, 75));\n assertEquals(r3.getPosition(), new Position2D(50, -75));\n assertEquals(r4.getPosition(), new Position2D(-50, -75));\n }", "@Test\n public void testEqualTo() {\n System.out.println(\"AbsolutePathNode - testEqualTo\");\n final AbsolutePathNode instance1 = new AbsolutePathNode();\n final AbsolutePathNode instance2 = new AbsolutePathNode();\n final TestNode testInstance = TestNode.instance;\n assertTrue(instance1.equalTo(instance2));\n assertFalse(instance1.equalTo(testInstance));\n }", "@Override\n public boolean equals(Object other) {\n return this == other || (other instanceof TdOrder && hashCode() == other.hashCode());\n }", "public boolean equals(PosicionMatriz p) {\n return this.columna == p.columna && this.fila == p.fila;\n }", "public boolean isEqual(Road r) {\n if (this.targetVertex == r.targetVertex && this.startVertex == r.startVertex || this.targetVertex == r.startVertex && this.startVertex == r.targetVertex) {\n return true;\n } else {\n return false;\n }\n }", "public boolean equals(Object o) {\n if (o == this) {\n return true;\n }\n if (o instanceof SortKey) {\n return (((SortKey) o).column == column && ((SortKey) o).sortOrder == sortOrder);\n }\n return false;\n }", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof LetrasPagoCanje)) {\n return false;\n }\n LetrasPagoCanje other = (LetrasPagoCanje) object;\n if ((this.idLetrasPagoCanje == null && other.idLetrasPagoCanje != null) || (this.idLetrasPagoCanje != null && !this.idLetrasPagoCanje.equals(other.idLetrasPagoCanje))) {\n return false;\n }\n return true;\n }", "public boolean equals(Line other) {\n if(this.getStartDot().equals(other.getStartDot()) && this.getEndDot().equals(other.getEndDot()))\n \treturn true;\n else {\n\t\t\treturn false;\n\t\t}\n\t}", "private boolean samePosition(ITarget t1, ITarget t2) {\n assert t1.getTag() == t2.getTag() : \"Programmer error; tags must match.\";\n switch (t1.getTag()) {\n case JPL_MINOR_BODY:\n case MPC_MINOR_PLANET:\n case NAMED:\n\n // SUPER SUPER SKETCHY\n // The .equals logic in NonSiderealTarget actually does what we want here, at\n // least according to the old implementation here. So we'll leave it for now.\n // This will be easier with the new model.\n return t1.equals(t2);\n\n case SIDEREAL:\n final HmsDegTarget hms1 = (HmsDegTarget) t1;\n final HmsDegTarget hms2 = (HmsDegTarget) t2;\n return hasSameCoordinates(hms1, hms2) &&\n hasSameProperMotion(hms1, hms2) &&\n hasSameTrackingDetails(hms1, hms2);\n\n default:\n throw new Error(\"Unpossible target tag: \" + t1.getTag());\n }\n }", "public final boolean locationEquals(Actor other) {\n if (location.equals(other.location)) { return true; }\n return false;\n }", "@Override\r\n public boolean equals(Object object) {\n if (!(object instanceof BizZjysxx)) {\r\n return false;\r\n }\r\n BizZjysxx other = (BizZjysxx) object;\r\n if ((this.zjkm == null && other.zjkm != null) || (this.zjkm != null && !this.zjkm.equals(other.zjkm))) {\r\n return false;\r\n }\r\n return true;\r\n }", "@Override\r\n public boolean equals(Object object) {\n if (!(object instanceof RepairmenOrders)) {\r\n return false;\r\n }\r\n RepairmenOrders other = (RepairmenOrders) object;\r\n if ((this.repCarID == null && other.repCarID != null) || (this.repCarID != null && !this.repCarID.equals(other.repCarID))) {\r\n return false;\r\n }\r\n return true;\r\n }", "@Override\n public boolean equals(Object o) {\n if ((o == null) || !(o instanceof Location)) {\n return false;\n }\n\n // Check x- and y-coordinates.\n Location other = (Location) o;\n if ((this.x == other.x) && (this.y == other.y)) {\n return true;\n }\n\n return false;\n }", "@Override\r\n public boolean collocated(Space other) {\r\n return this.row == other.getRow() &&\r\n this.col == other.getCol();\r\n }", "@Override\r\n public boolean equals(INavMeshAtom atom) {\r\n if(atom.getClass() == OffMeshPoint.class) {\r\n OffMeshPoint op = (OffMeshPoint) atom;\r\n return (op.navpointId.getStringId().equals(this.navpointId.getStringId()));\r\n }\r\n else return false;\r\n }", "public boolean equals(Object lineSegment) {\n try {\n GLineSegment temp=(GLineSegment) lineSegment;\n return(( (this.point1.equals(temp.getFirstPoint())) &&\n (this.point2.equals(temp.getSecondPoint())) ) ||\n ( (this.point1.equals(temp.getSecondPoint())) &&\n (this.point2.equals(temp.getFirstPoint())) )); \n }\n catch(Exception e) {\n return(false);\n }\n }", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof CostoActividadPK)) {\n return false;\n }\n CostoActividadPK other = (CostoActividadPK) object;\n if (this.numeroPeriodo != other.numeroPeriodo) {\n return false;\n }\n if ((this.idActividad == null && other.idActividad != null) || (this.idActividad != null && !this.idActividad.equals(other.idActividad))) {\n return false;\n }\n return true;\n }", "public boolean equals(Position b) {\n\t\treturn b != null && xCoord == b.getX() && yCoord == b.getY();\n\t}", "@Override\r\n public boolean equals(Object object) {\n if (!(object instanceof Location)) {\r\n return false;\r\n }\r\n Location other = (Location) object;\r\n if ((this.locId == null && other.locId != null) || (this.locId != null && !this.locId.equals(other.locId))) {\r\n return false;\r\n }\r\n return true;\r\n }", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof PoaReprogramacionesDetalleTiposMovPK)) {\n return false;\n }\n PoaReprogramacionesDetalleTiposMovPK other = (PoaReprogramacionesDetalleTiposMovPK) object;\n if (this.tipoMovimiento != other.tipoMovimiento) {\n return false;\n }\n if (this.reprogramacion != other.reprogramacion) {\n return false;\n }\n return true;\n }", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof Portaria)) {\n return false;\n }\n Portaria other = (Portaria) object;\n if ((this.portariaPK == null && other.portariaPK != null) || (this.portariaPK != null && !this.portariaPK.equals(other.portariaPK))) {\n return false;\n }\n return true;\n }", "private boolean correctPlacement(int[] pos) {\n for (int i = 0; i < crtStep; ++i) {\n for (int j = i + 1; j <= crtStep; ++j) {\n if (pos[i] == pos[j] || i - pos[i] == j - pos[j] || i + pos[i] == j + pos[j]) {\n return false;\n }\n }\n }\n \n return true;\n }", "@Override\n\tpublic boolean equals(Object obj) {\n if (obj == this) { \n return true; \n } \n // Check if obj is an instance of Position or not \n if (!(obj instanceof Player)) { \n return false; \n } \n // Type cast obj to \"Player\" so that we can compare the name & side attributes \n Player p = (Player) obj; \n return ( this.name == p.getName() && this.side == p.getSide() ); \n }", "@Override\n\tpublic boolean equals(Object obj) {\n\t\tif(obj instanceof StopDTO)\n\t {\n\t\t\tStopDTO temp = (StopDTO) obj;\n\t if(this.name.equals(temp.name) && this.lat == temp.lat && this.lon == temp.lon)\n\t return true;\n\t }\n\t return false;\n\t}", "public boolean equals(Object obj) {\n\n if (obj == this) {\n return true;\n }\n\n if (obj instanceof Row) {\n return ((Row) obj).table == table\n && ((Row) obj).position == position;\n }\n\n return false;\n }", "public boolean equals(Tile tile){\n\t if(tile.getLocation().equals(location))\n\t\t return true;\n\t else\n\t\t return false;\n\t}" ]
[ "0.5891131", "0.5721023", "0.5638005", "0.5604332", "0.5529913", "0.55024946", "0.54877746", "0.5480065", "0.54699695", "0.5468072", "0.5431242", "0.5426405", "0.54260385", "0.5413164", "0.539939", "0.5377084", "0.53376585", "0.53255904", "0.5301988", "0.527977", "0.5270267", "0.52666897", "0.52461696", "0.52233785", "0.520403", "0.5201042", "0.5196075", "0.51896477", "0.5176227", "0.5155827", "0.5152024", "0.51501095", "0.5137161", "0.51175994", "0.51052624", "0.50848264", "0.5078297", "0.5039824", "0.50382173", "0.5034819", "0.5029285", "0.5027902", "0.5023684", "0.5021657", "0.50171643", "0.50130767", "0.5012668", "0.5007238", "0.4997047", "0.4987659", "0.49809206", "0.49792024", "0.49732065", "0.4960627", "0.49456957", "0.49343517", "0.49203014", "0.49158114", "0.49143624", "0.49120486", "0.49110866", "0.49077746", "0.4881796", "0.48795295", "0.4878547", "0.48723394", "0.4867915", "0.4866827", "0.48635215", "0.48627195", "0.48594403", "0.48555857", "0.48423666", "0.48417822", "0.48375756", "0.48366654", "0.48358318", "0.48240516", "0.48231572", "0.48215404", "0.48192886", "0.48180902", "0.48167124", "0.4816647", "0.48164994", "0.48065194", "0.48013598", "0.47978264", "0.47957295", "0.4794435", "0.47932824", "0.47926688", "0.47883868", "0.4787332", "0.47857693", "0.4784892", "0.4783398", "0.47799763", "0.47771704", "0.47596163" ]
0.7326032
0
Constructs a SpringJmsProvider object given the name of a classpath resource (the spring application context file), and the bean names of a JMS connection factory and destination.
public SpringJmsProviderMain(String appContextClasspathResource, String connectionFactoryBean, String destinationBean, String jmsTemplateBean) { ApplicationContext context = new ClassPathXmlApplicationContext(appContextClasspathResource); this.jmsTemplate = (JmsTemplate) context.getBean(jmsTemplateBean); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public SpringJmsProvider(ApplicationContext context, String connectionFactoryBean, String destinationBean){\n this.connectionFactory = (ConnectionFactory)context.getBean(connectionFactoryBean);\n this.destination = (Destination)context.getBean(destinationBean);\n }", "public MessageDestinationFactory() {\n this.properties = new ConfigMap();\n }", "private void setupJMS(String destinationName) throws Exception\n { Look up connection factory and destination.\n //\n Context jndiContext = new InitialContext();\n\n ConnectionFactory connectionFactory = \n (ConnectionFactory)jndiContext.lookup(\"jms/ConnectionFactory\");\n \n destination = (Destination)jndiContext.lookup(destinationName);\n\n jndiContext.close();\n\n // Create JMS connection, session, and message consumer\n //\n connection = connectionFactory.createConnection();\n session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);\n consumer = session.createConsumer(destination);\n consumer.setMessageListener( this );\n connection.start();\n }", "@Bean\n JmsComponent jms() {\n ActiveMQConnectionFactory factory = new ActiveMQConnectionFactory(\"vm://localhost\");\n // Need to setTrustedPackagers for JMS because were failing to pull Order.class off the JMS queue because it's not a \"Trusted Class\".\n factory.setTrustedPackages(Arrays.asList(\"jonathandandries.example.camelinaction.riderauto.model\"));\n return JmsComponent.jmsComponentAutoAcknowledge(factory);\n }", "CPSMFactory getCPSMFactory();", "public MPSApplicationContextFactory() {\n this.encodingManager = new EncodingManager();\n\n protocolBuilder = new NamedProtocolBuilder();\n // Register the known protocols with the builder.\n ProtocolRegistry registry = new ProtocolRegistry();\n registry.register(protocolBuilder);\n }", "public MessageSourceHolder(String... classPathResourcePaths) {\n Properties globalProperties = new Properties();\n try {\n globalProperties.load(MessageSourceHolder.class.getResourceAsStream(\"/resources/global.properties\"));\n } catch (IOException e1) {\n throw new CommonPropertiesTechnicalRuntimeException();\n }\n String locale = globalProperties.getProperty(ConfigurationKeys.LOCALE);\n \n for (String path : classPathResourcePaths) {\n Properties resMessages = new Properties();\n String fullPath = path + \"_\" + locale.toLowerCase() + \".properties\";\n LOG.debug(\"Load Property file {}\", fullPath);\n try (InputStream is = MessageSourceHolder.class.getResourceAsStream(fullPath)) {\n resMessages.load(is);\n } catch (IOException e) {\n throw new CommonPropertiesTechnicalRuntimeException();\n }\n messages.putAll(resMessages);\n }\n }", "@Bean(name = \"messageSource\")\n public DistributedResourceBundleMessageSource messageSource() {\n return new DistributedResourceBundleMessageSource();\n }", "public List<MessageSource> createMessageSources(){\n\n List<MessageSource> messageSourceList = new ArrayList<>();\n\n String messageSourceConfig = Configurations.map.getProperty(\"messageSourceChannels\");\n String[] sourceConfigArray = messageSourceConfig.split(\",\");\n\n for(String sourceConfig : sourceConfigArray) {\n MessageSource messageSource = null;\n\n // there is only file message source option for instance, but it's extendable\n if(sourceConfig.equals(\"file\")){\n messageSource = new FileSource();\n }\n\n if(messageSource != null){\n messageSourceList.add(messageSource);\n }\n }\n\n if(messageSourceList.size() == 0){\n return null;\n }\n\n return messageSourceList;\n }", "@Bean\n ActiveMQConnectionFactory connectionFactory() {\n ActiveMQConnectionFactory connectionFactory = new ActiveMQConnectionFactory(BROKER_URL);\n return connectionFactory;\n }", "@Bean\n public ConnectionFactory connectionFactory(){\n ActiveMQConnectionFactory activeMQConnectionFactory = new ActiveMQConnectionFactory();\n activeMQConnectionFactory.setBrokerURL(brokerUrl);\n activeMQConnectionFactory.setUserName(brokerUsername);\n activeMQConnectionFactory.setPassword(brokerPassword);\n return activeMQConnectionFactory;\n }", "public MailProvider(ProviderProperties providerProperties) {\n super(providerProperties);\n }", "@Bean\n public ResourceBundleMessageSource messageSource() {\n \tResourceBundleMessageSource messageSource =new ResourceBundleMessageSource();\n \t//messageSource.setBasename(\"classpath:messages\");\n \tmessageSource.setBasename(\"messages\");\n \treturn messageSource;\n }", "@Bean\r\n public MessageSource messageSource() {\r\n\r\n ResourceBundleMessageSource messageSource = new ResourceBundleMessageSource();\r\n messageSource.setBasename(\"messages\");\r\n\r\n return messageSource;\r\n }", "@Autowired\n\tpublic MyUtil(MessageSource messageSource){\n\t\tMyUtil.messageSource=messageSource;\n\t}", "private SpringApplicationContextProvider() {\r\n\t}", "public interface MessageResourceAdapter extends ResourceAdapter {\n\n /**\n */\n ActiveMQConnection makeConnection(ActiveMQConnectionRequestInfo info) throws JMSException;\n\n /**\n * @param activationSpec\n */\n ActiveMQConnection makeConnection(MessageActivationSpec activationSpec) throws JMSException;\n\n /**\n * @return bootstrap context\n */\n BootstrapContext getBootstrapContext();\n\n /**\n */\n String getBrokerXmlConfig();\n\n /**\n * @return Returns the info.\n */\n ActiveMQConnectionRequestInfo getInfo();\n\n}", "@Bean(name = \"activeMqJmsListenerContainerFactory\")\r\n\tpublic JmsListenerContainerFactory<?> activeMqJmsListenerContainerFactory(ConnectionFactory connectionFactory,\r\n\t\t\tDefaultJmsListenerContainerFactoryConfigurer configurer) {\r\n\t\tDefaultJmsListenerContainerFactory factory = new DefaultJmsListenerContainerFactory();\r\n\t\tconfigurer.configure(factory, connectionFactory);\r\n\t\tfactory.setMessageConverter(jacksonJmsMessageConverter());\r\n\t\treturn factory;\r\n\t}", "@Bean\n public JmsListenerContainerFactory<?> jmsListenerContainerFactory() {\n DefaultJmsListenerContainerFactory factory = new DefaultJmsListenerContainerFactory();\n factory.setConnectionFactory(connectionFactory());\n factory.setConcurrency(\"1-1\");\n // Potrebno je obezbediti publish/subscribe za topic. Nije neophodno za queue.\n // factory.setPubSubDomain(true);\n return factory;\n }", "@Override\n protected final void initializeSpecific() {\n initializeSpringSpecific();\n\n // Once the subclasses have had their opportunity, compute configurations belonging to SpringTemplateEngine\n super.initializeSpecific();\n\n final MessageSource messageSource =\n this.templateEngineMessageSource == null ? this.messageSource : this.templateEngineMessageSource;\n\n final IMessageResolver messageResolver;\n if (messageSource != null) {\n final SpringMessageResolver springMessageResolver = new SpringMessageResolver();\n springMessageResolver.setMessageSource(messageSource);\n messageResolver = springMessageResolver;\n } else {\n messageResolver = new StandardMessageResolver();\n }\n\n super.setMessageResolver(messageResolver);\n\n }", "private void initializeProducers(ComponentContext context) {\n BrokerHost rfHost;\n Properties prop = MQUtil.getProp(context);\n if (prop == null) {\n log.error(\"RabbitMQ configuration file not found...\");\n return;\n }\n try {\n correlationId = prop.getProperty(SENDER_COR_ID);\n rfHost = new BrokerHost(MQUtil.getMqUrl(\n prop.getProperty(SERVER_PROTO),\n prop.getProperty(SERVER_UNAME),\n prop.getProperty(SERVER_PWD),\n prop.getProperty(SERVER_ADDR),\n prop.getProperty(SERVER_PORT),\n prop.getProperty(SERVER_VHOST)));\n\n manageSender = registerProducer(rfHost,\n MQUtil.rfProducerChannelConf(\n prop.getProperty(SENDER_EXCHG),\n prop.getProperty(ROUTE_KEY),\n prop.getProperty(SENDER_QUEUE)),\n msgOutQueue);\n } catch (Exception e) {\n throw new IllegalStateException(e);\n }\n manageSender.start();\n }", "@Bean\n\tpublic ResourceBundleMessageSource messageSource() {\n\t\tResourceBundleMessageSource messageSource = new ResourceBundleMessageSource();\n\t\tmessageSource.setBasename(\"messages\");\n\t\t// use this setting to apply consistent single-quote escaping to all messages \n\t\tmessageSource.setAlwaysUseMessageFormat( true );\n\t\t\n\t\treturn messageSource;\n\t}", "@Bean\n public MessageSource messageSource() {\n ResourceBundleMessageSource messageSource = new ResourceBundleMessageSource();\n messageSource.setBasename(\"messages\");\n return messageSource;\n }", "public static ServiceProvider createServiceProvider() {\n \t//return new ActiveMQProvider();\n \treturn new RSPServiceProvider();\n }", "public interface JcrContextFactory {\n /**\n * Create a JNDI naming context from the supplied connection properties.\n * \n * @param properties the connection properties; may be null or empty\n * @return the naming context; may not be null\n * @throws NamingException if there is a problem creating or obtaining the naming context\n */\n Context createContext( Properties properties ) throws NamingException;\n }", "@Bean\n\tpublic ResourceBundleMessageSource messageSource() {\n\t\tResourceBundleMessageSource source = new ResourceBundleMessageSource();\n\t\t/*\n\t\t * By default, Spring will try to find messages_XX.properties under\n\t\t * src/main/resources. To change such location we need to call\n\t\t * setBasenames. This indicates that all messagesXXX will be under i18n\n\t\t * folder(NOT i18n/messages/messages_XXXX)\n\t\t */\n\t\tsource.setBasenames(\"i18n/messages\");\n\t\tsource.setUseCodeAsDefaultMessage(true);\n\t\tsource.setDefaultEncoding(StandardCharsets.UTF_8.name());\n\t\tlog.info(\"Setting message source \" + source.toString());\n\t\treturn source;\n\t}", "@Bean(name = \"messageSource\")\n\tpublic ReloadableResourceBundleMessageSource messageSource() {\n\t\tReloadableResourceBundleMessageSource messageBundle = new ReloadableResourceBundleMessageSource();\n\t\tmessageBundle.setBasename(\"classpath:messages/messages\");\n\t\tmessageBundle.setDefaultEncoding(\"UTF-8\");\n\t\tLocaleContextHolder.setLocale(Locale.US);\n\t\treturn messageBundle;\n\t}", "@Bean\r\n\tpublic MessageSource messageSource() {\r\n\t\tResourceBundleMessageSource messageSource = new ResourceBundleMessageSource();\r\n\r\n\t\tmessageSource.setBasenames(\"messages\");\r\n\t\tmessageSource.setDefaultEncoding(\"UTF-8\");\r\n\r\n\t\treturn messageSource;\r\n\t}", "@Bean(\"messageSource\")\n\tpublic MessageSource messageSource() {\n\t\tReloadableResourceBundleMessageSource messageSource = new ReloadableResourceBundleMessageSource();\n\t\tmessageSource.setBasename(\"classpath:strings\");\n\t\tmessageSource.setDefaultEncoding(\"UTF-8\");\n\t\tmessageSource.setUseCodeAsDefaultMessage(true);\n\t\treturn messageSource;\n\t}", "public static Object getFactory(String propName, Hashtable<?, ?> env, Context ctx, String classSuffix,\n String defaultPkgPrefix) throws NamingException {\n\n // Merge property with provider property and supplied default\n String facProp = getProperty(propName, env, ctx, true);\n if (facProp != null)\n facProp += (\":\" + defaultPkgPrefix);\n else\n facProp = defaultPkgPrefix;\n\n // Cache factory based on context class loader, class name, and\n // property val\n ClassLoader loader = helper.getContextClassLoader();\n String key = classSuffix + \" \" + facProp;\n\n Map<String, WeakReference<Object>> perLoaderCache = null;\n synchronized (urlFactoryCache) {\n perLoaderCache = urlFactoryCache.get(loader);\n if (perLoaderCache == null) {\n perLoaderCache = new HashMap<>(11);\n urlFactoryCache.put(loader, perLoaderCache);\n }\n }\n\n synchronized (perLoaderCache) {\n Object factory = null;\n\n WeakReference<Object> factoryRef = perLoaderCache.get(key);\n if (factoryRef == NO_FACTORY) {\n return null;\n } else if (factoryRef != null) {\n factory = factoryRef.get();\n if (factory != null) { // check if weak ref has been cleared\n return factory;\n }\n }\n\n // Not cached; find first factory and cache\n StringTokenizer parser = new StringTokenizer(facProp, \":\");\n String className;\n while (factory == null && parser.hasMoreTokens()) {\n className = parser.nextToken() + classSuffix;\n try {\n // System.out.println(\"loading \" + className);\n factory = helper.loadClass(className, loader).newInstance();\n } catch (InstantiationException e) {\n NamingException ne = new NamingException(\"Cannot instantiate \" + className);\n ne.setRootCause(e);\n throw ne;\n } catch (IllegalAccessException e) {\n NamingException ne = new NamingException(\"Cannot access \" + className);\n ne.setRootCause(e);\n throw ne;\n } catch (Exception e) {\n // ignore ClassNotFoundException, IllegalArgumentException,\n // etc.\n }\n }\n\n // Cache it.\n perLoaderCache.put(key, (factory != null) ? new WeakReference<>(factory) : NO_FACTORY);\n return factory;\n }\n }", "@Bean\n public MessageSource messageSource(){\n ResourceBundleMessageSource resourceBundleMessageSource = new ResourceBundleMessageSource();\n resourceBundleMessageSource.setBasenames(\"/messages\");\n return resourceBundleMessageSource;\n }", "public ClientConnectionFactoryWrapper getManagedDataSource(Map configMap,\n List<ConfigProperty> props) throws DataSourceCreateException {\n Object cf = null;\n ManagedConnectionFactory mcf = null;\n ConfiguredDataSourceProperties configs = createDataSourceProperties(configMap);\n if (configs.getMCFClass() == null) {\n logger.error(\n \"DataSourceFactory::getManagedDataSource:Managed Connection factory class is not available\");\n throw new DataSourceCreateException(\n \"DataSourceFactory::getManagedDataSource:Managed Connection factory class is not available\");\n } else {\n try {\n Class cl = ClassPathLoader.getLatest().forName(configs.getMCFClass());\n mcf = (ManagedConnectionFactory) cl.newInstance();\n invokeAllMethods(cl, mcf, props);\n } catch (Exception ex) {\n logger.error(String.format(\n \"DataSourceFactory::getManagedDataSource: Exception in creating managed connection factory. Exception string, %s\",\n ex));\n throw new DataSourceCreateException(\n String.format(\n \"DataSourceFactory::getManagedDataSource: Exception in creating managed connection factory. Exception string, %s\",\n ex));\n }\n }\n // Initialize the managed connection factory class\n // Instantiate a connection manager with the managed-conn-facory-class\n // and generate a connection pool.\n Object cm = null;\n if (configs.getMCFClass().equals(\"org.apache.persistence.connection.internal.ConnFactory\")) {\n cm = new FacetsJCAConnectionManagerImpl(mcf, configs);\n } else {\n cm = new JCAConnectionManagerImpl(mcf, configs);\n }\n try {\n cf = mcf.createConnectionFactory((ConnectionManager) cm);\n } catch (Exception ex) {\n logger.error(\n \"DataSourceFactory::getManagedDataSource: Exception in creating managed connection factory. Exception string:{}\",\n ex.toString());\n throw new DataSourceCreateException(\n String.format(\n \"DataSourceFactory::getManagedDataSource: Exception in creating managed connection factory. Exception string, %s\",\n ex));\n }\n return new ClientConnectionFactoryWrapper(cf, cm);\n }", "@Bean\n\tpublic ResourceBundleMessageSource messageSource() {\n\n\t\tSystem.out.println(\"\\n\" + \"execution is reaching messageSource()\");\n\t\tResourceBundleMessageSource messageSource = new ResourceBundleMessageSource();\n\t\tmessageSource.setBasename(\"Messages\");\n\t\treturn messageSource;\n\t}", "private NamedQueueClient(Context context,String jndiUrl, String name) throws \n MessageServiceException {\n try {\n context = new InitialContext();\n this.jndiUrl = jndiUrl;\n this.name = name;\n } catch (Exception ex) {\n throw new MessageServiceException(\n \"Failed to instanciate the NamedQueueClient : \" + \n ex.getMessage(),ex);\n }\n }", "protected void populateExtranInfoAndCreateFactory() throws MessageBusException {\n\t\tString filePath = null;\n\n\t\tfilePath = locateFile(\"MessageBus.properties\");\n\t\tif (filePath != null) {\n\t\t\tFile propertyFile = new File(filePath);\n\t\t\tif (propertyFile.exists()) {\n\t\t\t\tProperties mbProperty = loadPropertiesFile(filePath);\n\t\t\t\tconnectionType = mbProperty.getProperty(\"connectionType\");\n\t\t\t\t// If not found in the property file then assume Queue\n\t\t\t\tif (null == connectionType) {\n\t\t\t\t\tconnectionType = IMessageBusConnection.DEFAULT_CONNECTION_TYPE;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tuserName = mbProperty.getProperty(\"userName\");\n\t\t\t\tpassword = mbProperty.getProperty(\"password\");\n\t\t\t\tcertPath = mbProperty.getProperty(\"certPath\");\n\t\t\t\tcertPassword = mbProperty.getProperty(\"certPassword\");\n\n\t\t\t\tif(certPath == null || certPassword == null){\n\t\t\t\t\tthrow new MessageBusException(\"ERROR :: certPath or certPassword is missing from MessageBus.properties\");\n\t\t\t\t}\n\t\t\t\t\n\t\t\t} else {\n\t\t\t\tthrow new MessageBusException(\"ERROR :: MessageBus.properties is missing from Classapth\");\n\t\t\t}\n\t\t} else {\n\t\t\tthrow new MessageBusException(\"ERROR :: MessageBus.properties is missing from Classapth\");\n\t\t}\n\t\tcreateFactory();\n\t}", "public interface ConnectionFactory\r\n{\r\n /**\r\n * Create the ManagedConnection. \r\n * <b>Only used by ConnectionManager so do not call this.</b>\r\n * @param ec ExecutionContext that the connection is bound to during its lifecycle (if any)\r\n * @param transactionOptions the Transaction options this connection will be enlisted to, null if non existent\r\n * @return The ManagedConnection.\r\n */\r\n ManagedConnection createManagedConnection(ExecutionContext ec, Map<String, Object> transactionOptions);\r\n\r\n /**\r\n * Release any resources that have been allocated.\r\n */\r\n void close();\r\n\r\n /**\r\n * Type of resource that this ConnectionFactory represents. See ConnectionResourceType.\r\n * @return Resource type (\"JTA\", \"RESOURCE_LOCAL\")\r\n */\r\n String getResourceType();\r\n\r\n /**\r\n * Accessor for the resource name (e.g \"jdbc/tx\").\r\n * @return The resource name\r\n */\r\n String getResourceName();\r\n}", "public interface GcJdbcConnectionProvider {\n\n /**\n * if the provider requires jdbc data in the subject.properties\n * @return true if provider requires data in subject.properties\n */\n public boolean requiresJdbcConfigInSourcesXml();\n \n /** \n * init the pool \n * @param properties \n * @param sourceId mainly for logging\n * @param driver driver\n * @param maxActive max active connection if pool\n * @param defaultMaxActive if max active is needed, and blank, then use this\n * @param maxIdle max idle connections if pool\n * @param defaultMaxIdle if max is needed, and blank, then use this\n * @param maxWaitSeconds max wait if pool empty in seconds. -1 means long time\n * @param defaultMaxWaitSeconds if max wait is needed, and blank, then use this, -1 mean long time\n * @param dbUrl jdbc url of the database\n * @param dbUser user to login to the database\n * @param dbPassword password for the database (unencrypted)\n * @param readOnly if conn should be readonly\n * @param readOnlyDefault default if not specified and needed\n * @param jdbcConfigId if blank or \"grouper\" then its the grouper database, otherwise its the configId\n * in the grouper-loader.properties database entry\n * @throws SourceUnavailableException if something is not right or not available\n */\n public void init(Properties properties, String sourceId, String driver, Integer maxActive, int defaultMaxActive, Integer maxIdle, int defaultMaxIdle,\n Integer maxWaitSeconds, int defaultMaxWaitSeconds, String dbUrl, String dbUser, \n String dbPassword, Boolean readOnly, boolean readOnlyDefault, String jdbcConfigId);\n \n /**\n * get a connection (dont close this when done, just call \"doneWithConnection()\"\n * @return the connection\n * @throws SQLException if there is a problem\n */\n public GcJdbcConnectionBean connectionBean() throws SQLException;\n \n}", "public Object lookup()\r\n {\n if (applicationInstance != null)\r\n return applicationInstance;\r\n\r\n ApplicationContext appContext = WebApplicationContextUtils.getWebApplicationContext(flex.messaging.FlexContext.getServletConfig().getServletContext());\r\n if (appContext == null)\r\n {\r\n if (Log.isError())\r\n Log.getLogger(\"Configuration\").error(\r\n \"SpringFactory - not able to look up the WebApplicationContext for Spring. Check your web.xml to ensure Spring is installed properly in this web application.\");\r\n return null;\r\n }\r\n String beanName = getSource();\r\n\r\n try\r\n {\r\n Object inst;\r\n if (appContext.isSingleton(beanName))\r\n {\r\n if (Log.isDebug())\r\n Log.getLogger(\"Configuration\").debug(\r\n \"SpringFactory creating singleton component with spring id: \" + beanName + \" for destination: \" + getId());\r\n // We have a singleton instance but no one has initialized it yet.\r\n // We need to sync to prevent two threads from potentially initializing\r\n // the instance at the same time and to ensure we only return\r\n // initialized instances.\r\n synchronized (this)\r\n {\r\n // Someone else got to this before us\r\n if (applicationInstance != null)\r\n return applicationInstance;\r\n inst = appContext.getBean(beanName);\r\n if (inst instanceof FlexConfigurable)\r\n ((FlexConfigurable) inst).initialize(getId(), getProperties());\r\n applicationInstance = inst;\r\n }\r\n }\r\n else\r\n {\r\n if (Log.isDebug())\r\n Log.getLogger(\"Configuration\").debug(\r\n \"SpringFactory creating non-singleton component with spring id: \" + beanName + \" for destination: \" + getId());\r\n inst = appContext.getBean(beanName);\r\n if (inst instanceof FlexConfigurable)\r\n ((FlexConfigurable) inst).initialize(getId(), getProperties());\r\n }\r\n return inst;\r\n }\r\n catch (NoSuchBeanDefinitionException nexc)\r\n {\r\n ServiceException e = new ServiceException();\r\n String msg = \"Spring service named '\" + beanName + \"' does not exist.\";\r\n e.setMessage(msg);\r\n e.setRootCause(nexc);\r\n e.setDetails(msg);\r\n e.setCode(\"Server.Processing\");\r\n throw e;\r\n }\r\n catch (BeansException bexc)\r\n {\r\n ServiceException e = new ServiceException();\r\n String msg = \"Unable to create Spring service named '\" + beanName + \"' \";\r\n e.setMessage(msg);\r\n e.setRootCause(bexc);\r\n e.setDetails(msg);\r\n e.setCode(\"Server.Processing\");\r\n throw e;\r\n }\r\n }", "private MessageConsumer getMessageConsumer(SynapseConfiguration configuration, String processorName) {\n MessageProcessor processor = configuration.getMessageProcessors().get(processorName);\n String messageStoreName = processor.getMessageStoreName();\n return configuration.getMessageStore(messageStoreName).getConsumer();\n }", "public void initialize() {\r\n\r\n\t\t/** URL of the ActiveMQ broker, prepended by transport protocol **/\r\n\t\tString brokerUrl = config.getConfig().getString(\"broker_url\");\r\n\r\n\t\t/** Topic to subscribe to for receiving access to all notifications **/\r\n\t\tString topicName = config.getConfig().getString(\"topic\");\r\n\r\n\t\t/** Username for authenticating with the ActiveMQ broker **/\r\n\t\tString userName = config.getConfig().getString(\"user\");\r\n\r\n\t\t/** The password corresponding to the username **/\r\n\t\tString password = config.getConfig().getString(\"password\");\r\n\r\n\t\t// Creates a connection\r\n\t\tActiveMQSslConnectionFactory connectionFactory = new ActiveMQSslConnectionFactory(\r\n\t\t\t\tbrokerUrl);\r\n\r\n\t\t// Setting the trust manager to the connection factory\r\n\t\tconnectionFactory.setKeyAndTrustManagers(null, trustedCerts,\r\n\t\t\t\tnew SecureRandom());\r\n\t\tconnectionFactory.setWatchTopicAdvisories(false);\r\n\r\n\t\ttry {\r\n\t\t\t\r\n\t\t\tif (logger.isDebugEnabled()){\r\n\t\t\t\tlogger.debug(\"creating connection to \" + brokerUrl);\r\n\t\t\t}\r\n\t\t\t// Connect to the broker\r\n\t\t\tConnection connection = connectionFactory.createConnection(\r\n\t\t\t\t\tuserName, password);\r\n\r\n\t\t\t// Creating session for sending messages\r\n\t\t\tsession = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);\r\n\t\t\tconnection.start();\r\n\r\n\t\t\t// Creating the topic (i.e. creating a link to the already existing\r\n\t\t\t// one on the broker)\r\n\t\t\tTopic topic = session.createTopic(topicName);\r\n\r\n\t\t\t// MessageConsumer is used for receiving (consuming) messages from\r\n\t\t\t// the topic (above given threshold)\r\n\t\t\tMessageConsumer consumer = session.createConsumer(topic);\r\n\t\t\tconsumer.setMessageListener(this);\r\n\r\n\t\t\tif (logger.isDebugEnabled()) {\r\n\t\t\t\tlogger.debug(\"Connection to Notification with Id \"\r\n\t\t\t\t\t\t+ connection.getClientID() + \" Listening for messages\");\r\n\t\t\t}\r\n\r\n\t\t} catch (JMSException e) {\r\n\t\t\tsession = null;\r\n\t\t\tlogger.error(\"[JMS Exception] \" + e.getMessage());\r\n\t\t}\r\n\t}", "public UMOManagementContext configure(String[] configResources, Properties startupProperties)\n throws ConfigurationException\n {\n try\n {\n MuleApplicationContext context = new MuleApplicationContext(new String[]{getDefaultConfigResource()});\n managementContext = context.getManagementContext();\n MuleServer.setManagementContext(managementContext);\n\n // Load startup properties.\n Registry registry = RegistryContext.getOrCreateRegistry();\n try\n {\n registry.registerObjects(startupProperties);\n }\n catch (RegistrationException e)\n {\n throw new ConfigurationException(e);\n }\n\n for (int i = 0; i < configResources.length; i++)\n {\n String configResource = configResources[i];\n scriptComponent.setScriptFile(configResource);\n scriptComponent.initialise();\n Bindings ns = scriptComponent.getScriptEngine().createBindings();\n populateBindings(ns);\n scriptComponent.runScript(ns);\n }\n\n if (!managementContext.isInitialised() && !managementContext.isInitialising())\n {\n managementContext.initialise();\n }\n\n if (System.getProperty(MuleProperties.MULE_START_AFTER_CONFIG_SYSTEM_PROPERTY, \"true\")\n .equalsIgnoreCase(\"true\") && isStartContext())\n {\n if (!managementContext.isStarted())\n {\n managementContext.start();\n }\n }\n\n }\n catch (Exception e)\n {\n throw new ConfigurationException(e);\n }\n return managementContext;\n }", "protected ConnectionProvider createConnectionProviderIfNotSupplied() {\n\t\tif (connectionProviderSupplier != null) {\n\t\t\treturn connectionProviderSupplier.get();\n\t\t}\n\t\treturn new CoreConnectionPool();\n\t}", "public UniqueResourcesAndLocations() {\n this.context = new ClassPathXmlApplicationContext(\"spring-dao.xml\");\n this.jtemp = (JdbcTemplate)context.getBean(\"jt\");\n\t}", "public static MasterKeyProvider<KmsMasterKey> initializeKeyProvider(\n String cmkArns, Region currentRegion) {\n return initializeKeyProvider(splitArns(cmkArns), currentRegion);\n }", "public interface JmsSenderTemplate {\n\n\t/**\n\t * Executes an application-level call-back within the managed session.\n\t *\n\t * @param callback\n\t * @throws JMSException\n\t */\n\tvoid executeCallback(JmsSenderTemplateCallback callback) throws JMSException;\n\n\t/**\n\t * Sends a TextMessage.\n\t *\n\t * @param content The text as a string.\n\t * @throws JMSException\n\t */\n\tvoid sendTextMessage(String content) throws JMSException;\n\n\t/**\n\t * Sends a MapMessage.\n\t *\n\t * @param content The Map to get the content from.\n\t *\n\t * @throws JMSException\n\t */\n\t@SuppressWarnings(\"rawtypes\")\n\tvoid sendMapMessage(Map content) throws JMSException;\n\n\t/**\n\t * Sends an ObjectMessage.\n\t *\n\t * @param content The serializable object content.\n\t * @throws JMSException\n\t */\n\tvoid sendObjectMessage(Serializable content)\n\t\t\tthrows JMSException;\n\n\t/**\n\t * Sends a ByteMessage.\n\t *\n\t * @param content The content as a byte array.\n\t * @throws JMSException\n\t */\n\tvoid sendBytesMessage(byte[] content) throws JMSException;\n\n}", "@Override\n public void configureMessageBroker(MessageBrokerRegistry registry) {\n registry.setApplicationDestinationPrefixes(\"/app\"); //route messages to /app to Spring app message handling methods (see ChatController)\n registry.enableSimpleBroker(\"/topic/\", \"/queue/\"); //route messages to /topic to the in-memory Message Broker\n }", "@PostConstruct\n private void fixJMSTemplate() {\n CachingConnectionFactory ccf = new CachingConnectionFactory();\n ccf.setTargetConnectionFactory(jmsTemplate.getConnectionFactory());\n jmsTemplate.setConnectionFactory(ccf);\n jmsTemplate.setPubSubDomain(true);\n jmsTemplate.setTimeToLive(24*60*60*1000);\n }", "@Bean\n\tpublic ReloadableResourceBundleMessageSource messageSource() {\n\t\tReloadableResourceBundleMessageSource r = new ReloadableResourceBundleMessageSource();\n\t\tr.setBasename(\"classpath:message\");\n\t\tr.setDefaultEncoding(\"UTF-8\");\n\t\treturn r;\n\t}", "SMSProvider findSMSProvidersBySMSProviderName(String smsProviderName);", "TopicMessageStore createTopicMessageStore(ActiveMQTopic destination) throws IOException;", "public interface Provider {\n //Connection connect(String url, java.util.Properties info)\n Service newService();\n}", "public static void main(String[] args) {\n BeanFactory beanFactory = new ClassPathXmlApplicationContext(\"/com/bridgelabz/Spring/bean.xml\"); \n /* beans are loaded as soon as bean factory instance is created but \n * the beans are created only when getBean() method is called.\n * getBean: Return an instance, which may be shared*/\n GreetingMessage obj = (GreetingMessage) beanFactory.getBean(\"greetingMessage\"); \n String message = obj.getMessage();\n System.out.println(message);\n }", "public TemplateAvailabilityProviders(ClassLoader classLoader)\n/* */ {\n/* 87 */ Assert.notNull(classLoader, \"ClassLoader must not be null\");\n/* */ \n/* 89 */ this.providers = SpringFactoriesLoader.loadFactories(TemplateAvailabilityProvider.class, classLoader);\n/* */ }", "Consumer createConsumer(String consumerId, String consumerName) throws RegistrationException;", "MessageStore createQueueMessageStore(ActiveMQQueue destination) throws IOException;", "@Override\n public void init(ConfigurationContext cfgCtx, TransportOutDescription transportOut)\n throws AxisFault {\n super.init(cfgCtx, transportOut);\n rabbitMQConnectionFactoryManager = new RabbitMQConnectionFactoryManager(transportOut);\n log.info(\"RabbitMQ AMQP Transport Sender initialized...\");\n\n }", "public ESocketThreadNew() {\n ac = new FileSystemXmlApplicationContext(\"classpath*:applicationContext.xml\");\n if (ESocketThreadNew.service == null) {\n ESocketThreadNew.service = ac.getBean(VnsAuthorGETServiceNew.class);\n }\n if (ESocketThreadNew.resultService == null) {\n ESocketThreadNew.resultService = ac.getBean(VnsResultService.class);\n }\n if (ESocketThreadNew.vnsPulseService == null) {\n ESocketThreadNew.vnsPulseService = ac.getBean(VnsPulseService.class);\n }\n if (ESocketThreadNew.locationService == null) {\n ESocketThreadNew.locationService = ac.getBean(VnsLocationService.class);\n }\n }", "public Object createConnectionFactory() throws ResourceException {\n throw new ResourceException(\"Vert.x JCA adapter not supported in non-managed environment\");\n }", "protected CacheManagerPeerProvider createManuallyConfiguredCachePeerProvider(Properties properties) {\r\n String urls = PropertyUtil.extractAndLogProperty(JNDI_URLS, properties);\r\n if (urls == null || urls.length() == 0) {\r\n throw new CacheException(JNDI_URLS + \" must be specified when peerDiscovery is manual\");\r\n }\r\n\r\n boolean stashContexts = isStashContexts(properties);\r\n boolean stashRemoteCachePeers = isStashRemoteCachePeers(properties);\r\n\r\n JNDIManualRMICacheManagerPeerProvider jndiPeerProvider = new JNDIManualRMICacheManagerPeerProvider(stashContexts,\r\n stashRemoteCachePeers);\r\n urls = urls.trim();\r\n StringTokenizer stringTokenizer = new StringTokenizer(urls, PayloadUtil.URL_DELIMITER);\r\n while (stringTokenizer.hasMoreTokens()) {\r\n String jndiUrl = stringTokenizer.nextToken();\r\n jndiUrl = jndiUrl.trim();\r\n jndiPeerProvider.registerPeer(jndiUrl);\r\n if (LOG.isDebugEnabled()) {\r\n LOG.debug(\"Registering peer \" + jndiUrl);\r\n }\r\n }\r\n return jndiPeerProvider;\r\n }", "MessageReceiver createReceiver(String topic) throws MessagingException;", "protected MXBeanMappingFactory() {}", "public JGitFileSystemProvider() {\n this(new ConfigProperties(System.getProperties()),\n Executors.newCachedThreadPool(new DescriptiveThreadFactory()));\n }", "public static NamedQueueClient create(Context context,String jndiUrl, \n String name) throws MessageServiceException {\n return new NamedQueueClient(context,jndiUrl,name);\n }", "Provider createProvider();", "public DefaultConnectionProvider() {\n loadProperties();\n }", "@Bean\n public MessageSource messageSource() {\n ResourceBundleMessageSource messageSource = new ResourceBundleMessageSource();\n messageSource.setBasename(\"i18n/messages\");\n messageSource.setUseCodeAsDefaultMessage(true);\n return messageSource;\n }", "public ManagedHttpClientConnectionFactory(HttpMessageWriterFactory<HttpRequest> requestWriterFactory, HttpMessageParserFactory<HttpResponse> responseParserFactory) {\n/* 96 */ this(requestWriterFactory, responseParserFactory, null, null);\n/* */ }", "@Bean\n public SimpleMessageListenerContainer containeraaaaa(@Qualifier(\"myqueue\") Queue queue,\n ConnectionFactory connectionFactory) {\n SimpleMessageListenerContainer cont = new SimpleMessageListenerContainer(connectionFactory);\n cont.addQueues(queue);\n return cont;\n }", "public TemplateAvailabilityProviders(ApplicationContext applicationContext)\n/* */ {\n/* 79 */ this(applicationContext == null ? null : applicationContext.getClassLoader());\n/* */ }", "public MessageService(PlatformTransactionManager transactionManager) {\n this.transactionTemplate = new TransactionTemplate(transactionManager);\n }", "public SmsServiceProvider(int clockFormat, ConnectionInfo imap, ConnectionInfo smtp, String subsOutputFile) throws MessagingException, TransformerConfigurationException\r\n\t{\r\n\t\tsuper();\r\n\r\n\t\tif (clockFormat == Time.MILITARY_CLOCK_FORMAT)\r\n\t\t\tTime.setMilitaryFormat();\r\n\r\n\t\telse\r\n\t\t\tTime.setDefaultFormat();\r\n\r\n\t\tthis.server = new EmailServer(imap, smtp);\r\n\t\tthis.subscription = new AddressSet(subsOutputFile);\r\n\t\tthis.log = new LogBook();\r\n\t\tthis.populateFilter();\r\n\t}", "public interface PoolingQueueService {\n\n void setIMessageProcessor(final IMessageProcessor iMessageProcessor) throws PoolingQueueException;\n\n MessageMapper cconn(String serialNumber, String contentType, MessageMapper messageMapper);\n\n MessageMapper cpull(String serialNumber);\n\n MessageMapper cpush(String serialNumber, String applicationID, String broadcast, String contentType, MessageMapper messageMapper);\n\n MessageMapper aconn(String serialNumber, String applicationID, String contentType, MessageMapper messageMapper);\n\n MessageMapper apull(String serialNumber, String applicationID, String messageAmount);\n\n MessageMapper apush(String serialNumber, String applicationID, String contentType, MessageMapper messageMapper);\n\n}", "public static MasterKeyProvider<KmsMasterKey> initializeKeyProvider(\n List<String> cmkArns, Region currentRegion) {\n List<MasterKeyProvider<KmsMasterKey>> providers = new ArrayList();\n List<String> arnList = getSortedArnListByCurrentRegion(cmkArns, currentRegion);\n providers.add(KmsMasterKeyProvider.builder().buildStrict(arnList));\n return (MasterKeyProvider<KmsMasterKey>) MultipleProviderFactory.buildMultiProvider(providers);\n }", "public JmsEventSubscriber(final String topic, final ConnectionFactory connectionFactory, final String username,\n final String password) throws JMSException {\n this.topic = topic;\n connection = connectionFactory.createConnection(username, password);\n connection.start();\n\n subscriberThread = new Thread(this);\n subscriberThread.start();\n }", "public interface MessageServiceInjector {\n public Consumer getConsumer() ;\n}", "SpringLoader getSpringLoader();", "@Bean\n SimpleMessageListenerContainer container(final MessageListenerAdapter messageListener,\n final ConnectionFactory connectionFactory) {\n SimpleMessageListenerContainer container = new SimpleMessageListenerContainer();\n container.setMessageListener(messageListener);\n container.setConnectionFactory(connectionFactory);\n container.setDestinationName(DESTINATION);\n return container;\n }", "@Override\n public javax.jms.Destination resolveDestination(Destination d) {\n // we resolve any destination\n //\n\n String name = d.getName();\n\n javax.jms.Destination jmsDestination;\n\n if (d.isQueue()) {\n\n jmsDestination = queues.get(d.getName());\n\n if (jmsDestination == null) {\n\n jmsDestination = new EmbeddedQueue(name);\n queues.put(name, (EmbeddedQueue)jmsDestination);\n }\n }\n else {\n\n jmsDestination = topics.get(d.getName());\n\n if (jmsDestination == null) {\n\n jmsDestination = new EmbeddedTopic(name);\n topics.put(name, (EmbeddedTopic)jmsDestination);\n }\n }\n\n return jmsDestination;\n }", "private static CamelContext configureCamelContext(ApplicationContext context) throws Exception {\n //normal way of getting camel context but i have it defined in camelSpringApplicationContext.xml\n // CamelContext camel = new DefaultCamelContext();\n // CamelContext camel = new SpringCamelContext(context);\n CamelContext camel = (CamelContext) context.getBean(\"myCamelContext\");\n // shows up in jmx with this context name instead of camel-1\n camel.setNameStrategy(new DefaultCamelContextNameStrategy(\"steves_camel_driver\"));\n // camel.setTracing(true); // set in camelSpringApplicationContext.xml\n camel.addStartupListener(new StartupListener() {\n @Override\n public void onCamelContextStarted(CamelContext context, boolean alreadyStarted) throws Exception {\n LOG.info(\"Seeing when startup strategy is called. CamelContext=\" + context);\n }\n });\n\n return camel;\n }", "Context createContext( Properties properties ) throws NamingException;", "private static SingerWithJSR250 getBean(String beanName, ApplicationContext context) {\n\t\ttry {\n\t\t\tSingerWithJSR250 bean = (SingerWithJSR250) context.getBean(beanName);\n\t\t\treturn bean;\n\t\t} catch (Exception e) {\n\t\t\t// TODO: handle exception\n\t\t\tSystem.out.println(\"An error occured in bean configuration: \" + e.getMessage());\n\t\t\treturn null;\n\t\t}\n\t}", "protected QueueReceiver getQueueReceiver(String name, String ms)\n throws JMSException {\n Queue q = qSession.createQueue(name);\n if (ms != null)\n return qSession.createReceiver(q, ms);\n else\n return qSession.createReceiver(q);\n }", "public interface IMessageFetcherFactory {\n /**\n * Create a fetcher for a named queue with given consumer of the item\n *\n * @param queueName Named queue in HzC.\n * @param itemConsumer The logic to be called once the item arrives in the queue\n * @param <T> Type of the item kept in queue\n * @return Constructed instance of the message fetcher\n */\n <T> IMessageFetcher<T> createFetcher(String queueName, Consumer<T> itemConsumer);\n}", "abstract public Core createCore(String configPath, String factoryConfigPath, Object systemContext);", "public ConfigurationProvider load(String rsrc, String name, Map m)\n throws IOException {\n boolean explicit = !StringUtil.isEmpty(rsrc);\n if (!explicit)\n rsrc = RSRC_DEFAULT;\n\n ConfigurationProviderImpl cp = new ConfigurationProviderImpl();\n Boolean ret = load(cp, rsrc, name, m, null, explicit);\n if (ret != null)\n return (ret) ? cp : null;\n if (explicit)\n return null;\n\n // persistence.xml does not exist; just load map\n PersistenceUnitInfoImpl pinfo = new PersistenceUnitInfoImpl();\n pinfo.fromUserProperties(m);\n if (!isOpenJPAPersistenceProvider(pinfo, null)) {\n warnUnknownProvider(pinfo);\n return null;\n }\n cp.addProperties(pinfo.toOpenJPAProperties());\n return cp;\n }", "@VisibleForTesting\n public static <T> FailoverProxyProvider<T> createFailoverProxyProvider(\n Configuration conf, Class<FailoverProxyProvider<T>> failoverProxyProviderClass,\n Class<T> xface, URI nameNodeUri, AtomicBoolean fallbackToSimpleAuth) throws IOException {\n Preconditions.checkArgument(\n xface.isAssignableFrom(NamenodeProtocols.class),\n \"Interface %s is not a NameNode protocol\", xface);\n try {\n Constructor<FailoverProxyProvider<T>> ctor = failoverProxyProviderClass\n .getConstructor(Configuration.class, URI.class, Class.class);\n FailoverProxyProvider<T> provider = ctor.newInstance(conf, nameNodeUri,\n xface);\n return provider;\n } catch (Exception e) {\n String message = \"Couldn't create proxy provider \" + failoverProxyProviderClass;\n if (LOG.isDebugEnabled()) {\n LOG.debug(message, e);\n }\n if (e.getCause() instanceof IOException) {\n throw (IOException) e.getCause();\n } else if(e.getCause() instanceof RuntimeException && e.getCause().getCause() instanceof IOException){\n throw (IOException) e.getCause().getCause();\n } else {\n throw new IOException(message, e);\n }\n }\n }", "@Override\n\tpublic LoggerContext getContext(final String fqcn, final ClassLoader loader, final Object externalContext,\n\t\t\tfinal boolean currentContext, final URI configLocation, final String name) {\n\t\tfinal LoggerContext ctx = selector.getContext(fqcn, loader, currentContext, configLocation);\n\t\tif (externalContext != null && ctx.getExternalContext() == null) {\n\t\t\tctx.setExternalContext(externalContext);\n\t\t}\n\t\tif (name != null) {\n\t\t\tctx.setName(name);\n\t\t}\n\t\tif (ctx.getState() == LifeCycle.State.INITIALIZED) {\n\t\t\tif (configLocation != null || name != null) {\n\t\t\t\tContextAnchor.THREAD_CONTEXT.set(ctx);\n\t\t\t\tfinal Configuration config = ConfigurationFactory.getInstance().getConfiguration(ctx, name,\n\t\t\t\t\t\tconfigLocation);\n\t\t\t\tLOGGER.debug(\"Starting LoggerContext[name={}] from configuration at {}\", ctx.getName(), configLocation);\n\t\t\t\tctx.start(config);\n\t\t\t\tContextAnchor.THREAD_CONTEXT.remove();\n\t\t\t} else {\n\t\t\t\tctx.start();\n\t\t\t}\n\t\t}\n\t\treturn ctx;\n\t}", "public void setQueueConnectionFactoryBean ( QueueConnectionFactoryBean bean )\r\n {\r\n setAbstractConnectionFactoryBean ( bean );\r\n }", "@Bean\r\n\t@ConditionalOnProperty(\"spring.mail.host\")\r\n\tpublic MailSender_Interface sMTPMailSender(JavaMailSender javaMailSender)\r\n\t{\n\t\treturn new SMTPMailSender(javaMailSender);\r\n\t}", "public interface PersistenceAdapter extends Service {\n\n /**\n * Returns a set of all the\n * {@link org.apache.activemq.command.ActiveMQDestination} objects that the\n * persistence store is aware exist.\n *\n * @return active destinations\n */\n Set<ActiveMQDestination> getDestinations();\n\n /**\n * Factory method to create a new queue message store with the given\n * destination name\n *\n * @param destination\n * @return the message store\n * @throws IOException\n */\n MessageStore createQueueMessageStore(ActiveMQQueue destination) throws IOException;\n\n /**\n * Factory method to create a new topic message store with the given\n * destination name\n *\n * @param destination\n * @return the topic message store\n * @throws IOException\n */\n TopicMessageStore createTopicMessageStore(ActiveMQTopic destination) throws IOException;\n\n /**\n * Creates and returns a new Job Scheduler store instance.\n *\n * @return a new JobSchedulerStore instance if this Persistence adapter provides its own.\n *\n * @throws IOException If an error occurs while creating the new JobSchedulerStore.\n * @throws UnsupportedOperationException If this adapter does not provide its own\n * scheduler store implementation.\n */\n JobSchedulerStore createJobSchedulerStore() throws IOException, UnsupportedOperationException;\n\n /**\n * Cleanup method to remove any state associated with the given destination.\n * This method does not stop the message store (it might not be cached).\n *\n * @param destination\n * Destination to forget\n */\n void removeQueueMessageStore(ActiveMQQueue destination);\n\n /**\n * Cleanup method to remove any state associated with the given destination\n * This method does not stop the message store (it might not be cached).\n *\n * @param destination\n * Destination to forget\n */\n void removeTopicMessageStore(ActiveMQTopic destination);\n\n /**\n * Factory method to create a new persistent prepared transaction store for\n * XA recovery\n *\n * @return transaction store\n * @throws IOException\n */\n TransactionStore createTransactionStore() throws IOException;\n\n /**\n * This method starts a transaction on the persistent storage - which is\n * nothing to do with JMS or XA transactions - its purely a mechanism to\n * perform multiple writes to a persistent store in 1 transaction as a\n * performance optimization.\n * <p/>\n * Typically one transaction will require one disk synchronization point and\n * so for real high performance its usually faster to perform many writes\n * within the same transaction to minimize latency caused by disk\n * synchronization. This is especially true when using tools like Berkeley\n * Db or embedded JDBC servers.\n *\n * @param context\n * @throws IOException\n */\n void beginTransaction(ConnectionContext context) throws IOException;\n\n /**\n * Commit a persistence transaction\n *\n * @param context\n * @throws IOException\n *\n * @see PersistenceAdapter#beginTransaction(ConnectionContext context)\n */\n void commitTransaction(ConnectionContext context) throws IOException;\n\n /**\n * Rollback a persistence transaction\n *\n * @param context\n * @throws IOException\n *\n * @see PersistenceAdapter#beginTransaction(ConnectionContext context)\n */\n void rollbackTransaction(ConnectionContext context) throws IOException;\n\n /**\n *\n * @return last broker sequence\n * @throws IOException\n */\n long getLastMessageBrokerSequenceId() throws IOException;\n\n /**\n * Delete's all the messages in the persistent store.\n *\n * @throws IOException\n */\n void deleteAllMessages() throws IOException;\n\n /**\n * @param usageManager\n * The UsageManager that is controlling the broker's memory\n * usage.\n */\n void setUsageManager(SystemUsage usageManager);\n\n /**\n * Set the name of the broker using the adapter\n *\n * @param brokerName\n */\n void setBrokerName(String brokerName);\n\n /**\n * Set the directory where any data files should be created\n *\n * @param dir\n */\n void setDirectory(File dir);\n\n /**\n * @return the directory used by the persistence adaptor\n */\n File getDirectory();\n\n /**\n * checkpoint any\n *\n * @param cleanup\n * @throws IOException\n *\n */\n void checkpoint(boolean cleanup) throws IOException;\n\n /**\n * A hint to return the size of the store on disk\n *\n * @return disk space used in bytes of 0 if not implemented\n */\n long size();\n\n /**\n * return the last stored producer sequenceId for this producer Id used to\n * suppress duplicate sends on failover reconnect at the transport when a\n * reconnect occurs\n *\n * @param id\n * the producerId to find a sequenceId for\n * @return the last stored sequence id or -1 if no suppression needed\n */\n long getLastProducerSequenceId(ProducerId id) throws IOException;\n\n void allowIOResumption();\n}", "public void init(int yea)\n {\n try\n {\n InitialContext initialContext = new InitialContext(getProperties());\n //logger.info(\"initial context successful\");\n\n// ConnectionFactory connectionFactory = (ConnectionFactory)initialContext.lookup(\"/ConnectionFactory\");\n// System.out.println(\"lookup successful\");\n// Connection connection = connectionFactory.createConnection();\n//\n// Queue bridgeQueue = (Queue)initialContext.lookup(\"/queue/bridgeQueue\");\n// Queue himsQueue = (Queue)initialContext.lookup(\"/queue/himsQueue\");\n//\n// Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);\n// consumer = session.createConsumer(bridgeQueue);\n// producer = session.createProducer(himsQueue);\n\n System.out.println(\"connection successful\");\n //logger.info(\"Jms Connection factory and resources created without errors\");\n// connection.start();\n }\n catch (Exception e)\n {\n e.printStackTrace();\n //logger.error(\"error looking up jms connection factory\", e);\n }\n }", "public FailoverQReceiver() throws SQLException {\n\t\t// set up JMS environment\n\t\tsetup();\n\t}", "@Autowired\n public LecturerMailCreationService(TemplateEngine templateEngine) {\n this.templateEngine = templateEngine;\n }", "@Override\n\tpublic MongoClient getConnection(MqsConfigBean mqsConfigBean) {\n\t\tif (mongoClient == null) {\n\t\t\tConnectionBean connectionBean = new ConnectionBean(mqsConfigBean.getHost(), mqsConfigBean.getPort(),\n\t\t\t\t\tmqsConfigBean.getUsername(), mqsConfigBean.getPassword(), mqsConfigBean.getDbName());\n\t\t\tfinal ConnectionValidation hostPortValidation = ConnectionValidation.hostIsNotEmpty()\n\t\t\t\t\t.and(ConnectionValidation.portIsNotDefault());\n\t\t\tfinal ConnectionValidation userNamePasswordValidation = ConnectionValidation.userNameIsNotEmpty()\n\t\t\t\t\t.and(ConnectionValidation.passwordIsNotEmpty());\n\t\t\tif (hostPortValidation.apply(connectionBean) && userNamePasswordValidation.apply(connectionBean)) {\n\t\t\t\tServerAddress serverAddress = new ServerAddress(mqsConfigBean.getHost(), mqsConfigBean.getPort());\n\t\t\t\tMongoCredential credential = MongoCredential.createCredential(mqsConfigBean.getUsername(),\n\t\t\t\t\t\tmqsConfigBean.getDbName(), mqsConfigBean.getPassword().toCharArray());\n\t\t\t\tMongoClientOptions mongoClientOptions = new MongoClientOptions.Builder().build();\n\t\t\t\tmongoClient = new MongoClient(serverAddress, credential, mongoClientOptions);\n\t\t\t} else {\n\t\t\t\t\n\t\t\t\tif (ConnectionValidation.hostIsNotEmpty().apply(connectionBean)) {\n\t\t\t\t\treturn new MongoClient(mqsConfigBean.getHost(), mqsConfigBean.getPort());\n\t\t\t\t}\n\t\t\t\treturn getDefaultConnection();\n\t\t\t}\n\t\t}\n\t\treturn mongoClient;\n\t}", "@DataBoundConstructor\n\tpublic CoveragePublisher(String jacocoPathPattern, String lcovPathPattern) {\n\t\t// Fields in config.jelly must match the parameter names in the \"DataBoundConstructor\"\n\t\tthis.jacocoPathPattern = jacocoPathPattern == null || jacocoPathPattern.isEmpty() ? CoverageService.Jacoco.JACOCO_DEFAULT_PATH : jacocoPathPattern;\n\t\tthis.lcovPathPattern = lcovPathPattern == null || lcovPathPattern.isEmpty() ? CoverageService.Lcov.LCOV_DEFAULT_PATH : lcovPathPattern;\n\t}", "public ValidatorFactory(String bundleName) {\n this.messageResolver = new ResourceMessageResolver(bundleName);\n }", "MessageSender createSender(String topic) throws MessagingException;", "@Override\n public void addConnectionFactories(ConnectionFactoryConfigurer cfConfig, Environment env) {\n\n FacebookConnectionFactory fcf = new FacebookConnectionFactory(\n \"1487938974801143\",\n \"b53bfee1bbc43715311e12e109d90621\"\n );\n fcf.setScope(\"email\");\n cfConfig.addConnectionFactory(fcf);\n\n GoogleConnectionFactory gcf = new GoogleConnectionFactory(\"298688116141-tomf8f4jkunlankbd4c55nu9bp83h963.apps.googleusercontent.com\", \"iGEoPkecoD4Gu1RTjNKAoxFl\");\n gcf.setScope(\"profile\");\n cfConfig.addConnectionFactory(gcf);\n\n\n }", "CustomerServiceProviderConfiguration getConfiguration(String serviceProviderId);", "public interface MnsService {\n\n void init();\n\n String pop();\n\n boolean sendMsg(BaseConsumer.Message entity);\n\n String getTopicName();\n\n void destroy();\n}" ]
[ "0.73020035", "0.5485776", "0.52265394", "0.4937619", "0.48904312", "0.48802826", "0.48618817", "0.4800828", "0.47890726", "0.47232646", "0.47162825", "0.4667765", "0.46559197", "0.46416515", "0.46224332", "0.4610363", "0.46051642", "0.45978442", "0.45627996", "0.45509857", "0.45222318", "0.4521673", "0.45116726", "0.45014355", "0.4492794", "0.44707504", "0.44375274", "0.4402312", "0.44012833", "0.43899685", "0.4380804", "0.4377698", "0.43640858", "0.43609852", "0.4357827", "0.4340719", "0.43336976", "0.43005693", "0.42898807", "0.42889613", "0.4285349", "0.4269789", "0.426543", "0.42390057", "0.422052", "0.42051995", "0.42012727", "0.419776", "0.4183603", "0.41775787", "0.41768217", "0.41673112", "0.416296", "0.4142787", "0.41367048", "0.41276956", "0.41192216", "0.41165727", "0.41141376", "0.41111913", "0.41102782", "0.4094016", "0.40936562", "0.40876842", "0.408042", "0.40763503", "0.4074632", "0.4062068", "0.40489018", "0.40477076", "0.40450865", "0.40422162", "0.40264153", "0.4018078", "0.40126368", "0.40010518", "0.39985347", "0.39963567", "0.39949477", "0.39893097", "0.39853704", "0.39847696", "0.3969777", "0.39672807", "0.39510083", "0.39502302", "0.39416218", "0.39414927", "0.39409488", "0.39387858", "0.39365706", "0.39304948", "0.39296663", "0.3925086", "0.392268", "0.3920162", "0.39177352", "0.39141265", "0.38981318", "0.3898047" ]
0.7642246
0
An activity that sends notifications to the user. Created by hollie on 17/04/2017.
public interface NotificationSenderActivity { public void update(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void sendNotification() {\n }", "private void sendNotification() {\n int mNotificationId = 001;\n NotificationCompat.Builder mBuilder = new NotificationCompat.Builder(this)\n .setSmallIcon(R.drawable.ic_action_camera)\n .setContentTitle(\"Daily Selfie\")\n .setContentText(\"Time for another selfie\");\n Intent resultIntent = new Intent(this, MainActivity.class);\n PendingIntent resultPendingIntent =\n PendingIntent.getActivity(\n this,\n 0,\n resultIntent,\n PendingIntent.FLAG_UPDATE_CURRENT\n );\n mBuilder.setContentIntent(resultPendingIntent);\n // Gets an instance of the NotificationManager service\n NotificationManager mNotifyMgr = (NotificationManager) getSystemService(NOTIFICATION_SERVICE);\n // Builds the notification and issues it.\n mNotifyMgr.notify(mNotificationId, mBuilder.build());\n }", "public void sendNotification(View view) {\n\t\t Intent intent = new Intent(this, MainActivity.class);\r\n\t\t PendingIntent pIntent = PendingIntent.getActivity(this, 0, intent, 0);\r\n\r\n\t\t // Build notification\r\n\t\t // Actions are just fake\r\n\t\t Notification noti = new Notification.Builder(this)\r\n\t\t .setContentTitle(\"TodoList Item\")\r\n\t\t .setContentText(\"A New Item was Added\").setSmallIcon(R.drawable.ic_launcher)\r\n\t\t .setContentIntent(pIntent).build();\r\n\t\t //.addAction(R.drawable.ic_launcher, \"Call\", pIntent);\r\n\t\t //.addAction(R.drawable.ic_launcher, \"More\", pIntent)\r\n\t\t //.addAction(R.drawable.ic_launcher, \"And more\", pIntent).build();\r\n\t\t NotificationManager notificationManager = (NotificationManager) getSystemService(NOTIFICATION_SERVICE);\r\n\t\t // hide the notification after its selected\r\n\t\t noti.flags |= Notification.FLAG_AUTO_CANCEL;\r\n\r\n\t\t notificationManager.notify(0, noti);\r\n\r\n\t\t }", "private void sendNotification(PanicIncidentDTO simpleMessage) {\n// Intent intent = new Intent(this, SimpleMessagingActivity.class);\n// intent.putExtra(\"simpleMessage\",simpleMessage);\n// intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);\n// PendingIntent pendingIntent = PendingIntent.getActivity(this,\n// LOCATION_REQUEST_CODE, intent,\n// PendingIntent.FLAG_ONE_SHOT);\n\n\n Uri defaultSoundUri= RingtoneManager.getDefaultUri(RingtoneManager.TYPE_NOTIFICATION);\n NotificationCompat.Builder notificationBuilder = new NotificationCompat.Builder(this)\n .setSmallIcon(R.drawable.ic_favorite)\n .setContentTitle(\"Message received\")\n .setContentText(simpleMessage.getPanicType().getName())\n .setAutoCancel(true)\n .setSound(defaultSoundUri);\n// .setContentIntent(pendingIntent);\n\n NotificationManager notificationManager =\n (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);\n\n notificationManager.notify(0 /* ID of notification */, notificationBuilder.build());\n }", "public static void createNotification(MainActivity a, CustomFBProfile profile, IMessagingMetaData meta, HashMap<String, String> loc) {\n NotificationCompat.Builder mBuilder =\n new NotificationCompat.Builder(a)\n .setSmallIcon(R.drawable.acba)\n .setContentTitle(\"New Message\")\n .setContentText(meta.getName().toUpperCase()).setTicker(\"New Message!!\");\n NotificationCompat.InboxStyle inboxStyle = new NotificationCompat.InboxStyle();\n mBuilder.setStyle(inboxStyle);\n mBuilder.setVibrate(new long[]{2000, 2000, 1000});\n mBuilder.setLights(Color.RED, 3000, 3000);\n mBuilder.setSound(RingtoneManager.getDefaultUri(RingtoneManager.TYPE_NOTIFICATION));\n mBuilder.setAutoCancel(true);\n\n// Creates an explicit intent for an Activity in your app\n Intent resultIntent = a.startMessagingActivityFromAnywhereInApp(profile, meta, loc);\n\n// The stack builder object will contain an artificial back stack for the\n// started Activity.\n// This ensures that navigating backward from the Activity leads out of\n// your application to the Home screen.\n TaskStackBuilder stackBuilder = TaskStackBuilder.create(a);\n// Adds the back stack for the Intent (but not the Intent itself)\n stackBuilder.addParentStack(MainActivity.class);\n// Adds the Intent that starts the Activity to the top of the stack\n stackBuilder.addNextIntent(resultIntent);\n PendingIntent resultPendingIntent =\n stackBuilder.getPendingIntent(\n 0,\n PendingIntent.FLAG_UPDATE_CURRENT\n );\n mBuilder.setContentIntent(resultPendingIntent);\n NotificationManager mNotificationManager =\n (NotificationManager) a.getSystemService(Context.NOTIFICATION_SERVICE);\n// mId allows you to update the notification later on.\n mNotificationManager.notify(1, mBuilder.build());\n }", "private void sendNotification(String title,String date)\n {\n\n NotificationManager mNotificationManager = (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);\n\n Intent intent = new Intent(getApplicationContext(), MainActivity.class);\n intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);\n intent.putExtra(\"msg\", title);\n\n PendingIntent contentIntent = PendingIntent.getActivity(this, 0, intent, PendingIntent.FLAG_UPDATE_CURRENT);\n\n NotificationCompat.Builder mBuilder = new NotificationCompat.Builder(this).setSmallIcon(R.mipmap.ic_launcher)\n .setContentTitle(title)\n .setStyle(new NotificationCompat.BigTextStyle().bigText(title))\n .setContentText(date)\n .setAutoCancel(true)\n .setVibrate(new long[]{0, 500});\n\n mBuilder.setContentIntent(contentIntent);\n mNotificationManager.notify(NOTIFICATION_ID, mBuilder.build());\n\n }", "private void sendNotification() {\n //Log.e(\"sendNotification: \", \"\" + message);\n\n Uri defaultSoundUri = RingtoneManager.getDefaultUri(RingtoneManager.TYPE_NOTIFICATION);\n\n Intent intent = new Intent(this, ClubNewsActivity.class);\n intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);\n PendingIntent pendingIntent = PendingIntent.getActivity(this, 0 /* Request code */, intent,\n 0);\n\n notificationBuilder = new NotificationCompat.Builder(this)\n .setSmallIcon(R.mipmap.ic_launcher)\n .setLargeIcon(BitmapFactory.decodeResource(getResources(), R.mipmap.ic_launcher))\n .setContentTitle(getResources().getString(R.string.app_name))\n .setContentText(getUnexpandedContentText(strArrList.size()))\n .setAutoCancel(true)\n /*.setNumber(strArrList.size())*/\n .setSound(defaultSoundUri)\n .setContentIntent(pendingIntent)\n .setPriority(Notification.PRIORITY_HIGH)\n .setStyle(getExpandedNotificationStyle(strArrList));\n\n NotificationCompat.InboxStyle inboxStyle = new NotificationCompat.InboxStyle();\n // Moves events into the expanded layout\n for (int iCount = 0; iCount < strArrList.size(); iCount++) {\n inboxStyle.addLine(strArrList.get(iCount));\n }\n NotificationManager notificationManager = (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);\n notificationManager.notify(0, notificationBuilder.build());\n }", "@Override\n\tpublic void run() {\n\t\tthis.logger.debug(\"activity created sent: \" + body);\n\n\t\tSender sender = new Sender(this.apiKey);\n//\t\tNotification value = new Notification.Builder(\"TiTlE\").body(\"BoDy\").build();\n//\t\tMessage message = new Message.Builder().notification(value)\n//\t\t\t\t.addData(\"message\", body)\n//\t\t\t\t.addData(\"title\", title)\n//\t\t\t\t.build();\n\t\tMessage message = new Message.Builder()\n\t\t\t\t.addData(\"message\", body)\n\t\t\t\t.addData(\"title\", title)\n\t\t\t\t.addData(\"activity_id\", this.activityId)\n\t\t\t\t.build();\n\n\t\ttry {\n\t\t\tResult result = sender.send(message, this.registrationId, 1);\n\t\t\t//System.out.println(\"gcm result success:\" + result.getSuccess() + \" failure:\"+ result.getFailure() + \" fail msg: \" + result.getErrorCodeName());\n\t\t} catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\t//System.out.println(\"activity creation notification sent\");\n\n\t}", "private void createNotification() {\n\t\tIntent notifyIntent = new Intent(this, BirthdayActivity.class);\r\n\t\t// Sets the Activity to start in a new, empty task\r\n\t\tnotifyIntent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);\r\n\t\t// Creates the PendingIntent\r\n\t\tPendingIntent pendingIntent = PendingIntent.getActivity(this,\r\n\t\t\t\t(int) System.currentTimeMillis(), notifyIntent,\r\n\t\t\t\tPendingIntent.FLAG_UPDATE_CURRENT);\r\n\r\n\t\tNotificationManagerUtil notificationManagerUtil = NotificationManagerUtil\r\n\t\t\t\t.getInstance();\r\n\t\tnotificationManagerUtil.createNotifications(this, 1, \"Message\",\r\n\t\t\t\tpendingIntent);\r\n\t}", "private void sendNotificationSample() {\n Intent notificationIntent = new Intent(GCMIntentService.this, AlertActivity.class);\n\n // Get a PendingIntent containing the entire back stack.\n int i = new Random().nextInt(100);\n PendingIntent notificationPendingIntent = PendingIntent.getActivity(GCMIntentService.this, i, notificationIntent, PendingIntent.FLAG_UPDATE_CURRENT);\n\n // Get a notification builder that's compatible with platform versions >= 4\n NotificationCompat.Builder builder = new NotificationCompat.Builder(GCMIntentService.this);\n\n // Define the notification settings.\n builder.setSmallIcon(R.drawable.icon_v2)\n // In a real app, you may want to use a library like Volley\n // to decode the Bitmap.\n //.setLargeIcon(BitmapFactory.decodeResource(ctx.getResources(), R.drawable.ic_launcher)).\n .setContentTitle(\"Shang\").setContentText(i + \". This is test mesage from notification\").setContentIntent(notificationPendingIntent);\n\n // Dismiss notification once the user touches it.\n builder.setAutoCancel(true);\n\n Uri alarmSound = RingtoneManager.getDefaultUri(RingtoneManager.TYPE_NOTIFICATION);\n builder.setSound(alarmSound);\n\n builder.setVibrate(new long[]{0, 2000});\n\n builder.setContentIntent(notificationPendingIntent);\n\n // Get an instance of the Notification manager\n NotificationManager mNotificationManager = (NotificationManager) GCMIntentService.this.getSystemService(Context.NOTIFICATION_SERVICE);\n\n // Issue the notification\n mNotificationManager.notify(i, builder.build());\n }", "private void sendNotification(String transitionType, String msg) {\n long when = System.currentTimeMillis();\n Intent notifyIntent = new Intent(this, MapsActivity.class);\n notifyIntent.putExtra(\"type\", transitionType);\n notifyIntent.putExtra(\"id\", msg);\n notifyIntent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TASK);\n\n PendingIntent pendingIntent = PendingIntent.getActivity(this, 0, notifyIntent, PendingIntent.FLAG_UPDATE_CURRENT);\n\n NotificationCompat.Builder builder =\n new NotificationCompat.Builder(getApplicationContext())\n .setSmallIcon(R.drawable.ic_notification)\n .setCategory(NotificationCompat.CATEGORY_ALARM)\n .setContentTitle(transitionType)\n .setContentText(msg)\n .setContentIntent(pendingIntent)\n .setAutoCancel(true)\n .setDefaults(NotificationCompat.DEFAULT_ALL)\n .setWhen(when);\n\n NotificationManager notificationManager =\n (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);\n notificationManager.notify((int) when, builder.build());\n }", "@Override\r\n\tpublic void sendNotifications() {\n\r\n\t}", "private void sendNotifications() {\n this.sendNotifications(null);\n }", "private void sendNotification(NotificationCompat.Builder notification){\n NotificationManager notifier = (NotificationManager)getSystemService(Context.NOTIFICATION_SERVICE);\n NotificationChannel channel = new NotificationChannel(\"default\", \"notification\", NotificationManager.IMPORTANCE_DEFAULT);\n notifier.createNotificationChannel(channel);\n NotificationManagerCompat notificationManager = NotificationManagerCompat.from(this);\n\n notificationManager.notify(0, notification.build());\n }", "public void sendTestNotification() {\n\n Log.d(TAG, \"version: \" + Build.VERSION.SDK_INT);\n // Create an explicit intent for an Activity in your app\n Intent intent = new Intent(context, MainActivity.class);\n intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TASK);\n PendingIntent pendingIntent = PendingIntent.getActivity(context, 0, intent, 0);\n\n final int NOTIFICATION_ID = 1;\n final String NOTIFICATION_CHANNEL_ID = \"my_notification_channel\";\n\n NotificationCompat.Builder mBuilder = new NotificationCompat.Builder(context, channelId)\n .setSmallIcon(R.drawable.alarm_sound_icon) // icon must be right size for all supported APIs. Icon is changeable\n .setContentTitle(\"IDO\") // changeable\n .setContentText(\"Become A Better Spouse Today!\") // changeable\n .setPriority(NotificationCompat.PRIORITY_DEFAULT) // changeable\n .setContentIntent(pendingIntent)\n .setVisibility(Notification.VISIBILITY_PUBLIC) // changeable\n .setAutoCancel(true);\n\n NotificationManagerCompat notificationManager = NotificationManagerCompat.from(context);\n\n // notificationId is a unique int for each notification that you must define\n notificationManager.notify(NOTIFICATION_ID, mBuilder.build());\n\n }", "private void sendNotification(String title, String messageBody, Map<String, String> extra) {\n Intent intent = new Intent(this, MainActivity.class);\n intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);\n PendingIntent pendingIntent;\n if (extra != null) {\n String type = extra.get(\"type\") != null ? extra.get(\"type\") : \"\";\n switch (type) {\n case \"page\":\n // for background, foreground can get this message directly without intent.putExtra()\n intent.putExtra(\"type\", type);\n if (extra.get(\"page\") != null) {\n intent.putExtra(\"page\", extra.get(\"page\"));\n }\n if (extra.get(\"id\") != null) {\n Log.i(TAG, \"sendNotification: payload page id \" + extra.get(\"id\"));\n intent.putExtra(\"id\", extra.get(\"id\"));\n }\n pendingIntent = PendingIntent.getActivity(this, 0, intent,\n PendingIntent.FLAG_ONE_SHOT);\n break;\n case \"link\":\n // only for foreground, without sending extra\n if (extra.get(\"link\") != null) {\n Uri uri = Uri.parse(LauUtil.getLegalURL(extra.get(\"link\")));\n intent = new Intent(Intent.ACTION_VIEW, uri);\n intent.putExtra(\"link\", extra.get(\"link\"));\n }\n pendingIntent = PendingIntent.getActivity(this, 2, intent,\n PendingIntent.FLAG_ONE_SHOT);\n break;\n case \"alarm_alert\":\n pendingIntent = getPendingIntentForAlertSystem(this, 0, 0, 0);\n break;\n default:\n pendingIntent = PendingIntent.getActivity(this, 0, intent,\n PendingIntent.FLAG_ONE_SHOT);\n break;\n }\n } else {\n pendingIntent = PendingIntent.getActivity(this, 0, intent,\n PendingIntent.FLAG_ONE_SHOT);\n }\n\n String channelId = getString(R.string.default_notification_channel_id);\n Uri defaultSoundUri = RingtoneManager.getDefaultUri(RingtoneManager.TYPE_NOTIFICATION);\n\n NotificationCompat.BigTextStyle bigTextStyle = new NotificationCompat.BigTextStyle();\n bigTextStyle.setBigContentTitle(title).bigText(messageBody);\n\n NotificationCompat.Builder notificationBuilder =\n new NotificationCompat.Builder(this, channelId)\n .setSmallIcon(R.drawable.young_icon_192x192)\n .setLargeIcon(BitmapFactory.decodeResource(getResources(), R.drawable.young_icon_192x192))\n .setContentTitle(title)\n .setContentText(messageBody)\n .setStyle(bigTextStyle)\n .setAutoCancel(true)\n .setPriority(Notification.PRIORITY_HIGH)\n .setDefaults(Notification.DEFAULT_ALL)\n// .setSound(defaultSoundUri)\n .setContentIntent(pendingIntent);\n\n NotificationManager notificationManager =\n (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);\n\n // Since android Oreo notification channel is needed.\n if (notificationManager != null) {\n if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {\n NotificationChannel channel = new NotificationChannel(channelId,\n channelId,\n NotificationManager.IMPORTANCE_DEFAULT);\n channel.setDescription(\"Young+推送\");\n notificationManager.createNotificationChannel(channel);\n }\n notificationManager.notify(0 /* ID of notification */, notificationBuilder.build());\n }\n }", "private void sendNotify(JSONObject notification, String staffID) {\r\n JsonObjectRequest jsonObjectRequest = new JsonObjectRequest(FCM_API, notification,\r\n new Response.Listener<JSONObject>() {\r\n @Override\r\n public void onResponse(JSONObject response) {\r\n Toast.makeText(BookingListDetails.this, \"\"+ staffID + \" has been Notified!\", Toast.LENGTH_SHORT).show();\r\n Log.i(TAG, \"onResponse: \" + response);\r\n startActivity(new Intent(getApplicationContext(), AdminBookingList.class));\r\n finish();\r\n }\r\n },\r\n new Response.ErrorListener() {\r\n @Override\r\n public void onErrorResponse(VolleyError error) {\r\n Toast.makeText(BookingListDetails.this, \"Request error\", Toast.LENGTH_LONG).show();\r\n Log.i(TAG, \"onErrorResponse: Didn't work\");\r\n }\r\n }) {\r\n @Override\r\n public Map<String, String> getHeaders() throws AuthFailureError {\r\n Map<String, String> params = new HashMap<>();\r\n params.put(\"Authorization\", serverKey);\r\n params.put(\"Content-Type\", contentType);\r\n return params;\r\n }\r\n };\r\n MySingleton.getInstance(getApplicationContext()).addToRequestQueue(jsonObjectRequest);\r\n }", "private void sendNotification(Map<String, String> serverData) {\n Intent intent = new Intent(serverData.get(\"click_action\"));\n String title = serverData.get(\"title\");\n String body = serverData.get(\"body\");\n intent.putExtra(\"title\",title);\n intent.putExtra(\"body\",body);\n intent.putExtra(\"order\" , serverData.get(\"order\"));\n intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);\n PendingIntent pendingIntent = PendingIntent.getActivity(this,0 /* request code */, intent, PendingIntent.FLAG_UPDATE_CURRENT);\n\n long[] pattern = {500,500,500,500,500};\n\n Uri defaultSoundUri= RingtoneManager.getDefaultUri(RingtoneManager.TYPE_NOTIFICATION);\n\n NotificationCompat.Builder notificationBuilder = (NotificationCompat.Builder) new NotificationCompat.Builder(this)\n .setSmallIcon(R.drawable.ok)\n .setContentTitle(serverData.get(\"title\"))\n .setContentText(serverData.get(\"body\"))\n .setAutoCancel(true)\n .setVibrate(pattern)\n .setLights(Color.BLUE,1,1)\n .setSound(defaultSoundUri)\n .setContentIntent(pendingIntent);\n\n NotificationManager notificationManager = (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);\n notificationManager.notify(0 , notificationBuilder.build());\n }", "private void sendNotification(String title, String messageBody,int count,int chatcount,int id) {\n Intent intent = new Intent(this, Home.class);\n intent.putExtra(\"title\",title);\n intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);\n PendingIntent pendingIntent = PendingIntent.getActivity(this, 0, intent,\n PendingIntent.FLAG_ONE_SHOT);\n\n Uri defaultSoundUri= RingtoneManager.getDefaultUri(RingtoneManager.TYPE_NOTIFICATION);\n String message;\n if(count<=1){\n message = messageBody;\n }\n else{\n if(chatcount==1)\n message = count +\" new messages \";\n else {\n\n\n message = count + \" new messages from \" + chatcount + \" chats.\";\n title=\"Icebreaker\";\n }\n\n }\n\n NotificationCompat.Builder notificationBuilder = new NotificationCompat.Builder(this)\n .setSmallIcon(R.mipmap.ic_launcher)\n .setContentTitle(title)\n .setContentText(message)\n .setAutoCancel(true)\n .setGroupSummary(true)\n .setGroup(GROUP_KEY_EMAILS)\n .setSound(defaultSoundUri)\n .setContentIntent(pendingIntent);\n\n NotificationManager notificationManager =\n (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);\n\n notificationManager.notify(id, notificationBuilder.build());\n }", "private static void createNotification(Activity a, CustomFBProfile prof) {\n NotificationCompat.Builder mBuilder =\n new NotificationCompat.Builder(a)\n .setSmallIcon(R.drawable.acba)\n .setContentTitle(\"New Message\")\n .setTicker(\"New Message!!\");\n NotificationCompat.InboxStyle inboxStyle = new NotificationCompat.InboxStyle();\n mBuilder.setStyle(inboxStyle);\n mBuilder.setVibrate(new long[]{2000, 500, 500, 250});\n mBuilder.setLights(Color.YELLOW, 3000, 3000);\n mBuilder.setSound(RingtoneManager.getDefaultUri(RingtoneManager.TYPE_NOTIFICATION));\n mBuilder.setAutoCancel(true);\n\n// Creates an explicit intent for an Activity in your app\n Intent resultIntent = new Intent(a, LoginActivity.class);\n\n// The stack builder object will contain an artificial back stack for the\n// started Activity.\n// This ensures that navigating backward from the Activity leads out of\n// your application to the Home screen.\n TaskStackBuilder stackBuilder = TaskStackBuilder.create(a);\n// Adds the back stack for the Intent (but not the Intent itself)\n stackBuilder.addParentStack(LoginActivity.class);\n// Adds the Intent that starts the Activity to the top of the stack\n stackBuilder.addNextIntent(resultIntent);\n PendingIntent resultPendingIntent =\n stackBuilder.getPendingIntent(\n 0,\n PendingIntent.FLAG_UPDATE_CURRENT\n );\n mBuilder.setContentIntent(resultPendingIntent);\n NotificationManager mNotificationManager =\n (NotificationManager) a.getSystemService(Context.NOTIFICATION_SERVICE);\n// mId allows you to update the notification later on.\n mNotificationManager.notify(1, mBuilder.build());\n }", "private void sendNotification() {\n ParsePush parsePush = new ParsePush();\n String id = ParseInstallation.getCurrentInstallation().getInstallationId();\n Log.d(\"Debug_id\", id);\n Log.d(\"Debug_UserName\", event.getHost().getUsername()); // host = event.getHost().getUsername();\n ParseQuery pQuery = ParseInstallation.getQuery(); // <-- Installation query\n Log.d(\"Debug_pQuery\", pQuery.toString());\n pQuery.whereEqualTo(\"username\", event.getHost().getUsername());// <-- you'll probably want to target someone that's not the current user, so modify accordingly\n parsePush.sendMessageInBackground(\"Hey your Event: \" + event.getTitle() + \" has a subscriber\", pQuery);\n\n }", "private void note(Notification n){\r\n\t\tusers.get(n.userID).addNotification(n);\r\n\t\tif (loggedInUsers.contains(n.userID))\r\n\t\t\tcomms.sendMessage(n);\r\n\t}", "private void sendNotification(String notificationDetails)\r\n {\n NotificationManager notificationManager =\r\n (NotificationManager) this.getSystemService(Context.NOTIFICATION_SERVICE);\r\n\r\n // 2. Create a PendingIntent for AllGeofencesActivity\r\n Intent intent = new Intent(this, MainActivity.class);\r\n intent.addFlags(Intent.FLAG_ACTIVITY_SINGLE_TOP | Intent.FLAG_ACTIVITY_CLEAR_TOP);\r\n PendingIntent pendingNotificationIntent = PendingIntent.getActivity(this, 0, intent, PendingIntent.FLAG_UPDATE_CURRENT);\r\n\r\n // 3. Create and send a notification\r\n Notification notification = new NotificationCompat.Builder(this)\r\n .setSmallIcon(R.mipmap.ic_launcher)\r\n .setContentTitle(\"notification,\")\r\n .setContentText(notificationDetails)\r\n .setContentIntent(pendingNotificationIntent)\r\n .setStyle(new NotificationCompat.BigTextStyle().bigText(notificationDetails))\r\n .setPriority(NotificationCompat.PRIORITY_HIGH)\r\n .setAutoCancel(true)\r\n .build();\r\n notificationManager.notify(0, notification);\r\n\r\n\r\n\r\n\r\n }", "protected void notifyUser()\n {\n }", "public void sendNotification(String str, String str2, String str3, String str4) {\n this.apiService.sendNotification(new Sender(new Data(FirebaseAuth.getInstance().getCurrentUser().getUid(), str3 + \":\" + str4, \"New \" + getIntent().getStringExtra(\"noti\"), str2), str)).enqueue(new Callback<MyResponse>() {\n public void onFailure(Call<MyResponse> call, Throwable th) {\n }\n\n public void onResponse(Call<MyResponse> call, Response<MyResponse> response) {\n if (response.code() == 200) {\n int i = response.body().success;\n }\n }\n });\n }", "private void ShowNotification()\n {\n Notification n = new Notification.Builder(this)\n .setContentTitle(\"Message from Himanshu\")\n .setContentText(\"Thank you Sir. Enjoyed Your Class!\")\n .setSmallIcon(R.drawable.cloud)\n //.setContentIntent(pIntent)\n .setAutoCancel(true)\n //.addAction(R.drawable.icon, \"Call\", pIntent)\n //.addAction(R.drawable.icon, \"More\", pIntent)\n //.addAction(R.drawable.icon, \"And more\", pIntent)\n .getNotification();\n\n\n NotificationManager notificationManager =\n (NotificationManager) getSystemService(NOTIFICATION_SERVICE);\n\n try {\n notificationManager.notify(0, n);\n }catch (Exception ex) {\n Log.d(\"MyApp\", \"Exception Occured!\");\n }\n }", "private void sendMessageToNews(){\r\n JSONObject jPayload = new JSONObject();\r\n JSONObject jNotification = new JSONObject();\r\n try {\r\n jNotification.put(\"message\", \"Leaderboard Activity\");\r\n jNotification.put(\"body\", \"New high score!\");\r\n jNotification.put(\"sound\", \"default\");\r\n jNotification.put(\"badge\", \"1\");\r\n jNotification.put(\"click_action\", \"OPEN_ACTIVITY_1\");\r\n\r\n // Populate the Payload object.\r\n // Note that \"to\" is a topic, not a token representing an app instance\r\n jPayload.put(\"to\", \"/topics/high_score\");\r\n jPayload.put(\"priority\", \"high\");\r\n jPayload.put(\"notification\", jNotification);\r\n\r\n // Open the HTTP connection and send the payload\r\n URL url = new URL(\"https://fcm.googleapis.com/fcm/send\");\r\n HttpURLConnection conn = (HttpURLConnection) url.openConnection();\r\n conn.setRequestMethod(\"POST\");\r\n conn.setRequestProperty(\"Authorization\", SERVER_KEY);\r\n conn.setRequestProperty(\"Content-Type\", \"application/json\");\r\n conn.setDoOutput(true);\r\n\r\n // Send FCM message content.\r\n OutputStream outputStream = conn.getOutputStream();\r\n outputStream.write(jPayload.toString().getBytes());\r\n outputStream.close();\r\n\r\n // Read FCM response.\r\n InputStream inputStream = conn.getInputStream();\r\n final String resp = convertStreamToString(inputStream);\r\n\r\n Handler h = new Handler(Looper.getMainLooper());\r\n h.post(new Runnable() {\r\n @Override\r\n public void run() {\r\n Log.e(TAG, \"run: \" + resp);\r\n Toast.makeText(getActivity(),resp,Toast.LENGTH_LONG).show();\r\n }\r\n });\r\n } catch (JSONException | IOException e) {\r\n e.printStackTrace();\r\n }\r\n }", "protected void sendNotification(Bundle messageInfo) {\n mNotificationManager = (NotificationManager)\n this.getSystemService(Context.NOTIFICATION_SERVICE);\n\n Class targetActivity = TCSAppInstance.getInstance().getTargetNotificationClass();\n Intent notificationIntent;\n\n if (targetActivity != null)\n notificationIntent = new Intent(this, targetActivity);\n else\n notificationIntent = getPackageManager().getLaunchIntentForPackage(getApplication().getPackageName());\n\n\n // set intent so it does not start a new activity\n notificationIntent.setFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP | Intent.FLAG_ACTIVITY_SINGLE_TOP);\n\n PendingIntent contentIntent = PendingIntent.getActivity(this, 0, notificationIntent, 0);\n\n NotificationCompat.Builder mBuilder =\n new NotificationCompat.Builder(getApplicationContext())\n .setContentTitle(TCSAppInstance.getInstance().getApplication().getString(R.string.app_name))\n .setContentText(messageInfo.getString(\"message\"))\n .setWhen(System.currentTimeMillis())\n .setStyle(new NotificationCompat.BigTextStyle().bigText(messageInfo.getString(\"message\")))\n .setAutoCancel(true);\n\n if (icon > 0) {\n mBuilder.setSmallIcon(icon);\n }\n\n if (messageInfo.getString(\"alertSound\") != null && messageInfo.getString(\"alertSound\").equals(\"true\")) {\n mBuilder.setDefaults(Notification.DEFAULT_SOUND);\n }\n\n mBuilder.setContentIntent(contentIntent);\n\n int notificationId = TCSUtilities.generateRandomNumber();\n mNotificationManager.notify(notificationId, mBuilder.build());\n\n broadcastMessageIntent.putExtra(MESSAGE_STRING, messageInfo.getString(\"message\"));\n sendBroadcast(broadcastMessageIntent);\n }", "private void sendNotificationLocalToUser() {\n\n Intent notificationIntent = new Intent(this, GameScreenActivity.class);\n PendingIntent pendingIntent = PendingIntent.getActivity(this, 0, notificationIntent, 0);\n Notification.Builder builder = new Notification.Builder(this);\n builder.setAutoCancel(false);\n\n if ((currentPlay + 1)<= Utility.game.getLength()) {\n// notification.setLatestEventInfo(GameScreenActivity.this, \"Game in progress\", \"Play \" + (currentPlay + 1) + \" started get your guess in.\", pendingIntent);\n\n// builder.setTicker(\"this is ticker text\");\n builder.setContentTitle(\"Game in progress\");\n builder.setContentText(\"Play \" + (currentPlay + 1) + \" started get your guess in.\");\n builder.setSmallIcon(R.drawable.ic_launcher);\n builder.setContentIntent(pendingIntent);\n builder.setOngoing(true);\n// builder.setSubText(\"This is subtext...\"); //API level 16\n builder.setNumber(100);\n builder.build();\n\n }else{\n notificationIntent = new Intent(this,FinalLeaderBoardActivity.class);\n pendingIntent = PendingIntent.getActivity(this,0,notificationIntent,0);\n// notification.setLatestEventInfo(GameScreenActivity.this, \"Game completed\", \"Your game is complete. Check the final leaderboard.\", pendingIntent);\n\n// builder.setTicker(\"this is ticker text\");\n builder.setContentTitle(\"Game completed\");\n builder.setContentText(\"Your game is complete. Check the final leaderboard.\");\n builder.setSmallIcon(R.drawable.ic_launcher);\n builder.setContentIntent(pendingIntent);\n builder.setOngoing(true);\n// builder.setSubText(\"This is subtext...\"); //API level 16\n builder.setNumber(100);\n builder.build();\n\n }\n\n notification = builder.getNotification();\n notification.defaults = Notification.DEFAULT_LIGHTS | Notification.DEFAULT_VIBRATE | Notification.DEFAULT_SOUND;\n\n notificationManager.notify(9999, notification);\n }", "private void sendNotification(final String notificationDetails) {\n Intent notificationIntent = new Intent(getApplicationContext(), MainActivity.class);\n\n // Construct a task stack.\n TaskStackBuilder stackBuilder = TaskStackBuilder.create(this);\n\n // Add the main Activity to the task stack as the parent.\n stackBuilder.addParentStack(MainActivity.class);\n\n // Push the content Intent onto the stack.\n stackBuilder.addNextIntent(notificationIntent);\n\n // Get a PendingIntent containing the entire back stack.\n PendingIntent notificationPendingIntent =\n stackBuilder.getPendingIntent(0, PendingIntent.FLAG_UPDATE_CURRENT);\n\n // Get a notification builder that's compatible with platform versions >= 4\n NotificationCompat.Builder builder = new NotificationCompat.Builder(this);\n\n // Define the notification settings.\n builder.setSmallIcon(R.mipmap.ic_launcher)\n .setLargeIcon(BitmapFactory.decodeResource(getResources(),\n R.mipmap.ic_launcher))\n .setColor(Color.RED)\n .setContentTitle(title)\n// .setContentText(title)\n .setContentIntent(notificationPendingIntent);\n\n // Dismiss notification once the user touches it.\n builder.setAutoCancel(true);\n\n // Get an instance of the Notification manager\n NotificationManager mNotificationManager =\n (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);\n\n // Issue the notification\n mNotificationManager.notify(0, builder.build());\n }", "private void sendNotification(String msg) {\n\n mNotificationManager = (NotificationManager) this.getSystemService(Context.NOTIFICATION_SERVICE);\n\n PendingIntent contentIntent = PendingIntent.getActivity(this, 0,new Intent(this, ServiceListActivity.class), 0);\n\n NotificationCompat.Builder mBuilder =new NotificationCompat.Builder(this)\n .setSmallIcon(R.drawable.ic_launcher)\n .setContentTitle(\"Ruta Plus\")\n .setStyle(new NotificationCompat.BigTextStyle()\n .bigText(msg))\n .setContentText(msg);\n\n mBuilder.setContentIntent(contentIntent);\n mNotificationManager.notify(NOTIFICATION_ID, mBuilder.build());\n }", "public void sendNotification(String notifTitle, String notifText) {\n\n }", "protected void pushNotification(String userID, String message){\n }", "static void sendNotifications() {\n\t\testablishConnection();\n\t\tSystem.out.println(\"sending multiple notificatiosn\");\n\t}", "private void showNotification() {\n\n Intent intent = new Intent(this, DashboardActivity.class);\n TaskStackBuilder stackBuilder = TaskStackBuilder.create(this);\n stackBuilder.addParentStack(DashboardActivity.class);\n stackBuilder.addNextIntent(intent);\n\n final NotificationCompat.Builder builder = new NotificationCompat.Builder(this);\n\n builder.setSmallIcon(R.drawable.ic_gps);\n builder.setContentText(getText(R.string.local_service_started));\n builder.setContentTitle(getText(R.string.local_service_label));\n builder.setOngoing(true);\n builder.setContentIntent(stackBuilder.getPendingIntent(0, PendingIntent.FLAG_UPDATE_CURRENT));\n\n final Notification notification = builder.build();\n\n // Send the notification.\n mNotificationManager.notify(NOTIFICATION, notification);\n }", "public void sendToActivity(String message){\n //In questo metodo \"avviso\" l'app che è arrivato un nuovo dato dal raspberry.\n\n Intent intent = new Intent(\"NOTIFY_ACTIVITY\");\n\n if(message != null){\n intent.putExtra(\"CURRENT_ACTIVITY\",message);\n }\n\n //invio messaggio tramite broadcaster\n broadcast.sendBroadcast(intent);\n\n }", "@Override\n public void onReceive(Context context, Intent intent) {\n NotificationCompat.Builder builder = new NotificationCompat.Builder(context, \"channel\")\n .setSmallIcon(R.drawable.ic_baseline_message_24)\n .setContentTitle(\"You have an upcoming event!!\")\n .setContentText(\"Click on the message to view more\")\n .setPriority(NotificationCompat.PRIORITY_HIGH);\n NotificationManagerCompat notificationManager = NotificationManagerCompat.from( context);\n notificationManager.notify(200,builder.build());\n }", "private void sendNotification(String notificationTitle, String notificationBody){//, String dataTitle, String dataMessage) {\n Intent intent = new Intent(this, Login.class);\n// intent.putExtra(\"title\", dataTitle);\n// intent.putExtra(\"message\", dataMessage);\n intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);\n PendingIntent pendingIntent = PendingIntent.getActivity(this, 0 /* Request code */, intent,\n PendingIntent.FLAG_ONE_SHOT);\n\n Uri defaultSoundUri= RingtoneManager.getDefaultUri(RingtoneManager.TYPE_NOTIFICATION);\n\n Notification notification = new NotificationCompat.Builder(this,getString(R.string.notificationChannelId))\n .setSmallIcon(R.drawable.notification_icon)\n .setContentTitle(notificationTitle)\n .setContentText(notificationBody)\n .setStyle(new NotificationCompat.BigTextStyle()\n .bigText(notificationBody))\n .setContentIntent(pendingIntent)\n .setAutoCancel(true)\n .setSound(defaultSoundUri)\n .build();\n\n\n NotificationManager notificationManager =\n (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);\n\n int randomNotificationId=new Random().nextInt(100)+1;\n notificationManager.notify(randomNotificationId, notification);\n\n\n\n// notificationManager.notify(0 /* ID of notification */, notificationBuilder.build());\n }", "private void sendNotification(String notificationDetails) {\n // Create an explicit content Intent that starts the main Activity.\n Intent notificationIntent = new Intent(getApplicationContext(), MainActivity.class);\n\n // Construct a task stack.\n TaskStackBuilder stackBuilder = TaskStackBuilder.create(this);\n\n // Add the main Activity to the task stack as the parent.\n stackBuilder.addParentStack(MainActivity.class);\n\n // Push the content Intent onto the stack.\n stackBuilder.addNextIntent(notificationIntent);\n\n // Get a PendingIntent containing the entire back stack.\n PendingIntent notificationPendingIntent =\n stackBuilder.getPendingIntent(0, PendingIntent.FLAG_UPDATE_CURRENT);\n\n // Get a notification builder that's compatible with platform versions >= 4\n NotificationCompat.Builder builder = new NotificationCompat.Builder(this);\n\n // Define the notification settings.\n builder.setSmallIcon(R.drawable.ic_action_likeable)\n // In a real app, you may want to use a library like Volley\n // to decode the Bitmap.\n .setLargeIcon(BitmapFactory.decodeResource(getResources(),\n R.drawable.ic_action_likeable))\n .setColor(Color.RED)\n .setContentTitle(\"Uncertainties\")\n .setContentText(notificationDetails)\n .setStyle(new NotificationCompat.BigTextStyle().bigText(notificationDetails))\n .setContentIntent(notificationPendingIntent);\n\n // Dismiss notification once the user touches it.\n builder.setAutoCancel(true);\n\n // Get an instance of the Notification manager\n NotificationManager mNotificationManager =\n (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);\n\n // Issue the notification\n mNotificationManager.notify(0, builder.build());\n }", "@Override\n public void onReceive(Context context, Intent intent) {\n Log.i(\"BASH\", \"Notification sent\");\n\n Log.i(\"BASH\", \"RECIEVED\");\n\n createNotification(context, \"Times up\", \"5 sec\", \"as\");\n\n }", "private void sendHeadlinerNotification() {\n startService(new Intent(this, ForegroundNotificationService.class));\n }", "private void sendMyNotification(String title, String message, String type, String Branch_Id) {\n\n\n Intent intent = new Intent(this, ActivityWithNavigationMenuPatient.class);\n intent.putExtra(\"push\", \"1\");\n intent.putExtra(\"Branch_Id\", Branch_Id);\n\n intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);\n\n PendingIntent pendingIntent = PendingIntent.getActivity(this, 0, intent, PendingIntent.FLAG_ONE_SHOT);\n\n Uri soundUri = RingtoneManager.getDefaultUri(RingtoneManager.TYPE_NOTIFICATION);\n NotificationCompat.Builder notificationBuilder = new NotificationCompat.Builder(this)\n .setSmallIcon(R.mipmap.ic_launcher)\n .setContentTitle(title)\n .setContentText(message)\n .setAutoCancel(true)\n .setSound(soundUri)\n .setChannelId(\"my_channel_id_00011\") // set channel id\n .setContentIntent(pendingIntent);\n\n NotificationManager notificationManager =\n (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);\n\n notificationManager.notify(1224, notificationBuilder.build());\n }", "private void handleActionNotification() {\n String result = getQuote(stringsArray);\n// Notification myNotification = new Notification.Builder(this)\n// .setAutoCancel(true)\n// .setDefaults(Notification.DEFAULT_ALL)\n// .setWhen(System.currentTimeMillis())\n// .setSmallIcon(R.mipmap.ic_launcher)\n// .setContentText(result)\n// .build();\n//\n// NotificationManagerCompat manager = NotificationManagerCompat.from(this);\n// manager.notify(0, myNotification);\n\n\n NotificationCompat.Builder builder = new NotificationCompat.Builder(this)\n .setSmallIcon(R.mipmap.ic_launcher)\n .setContentTitle(\"My notification\")\n .setContentText(result);\n\n NotificationManager notificationManager = (NotificationManager)this\n .getSystemService(Context.NOTIFICATION_SERVICE);\n int id = 1;\n notificationManager.notify(id, builder.build());\n }", "@JavascriptInterface\n\tpublic void sendNotification(int notifications) {\n\t\tLog.d(TAG_NAME, \"NotificationWebInterface::sendNotification\");\n\t\tif (notifications > 0)\n\t\t\tToast.makeText(context, \"You have \" + notifications + \" new message(s)\", Toast.LENGTH_SHORT).show();\n\t}", "private PendingIntent getNotificationIntent() {\n Intent resultIntent = new Intent(this, ScheduleNotificationActivity.class);\n // Because clicking the notification opens a new (\"special\") activity, there's\n // no need to create an artificial back stack.\n return PendingIntent.getActivity(\n this,\n 0,\n resultIntent,\n PendingIntent.FLAG_ONE_SHOT\n );\n }", "private void sendNotification(JSONObject notification, final String staffID) {\r\n JsonObjectRequest jsonObjectRequest = new JsonObjectRequest(FCM_API, notification,\r\n new Response.Listener<JSONObject>() {\r\n @Override\r\n public void onResponse(JSONObject response) {\r\n Toast.makeText(BookingListDetails.this, \"\"+ staffID + \" has been Notified!\", Toast.LENGTH_SHORT).show();\r\n Log.i(TAG, \"onResponse: \" + response);\r\n }\r\n },\r\n new Response.ErrorListener() {\r\n @Override\r\n public void onErrorResponse(VolleyError error) {\r\n Toast.makeText(BookingListDetails.this, \"Request error\", Toast.LENGTH_LONG).show();\r\n Log.i(TAG, \"onErrorResponse: Didn't work\");\r\n }\r\n }) {\r\n @Override\r\n public Map<String, String> getHeaders() throws AuthFailureError {\r\n Map<String, String> params = new HashMap<>();\r\n params.put(\"Authorization\", serverKey);\r\n params.put(\"Content-Type\", contentType);\r\n return params;\r\n }\r\n };\r\n MySingleton.getInstance(getApplicationContext()).addToRequestQueue(jsonObjectRequest);\r\n }", "private void sendNotification(String ttl, String messageBody) {\n Intent intent = new Intent(this, ActivitySplash.class);\n\n intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);\n PendingIntent pendingIntent = PendingIntent.getActivity(this, 0 /* Request code */, intent,\n PendingIntent.FLAG_ONE_SHOT);\n\n Uri defaultSoundUri = RingtoneManager.getDefaultUri(RingtoneManager.TYPE_NOTIFICATION);\n NotificationCompat.Builder notificationBuilder = new NotificationCompat.Builder(this);\n if (android.os.Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) {\n notificationBuilder.setSmallIcon(R.mipmap.splash_screen_logo);\n notificationBuilder.setColor(getResources().getColor(R.color.white));\n } else {\n notificationBuilder.setSmallIcon(R.mipmap.logo);\n }\n notificationBuilder.setContentTitle(ttl)\n .setContentText(messageBody)\n // .setStyle(new NotificationCompat.BigPictureStyle().bigPicture(image))/*Notification with Image*/\n .setAutoCancel(true)\n .setStyle(new NotificationCompat.BigTextStyle().bigText(messageBody))\n .setLargeIcon(BitmapFactory.decodeResource(getResources(), R.mipmap.logo))\n .setSound(defaultSoundUri)\n .setContentIntent(pendingIntent);\n\n NotificationManager notificationManager =\n (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);\n\n notificationManager.notify(0 /* ID of notification */, notificationBuilder.build());\n }", "private void notifyUser(Context context, String message) {\n\n Uri soundUri = RingtoneManager.getDefaultUri(RingtoneManager.TYPE_NOTIFICATION);\n\n Intent intent = new Intent(context, MovieActivity.class);\n PendingIntent pendingIntent = PendingIntent.getActivity(context, 0, intent,\n PendingIntent.FLAG_UPDATE_CURRENT);\n\n NotificationManager manager = (NotificationManager)\n context.getSystemService(Context.NOTIFICATION_SERVICE);\n\n android.support.v4.app.NotificationCompat.Builder builder = new NotificationCompat.Builder(context)\n .setContentTitle(\"device is now \" + message + \".\")\n .setOngoing(true)\n .setVibrate(new long[]{0, 500, 500, 500, 500, 500, 500})\n .setSound(soundUri)\n .setContentIntent(pendingIntent)\n .setSmallIcon(android.R.drawable.sym_def_app_icon)\n .setAutoCancel(true);\n\n manager.notify(1001, builder.build());\n\n }", "public void sendNotification(String type, int fromId, int commentId, int articleId) {\n Map<String, String> content = new HashMap<String, String>();\n content.put(\"reply\", \"{from} replied your comment for {article}, check it out!\");\n //more to add to assist with upcoming services\n\n CommentAdder comment = CommentAdder.dao.findById(commentId);\n int toId = comment.get(\"user_id\"); //user_id of whom is getting this notification\n\n UserAdder fromUserSheet = UserAdder.dao.findById(fromId);\n String fromUser = fromUserSheet.get(\"username\");\n\n ContentAdder article = ContentAdder.dao.findById(articleId);\n String articleTitle = article.get(\"title\");\n String articleUrl = article.get(\"en_title\");\n\n String notificationText = Integer.toString(commentId).length() +\n \":\" + commentId + content.get(type).replace(\"{from}\",fromUser)\n .replace(\"{article}\",articleTitle);\n Date now = new Date();\n DateFormat simpleFormat = new SimpleDateFormat(\"yyyy-MM-dd HH:mm:ss\");\n\n new NotificationAdder().set(\"title\", type).set(\"text\", notificationText).set(\"url\",articleUrl).set(\"type\", type)\n .set(\"from_user_id\",fromId).set(\"to_user_id\",toId).set(\"create_time\", simpleFormat.format(now)).save();\n\n }", "private void sendNotification(String msg) {\r\n\t\tmNotificationManager = (NotificationManager)\r\n\t\t\t\tthis.getSystemService(Context.NOTIFICATION_SERVICE);\r\n\t\tBundle chat = new Bundle();\r\n\t\tchat.putString(\"claimedBy\", uid);\r\n\t\tchat.putString(\"uid\", claimedBy);\r\n\r\n\t\tIntent intent = new Intent();\r\n\t\tintent.putExtras(chat);\r\n\t\t\r\n\t\tNotificationCompat.Builder mBuilder = new NotificationCompat.Builder(this)\r\n\t\t.setSmallIcon(R.drawable.divvylogo)\r\n\t\t.setContentTitle(\"You've been matched\")\r\n\t\t.setAutoCancel(true)\r\n\t\t.setStyle(new NotificationCompat.BigTextStyle()\r\n\t\t.bigText(msg))\r\n\t\t.setContentText(msg);\r\n\r\n\t\tIntent resultIntent = new Intent(this, ChatAfterMatch.class);\r\n\t\tresultIntent.putExtras(chat);\r\n\t\t\r\n\t\t// The stack builder object will contain an artificial back stack for the\r\n\t\t// started Activity.\r\n\t\t// This ensures that navigating backward from the Activity leads out of\r\n\t\t// your application to the Home screen.\r\n\t\tTaskStackBuilder stackBuilder = TaskStackBuilder.create(this);\r\n\t\t\r\n\t\t// Adds the back stack for the Intent (but not the Intent itself)\r\n\t\tstackBuilder.addParentStack(ChatAfterMatch.class);\r\n\t\t\r\n\t\t// Adds the Intent that starts the Activity to the top of the stack\r\n\t\tstackBuilder.addNextIntent(resultIntent);\r\n\t\tPendingIntent resultPendingIntent =\r\n\t\t\t\tstackBuilder.getPendingIntent(\r\n\t\t\t\t\t\t0,\r\n\t\t\t\t\t\tPendingIntent.FLAG_UPDATE_CURRENT\r\n\t\t\t\t\t\t);\r\n\t\tmBuilder.setContentIntent(resultPendingIntent);\r\n\t\tNotificationManager mNotificationManager =\r\n\t\t\t\t(NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);\r\n\t\tmNotificationManager.notify(NOTIFICATION_ID, mBuilder.build());\r\n\t}", "@Override\r\n\tpublic void sendNotification(String notificationType) {\n\t\t\r\n\t}", "public void notify(String userId);", "private void showNotificationCourse(Bundle data) {\n\n/* try {\n int unreadNotificationCount = Integer.valueOf(data.getString(\"total_unread_notification\"));\n NotificationCountEventBus.Event event = new NotificationCountEventBus.Event(unreadNotificationCount);\n NotificationCountEventBus.getInstance().post(event);\n } catch (Exception ignored) {\n\n }*/\n\n // check the type_push from data and navigate to activity\n Intent intent = navigateNotification(data);\n\n PendingIntent pendingIntent = PendingIntent.getActivity(this, notificationId, intent,\n PendingIntent.FLAG_UPDATE_CURRENT | PendingIntent.FLAG_ONE_SHOT);\n\n\n Uri defaultSoundUri = RingtoneManager.getDefaultUri(RingtoneManager.TYPE_NOTIFICATION);\n NotificationCompat.Builder notificationBuilder = new NotificationCompat.Builder(this)\n .setSmallIcon(getNotificationIcon())\n .setContentTitle(data.getString(\"title\"))\n .setContentText(data.getString(\"body\"))\n .setAutoCancel(true)\n .setSound(defaultSoundUri)\n .setContentIntent(pendingIntent);\n\n NotificationManager notificationManager =\n (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);\n\n notificationManager.notify(notificationId++, notificationBuilder.build());\n }", "public void sendNotification(View view) {\n\n NotificationManager nm= (NotificationManager) getSystemService(NOTIFICATION_SERVICE);\n\n if(Build.VERSION.SDK_INT>=Build.VERSION_CODES.O){\n\n //We have to create a notification channel\n NotificationChannel nc = new NotificationChannel(\"srminterns\",\"SRM NOTIFICATIONS\",NotificationManager.IMPORTANCE_HIGH);\n nm.createNotificationChannel(nc);\n\n }\n\n // we have to normally write notification code.\n\n NotificationCompat.Builder builder=new NotificationCompat.Builder(this,\"srminterns\");\n builder.setSmallIcon(R.drawable.umbrella);\n builder.setContentTitle(\"Sample Notification\");\n builder.setContentText(\"This is the description of the notification\");\n builder.setAutoCancel(true);\n\n /* Pending Intent\n * - It is the description of the operation to be performed\n * - can be created using the following methods\n * -getActivity() - if you want to open an activity with pending Intent\n * -getService() - if you want to strat a service with Pending Intent\n * -getBroadcast() - if you want to send a broadcast with Pending Intent\n *\n * Requires 4 Arguments\n * -context\n * -Pending Intent ID (Can be any Integer)\n * -Intent(Action that you want to perform)\n * - FLAG (This flag will tell the existing pending Intent about what to do if there\n * is a new Pending Intent (Arrival) */\n\n PendingIntent pi = PendingIntent.getActivity(this,12,new Intent(this, MainActivity.class)\n ,PendingIntent.FLAG_UPDATE_CURRENT);\n\n builder.setContentIntent(pi);\n\n /*\n * Step1: is to convert any image format that you want to display into a Bitmap image format\n * Step2: is to create bigPicture style before you issue the notification.\n *\n *\n *\n *\n * */\n\n Bitmap bitmap= BitmapFactory.decodeResource(getResources(),R.drawable.kathmandu);\n builder.setStyle(new NotificationCompat.BigPictureStyle().bigPicture(bitmap));\n nm.notify(42,builder.build());\n }", "private void sendNotification(String messageBody) {\n Log.d(TAG, messageBody);\n NotificationManager mNotificationManager =\n (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);\n if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.O) {\n NotificationChannel channel = new NotificationChannel(\"default\",\n \"oqatt\",\n NotificationManager.IMPORTANCE_DEFAULT);\n channel.setDescription(\"oqatt_updates\");\n channel.setImportance(IMPORTANCE_HIGH);\n assert mNotificationManager != null;\n mNotificationManager.createNotificationChannel(channel);\n }\n Uri defaultSoundUri = RingtoneManager.getDefaultUri(RingtoneManager.TYPE_NOTIFICATION);\n NotificationCompat.Builder mBuilder = new NotificationCompat.Builder(getApplicationContext(), \"default\")\n .setSmallIcon(R.mipmap.oqatt_logo) // notification icon\n .setContentTitle(messageBody) // title for notification\n .setSound(defaultSoundUri) // sound notification\n .setAutoCancel(true); // clear notification after click\n\n Intent intent = new Intent(getApplicationContext(), MainActivity.class);\n PendingIntent pi = PendingIntent.getActivity(this, 0, intent, PendingIntent.FLAG_UPDATE_CURRENT);\n mBuilder.setContentIntent(pi);\n assert mNotificationManager != null;\n mNotificationManager.notify(0, mBuilder.build());\n }", "public void sendStatusUpdateNotification() {\n\n ParseQuery<ParseObject> query = ParseQuery.getQuery(\"IncidentReports\");\n query.whereEqualTo(\"username\", ParseUser.getCurrentUser().getUsername());\n query.whereEqualTo(\"notified\", \"false\");\n query.findInBackground(new FindCallback<ParseObject>() {\n @Override\n public void done(List<ParseObject> objects, ParseException e) {\n if (e == null && objects.size()>0) {\n\n Intent activityIntent = new Intent(getApplicationContext(), MyActivity.class);\n PendingIntent contentIntent = PendingIntent.getActivity(getApplicationContext(), 0,activityIntent, 0);\n\n String message = \"An incident report you have submitted has been reviewed. Go to 'My Activity' to view update.\";\n android.app.Notification notification = new NotificationCompat.Builder(mContext, StarterApplication.CHANNEL_1_ID)\n .setSmallIcon(R.drawable.unnamed)\n .setLargeIcon(BitmapFactory.decodeResource(mContext.getResources(),\n R.drawable.unnamed))\n .setContentTitle(\"Status Update\")\n .setContentText(message)\n .setStyle(new NotificationCompat.BigTextStyle())\n .setPriority(NotificationCompat.PRIORITY_HIGH)\n .setCategory(NotificationCompat.CATEGORY_MESSAGE)\n .setContentIntent(contentIntent)\n .build();\n\n for (ParseObject object : objects) {\n object.put(\"notified\", \"true\");\n object.saveInBackground();\n }\n\n notificationManager.notify(1, notification);\n Log.i(\"Notification\", \"sent\");\n\n }\n\n else {\n Log.i(\"Notification\", \"Not sent\");\n if (e != null) {\n Log.i(\"Error:\", e.getMessage());\n }\n\n\n }\n }\n });\n }", "void showNotification() {\n Intent notificationIntent = new Intent(mContext, MainActivity.class);\n\n // Construct a task stack.\n TaskStackBuilder stackBuilder = TaskStackBuilder.create(mContext);\n\n // Add the main Activity to the task stack as the parent.\n stackBuilder.addParentStack(MainActivity.class);\n\n // Push the content Intent onto the stack.\n stackBuilder.addNextIntent(notificationIntent);\n\n // Get a PendingIntent containing the entire back stack.\n PendingIntent notificationPendingIntent =\n stackBuilder.getPendingIntent(0, PendingIntent.FLAG_UPDATE_CURRENT);\n\n Notification.Builder notificationBuilder = new Notification.Builder(mContext)\n .setContentTitle(getLocationResultTitle())\n .setContentText(getLocationResultText())\n .setSmallIcon(R.mipmap.ic_launcher)\n .setAutoCancel(true)\n .setContentIntent(notificationPendingIntent);\n\n getNotificationManager().notify(0, notificationBuilder.build());\n }", "@Override\r\n public void onClick(View v) {\n try {\r\n postDatatoServer(\"accept_request\", notification.toJSON());\r\n fetchDatafromServer(\"notifications\");\r\n } \r\n catch (JSONException e) {\r\n e.printStackTrace();\r\n }\r\n }", "@Override\n public void onNotificationPosted(StatusBarNotification sbn) {\n\n if(isConnected()) {\n cone = ConnectBlActivity.con;\n //Here every notification is checked and if the user wands to listen to facebook, we get the message\n if (getFb()) {\n\n\n if (sbn.getPackageName().equals(\"com.facebook.orca\")) { //checking if the is a notification from facebook\n Bundle extras = sbn.getNotification().extras;\n String title;\n\n\n if (!extras.getString(\"android.text\").equals(\"Chat heads active\")) {\n String pack = \"Facebook\";\n title = extras.getString(\"android.text\"); //This is the actual user that sends the message\n String text = extras.getCharSequence(\"android.title\").toString(); //and that is the actual message\n\n\n Log.i(\"Title\", title);\n Log.i(\"Text\", text);\n\n\n //The message is being put in a String Builder\n StringBuilder msg = new StringBuilder();\n msg.append(pack);\n msg.append(\"\\n\");\n msg.append(text);\n msg.append(\"\\n\");\n msg.append(title);\n\n //The ui gets updated with the message\n Main.t.setText(msg);\n\n\n //The message is written to the outputStream\n\n byte[] send = msg.toString().getBytes();\n try {\n cone.write(String.valueOf(msg));\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n }\n }\n\n\n //Here every notification is checked and if the user wands to listen to instagram, we get the message\n if (getInsta()) {\n if (sbn.getPackageName().equals(\"com.instagram.android\")) { //checking if the is a notification from facebook\n Bundle extras = sbn.getNotification().extras;\n String title = extras.getString(\"android.text\"); //This is the actual user that sends the message\n String text = extras.getCharSequence(\"android.title\").toString(); //and that is the actual message\n\n SimpleDateFormat sdff = new SimpleDateFormat(\"HH:mm\", Locale.getDefault());\n String tempf = sdff.format(new Date());\n\n\n Log.i(\"Title\", title);\n Log.i(\"Text\", text);\n\n\n //The message is being put in a String Builder\n StringBuilder msg = new StringBuilder();\n msg.append(\"`\");\n msg.append(tempf);\n msg.append(\" \");\n msg.append(text);\n msg.append(\" \");\n msg.append(title);\n\n //The ui gets updated with the message\n Main.t.setText(msg);\n\n\n //The message is written to the outputStream\n try {\n cone.write(String.valueOf(msg));\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n }\n }\n }", "private void sendNotification(Bundle extra) {\n\n if(CMAppGlobals.DEBUG) Logger.i(TAG, \":: GCMIntentService.sendNotification : extra : \" + extra);\n\n// int message = R.string.gcm_message;\n String message = extra.getString(\"message\");\n String status = extra.getString(\"status\");\n String orderId = extra.getString(\"order_id\");\n\n if(CMAppGlobals.DEBUG) Logger.i(TAG, \":: GCMIntentService.sendNotification : message : \" + message);\n if(CMAppGlobals.DEBUG) Logger.i(TAG, \":: GCMIntentService.sendNotification : status : \" + status);\n\n\n GCMMessages receivedStatus = GCMMessages.NONE;\n\n String type = extra.getString(\"type\");\n if (type != null && type.equals(\"webview\")){\n\n String subtitle = extra.getString(\"subtitle\");\n String title = extra.getString(\"title\");\n String url = extra.getString(\"url\");\n if (url != null && !url.isEmpty())\n EventBus.getDefault().post(new WebViewDialogMessage(url));\n\n GCMUtils.GCMNotifyWebViewNews(this, title, subtitle, GCMMessages.WEB_VIEW_NEWS.ordinal(), new WebViewDialogMessage(url));\n }\n\n if (status != null) {\n if (TextUtils.equals(status, \"AM\")) {\n receivedStatus = GCMMessages.AM;\n GCMUtils.GCMNotifyUI(this, message, receivedStatus.ordinal(),\n orderId);\n } else if (TextUtils.equals(status, \"R\")) {\n receivedStatus = GCMMessages.R;\n GCMUtils.GCMNotifyUI(this, message, receivedStatus.ordinal(),\n orderId);\n } else if (TextUtils.equals(status, \"A\")) {\n receivedStatus = GCMMessages.A;\n GCMUtils.GCMNotifyUI(this, message, receivedStatus.ordinal(),\n orderId);\n } else if (TextUtils.equals(status, \"CC\")) {\n receivedStatus = GCMMessages.CC;\n GCMUtils.GCMNotifyUI(this, message, receivedStatus.ordinal(),\n orderId);\n } else if (TextUtils.equals(status, \"NC\")) {\n receivedStatus = GCMMessages.NC;\n GCMUtils.GCMNotifyUI(this, message, receivedStatus.ordinal(),\n orderId);\n } else if (TextUtils.equals(status, \"SC\")) {\n receivedStatus = GCMMessages.SC;\n GCMUtils.GCMNotifyUI(this, message, receivedStatus.ordinal(),\n orderId);\n } else if (TextUtils.equals(status, \"BR\")) {\n receivedStatus = GCMMessages.BR;\n GCMUtils.GCMNotifyUI(this, message, receivedStatus.ordinal(),\n orderId);\n } else if (TextUtils.equals(status, \"RC\")) {\n receivedStatus = GCMMessages.RC;\n GCMUtils.GCMNotifyUI(this, message, receivedStatus.ordinal(),\n orderId);\n } else if (TextUtils.equals(status, \"OW\")) {\n receivedStatus = GCMMessages.OW;\n GCMUtils.GCMNotifyUI(this, message, receivedStatus.ordinal(),\n orderId);\n }\n\n else {\n if(CMAppGlobals.DEBUG)Logger.i(TAG, \":: GCMIntentService : JSON CASE \");\n try {\n JSONObject json = new JSONObject(status);\n if(CMAppGlobals.DEBUG)Logger.i(TAG, \":: GCMIntentService : json : \" + json.toString());\n\n if (json != null) {\n String orderStatus = JsonParser.getString(json,\n \"status\");\n if (orderStatus != null\n && TextUtils.equals(orderStatus, \"CP\")) {\n receivedStatus = GCMMessages.CP;\n String price = json.optString(\"price\");\n String bonus = json.optString(\"bonus\");\n String time = json.optString(\"time\");\n\n GCMUtils.GCMNotifyUIEx(this, message,\n receivedStatus.ordinal(), orderId, price,\n time, bonus);\n } else if (TextUtils.equals(orderStatus, \"AR\")) {\n return;\n } else if (TextUtils.equals(orderStatus, \"AM\")) {\n receivedStatus = GCMMessages.AM;\n GCMUtils.GCMNotifyUI(this, message, receivedStatus.ordinal(),\n orderId);\n } else if (TextUtils.equals(orderStatus, \"R\")) {\n receivedStatus = GCMMessages.R;\n GCMUtils.GCMNotifyUI(this, message, receivedStatus.ordinal(),\n orderId);\n } else if (TextUtils.equals(orderStatus, \"A\")) {\n receivedStatus = GCMMessages.A;\n GCMUtils.GCMNotifyUI(this, message, receivedStatus.ordinal(),\n orderId);\n } else if (TextUtils.equals(orderStatus, \"CC\")) {\n receivedStatus = GCMMessages.CC;\n GCMUtils.GCMNotifyUI(this, message, receivedStatus.ordinal(),\n orderId);\n } else if (TextUtils.equals(orderStatus, \"NC\")) {\n receivedStatus = GCMMessages.NC;\n GCMUtils.GCMNotifyUI(this, message, receivedStatus.ordinal(),\n orderId);\n } else if (TextUtils.equals(orderStatus, \"SC\")) {\n receivedStatus = GCMMessages.SC;\n GCMUtils.GCMNotifyUI(this, message, receivedStatus.ordinal(),\n orderId);\n } else if (TextUtils.equals(orderStatus, \"BR\")) {\n receivedStatus = GCMMessages.BR;\n GCMUtils.GCMNotifyUI(this, message, receivedStatus.ordinal(),\n orderId);\n } else if (TextUtils.equals(orderStatus, \"RC\")) {\n receivedStatus = GCMMessages.RC;\n GCMUtils.GCMNotifyUI(this, message, receivedStatus.ordinal(),\n orderId);\n } else if (TextUtils.equals(orderStatus, \"OW\")) {\n receivedStatus = GCMMessages.OW;\n GCMUtils.GCMNotifyUI(this, message, receivedStatus.ordinal(),\n orderId);\n }\n }\n } catch (JSONException e) {\n // TODO Auto-generated catch block\n e.printStackTrace();\n }\n }\n }\n\n // notifies user\n if (LocServicePreferences.getAppSettings().getString(\n LocServicePreferences.Settings.NEWS_WEBVIEW_MESSAGE.key(), \"\") != null\n && !LocServicePreferences.getAppSettings()\n .getString(LocServicePreferences.Settings.NEWS_WEBVIEW_MESSAGE.key(), \"\")\n .isEmpty()) {\n NotificationManager mNotificationManager = (NotificationManager) CMApplication\n .getAppContext().getSystemService(\n Context.NOTIFICATION_SERVICE);\n Class<?> startClass = MainActivity.class;\n Intent resultIntent = new Intent(CMApplication.getAppContext(), startClass);\n resultIntent.putExtra(\"WEBVIEW\", \"WEBVIEW\");\n TaskStackBuilder stackBuilder = TaskStackBuilder.create(CMApplication.getAppContext());\n // Adds the back stack\n stackBuilder.addParentStack(startClass);\n // Adds the Intent to the top of the stack\n stackBuilder.addNextIntent(resultIntent);\n // Gets a PendingIntent containing the entire back stack\n PendingIntent resultPendingIntent = PendingIntent.getActivity(\n getApplicationContext(), 0, resultIntent,\n PendingIntent.FLAG_UPDATE_CURRENT);\n\n NotificationCompat.Builder mBuilder = new NotificationCompat.Builder(\n CMApplication.getAppContext())\n .setSmallIcon(R.drawable.ic_nf_small)\n .setDefaults(Notification.DEFAULT_SOUND)\n .setAutoCancel(true)\n .setContentTitle(\n CMApplication.getAppContext().getString(\n R.string.app_name))\n .setStyle(\n new NotificationCompat.BigTextStyle()\n .bigText(LocServicePreferences\n .getAppSettings()\n .getString(\n LocServicePreferences.Settings.NEWS_WEBVIEW_MESSAGE\n .key(), \"\")\n .toString()))\n .setContentText(\n LocServicePreferences.getAppSettings().getString(\n LocServicePreferences.Settings.NEWS_WEBVIEW_MESSAGE.key(), \"\"));\n LocServicePreferences.getAppSettings().setSetting(\n LocServicePreferences.Settings.NEWS_WEBVIEW_MESSAGE, \"\");\n\n mBuilder.setContentIntent(resultPendingIntent);\n mNotificationManager.notify(0, mBuilder.build());\n\n } else if ((receivedStatus != GCMMessages.NONE)\n && TextUtils.isEmpty(orderId)) {\n// Utils.generateNotification(this, receivedStatus, orderId, -1);\n }\n\n }", "private void sendNotification(Map<String, String> data) {\n int num = ++NOTIFICATION_ID;\n Bundle msg = new Bundle();\n for (String key : data.keySet()) {\n Log.e(key, data.get(key));\n msg.putString(key, data.get(key));\n }\n\n\n pref = getSharedPreferences(\"UPDATE_INSTANCE\", MODE_PRIVATE);\n edit = pref.edit();\n Intent backIntent;\n Intent intent = null;\n PendingIntent pendingIntent = null;\n backIntent = new Intent(getApplicationContext(), LoginActivity.class);\n backIntent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);\n SharedPreferences sp;\n SharedPreferences.Editor editor;\n\n\n if (!is_noty) {\n mNotificationManager = (NotificationManager) this\n .getSystemService(Context.NOTIFICATION_SERVICE);\n NotificationCompat.Builder mBuilder = new NotificationCompat.Builder(\n this);\n\n mBuilder.setSmallIcon(R.drawable.ic_launcher)\n .setContentTitle(msg.getString(\"title\"))\n .setStyle(\n new NotificationCompat.BigTextStyle().bigText(msg\n .getString(\"msg\").toString()))\n .setAutoCancel(true)\n .setContentText(msg.getString(\"msg\"));\n\n if (Integer.parseInt(msg.getString(\"type\")) != 1) {\n mBuilder.setContentIntent(pendingIntent);\n }\n\n mBuilder.setDefaults(Notification.DEFAULT_ALL);\n\n mNotificationManager.notify(++NOTIFICATION_ID, mBuilder.build());\n }\n }", "private void sendNotification(String msg) {\n mNotificationManager = (NotificationManager) getApplicationContext()\n .getSystemService(Context.NOTIFICATION_SERVICE);\n\n PendingIntent contentIntent = PendingIntent.getActivity(this, 0,\n new Intent(this, MainActivity.class),\n PendingIntent.FLAG_UPDATE_CURRENT);\n\n NotificationCompat.Builder mBuilder = new NotificationCompat.Builder(\n this).setSmallIcon(R.mipmap.ic_launcher)\n .setContentTitle(\"GCM Notification\")\n .setStyle(new NotificationCompat.BigTextStyle().bigText(msg))\n .setContentText(msg);\n\n mBuilder.setContentIntent(contentIntent);\n mNotificationManager.notify(NOTIFICATION_ID, mBuilder.build());\n\n }", "@Override\n public void onReceive(Context context, Intent intent) {\n\n NotificationChannel notificationChannel = new NotificationChannel(\"CHANNELID\", \"name\", NotificationManager.IMPORTANCE_HIGH );\n NotificationManager notificationManager = context.getSystemService(NotificationManager.class);\n\n notificationManager.createNotificationChannel(notificationChannel);\n\n Intent i = new Intent(context, DisplayMedication.class);\n\n // FIXME - hardcoded values\n i.putExtra(\"MedicationName\",\"Vicodin\" + \"\");\n i.putExtra(\"DoseAmount\",\"1\" + \"\");\n i.putExtra(\"HourlyFrequency\",\"2\" + \"\");\n i.putExtra(\"DaysBetweenDose\",\"7\" + \"\");\n /* <--- above this line ---> */\n\n\n PendingIntent pendingIntent = PendingIntent.getActivity(context, 0, i, PendingIntent.FLAG_UPDATE_CURRENT);\n\n\n NotificationCompat.Builder builder = new NotificationCompat.Builder(context, \"CHANNELID\")\n .setSmallIcon(R.drawable.icon)\n .setContentTitle(\"Medication Time\")\n .setContentText(\"Time to take a medication\")\n .setPriority(NotificationManager.IMPORTANCE_HIGH)\n .setContentIntent(pendingIntent);\n NotificationManagerCompat notificationManagerCompat = NotificationManagerCompat.from(context);\n notificationManagerCompat.notify(0, builder.build());\n\n\n }", "public void createNotificationChannel(Activity activity) {\n\n if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {\n\n CharSequence name = \"notifier\";\n String description = \"notifies the firebaseUser about app activities\";\n\n int importance = NotificationManager.IMPORTANCE_DEFAULT;\n\n NotificationChannel channel = new NotificationChannel(CHANNEL_ID, name, importance);\n channel.setDescription(description);\n // Register the channel with the system; you can't change the importance\n // or other notification behaviors after this\n NotificationManager notificationManager = activity.getSystemService(NotificationManager.class);\n notificationManager.createNotificationChannel(channel);\n }\n }", "private void sendNotification(String msg) {\n mNotificationManager = (NotificationManager)\n ctx.getSystemService(Context.NOTIFICATION_SERVICE);\n\n PendingIntent contentIntent = PendingIntent.getActivity(ctx, 0,\n new Intent(ctx, LLActivity.class), 0);\n\n NotificationCompat.Builder mBuilder =\n new NotificationCompat.Builder(ctx)\n .setSmallIcon(R.drawable.ic_stat_gcm)\n .setContentTitle(\"GCM Notification\")\n .setStyle(new NotificationCompat.BigTextStyle()\n .bigText(msg))\n .setContentText(msg);\n\n mBuilder.setContentIntent(contentIntent);\n mNotificationManager.notify(NOTIFICATION_ID, mBuilder.build());\n }", "private void sendNotification(String msg) {\n Uri hejsound = Uri.parse(\"android.resource://\" + getApplicationContext().getPackageName() + \"/\" + R.raw.hejsound);\n long[] notifyVibrate = {0, 200, 100, 200};\n Intent hejIntent = new Intent(this, MyActivity.class);\n hejIntent.putExtra(\"sender\", msg);\n Intent respondIntent = new Intent(this, respondHejService.class); //An intent to be used by the ReplyTo button\n respondIntent.putExtra(\"sender\", msg);\n respondIntent.putExtra(\"respondTo\", msg);\n PendingIntent respondToIntent = PendingIntent.getService(this, msg.hashCode(), respondIntent, PendingIntent.FLAG_CANCEL_CURRENT);\n PendingIntent contentIntent = PendingIntent.getActivity(this, msg.hashCode(), hejIntent, PendingIntent.FLAG_CANCEL_CURRENT);\n\n NOTIFICATION_ID = msg.hashCode();\n\n if (SDK_INT >= Build.VERSION_CODES.HONEYCOMB_MR1) {\n\n NotificationManager mNotificationManager = (NotificationManager)\n this.getSystemService(Context.NOTIFICATION_SERVICE);\n\n NotificationCompat.Builder mBuilder =\n new NotificationCompat.Builder(this)\n .addAction(R.drawable.arrow, \"Send Hej Back\", respondToIntent)\n .setAutoCancel(true)\n .setSmallIcon(R.drawable.ic_launcher)\n .setContentTitle(\"Hej\")\n .setTicker(\"Hej from \" + msg + \"!\")\n .setVibrate(notifyVibrate)\n .setSound(hejsound)\n .setPriority(Notification.PRIORITY_MAX)\n .setLights(0xFFFF8B00, 200, 200)\n .setContentText(\"Hej from \" + msg + \"!\");\n\n\n mBuilder.setContentIntent(contentIntent);\n mNotificationManager.notify(NOTIFICATION_ID, mBuilder.build());\n\n\n } else { //Sander Edition\n NotificationManager notificationManager = (NotificationManager)getSystemService(Context.NOTIFICATION_SERVICE);\n System.out.println(\"what the fuck\");\n int icon = R.drawable.ic_launcher;\n CharSequence text = \"Hej from \" + msg + \"!\";\n CharSequence contentTitle = \"Hej\";\n CharSequence contentText = \"Hej from \" + msg + \"!\";\n long when = System.currentTimeMillis();\n\n Notification notification = new Notification(icon,text,when);\n\n notification.vibrate = notifyVibrate;\n notification.sound = hejsound;\n notification.ledARGB = 0xFFFF8B00;\n notification.ledOffMS = 200;\n notification.ledOnMS = 200;\n\n notification.setLatestEventInfo(this, contentTitle, contentText, contentIntent);\n\n notificationManager.notify(NOTIFICATION_ID, notification);\n\n\n }\n }", "private static void generateNotification(Context context, Bundle bundle) {\n\t\tint icon = R.drawable.icon;\n\t\tlong when = System.currentTimeMillis();\n\t\tString message = bundle.getString(\"message\");\n\t\tNotificationManager notificationManager = (NotificationManager) context\n\t\t\t\t.getSystemService(Context.NOTIFICATION_SERVICE);\n\t\tNotification notification = new Notification(icon, message, when);\n\t\tString title = context.getString(R.string.app_name);\n\t\tIntent notificationIntent = new Intent(context, NetasDemoActivity.class);\n\n\t\tnotificationIntent.putExtras(bundle);\n\n\t\t// set intent so it does not start a new activity\n\t\tnotificationIntent.setFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP\n\t\t\t\t| Intent.FLAG_ACTIVITY_NEW_TASK);\n\t\tPendingIntent intent = PendingIntent.getActivity(context, 0,\n\t\t\t\tnotificationIntent, PendingIntent.FLAG_UPDATE_CURRENT);\n\t\tnotification.defaults |= Notification.DEFAULT_SOUND\n\t\t\t\t| notification.DEFAULT_LIGHTS | notification.DEFAULT_VIBRATE;\n\t\t// long[] vibrate = {0,100,200,300};\n\t\t// notification.vibrate = vibrate;\n\t\tnotification.setLatestEventInfo(context, title, message, intent);\n\t\tnotification.flags |= Notification.FLAG_AUTO_CANCEL\n\t\t\t\t| Notification.FLAG_SHOW_LIGHTS;\n\t\tnotification.ledOnMS = 1000; // light on in milliseconds\n\t\tnotification.ledOffMS = 4000; // light off in milliseconds\n\t\tnotificationManager.notify(0, notification);\n\t}", "private void notifyUser(List<String> result) {\r\n\t\t\tif(Util.getProperty(getApplicationContext(),\"notificationTimeChanged\",\"\").equals(\"true\") \r\n\t\t\t\t\t|| !notifiedToday())\r\n\t\t\t{\r\n\t\t\t\tUtil.setProperty(getApplicationContext(), \"notificationTimeChanged\", \"false\");\r\n\t\t\t\tif(result.size() > 0){\r\n\t\t\t\t\tint itemsDue = result.size();\r\n\t\t\t\t\tStringBuffer notificationText = new StringBuffer();\r\n\t\t\t\t\tfor(int i=0; i<itemsDue; i++){\r\n\t\t\t\t\t\tif(i!=0)\r\n\t\t\t\t\t\t\tnotificationText.append(\", \");\r\n\t\t\t\t\t\tnotificationText.append(result.get(i));\t\t\t\t\r\n\t\t\t\t\t}\r\n\t\t\t\t\tContext context = getApplicationContext();\r\n\t\t\t\t\tNotificationManager nm = (NotificationManager)context.getSystemService(NOTIFICATION_SERVICE);\r\n\t\t\t\t\tIntent notificationIntent = new Intent(context,ReminderActivity.class);\r\n\t\t\t\t\tPendingIntent pi = PendingIntent.getActivity(context, 0, notificationIntent,PendingIntent.FLAG_UPDATE_CURRENT | PendingIntent.FLAG_ONE_SHOT);\r\n\t\t\t\t\tNotification n = new Notification.Builder(context)\r\n\t\t\t\t\t.setContentTitle(String.valueOf(itemsDue) + \" Items Due\")\r\n\t\t\t\t\t.setContentText(notificationText.toString())\r\n\t\t\t\t\t.setSmallIcon(R.drawable.ic_launcher)\r\n\t\t\t\t\t//.setLargeIcon(R.drawable.ic_basket)\r\n\t\t\t\t\t.setContentIntent(pi)\r\n\t\t\t\t\t.build();\t \r\n\t\t\t\t\tnm.notify(1, n);\r\n\t\t\t\t}\r\n\t\t\t\tSimpleDateFormat formatter = new SimpleDateFormat(\"dd-MMM-yyyy\",Locale.US);\r\n\t\t\t\tUtil.setProperty(getApplicationContext(), \"ServiceLastRanOn\",formatter.format(new Date()));\r\n\t\t\t}\r\n\t\t}", "private void showNotification() {\n\n NotificationCompat.Builder mBuilder =\n new NotificationCompat.Builder(this)\n .setSmallIcon(R.drawable.food_icon2)\n .setContentTitle(\"Let's eat\")\n .setContentText(\"Good morning, It's time to take your Breakfast :)\");\n\n int mNotificationId = 001;\n\n\n Intent contentIntent = new Intent(this, RecommendationActivity.class);\n contentIntent.putExtra(\"dePagi\", \"pagigan\");\n TaskStackBuilder stackBuilder = TaskStackBuilder.create(this);\n stackBuilder.addParentStack(RecommendationActivity.class);\n stackBuilder.addNextIntent(contentIntent);\n\n PendingIntent resultPendingIntent =\n stackBuilder.getPendingIntent(\n 0,\n PendingIntent.FLAG_UPDATE_CURRENT\n );\n mBuilder.setContentIntent(resultPendingIntent);\n\n mBuilder.setVibrate(new long[] { 1000, 1000, 1000, 1000, 1000 });\n mBuilder.setLights(Color.YELLOW, 3000, 3000);\n\n mBuilder.setAutoCancel(true);\n\n mNM =(NotificationManager) getSystemService(NOTIFICATION_SERVICE);\n\n mNM.notify(mNotificationId, mBuilder.build());\n\n stopSelf();\n\n }", "public static void createNotification1(Context context, Reminder reminder) {\n\n\n Intent intent = new Intent(context, SplashActivity.class);\n intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);\n PendingIntent pendingIntent = PendingIntent.getActivity(context, 0 /* Request code */, intent,\n PendingIntent.FLAG_ONE_SHOT);\n\n String channelId = context.getString(R.string.default_notification_channel_id);\n Uri defaultSoundUri = RingtoneManager.getDefaultUri(RingtoneManager.TYPE_NOTIFICATION);\n NotificationCompat.Builder notificationBuilder =\n new NotificationCompat.Builder(context, channelId)\n .setSmallIcon(R.mipmap.ic_launcher)\n .setContentTitle(reminder.getTitle())\n .setContentText(reminder.getContent())\n .setAutoCancel(true)\n .setSound(defaultSoundUri)\n .setContentIntent(pendingIntent);\n\n NotificationManager notificationManager =\n (NotificationManager) context.getSystemService(Context.NOTIFICATION_SERVICE);\n\n // Since android Oreo notification channel is needed.\n if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {\n NotificationChannel channel = new NotificationChannel(channelId,\n \"Channel human readable title\",\n NotificationManager.IMPORTANCE_DEFAULT);\n notificationManager.createNotificationChannel(channel);\n }\n\n notificationManager.notify(0 /* ID of notification */, notificationBuilder.build());\n\n DeleteNotification(reminder,context);\n }", "private void sendNotification(String title, String messageBody) {\n Intent intent = new Intent(this, MainActivity.class);\n intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);\n PendingIntent pendingIntent = PendingIntent.getActivity(this, 0, intent,\n PendingIntent.FLAG_ONE_SHOT);\n\n Log.d(TAG, \"sendNotification: \" + messageBody + title);\n\n Uri defaultSoundUri = RingtoneManager.getDefaultUri(RingtoneManager.TYPE_NOTIFICATION);\n NotificationCompat.Builder notificationBuilder = new NotificationCompat.Builder(this)\n .setSmallIcon(android.R.mipmap.sym_def_app_icon)\n .setContentTitle(title)\n .setContentText(messageBody)\n .setAutoCancel(true)\n .setSound(defaultSoundUri)\n .setContentIntent(pendingIntent).addAction(new NotificationCompat.Action(\n android.R.drawable.sym_call_missed,\n \"Cancel\",\n PendingIntent.getActivity(this, 0, intent, PendingIntent.FLAG_CANCEL_CURRENT)))\n .addAction(new NotificationCompat.Action(\n android.R.drawable.sym_call_outgoing,\n \"OK\",\n PendingIntent.getActivity(this, 0, intent, PendingIntent.FLAG_CANCEL_CURRENT)));\n ;\n\n NotificationManager notificationManager =\n (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);\n\n notificationManager.notify(0, notificationBuilder.build());\n\n Log.d(TAG, \"sendNotification: \" + messageBody + title);\n }", "private void showSimpleNotification() {\n Notification notification = new NotificationCompat.Builder(getActivity())\n //Title of the notification\n .setContentTitle(getString(R.string.nf_simple_title))\n //Content of the notification once opened\n .setContentText(getString(R.string.nf_simple_message))\n //This bit will show up in the notification area in devices that support that\n .setTicker(getString(R.string.nf_simple_ticker))\n //Icon that shows up in the notification area\n .setSmallIcon(R.drawable.ic_notify)\n //Icon that shows up in the drawer\n .setLargeIcon(BitmapFactory.decodeResource(getActivity().getResources(), R.drawable.ic_launcher))\n //Set the intent\n .setContentIntent(pendingIntentForNotification())\n //Build the notification with all the stuff you've just set.\n .build();\n\n //Add the auto-cancel flag to make it dismiss when clicked on\n //This is a bitmask value so you have to pipe-equals it.\n notification.flags |= Notification.FLAG_AUTO_CANCEL;\n\n //Grab the NotificationManager and post the notification\n NotificationManager notificationManager = (NotificationManager)\n getActivity().getSystemService(Context.NOTIFICATION_SERVICE);\n\n //Set a tag so that the same notification doesn't get reposted over and over again and\n //you can grab it again later if you need to.\n notificationManager.notify(TAG_SIMPLE_NOTIFICATION, notification);\n }", "public static void sendNotificationTransactionDetail(Context ctx, String message, long type_id, int notifyId) {\n Intent notificationIntent = new Intent(ctx.getApplicationContext(), TransactionDetailActivity.class);\n notificationIntent.setAction(\"shang_\" + System.currentTimeMillis());\n notificationIntent.putExtra(\"entity_id\", type_id);\n\n// // Construct a task stack.\n// TaskStackBuilder stackBuilder = TaskStackBuilder.create(ctx);\n//\n// // Add the main Activity to the task stack as the parent.\n// stackBuilder.addParentStack(DealDetailActivity.class);\n//\n// // Push the content Intent onto the stack.\n// stackBuilder.addNextIntent(notificationIntent);\n//\n// // Get a PendingIntent containing the entire back stack.\n// PendingIntent notificationPendingIntent = stackBuilder.getPendingIntent(0, PendingIntent.FLAG_UPDATE_CURRENT);\n\n PendingIntent notificationPendingIntent = PendingIntent.getActivity(ctx.getApplicationContext(), notifyId, notificationIntent, PendingIntent.FLAG_UPDATE_CURRENT);\n // Get a notification builder that's compatible with platform versions >= 4\n NotificationCompat.Builder builder = new NotificationCompat.Builder(ctx);\n\n // Define the notification settings.\n builder.setContentTitle(\"Shang\").setContentText(message).setContentIntent(notificationPendingIntent);\n\n // Dismiss notification once the user touches it.\n builder.setAutoCancel(true);\n\n builder.setPriority(NotificationCompat.PRIORITY_HIGH);\n\n if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) {\n builder.setSmallIcon(R.drawable.icon_noti);\n builder.setLargeIcon(BitmapFactory.decodeResource(ctx.getResources(), R.drawable.icon_v2));\n } else {\n builder.setSmallIcon(R.drawable.icon_v2);\n }\n\n builder.setVibrate(new long[]{1000, 500});\n\n\n // Get an instance of the Notification manager\n NotificationManager mNotificationManager = (NotificationManager) ctx.getSystemService(Context.NOTIFICATION_SERVICE);\n\n // Issue the notification\n mNotificationManager.notify(notifyId, builder.build());\n }", "private void createNotification(int icon, String name, String auto_manual, String secondText, int color) {\n\n Intent notificationIntent = new Intent(this, SyncopyActivity.class);\n\n PendingIntent pendingIntent = PendingIntent.getActivity(this,\n 0, notificationIntent, 0);\n Notification notification = new NotificationCompat.Builder(this, CHANNEL_ID)\n .setContentTitle(name)\n .setContentText(secondText)\n .setSubText(String.format(\"(%s)\", auto_manual))\n .setSmallIcon(icon)\n .setColor(getResources().getColor(color))\n .setContentIntent(pendingIntent)\n .setVibrate(null)\n .setSound(null)\n .setPriority(NotificationManager.IMPORTANCE_LOW)\n .build();\n\n synchronized (notification){\n notification.notify();\n }\n\n startForeground(1, notification);\n\n\n }", "public void sendIncidentNotification() {\n\n final ParseQuery<ParseObject> pendingNotifs = ParseQuery.getQuery(\"PendingNotifications\");\n pendingNotifs.whereEqualTo(\"username\", ParseUser.getCurrentUser().getUsername());\n pendingNotifs.findInBackground(new FindCallback<ParseObject>() {\n @Override\n public void done(List<ParseObject> objects, ParseException e) {\n if ( e == null) {\n if (objects.size()>0) {\n for (ParseObject object : objects) {\n String type = object.getString(\"type\");\n\n Intent activityIntent = new Intent(getApplicationContext(), MyNeighbourhood.class);\n PendingIntent contentIntent = PendingIntent.getActivity(NotificationAbstract.this, 0,activityIntent, 0);\n\n String message = \"A new \" + type + \" incident has occurred in your neighbourhood. Check 'my Neighbourhood' to view details\";\n android.app.Notification notification = new NotificationCompat.Builder(mContext, StarterApplication.CHANNEL_1_ID)\n .setSmallIcon(R.drawable.unnamed)\n .setLargeIcon(BitmapFactory.decodeResource(mContext.getResources(),\n R.drawable.unnamed))\n .setContentTitle(\"New \" + type + \" Incident\")\n .setContentText(message)\n .setStyle(new NotificationCompat.BigTextStyle())\n .setPriority(NotificationCompat.PRIORITY_HIGH)\n .setCategory(NotificationCompat.CATEGORY_MESSAGE)\n .setContentIntent(contentIntent)\n .build();\n\n notificationManager.notify(1, notification);\n Log.i(\"NotificationIncident\", \"sent\");\n\n ParseUser.getCurrentUser().put(\"notifiedUpdated\", \"true\");\n try {\n object.delete();\n } catch (ParseException e1) {\n e1.printStackTrace();\n }\n ParseUser.getCurrentUser().saveInBackground();\n\n }\n }\n }\n }\n });\n\n\n if (ParseUser.getCurrentUser().getString(\"notifiedUpdated\").matches(\"false\")) {\n Log.i(\"Incident:\", \"Incident notification needs to be sent\");\n // the user is NOT up to date, so query incidents\n\n\n\n }\n\n else {\n Log.i(\"Incident\", \"Incident notification not sending\");\n String stat = ParseUser.getCurrentUser().getString(\"pending\");\n if (stat != null){\n\n }\n else {\n\n }\n }\n }", "public void sendRecordingNotification(){\n\n NotificationCompat.Builder mBuilder = (android.support.v7.app.NotificationCompat.Builder) new NotificationCompat.Builder(this)\n .setSmallIcon(R.drawable.road)\n .setContentTitle(\"Sprint LT is recording your session\")\n .setContentText(mySession.getTrackName());\n // .setContentIntent(pendingIntent);\n\n NotificationManager mNotificationManager =\n (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);\n\n mNotificationManager.notify(mRecordingNotificationID, mBuilder.build());\n\n }", "private void notifyUser() {\r\n //Start add into notification fragment process\r\n notify = new Notify();\r\n DatabaseReference NotRef = FirebaseDatabase.getInstance().getReference().child(\"Notify\");\r\n notify.setBookID(getBookID.getText().toString());\r\n notify.setUserID(getUID.getText().toString());\r\n String key = NotRef.push().getKey();\r\n notify.setNotifyID(key);\r\n NotRef.child(key).setValue(notify);\r\n\r\n //Update notify status\r\n DatabaseReference dbNotify = FirebaseDatabase.getInstance().getReference(\"Booking\").child(getUID.getText().toString()).child(getBookID.getText().toString());\r\n HashMap<String, Object> hashMap = new HashMap<>();\r\n hashMap.put(\"notifyStatus\", \"Approved\");\r\n dbNotify.updateChildren(hashMap);\r\n\r\n //Send push notification\r\n String StaffID = id.getText().toString();\r\n TOPIC = \"/topics/\" + StaffID.toLowerCase(); //topic must match with what the receiver subscribed to\r\n Log.v(TAG,StaffID);\r\n NOTIFICATION_TITLE = \"FKOM Car Booking\";\r\n NOTIFICATION_MESSAGE = \"Dear \" + name.getText().toString() + \", Your Booking \" + getBookID.getText().toString() + \" has been approved!\";\r\n\r\n JSONObject notification = new JSONObject();\r\n JSONObject notificationBody = new JSONObject();\r\n try {\r\n notificationBody.put(\"title\", NOTIFICATION_TITLE);\r\n notificationBody.put(\"message\", NOTIFICATION_MESSAGE);\r\n\r\n notification.put(\"to\", TOPIC);\r\n notification.put(\"data\", notificationBody);\r\n } catch (JSONException e) {\r\n Log.e(TAG, \"onCreate: \" + e.getMessage());\r\n }\r\n sendNotification(notification, StaffID);\r\n }", "private void sendNotification(RemoteMessage remoteMessage) {\n\n Intent intent = selectIntent(remoteMessage);\n\n intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);\n PendingIntent pendingIntent = PendingIntent.getActivity(\n this\n , MyFirebaseMessagingServiceRequestCode /* Request code */\n , intent,\n PendingIntent.FLAG_ONE_SHOT\n );\n\n String channelId = getString(R.string.default_notification_channel_id);\n NotificationCompat.Builder notificationBuilder =\n new NotificationCompat.Builder(this, channelId)\n .setSmallIcon(R.drawable.ic_person_24dp) //// TODO: 07/11/2017 app icon\n .setContentTitle(remoteMessage.getNotification().getTitle())\n .setContentText(remoteMessage.getNotification().getBody())\n .setAutoCancel(true)\n .setContentIntent(pendingIntent);\n\n NotificationManager notificationManager =\n (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);\n\n notificationManager.notify(getNotificationID()/* ID of notification */, notificationBuilder.build());\n }", "private void showNotification() {\n\n }", "public NotificationCompat.Builder getChannel1Notification(String message){\n\n Intent confirmIntent = new Intent(this, Alarm2Activity.class); //can create an activity here that simply says \"Take med\"\n confirmIntent.setFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP | Intent.FLAG_ACTIVITY_SINGLE_TOP);\n confirmIntent.setAction(YES_ACTION);\n\n Intent openAppIntent = new Intent(this, MedicineActivity.class); //can create an activity here that simply says \"Take med\"\n openAppIntent.setFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP | Intent.FLAG_ACTIVITY_SINGLE_TOP);\n\n //processIntentAction(getIntent()); //where to put this???\n\n NotificationCompat.Builder notificationBuilder = new NotificationCompat.Builder(getApplicationContext(), Channel1_ID)\n .setContentTitle(getString(R.string.med_notif_title))\n .setContentText(message)\n .setContentIntent(PendingIntent.getActivity(this, REQUEST_CODE, openAppIntent, PendingIntent.FLAG_UPDATE_CURRENT))\n .setSmallIcon(R.drawable.ic_blur_circular_black_24dp) //setLargeIcon as a picture of a pill\n .addAction(new NotificationCompat.Action(\n R.drawable.ic_blur_circular_black_24dp,\n getString(R.string.confirm_med_taken),\n PendingIntent.getActivity(this, REQUEST_CODE, confirmIntent, PendingIntent.FLAG_UPDATE_CURRENT)))\n .setCategory(NotificationCompat.CATEGORY_REMINDER)\n .setAutoCancel(true);\n //.setTimeOutAfter()\n //.setStyle(new NotificationCompat.BigTextStyle().bigText(context.getString(message)))\n //.setColor(ContextCompat.getColor(context, R.color.colorPrimary))\n //.setTimeOutAfter();\n\n if(Build.VERSION.SDK_INT >= Build.VERSION_CODES.KITKAT && Build.VERSION.SDK_INT < Build.VERSION_CODES.O){\n notificationBuilder.setPriority(NotificationCompat.PRIORITY_HIGH);\n }\n\n return notificationBuilder;\n }", "private void sendNotification(String message) {\n Intent intent = new Intent(this, MainActivity.class);\n intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);\n PendingIntent pendingIntent = PendingIntent.getActivity(this, 0 /* Request code */, intent,\n PendingIntent.FLAG_ONE_SHOT);\n\n Uri defaultSoundUri= RingtoneManager.getDefaultUri(RingtoneManager.TYPE_NOTIFICATION);\n NotificationCompat.Builder notificationBuilder = new NotificationCompat.Builder(this)\n .setSmallIcon(R.drawable.ic_check_circle_black_24dp)\n .setContentTitle(\"Welcome Aboard\")\n .setContentText(message)\n .setAutoCancel(true)\n .setSound(defaultSoundUri)\n .setContentIntent(pendingIntent);\n\n NotificationManager notificationManager =\n (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);\n\n notificationManager.notify(0 /* ID of notification */, notificationBuilder.build());\n }", "private void generateNotification(Context context, String m) {\n message = m;\n handler.post(new Runnable() {\n public void run() {\n Context context = GCMIntentService.this;\n int icon = getResources().getIdentifier(\"ic_launcher\", \"drawable\", context.getPackageName());//R.drawable.ic_launcher;\n long when = System.currentTimeMillis();\n NotificationManager notificationManager = (NotificationManager)\n context.getSystemService(Context.NOTIFICATION_SERVICE);\n Notification notification = new Notification(icon, message, when);\n \n Intent notificationIntent = new Intent(GCMIntentService.this, UnityPlayerActivity.class);\n // set intent so it does not start a new activity\n notificationIntent.setFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP |\n Intent.FLAG_ACTIVITY_SINGLE_TOP);\n PendingIntent intent =\n PendingIntent.getActivity(context, 0, notificationIntent, 0);\n notification.setLatestEventInfo(context, NOTIFICATION_TITLE, message, intent);\n \n // Flags\n notification.flags |= Notification.FLAG_AUTO_CANCEL;\n //notification.defaults |= Notification.DEFAULT_SOUND;\n //notification.defaults |= Notification.DEFAULT_VIBRATE; // uncomment and add VIBRATE permissions on manifest to get vibrating notifications\n notificationManager.notify(0, notification);\n }\n });\n \n }", "public void oreo(String t, String d){\n String id = \"messange\";\n\n NotificationManager nm = (NotificationManager) getApplicationContext().getSystemService(Context.NOTIFICATION_SERVICE);\n NotificationCompat.Builder builder = new NotificationCompat.Builder(getApplicationContext(),id);\n Uri soundUri = RingtoneManager.getDefaultUri(RingtoneManager.TYPE_ALARM);\n Intent intent = new Intent(getApplicationContext(), Menu_principla_Activity.class);\n\n if(Build.VERSION.SDK_INT >= Build.VERSION_CODES.O){\n NotificationChannel nc = new NotificationChannel(id,\"nuevo\",NotificationManager.IMPORTANCE_HIGH);\n nc.setDescription(\"Notification FCM\");\n nc.setShowBadge(true);\n assert nm != null;\n System.out.println(\"Bandera 1\");\n nm.createNotificationChannel(nc);\n }\n/*\n\n\n // intent.setFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP | Intent.FLAG_ACTIVITY_SINGLE_TOP);\n PendingIntent pendingIntent = PendingIntent.getActivity(getApplicationContext(),1,intent, PendingIntent.FLAG_UPDATE_CURRENT);\n\n builder.setAutoCancel(true)\n .setWhen(System.currentTimeMillis())\n .setContentTitle(t).setCategory(Notification.CATEGORY_SERVICE)\n .setDefaults(Notification.DEFAULT_ALL)\n .setSound(soundUri)\n .setTicker(\"Nueva notification\")\n .setSmallIcon(R.mipmap.ic_launcher)\n .setContentText(d)\n .setContentIntent(pendingIntent)\n .setContentInfo(\"nuevo\")\n .setVibrate(new long[]{100, 200, 300, 400, 500, 400, 300, 200, 400});\n\n Random random = new Random();\n int idNotify = random.nextInt(8000);\n\n assert nm != null;\n nm.notify(idNotify,builder.build());\n\n */\n PendingIntent pendingIntent = PendingIntent.getActivity(getApplicationContext(),1,intent, PendingIntent.FLAG_UPDATE_CURRENT);\n notification = new NotificationCompat.Builder(getApplicationContext())\n .setContentIntent(pendingIntent)\n .setSmallIcon(R.drawable.ic_medical_services_black_24dp)\n .setSound(soundUri)\n .setAutoCancel(true)\n .setContentTitle(t).setCategory(Notification.CATEGORY_SERVICE)\n .setContentText(d).build();\n nm.notify(1,notification);\n\n System.out.println(\"Bandera 2\");\n }", "public void showNotification(String title,String message)\n {\n\n Bitmap icon = BitmapFactory.decodeResource(this.getResources(),\n R.drawable.girl);\n// NotificationCompat.Builder builder = new NotificationCompat.Builder(this,\"Notify\")\n// .setContentTitle(title).setSmallIcon(R.drawable.common_google_signin_btn_icon_dark)\n\n// // .addAction(R.drawable.user,\"Pay\",payInent)\n// //.addAction(R.drawable.user,\"Pay Later\",payLaterInent)\n// .setDefaults(Notification.DEFAULT_ALL)\n// .setPriority(NotificationManager.IMPORTANCE_HIGH)\n// .setAutoCancel(true).setContentText(message).setLargeIcon(icon)\n// .setStyle(new NotificationCompat.BigPictureStyle()\n// .bigPicture(icon).bigLargeIcon(null));\n\n// NotificationCompat.Builder builder;\n// builder = new NotificationCompat.Builder(this, \"Notify\");\n// builder.setContentTitle(title) // required\n// .setSmallIcon(R.drawable.user) // required\n// .setContentText(message) // required\n// .setStyle(new NotificationCompat.BigPictureStyle()\n// .bigPicture(icon).setSummaryText(\"\"))\n// .setAutoCancel(true)\n// .setVibrate(new long[]{100, 200, 300, 400, 500, 400, 300, 200, 400})\n// .setSound(Settings.System.DEFAULT_NOTIFICATION_URI)\n// .setPriority(NotificationCompat.PRIORITY_HIGH)\n// ;\n\n Notification notification = null;\n if( message.charAt(0) == 'C' )\n {\n// Intent intent = new Intent(this, PayLater.class);\n Intent intent = new Intent(this, PayLaterTest.class);\n PendingIntent payInent = PendingIntent.getActivity(MyMessagingService.this, 0, intent, 0);\n notification = new NotificationCompat.Builder(this, \"Notify\")\n .setSmallIcon(android.R.drawable.ic_dialog_info)\n .setContentTitle(title)\n .setContentText(message)\n .setDefaults(Notification.DEFAULT_ALL)\n .setPriority(NotificationCompat.PRIORITY_DEFAULT)\n .setVibrate(new long[0])// heads-up\n .addAction(R.drawable.user,\"Pay\",payInent)\n .setAutoCancel(true)\n .build();\n }\n else if( message.charAt(0) == 'G' )\n {\n //start activity go in\n Intent intent = new Intent(this, PayActivity.class);\n PendingIntent payInent = PendingIntent.getActivity(MyMessagingService.this, 0, intent, 0);\n notification = new NotificationCompat.Builder(this, \"Notify\")\n .setSmallIcon(android.R.drawable.ic_dialog_info)\n .setContentTitle(title)\n .setContentText(message)\n .setDefaults(Notification.DEFAULT_ALL)\n .setPriority(NotificationCompat.PRIORITY_DEFAULT)\n .setVibrate(new long[0])// heads-up\n .addAction(R.drawable.user,\"Verify\",payInent)\n .setAutoCancel(true)\n .build();\n }\n else if( message.charAt(0) == 'I' )\n {\n //start activity invalid slot\n// Intent intent = new Intent(this, PayActivity.class);\n\n// PendingIntent payInent = PendingIntent.getActivity(MyMessagingService.this, 0, intent, 0);\n notification = new NotificationCompat.Builder(this, \"Notify\")\n .setSmallIcon(android.R.drawable.ic_dialog_info)\n .setContentTitle(title)\n .setContentText(message)\n .setDefaults(Notification.DEFAULT_ALL)\n .setPriority(NotificationCompat.PRIORITY_DEFAULT)\n .setAutoCancel(true)\n .setVibrate(new long[0])// heads-up\n // .addAction(R.drawable.user,\"Verify\",payInent)\n .build();\n }\n\n m = (NotificationManager) getSystemService(getApplicationContext().NOTIFICATION_SERVICE);;\n m.notify(999,notification);\n // m.cancel(999);\n }", "private void sendNotification(final String msg) {\n mNotificationManager = (NotificationManager)\n GcmIntentService.this.getSystemService(Context.NOTIFICATION_SERVICE);\n PendingIntent contentIntent = PendingIntent.getActivity(GcmIntentService.this, 0,\n new Intent(GcmIntentService.this, MainActivity.class), 0);\n\n NotificationCompat.Builder mBuilder =\n new NotificationCompat.Builder(GcmIntentService.this)\n .setSmallIcon(R.drawable.pplogo)\n .setAutoCancel(true)\n .setContentTitle(\"PawPads\")\n .setStyle(new NotificationCompat.BigTextStyle()\n .bigText(msg))\n .setContentText(msg);\n\n mBuilder.setContentIntent(contentIntent);\n mNotificationManager.notify(NOTIFICATION_ID, mBuilder.build());\n }", "private void sendNotification(Context context, int transitionType) {\n Intent notificationIntent = new Intent(context, MainActivity.class);\n notificationIntent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);\n // Construct a task stack.\n TaskStackBuilder stackBuilder = TaskStackBuilder.create(context);\n\n // Add the main Activity to the task stack as the parent.\n stackBuilder.addParentStack(MainActivity.class);\n\n // Push the content Intent onto the stack.\n stackBuilder.addNextIntent(notificationIntent);\n\n // Get a PendingIntent containing the entire back stack.\n PendingIntent notificationPendingIntent =\n stackBuilder.getPendingIntent(0, PendingIntent.FLAG_UPDATE_CURRENT);\n\n // Get a notification builder\n NotificationCompat.Builder builder = new NotificationCompat.Builder(context);\n\n // Check the transition type to display the relevant icon image\n if (transitionType == Geofence.GEOFENCE_TRANSITION_ENTER) {\n builder.setSmallIcon(R.drawable.ic_volume_off_white_24dp)\n .setLargeIcon(BitmapFactory.decodeResource(context.getResources(),\n R.drawable.ic_volume_off_white_24dp))\n .setContentTitle(context.getString(R.string.silent_mode_activated));\n } else if (transitionType == Geofence.GEOFENCE_TRANSITION_EXIT) {\n builder.setSmallIcon(R.drawable.ic_volume_up_white_24dp)\n .setLargeIcon(BitmapFactory.decodeResource(context.getResources(),\n R.drawable.ic_volume_up_white_24dp))\n .setContentTitle(context.getString(R.string.back_to_normal));\n }\n\n // Continue building the notification\n builder.setContentText(context.getString(R.string.touch_to_relaunch));\n builder.setContentIntent(notificationPendingIntent);\n\n // Dismiss notification once the user touches it.\n builder.setAutoCancel(true);\n\n // Get an instance of the Notification manager\n NotificationManager mNotificationManager =\n (NotificationManager) context.getSystemService(Context.NOTIFICATION_SERVICE);\n\n // Issue the notification\n mNotificationManager.notify(0, builder.build());\n }", "@Override\n public void execute(DelegateExecution execution) throws Exception {\n\tlogger.info(\"NotificationActivity Task Started\");\n\tLoanApplicationReqeust sc = (LoanApplicationReqeust) execution.getVariable(ProcessConstants.VAR_CTX);\n\tMessageRequest messageRequest = new MessageRequest();\n\t\n\tmessageRequest.setServiceName(ProcessConstants.SERVICE_NAME_NOTIFICATION);\n\tlogger.info(\"NotificationActivity Task completed\\n\\n\");\n }", "private void StartNotifyActivity()\r\n\t{\n \tIntent intent = new Intent();\r\n\t\tintent.setClass(this, NotifyDateActivity.class);\r\n\t\t// Set time\r\n\t\tBundle Parameters = new Bundle();\r\n\t\tParameters.putString(OneNote.KEY_NOTIFYTIME, HelperFunctions.Calendar2String(AddOneNote.NotifyTime));\r\n\t\tParameters.putInt(OneNote.KEY_NOTIFYDURA, AddOneNote.NotifyDura);\r\n\t\tParameters.putString(OneNote.KEY_RINGMUSIC, AddOneNote.RingMusic);\r\n\t\tParameters.putInt(OneNote.KEY_NOTIFYMETHOD, AddOneNote.NotifyMethod);\r\n // Pass it to next activity \r\n\t\tintent.putExtras(Parameters);\r\n\t\t// Go to next activity(set note's notify time activity)\r\n\t\tstartActivityForResult(intent, ProjectConst.ACTIVITY_SET_NOTIFYTIME);\t\t\r\n\t}", "private void showNotification() {\n CharSequence text = \"Running\";\n\n // The PendingIntent to launch our activity if the user selects this notification\n PendingIntent contentIntent = PendingIntent.getActivity(this, 0,\n new Intent(this, MainActivity.class), 0);\n\n // Set the info for the views that show in the notification panel.\n Notification notification = new Notification.Builder(this)\n //.setSmallIcon(R.drawable.stat_sample) // the status icon\n .setTicker(text) // the status text\n //.setWhen(System.currentTimeMillis()) // the time stamp\n .setContentTitle(\"PodcastFTPService\") // the label of the entry\n .setContentText(text) // the contents of the entry\n .setContentIntent(contentIntent) // The intent to send when the entry is clicked\n .build();\n\n // Send the notification.\n mNM.notify(0, notification);\n }", "public static void noti(Context context, String title, String content, int notifyid) {\n NotificationCompat.Builder builder = new NotificationCompat.Builder(context);\n builder.setContentTitle(title)\n .setContentText(content)\n .setSmallIcon(R.mipmap.ic_launcher);\n builder.setDefaults(Notification.DEFAULT_SOUND);\n// Creates an Intent for the Activity\n Intent notifyIntent =\n new Intent(context, SmartCabinetDeviceListActivity.class);\n// Sets the Activity to start in a new, empty task\n notifyIntent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK\n | Intent.FLAG_ACTIVITY_CLEAR_TASK);\n// Creates the PendingIntent\n PendingIntent notifyPendingIntent =\n PendingIntent.getActivity(\n context,\n 0,\n notifyIntent,\n PendingIntent.FLAG_UPDATE_CURRENT\n );\n// Puts the PendingIntent into the notification builder\n builder.setContentIntent(notifyPendingIntent);\n// Notifications are issued by sending them to the\n// NotificationManager system service.\n NotificationManager mNotificationManager =\n (NotificationManager) context.getSystemService(Context.NOTIFICATION_SERVICE);\n// Builds an anonymous Notification object from the builder, and\n// passes it to the NotificationManager\n mNotificationManager.notify(notifyid, builder.build());\n }", "public void notifyJoueurActif();", "public void sendNotification(String task, int id) {\n NotificationCompat.Builder builder = new NotificationCompat.Builder(getApplicationContext());\n builder.setContentTitle(\"Amigo ToDo Manager\");\n builder.setContentText(task);\n\n //Create a pending intent to attach with the notif\n Intent i = new Intent(getApplicationContext(), ToDoEditActivity.class);\n Uri todoUri = Uri.parse(ToDoContentProvider.CONTENT_URI + \"/\" + id);\n i.putExtra(ToDoContentProvider.CONTENT_ITEM_TYPE, todoUri);\n PendingIntent pIntent = PendingIntent.getActivity(getApplicationContext(), 101, i, PendingIntent.FLAG_UPDATE_CURRENT);\n builder.setContentIntent(pIntent);\n builder.setSmallIcon(R.mipmap.ic_launcher);\n builder.setAutoCancel(true);\n Notification notif = builder.build();\n\n notificationManager.notify(101, notif);\n\n }", "@Override\n public void onReceive(Context context, Intent intent){\n NotificationCompat.Builder builder = new NotificationCompat.Builder(context, \"myCalendar\")\n .setSmallIcon(R.mipmap.ic_launcher_round)\n .setContentTitle(\"Calendar App\")\n .setContentText(\"Event Reminder!\")\n .setAutoCancel(true)\n .setPriority(NotificationCompat.PRIORITY_DEFAULT);\n\n NotificationManagerCompat notificationManager = NotificationManagerCompat.from(context);\n\n notificationManager.notify(154, builder.build()); //building the notification with the info\n }", "void notify(PushMessage m);", "public abstract void sendNotification(String sendFrom, List<Object> sendTo, String sendToProperty, NoticeTemplate noticeTemplate, Object noticeData);", "private void showArrivalNotification(String body) {\n\n PendingIntent contentIntent = PendingIntent.getActivity(getBaseContext()\n , 0, new Intent(), PendingIntent.FLAG_ONE_SHOT);\n\n NotificationCompat.Builder builder = new NotificationCompat.Builder(getBaseContext());\n\n builder.setAutoCancel(true).setDefaults(android.app.Notification.DEFAULT_LIGHTS| android.app.Notification.DEFAULT_SOUND)\n .setWhen(System.currentTimeMillis()).setSmallIcon(R.mipmap.ic_launcher)\n .setContentTitle(\"Arrival\").setContentText(body)\n .setContentIntent(contentIntent);\n NotificationManager manager = (NotificationManager)getBaseContext().getSystemService(Context.NOTIFICATION_SERVICE);\n manager.notify(1, builder.build());\n }", "public void sendNotification(Bundle bundle) {\n int numberNotifications = AppPrefers.getInstance().getNumberNotifications();\n AppPrefers.getInstance().saveNumberNotifications(numberNotifications + 1);\n sendNotificationNumber();\n }", "public static void sendNotification(Context context, String account, String text) {\n Intent notificationIntent = new Intent(context, HomeMapScreen.class);\n\n // Construct a task stack\n TaskStackBuilder stackBuilder = TaskStackBuilder.create(context);\n\n // Adds the main Activity to the task stack as the parent\n stackBuilder.addParentStack(HomeMapScreen.class);\n\n // Push the content Intent onto the stack\n stackBuilder.addNextIntent(notificationIntent);\n\n // Get a PendingIntent containing the entire back stack\n PendingIntent notificationPendingIntent = stackBuilder.getPendingIntent(0, PendingIntent.FLAG_UPDATE_CURRENT);\n\n // Get a notification builder that's compatible with platform versions >= 4\n NotificationCompat.Builder builder = new NotificationCompat.Builder(context);\n\n // Set the notification contents\n builder.setSmallIcon(R.drawable.ic_stat_on).setContentText(text)\n .setContentIntent(notificationPendingIntent);\n\n // Get an instance of the Notification manager\n NotificationManager mNotificationManager = (NotificationManager) context\n .getSystemService(Context.NOTIFICATION_SERVICE);\n\n // Issue the notification\n mNotificationManager.notify(text.hashCode(), builder.build());\n }", "private void sendNotification(int channelId, String title, String msg, int status) {\n //if (!LawnmowerApp.isVisibile()) return;\n\n NotificationCompat.Builder notficiationBuilder =\n new NotificationCompat.Builder(ctx, String.valueOf(channelId))\n .setSmallIcon(status)\n .setContentTitle(title)\n .setContentText(msg)\n .setPriority(NotificationCompat.PRIORITY_DEFAULT)\n .setAutoCancel(true)\n ;\n NotificationManagerCompat notificationManagerCompat = NotificationManagerCompat.from(ctx);\n notificationManagerCompat.notify(channelId,notficiationBuilder.build());\n }", "public void btnpress(View view) {\n NewMessageNotification newMessageNotification = new NewMessageNotification();\n newMessageNotification.notify(MainActivity.this,\"Danger\",1);\n }" ]
[ "0.75609684", "0.7531252", "0.7082101", "0.70379347", "0.7008891", "0.6988059", "0.6974694", "0.693065", "0.69248766", "0.69235927", "0.6880307", "0.6846301", "0.6833024", "0.68013066", "0.6790052", "0.67844033", "0.67802066", "0.6779987", "0.6772445", "0.6768704", "0.6738765", "0.6708844", "0.67073244", "0.670517", "0.67040855", "0.67015105", "0.66993946", "0.6684028", "0.6682825", "0.6670176", "0.66564125", "0.6645689", "0.6641957", "0.6627158", "0.66216964", "0.66198957", "0.6619742", "0.6613719", "0.66083074", "0.6606207", "0.6590698", "0.6589983", "0.65658975", "0.65636736", "0.6558751", "0.6549038", "0.6537294", "0.6526916", "0.65006137", "0.6461109", "0.6458451", "0.6439261", "0.6436832", "0.64355683", "0.6415751", "0.64074683", "0.64027834", "0.639272", "0.6388224", "0.63872826", "0.6362293", "0.63565445", "0.63463426", "0.6345833", "0.63429457", "0.6337384", "0.63319165", "0.6331557", "0.63311446", "0.6327927", "0.63214856", "0.6315193", "0.63141465", "0.63092715", "0.63065547", "0.6299917", "0.62988937", "0.6298885", "0.6296296", "0.6294452", "0.6293853", "0.6281281", "0.6280277", "0.6275328", "0.62712044", "0.6266271", "0.62650937", "0.6260109", "0.6253734", "0.62368536", "0.623397", "0.6228088", "0.62267536", "0.62225044", "0.62216955", "0.6216774", "0.62123054", "0.6209575", "0.6204171", "0.61999714" ]
0.6328003
69
Gets the value of the iznos property.
public double getIznos() { return iznos; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public int getIzq() {\r\n\t\treturn izq;\r\n\t}", "public int getItens() {\n\t\treturn itens;\n\t}", "public void setIznos(double value) {\n this.iznos = value;\n }", "Integer getIPos();", "public Nodo getNodoIzquierdo(){\n return izq;\n }", "public ArrayList<Integer> getNumeros(){\r\n\t\treturn numeros;\r\n\t}", "public Nodo<T> getIzquierdo() {\n\t\treturn izquierdo;\n\t}", "public String getImsi() {\r\n return imsi;\r\n }", "public int getAoisCount() {\n return aois_.size();\n }", "public Integer[] getExchangeIndicies() {\n return exchangeIndicies;\n }", "public Long getIops() {\n return this.iops;\n }", "public int getIva() {\n\t\treturn producto.getIva();\n\t}", "public int getNiveauIA() {\n\t\treturn niveauIA;\r\n\t}", "public Integer getIops() {\n return this.iops;\n }", "public void setIzq(int izq) {\r\n\t\tthis.izq = izq;\r\n\t}", "public int getIndice() {\n\t\treturn this.indice;\n\t}", "public Integer getIdexpediente() {\r\n return idexpediente;\r\n }", "public Number getFoliosintramo() {\n return (Number) getAttributeInternal(FOLIOSINTRAMO);\n }", "public double Iz() {\r\n\t\tdouble iz = 0;\r\n\t\tfor(int i = 0;i < liczbaPunktow;i++) {\r\n\t\t\tiz = iz + A[i].getMasa() * (Math.pow((XYZC[0] - A[i].getPozX()),2) + Math.pow((XYZC[1] - A[i].getPozY()),2));\r\n\t\t}\r\n\t\treturn iz;\r\n\t}", "public int getInversiones(){\r\n\t\treturn inversiones;\r\n\t}", "public List<ItemProduto> getItens() {\n\t\treturn itens;\n\t}", "@Override\r\n\tpublic String getIzena() {\n\t\treturn super.getIzena();\r\n\t}", "@JsonProperty(\"ipmiNicArray\")\r\n public List<IpmiNicArray> getIpmiNicArray() {\r\n return ipmiNicArray;\r\n }", "@JsonProperty(\"itens\")\n @NotNull\n public List<ItemAgrupamentoLpco> getItens() {\n return itens;\n }", "public Integer getnOrder() {\n return nOrder;\n }", "public Integer getEi() {\n return ei;\n }", "public int getNumber() {\n\t\treturn i;\r\n\t}", "public int numNodi() {\n\t\treturn this.nodi.size();\n\t}", "public double getTipoInteres() {\r\n return tipoInteres;\r\n }", "public int getNmi(){\n return nmi;\n }", "public int getILastIPosX() {\n return iLastIPosX;\n }", "public double Ix() {\r\n\t\tdouble ix = 0;\r\n\t\tfor(int i = 0;i < liczbaPunktow;i++) {\r\n\t\t\tix = ix + A[i].getMasa() * (Math.pow((XYZC[1] - A[i].getPozY()),2) + Math.pow((XYZC[2] - A[i].getPozZ()),2));\r\n\t\t}\r\n\t\treturn ix;\r\n\t}", "public int getQtdInteresses() {\n\t\treturn this.qtdInteresses;\n\t}", "@javax.jdo.annotations.Column(allowsNull = \"false\")\n\t@Title(sequence = \"2\")\n\t@MemberOrder(sequence = \"5\")\n\tpublic PuntoInteres getPuntoInteres() {\n\t\treturn this.puntoInteres;\n\t}", "public int[] getLineNumbers() {\n return lineNos;\n }", "public int getAnnoIscrizione() {\n\t\treturn annoIscrizione;\n\t}", "public int getIntentos() {\r\n return intentos;\r\n }", "public Deixis getDeixis() {\n\t\treturn this.deixis;\n\t}", "public int getNumer()\n\t{\n\t\treturn numer;\n\t}", "@Column(name = \"SCNUMIDENTIFICACION\")\n\tpublic Long getNumeroidentificacion() {\n\t\treturn numeroidentificacion;\n\t}", "@Override\n public int getNInt() {\n return this.values.length;\n }", "public HashMap<Integer, edge_data> getNi() {\n return neighborEdges;\n }", "public int getNickels()\n {\n\treturn nickels;\n }", "public String getImie() {\n return this.imie;\n }", "public int getN() {\n\t\treturn N;\n\t}", "public int getN() {\n\t\treturn n;\n\t}", "public java.lang.String getIpto() {\n return ipto;\n }", "public int getN() {\n return this.n;\n }", "public item getI() {\n return i;\n }", "public int getNOficina ()\r\n {\r\n return this.nOficina;\r\n }", "public int getNumOrdine() {\n\t\t\treturn numOrdine;\n\t\t}", "public int getVonalAzonosito()\r\n\t{\r\n\t\treturn vonalAzonosito;\r\n\t}", "public int getN() {\r\n\t\treturn n;\r\n\t}", "@JsonProperty(PROP_NOT_ECNS)\n public SortedSet<Integer> getNotEcns() {\n return _notEcns;\n }", "public Complejo[][] getNumeros(){\n\t\treturn numeros;\n\t}", "public int getOcena() {\n return ocena;\n }", "public Arbol <T> getHijoIzq(){\n\t\treturn hIzq;\n\t}", "public int getN() {\n return n;\n }", "public int getN() {\n return n_;\n }", "public int getNumFilhos() {\n return this.numFilhos;\n }", "public String getNaziv() {\n\t\treturn naziv;\n\t}", "public Invima getInvima(){\n\t\treturn invima;\n\t}", "public String getNaziv() {\r\n\t\treturn naziv;\r\n\t}", "public String getIdimgZ() {\r\n return idimgZ;\r\n }", "public int getN() {\n return n_;\n }", "public int getNumber() {\n\t\treturn nodeList.size();\n\t}", "@MetadataValueMatcher(metadataValue=20)\n\tpublic List<String> getIsbns() {\n\t\treturn isbns;\n\t}", "public int[] is() {\n int rval[] = new int[size()];\n for (int i = 0; i < rval.length; i++) {\n rval[i] = get(i) == null ? 0 : get(i).intValue();\n }\n return rval;\n }", "public List<Ano> getAno() {\n\t\treturn ano;\n\t}", "public int getUVelosDispos() {\n\t\treturn UVelosDispos;\n\t}", "public int getNunFigli() {\n\t\tint numFigli = 0;\n\t\tfor (Nodo_m_ario figlio : figli) {\n\t\t\tif (figlio != null) {\n\t\t\t\tnumFigli += 1;\n\t\t\t}\n\t\t}\n\t\treturn numFigli;\n\t}", "public int getNum() {\n\treturn this.n;\n }", "public String annaNimi()\n\t{\n\t\treturn this.nimi;\n\t}", "public int getIdenti() {\r\n return identi;\r\n }", "public static int[] getNumeros() {\n\t\treturn numeros;\n\t}", "public long getI() {\n return i;\n }", "ProductoO getIzq();", "public int getNatom() {\n return natom;\n }", "public String getNIF() { return this.NIF; }", "public int getUlIdInvoInvoice()\r\n {\r\n return this._ulIdInvoInvoice;\r\n }", "public int getAnzahl() {\r\n\t\treturn anzahl;\r\n\t}", "public Nodo_m_ario[] getFigli() {\n\t\treturn figli;\n\t}", "public BigDecimal getIstrue() {\n return istrue;\n }", "public float getInteresFijo() {\r\n\t\treturn interesFijo;\r\n\t}", "public int getNr() {\n return nr;\n }", "public int numberOfIcosahedrons() {\n return icosList.size();\n }", "Set getNi()\n {\n return neighbors.keySet();\n }", "public String getIsontv() {\r\n return isontv;\r\n }", "public Integer getQtVoos()\n {\n return this.qtVoos;\n }", "public List<Integer> getListProperty() {\n\t\t\treturn null;\n\t\t}", "public int getItems() {\n return items;\n }", "public String getInumber()\n\t{\n\t\treturn getInumber( getSession().getSessionContext() );\n\t}", "public int getNumero() { return this.numero; }", "public int numeroHojas(){\n\t int N=0, ni=0, nd=0;\n\t Arbol <T> aux=null;\n\t if (!vacio()) {\n\t if ((aux=getHijoIzq())!=null) ni = aux.numeroHojas();\n\t if ((aux=getHijoDer())!=null) nd = aux.numeroHojas();\n\t if ((aux=getHijoDer())==null && (aux=getHijoIzq())==null)N = 1;\n\t else N = ni + nd;\n\t }\n\t\treturn N;\n\t}", "public Float getIhoatts() {\r\n return ihoatts;\r\n }", "public int getAno() {\n\t\t\treturn ano;\n\t\t}", "public int getNumEspacios() {\r\n\t\treturn numEspacios;\r\n\t}", "public int GetNoElises(){\n\t\treturn NoElises;\n\t}", "public int getNumber() {\n return this.numPizzas;\n }", "public byte[] getNr() {\n return nr;\n }" ]
[ "0.6587908", "0.60673475", "0.6063164", "0.6005631", "0.59993386", "0.5976214", "0.59545887", "0.58414125", "0.5828442", "0.5791018", "0.5789253", "0.5757976", "0.57493967", "0.5747832", "0.569675", "0.5641966", "0.564167", "0.5615451", "0.5609077", "0.56009793", "0.5585501", "0.5578575", "0.5574428", "0.5556947", "0.5541526", "0.55399954", "0.5517664", "0.55166364", "0.55094683", "0.5485497", "0.5484351", "0.5431575", "0.542885", "0.5413083", "0.54012364", "0.5392358", "0.5391765", "0.53736526", "0.5357804", "0.53510237", "0.53478134", "0.53475624", "0.5334931", "0.5318435", "0.5309106", "0.5287202", "0.5284587", "0.52835333", "0.5282029", "0.5280275", "0.52794427", "0.5277059", "0.52691185", "0.5265725", "0.52653694", "0.52653635", "0.5263033", "0.52479297", "0.5243956", "0.52432483", "0.52320087", "0.5218797", "0.52113897", "0.5205916", "0.52057904", "0.5200612", "0.5191788", "0.5187407", "0.5182642", "0.5181644", "0.5177229", "0.5171656", "0.51585114", "0.51547366", "0.5154025", "0.51508224", "0.5150817", "0.51473475", "0.51450807", "0.5133224", "0.5123755", "0.51164365", "0.51153105", "0.5113349", "0.5110528", "0.50990766", "0.50988585", "0.5093698", "0.50892645", "0.5085068", "0.5084931", "0.5083286", "0.5081938", "0.50813377", "0.5057921", "0.5056158", "0.50539726", "0.50538313", "0.5051588", "0.5050382" ]
0.79933715
0