blob_id
stringlengths
40
40
directory_id
stringlengths
40
40
path
stringlengths
7
410
content_id
stringlengths
40
40
detected_licenses
listlengths
0
51
license_type
stringclasses
2 values
repo_name
stringlengths
5
132
snapshot_id
stringlengths
40
40
revision_id
stringlengths
40
40
branch_name
stringlengths
4
80
visit_date
timestamp[us]
revision_date
timestamp[us]
committer_date
timestamp[us]
github_id
int64
5.85k
684M
star_events_count
int64
0
209k
fork_events_count
int64
0
110k
gha_license_id
stringclasses
22 values
gha_event_created_at
timestamp[us]
gha_created_at
timestamp[us]
gha_language
stringclasses
132 values
src_encoding
stringclasses
34 values
language
stringclasses
1 value
is_vendor
bool
1 class
is_generated
bool
2 classes
length_bytes
int64
3
9.45M
extension
stringclasses
28 values
content
stringlengths
3
9.45M
authors
listlengths
1
1
author_id
stringlengths
0
352
9c70bf9ae3aa0135b751830ea18b3a8f1a0d7040
26c784066fac305f9e105cd90e9cda8f0d366d40
/boot_15/src/main/java/com/example/boot_15/conditions/JdbcTemplateCondition.java
a145ecdb20792e4c858ac78f068be9532bf86136
[]
no_license
zhayangtao/boot_parent
01b34c41111c124784c61c12dc6dc8b6ec7ace74
d8b60c1687d3eaf70b166d63692464c0c69ae275
refs/heads/master
2022-09-22T08:02:46.589992
2020-12-25T03:19:12
2020-12-25T03:19:12
123,428,327
2
0
null
2022-09-08T00:03:42
2018-03-01T11:51:40
Java
UTF-8
Java
false
false
765
java
package com.example.boot_15.conditions; import org.springframework.context.annotation.Condition; import org.springframework.context.annotation.ConditionContext; import org.springframework.core.type.AnnotatedTypeMetadata; /** * @author zhayangtao * @version 1.0 * @since 2019/01/29 * 条件类:只有在Classpath里存在 JdbcTemplate 时 * 才会生效 */ public class JdbcTemplateCondition implements Condition { @Override public boolean matches(ConditionContext conditionContext, AnnotatedTypeMetadata annotatedTypeMetadata) { try { conditionContext.getClassLoader().loadClass("org.springframework.jdbc.core.JdbcTemplate"); return true; } catch (Exception e) { return false; } } }
[ "1264214725@qq.com" ]
1264214725@qq.com
8d91dae5c8f2c5be471f4db511205e03acb639ad
30057e353957920564ee07722427c3ff434d322f
/ProblemSolving/src/com/basics/backtrack/ConstructWordUsingDice.java
23fc42eb3839f24039c4e9caa15ee18746c52558
[]
no_license
mmanjunath998/Problem-Solving
a7f4e541b150ad3d28e545b7c990d47b020c79a9
32f21921f05ff351a6cdc52fe72e954633d9036a
refs/heads/master
2020-09-09T15:06:46.232130
2019-12-04T08:04:58
2019-12-04T08:04:58
221,479,218
0
0
null
null
null
null
UTF-8
Java
false
false
1,440
java
package com.basics.backtrack; import java.util.ArrayList; import java.util.List; public class ConstructWordUsingDice { public static void main(String[] args){ char[][] arrays = { {'a','l','c','d','e','f'}, {'a','b','c','d','e','f'}, {'a','b','c','h','e','f'}, {'a','b','c','d','o','f'}, {'a','b','c','l','e','f'},}; char[] pat = {'h','e','l','l','o'}; char[][] arr2 = {{'a', 'b', 'c', 'd', 'e', 'f'}, {'a', 'b', 'c', 'd', 'e', 'f'}, {'a', 'b', 'c', 'd', 'e', 'f'}, {'a', 'b', 'c', 'd', 'e', 'f'}, {'a', 'b', 'c', 'd', 'e', 'f'}}; List<Path> results = new ArrayList<Path>(); List<Integer> visited = new ArrayList<>(); System.out.println(find(arrays, pat, results, 0, visited)); } public static boolean find(char[][] arrays, char[] pat, List<Path> result, int seqCount, List<Integer> visited){ if(seqCount == pat.length){ //goal System.out.println(result); return true; } //choices for(int i=0; i<arrays.length; i++){ char[] seq = arrays[i]; for(int j=0; j<seq.length; j++){ if(seq[j] == pat[seqCount] && !visited.contains(i)){ //constraints result.add(new Path(i, j)); visited.add(i); if(find(arrays, pat, result, seqCount+1, visited)){ return true; } //back track result.remove(result.size()-1); visited.remove(visited.size()-1); } } } return false; } }
[ "manjunath@bytemark.co" ]
manjunath@bytemark.co
50f338f96519460aa7bd63e3535c1db8c897d296
4fd736858d11b6c31c4c66e39f1495f6014043e5
/core/src/main/java/net/hasor/core/classcode/asm/MethodVisitor.java
4cb8cae065fb61a59d278cacbdbee6e4c8a37b95
[ "Apache-2.0" ]
permissive
147549561/hasor
0f031ae4d4d7b4551a37abed80a92cf997f22bfb
f446d3995acbb58122926d143d7a23edae357d5f
refs/heads/master
2021-01-25T11:02:39.054793
2017-06-09T12:33:21
2017-06-09T12:33:21
93,906,481
1
0
null
2017-06-10T00:35:22
2017-06-10T00:35:22
null
UTF-8
Java
false
false
36,028
java
/*** * ASM: a very small and fast Java bytecode manipulation framework * Copyright (c) 2000-2011 INRIA, France Telecom * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * 3. Neither the name of the copyright holders nor the names of its * contributors may be used to endorse or promote products derived from * this software without specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF * THE POSSIBILITY OF SUCH DAMAGE. */ package net.hasor.core.classcode.asm; /** * A visitor to visit a Java method. The methods of this class must be called in * the following order: ( <tt>visitParameter</tt> )* [ * <tt>visitAnnotationDefault</tt> ] ( <tt>visitAnnotation</tt> | * <tt>visitParameterAnnotation</tt> <tt>visitTypeAnnotation</tt> | * <tt>visitAttribute</tt> )* [ <tt>visitCode</tt> ( <tt>visitFrame</tt> | * <tt>visit<i>X</i>Insn</tt> | <tt>visitLabel</tt> | * <tt>visitInsnAnnotation</tt> | <tt>visitTryCatchBlock</tt> | * <tt>visitTryCatchAnnotation</tt> | <tt>visitLocalVariable</tt> | * <tt>visitLocalVariableAnnotation</tt> | <tt>visitLineNumber</tt> )* * <tt>visitMaxs</tt> ] <tt>visitEnd</tt>. In addition, the * <tt>visit<i>X</i>Insn</tt> and <tt>visitLabel</tt> methods must be called in * the sequential order of the bytecode instructions of the visited code, * <tt>visitInsnAnnotation</tt> must be called <i>after</i> the annotated * instruction, <tt>visitTryCatchBlock</tt> must be called <i>before</i> the * labels passed as arguments have been visited, * <tt>visitTryCatchBlockAnnotation</tt> must be called <i>after</i> the * corresponding try catch block has been visited, and the * <tt>visitLocalVariable</tt>, <tt>visitLocalVariableAnnotation</tt> and * <tt>visitLineNumber</tt> methods must be called <i>after</i> the labels * passed as arguments have been visited. * * @author Eric Bruneton */ public abstract class MethodVisitor { /** * The ASM API version implemented by this visitor. The value of this field * must be one of {@link Opcodes#ASM4} or {@link Opcodes#ASM5}. */ protected final int api; /** * The method visitor to which this visitor must delegate method calls. May * be null. */ protected MethodVisitor mv; /** * Constructs a new {@link MethodVisitor}. * * @param api * the ASM API version implemented by this visitor. Must be one * of {@link Opcodes#ASM4} or {@link Opcodes#ASM5}. */ public MethodVisitor(final int api) { this(api, null); } /** * Constructs a new {@link MethodVisitor}. * * @param api * the ASM API version implemented by this visitor. Must be one * of {@link Opcodes#ASM4} or {@link Opcodes#ASM5}. * @param mv * the method visitor to which this visitor must delegate method * calls. May be null. */ public MethodVisitor(final int api, final MethodVisitor mv) { if (api != Opcodes.ASM4 && api != Opcodes.ASM5) { throw new IllegalArgumentException(); } this.api = api; this.mv = mv; } // ------------------------------------------------------------------------- // Parameters, annotations and non standard attributes // ------------------------------------------------------------------------- /** * Visits a parameter of this method. * * @param name * parameter name or null if none is provided. * @param access * the parameter's access flags, only <tt>ACC_FINAL</tt>, * <tt>ACC_SYNTHETIC</tt> or/and <tt>ACC_MANDATED</tt> are * allowed (see {@link Opcodes}). */ public void visitParameter(String name, int access) { if (api < Opcodes.ASM5) { throw new RuntimeException(); } if (mv != null) { mv.visitParameter(name, access); } } /** * Visits the default value of this annotation interface method. * * @return a visitor to the visit the actual default value of this * annotation interface method, or <tt>null</tt> if this visitor is * not interested in visiting this default value. The 'name' * parameters passed to the methods of this annotation visitor are * ignored. Moreover, exacly one visit method must be called on this * annotation visitor, followed by visitEnd. */ public AnnotationVisitor visitAnnotationDefault() { if (mv != null) { return mv.visitAnnotationDefault(); } return null; } /** * Visits an annotation of this method. * * @param desc * the class descriptor of the annotation class. * @param visible * <tt>true</tt> if the annotation is visible at runtime. * @return a visitor to visit the annotation values, or <tt>null</tt> if * this visitor is not interested in visiting this annotation. */ public AnnotationVisitor visitAnnotation(String desc, boolean visible) { if (mv != null) { return mv.visitAnnotation(desc, visible); } return null; } /** * Visits an annotation on a type in the method signature. * * @param typeRef * a reference to the annotated type. The sort of this type * reference must be {@link TypeReference#METHOD_TYPE_PARAMETER * METHOD_TYPE_PARAMETER}, * {@link TypeReference#METHOD_TYPE_PARAMETER_BOUND * METHOD_TYPE_PARAMETER_BOUND}, * {@link TypeReference#METHOD_RETURN METHOD_RETURN}, * {@link TypeReference#METHOD_RECEIVER METHOD_RECEIVER}, * {@link TypeReference#METHOD_FORMAL_PARAMETER * METHOD_FORMAL_PARAMETER} or {@link TypeReference#THROWS * THROWS}. See {@link TypeReference}. * @param typePath * the path to the annotated type argument, wildcard bound, array * element type, or static inner type within 'typeRef'. May be * <tt>null</tt> if the annotation targets 'typeRef' as a whole. * @param desc * the class descriptor of the annotation class. * @param visible * <tt>true</tt> if the annotation is visible at runtime. * @return a visitor to visit the annotation values, or <tt>null</tt> if * this visitor is not interested in visiting this annotation. */ public AnnotationVisitor visitTypeAnnotation(int typeRef, TypePath typePath, String desc, boolean visible) { if (api < Opcodes.ASM5) { throw new RuntimeException(); } if (mv != null) { return mv.visitTypeAnnotation(typeRef, typePath, desc, visible); } return null; } /** * Visits an annotation of a parameter this method. * * @param parameter * the parameter index. * @param desc * the class descriptor of the annotation class. * @param visible * <tt>true</tt> if the annotation is visible at runtime. * @return a visitor to visit the annotation values, or <tt>null</tt> if * this visitor is not interested in visiting this annotation. */ public AnnotationVisitor visitParameterAnnotation(int parameter, String desc, boolean visible) { if (mv != null) { return mv.visitParameterAnnotation(parameter, desc, visible); } return null; } /** * Visits a non standard attribute of this method. * * @param attr * an attribute. */ public void visitAttribute(Attribute attr) { if (mv != null) { mv.visitAttribute(attr); } } /** * Starts the visit of the method's code, if any (i.e. non abstract method). */ public void visitCode() { if (mv != null) { mv.visitCode(); } } /** * Visits the current state of the local variables and operand stack * elements. This method must(*) be called <i>just before</i> any * instruction <b>i</b> that follows an unconditional branch instruction * such as GOTO or THROW, that is the target of a jump instruction, or that * starts an exception handler block. The visited types must describe the * values of the local variables and of the operand stack elements <i>just * before</i> <b>i</b> is executed.<br> * <br> * (*) this is mandatory only for classes whose version is greater than or * equal to {@link Opcodes#V1_6 V1_6}. <br> * <br> * The frames of a method must be given either in expanded form, or in * compressed form (all frames must use the same format, i.e. you must not * mix expanded and compressed frames within a single method): * <ul> * <li>In expanded form, all frames must have the F_NEW type.</li> * <li>In compressed form, frames are basically "deltas" from the state of * the previous frame: * <ul> * <li>{@link Opcodes#F_SAME} representing frame with exactly the same * locals as the previous frame and with the empty stack.</li> * <li>{@link Opcodes#F_SAME1} representing frame with exactly the same * locals as the previous frame and with single value on the stack ( * <code>nStack</code> is 1 and <code>stack[0]</code> contains value for the * type of the stack item).</li> * <li>{@link Opcodes#F_APPEND} representing frame with current locals are * the same as the locals in the previous frame, except that additional * locals are defined (<code>nLocal</code> is 1, 2 or 3 and * <code>local</code> elements contains values representing added types).</li> * <li>{@link Opcodes#F_CHOP} representing frame with current locals are the * same as the locals in the previous frame, except that the last 1-3 locals * are absent and with the empty stack (<code>nLocals</code> is 1, 2 or 3).</li> * <li>{@link Opcodes#F_FULL} representing complete frame data.</li> * </ul> * </li> * </ul> * <br> * In both cases the first frame, corresponding to the method's parameters * and access flags, is implicit and must not be visited. Also, it is * illegal to visit two or more frames for the same code location (i.e., at * least one instruction must be visited between two calls to visitFrame). * * @param type * the type of this stack map frame. Must be * {@link Opcodes#F_NEW} for expanded frames, or * {@link Opcodes#F_FULL}, {@link Opcodes#F_APPEND}, * {@link Opcodes#F_CHOP}, {@link Opcodes#F_SAME} or * {@link Opcodes#F_APPEND}, {@link Opcodes#F_SAME1} for * compressed frames. * @param nLocal * the number of local variables in the visited frame. * @param local * the local variable types in this frame. This array must not be * modified. Primitive types are represented by * {@link Opcodes#TOP}, {@link Opcodes#INTEGER}, * {@link Opcodes#FLOAT}, {@link Opcodes#LONG}, * {@link Opcodes#DOUBLE},{@link Opcodes#NULL} or * {@link Opcodes#UNINITIALIZED_THIS} (long and double are * represented by a single element). Reference types are * represented by String objects (representing internal names), * and uninitialized types by Label objects (this label * designates the NEW instruction that created this uninitialized * value). * @param nStack * the number of operand stack elements in the visited frame. * @param stack * the operand stack types in this frame. This array must not be * modified. Its content has the same format as the "local" * array. * @throws IllegalStateException * if a frame is visited just after another one, without any * instruction between the two (unless this frame is a * Opcodes#F_SAME frame, in which case it is silently ignored). */ public void visitFrame(int type, int nLocal, Object[] local, int nStack, Object[] stack) { if (mv != null) { mv.visitFrame(type, nLocal, local, nStack, stack); } } // ------------------------------------------------------------------------- // Normal instructions // ------------------------------------------------------------------------- /** * Visits a zero operand instruction. * * @param opcode * the opcode of the instruction to be visited. This opcode is * either NOP, ACONST_NULL, ICONST_M1, ICONST_0, ICONST_1, * ICONST_2, ICONST_3, ICONST_4, ICONST_5, LCONST_0, LCONST_1, * FCONST_0, FCONST_1, FCONST_2, DCONST_0, DCONST_1, IALOAD, * LALOAD, FALOAD, DALOAD, AALOAD, BALOAD, CALOAD, SALOAD, * IASTORE, LASTORE, FASTORE, DASTORE, AASTORE, BASTORE, CASTORE, * SASTORE, POP, POP2, DUP, DUP_X1, DUP_X2, DUP2, DUP2_X1, * DUP2_X2, SWAP, IADD, LADD, FADD, DADD, ISUB, LSUB, FSUB, DSUB, * IMUL, LMUL, FMUL, DMUL, IDIV, LDIV, FDIV, DDIV, IREM, LREM, * FREM, DREM, INEG, LNEG, FNEG, DNEG, ISHL, LSHL, ISHR, LSHR, * IUSHR, LUSHR, IAND, LAND, IOR, LOR, IXOR, LXOR, I2L, I2F, I2D, * L2I, L2F, L2D, F2I, F2L, F2D, D2I, D2L, D2F, I2B, I2C, I2S, * LCMP, FCMPL, FCMPG, DCMPL, DCMPG, IRETURN, LRETURN, FRETURN, * DRETURN, ARETURN, RETURN, ARRAYLENGTH, ATHROW, MONITORENTER, * or MONITOREXIT. */ public void visitInsn(int opcode) { if (mv != null) { mv.visitInsn(opcode); } } /** * Visits an instruction with a single int operand. * * @param opcode * the opcode of the instruction to be visited. This opcode is * either BIPUSH, SIPUSH or NEWARRAY. * @param operand * the operand of the instruction to be visited.<br> * When opcode is BIPUSH, operand value should be between * Byte.MIN_VALUE and Byte.MAX_VALUE.<br> * When opcode is SIPUSH, operand value should be between * Short.MIN_VALUE and Short.MAX_VALUE.<br> * When opcode is NEWARRAY, operand value should be one of * {@link Opcodes#T_BOOLEAN}, {@link Opcodes#T_CHAR}, * {@link Opcodes#T_FLOAT}, {@link Opcodes#T_DOUBLE}, * {@link Opcodes#T_BYTE}, {@link Opcodes#T_SHORT}, * {@link Opcodes#T_INT} or {@link Opcodes#T_LONG}. */ public void visitIntInsn(int opcode, int operand) { if (mv != null) { mv.visitIntInsn(opcode, operand); } } /** * Visits a local variable instruction. A local variable instruction is an * instruction that loads or stores the value of a local variable. * * @param opcode * the opcode of the local variable instruction to be visited. * This opcode is either ILOAD, LLOAD, FLOAD, DLOAD, ALOAD, * ISTORE, LSTORE, FSTORE, DSTORE, ASTORE or RET. * @param var * the operand of the instruction to be visited. This operand is * the index of a local variable. */ public void visitVarInsn(int opcode, int var) { if (mv != null) { mv.visitVarInsn(opcode, var); } } /** * Visits a type instruction. A type instruction is an instruction that * takes the internal name of a class as parameter. * * @param opcode * the opcode of the type instruction to be visited. This opcode * is either NEW, ANEWARRAY, CHECKCAST or INSTANCEOF. * @param type * the operand of the instruction to be visited. This operand * must be the internal name of an object or array class (see * {@link Type#getInternalName() getInternalName}). */ public void visitTypeInsn(int opcode, String type) { if (mv != null) { mv.visitTypeInsn(opcode, type); } } /** * Visits a field instruction. A field instruction is an instruction that * loads or stores the value of a field of an object. * * @param opcode * the opcode of the type instruction to be visited. This opcode * is either GETSTATIC, PUTSTATIC, GETFIELD or PUTFIELD. * @param owner * the internal name of the field's owner class (see * {@link Type#getInternalName() getInternalName}). * @param name * the field's name. * @param desc * the field's descriptor (see {@link Type Type}). */ public void visitFieldInsn(int opcode, String owner, String name, String desc) { if (mv != null) { mv.visitFieldInsn(opcode, owner, name, desc); } } /** * Visits a method instruction. A method instruction is an instruction that * invokes a method. * * @param opcode * the opcode of the type instruction to be visited. This opcode * is either INVOKEVIRTUAL, INVOKESPECIAL, INVOKESTATIC or * INVOKEINTERFACE. * @param owner * the internal name of the method's owner class (see * {@link Type#getInternalName() getInternalName}). * @param name * the method's name. * @param desc * the method's descriptor (see {@link Type Type}). */ @Deprecated public void visitMethodInsn(int opcode, String owner, String name, String desc) { if (api >= Opcodes.ASM5) { boolean itf = opcode == Opcodes.INVOKEINTERFACE; visitMethodInsn(opcode, owner, name, desc, itf); return; } if (mv != null) { mv.visitMethodInsn(opcode, owner, name, desc); } } /** * Visits a method instruction. A method instruction is an instruction that * invokes a method. * * @param opcode * the opcode of the type instruction to be visited. This opcode * is either INVOKEVIRTUAL, INVOKESPECIAL, INVOKESTATIC or * INVOKEINTERFACE. * @param owner * the internal name of the method's owner class (see * {@link Type#getInternalName() getInternalName}). * @param name * the method's name. * @param desc * the method's descriptor (see {@link Type Type}). * @param itf * if the method's owner class is an interface. */ public void visitMethodInsn(int opcode, String owner, String name, String desc, boolean itf) { if (api < Opcodes.ASM5) { if (itf != (opcode == Opcodes.INVOKEINTERFACE)) { throw new IllegalArgumentException("INVOKESPECIAL/STATIC on interfaces require ASM 5"); } visitMethodInsn(opcode, owner, name, desc); return; } if (mv != null) { mv.visitMethodInsn(opcode, owner, name, desc, itf); } } /** * Visits an invokedynamic instruction. * * @param name * the method's name. * @param desc * the method's descriptor (see {@link Type Type}). * @param bsm * the bootstrap method. * @param bsmArgs * the bootstrap method constant arguments. Each argument must be * an {@link Integer}, {@link Float}, {@link Long}, * {@link Double}, {@link String}, {@link Type} or {@link Handle} * value. This method is allowed to modify the content of the * array so a caller should expect that this array may change. */ public void visitInvokeDynamicInsn(String name, String desc, Handle bsm, Object... bsmArgs) { if (mv != null) { mv.visitInvokeDynamicInsn(name, desc, bsm, bsmArgs); } } /** * Visits a jump instruction. A jump instruction is an instruction that may * jump to another instruction. * * @param opcode * the opcode of the type instruction to be visited. This opcode * is either IFEQ, IFNE, IFLT, IFGE, IFGT, IFLE, IF_ICMPEQ, * IF_ICMPNE, IF_ICMPLT, IF_ICMPGE, IF_ICMPGT, IF_ICMPLE, * IF_ACMPEQ, IF_ACMPNE, GOTO, JSR, IFNULL or IFNONNULL. * @param label * the operand of the instruction to be visited. This operand is * a label that designates the instruction to which the jump * instruction may jump. */ public void visitJumpInsn(int opcode, Label label) { if (mv != null) { mv.visitJumpInsn(opcode, label); } } /** * Visits a label. A label designates the instruction that will be visited * just after it. * * @param label * a {@link Label Label} object. */ public void visitLabel(Label label) { if (mv != null) { mv.visitLabel(label); } } // ------------------------------------------------------------------------- // Special instructions // ------------------------------------------------------------------------- /** * Visits a LDC instruction. Note that new constant types may be added in * future versions of the Java Virtual Machine. To easily detect new * constant types, implementations of this method should check for * unexpected constant types, like this: * * <pre> * if (cst instanceof Integer) { * // ... * } else if (cst instanceof Float) { * // ... * } else if (cst instanceof Long) { * // ... * } else if (cst instanceof Double) { * // ... * } else if (cst instanceof String) { * // ... * } else if (cst instanceof Type) { * int sort = ((Type) cst).getSort(); * if (sort == Type.OBJECT) { * // ... * } else if (sort == Type.ARRAY) { * // ... * } else if (sort == Type.METHOD) { * // ... * } else { * // throw an exception * } * } else if (cst instanceof Handle) { * // ... * } else { * // throw an exception * } * </pre> * * @param cst * the constant to be loaded on the stack. This parameter must be * a non null {@link Integer}, a {@link Float}, a {@link Long}, a * {@link Double}, a {@link String}, a {@link Type} of OBJECT or * ARRAY sort for <tt>.class</tt> constants, for classes whose * version is 49.0, a {@link Type} of METHOD sort or a * {@link Handle} for MethodType and MethodHandle constants, for * classes whose version is 51.0. */ public void visitLdcInsn(Object cst) { if (mv != null) { mv.visitLdcInsn(cst); } } /** * Visits an IINC instruction. * * @param var * index of the local variable to be incremented. * @param increment * amount to increment the local variable by. */ public void visitIincInsn(int var, int increment) { if (mv != null) { mv.visitIincInsn(var, increment); } } /** * Visits a TABLESWITCH instruction. * * @param min * the minimum key value. * @param max * the maximum key value. * @param dflt * beginning of the default handler block. * @param labels * beginnings of the handler blocks. <tt>labels[i]</tt> is the * beginning of the handler block for the <tt>min + i</tt> key. */ public void visitTableSwitchInsn(int min, int max, Label dflt, Label... labels) { if (mv != null) { mv.visitTableSwitchInsn(min, max, dflt, labels); } } /** * Visits a LOOKUPSWITCH instruction. * * @param dflt * beginning of the default handler block. * @param keys * the values of the keys. * @param labels * beginnings of the handler blocks. <tt>labels[i]</tt> is the * beginning of the handler block for the <tt>keys[i]</tt> key. */ public void visitLookupSwitchInsn(Label dflt, int[] keys, Label[] labels) { if (mv != null) { mv.visitLookupSwitchInsn(dflt, keys, labels); } } /** * Visits a MULTIANEWARRAY instruction. * * @param desc * an array type descriptor (see {@link Type Type}). * @param dims * number of dimensions of the array to allocate. */ public void visitMultiANewArrayInsn(String desc, int dims) { if (mv != null) { mv.visitMultiANewArrayInsn(desc, dims); } } /** * Visits an annotation on an instruction. This method must be called just * <i>after</i> the annotated instruction. It can be called several times * for the same instruction. * * @param typeRef * a reference to the annotated type. The sort of this type * reference must be {@link TypeReference#INSTANCEOF INSTANCEOF}, * {@link TypeReference#NEW NEW}, * {@link TypeReference#CONSTRUCTOR_REFERENCE * CONSTRUCTOR_REFERENCE}, {@link TypeReference#METHOD_REFERENCE * METHOD_REFERENCE}, {@link TypeReference#CAST CAST}, * {@link TypeReference#CONSTRUCTOR_INVOCATION_TYPE_ARGUMENT * CONSTRUCTOR_INVOCATION_TYPE_ARGUMENT}, * {@link TypeReference#METHOD_INVOCATION_TYPE_ARGUMENT * METHOD_INVOCATION_TYPE_ARGUMENT}, * {@link TypeReference#CONSTRUCTOR_REFERENCE_TYPE_ARGUMENT * CONSTRUCTOR_REFERENCE_TYPE_ARGUMENT}, or * {@link TypeReference#METHOD_REFERENCE_TYPE_ARGUMENT * METHOD_REFERENCE_TYPE_ARGUMENT}. See {@link TypeReference}. * @param typePath * the path to the annotated type argument, wildcard bound, array * element type, or static inner type within 'typeRef'. May be * <tt>null</tt> if the annotation targets 'typeRef' as a whole. * @param desc * the class descriptor of the annotation class. * @param visible * <tt>true</tt> if the annotation is visible at runtime. * @return a visitor to visit the annotation values, or <tt>null</tt> if * this visitor is not interested in visiting this annotation. */ public AnnotationVisitor visitInsnAnnotation(int typeRef, TypePath typePath, String desc, boolean visible) { if (api < Opcodes.ASM5) { throw new RuntimeException(); } if (mv != null) { return mv.visitInsnAnnotation(typeRef, typePath, desc, visible); } return null; } // ------------------------------------------------------------------------- // Exceptions table entries, debug information, max stack and max locals // ------------------------------------------------------------------------- /** * Visits a try catch block. * * @param start * beginning of the exception handler's scope (inclusive). * @param end * end of the exception handler's scope (exclusive). * @param handler * beginning of the exception handler's code. * @param type * internal name of the type of exceptions handled by the * handler, or <tt>null</tt> to catch any exceptions (for * "finally" blocks). * @throws IllegalArgumentException * if one of the labels has already been visited by this visitor * (by the {@link #visitLabel visitLabel} method). */ public void visitTryCatchBlock(Label start, Label end, Label handler, String type) { if (mv != null) { mv.visitTryCatchBlock(start, end, handler, type); } } /** * Visits an annotation on an exception handler type. This method must be * called <i>after</i> the {@link #visitTryCatchBlock} for the annotated * exception handler. It can be called several times for the same exception * handler. * * @param typeRef * a reference to the annotated type. The sort of this type * reference must be {@link TypeReference#EXCEPTION_PARAMETER * EXCEPTION_PARAMETER}. See {@link TypeReference}. * @param typePath * the path to the annotated type argument, wildcard bound, array * element type, or static inner type within 'typeRef'. May be * <tt>null</tt> if the annotation targets 'typeRef' as a whole. * @param desc * the class descriptor of the annotation class. * @param visible * <tt>true</tt> if the annotation is visible at runtime. * @return a visitor to visit the annotation values, or <tt>null</tt> if * this visitor is not interested in visiting this annotation. */ public AnnotationVisitor visitTryCatchAnnotation(int typeRef, TypePath typePath, String desc, boolean visible) { if (api < Opcodes.ASM5) { throw new RuntimeException(); } if (mv != null) { return mv.visitTryCatchAnnotation(typeRef, typePath, desc, visible); } return null; } /** * Visits a local variable declaration. * * @param name * the name of a local variable. * @param desc * the type descriptor of this local variable. * @param signature * the type signature of this local variable. May be * <tt>null</tt> if the local variable type does not use generic * types. * @param start * the first instruction corresponding to the scope of this local * variable (inclusive). * @param end * the last instruction corresponding to the scope of this local * variable (exclusive). * @param index * the local variable's index. * @throws IllegalArgumentException * if one of the labels has not already been visited by this * visitor (by the {@link #visitLabel visitLabel} method). */ public void visitLocalVariable(String name, String desc, String signature, Label start, Label end, int index) { if (mv != null) { mv.visitLocalVariable(name, desc, signature, start, end, index); } } /** * Visits an annotation on a local variable type. * * @param typeRef * a reference to the annotated type. The sort of this type * reference must be {@link TypeReference#LOCAL_VARIABLE * LOCAL_VARIABLE} or {@link TypeReference#RESOURCE_VARIABLE * RESOURCE_VARIABLE}. See {@link TypeReference}. * @param typePath * the path to the annotated type argument, wildcard bound, array * element type, or static inner type within 'typeRef'. May be * <tt>null</tt> if the annotation targets 'typeRef' as a whole. * @param start * the fist instructions corresponding to the continuous ranges * that make the scope of this local variable (inclusive). * @param end * the last instructions corresponding to the continuous ranges * that make the scope of this local variable (exclusive). This * array must have the same size as the 'start' array. * @param index * the local variable's index in each range. This array must have * the same size as the 'start' array. * @param desc * the class descriptor of the annotation class. * @param visible * <tt>true</tt> if the annotation is visible at runtime. * @return a visitor to visit the annotation values, or <tt>null</tt> if * this visitor is not interested in visiting this annotation. */ public AnnotationVisitor visitLocalVariableAnnotation(int typeRef, TypePath typePath, Label[] start, Label[] end, int[] index, String desc, boolean visible) { if (api < Opcodes.ASM5) { throw new RuntimeException(); } if (mv != null) { return mv.visitLocalVariableAnnotation(typeRef, typePath, start, end, index, desc, visible); } return null; } /** * Visits a line number declaration. * * @param line * a line number. This number refers to the source file from * which the class was compiled. * @param start * the first instruction corresponding to this line number. * @throws IllegalArgumentException * if <tt>start</tt> has not already been visited by this * visitor (by the {@link #visitLabel visitLabel} method). */ public void visitLineNumber(int line, Label start) { if (mv != null) { mv.visitLineNumber(line, start); } } /** * Visits the maximum stack size and the maximum number of local variables * of the method. * * @param maxStack * maximum stack size of the method. * @param maxLocals * maximum number of local variables for the method. */ public void visitMaxs(int maxStack, int maxLocals) { if (mv != null) { mv.visitMaxs(maxStack, maxLocals); } } /** * Visits the end of the method. This method, which is the last one to be * called, is used to inform the visitor that all the annotations and * attributes of the method have been visited. */ public void visitEnd() { if (mv != null) { mv.visitEnd(); } } }
[ "zyc@hasor.net" ]
zyc@hasor.net
5b3995a1c35dc17907ef37a51b5929f6adbf007b
7abe8149560abf2d3daa9e8cb722d7943150e715
/ThirdParty/adobe-ecosign-api/src/main/java/echosign/api/clientv15/dto11/ParticipantRole.java
8ea2b56e709b86b3b71efc0290ee1d1d760d0455
[ "BSD-3-Clause" ]
permissive
tnsgmddb/Consent2Share
6e9c264c9719494b1dee76b612e0a1fd11623529
7010e66f0c098f77d9b15c1bc7496c1fe9b1e408
refs/heads/master
2021-01-18T00:36:16.040783
2016-02-12T21:56:09
2016-02-12T21:56:09
null
0
0
null
null
null
null
UTF-8
Java
false
false
987
java
package echosign.api.clientv15.dto11; import javax.xml.bind.annotation.XmlEnum; import javax.xml.bind.annotation.XmlType; /** * <p>Java class for ParticipantRole. * * <p>The following schema fragment specifies the expected content contained within this class. * <p> * <pre> * &lt;simpleType name="ParticipantRole"> * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}string"> * &lt;enumeration value="SENDER"/> * &lt;enumeration value="SIGNER"/> * &lt;enumeration value="CC"/> * &lt;enumeration value="DELEGATE"/> * &lt;enumeration value="SHARE"/> * &lt;enumeration value="OTHER"/> * &lt;/restriction> * &lt;/simpleType> * </pre> * */ @XmlType(name = "ParticipantRole") @XmlEnum public enum ParticipantRole { SENDER, SIGNER, CC, DELEGATE, SHARE, OTHER; public String value() { return name(); } public static ParticipantRole fromValue(String v) { return valueOf(v); } }
[ "tao.lin@feisystems.com" ]
tao.lin@feisystems.com
05b0611e65832275002d07b61614066f1ec3d9af
02bb01cdb1ef712fd6d7ce16134eeee12793c448
/mumu-system/mumu-system-service/src/main/java/com/lovecws/mumu/system/service/impl/SysRolePermissionServiceImpl.java
674fd6d5f77a38a76baa38f8f419acf054319d97
[ "Apache-2.0" ]
permissive
lnSmallsix/mumu
6eae62b98fb4e3ac85facf57173d9f69421d0674
1c7e609189da04412731c52bfae9788de690ff38
refs/heads/master
2021-01-14T00:09:21.960463
2019-03-09T02:59:38
2019-03-09T02:59:38
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,394
java
package com.lovecws.mumu.system.service.impl; import com.lovecws.mumu.common.core.enums.PublicEnum; import com.lovecws.mumu.system.dao.SysRolePermissionDao; import com.lovecws.mumu.system.entity.SysRolePermission; import com.lovecws.mumu.system.service.SysRolePermissionService; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Isolation; import org.springframework.transaction.annotation.Propagation; import org.springframework.transaction.annotation.Transactional; import java.util.*; @Service @Transactional(isolation = Isolation.DEFAULT, propagation = Propagation.REQUIRED, readOnly = true) public class SysRolePermissionServiceImpl implements SysRolePermissionService { @Autowired private SysRolePermissionDao rolePermissionDao; @Override @Transactional(readOnly = false) public void saveRolePermission(String roleId, String permissionIds, String creator) { // 删除 角色权限 Map<String, Object> paramMap = new HashMap<String, Object>(); paramMap.put("roleId", roleId); rolePermissionDao.delete(paramMap); if (permissionIds != null && !"".equals(permissionIds)) { String[] permissionArray = permissionIds.split(","); List<SysRolePermission> rolePermissions = new ArrayList<SysRolePermission>(); for (String permissionId : permissionArray) { rolePermissions.add(new SysRolePermission(PublicEnum.NORMAL.value(), creator, new Date(), Integer.parseInt(roleId), Integer.parseInt(permissionId))); } // 添加角色权限 rolePermissionDao.insert(rolePermissions); } } @Override @Transactional(readOnly = false) public void deleteRolePermissionByMenuId(String menuId) { Map<String, Object> paramMap = new HashMap<String, Object>(); paramMap.put("menuId", menuId); rolePermissionDao.delete(paramMap); } @Override @Transactional(readOnly = false) public void deleteRolePermissionByPermissionId(String permissionId) { Map<String, Object> paramMap = new HashMap<String, Object>(); paramMap.put("permissionId", permissionId); rolePermissionDao.delete(paramMap); } @Override @Transactional(readOnly = false) public void deleteRolePermissionByRoleId(String roleId) { Map<String, Object> paramMap = new HashMap<String, Object>(); paramMap.put("roleId", roleId); rolePermissionDao.delete(paramMap); } }
[ "lovercws@gmail.com" ]
lovercws@gmail.com
f9b6461291a63a290f856abe7de6856f79a82bc8
10e1b8f41207ab29a0b54481135c9fca07134d9d
/src/main/java/com/jjson/leetcode236/Solution.java
01b7bac1f6c33c8a8a9fc2e3bc8423f161db64df
[]
no_license
Json-Jiang/leetcode
cf626bebfb322d46bf51cc85126656732039bf13
8f4e8b2b036a43f9580f23ed5d5187d9d0b5e310
refs/heads/master
2021-02-27T04:29:17.523260
2020-03-24T15:36:26
2020-03-24T15:36:26
245,578,915
0
0
null
null
null
null
UTF-8
Java
false
false
1,319
java
package com.jjson.leetcode236; /** * 1. 递归搜索 * 2. 如果当前节点等于p或者q,那么计数 * 3. 如果左子树搜到了p或者q,那么计数+1 * 4. 如果右子树搜到了p或者q,那么计数+1 * 5. 如果当前计数大于等于2,直接返回当前节点 * 6. 如果当前节点搜到了p或者q,返回1,否则返回0 * * @author jiangjunshen * @date 8:54 下午 2020/3/12 */ public class Solution { TreeNode node; public TreeNode lowestCommonAncestor(TreeNode root, TreeNode p, TreeNode q) { search(root, p, q); return node; } private int search(TreeNode cur, TreeNode p, TreeNode q) { if (null != node) { return 0; } if (null != cur) { int count = 0; if (p == cur || q == cur) { count++; } count += search(cur.left, p, q); count += search(cur.right, p, q); if (count >= 2) { node = cur; // 防止多余错误判断 return 0; } return count; } return 0; } class TreeNode { int val; TreeNode left; TreeNode right; TreeNode(int x) { val = x; } } }
[ "jiangjunshen@cai-inc.com" ]
jiangjunshen@cai-inc.com
2532bd841aabbb2764d99e82625f8b1b21cb5ec9
f65059dbda96f025e242b340c5b5e58dfe3deb11
/src/main/java/com/expenses/app/AppApplication.java
d01d8e0a0fa4daee40687d65fa36038ae23699df
[]
no_license
leandrotula/expenses-app
65e34b508c23ca4f6689a0ba16b3de58da8b23b3
ef9a1289b00982c94a8dba7b6375b8c5ccc33bd6
refs/heads/master
2023-01-20T14:05:16.119803
2020-11-29T23:50:22
2020-11-29T23:50:22
301,245,927
0
0
null
2020-11-23T15:22:16
2020-10-04T23:13:02
Java
UTF-8
Java
false
false
545
java
package com.expenses.app; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; import org.springframework.boot.autoconfigure.data.mongo.MongoDataAutoConfiguration; import org.springframework.boot.autoconfigure.mongo.MongoAutoConfiguration; @SpringBootApplication(exclude = { MongoAutoConfiguration.class, MongoDataAutoConfiguration.class }) public class AppApplication { public static void main(String[] args) { SpringApplication.run(AppApplication.class, args); } }
[ "leandrotula@gmail.com" ]
leandrotula@gmail.com
0f71b80fcbc165a80c7b0ec3bcea38855fae4de9
fa91450deb625cda070e82d5c31770be5ca1dec6
/Diff-Raw-Data/32/32_cbad0e400ec5d79b954b62f7f2c31e7e036121ea/AnnotationModelVisitor/32_cbad0e400ec5d79b954b62f7f2c31e7e036121ea_AnnotationModelVisitor_t.java
10b54a6060df50e53e95fcccccb71a5871463fcd
[]
no_license
zhongxingyu/Seer
48e7e5197624d7afa94d23f849f8ea2075bcaec0
c11a3109fdfca9be337e509ecb2c085b60076213
refs/heads/master
2023-07-06T12:48:55.516692
2023-06-22T07:55:56
2023-06-22T07:55:56
259,613,157
6
2
null
2023-06-22T07:55:57
2020-04-28T11:07:49
null
UTF-8
Java
false
false
24,142
java
package com.redhat.ceylon.compiler.java.codegen; import static com.redhat.ceylon.compiler.typechecker.analyzer.Util.isBooleanFalse; import static com.redhat.ceylon.compiler.typechecker.analyzer.Util.isBooleanTrue; import java.util.ArrayList; import java.util.List; import com.redhat.ceylon.compiler.typechecker.model.Class; import com.redhat.ceylon.compiler.typechecker.model.Declaration; import com.redhat.ceylon.compiler.typechecker.model.Method; import com.redhat.ceylon.compiler.typechecker.model.Parameter; import com.redhat.ceylon.compiler.typechecker.model.ProducedType; import com.redhat.ceylon.compiler.typechecker.model.TypeDeclaration; import com.redhat.ceylon.compiler.typechecker.model.Unit; import com.redhat.ceylon.compiler.typechecker.model.Value; import com.redhat.ceylon.compiler.typechecker.tree.NaturalVisitor; import com.redhat.ceylon.compiler.typechecker.tree.Node; import com.redhat.ceylon.compiler.typechecker.tree.Tree; import com.redhat.ceylon.compiler.typechecker.tree.Tree.AnyMethod; import com.redhat.ceylon.compiler.typechecker.tree.Tree.Term; import com.redhat.ceylon.compiler.typechecker.tree.Visitor; /** * Visitor which inspects annotation constructors. * * @author tom */ public class AnnotationModelVisitor extends Visitor implements NaturalVisitor { private java.util.List<AnnotationFieldName> fieldNames = new ArrayList<AnnotationFieldName>(); /** The annotation constructor we are currently visiting */ private AnyMethod annotationConstructor; /** The instantiation in the body of the constructor, or in its default parameters */ private AnnotationInvocation instantiation; private List<AnnotationInvocation> nestedInvocations; private boolean spread; private boolean checkingArguments; private boolean checkingDefaults; private AnnotationTerm term; private boolean checkingInvocationPrimary; private CollectionLiteralAnnotationTerm elements; public AnnotationModelVisitor() { } private void push(AnnotationFieldName parameter) { fieldNames.add(parameter); } private AnnotationFieldName pop() { return fieldNames.remove(fieldNames.size()-1); } public Parameter parameter() { return fieldNames.get(fieldNames.size()-1).getAnnotationField(); } @Override public void handleException(Exception e, Node node) { if (e instanceof RuntimeException) { throw (RuntimeException)e; } else { throw new RuntimeException(e); } } public static boolean isAnnotationConstructor(AnyMethod def) { return isAnnotationConstructor(def.getDeclarationModel()); } public static boolean isAnnotationConstructor(Declaration def) { return def.isToplevel() && def instanceof Method && def.isAnnotation(); } public static boolean isAnnotationClass(Tree.ClassOrInterface def) { return isAnnotationClass(def.getDeclarationModel()); } public static boolean isAnnotationClass(Declaration declarationModel) { return (declarationModel instanceof Class) && declarationModel.isAnnotation(); } @Override public void visit(Tree.MethodDefinition d) { if (isAnnotationConstructor(d)) { annotationConstructor = d; instantiation = new AnnotationInvocation(); instantiation.setConstructorDeclaration(d.getDeclarationModel()); d.getDeclarationModel().setAnnotationConstructor(instantiation); } super.visit(d); if (isAnnotationConstructor(d)) { instantiation = null; annotationConstructor = null; } } @Override public void visit(Tree.MethodDeclaration d) { if (isAnnotationConstructor(d) && d.getSpecifierExpression() != null) { annotationConstructor = d; instantiation = new AnnotationInvocation(); instantiation.setConstructorDeclaration(d.getDeclarationModel()); d.getDeclarationModel().setAnnotationConstructor(instantiation); } super.visit(d); if (isAnnotationConstructor(d) && d.getSpecifierExpression() != null) { instantiation = null; annotationConstructor = null; } } @Override public void visit(Tree.Statement d) { if (annotationConstructor != null) { if (!(annotationConstructor instanceof Tree.MethodDefinition && d instanceof Tree.Return) && d != annotationConstructor) { d.addError("Annotation constructors may only contain a return statement"); } } super.visit(d); } @Override public void visit(Tree.AnnotationList al) { // Ignore statements in annotation lists } @Override public void visit(Tree.Parameter p) { if (annotationConstructor != null) { AnnotationConstructorParameter acp = new AnnotationConstructorParameter(); acp.setParameter(p.getParameterModel()); instantiation.getConstructorParameters().add(acp); push(acp); //super.visit(p); Tree.SpecifierOrInitializerExpression defaultArgument = Decl.getDefaultArgument(p); if (defaultArgument != null) { defaultedParameter(defaultArgument); } pop(); Tree.ValueParameterDeclaration vp; } // Ignore statements in parameters } public void defaultedParameter(Tree.SpecifierOrInitializerExpression d) { if (annotationConstructor != null) { AnnotationConstructorParameter annotationConstructorParameter = instantiation.getConstructorParameters().get( instantiation.getConstructorParameters().size()-1); Declaration t = d.getUnit().getTrueValueDeclaration(); Declaration f = d.getUnit().getFalseValueDeclaration(); Term term = d.getExpression().getTerm(); if (term instanceof Tree.InvocationExpression) { Tree.Primary primary = ((Tree.InvocationExpression)term).getPrimary(); if (primary instanceof Tree.BaseMemberOrTypeExpression && (isAnnotationConstructor( ((Tree.BaseMemberOrTypeExpression)primary).getDeclaration()) || isAnnotationClass( ((Tree.BaseMemberOrTypeExpression)primary).getDeclaration()))) { final AnnotationInvocation prevInstantiation = this.instantiation; this.instantiation = new AnnotationInvocation(); if (isAnnotationConstructor( ((Tree.BaseMemberOrTypeExpression)primary).getDeclaration())) { Method constructor = (Method)((Tree.BaseMemberOrTypeExpression)primary).getDeclaration(); instantiation.setConstructorDeclaration(constructor); instantiation.getConstructorParameters().addAll(((AnnotationInvocation)constructor.getAnnotationConstructor()).getConstructorParameters()); } checkingDefaults = true; super.visit(d); annotationConstructorParameter.setDefaultArgument(this.term); this.term = null; checkingDefaults = false; this.instantiation = prevInstantiation; } else { errorDefaultedParameter(d); } } else if (term instanceof Tree.Literal || (term instanceof Tree.BaseMemberExpression && (((Tree.BaseMemberExpression)term).getDeclaration().equals(t) || ((Tree.BaseMemberExpression)term).getDeclaration().equals(f) || ((Tree.BaseMemberExpression)term).getDeclaration().isParameter() || Decl.isAnonCaseOfEnumeratedType((Tree.BaseMemberExpression)term)))) { checkingDefaults = true; super.visit(d); annotationConstructorParameter.setDefaultArgument(this.term); this.term = null; checkingDefaults = false; } else if (term instanceof Tree.Tuple || term instanceof Tree.SequenceEnumeration) { // TODO Tuples and SequenceEnumerations of the above cases should also be allowed checkingDefaults = true; super.visit(d); annotationConstructorParameter.setDefaultArgument(this.term); this.term = null; checkingDefaults = false; } else { errorDefaultedParameter(d); } } } private void errorDefaultedParameter(Node d) { d.addError("Only literals, true, false, and annotation class instantiations are permitted as annotation parameter defaults"); } @Override public void visit(Tree.InvocationExpression invocation) { if (annotationConstructor != null) { final AnnotationInvocation prevInstantiation = this.instantiation; if (this.checkingArguments) { this.instantiation = new AnnotationInvocation(); } this.checkingInvocationPrimary = true; invocation.getPrimary().visit(this); this.checkingInvocationPrimary = false; if (invocation.getPositionalArgumentList() != null) { invocation.getPositionalArgumentList().visit(this); } if (invocation.getNamedArgumentList() != null) { invocation.getNamedArgumentList().visit(this); } InvocationAnnotationTerm invocationTerm = new InvocationAnnotationTerm(); invocationTerm.setInstantiation(instantiation); if (this.checkingArguments) { if (this.nestedInvocations == null) { this.nestedInvocations = new ArrayList<AnnotationInvocation>(); } this.nestedInvocations.add(this.instantiation); this.instantiation = prevInstantiation; } this.term = invocationTerm; } else { super.visit(invocation); } } @Override public void visit(Tree.NamedArgumentList argumentList) { final boolean prevCheckingArguments = this.checkingArguments; this.checkingArguments = true; super.visit(argumentList); this.checkingArguments = prevCheckingArguments; } @Override public void visit(Tree.PositionalArgumentList argumentList) { final boolean prevCheckingArguments = this.checkingArguments; this.checkingArguments = true; super.visit(argumentList); this.checkingArguments = prevCheckingArguments; } public void visit(Tree.StringLiteral literal) { if (annotationConstructor != null) { if (checkingArguments || checkingDefaults){ LiteralAnnotationTerm argument = new StringLiteralAnnotationTerm(ExpressionTransformer.literalValue(literal)); argument.setTerm(literal); appendLiteralArgument(literal, argument); } } } public void visit(Tree.CharLiteral literal) { if (annotationConstructor != null) { if (checkingArguments || checkingDefaults){ LiteralAnnotationTerm argument = new CharacterLiteralAnnotationTerm(ExpressionTransformer.literalValue(literal)); argument.setTerm(literal); appendLiteralArgument(literal, argument); } } } public void visit(Tree.FloatLiteral literal) { if (annotationConstructor != null) { if (checkingArguments || checkingDefaults){ try { LiteralAnnotationTerm argument = new FloatLiteralAnnotationTerm(ExpressionTransformer.literalValue(literal)); argument.setTerm(literal); appendLiteralArgument(literal, argument); } catch (ErroneousException e) { // Ignore it: The ExpressionTransformer will produce an error later in codegen } } } } public void visit(Tree.NaturalLiteral literal) { if (annotationConstructor != null) { if (checkingArguments || checkingDefaults){ try { LiteralAnnotationTerm argument = new IntegerLiteralAnnotationTerm(ExpressionTransformer.literalValue(literal), parameter().getModel().getType()); argument.setTerm(literal); appendLiteralArgument(literal, argument); } catch (ErroneousException e) { // Ignore it: The ExpressionTransformer will produce an error later in codegen } } } } public void visit(Tree.NegativeOp op) { if (annotationConstructor != null) { if (checkingArguments || checkingDefaults){ try { if (op.getTerm() instanceof Tree.NaturalLiteral) { LiteralAnnotationTerm argument = new IntegerLiteralAnnotationTerm(ExpressionTransformer.literalValue(op), parameter().getModel().getType()); argument.setTerm(op); appendLiteralArgument(op, argument); } else if (op.getTerm() instanceof Tree.FloatLiteral) { LiteralAnnotationTerm argument = new FloatLiteralAnnotationTerm(-ExpressionTransformer.literalValue((Tree.FloatLiteral)op.getTerm())); argument.setTerm(op); appendLiteralArgument(op, argument); } } catch (ErroneousException e) { // Ignore it: The ExpressionTransformer will produce an error later in codegen } } } } public void visit(Tree.MetaLiteral literal) { if (annotationConstructor != null) { if (checkingArguments || checkingDefaults){ LiteralAnnotationTerm argument = new DeclarationLiteralAnnotationTerm(ExpressionTransformer.getSerializedMetaLiteral(literal)); argument.setTerm(literal); appendLiteralArgument(literal, argument); } } } public void visit(Tree.Tuple literal) { if (annotationConstructor != null) { if (checkingArguments || checkingDefaults){ // Continue the visit to collect the elements this.elements = new CollectionLiteralAnnotationTerm(null); literal.visitChildren(this); this.term = this.elements; this.elements = null; ((CollectionLiteralAnnotationTerm)this.term).setTerm(literal); appendLiteralArgument(literal, (CollectionLiteralAnnotationTerm)term); } } } public void visit(Tree.SequenceEnumeration literal) { if (annotationConstructor != null) { if (checkingArguments || checkingDefaults){ // Continue the visit to collect the elements Unit unit = literal.getUnit(); ProducedType iteratedType = unit.getIteratedType(literal.getTypeModel()); TypeDeclaration declaration = iteratedType.getDeclaration(); LiteralAnnotationTerm factory; if (unit.getStringDeclaration().equals(declaration)) { factory = new StringLiteralAnnotationTerm(null); } else if (unit.getIntegerDeclaration().equals(declaration)) { factory = new IntegerLiteralAnnotationTerm(0, null); } else if (unit.getCharacterDeclaration().equals(declaration)) { factory = new CharacterLiteralAnnotationTerm(0); } else if (unit.getBooleanDeclaration().equals(declaration)) { factory = new BooleanLiteralAnnotationTerm(false); } else if (unit.getFloatDeclaration().equals(declaration)) { factory = new FloatLiteralAnnotationTerm(0.0); } else if (Decl.isEnumeratedTypeWithAnonCases(iteratedType)) { factory = new ObjectLiteralAnnotationTerm(null); } else {//if (iteratedType.isExactly(unit.getMetamodelDeclarationDeclaration().getType())) { factory = new DeclarationLiteralAnnotationTerm(null); } /*else { throw new RuntimeException(); }*/ this.elements = new CollectionLiteralAnnotationTerm(factory); literal.visitChildren(this); this.term = this.elements; this.elements = null; ((CollectionLiteralAnnotationTerm)this.term).setTerm(literal); appendLiteralArgument(literal, (CollectionLiteralAnnotationTerm)term); } } } @Override public void visit(Tree.Expression term) { if (annotationConstructor != null) { term.visitChildren(this); } } @Override public void visit(Tree.Term term) { if (annotationConstructor != null && !checkingDefaults) { term.addError("Unsupported term " + term.getClass().getSimpleName()); } } @Override public void visit(Tree.BaseMemberExpression bme) { if (annotationConstructor != null) { Declaration declaration = bme.getDeclaration(); if (checkingInvocationPrimary && isAnnotationConstructor(bme.getDeclaration())) { Method ctor = (Method)bme.getDeclaration(); instantiation.setPrimary(ctor); if (ctor.getAnnotationConstructor() != null) { instantiation.getConstructorParameters().addAll(((AnnotationInvocation)ctor.getAnnotationConstructor()).getConstructorParameters()); } } else if (checkingArguments || checkingDefaults) { if (declaration instanceof Value && ((Value)declaration).isParameter()) { Value constructorParameter = (Value)declaration; ParameterAnnotationTerm a = new ParameterAnnotationTerm(); a.setSpread(spread); // XXX Is this right? a.setSourceParameter(constructorParameter.getInitializerParameter()); this.term = a; } else if (isBooleanTrue(declaration)) { LiteralAnnotationTerm argument = new BooleanLiteralAnnotationTerm(true); argument.setTerm(bme); appendLiteralArgument(bme, argument); } else if (isBooleanFalse(declaration)) { LiteralAnnotationTerm argument = new BooleanLiteralAnnotationTerm(false); argument.setTerm(bme); appendLiteralArgument(bme, argument); } else if (Decl.isAnonCaseOfEnumeratedType(bme)) { LiteralAnnotationTerm argument = new ObjectLiteralAnnotationTerm(bme.getTypeModel()); argument.setTerm(bme); appendLiteralArgument(bme, argument); } else { bme.addError("Unsupported base member expression in annotation constructor"); } } else { bme.addError("Unsupported base member expression in annotation constructor"); } } } /** * Records <strong>either</strong> * a literal argument to the annotation class instantiation: * <pre> * ... => AnnotationClass("", 1, true, 1.0, 'x') * </pre> * <strong>Or</strong> a literal default argument in an annotation constructor: * <pre> * AnnotationClass ctor(String s="", Integer i=1, * Boolean b=true, Float f=1.0, * Character c='x') => ... * </pre> * Literal is in the Javac sense. */ private LiteralAnnotationTerm appendLiteralArgument(Node bme, LiteralAnnotationTerm argument) { if (spread) { bme.addError("Spread static arguments not supported"); } if (this.elements != null) { this.elements.addElement(argument); } else { this.term = argument; } return argument; } @Override public void visit(Tree.BaseTypeExpression bte) { if (annotationConstructor != null) { if (isAnnotationClass(bte.getDeclaration())) { instantiation.setPrimary((Class)bte.getDeclaration()); } else { bte.addError("Not an annotation class"); } } } @Override public void visit(Tree.PositionalArgument argument) { if (annotationConstructor != null && this.elements == null) { argument.addError("Unsupported positional argument"); } super.visit(argument); } @Override public void visit(Tree.SpreadArgument argument) { if (annotationConstructor != null && this.elements == null) { spread = true; argument.getExpression().visit(this); AnnotationArgument aa = new AnnotationArgument(); aa.setParameter(argument.getParameter()); aa.setTerm(this.term); instantiation.getAnnotationArguments().add(aa); this.term = null; spread = false; } else { super.visit(argument); } } @Override public void visit(Tree.ListedArgument argument) { if (annotationConstructor != null && this.elements == null) { AnnotationArgument aa = new AnnotationArgument(); aa.setParameter(argument.getParameter()); push(aa); argument.getExpression().visit(this); aa.setTerm(this.term); instantiation.getAnnotationArguments().add(aa); this.term = null; pop(); } else { super.visit(argument); } } @Override public void visit(Tree.NamedArgument argument) { if (annotationConstructor != null && this.elements == null) { argument.addError("Unsupported named argument"); } super.visit(argument); } @Override public void visit(Tree.SpecifiedArgument argument) { if (annotationConstructor != null && this.elements == null) { AnnotationArgument aa = new AnnotationArgument(); aa.setParameter(argument.getParameter()); push(aa); argument.getSpecifierExpression().visit(this); aa.setTerm(this.term); instantiation.getAnnotationArguments().add(aa); this.term = null; pop(); } else { super.visit(argument); } } }
[ "yuzhongxing88@gmail.com" ]
yuzhongxing88@gmail.com
8018c66d153e652f982257567cc025cb4d0d53ef
4e8113da5ae1f4a63f0cc611dc5f43537e6d1777
/src/test/java/com/rest/integration/LibraryCucumberTest.java
a6d3da8843da1cef34b38866f72d12f3614bb9cb
[]
no_license
prakashbalaji/table-affermare-sample
4fc44d28b0b2fef205d97ff64b285bdfc236a5d7
fdd61884cf1aaaffedb563320063d724a554ec3e
refs/heads/master
2021-01-23T20:49:39.714399
2015-01-04T09:25:52
2015-01-04T09:25:52
24,181,132
0
0
null
null
null
null
UTF-8
Java
false
false
756
java
package com.rest.integration; import com.rest.application.LibraryApplication; import com.rest.configuration.LibraryConfiguration; import cucumber.api.junit.Cucumber; import io.dropwizard.testing.junit.DropwizardAppRule; import org.junit.ClassRule; import org.junit.runner.RunWith; @RunWith(Cucumber.class) @Cucumber.Options(format = {"html:target/cucumber-html-report", "json:target/cucumber-json-report.json"}, glue = {"com.rest.steps", "com.rest.request", "com.rest.verification", "com.table.verification" }) public class LibraryCucumberTest { @ClassRule public static final DropwizardAppRule<LibraryConfiguration> RULE = new DropwizardAppRule<LibraryConfiguration>(LibraryApplication.class, "configuration.yml"); }
[ "prakashk@thoughtworks.com" ]
prakashk@thoughtworks.com
dbe1d5ce74af759c1dbda56ce9cc943f62483839
ae71dbe7bcf9affdaca69546081eef44989ca8f7
/week2_POC_SpringBoot/src/main/java/org/infogain/boot/controller/MainApp.java
90f115c92a4d66d9b7cec99866126e808243ccec
[]
no_license
khushboojain1993/POC
a2e27638c8aadbab6f00c777efb3df74293e7517
fa99dd389082c7dad9c827de5fe5635502f049c7
refs/heads/master
2020-03-25T10:09:38.359690
2018-08-06T06:25:32
2018-08-06T06:25:32
143,685,180
0
0
null
null
null
null
UTF-8
Java
false
false
3,512
java
package org.infogain.boot.controller; import java.util.Collections; import java.util.List; import org.infogain.boot.comparator.NameComparator; import org.infogain.boot.comparator.SalaryComparator; import org.infogain.boot.dao.IEmployeeDao; import org.infogain.boot.model.Employee; import org.infogain.boot.services.IEmployeeService; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.http.HttpStatus; import org.springframework.http.ResponseEntity; import org.springframework.web.bind.annotation.DeleteMapping; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.PutMapping; import org.springframework.web.bind.annotation.RequestBody; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; @RestController @RequestMapping(value = "/employee") public class MainApp { @Autowired IEmployeeDao employeeDAO; @GetMapping("/{id}") public ResponseEntity<?> getEmployeeById(@PathVariable("id") String id) { Employee emp = employeeDAO.getEmployeeById(id); if(emp==null) { return new ResponseEntity<String>("Employee with given id doesn't exist", HttpStatus.NOT_FOUND); } return new ResponseEntity<Employee>(emp, HttpStatus.OK); } @GetMapping("/all") public ResponseEntity<?> getAllEmployees() { List<Employee> list = employeeDAO.getAllEmployees(); if(list.isEmpty() || list.size() == 0) { return new ResponseEntity<String>("No employee exists in the record",HttpStatus.NOT_FOUND); } return new ResponseEntity<List<Employee>>(list, HttpStatus.OK); } @GetMapping("/name") public ResponseEntity<?> getEmployeesNameSorted() { List<Employee> list = employeeDAO.getAllEmployees(); Collections.sort(list, new NameComparator()); return new ResponseEntity<List<Employee>>(list, HttpStatus.OK); } @GetMapping("/salary") public ResponseEntity<?> getEmployeesSalarySorted() { List<Employee> list = employeeDAO.getAllEmployees(); Collections.sort(list, new SalaryComparator()); return new ResponseEntity<List<Employee>>(list, HttpStatus.OK); } @PostMapping() public ResponseEntity<?> addEmployee(@RequestBody Employee employee) { boolean flag = employeeDAO.EmployeeExists(employee.getEmpId()); if (flag) { return new ResponseEntity<String>("Employee Already exist!", HttpStatus.CONFLICT); } employeeDAO.addEmployee(employee); return new ResponseEntity<String>("Employee created successfully!", HttpStatus.CREATED); } @PutMapping() public ResponseEntity<?> updateEmployee(@RequestBody Employee employee) { boolean flag = employeeDAO.EmployeeExists(employee.getEmpId()); if (!flag) { employeeDAO.addEmployee(employee); return new ResponseEntity<String>("New Employee created successfully!", HttpStatus.CREATED); } employeeDAO.updateEmployee(employee); return new ResponseEntity<Employee>(employee, HttpStatus.CREATED); } @DeleteMapping("/{id}") public ResponseEntity<?> deleteEmployee(@PathVariable("id") String id) { Employee employee = employeeDAO.getEmployeeById(id); if (employee != null) { employeeDAO.deleteEmployee(employee); return new ResponseEntity<String>("Employee " + id + " deleted successfully!", HttpStatus.GONE); } return new ResponseEntity<String>("Employee " + id + " does not exist!", HttpStatus.NOT_FOUND); } }
[ "Khushboo.Jain@igglobal.com" ]
Khushboo.Jain@igglobal.com
707dc6fab62f7f867a8c5d01e29ca0018abfd511
546042c42f27a449e2dc2ef0fb54f0bf063d921f
/Java/Java_8/Kishori_Sharan/src/book1/ch06/classes_objects/MultipleMainMethods.java
99ae021b26f05a5e81be0c57e0b42fbeec5637f7
[]
no_license
Anubhawn/practice
9d49d966da8331a813fdfe98a0b7ec93067fb75e
df44d3e33b502d2902d0b61b66b6a65f6b13e960
refs/heads/master
2023-07-15T11:46:11.965899
2021-08-18T14:37:59
2021-08-18T14:37:59
null
0
0
null
null
null
null
UTF-8
Java
false
false
564
java
package book1.ch06.classes_objects; import java.util.Arrays; public class MultipleMainMethods { public static void main(String[] args) { System.out.println("The main main()"); String[] arr ={"1","2","abc"}; MultipleMainMethods.main(arr, "Christy"); MultipleMainMethods mmm = new MultipleMainMethods(); mmm.main(); } public static void main(String[] args, String a) { System.out.println("main(String[] args, String a ->" + Arrays.toString(args) + ", " + a); } public int main() { System.out.println("main()"); return 0; } }
[ "christyjohn.crz@gmail.com" ]
christyjohn.crz@gmail.com
5fc6bdd1fccb86a03a819c5f560c97fe0739cae5
3ef55ae7e258b2816f6530b5c65d912aef1e33cb
/fut-bid-service/src/main/java/br/com/futbid/service/listener/AutoBuyerListener.java
2c3744bc95f0678d83f8f8cee35c0530c37b6eef
[]
no_license
brunocconrado/fut-bid
6836997a3920365968264a682226cef99098173f
fe4a938b40b0c9fcd738778b6e8768a0a0ae58aa
HEAD
2016-09-05T18:00:01.491710
2014-05-25T15:02:03
2014-05-25T15:02:03
null
0
0
null
null
null
null
UTF-8
Java
false
false
81
java
package br.com.futbid.service.listener; public interface AutoBuyerListener { }
[ "brunoc.conrado@gmail.com" ]
brunoc.conrado@gmail.com
1e11529e013ea797d31afe82b6bb701c02379a7a
69a93ebc8e75663c52887f6e98e2928b80624acb
/lhx.dao/src/main/java/com/lhx/model/BetOp.java
fdb2ec6b67397461a8a828fb0f092766a0627d1c
[]
no_license
888xin/multiMavenWeb
2ac9dda5ad91211650b6c08a740c0b6f1a15dcea
4909e80978eb2ab146adb615c66d121aecd719e7
refs/heads/master
2022-12-20T13:54:45.445452
2019-10-29T08:20:03
2019-10-29T08:20:03
29,122,133
0
0
null
2022-12-16T02:16:10
2015-01-12T06:34:06
Java
UTF-8
Java
false
false
937
java
package com.lhx.model; public class BetOp extends Bet { private static final long serialVersionUID = -6880809221612162119L; /** * 主胜赔率 */ private Double homeRoi; /** * 平赔率 */ private Double drawRoi; /** * 客胜赔率 */ private Double awayRoi; /** * 龙筹券 */ private Integer coupon; public Double getHomeRoi() { return homeRoi; } public void setHomeRoi(Double homeRoi) { this.homeRoi = homeRoi; } public Double getDrawRoi() { return drawRoi; } public void setDrawRoi(Double drawRoi) { this.drawRoi = drawRoi; } public Double getAwayRoi() { return awayRoi; } public Integer getCoupon() { return coupon; } public void setCoupon(Integer coupon) { this.coupon = coupon; } public void setAwayRoi(Double awayRoi) { this.awayRoi = awayRoi; } }
[ "hengxinl@l99.com" ]
hengxinl@l99.com
ae891548beac4d073482bff27096b3c5f688fdf0
d7acb1004ef0f770016bc1f5e94754d523a717e2
/app/src/main/java/com/example/atmconsultoria2/ui/principal/PrincipalFragment.java
06fb40cddca9a22e03e51db0a0bb794f856ffba7
[]
no_license
soapmactavish23/ATMConsultoria2
9776bbaf9ac45021426152d1140cfc9844d5c525
d9adc2b4f9681b622bd656cd85b718cefdad8ce5
refs/heads/master
2023-08-29T05:25:16.117491
2021-10-10T13:59:06
2021-10-10T13:59:06
257,148,713
0
0
null
null
null
null
UTF-8
Java
false
false
2,122
java
package com.example.atmconsultoria2.ui.principal; import android.os.Bundle; import androidx.fragment.app.Fragment; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import com.example.atmconsultoria2.R; /** * A simple {@link Fragment} subclass. * Use the {@link PrincipalFragment#newInstance} factory method to * create an instance of this fragment. */ public class PrincipalFragment extends Fragment { // TODO: Rename parameter arguments, choose names that match // the fragment initialization parameters, e.g. ARG_ITEM_NUMBER private static final String ARG_PARAM1 = "param1"; private static final String ARG_PARAM2 = "param2"; // TODO: Rename and change types of parameters private String mParam1; private String mParam2; public PrincipalFragment() { // Required empty public constructor } /** * Use this factory method to create a new instance of * this fragment using the provided parameters. * * @param param1 Parameter 1. * @param param2 Parameter 2. * @return A new instance of fragment PrincipalFragment. */ // TODO: Rename and change types and number of parameters public static PrincipalFragment newInstance(String param1, String param2) { PrincipalFragment fragment = new PrincipalFragment(); Bundle args = new Bundle(); args.putString(ARG_PARAM1, param1); args.putString(ARG_PARAM2, param2); fragment.setArguments(args); return fragment; } @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); if (getArguments() != null) { mParam1 = getArguments().getString(ARG_PARAM1); mParam2 = getArguments().getString(ARG_PARAM2); } } @Override public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { // Inflate the layout for this fragment return inflater.inflate(R.layout.fragment_principal, container, false); } }
[ "ricknogueira1231@gmail.com" ]
ricknogueira1231@gmail.com
644b7e6428a4690bc286e1ebff76521db13e69ee
667e3a45a797cb29e32a5a5444da9d95f8420b7a
/src/com/calculationEngine/Divider.java
b5be264b3ef4aa0c7e499b82b8e513239da98517
[]
no_license
neoyiukit/CalculationEngine
26f4adcfaae456ca942dea5572c91956b7fd707b
97f7825f495d0bffc7496b5b33a8015ba9f7ca76
refs/heads/master
2021-01-16T18:55:40.481148
2017-08-13T15:44:03
2017-08-13T15:44:03
100,128,096
0
0
null
null
null
null
UTF-8
Java
false
false
369
java
package com.calculationEngine; /** * Created by neo.yiu on 07/08/2017. */ public class Divider extends CalculateBase{ public Divider(){} public Divider(double leftVal, double rightVal){ super(leftVal, rightVal); } @Override public void calculate() { double value = getLeftVal() / getRightVal(); setResult(value); } }
[ "neo.yiu@rakuten.com" ]
neo.yiu@rakuten.com
422c8e89c678bfa9ab55d8b168b61b1f78e1d465
b1d3063b797e671f413419d997a9bc492300519b
/ParamExcelPhantom/src/main/java/AddUserPage.java
f44292563f37520ef56eb7fbfd8929cbc46f4264
[]
no_license
declanmcgee01/AutomatedTesting
a42725968e9b2b6ac4720eaa4226a97ae1df1340
cf3eb831016db65176ffa28ba3686a0ff3d55751
refs/heads/master
2020-04-19T17:19:30.488811
2019-01-31T16:26:12
2019-01-31T16:26:12
168,331,102
0
0
null
null
null
null
UTF-8
Java
false
false
422
java
import org.openqa.selenium.WebElement; import org.openqa.selenium.support.FindBy; public class AddUserPage { @FindBy(name = "username") private WebElement username; @FindBy(name = "password") private WebElement password; @FindBy(name = "FormsButton2") private WebElement button; public void addUser(String user, String pass) { username.sendKeys(user); password.sendKeys(pass); button.click(); } }
[ "declanmcgee1995@gmail.com" ]
declanmcgee1995@gmail.com
8ad364e5e82bdc42162b972faf86c2edaa94b048
e078e97dba70d85bdc836610a6e276979ed2d3c7
/src/main/java/com/leap/service/connect/IAuthServer.java
dc46fb961f748c433854892899c16cc1a1ac5742
[]
no_license
leap66/spring_boot
f11c15253f36e29f5ed41e8ebfdccdab45bd200d
2100b8d7984fc810a0f2eff6e0e363093220a975
refs/heads/master
2021-09-13T16:55:56.947968
2017-12-22T04:58:37
2017-12-22T04:58:37
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,474
java
package com.leap.service.connect; import com.leap.handle.exception.base.BaseException; import com.leap.model.Auth; import com.leap.model.User; /** * @author : ylwei * @time : 2017/9/18 * @description : */ public interface IAuthServer { /** * 注册 * * @return String */ public String register(Auth auth) throws BaseException; /** * 登陆 * * @return User */ public User login(String mobile, String password) throws BaseException; /** * 注销登陆 * * @return boolean */ public boolean logout(String id) throws BaseException; /** * 发送验证码 * * @return boolean */ public boolean sendSms(String mobile, boolean exist) throws BaseException; /** * 校验验证码 * * @return boolean */ public boolean checkSms(String mobile, String code) throws BaseException; /** * 重置密码 * * @return boolean */ public boolean pwdReset(String mobile, String password, String code) throws BaseException; /** * 修改手机号 * * @return Response */ public String mobileReset(String mobile, String oldMobile, String code) throws BaseException; /** * 删除 */ public boolean delete(String mobile) throws BaseException; /** * 查-ID * * @return Auth */ public Auth findById(String id) throws BaseException; /** * 查-Mobile * * @return Auth */ public Auth findByMobile(String mobile) throws BaseException; }
[ "weiyaling@hd123.com" ]
weiyaling@hd123.com
8608dd7e69e89e1025fb985c8555144beb808f35
2eaaf371e32040474bb8dbcb55410dba79fc6799
/app/build/generated/source/r/debug/android/support/slidingpanelayout/R.java
7e539419e5d5d4202ef5a2029ddbfeaa8143734f
[ "Apache-2.0" ]
permissive
monashamsolebad/DroidCafe1
4b2d4eb757ae05b5233e7547dd40d547a3e6473d
d9807a12f2b74cacbaa001666db0a46d15cbcdb1
refs/heads/master
2020-05-28T05:23:27.230201
2019-05-27T18:29:14
2019-05-27T18:29:14
188,891,450
0
0
null
null
null
null
UTF-8
Java
false
false
10,178
java
/* AUTO-GENERATED FILE. DO NOT MODIFY. * * This class was automatically generated by the * gradle plugin from the resource data it found. It * should not be modified by hand. */ package android.support.slidingpanelayout; public final class R { public static final class attr { public static final int alpha = 0x7f040027; public static final int font = 0x7f0400d7; public static final int fontProviderAuthority = 0x7f0400d9; public static final int fontProviderCerts = 0x7f0400da; public static final int fontProviderFetchStrategy = 0x7f0400db; public static final int fontProviderFetchTimeout = 0x7f0400dc; public static final int fontProviderPackage = 0x7f0400dd; public static final int fontProviderQuery = 0x7f0400de; public static final int fontStyle = 0x7f0400df; public static final int fontVariationSettings = 0x7f0400e0; public static final int fontWeight = 0x7f0400e1; public static final int ttcIndex = 0x7f040208; } public static final class color { public static final int notification_action_color_filter = 0x7f06006a; public static final int notification_icon_bg_color = 0x7f06006b; public static final int ripple_material_light = 0x7f060075; public static final int secondary_text_default_material_light = 0x7f060077; } public static final class dimen { public static final int compat_button_inset_horizontal_material = 0x7f07004e; public static final int compat_button_inset_vertical_material = 0x7f07004f; public static final int compat_button_padding_horizontal_material = 0x7f070050; public static final int compat_button_padding_vertical_material = 0x7f070051; public static final int compat_control_corner_material = 0x7f070052; public static final int compat_notification_large_icon_max_height = 0x7f070053; public static final int compat_notification_large_icon_max_width = 0x7f070054; public static final int notification_action_icon_size = 0x7f0700c0; public static final int notification_action_text_size = 0x7f0700c1; public static final int notification_big_circle_margin = 0x7f0700c2; public static final int notification_content_margin_start = 0x7f0700c3; public static final int notification_large_icon_height = 0x7f0700c4; public static final int notification_large_icon_width = 0x7f0700c5; public static final int notification_main_column_padding_top = 0x7f0700c6; public static final int notification_media_narrow_margin = 0x7f0700c7; public static final int notification_right_icon_size = 0x7f0700c8; public static final int notification_right_side_padding_top = 0x7f0700c9; public static final int notification_small_icon_background_padding = 0x7f0700ca; public static final int notification_small_icon_size_as_large = 0x7f0700cb; public static final int notification_subtext_size = 0x7f0700cc; public static final int notification_top_pad = 0x7f0700cd; public static final int notification_top_pad_large_text = 0x7f0700ce; } public static final class drawable { public static final int notification_action_background = 0x7f080072; public static final int notification_bg = 0x7f080073; public static final int notification_bg_low = 0x7f080074; public static final int notification_bg_low_normal = 0x7f080075; public static final int notification_bg_low_pressed = 0x7f080076; public static final int notification_bg_normal = 0x7f080077; public static final int notification_bg_normal_pressed = 0x7f080078; public static final int notification_icon_background = 0x7f080079; public static final int notification_template_icon_bg = 0x7f08007a; public static final int notification_template_icon_low_bg = 0x7f08007b; public static final int notification_tile_bg = 0x7f08007c; public static final int notify_panel_notification_icon_bg = 0x7f08007d; } public static final class id { public static final int action_container = 0x7f09000e; public static final int action_divider = 0x7f090010; public static final int action_image = 0x7f090012; public static final int action_text = 0x7f09001a; public static final int actions = 0x7f09001b; public static final int async = 0x7f090023; public static final int blocking = 0x7f090027; public static final int chronometer = 0x7f09002f; public static final int forever = 0x7f090053; public static final int icon = 0x7f09005e; public static final int icon_group = 0x7f09005f; public static final int info = 0x7f090062; public static final int italic = 0x7f090064; public static final int line1 = 0x7f09006a; public static final int line3 = 0x7f09006b; public static final int normal = 0x7f09007b; public static final int notification_background = 0x7f09007e; public static final int notification_main_column = 0x7f09007f; public static final int notification_main_column_container = 0x7f090080; public static final int right_icon = 0x7f090091; public static final int right_side = 0x7f090092; public static final int tag_transition_group = 0x7f0900bf; public static final int tag_unhandled_key_event_manager = 0x7f0900c0; public static final int tag_unhandled_key_listeners = 0x7f0900c1; public static final int text = 0x7f0900c2; public static final int text2 = 0x7f0900c3; public static final int time = 0x7f0900cc; public static final int title = 0x7f0900cd; } public static final class integer { public static final int status_bar_notification_info_maxnum = 0x7f0a000e; } public static final class layout { public static final int notification_action = 0x7f0c002f; public static final int notification_action_tombstone = 0x7f0c0030; public static final int notification_template_custom_big = 0x7f0c0031; public static final int notification_template_icon_group = 0x7f0c0032; public static final int notification_template_part_chronometer = 0x7f0c0033; public static final int notification_template_part_time = 0x7f0c0034; } public static final class string { public static final int status_bar_notification_info_overflow = 0x7f0f003f; } public static final class style { public static final int TextAppearance_Compat_Notification = 0x7f100118; public static final int TextAppearance_Compat_Notification_Info = 0x7f100119; public static final int TextAppearance_Compat_Notification_Line2 = 0x7f10011a; public static final int TextAppearance_Compat_Notification_Time = 0x7f10011b; public static final int TextAppearance_Compat_Notification_Title = 0x7f10011c; public static final int Widget_Compat_NotificationActionContainer = 0x7f1001c2; public static final int Widget_Compat_NotificationActionText = 0x7f1001c3; } public static final class styleable { public static final int[] ColorStateListItem = { 0x010101a5, 0x0101031f, 0x7f040027 }; public static final int ColorStateListItem_android_color = 0; public static final int ColorStateListItem_android_alpha = 1; public static final int ColorStateListItem_alpha = 2; public static final int[] FontFamily = { 0x7f0400d9, 0x7f0400da, 0x7f0400db, 0x7f0400dc, 0x7f0400dd, 0x7f0400de }; public static final int FontFamily_fontProviderAuthority = 0; public static final int FontFamily_fontProviderCerts = 1; public static final int FontFamily_fontProviderFetchStrategy = 2; public static final int FontFamily_fontProviderFetchTimeout = 3; public static final int FontFamily_fontProviderPackage = 4; public static final int FontFamily_fontProviderQuery = 5; public static final int[] FontFamilyFont = { 0x01010532, 0x01010533, 0x0101053f, 0x0101056f, 0x01010570, 0x7f0400d7, 0x7f0400df, 0x7f0400e0, 0x7f0400e1, 0x7f040208 }; public static final int FontFamilyFont_android_font = 0; public static final int FontFamilyFont_android_fontWeight = 1; public static final int FontFamilyFont_android_fontStyle = 2; public static final int FontFamilyFont_android_ttcIndex = 3; public static final int FontFamilyFont_android_fontVariationSettings = 4; public static final int FontFamilyFont_font = 5; public static final int FontFamilyFont_fontStyle = 6; public static final int FontFamilyFont_fontVariationSettings = 7; public static final int FontFamilyFont_fontWeight = 8; public static final int FontFamilyFont_ttcIndex = 9; public static final int[] GradientColor = { 0x0101019d, 0x0101019e, 0x010101a1, 0x010101a2, 0x010101a3, 0x010101a4, 0x01010201, 0x0101020b, 0x01010510, 0x01010511, 0x01010512, 0x01010513 }; public static final int GradientColor_android_startColor = 0; public static final int GradientColor_android_endColor = 1; public static final int GradientColor_android_type = 2; public static final int GradientColor_android_centerX = 3; public static final int GradientColor_android_centerY = 4; public static final int GradientColor_android_gradientRadius = 5; public static final int GradientColor_android_tileMode = 6; public static final int GradientColor_android_centerColor = 7; public static final int GradientColor_android_startX = 8; public static final int GradientColor_android_startY = 9; public static final int GradientColor_android_endX = 10; public static final int GradientColor_android_endY = 11; public static final int[] GradientColorItem = { 0x010101a5, 0x01010514 }; public static final int GradientColorItem_android_color = 0; public static final int GradientColorItem_android_offset = 1; } }
[ "shamsolebad.mona@gmail.com" ]
shamsolebad.mona@gmail.com
f970cf0d7ddc13ca44d95463c05d534da48558cd
ad27764c00aea69f57e5ec2135634c02ab3d4a8e
/src/main/java/com/wavemaker/tests/api/exception/WmTestExceptionMessage.java
29f8c6576888348a4f57d41dca85db0555cbe8ee
[]
no_license
tejaswim/wavemaker-api-tests
8cd8cf3ced7d1ea0203db06bedd18ae5b72ebc24
b035f173819f7ec522b13565814d2508470b1574
refs/heads/master
2021-08-22T20:36:19.930242
2017-12-01T07:00:05
2017-12-01T07:00:06
111,686,743
0
0
null
null
null
null
UTF-8
Java
false
false
239
java
package com.wavemaker.tests.api.exception; /** * Created by venkateswarluk on 13/7/17. */ public class WmTestExceptionMessage { public static final String PROJECT_CREATION_FAILED = "Error occurred while creating designtime - %s"; }
[ "tejaswi.maryala@wavemaker.com" ]
tejaswi.maryala@wavemaker.com
b2078a0111a29884b856032b1c33a0567c7ff06d
f822577012dcd3e1b0808374736b5b94c05e9fc2
/server_study02/src/com/wmp/server/Server05.java
88d22807b15a45d9a6ccc238fb8f5fb7d6909139
[]
no_license
wumingpu/JavaStudy
0ac06350020347a87b816c41e9d2e70cf661570f
02d94b68fd785c0f779b9aff32e39b00e5debf90
refs/heads/master
2020-05-13T21:03:22.244691
2018-11-16T10:52:44
2018-11-16T10:52:44
26,054,112
0
0
null
null
null
null
UTF-8
Java
false
false
1,515
java
package com.wmp.server; import java.io.BufferedWriter; import java.io.IOException; import java.io.InputStream; import java.io.OutputStreamWriter; import java.net.ServerSocket; import java.net.Socket; import java.util.Date; /** * 封装请求信息 * @author WMP * */ public class Server05 { private ServerSocket serverSocket; public static void main(String[] args) { Server05 server = new Server05(); server.start(); } // 启动服务 public void start() { try { serverSocket = new ServerSocket(8888); receive(); } catch (IOException e) { e.printStackTrace(); System.out.println("服务器启动失败..."); } } // 接收连接处理 public void receive() { try { Socket client = serverSocket.accept(); System.out.println("一个客户端建立了链接"); // 获取请求协议 Request2 request = new Request2(client); Response response = new Response(client); // 关注内容 response.print("<html>"); response.print("<head>"); response.print("<title>"); response.print("服务器响应成功"); response.print("</title>"); response.print("</head>"); response.print("<body>"); response.print("wmpServer终于回来了..."+request.getParameterValue("uname")); response.print("</body>"); response.print("</html>"); // 关注状态码 response.pushToBrowser(200); } catch (IOException e) { e.printStackTrace(); System.out.println("客户端错误"); } } // 停止服务 public void stop() { } }
[ "mingpu.wu@us.beyondosft.com" ]
mingpu.wu@us.beyondosft.com
9430f69339022c6c9b056f8320296195302d6315
6d44df37a12f1b811f6528377115917d672dc710
/keyboardstatuslistener/src/main/java/com/ak961/keyboardstatuslistener/KeyboardListener.java
ac685befa6d6f32d618a6e7dd8ab31cc0f6d66f2
[ "MIT" ]
permissive
droidhubworld/Keyboard-Status-Listener
3853afad8315266a86a63a4772f9ade1826c55b7
13405d389905b65571749fc4caaa4d410b05210e
refs/heads/master
2022-04-15T17:20:25.712288
2020-04-17T12:31:34
2020-04-17T12:31:34
256,479,262
1
0
null
null
null
null
UTF-8
Java
false
false
130
java
package com.ak961.keyboardstatuslistener; public interface KeyboardListener { void onKeyboardStatusChange(Boolean isOpen); }
[ "anandkumar.omnisttechhub@gmail.com" ]
anandkumar.omnisttechhub@gmail.com
e7bdbac0e0c5c75b1b496639886ffe1cb5c385c3
69d02bc1bffd55a87e78544ba5494b0ff00e9e11
/src/main/java/com/sx/drainage/service/impl/ProjectCriticalProjectServiceImpl.java
6b95ebbffaf5574efbaa8428504f3bc66456be6a
[]
no_license
wangchongyang0730/drainage
c9e4433cfc6e64bd4be17b9856e3e2399c78228c
8f94b8298e699f876050b07db60b282593b7ab20
refs/heads/master
2023-08-27T02:29:25.043194
2021-10-19T08:37:38
2021-10-19T08:37:38
418,842,723
0
0
null
null
null
null
UTF-8
Java
false
false
2,685
java
package com.sx.drainage.service.impl; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.sx.drainage.common.CreateUuid; import com.sx.drainage.common.PageUtils; import com.sx.drainage.common.Query; import com.sx.drainage.dao.ProjectCriticalProjectDao; import com.sx.drainage.entity.OmAccountEntity; import com.sx.drainage.entity.ProjectCriticalProjectEntity; import com.sx.drainage.service.OmAccountService; import com.sx.drainage.service.ProjectCriticalProjectService; import lombok.RequiredArgsConstructor; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; import java.util.Date; import java.util.HashMap; import java.util.List; import java.util.Map; /** * Created with IntelliJ IDEA. * User: QianMo * Date: 2020/11/19 * Time: 16:10 */ @Service @Transactional @RequiredArgsConstructor public class ProjectCriticalProjectServiceImpl extends ServiceImpl<ProjectCriticalProjectDao, ProjectCriticalProjectEntity> implements ProjectCriticalProjectService { private final OmAccountService omAccountService; /* * 根据项目id获取危大工程 * , Integer page, Integer limit * */ @Override public List<ProjectCriticalProjectEntity> getAllByProjectId(String projectId) { /*Map<String, Object> map = new HashMap<>(); map.put("page", page.toString()); map.put("limit", limit.toString()); IPage<ProjectCriticalProjectEntity> iPage = this.page( new Query<ProjectCriticalProjectEntity>().getPage(map), new QueryWrapper<ProjectCriticalProjectEntity>().eq("projectId",projectId) ); return new PageUtils(iPage);*/ return this.list(new QueryWrapper<ProjectCriticalProjectEntity>().eq("projectId",projectId)); } /* * 添加危大工程 * */ @Override public void addCriticalProject(ProjectCriticalProjectEntity entity,String userId) { entity.setSysId(CreateUuid.uuid()); entity.setCreateDate(new Date()); entity.setCreateUserId(userId); OmAccountEntity user = omAccountService.getUser(userId); entity.setCreateUserName(user.getName()); this.save(entity); } /* * 删除危大工程 * */ @Override public void deleteCriticalProject(String sysId) { this.removeById(sysId); } /* * 修改危大工程 * */ @Override public void updateCriticalProject(ProjectCriticalProjectEntity entity) { this.updateById(entity); } }
[ "744826699@qq.com" ]
744826699@qq.com
f9a88780c4ebe33e2492162cdb5b2cc6f6f2e1f5
a2893ede0fd80ae186bebf2326522b6652ea5772
/src/adventofcode04/main.java
79639eb000add373d8baa8b64faf51ea53da2049
[]
no_license
Markvatr/AdventOfCode
85ef39d46f887382957b4cdaef884e405d36199b
aa739e2d7e71866100f9a801c3d3810b06a572fd
refs/heads/master
2020-04-09T07:50:22.661165
2018-12-05T20:30:29
2018-12-05T20:30:29
160,172,632
0
0
null
null
null
null
UTF-8
Java
false
false
4,651
java
package adventofcode04; import java.io.BufferedReader; import java.io.FileNotFoundException; import java.io.FileReader; import java.io.IOException; import java.text.ParseException; import java.text.SimpleDateFormat; import java.util.ArrayList; import java.util.Arrays; import java.util.Comparator; import java.util.Date; /** * * @author Sebastian */ public class main { static SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm"); public static void main(String[] args) throws FileNotFoundException, IOException, ParseException { BufferedReader br = new BufferedReader(new FileReader("texts/04")); ArrayList<String> data = new ArrayList<String>(); bufferToList(data, br); ArrayList<rowFormat> formatedData = new ArrayList<rowFormat>(); ArrayList<daySchedule> schedule = new ArrayList<daySchedule>(); for (String s : data) { formatedData.add(new rowFormat(s)); } formatedData.sort(new CustomComparator()); int prevGuard = -1; for (int i = 0; i < formatedData.size(); i++) { if(formatedData.get(i).getEvent().equals("Guard")){ schedule.add(new daySchedule(formatedData.get(i).getGuardID(), sdf.parse(formatedData.get(i).getDate()))); prevGuard++; }else{ schedule.get(prevGuard).add(formatedData.get(i).getMin(), formatedData.get(i).getEvent()); } } for(daySchedule ds : schedule){ System.out.println(Arrays.toString(ds.getActiveHours())); } } public static class CustomComparator implements Comparator<rowFormat> { @Override public int compare(rowFormat o1, rowFormat o2) { try { return sdf.parse(o1.getDate()).compareTo(sdf.parse(((rowFormat) o2).getDate())); } catch (ParseException ex) { } return 0; } } protected static class rowFormat { ArrayList<String> formatedRow = new ArrayList<String>(); protected rowFormat(String s) { formatedRow.add(s.substring(1, 17)); formatedRow.add(s.substring(19, 24)); if (s.indexOf("#") != -1) { int temp = s.indexOf("b", s.indexOf("#")); formatedRow.add(s.substring(s.indexOf("#"), temp)); } else { formatedRow.add(null); } } protected String getDate() { return formatedRow.get(0); } protected int getMin() throws ParseException{ return sdf.parse(getDate()).getMinutes(); } protected String getEvent() { return formatedRow.get(1); } protected String getGuardID() { return formatedRow.get(2); } } protected static class daySchedule { Date date; String guardID; ArrayList<Integer> eventstime = new ArrayList<Integer>(); ArrayList<String> events = new ArrayList<String>(); String[] activeHours = new String[59]; /** * * @param guardID * @param workDate */ protected daySchedule(String guardID, Date workDate) { date = workDate; this.guardID = guardID; } protected void add(int time, String event) { eventstime.add(time); events.add(event); } protected Date getDate() { return date; } protected String[] getActiveHours() { for (int i = 0; i < activeHours.length; i++) { activeHours[i] = "."; } for (int i = 0; i < events.size(); i++) { switch (events.get(i)) { case "falls": for (int j = eventstime.get(i); j < eventstime.get(i + 1); j++) { activeHours[j] = "X"; } break; case "wakes": break; } } return activeHours; } } private static void bufferToList(ArrayList<String> data, BufferedReader br) throws IOException { while (true) { String temp = br.readLine(); if (temp == null) { break; } data.add(temp); } } }
[ "sbstn96@gmail.com" ]
sbstn96@gmail.com
5c83dafd8705cfd097fa2d6ef74428bc589a46db
13edecd43d979ff6daf21a01fffc050944b36f02
/rpc/src/main/java/com/yanghui/distributed/rpc/config/RegistryConfig.java
8a760cbe046c253e8431e23a4bae66a253e65d5b
[]
no_license
rainofflower/distributed-service
add03fecdbe43a6391781ba301aafb837edb57cc
f553e636d82909c43522dd561a9df53f3d3cdcdb
refs/heads/master
2022-10-21T23:08:23.204690
2020-08-19T18:07:06
2020-08-19T18:07:06
221,436,414
2
0
null
2022-10-04T23:56:16
2019-11-13T10:46:57
Java
UTF-8
Java
false
false
10,866
java
package com.yanghui.distributed.rpc.config; import java.io.Serializable; import java.util.Map; import java.util.concurrent.ConcurrentHashMap; import static com.yanghui.distributed.rpc.common.RpcConfigs.*; import static com.yanghui.distributed.rpc.common.RpcOptions.*; /** * 注册中心配置 * * */ public class RegistryConfig implements Serializable { /** * The constant serialVersionUID. */ private static final long serialVersionUID = -2921019924557602234L; /** * 协议 */ private String protocol = getStringValue(DEFAULT_REGISTRY); /** * 指定注册中心的地址, 和index必须填一个,address优先 */ private String address; /** * 指定注册中心寻址服务的地址, 和address必须填一个 */ private String index = getStringValue(REGISTRY_INDEX_ADDRESS); /** * 是否注册,如果是false只订阅不注册 */ private boolean register = getBooleanValue(SERVICE_REGISTER); /** * 是否订阅服务 */ private boolean subscribe = getBooleanValue(SERVICE_SUBSCRIBE); /** * 调用注册中心超时时间 */ private int timeout = getIntValue(REGISTRY_INVOKE_TIMEOUT); /** * 连接注册中心超时时间 */ private int connectTimeout = getIntValue(REGISTRY_CONNECT_TIMEOUT); /** * 保存到本地文件的位置,默认$HOME下 */ private String file; /** * 是否批量操作 */ private boolean batch = getBooleanValue(REGISTRY_BATCH); /** * 定时批量检查时的条目数 */ private int batchSize = getIntValue(REGISTRY_BATCH_SIZE); /** * Consumer给Provider发心跳的间隔 */ protected int heartbeatPeriod = getIntValue(REGISTRY_HEARTBEAT_PERIOD); /** * Consumer给Provider重连的间隔 */ protected int reconnectPeriod = getIntValue(REGISTRY_RECONNECT_PERIOD); /** * The Parameters. 自定义参数 */ protected Map<String, String> parameters; /** * Gets protocol. * * @return the protocol */ public String getProtocol() { return protocol; } /** * Sets protocol. * * @param protocol the protocol * @return the protocol */ public RegistryConfig setProtocol(String protocol) { this.protocol = protocol; return this; } /** * Gets address. * * @return the address */ public String getAddress() { return address; } /** * Sets address. * * @param address the address * @return the address */ public RegistryConfig setAddress(String address) { this.address = address; return this; } /** * Gets index. * * @return the index */ public String getIndex() { return index; } /** * Sets index. * * @param index the index * @return the index */ public RegistryConfig setIndex(String index) { this.index = index; return this; } /** * Is register boolean. * * @return the boolean */ public boolean isRegister() { return register; } /** * Sets register. * * @param register the register * @return the register */ public RegistryConfig setRegister(boolean register) { this.register = register; return this; } /** * Is subscribe boolean. * * @return the boolean */ public boolean isSubscribe() { return subscribe; } /** * Sets subscribe. * * @param subscribe the subscribe * @return the subscribe */ public RegistryConfig setSubscribe(boolean subscribe) { this.subscribe = subscribe; return this; } /** * Gets timeout. * * @return the timeout */ public int getTimeout() { return timeout; } /** * Sets timeout. * * @param timeout the timeout * @return the timeout */ public RegistryConfig setTimeout(int timeout) { this.timeout = timeout; return this; } /** * Gets connect timeout. * * @return the connect timeout */ public int getConnectTimeout() { return connectTimeout; } /** * Sets connect timeout. * * @param connectTimeout the connect timeout * @return the connect timeout */ public RegistryConfig setConnectTimeout(int connectTimeout) { this.connectTimeout = connectTimeout; return this; } /** * Gets file. * * @return the file */ public String getFile() { return file; } /** * Sets file. * * @param file the file * @return the file */ public RegistryConfig setFile(String file) { this.file = file; return this; } /** * Is batch boolean. * * @return the boolean */ public boolean isBatch() { return batch; } /** * Sets batch. * * @param batch the batch * @return the batch */ public RegistryConfig setBatch(boolean batch) { this.batch = batch; return this; } /** * Gets batch check. * * @return the batch check */ public int getBatchSize() { return batchSize; } /** * Sets batch check. * * @param batchSize the batch check * @return the batch check */ public RegistryConfig setBatchSize(int batchSize) { this.batchSize = batchSize; return this; } /** * Gets heartbeatPeriod. * * @return the heartbeatPeriod */ public int getHeartbeatPeriod() { return heartbeatPeriod; } /** * Sets heartbeatPeriod. * * @param heartbeatPeriod the heartbeatPeriod * @return the heartbeatPeriod */ public RegistryConfig setHeartbeatPeriod(int heartbeatPeriod) { this.heartbeatPeriod = heartbeatPeriod; return this; } /** * Gets reconnectPeriod. * * @return the reconnectPeriod */ public int getReconnectPeriod() { return reconnectPeriod; } /** * Sets reconnectPeriod. * * @param reconnectPeriod the reconnectPeriod * @return the reconnectPeriod */ public RegistryConfig setReconnectPeriod(int reconnectPeriod) { this.reconnectPeriod = reconnectPeriod; return this; } /** * Gets parameters. * * @return the parameters */ public Map<String, String> getParameters() { return parameters; } /** * Sets parameters. * * @param parameters the parameters * @return the RegistryConfig */ public RegistryConfig setParameters(Map<String, String> parameters) { if (this.parameters == null) { this.parameters = new ConcurrentHashMap<String, String>(); this.parameters.putAll(parameters); } return this; } /** * Sets parameter. * * @param key the key * @param value the value * @return the RegistryConfig */ public RegistryConfig setParameter(String key, String value) { if (parameters == null) { parameters = new ConcurrentHashMap<String, String>(); } parameters.put(key, value); return this; } /** * Gets parameter. * * @param key the key * @return the value */ public String getParameter(String key) { return parameters == null ? null : parameters.get(key); } @Override public String toString() { return "RegistryConfig{" + "protocol='" + protocol + '\'' + ", address='" + address + '\'' + ", index='" + index + '\'' + ", register=" + register + ", subscribe=" + subscribe + ", timeout=" + timeout + ", connectTimeout=" + connectTimeout + ", file='" + file + '\'' + ", batch=" + batch + ", batchSize=" + batchSize + ", heartbeatPeriod=" + heartbeatPeriod + ", reconnectPeriod=" + reconnectPeriod + ", parameters=" + parameters + '}'; } @Override public boolean equals(Object o) { if (this == o) { return true; } if (!(o instanceof RegistryConfig)) { return false; } RegistryConfig that = (RegistryConfig) o; if (register != that.register) { return false; } if (subscribe != that.subscribe) { return false; } if (timeout != that.timeout) { return false; } if (connectTimeout != that.connectTimeout) { return false; } if (batch != that.batch) { return false; } if (batchSize != that.batchSize) { return false; } if (heartbeatPeriod != that.heartbeatPeriod) { return false; } if (reconnectPeriod != that.reconnectPeriod) { return false; } if (!protocol.equals(that.protocol)) { return false; } if (address != null ? !address.equals(that.address) : that.address != null) { return false; } if (index != null ? !index.equals(that.index) : that.index != null) { return false; } if (file != null ? !file.equals(that.file) : that.file != null) { return false; } return parameters != null ? parameters.equals(that.parameters) : that.parameters == null; } @Override public int hashCode() { int result = protocol.hashCode(); result = 31 * result + (address != null ? address.hashCode() : 0); result = 31 * result + (index != null ? index.hashCode() : 0); result = 31 * result + (register ? 1 : 0); result = 31 * result + (subscribe ? 1 : 0); result = 31 * result + timeout; result = 31 * result + connectTimeout; result = 31 * result + (file != null ? file.hashCode() : 0); result = 31 * result + (batch ? 1 : 0); result = 31 * result + batchSize; result = 31 * result + heartbeatPeriod; result = 31 * result + reconnectPeriod; result = 31 * result + (parameters != null ? parameters.hashCode() : 0); return result; } }
[ "rainofflower.yh@qq.com" ]
rainofflower.yh@qq.com
f1f7a6e1b2355646f418ee6664d7ca54e8624074
0e71ab06b33e7203f6659ff23acee47a5678b073
/HW01/tester/org/objenesis/instantiator/basic/ConstructorInstantiator.java
f30a0b14b4a2ac7c654d789c3b87a70b2b4869b2
[ "MIT", "BSD-3-Clause", "Apache-2.0" ]
permissive
przrak/homework_tester
10243be8b6d16d54cc0fc24f6d213efee3c300c8
9b292dc6c07abb466d6ad568931b84b6ac718401
refs/heads/master
2020-04-21T21:29:58.597449
2019-02-10T16:40:48
2019-02-10T16:40:48
169,880,768
0
0
MIT
2019-02-09T15:27:29
2019-02-09T15:27:29
null
UTF-8
Java
false
false
913
java
package org.objenesis.instantiator.basic; import java.lang.reflect.Constructor; import org.objenesis.ObjenesisException; import org.objenesis.instantiator.ObjectInstantiator; /** * Instantiates a class by grabbing the no args constructor and calling Constructor.newInstance(). * This can deal with default public constructors, but that's about it. * * @see ObjectInstantiator */ public class ConstructorInstantiator implements ObjectInstantiator { protected Constructor constructor; public ConstructorInstantiator(Class type) { try { constructor = type.getDeclaredConstructor((Class[]) null); } catch(Exception e) { throw new ObjenesisException(e); } } public Object newInstance() { try { return constructor.newInstance((Object[]) null); } catch(Exception e) { throw new ObjenesisException(e); } } }
[ "przrak@gmail.com" ]
przrak@gmail.com
2dcffa6d66910777ecc1e16a9864061e9d06e4e0
013e83b707fe5cd48f58af61e392e3820d370c36
/spring-webmvc-portlet/src/main/java/org/springframework/web/portlet/handler/HandlerInterceptorAdapter.java
489ea97764f0fc319e28416f25342ad83f6a0a0c
[]
no_license
yuexiaoguang/spring4
8376f551fefd33206adc3e04bc58d6d32a825c37
95ea25bbf46ee7bad48307e41dcd027f1a0c67ae
refs/heads/master
2020-05-27T20:27:54.768860
2019-09-02T03:39:57
2019-09-02T03:39:57
188,770,867
0
1
null
null
null
null
UTF-8
Java
false
false
3,583
java
package org.springframework.web.portlet.handler; import javax.portlet.ActionRequest; import javax.portlet.ActionResponse; import javax.portlet.EventRequest; import javax.portlet.EventResponse; import javax.portlet.PortletRequest; import javax.portlet.PortletResponse; import javax.portlet.RenderRequest; import javax.portlet.RenderResponse; import javax.portlet.ResourceRequest; import javax.portlet.ResourceResponse; import org.springframework.web.portlet.HandlerInterceptor; import org.springframework.web.portlet.ModelAndView; /** * {@link HandlerInterceptor}接口的抽象适配器类, 用于简化pre-only/post-only拦截器的实现. */ public abstract class HandlerInterceptorAdapter implements HandlerInterceptor { /** * 此实现委托给{@link #preHandle}. */ @Override public boolean preHandleAction(ActionRequest request, ActionResponse response, Object handler) throws Exception { return preHandle(request, response, handler); } /** * 此实现委托给{@link #afterCompletion}. */ @Override public void afterActionCompletion( ActionRequest request, ActionResponse response, Object handler, Exception ex) throws Exception { afterCompletion(request, response, handler, ex); } /** * 此实现委托给{@link #preHandle}. */ @Override public boolean preHandleRender(RenderRequest request, RenderResponse response, Object handler) throws Exception { return preHandle(request, response, handler); } /** * 此实现为空. */ @Override public void postHandleRender( RenderRequest request, RenderResponse response, Object handler, ModelAndView modelAndView) throws Exception { } /** * 此实现委托给{@link #afterCompletion}. */ @Override public void afterRenderCompletion( RenderRequest request, RenderResponse response, Object handler, Exception ex) throws Exception { afterCompletion(request, response, handler, ex); } /** * 此实现委托给{@link #preHandle}. */ @Override public boolean preHandleResource(ResourceRequest request, ResourceResponse response, Object handler) throws Exception { return preHandle(request, response, handler); } /** * 此实现为空. */ @Override public void postHandleResource( ResourceRequest request, ResourceResponse response, Object handler, ModelAndView modelAndView) throws Exception { } /** * 此实现委托给{@link #afterCompletion}. */ @Override public void afterResourceCompletion( ResourceRequest request, ResourceResponse response, Object handler, Exception ex) throws Exception { afterCompletion(request, response, handler, ex); } /** * 此实现委托给{@link #preHandle}. */ @Override public boolean preHandleEvent(EventRequest request, EventResponse response, Object handler) throws Exception { return preHandle(request, response, handler); } /** * 此实现委托给{@link #afterCompletion}. */ @Override public void afterEventCompletion( EventRequest request, EventResponse response, Object handler, Exception ex) throws Exception { afterCompletion(request, response, handler, ex); } /** * 所有"pre*"方法委托的默认回调. * <p>此实现始终返回{@code true}. */ protected boolean preHandle(PortletRequest request, PortletResponse response, Object handler) throws Exception { return true; } /** * 所有"after*"方法委托的默认回调. * <p>此实现为空. */ protected void afterCompletion( PortletRequest request, PortletResponse response, Object handler, Exception ex) throws Exception { } }
[ "yuexiaoguang@vortexinfo.cn" ]
yuexiaoguang@vortexinfo.cn
845cdda8f0bccd685a4494455f6c1dea51bacaf1
6cf7702886ff8fd9d088ebd7b8dfdd48b1dbe5e3
/csparql-core/src/main/java/eu/larkc/csparql/core/old_parser/SparqlProducer1_0.java
bfdcda908be3bb7c8de2746c03bc1ebe4522aa99
[ "LicenseRef-scancode-warranty-disclaimer", "Apache-2.0", "LicenseRef-scancode-unknown-license-reference" ]
permissive
pbmdq/CSPARQL-engine
1aed547919126156ec16046b55d8282e2c618fce
f1018f36c596aa596b1c345a91387a05745b4bb7
refs/heads/master
2020-12-31T01:23:03.435135
2015-10-28T17:16:54
2015-10-28T17:16:54
null
0
0
null
null
null
null
UTF-8
Java
false
false
4,614
java
/******************************************************************************* * Copyright 2014 DEIB -Politecnico di Milano * * Marco Balduini (marco.balduini@polimi.it) * Emanuele Della Valle (emanuele.dellavalle@polimi.it) * Davide Barbieri * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * * Acknowledgements: * * This work was partially supported by the European project LarKC (FP7-215535) ******************************************************************************/ /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package eu.larkc.csparql.core.old_parser; import java.util.List; /** * The class allow to obtain a Sparql executable query from a Tree representing a CSparql * v1.0 query. * * @author Marco */ public class SparqlProducer1_0 extends DefaultSparqlProducer { /** * METHOD NOT IMPLEMENTE YET!!! Method that parse csparqlQuery and from the resulting tree * call produceSparql(). * * @param csparqlQuery * @return */ public String produceSparql(final String csparqlQuery) { // ******** TO BE IMPLEMENTED final String s = new String("Method not implemented yet!"); return s; } /** * Create a string that represent an executable Sparql query from <code>t</code> which * represent a CSparql query. The param t is not modified by the method. * * @param t * @return null if the query is not CSparql */ public String produceSparql(final TreeBox t) { if (t.isCSparql()) { // Create a copy of the tree final TreeBox tbx = TreeBox.dupFullTreeDecorated(t); List<TreeBox> searchedNodes; TreeBox nodeToRemove; // Delete registration node searchedNodes = tbx.getNodesByText("registration"); nodeToRemove = searchedNodes.get(0); searchedNodes.get(0).getParent().deleteChild( nodeToRemove.getLabel().getChildIndex()); // Cut stream|query and range searchedNodes = tbx.getNodesByText("datasetClauseStream"); for (TreeBox tb : searchedNodes) { TreeBox father = tb.getParent(); if (father != null) { int n = 0; while (n < father.getChildCount()) { if (father.getChild(n).getText().equals("datasetClauseStream")) { father.deleteChild(n); // Index refresh on delete so don't increment n // System.out.println("FROM STREAM deleted"); } else { n++; } } } // TreeBox father = null; // if (!searchedNodes.isEmpty()) { // // father = searchedNodes.get(0).getParent(); //// StringBuffer buf = new StringBuffer(); //// father.printLeaves(buf); //// System.out.println(buf); // } // if (father != null) { // int n = 0; // while (n < father.getChildCount()) { // if (father.getChild(n).getText().equals("datasetClauseStream")) { // father.deleteChild(n); // Index refresh on delete so don't increment n // //// System.out.println("FROM STREAM deleted"); // } else { // n++; // } // } } final List<TreeBox> leaves = tbx.getLeaves(); // Leggo lista e creo la stringa aggiungendo i caratteri di convenzione per // var/blankNodes/iriRef final StringBuffer sb = new StringBuffer(); for (final TreeBox tempNode : leaves) { sb.append(this.getTextWithSymbols(tempNode)); } // System.out.println("****"+sb+"****"); // restituisco stringa return sb.toString(); } else { System.out.println("****"+t.toInputString()+"****"); return t.toInputString(); } } }
[ "balduini.marco@gmail.com" ]
balduini.marco@gmail.com
e7701c779258584e42781691f0a41157922240ad
9f5675f9f2a82b19e4f26818c5673df428d88b4e
/model/src/androidTest/java/com/nimura/model/ApplicationTest.java
17cc7caefd4975d89b9e523b582d76533a3864f6
[ "Apache-2.0" ]
permissive
vvkirillov/com.nr.android.examples
9e66f3a2464b197ca3c95ab76faaaef336bb3552
612378ac705937061975115dd765cfda2b665998
refs/heads/master
2021-01-18T01:25:37.709040
2016-04-09T20:05:26
2016-04-09T20:05:26
42,466,387
0
0
null
null
null
null
UTF-8
Java
false
false
347
java
package com.nimura.model; import android.app.Application; import android.test.ApplicationTestCase; /** * <a href="http://d.android.com/tools/testing/testing_android.html">Testing Fundamentals</a> */ public class ApplicationTest extends ApplicationTestCase<Application> { public ApplicationTest() { super(Application.class); } }
[ "naoseru@gmail.com" ]
naoseru@gmail.com
4cc4c6ff3ea301ce1ef23d6d78ad043bd3efb0af
57e5df525b4eb1a8f16f637be13492eb6d069faf
/src/test/java/jabara/it_inoculation_questions/entity/AnswerValueTest.java
96f19def46d6a815a67dcda7caee5263f26d5092
[]
no_license
jabaraster/ItInoculationQuestions
c900c02b0a7190472d457f3015bf2940334bca2a
ea133ea5123a11b3bf2fe73b6f246ee13a9fd41e
refs/heads/master
2016-09-05T11:58:05.336822
2013-05-13T23:29:27
2013-05-13T23:29:27
null
0
0
null
null
null
null
UTF-8
Java
false
false
940
java
/** * */ package jabara.it_inoculation_questions.entity; import static org.hamcrest.CoreMatchers.is; import static org.junit.Assert.assertThat; import org.junit.Before; import org.junit.Test; import org.junit.experimental.runners.Enclosed; import org.junit.runner.RunWith; /** * @author jabaraster */ @RunWith(Enclosed.class) public class AnswerValueTest { /** * @author jabaraster */ public static class OptionTextIsEmpty { private AnswerValue sut; /** * */ @SuppressWarnings("boxing") @Test public void _setOptionText_int_String() { this.sut.setOptionText(2, "option"); //$NON-NLS-1$ final int actual = this.sut.getOptionTextCount(); assertThat(actual, is(3)); } /** * */ @Before public void setUp() { this.sut = new AnswerValue(); } } }
[ "jabaraster@gmail.com" ]
jabaraster@gmail.com
4b17774fc54967beb2bc81f63641f4ff5c4339b9
fe2a92fb961cd9a185f5e675cbbec7d9ee1b5930
/frameworks/opt/telephony/src/java/com/android/internal/telephony/cat/ResponseData.java
9c9cc4023b6846137c52327a3a47d17b3ed6ce2f
[]
no_license
redstorm82/Framwork
e5bfe51a490d1a29d94bcb7d6dfce2869f70b34d
b48c6ac58cfd4355512df4dbd48b56f2d9342091
refs/heads/master
2021-05-30T10:01:51.835572
2015-08-04T06:42:49
2015-08-04T06:42:49
null
0
0
null
null
null
null
UTF-8
Java
false
false
26,952
java
/* * Copyright (C) 2006-2007 Google Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); you may not * use this file except in compliance with the License. You may obtain a copy of * the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the * License for the specific language governing permissions and limitations under * the License. */ package com.android.internal.telephony.cat; import com.android.internal.telephony.EncodeException; import com.android.internal.telephony.GsmAlphabet; import java.util.Calendar; import java.util.TimeZone; import java.util.ArrayList; import java.util.Iterator; import android.os.SystemProperties; import android.text.TextUtils; import com.android.internal.telephony.cat.AppInterface.CommandType; import java.io.ByteArrayOutputStream; import java.io.UnsupportedEncodingException; import com.android.internal.telephony.cat.bip.BipUtils; import com.android.internal.telephony.cat.bip.ChannelStatus; import com.android.internal.telephony.cat.bip.BearerDesc; import com.android.internal.telephony.cat.bip.DefaultBearerDesc; import com.android.internal.telephony.cat.bip.EUTranBearerDesc; import com.android.internal.telephony.cat.bip.GPRSBearerDesc; abstract class ResponseData { /** * Format the data appropriate for TERMINAL RESPONSE and write it into * the ByteArrayOutputStream object. */ public abstract void format(ByteArrayOutputStream buf); public static void writeLength(ByteArrayOutputStream buf, int length) { // As per ETSI 102.220 Sec7.1.2, if the total length is greater // than 0x7F, it should be coded in two bytes and the first byte // should be 0x81. if (length > 0x7F) { buf.write(0x81); } buf.write(length); } } class SelectItemResponseData extends ResponseData { // members private int mId; public SelectItemResponseData(int id) { super(); mId = id; } @Override public void format(ByteArrayOutputStream buf) { // Item identifier object int tag = 0x80 | ComprehensionTlvTag.ITEM_ID.value(); buf.write(tag); // tag buf.write(1); // length buf.write(mId); // identifier of item chosen } } class GetInkeyInputResponseData extends ResponseData { // members private boolean mIsUcs2; private boolean mIsPacked; private boolean mIsYesNo; private boolean mYesNoResponse; public String mInData; // GetInKey Yes/No response characters constants. protected static final byte GET_INKEY_YES = 0x01; protected static final byte GET_INKEY_NO = 0x00; public GetInkeyInputResponseData(String inData, boolean ucs2, boolean packed) { super(); mIsUcs2 = ucs2; mIsPacked = packed; mInData = inData; mIsYesNo = false; } public GetInkeyInputResponseData(boolean yesNoResponse) { super(); mIsUcs2 = false; mIsPacked = false; mInData = ""; mIsYesNo = true; mYesNoResponse = yesNoResponse; } @Override public void format(ByteArrayOutputStream buf) { if (buf == null) { return; } // Text string object int tag = 0x80 | ComprehensionTlvTag.TEXT_STRING.value(); buf.write(tag); // tag byte[] data; if (mIsYesNo) { data = new byte[1]; data[0] = mYesNoResponse ? GET_INKEY_YES : GET_INKEY_NO; } else if (mInData != null && mInData.length() > 0) { try { // ETSI TS 102 223 8.15, should use the same format as in SMS messages // on the network. if (mIsUcs2) { // data = mInData.getBytes("UTF-16"); // ucs2 is by definition big endian. data = mInData.getBytes("UTF-16BE"); } else if (mIsPacked) { // int size = mInData.length(); // byte[] tempData = GsmAlphabet // .stringToGsm7BitPacked(mInData); byte[] tempData = GsmAlphabet .stringToGsm7BitPacked(mInData, 0, 0); final int size = tempData.length - 1; data = new byte[size]; // Since stringToGsm7BitPacked() set byte 0 in the // returned byte array to the count of septets used... // copy to a new array without byte 0. System.arraycopy(tempData, 1, data, 0, size); } else { data = GsmAlphabet.stringToGsm8BitPacked(mInData); } } catch (UnsupportedEncodingException e) { data = new byte[0]; } catch (EncodeException e) { data = new byte[0]; } } else { data = new byte[0]; } // length - one more for data coding scheme. writeLength(buf, data.length + 1); // data coding scheme if (mIsUcs2) { buf.write(0x08); // UCS2 } else if (mIsPacked) { buf.write(0x00); // 7 bit packed } else { buf.write(0x04); // 8 bit unpacked } for (byte b : data) { buf.write(b); } } } // For "PROVIDE LOCAL INFORMATION" command. // See TS 31.111 section 6.4.15/ETSI TS 102 223 // TS 31.124 section 27.22.4.15 for test spec class LanguageResponseData extends ResponseData { private String mLang; public LanguageResponseData(String lang) { super(); mLang = lang; } @Override public void format(ByteArrayOutputStream buf) { if (buf == null) { return; } // Text string object int tag = 0x80 | ComprehensionTlvTag.LANGUAGE.value(); buf.write(tag); // tag byte[] data; if (mLang != null && mLang.length() > 0) { data = GsmAlphabet.stringToGsm8BitPacked(mLang); } else { data = new byte[0]; } buf.write(data.length); for (byte b : data) { buf.write(b); } } } // For "PROVIDE LOCAL INFORMATION" command. // See TS 31.111 section 6.4.15/ETSI TS 102 223 // TS 31.124 section 27.22.4.15 for test spec class DTTZResponseData extends ResponseData { private Calendar mCalendar; public DTTZResponseData(Calendar cal) { super(); mCalendar = cal; } @Override public void format(ByteArrayOutputStream buf) { if (buf == null) { return; } // DTTZ object int tag = 0x80 | CommandType.PROVIDE_LOCAL_INFORMATION.value(); buf.write(tag); // tag byte[] data = new byte[8]; data[0] = 0x07; // Write length of DTTZ data if (mCalendar == null) { mCalendar = Calendar.getInstance(); } // Fill year byte data[1] = byteToBCD(mCalendar.get(java.util.Calendar.YEAR) % 100); // Fill month byte data[2] = byteToBCD(mCalendar.get(java.util.Calendar.MONTH) + 1); // Fill day byte data[3] = byteToBCD(mCalendar.get(java.util.Calendar.DATE)); // Fill hour byte data[4] = byteToBCD(mCalendar.get(java.util.Calendar.HOUR_OF_DAY)); // Fill minute byte data[5] = byteToBCD(mCalendar.get(java.util.Calendar.MINUTE)); // Fill second byte data[6] = byteToBCD(mCalendar.get(java.util.Calendar.SECOND)); String tz = SystemProperties.get("persist.sys.timezone", ""); if (TextUtils.isEmpty(tz)) { data[7] = (byte) 0xFF; // set FF in terminal response } else { TimeZone zone = TimeZone.getTimeZone(tz); int zoneOffset = zone.getRawOffset() + zone.getDSTSavings(); data[7] = getTZOffSetByte(zoneOffset); } for (byte b : data) { buf.write(b); } } private byte byteToBCD(int value) { if (value < 0 && value > 99) { CatLog.d(this, "Err: byteToBCD conversion Value is " + value + " Value has to be between 0 and 99"); return 0; } return (byte) ((value / 10) | ((value % 10) << 4)); } private byte getTZOffSetByte(long offSetVal) { boolean isNegative = (offSetVal < 0); /* * The 'offSetVal' is in milliseconds. Convert it to hours and compute * offset While sending T.R to UICC, offset is expressed is 'quarters of * hours' */ long tzOffset = offSetVal / (15 * 60 * 1000); tzOffset = (isNegative ? -1 : 1) * tzOffset; byte bcdVal = byteToBCD((int) tzOffset); // For negative offsets, put '1' in the msb return isNegative ? (bcdVal |= 0x08) : bcdVal; } } // Add by Huibin Mao Mtk80229 // ICS Migration start class ProvideLocalInformationResponseData extends ResponseData { // members private int year; private int month; private int day; private int hour; private int minute; private int second; private int timezone; private byte[] language; private boolean mIsDate; private boolean mIsLanguage; public ProvideLocalInformationResponseData(int year, int month, int day, int hour, int minute, int second, int timezone) { super(); this.year = year; this.month = month; this.day = day; this.hour = hour; this.minute = minute; this.second = second; this.timezone = timezone; this.mIsDate = true; this.mIsLanguage = false; } public ProvideLocalInformationResponseData(byte[] language) { super(); this.language = language; this.mIsDate = false; this.mIsLanguage = true; } @Override public void format(ByteArrayOutputStream buf) { if (mIsDate == true) { int tag = 0x80 | ComprehensionTlvTag.DATE_TIME_AND_TIMEZONE.value(); buf.write(tag); // tag buf.write(7); // length buf.write(year); buf.write(month); buf.write(day); buf.write(hour); buf.write(minute); buf.write(second); buf.write(timezone); } else if (mIsLanguage == true) { int tag = 0x80 | ComprehensionTlvTag.LANGUAGE.value(); buf.write(tag); // tag buf.write(2); // length for (byte b : language) { buf.write(b); } } } } class OpenChannelResponseDataEx extends OpenChannelResponseData { int mProtocolType = -1; OpenChannelResponseDataEx(ChannelStatus channelStatus, BearerDesc bearerDesc, int bufferSize, int protocolType) { super(channelStatus, bearerDesc, bufferSize); CatLog.d("[BIP]", "OpenChannelResponseDataEx-constructor: protocolType " + protocolType); mProtocolType = protocolType; } @Override public void format(ByteArrayOutputStream buf) { if (buf == null) { CatLog.e("[BIP]", "OpenChannelResponseDataEx-format: buf is null"); return; } if (BipUtils.TRANSPORT_PROTOCOL_TCP_REMOTE == mProtocolType || BipUtils.TRANSPORT_PROTOCOL_UDP_REMOTE == mProtocolType) { if (null == mBearerDesc) { CatLog.e("[BIP]", "OpenChannelResponseDataEx-format: bearer null"); return; } else if ((mBearerDesc.bearerType != BipUtils.BEARER_TYPE_GPRS) && (mBearerDesc.bearerType != BipUtils.BEARER_TYPE_DEFAULT) && (mBearerDesc.bearerType != BipUtils.BEARER_TYPE_EUTRAN)) { CatLog.e("[BIP]", "OpenChannelResponseDataEx-format: bearer type is not gprs"); } } int tag; int length = 0; if (mChannelStatus != null) { CatLog.d("[BIP]", "OpenChannelResponseDataEx-format: Write channel status into TR"); tag = ComprehensionTlvTag.CHANNEL_STATUS.value(); buf.write(tag); length = 0x02; buf.write(length); buf.write(mChannelStatus.mChannelId | mChannelStatus.mChannelStatus); //For TCP status buf.write(mChannelStatus.mChannelStatusInfo); CatLog.d("[BIP]", "OpenChannel Channel status Rsp:tag[" + tag + "],len[" + length + "],cId[" + mChannelStatus.mChannelId + "],status[" + mChannelStatus.mChannelStatus + "]"); } else { CatLog.d("[BIP]", "No Channel status in TR."); } if (mBearerDesc != null) { /*6.8, only required in response to OPEN CHANNEL proactive commands, where Bearer description is mandatory in the command.*/ if (BipUtils.TRANSPORT_PROTOCOL_TCP_REMOTE == mProtocolType || BipUtils.TRANSPORT_PROTOCOL_UDP_REMOTE == mProtocolType) { CatLog.d("[BIP]", "Write bearer description into TR. bearerType: " + mBearerDesc.bearerType); tag = ComprehensionTlvTag.BEARER_DESCRIPTION.value(); buf.write(tag); if (BipUtils.BEARER_TYPE_GPRS == mBearerDesc.bearerType) { if (mBearerDesc instanceof GPRSBearerDesc) { GPRSBearerDesc gprsBD = (GPRSBearerDesc) mBearerDesc; length = 0x07; buf.write(length); buf.write(gprsBD.bearerType); buf.write(gprsBD.precedence); buf.write(gprsBD.delay); buf.write(gprsBD.reliability); buf.write(gprsBD.peak); buf.write(gprsBD.mean); buf.write(gprsBD.pdpType); CatLog.d("[BIP]", "OpenChannelResponseDataEx-format: tag: " + tag + ",length: " + length + ",bearerType: " + gprsBD.bearerType + ",precedence: " + gprsBD.precedence + ",delay: " + gprsBD.delay + ",reliability: " + gprsBD.reliability + ",peak: " + gprsBD.peak + ",mean: " + gprsBD.mean + ",pdp type: " + gprsBD.pdpType); } else { CatLog.d("[BIP]", "Not expected GPRSBearerDesc instance"); } } else if (BipUtils.BEARER_TYPE_EUTRAN == mBearerDesc.bearerType) { int[] bufferArr = new int[10]; int index = 0; if (mBearerDesc instanceof EUTranBearerDesc) { EUTranBearerDesc euTranBD = (EUTranBearerDesc) mBearerDesc; if (euTranBD.QCI != 0) bufferArr[index] = euTranBD.QCI; index++; if (euTranBD.maxBitRateU != 0) { bufferArr[index] = euTranBD.maxBitRateU; index++; } if (euTranBD.maxBitRateD != 0) { bufferArr[index] = euTranBD.maxBitRateD; index++; } if (euTranBD.guarBitRateU != 0) { bufferArr[index] = euTranBD.guarBitRateU; index++; } if (euTranBD.guarBitRateD != 0) { bufferArr[index] = euTranBD.guarBitRateD; index++; } if (euTranBD.maxBitRateUEx != 0) { bufferArr[index] = euTranBD.maxBitRateUEx; index++; } if (euTranBD.maxBitRateDEx != 0) { bufferArr[index] = euTranBD.maxBitRateDEx; index++; } if (euTranBD.guarBitRateUEx != 0) { bufferArr[index] = euTranBD.guarBitRateUEx; index++; } if (euTranBD.guarBitRateDEx != 0) { bufferArr[index] = euTranBD.guarBitRateDEx; index++; } if (euTranBD.pdnType != 0) { bufferArr[index] = euTranBD.pdnType; index++; } CatLog.d("[BIP]", "EUTranBearerDesc length: " + index); if (0 < index) { buf.write(index + 1); } else { buf.write(1); } buf.write(euTranBD.bearerType); for (int i = 0; i < index; i++) { buf.write(bufferArr[i]); CatLog.d("[BIP]", "EUTranBearerDesc buf: " + bufferArr[i]); } } else { CatLog.d("[BIP]", "Not expected EUTranBearerDesc instance"); } } else if (BipUtils.BEARER_TYPE_DEFAULT == mBearerDesc.bearerType) { buf.write(1); buf.write(((DefaultBearerDesc) mBearerDesc).bearerType); } } } else { CatLog.d("[BIP]", "No bearer description in TR."); } if (mBufferSize >= 0) { CatLog.d("[BIP]", "Write buffer size into TR.[" + mBufferSize + "]"); tag = ComprehensionTlvTag.BUFFER_SIZE.value(); buf.write(tag); length = 0x02; buf.write(length); buf.write(mBufferSize >> 8); buf.write(mBufferSize & 0xff); CatLog.d("[BIP]", "OpenChannelResponseDataEx-format: tag: " + tag + ",length: " + length + ",buffer size(hi-byte): " + (mBufferSize >> 8) + ",buffer size(low-byte): " + (mBufferSize & 0xff)); } else { CatLog.d("[BIP]", "No buffer size in TR.[" + mBufferSize + "]"); } } } class OpenChannelResponseData extends ResponseData { ChannelStatus mChannelStatus = null; BearerDesc mBearerDesc = null; int mBufferSize = 0; OpenChannelResponseData(ChannelStatus channelStatus, BearerDesc bearerDesc, int bufferSize) { super(); if (channelStatus != null) { CatLog.d("[BIP]", "OpenChannelResponseData-constructor: channelStatus cid/status : " + channelStatus.mChannelId + "/" + channelStatus.mChannelStatus); } else { CatLog.d("[BIP]", "OpenChannelResponseData-constructor: channelStatus is null"); } if (bearerDesc != null) { CatLog.d("[BIP]", "OpenChannelResponseData-constructor: bearerDesc bearerType" + bearerDesc.bearerType); } else { CatLog.d("[BIP]", "OpenChannelResponseData-constructor: bearerDesc is null"); } if (bufferSize > 0) { CatLog.d("[BIP]", "OpenChannelResponseData-constructor: buffer size is " + bufferSize); } else { CatLog.d("[BIP]", "OpenChannelResponseData-constructor: bearerDesc is invalid " + bufferSize); } mChannelStatus = channelStatus; mBearerDesc = bearerDesc; mBufferSize = bufferSize; } @Override public void format(ByteArrayOutputStream buf) { if (buf == null) { CatLog.d("[BIP]", "OpenChannelResponseData-format: buf is null"); return; } if (((GPRSBearerDesc) mBearerDesc).bearerType != BipUtils.BEARER_TYPE_GPRS) { CatLog.d("[BIP]", "OpenChannelResponseData-format: bearer type is not gprs"); return; } int tag; if (/* mChannelStatus != null && */mBearerDesc != null && mBufferSize > 0) { if (mChannelStatus != null) { CatLog.d("[BIP]", "OpenChannelResponseData-format: Write channel status into TR"); tag = ComprehensionTlvTag.CHANNEL_STATUS.value(); CatLog.d("[BIP]", "OpenChannelResponseData-format: tag: " + tag); buf.write(tag); CatLog.d("[BIP]", "OpenChannelResponseData-format: length: " + 0x02); buf.write(0x02); CatLog.d("[BIP]", "OpenChannelResponseData-format: channel id & isActivated: " + (mChannelStatus.mChannelId | (mChannelStatus.isActivated ? 0x80 : 0x00))); buf.write(mChannelStatus.mChannelId | (mChannelStatus.isActivated ? 0x80 : 0x00)); CatLog.d("[BIP]", "OpenChannelResponseData-format: channel status: " + mChannelStatus.mChannelStatus); buf.write(mChannelStatus.mChannelStatus); } CatLog.d("[BIP]", "Write bearer description into TR"); tag = ComprehensionTlvTag.BEARER_DESCRIPTION.value(); CatLog.d("[BIP]", "OpenChannelResponseData-format: tag: " + tag); buf.write(tag); CatLog.d("[BIP]", "OpenChannelResponseData-format: length: " + 0x07); buf.write(0x07); CatLog.d("[BIP]", "OpenChannelResponseData-format: bearer type: " + ((GPRSBearerDesc) mBearerDesc).bearerType); buf.write(((GPRSBearerDesc) mBearerDesc).bearerType); CatLog.d("[BIP]", "OpenChannelResponseData-format: precedence: " + ((GPRSBearerDesc) mBearerDesc).precedence); buf.write(((GPRSBearerDesc) mBearerDesc).precedence); CatLog.d("[BIP]", "OpenChannelResponseData-format: delay: " + ((GPRSBearerDesc) mBearerDesc).delay); buf.write(((GPRSBearerDesc) mBearerDesc).delay); CatLog.d("[BIP]", "OpenChannelResponseData-format: reliability: " + ((GPRSBearerDesc) mBearerDesc).reliability); buf.write(((GPRSBearerDesc) mBearerDesc).reliability); CatLog.d("[BIP]", "OpenChannelResponseData-format: peak: " + ((GPRSBearerDesc) mBearerDesc).peak); buf.write(((GPRSBearerDesc) mBearerDesc).peak); CatLog.d("[BIP]", "OpenChannelResponseData-format: mean: " + ((GPRSBearerDesc) mBearerDesc).mean); buf.write(((GPRSBearerDesc) mBearerDesc).mean); CatLog.d("[BIP]", "OpenChannelResponseData-format: pdp type: " + ((GPRSBearerDesc) mBearerDesc).pdpType); buf.write(((GPRSBearerDesc) mBearerDesc).pdpType); CatLog.d("[BIP]", "Write buffer size into TR"); tag = ComprehensionTlvTag.BUFFER_SIZE.value(); CatLog.d("[BIP]", "OpenChannelResponseData-format: tag: " + tag); buf.write(tag); CatLog.d("[BIP]", "OpenChannelResponseData-format: length: " + 0x02); buf.write(0x02); CatLog.d("[BIP]", "OpenChannelResponseData-format: length(hi-byte): " + (mBufferSize >> 8)); buf.write(mBufferSize >> 8); CatLog.d("[BIP]", "OpenChannelResponseData-format: length(low-byte): " + (mBufferSize & 0xff)); buf.write(mBufferSize & 0xff); } else { CatLog.d("[BIP]", "Miss ChannelStatus, BearerDesc or BufferSize"); } } } class SendDataResponseData extends ResponseData { int mTxBufferSize = 0; SendDataResponseData(int size) { super(); mTxBufferSize = size; } @Override public void format(ByteArrayOutputStream buf) { if (buf == null) { return; } int tag; tag = 0x80 | ComprehensionTlvTag.CHANNEL_DATA_LENGTH.value(); buf.write(tag); buf.write(1); if (mTxBufferSize >= 0xFF) { buf.write(0xFF); } else { buf.write(mTxBufferSize); } } } class ReceiveDataResponseData extends ResponseData { byte[] mData = null; int mRemainingCount = 0; ReceiveDataResponseData(byte[] data, int remaining) { super(); mData = data; mRemainingCount = remaining; } @Override public void format(ByteArrayOutputStream buf) { if (buf == null) { return; } int tag; tag = 0x80 | ComprehensionTlvTag.CHANNEL_DATA.value(); buf.write(tag); if (mData != null) { if (mData.length >= 0x80) { buf.write(0x81); } buf.write(mData.length); buf.write(mData, 0, mData.length); } else { buf.write(0); } tag = 0x80 | ComprehensionTlvTag.CHANNEL_DATA_LENGTH.value(); buf.write(tag); buf.write(0x01); CatLog.d("[BIP]", "ReceiveDataResponseData: length: " + mRemainingCount); if (mRemainingCount >= 0xFF) { buf.write(0xFF); } else { buf.write(mRemainingCount); } } } class GetMultipleChannelStatusResponseData extends ResponseData { ArrayList mArrList = null; GetMultipleChannelStatusResponseData(ArrayList arrList) { mArrList = arrList; } @Override public void format(ByteArrayOutputStream buf) { if (buf == null) { return; } int tag = 0x80 | ComprehensionTlvTag.CHANNEL_STATUS.value(); CatLog.d("[BIP]", "ChannelStatusResp: size: " + mArrList.size()); if (0 < mArrList.size()) { Iterator iterator = mArrList.iterator(); ChannelStatus chStatus = null; while (iterator.hasNext()) { buf.write(tag); buf.write(0x02); chStatus = (ChannelStatus) iterator.next(); buf.write((chStatus.mChannelId & 0x07) | (chStatus.mChannelStatus)); buf.write(chStatus.mChannelStatusInfo); CatLog.d("[BIP]", "ChannelStatusResp: cid:" + chStatus.mChannelId + ",status:" + chStatus.mChannelStatus + ",info:" + chStatus.mChannelStatusInfo); } } else { //No channel available, link not established or PDP context not activated. CatLog.d("[BIP]", "ChannelStatusResp: no channel status."); buf.write(tag); buf.write(0x02); buf.write(0x00); buf.write(0x00); } } } class GetChannelStatusResponseData extends ResponseData { int mChannelId = 0; int mChannelStatus = 0; int mChannelStatusInfo = 0; GetChannelStatusResponseData(int cid, int status, int statusInfo) { mChannelId = cid; mChannelStatus = status; mChannelStatusInfo = statusInfo; } @Override public void format(ByteArrayOutputStream buf) { if (buf == null) { return; } int tag = 0x80 | ComprehensionTlvTag.CHANNEL_STATUS.value(); buf.write(tag); buf.write(0x02); buf.write((mChannelId & 0x07) | mChannelStatus); buf.write(mChannelStatusInfo); } } // ICS Migration end
[ "deng.xie@sprocomm.com" ]
deng.xie@sprocomm.com
644ac7deb0a1d4b55d714588f329b164099ddda7
68a395133af5b4f551e8b29bfcb5448584ca5f3c
/MyApplication2/app/src/main/java/com/example/myapplication2/linia24/Linia24TurRetur.java
a668509a812799b96694b51a6d209fe86b7665c0
[]
no_license
alexmarin98/AndroidApp
7a6c94217940719c64130feb99ff1aee486563ce
af754d0981c17d06795fc7ed8d8b7c9a7d83b014
refs/heads/master
2020-12-02T09:51:50.906646
2020-01-11T17:53:27
2020-01-11T17:53:27
230,969,388
0
0
null
2020-01-11T14:02:12
2019-12-30T19:33:20
Java
UTF-8
Java
false
false
1,145
java
package com.example.myapplication2.linia24; import androidx.appcompat.app.AppCompatActivity; import android.content.Intent; import android.os.Bundle; import android.view.View; import android.widget.Button; import com.example.myapplication2.R; public class Linia24TurRetur extends AppCompatActivity { Button Tur; Button Retur; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_linia24_tur_retur); Tur = (Button) findViewById(R.id.tur); Retur = (Button) findViewById(R.id.retur); Tur.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { Intent i = new Intent(Linia24TurRetur.this,Linia24Tur.class); startActivity(i); } }); Retur.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { Intent i = new Intent(Linia24TurRetur.this,Linia24Retur.class); startActivity(i); } }); } }
[ "larissa9850@gmail.com" ]
larissa9850@gmail.com
dbde8a92b6d0a207023291dae890041195d409b5
b4d761c40c6f2f20505496692ca827ae1677ea09
/Blatt11_Duplikate/Datei.java
37f2022b8125eee896ff4bb35fa6dc50a867412d
[]
no_license
svenf1105/SE1
fefb87cb8eaaa624d19413be59d4e8064769b819
581079af4d93062c1db53c2dc9078b1c11ba80dd
refs/heads/master
2021-03-24T10:58:56.387802
2018-02-05T16:19:32
2018-02-05T16:19:32
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,835
java
import java.io.File; /** * Exemplare dieser Klasse repraesentieren Dateien im Dateisystem. * Ihr Zweck liegt darin, das Auffinden von Duplikaten zu erleichtern. * * @author Fredrik Winkler * @version 16. Dezember 2014 */ class Datei { private final File _file; private final long _groesse; private String _fingerabdruck; private final String _name; /** * Initialisiert eine neue Datei und merkt sich deren Groesse. * * @param file das einzulesende File */ public Datei(File file) { _file = file; _groesse = file.length(); _name = file.getName(); } /** * Wann gelten zwei Exemplare dieser Klasse als gleich? */ public boolean equals(Object obj) { if (obj instanceof Datei) { Datei zweite = (Datei) obj; return (_groesse == zweite._groesse) && (fingerabdruck().equals(zweite.fingerabdruck()) && (_name.equals(zweite._name))); } return false; } /** * Wie wird der hashCode berechnet? */ public int hashCode() { return (int) _groesse; } /** * Liefert den Dateinamen und den Fingerabdruck als String zurueck. * * @return String im Format "DATEINAME (FINGERABDRUCK)" */ public String toString() { return _file.toString() + " (" + fingerabdruck() + ")"; } /** * Liefert den Fingerabdruck. Da der Fingerabdruck nur bei Bedarf generiert wird, * kann der erste Aufruf dieser Methode u.U. recht lange dauern. * * @return der Fingerabdruck */ public String fingerabdruck() { if (_fingerabdruck == null) { _fingerabdruck = Fingerabdruck.aus(_file); } return _fingerabdruck; } }
[ "sven.f1105@googlemail.com" ]
sven.f1105@googlemail.com
0bdd7f038b62f3a68daf102045c568bbf189d0e8
1bac83edfa03444bdbfd9152cd81647a230418ee
/src/main/java/com/dili/formation8/controller/ScheduleController.java
333c73d1c58dffdf0555e1a5ab0bd54edf1c2d9f
[]
no_license
asiamaster/formation8
b5f0974045e13b63f20938a779847f87b8c85ad1
ba3ea559b7acc391f60f816b045456a0d1afd4d0
refs/heads/master
2021-01-20T02:46:56.659735
2017-05-16T01:32:17
2017-05-16T01:32:17
89,453,525
0
0
null
null
null
null
UTF-8
Java
false
false
1,611
java
package com.dili.formation8.controller; import com.dili.formation8.component.OrderScanComponent; import com.dili.formation8.dao.ScheduleJobMapper; import com.dili.utils.domain.BaseOutput; import com.dili.utils.quartz.domain.ScheduleJob; import com.dili.utils.quartz.service.JobTaskService; import org.quartz.SchedulerException; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.ResponseBody; import java.util.List; /** * 调度控制器 * Created by asiam on 2017/5/15 0015. */ @Controller @RequestMapping("/schedule") public class ScheduleController { private static final Logger log = LoggerFactory.getLogger(ScheduleController.class); @Autowired JobTaskService jobTaskService; @Autowired ScheduleJobMapper scheduleJobMapper; @RequestMapping("/refresh.aspx") public @ResponseBody BaseOutput refresh(){ List<ScheduleJob> scheduleJobs = scheduleJobMapper.selectAll(); for(ScheduleJob scheduleJob : scheduleJobs){ try { jobTaskService.updateJob(scheduleJob); } catch (SchedulerException e) { e.printStackTrace(); log.error(e.getMessage()); return BaseOutput.failure("调度失败, jobName:"+scheduleJob.getJobName()+", jobId:"+scheduleJob.getId()); } } return BaseOutput.success("调度器刷新完成"); } }
[ "asdf1qaz" ]
asdf1qaz
b919da56bdefcbbe492ecf5d00c4400361a2036c
b19eca32a76ded3c82aa2f2d3c8eff4931eb743b
/app/src/test/java/com/splashscreen/rpl_04/latihan1/ExampleUnitTest.java
f9c901ef360c1fd24c297752be05ffae690ca5a6
[]
no_license
widhyy25/Latihan1
c8e7aa626795639ab0617e52c58188f3892d2c8f
06a67df7cddbf5c5f0de51f6aaa1da6df9e07467
refs/heads/master
2022-12-02T11:06:44.576456
2020-08-19T06:15:36
2020-08-19T06:15:36
288,649,809
0
0
null
null
null
null
UTF-8
Java
false
false
393
java
package com.splashscreen.rpl_04.latihan1; import org.junit.Test; import static org.junit.Assert.*; /** * Example local unit test, which will execute on the development machine (host). * * @see <a href="http://d.android.com/tools/testing">Testing documentation</a> */ public class ExampleUnitTest { @Test public void addition_isCorrect() { assertEquals(4, 2 + 2); } }
[ "widiikhoerunnisa25@gmail.com" ]
widiikhoerunnisa25@gmail.com
174ec1f562bd8c424843a08e72736b0419933af0
6c35446feb5baaadf1901a083442e14dc423fc0b
/TestMR/src/main/java/com/mr/GetMovementTrackDataReducer.java
128a7b6bc6ad4f17298692eda37a4228fb88622a
[ "Apache-2.0" ]
permissive
chenqixu/TestSelf
8e533d2f653828f9f92564c3918041d733505a30
7488d83ffd20734ab5ca431d13fa3c5946493c11
refs/heads/master
2023-09-01T06:18:59.417999
2023-08-21T06:16:55
2023-08-21T06:16:55
75,791,787
3
1
Apache-2.0
2022-03-02T06:47:48
2016-12-07T02:36:58
Java
UTF-8
Java
false
false
9,420
java
package com.mr; import java.io.IOException; import java.text.ParseException; import java.text.SimpleDateFormat; import java.util.ArrayList; import java.util.Date; import java.util.List; import org.apache.hadoop.conf.Configuration; import org.apache.hadoop.io.NullWritable; import org.apache.hadoop.io.Text; import org.apache.hadoop.mapreduce.Reducer; import org.apache.hadoop.mapreduce.lib.output.MultipleOutputs; import com.mr.comm.GetMovementConstants; import com.mr.comm.MoveRecord; import com.mr.util.TempKey; public class GetMovementTrackDataReducer extends Reducer<TempKey, Text, Text, Text> { // 配置实例 private Configuration conf = null; // 声明 MultipleOutputs 的变量 private MultipleOutputs<Text, NullWritable> multipleOutputs; // 输出文件名前缀 private static String outputName = null; // 数据时间 private static String sumDate = null; // 存放输入value的list private List<String> inputValueList = new ArrayList<String>(); // 存放输入value的转换后的list private List<MoveRecord> recordList = new ArrayList<MoveRecord>(); // 存放单条源数据记录的数组 private String[] sourceDataValueArr = null; // 统一时间格式为MC的时间的格式 private SimpleDateFormat sdf_MC; // 输出时间的格式 private SimpleDateFormat sdf_output; @SuppressWarnings("unchecked") protected void setup(Context context) throws IOException, InterruptedException { multipleOutputs = new MultipleOutputs(context); super.setup(context); // 获取Configuration对象 if (conf == null) conf = context.getConfiguration(); // 输出文件名前缀 outputName = conf.get(GetMovementConstants.OUTPUT_NAME); // 数据时间 sumDate = conf.get(GetMovementConstants.SOURCE_DATA_DATE); // MC的时间的格式 sdf_MC = new SimpleDateFormat(GetMovementConstants.MC_TIME_FORMAT); // 输出时间的格式 sdf_output = new SimpleDateFormat( GetMovementConstants.OUTPUT_TIME_FORMAT); } protected void reduce(TempKey key, Iterable<Text> values, Context context) throws IOException, InterruptedException { // vlr_msisdn_number, 0 // vlr_imei, 1 // vlr_event_type, 2 // vlr_lac, 3 // vlr_cell, 4 // vlr_report_time, 5 // seu_type 6 // dataType 7 try { // 用于存放前一条记录的信息 String old_lac = null; String old_cell = null; long old_time = 0; // 存放当前记录的信息 String new_lac = null; String new_cell = null; long new_time = 0; // 时间转换时用到的临时变量 Date newTimeDate = new Date(); Date oldTimeDate = new Date(); // 输入数据list清空 recordList.clear(); // 将数据放入list中去 for (Text text : values) { inputValueList.add(text.toString()); } for (int i = 0; i < inputValueList.size(); i++) { MoveRecord record = new MoveRecord(); if (i == 0) { // 分隔输入数据到数组 sourceDataValueArr = inputValueList.get(i).split( GetMovementConstants.COMMA_SPLIT_STR, -1); // 设置record record.setMsisdn(sourceDataValueArr[0]); record.setVlr_imei(sourceDataValueArr[1]); record.setVlr_event_type(sourceDataValueArr[2]); new_lac = sourceDataValueArr[3]; record.setVlr_lac(new_lac); // 第一条记录的lac作为下一条记录old_lac的初始值 old_lac = new_lac; new_cell = sourceDataValueArr[4]; record.setVlr_cell(new_cell); // 第一条记录的cell作为下一条记录old_cell的初始值 old_cell = new_cell; // 时间格式转换 newTimeDate = sdf_MC.parse(sourceDataValueArr[5]); record.setVlr_report_time(sdf_output.format(newTimeDate)); // 第一条记录的time作为old_time的初始值 new_time = newTimeDate.getTime(); old_time = new_time; record.setSeu_type(sourceDataValueArr[6]); record.setDataType(sourceDataValueArr[7]); // 取一天最早的时间作第一条记录的old_time Date firstTimeDate = sdf_MC.parse(sumDate + "000000"); record.setOld_time(sdf_output.format(firstTimeDate)); record.setOld_lac(old_lac); record.setOld_cell(old_cell); // 时间间隔大于3小时标志位1,否则0 long firstTime = sdf_MC.parse(sumDate + "000000").getTime(); if (new_time - firstTime <= 10800000) { record.setIs_exception("0"); } else { record.setIs_exception("1"); } // 存入list recordList.add(record); } else { // 分隔输入数据到数组 sourceDataValueArr = inputValueList.get(i).split( GetMovementConstants.COMMA_SPLIT_STR, -1); new_lac = sourceDataValueArr[3]; new_cell = sourceDataValueArr[4]; new_time = sdf_MC.parse(sourceDataValueArr[5]).getTime(); long timeDifference = new_time - old_time; // 时间间隔大于3小时标志位1,否则0 if (new_cell.equals(old_cell) && new_lac.equals(old_lac) && timeDifference <= 10800000) { old_time = new_time; continue; } // 设置record record.setMsisdn(sourceDataValueArr[0]); record.setVlr_imei(sourceDataValueArr[1]); record.setVlr_event_type(sourceDataValueArr[2]); record.setVlr_lac(new_lac); record.setVlr_cell(new_cell); // 时间格式转换 newTimeDate = sdf_MC.parse(sourceDataValueArr[5]); record.setVlr_report_time(sdf_output.format(newTimeDate)); record.setSeu_type(sourceDataValueArr[6]); record.setDataType(sourceDataValueArr[7]); oldTimeDate.setTime(old_time); record.setOld_time(sdf_output.format(oldTimeDate)); record.setOld_lac(old_lac); record.setOld_cell(old_cell); // 根据时间差判断异常标志位取值 if (i < inputValueList.size() - 1) { if (timeDifference <= 10800000) { record.setIs_exception("0"); } else { record.setIs_exception("1"); } } else { // 最后一条记录与当天235959比较 long lasttTime = sdf_MC.parse(sumDate + "235959") .getTime(); if (lasttTime - new_time <= 10800000) { record.setIs_exception("0"); } else { record.setIs_exception("1"); } } // 存入list recordList.add(record); // 更新变量 old_time = new_time; old_lac = new_lac; old_cell = new_cell; } } //清空输入数据的list inputValueList.clear(); //创建MoveRecord对象 MoveRecord record = new MoveRecord(); for (int j = 0; j < recordList.size(); j++) { //创建用于输出的StringBuffer StringBuffer outputSB = new StringBuffer(); //取出记录 record = recordList.get(j); // msisdn, outputSB.append(record.getMsisdn()).append( GetMovementConstants.COMMA_SPLIT_STR); // vlr_imei, outputSB.append(record.getVlr_imei()).append( GetMovementConstants.COMMA_SPLIT_STR); // vlr_event_type, outputSB.append(record.getVlr_event_type()).append( GetMovementConstants.COMMA_SPLIT_STR); // vlr_lac, outputSB.append(record.getVlr_lac()).append( GetMovementConstants.COMMA_SPLIT_STR); // vlr_cell, outputSB.append(record.getVlr_cell()).append( GetMovementConstants.COMMA_SPLIT_STR); // old_lac, outputSB.append(record.getOld_lac()).append( GetMovementConstants.COMMA_SPLIT_STR); // old_cell, outputSB.append(record.getOld_cell()).append( GetMovementConstants.COMMA_SPLIT_STR); // in_time, if(j==0 || record.getIs_exception().equals("1")){ outputSB.append(record.getOld_time()).append( GetMovementConstants.COMMA_SPLIT_STR); }else{ outputSB.append(record.getVlr_report_time()).append( GetMovementConstants.COMMA_SPLIT_STR); } // out_time, if(j < recordList.size()-1){ MoveRecord nextRecord = recordList.get(j+1); if(nextRecord.getIs_exception().equals("1")){ outputSB.append(nextRecord.getOld_time()).append( GetMovementConstants.COMMA_SPLIT_STR); }else{ outputSB.append(nextRecord.getVlr_report_time()).append( GetMovementConstants.COMMA_SPLIT_STR); } }else{ Date lastTimeDate = sdf_MC.parse(sumDate + "235959"); outputSB.append(sdf_output.format(lastTimeDate)).append( GetMovementConstants.COMMA_SPLIT_STR); } // seu_type, outputSB.append(record.getSeu_type()).append( GetMovementConstants.COMMA_SPLIT_STR); // is_exception if(j < recordList.size()-1){ outputSB.append(record.getIs_exception()).append( GetMovementConstants.COMMA_SPLIT_STR); }else{ long lasttTime = sdf_MC.parse(sumDate + "235959") .getTime(); long lastReportTime = sdf_MC.parse(record.getVlr_report_time()) .getTime(); if (lasttTime - lastReportTime<= 10800000) { outputSB.append("0").append( GetMovementConstants.COMMA_SPLIT_STR); } else { outputSB.append("1").append( GetMovementConstants.COMMA_SPLIT_STR); } } // dataType outputSB.append(record.getDataType()); //设置输出 Text outputText = new Text(); outputText.set(outputSB.toString()); multipleOutputs.write(outputName, outputText, NullWritable.get()); } } catch (ParseException e) { e.printStackTrace(); } catch (Exception e) { e.printStackTrace(); } } protected void cleanup(Context context) throws IOException, InterruptedException { multipleOutputs.close(); super.cleanup(context); } }
[ "13509323824@139.com" ]
13509323824@139.com
935936fa95f640ff4a94c3c70a03d0d067733768
136dd4d173926d63c5213891c67c05d4cd7358c8
/network/src/main/java/com/forfuture/zxg/network/HttpInstaller.java
1c9899dc356df8cbc166fc1ac02c7e447763f3c8
[ "Apache-2.0" ]
permissive
zxg110/RxStudy
2860209df641799c1fb95f715fc90b94d819791d
66df52768d503a613c906ca2d1f2cd52aab00edd
refs/heads/master
2020-03-27T22:53:21.425822
2018-11-30T05:45:45
2018-11-30T05:45:45
147,269,496
0
0
null
null
null
null
UTF-8
Java
false
false
870
java
package com.forfuture.zxg.network; import okhttp3.OkHttpClient; import retrofit2.Retrofit; import retrofit2.adapter.rxjava2.RxJava2CallAdapterFactory; import retrofit2.converter.gson.GsonConverterFactory; public class HttpInstaller { private HttpClient client; private ClientFactory clientFactory; private static HttpInstaller instance; private HttpInstaller(){} public static HttpInstaller getInstance() { if(instance == null){ instance = new HttpInstaller(); } return instance; } public IHttpExecutor install(HttpRESTfulClient.Config httpConfig){ if(clientFactory == null){ initFactory(); } client = clientFactory.createClient(httpConfig); return null; } private void initFactory(){ clientFactory = new OkhttpClientFactory(); } }
[ "zxg@zxgdeMacBook-Pro.local" ]
zxg@zxgdeMacBook-Pro.local
0930ed2e5b854250060accd7c96bd637301ac677
28de2926e0df7367cb7b656b98d94c1483c51cf0
/Account/src/Account.java
8d350d6b80d2f4c08c385dc02f99e931c80de41d
[]
no_license
mramirez74/OOPHomework
49404a4e788da7230be44e0aa8b7a3dab98dd868
488eb5e059ee53dde85b46f9eeeb56853ab0cdff
refs/heads/master
2016-09-06T03:14:55.361964
2015-04-24T01:11:14
2015-04-24T01:11:14
32,964,334
0
0
null
null
null
null
UTF-8
Java
false
false
824
java
public class Account { int id; double balance; double annualInterestRate; public Account() { } public Account(int ID, double bal, double aIR) { id = ID; balance = bal; annualInterestRate = aIR; } public int getId() { return id; } public void setId(int id) { this.id = id; } public double getBalance() { return balance; } public void setBalance(double balance) { this.balance = balance; } public double getAnnualInterestRate() { return annualInterestRate; } public void setAnnualInterestRate(double annualInterestRate) { this.annualInterestRate = annualInterestRate; } public double getMonthlyInterestRate(){ return annualInterestRate / 12; } public double withdraw(){ return balance - 2500; } public double deposit(){ return balance - 2500 + 3000; } }
[ "mramirez74@mail.stmarytx.edu" ]
mramirez74@mail.stmarytx.edu
fc434cecc367c04f2f21d553aa4dc615874322cb
9964c437fcf91ac8a22e67122d79c9d91f790d5f
/optaplanner-examples/src/main/java/org/optaplanner/examples/projectjobscheduling/domain/Allocation.java
e0ac0fb03c59397a367562a6b7e08a4953ca8975
[ "Apache-2.0" ]
permissive
domhanak/optaplanner
4178c40da4a2d1b8d80a6f622f4fab481cf73f05
2503d5aad808e9049060f572e0fb18e7aee88793
refs/heads/master
2021-01-15T14:42:13.014824
2014-01-07T17:54:42
2014-01-07T17:54:42
15,376,389
0
0
null
null
null
null
UTF-8
Java
false
false
5,538
java
/* * Copyright 2010 JBoss Inc * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.optaplanner.examples.projectjobscheduling.domain; import java.util.List; import com.thoughtworks.xstream.annotations.XStreamAlias; import org.optaplanner.core.api.domain.entity.PlanningEntity; import org.optaplanner.core.api.domain.valuerange.ValueRange; import org.optaplanner.core.api.domain.valuerange.ValueRangeFactory; import org.optaplanner.core.api.domain.valuerange.ValueRangeProvider; import org.optaplanner.core.api.domain.variable.PlanningVariable; import org.optaplanner.examples.common.domain.AbstractPersistable; import org.optaplanner.examples.projectjobscheduling.domain.solver.DelayStrengthComparator; import org.optaplanner.examples.projectjobscheduling.domain.solver.ExecutionModeStrengthWeightFactory; import org.optaplanner.examples.projectjobscheduling.domain.solver.NotSourceOrSinkAllocationFilter; import org.optaplanner.examples.projectjobscheduling.domain.solver.PredecessorsDoneDateUpdatingVariableListener; @PlanningEntity(movableEntitySelectionFilter = NotSourceOrSinkAllocationFilter.class) @XStreamAlias("PjsAllocation") public class Allocation extends AbstractPersistable { private Job job; private Allocation sourceAllocation; private Allocation sinkAllocation; private List<Allocation> predecessorAllocationList; private List<Allocation> successorAllocationList; // Planning variables: changes during planning, between score calculations. private ExecutionMode executionMode; private Integer delay; // In days // Shadow variables private Integer predecessorsDoneDate; public Job getJob() { return job; } public void setJob(Job job) { this.job = job; } public Allocation getSourceAllocation() { return sourceAllocation; } public void setSourceAllocation(Allocation sourceAllocation) { this.sourceAllocation = sourceAllocation; } public Allocation getSinkAllocation() { return sinkAllocation; } public void setSinkAllocation(Allocation sinkAllocation) { this.sinkAllocation = sinkAllocation; } public List<Allocation> getPredecessorAllocationList() { return predecessorAllocationList; } public void setPredecessorAllocationList(List<Allocation> predecessorAllocationList) { this.predecessorAllocationList = predecessorAllocationList; } public List<Allocation> getSuccessorAllocationList() { return successorAllocationList; } public void setSuccessorAllocationList(List<Allocation> successorAllocationList) { this.successorAllocationList = successorAllocationList; } @PlanningVariable(valueRangeProviderRefs = {"executionModeRange"}, strengthWeightFactoryClass = ExecutionModeStrengthWeightFactory.class, variableListenerClasses = {PredecessorsDoneDateUpdatingVariableListener.class}) public ExecutionMode getExecutionMode() { return executionMode; } public void setExecutionMode(ExecutionMode executionMode) { this.executionMode = executionMode; } @PlanningVariable(valueRangeProviderRefs = {"delayRange"}, strengthComparatorClass = DelayStrengthComparator.class, variableListenerClasses = {PredecessorsDoneDateUpdatingVariableListener.class}) public Integer getDelay() { return delay; } public void setDelay(Integer delay) { this.delay = delay; } public Integer getPredecessorsDoneDate() { return predecessorsDoneDate; } public void setPredecessorsDoneDate(Integer predecessorsDoneDate) { this.predecessorsDoneDate = predecessorsDoneDate; } // ************************************************************************ // Complex methods // ************************************************************************ public Integer getStartDate() { if (predecessorsDoneDate == null) { return null; } return predecessorsDoneDate + (delay == null ? 0 : delay); } public Integer getEndDate() { if (predecessorsDoneDate == null) { return null; } return predecessorsDoneDate + (delay == null ? 0 : delay) + (executionMode == null ? 0 : executionMode.getDuration()); } public Project getProject() { return job.getProject(); } public String getLabel() { return "Job " + job.getId(); } // ************************************************************************ // Ranges // ************************************************************************ @ValueRangeProvider(id = "executionModeRange") public List<ExecutionMode> getExecutionModeRange() { return job.getExecutionModeList(); } @ValueRangeProvider(id = "delayRange") public ValueRange<Integer> getDelayRange() { return ValueRangeFactory.createIntValueRange(0, 500); } }
[ "gds.geoffrey.de.smet@gmail.com" ]
gds.geoffrey.de.smet@gmail.com
3dd15ab191982b0b50bef845fd7f27741cbbc52e
5b94670a42789289338ab05b58461235932c0763
/commonlibrary/src/androidTest/java/com/meiling/common/ExampleInstrumentedTest.java
f16a4852f6c269b834d30fd9f3b4004d08b2ed31
[]
no_license
MeilingHong/ThirdPartMixProject
3d8dfd75f0961fafca8e0a5c7547587aade56a72
44f4327a3930375cc455ec0d6201ab83cf0f3580
refs/heads/master
2020-05-03T01:32:51.121773
2019-12-18T07:15:48
2019-12-18T07:15:48
178,340,131
0
0
null
null
null
null
UTF-8
Java
false
false
742
java
package com.meiling.common; import android.content.Context; import android.support.test.InstrumentationRegistry; import android.support.test.runner.AndroidJUnit4; import org.junit.Test; import org.junit.runner.RunWith; import static org.junit.Assert.*; /** * Instrumented test, which will execute on an Android device. * * @see <a href="http://d.android.com/tools/testing">Testing documentation</a> */ @RunWith(AndroidJUnit4.class) public class ExampleInstrumentedTest { @Test public void useAppContext() throws Exception { // Context of the app under test. Context appContext = InstrumentationRegistry.getTargetContext(); assertEquals("com.meiling.common.test", appContext.getPackageName()); } }
[ "huangzhou@ulord.net" ]
huangzhou@ulord.net
3b963d1a626cf5b245e5325ef9748fce89dcd148
92e3067dd51b9bc6a22d77fdac20a24dd9b08662
/app/src/main/java/com/example/andres/bylopcastthesudoku/SudokuBoard.java
43b76a0711a931e2849bc8f79edbe3b3f2563ee7
[]
no_license
byLopcast/byLopcastTheSudoku
d5b7feb29bcb91d1228a5f808381e69529a29047
4fb980c314eb22a3c81580ac8c9a9cfd37bcfb85
refs/heads/master
2022-04-19T02:06:00.059456
2020-04-11T09:03:12
2020-04-11T09:03:12
255,146,305
0
0
null
null
null
null
UTF-8
Java
false
false
11,912
java
package com.example.andres.bylopcastthesudoku; import android.content.Intent; import android.os.Bundle; import android.view.MenuItem; import android.view.View; import android.widget.EditText; import android.widget.PopupMenu; import android.widget.Toast; import java.io.BufferedReader; import java.io.IOException; import java.io.InputStream; import java.io.InputStreamReader; import androidx.appcompat.app.AppCompatActivity; public class SudokuBoard extends AppCompatActivity implements PopupMenu.OnMenuItemClickListener { private String Difficulty; private int SudokuId; private EditText[][] SPlay_text = new EditText[9][9]; private Board PlayBoard = new Board(); private Board TemplateBoard = new Board(); private Board SolvedBoard = new Board(); @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_sudoku_board); this.Difficulty = getIntent().getStringExtra("Difficulty"); this.SPlay_text[0][0] = (EditText)findViewById(R.id.numberSudokuBoardMainTable11); this.SPlay_text[0][1] = (EditText)findViewById(R.id.numberSudokuBoardMainTable12); this.SPlay_text[0][2] = (EditText)findViewById(R.id.numberSudokuBoardMainTable13); this.SPlay_text[0][3] = (EditText)findViewById(R.id.numberSudokuBoardMainTable14); this.SPlay_text[0][4] = (EditText)findViewById(R.id.numberSudokuBoardMainTable15); this.SPlay_text[0][5] = (EditText)findViewById(R.id.numberSudokuBoardMainTable16); this.SPlay_text[0][6] = (EditText)findViewById(R.id.numberSudokuBoardMainTable17); this.SPlay_text[0][7] = (EditText)findViewById(R.id.numberSudokuBoardMainTable18); this.SPlay_text[0][8] = (EditText)findViewById(R.id.numberSudokuBoardMainTable19); this.SPlay_text[1][0] = (EditText)findViewById(R.id.numberSudokuBoardMainTable21); this.SPlay_text[1][1] = (EditText)findViewById(R.id.numberSudokuBoardMainTable22); this.SPlay_text[1][2] = (EditText)findViewById(R.id.numberSudokuBoardMainTable23); this.SPlay_text[1][3] = (EditText)findViewById(R.id.numberSudokuBoardMainTable24); this.SPlay_text[1][4] = (EditText)findViewById(R.id.numberSudokuBoardMainTable25); this.SPlay_text[1][5] = (EditText)findViewById(R.id.numberSudokuBoardMainTable26); this.SPlay_text[1][6] = (EditText)findViewById(R.id.numberSudokuBoardMainTable27); this.SPlay_text[1][7] = (EditText)findViewById(R.id.numberSudokuBoardMainTable28); this.SPlay_text[1][8] = (EditText)findViewById(R.id.numberSudokuBoardMainTable29); this.SPlay_text[2][0] = (EditText)findViewById(R.id.numberSudokuBoardMainTable31); this.SPlay_text[2][1] = (EditText)findViewById(R.id.numberSudokuBoardMainTable32); this.SPlay_text[2][2] = (EditText)findViewById(R.id.numberSudokuBoardMainTable33); this.SPlay_text[2][3] = (EditText)findViewById(R.id.numberSudokuBoardMainTable34); this.SPlay_text[2][4] = (EditText)findViewById(R.id.numberSudokuBoardMainTable35); this.SPlay_text[2][5] = (EditText)findViewById(R.id.numberSudokuBoardMainTable36); this.SPlay_text[2][6] = (EditText)findViewById(R.id.numberSudokuBoardMainTable37); this.SPlay_text[2][7] = (EditText)findViewById(R.id.numberSudokuBoardMainTable38); this.SPlay_text[2][8] = (EditText)findViewById(R.id.numberSudokuBoardMainTable39); this.SPlay_text[3][0] = (EditText)findViewById(R.id.numberSudokuBoardMainTable41); this.SPlay_text[3][1] = (EditText)findViewById(R.id.numberSudokuBoardMainTable42); this.SPlay_text[3][2] = (EditText)findViewById(R.id.numberSudokuBoardMainTable43); this.SPlay_text[3][3] = (EditText)findViewById(R.id.numberSudokuBoardMainTable44); this.SPlay_text[3][4] = (EditText)findViewById(R.id.numberSudokuBoardMainTable45); this.SPlay_text[3][5] = (EditText)findViewById(R.id.numberSudokuBoardMainTable46); this.SPlay_text[3][6] = (EditText)findViewById(R.id.numberSudokuBoardMainTable47); this.SPlay_text[3][7] = (EditText)findViewById(R.id.numberSudokuBoardMainTable48); this.SPlay_text[3][8] = (EditText)findViewById(R.id.numberSudokuBoardMainTable49); this.SPlay_text[4][0] = (EditText)findViewById(R.id.numberSudokuBoardMainTable51); this.SPlay_text[4][1] = (EditText)findViewById(R.id.numberSudokuBoardMainTable52); this.SPlay_text[4][2] = (EditText)findViewById(R.id.numberSudokuBoardMainTable53); this.SPlay_text[4][3] = (EditText)findViewById(R.id.numberSudokuBoardMainTable54); this.SPlay_text[4][4] = (EditText)findViewById(R.id.numberSudokuBoardMainTable55); this.SPlay_text[4][5] = (EditText)findViewById(R.id.numberSudokuBoardMainTable56); this.SPlay_text[4][6] = (EditText)findViewById(R.id.numberSudokuBoardMainTable57); this.SPlay_text[4][7] = (EditText)findViewById(R.id.numberSudokuBoardMainTable58); this.SPlay_text[4][8] = (EditText)findViewById(R.id.numberSudokuBoardMainTable59); this.SPlay_text[5][0] = (EditText)findViewById(R.id.numberSudokuBoardMainTable61); this.SPlay_text[5][1] = (EditText)findViewById(R.id.numberSudokuBoardMainTable62); this.SPlay_text[5][2] = (EditText)findViewById(R.id.numberSudokuBoardMainTable63); this.SPlay_text[5][3] = (EditText)findViewById(R.id.numberSudokuBoardMainTable64); this.SPlay_text[5][4] = (EditText)findViewById(R.id.numberSudokuBoardMainTable65); this.SPlay_text[5][5] = (EditText)findViewById(R.id.numberSudokuBoardMainTable66); this.SPlay_text[5][6] = (EditText)findViewById(R.id.numberSudokuBoardMainTable67); this.SPlay_text[5][7] = (EditText)findViewById(R.id.numberSudokuBoardMainTable68); this.SPlay_text[5][8] = (EditText)findViewById(R.id.numberSudokuBoardMainTable69); this.SPlay_text[6][0] = (EditText)findViewById(R.id.numberSudokuBoardMainTable71); this.SPlay_text[6][1] = (EditText)findViewById(R.id.numberSudokuBoardMainTable72); this.SPlay_text[6][2] = (EditText)findViewById(R.id.numberSudokuBoardMainTable73); this.SPlay_text[6][3] = (EditText)findViewById(R.id.numberSudokuBoardMainTable74); this.SPlay_text[6][4] = (EditText)findViewById(R.id.numberSudokuBoardMainTable75); this.SPlay_text[6][5] = (EditText)findViewById(R.id.numberSudokuBoardMainTable76); this.SPlay_text[6][6] = (EditText)findViewById(R.id.numberSudokuBoardMainTable77); this.SPlay_text[6][7] = (EditText)findViewById(R.id.numberSudokuBoardMainTable78); this.SPlay_text[6][8] = (EditText)findViewById(R.id.numberSudokuBoardMainTable79); this.SPlay_text[7][0] = (EditText)findViewById(R.id.numberSudokuBoardMainTable81); this.SPlay_text[7][1] = (EditText)findViewById(R.id.numberSudokuBoardMainTable82); this.SPlay_text[7][2] = (EditText)findViewById(R.id.numberSudokuBoardMainTable83); this.SPlay_text[7][3] = (EditText)findViewById(R.id.numberSudokuBoardMainTable84); this.SPlay_text[7][4] = (EditText)findViewById(R.id.numberSudokuBoardMainTable85); this.SPlay_text[7][5] = (EditText)findViewById(R.id.numberSudokuBoardMainTable86); this.SPlay_text[7][6] = (EditText)findViewById(R.id.numberSudokuBoardMainTable87); this.SPlay_text[7][7] = (EditText)findViewById(R.id.numberSudokuBoardMainTable88); this.SPlay_text[7][8] = (EditText)findViewById(R.id.numberSudokuBoardMainTable89); this.SPlay_text[8][0] = (EditText)findViewById(R.id.numberSudokuBoardMainTable91); this.SPlay_text[8][1] = (EditText)findViewById(R.id.numberSudokuBoardMainTable92); this.SPlay_text[8][2] = (EditText)findViewById(R.id.numberSudokuBoardMainTable93); this.SPlay_text[8][3] = (EditText)findViewById(R.id.numberSudokuBoardMainTable94); this.SPlay_text[8][4] = (EditText)findViewById(R.id.numberSudokuBoardMainTable95); this.SPlay_text[8][5] = (EditText)findViewById(R.id.numberSudokuBoardMainTable96); this.SPlay_text[8][6] = (EditText)findViewById(R.id.numberSudokuBoardMainTable97); this.SPlay_text[8][7] = (EditText)findViewById(R.id.numberSudokuBoardMainTable98); this.SPlay_text[8][8] = (EditText)findViewById(R.id.numberSudokuBoardMainTable99); initializeBoard(); this.SolvedBoard.solveBoard(); } public void openMenu(View view){ PopupMenu sudokuBoardMenu = new PopupMenu(this, view); sudokuBoardMenu.setOnMenuItemClickListener(this); sudokuBoardMenu.inflate(R.menu.sudokuboard_menu); sudokuBoardMenu.show(); } @Override public boolean onMenuItemClick(MenuItem menuItem) { switch (menuItem.getItemId()){ case R.id.itemSudokuBoardMenuResume: return true; case R.id.itemSudokuBoardMenuWhatToDo: Toast.makeText(this,"What to do button pressed.", Toast.LENGTH_SHORT).show(); return true; case R.id.itemSudokuBoardMenuRestart: restartBoard(); return true; case R.id.itemSudokuBoardMenuExit: Intent intentDifficultyBack = new Intent(this, MainActivity.class); startActivity(intentDifficultyBack); return true; default: return false; } } private void initializeBoard(){ String data; String[] splitData; int i, j, k; InputStream isSudokuDataSource = this.getResources().openRawResource(R.raw.sudokudatasource); BufferedReader brSudokuDataSource = new BufferedReader(new InputStreamReader(isSudokuDataSource)); try{ if(isSudokuDataSource!=null){ while((data = brSudokuDataSource.readLine()) != null){ if(data.indexOf(this.Difficulty) == 2){ splitData=data.split("\\|"); this.SudokuId = Integer.parseInt(splitData[0]); k = 1; for (i = 0; i < 9; i++) { for (j = 0; j < 9; j++) { k++; this.SPlay_text[i][j].setText(splitData[k]); if (this.SPlay_text[i][j].getText().toString().length() > 0){ this.PlayBoard.setBoardNumber(i,j,Integer.parseInt(this.SPlay_text[i][j].getText().toString())); this.TemplateBoard.setBoardNumber(i,j,Integer.parseInt(this.SPlay_text[i][j].getText().toString())); this.SolvedBoard.setBoardNumber(i,j,Integer.parseInt(this.SPlay_text[i][j].getText().toString())); } else { this.PlayBoard.setBoardNumber(i,j,0); this.TemplateBoard.setBoardNumber(i,j,0); this.SolvedBoard.setBoardNumber(i,j,0); } } } break; } } } isSudokuDataSource.close(); } catch (IOException e){ e.printStackTrace(); } } private void restartBoard(){ int i, j; this.PlayBoard = this.TemplateBoard; for (i = 0; i < 9; i++) { for (j = 0; j < 9; j++) { if (this.TemplateBoard.getBoardNumber(i,j)> 0) { this.SPlay_text[i][j].setText(String.valueOf(this.TemplateBoard.getBoardNumber(i, j))); } else { this.SPlay_text[i][j].getText().clear(); } } } } }
[ "andreslopezcast@gmail.com" ]
andreslopezcast@gmail.com
15515c28aded3f584a931ebb11de3e90935b665c
e58a3b2f6c673125dae2cda514b37c92c9d01601
/src/expressions/TanExpression.java
4e53868989f54c2d6f7119edf0151e77d981ede5
[]
no_license
wendytyin/Picassa-part3
abd15d7db262a853505ad0ca904a6d5bbaa45b0c
9ce6ac14722d24592632e221e013056bed26ac51
refs/heads/master
2020-05-19T16:56:53.686131
2012-02-08T00:56:53
2012-02-08T00:56:53
3,356,684
1
0
null
null
null
null
UTF-8
Java
false
false
1,292
java
package expressions; import java.util.List; import java.util.regex.Matcher; import java.util.regex.Pattern; import model.ParserException; import model.RGBColor; import model.util.ColorCombinations; public class TanExpression extends ParenExpression { private static final String myCommand="tan"; private static final String commandMatching="tan"; private static final Pattern COMMAND_REGEX = Pattern.compile(commandMatching); // for the factory to look at private TanExpression() {} @Override public Expression getNewExpression() { return new TanExpression(); } public static ExpressionFactory getFactory() { return new ExpressionFactory(new TanExpression()); } @Override public RGBColor evaluate() { List<Expression>mySubExpressions=getSubExpressions(); if (mySubExpressions.isEmpty()){ throw new ParserException( "Not enough numbers, what are you trying to do with " + myCommand +"?"); } RGBColor firstOne=mySubExpressions.get(0).evaluate(); return ColorCombinations.tan(firstOne); } @Override String getMyCommand() {return myCommand; } @Override boolean commandIsThisExpression(String commandName) { Matcher expMatcher = COMMAND_REGEX.matcher(commandName); return expMatcher.lookingAt(); } }
[ "wty3@duke.edu" ]
wty3@duke.edu
6eb605fafead688b989d7a5e812af47480a239cf
55a8f011d45e2a7e88289f15b956d711c0bfec80
/note_code/src/algorithms/four/DijkstraSP.java
d013d49fb29023ac79e26a58ca63f147817b6948
[]
no_license
wy3h/program_list
2246948749d202a41828f81c9d85e8811925ee2e
b7521f7620ecceb3355735800a790edbb3e961b1
refs/heads/master
2021-01-01T18:35:18.340032
2017-12-12T13:41:42
2017-12-12T13:41:42
98,368,021
0
0
null
null
null
null
UTF-8
Java
false
false
985
java
package algorithms.four; import algorithms.three.Graph; import edu.princeton.cs.algs4.DirectedEdge; import edu.princeton.cs.algs4.EdgeWeightedDigraph; import edu.princeton.cs.algs4.IndexMinPQ; public class DijkstraSP { private DirectedEdge[] edgeTo; private double[] distTo; private IndexMinPQ<Double> pq; public DijkstraSP(EdgeWeightedDigraph G, int s) { edgeTo = new DirectedEdge[G.V()]; distTo = new double[G.V()]; pq = new IndexMinPQ<Double>(G.V()); for(int v = 0; v < G.V(); v++) { distTo[v] = Double.POSITIVE_INFINITY; } distTo [s] = 0.0; pq.insert(s, 0.0); while(!pq.isEmpty()) { relax(G, pq.delMin()); } } private void relax(EdgeWeightedDigraph G, int v) { for(DirectedEdge e : G.adj(v)) { int w = e.to(); if(distTo[w] > distTo[v] + e.weight()) { distTo[w] = distTo[v] + e.weight(); edgeTo[w] = e; if(pq.contains(w)) pq.change(w, distTo[w]); else pq.insert(w, distTo[w]); } } } }
[ "wy3hlelouch@gmail.com" ]
wy3hlelouch@gmail.com
74a0e955669d9434abcb1929c7ce17a25f1c1568
beba1579f3be9a51c54ee63182cae8ba053a5e6e
/HackerRankExercises/Exercises/LinkedLists/CycleDetection/Solution.java
b1aadca8db6ca3d8156a943ed52185b8c875fb20
[]
no_license
Ryoliveira/HackerRankExercises
1a789bcaa8b50c6bcd3ca46494b7db80debdde9b
ceae080a1b9b40ffeef2bd66fcaf798ad62470b4
refs/heads/master
2020-05-04T04:32:06.896664
2019-05-14T00:20:05
2019-05-14T00:20:05
178,967,179
0
0
null
null
null
null
UTF-8
Java
false
false
2,939
java
package CycleDetection; import java.io.*; import java.math.*; import java.security.*; import java.text.*; import java.util.*; import java.util.concurrent.*; import java.util.regex.*; //Cycle Detection public class Solution { static class SinglyLinkedListNode { public int data; public SinglyLinkedListNode next; public SinglyLinkedListNode(int nodeData) { this.data = nodeData; this.next = null; } } static class SinglyLinkedList { public SinglyLinkedListNode head; public SinglyLinkedListNode tail; public SinglyLinkedList() { this.head = null; this.tail = null; } public void insertNode(int nodeData) { SinglyLinkedListNode node = new SinglyLinkedListNode(nodeData); if (this.head == null) { this.head = node; } else { this.tail.next = node; } this.tail = node; } } public static void printSinglyLinkedList(SinglyLinkedListNode node, String sep, BufferedWriter bufferedWriter) throws IOException { while (node != null) { bufferedWriter.write(String.valueOf(node.data)); node = node.next; if (node != null) { bufferedWriter.write(sep); } } } // Complete the hasCycle function below. /* * For your reference: * * SinglyLinkedListNode { int data; SinglyLinkedListNode next; } * */ static boolean hasCycle(SinglyLinkedListNode head) { ArrayList<SinglyLinkedListNode> check = new ArrayList<>(); while (head != null) { if (check.contains(head)) { return true; } else { check.add(head); } head = head.next; } return false; } private static final Scanner scanner = new Scanner(System.in); public static void main(String[] args) throws IOException { BufferedWriter bufferedWriter = new BufferedWriter(new FileWriter(System.getenv("OUTPUT_PATH"))); int tests = scanner.nextInt(); scanner.skip("(\r\n|[\n\r\u2028\u2029\u0085])?"); for (int testsItr = 0; testsItr < tests; testsItr++) { int index = scanner.nextInt(); scanner.skip("(\r\n|[\n\r\u2028\u2029\u0085])?"); SinglyLinkedList llist = new SinglyLinkedList(); int llistCount = scanner.nextInt(); scanner.skip("(\r\n|[\n\r\u2028\u2029\u0085])?"); for (int i = 0; i < llistCount; i++) { int llistItem = scanner.nextInt(); scanner.skip("(\r\n|[\n\r\u2028\u2029\u0085])?"); llist.insertNode(llistItem); } SinglyLinkedListNode extra = new SinglyLinkedListNode(-1); SinglyLinkedListNode temp = llist.head; for (int i = 0; i < llistCount; i++) { if (i == index) { extra = temp; } if (i != llistCount - 1) { temp = temp.next; } } temp.next = extra; boolean result = hasCycle(llist.head); bufferedWriter.write(String.valueOf(result ? 1 : 0)); bufferedWriter.newLine(); } bufferedWriter.close(); scanner.close(); } }
[ "windsofryannn@yahoo.com" ]
windsofryannn@yahoo.com
f8a702c03ccacb2b78a6b77184ea6831ac1b9f34
5cdef1cc5e2264ea85d0b42d34ff67e9db4ad47e
/app/src/main/java/com/yts/tsbible/data/TSLiveData.java
9d2fd4d13e771a225cea49570b07d356762846e0
[]
no_license
YunTaeSik/TsBible
b28b83fee06335473623aebd3ba320119810bcab
ebae6eb8092d951a4869f7131ae5d0397b7bce20
refs/heads/master
2020-12-18T18:19:38.734845
2020-01-22T02:27:03
2020-01-22T02:27:03
235,482,061
2
0
null
null
null
null
UTF-8
Java
false
false
276
java
package com.yts.tsbible.data; import androidx.lifecycle.MutableLiveData; public class TSLiveData<T> extends MutableLiveData<T> { public TSLiveData() { } public TSLiveData(T value) { if (value != null) { setValue(value); } } }
[ "sky877kr@gmail.com" ]
sky877kr@gmail.com
8f4c50f4f531d0ea97e6acb6d57e4fcebd096b93
82b354fd3843342f87ac5681db7a509222770e25
/jg/BlueJ/ARBEIT.java
958cd914eb7c5da23ea09517e173242b7dc86583
[]
no_license
hansdampf-dsm/inf09
716cb14b1df579138af51f5f1a575477c3061c4f
2f19927b8acefb88033f6c1ff31f7bacc4e27f9e
refs/heads/main
2023-04-29T00:39:37.715811
2021-05-25T10:43:16
2021-05-25T10:43:16
370,650,988
0
0
null
2021-05-25T10:19:07
2021-05-25T10:19:06
null
ISO-8859-1
Java
false
false
1,936
java
//Dies ist ein Kommentar, das liest nur der Programmierer class ARBEIT { //Der Inhalt einer Klasse wird durch zwei geschweifte Klammern zusammengehalten //Hier werden drei Objekte deklariert WELT welt; ROBOTER karola; ROBOTER cr7; ROBOTER messirve; public ARBEIT() { //Hier werden die drei Objekte erzeugt welt = new WELT( 20,20,20); karola = new ROBOTER(welt); karola.LinksDrehen(); karola.Schritt(); karola.Schritt(); cr7= new ROBOTER(welt); cr7.LinksDrehen(); cr7.Schritt(); messirve = new ROBOTER(welt); } void gleichschritt() { while(karola.IstWand()==false) { karola.Schritt(); cr7.Schritt(); messirve.Schritt(); } { karola.RechtsDrehen(); karola.RechtsDrehen(); cr7.RechtsDrehen(); cr7.RechtsDrehen(); messirve.RechtsDrehen(); messirve.RechtsDrehen(); } while(karola.IstWand()==false) { karola.Schritt(); cr7.Schritt(); messirve.Schritt(); } } void stein(){ while(karola.IstWand()==false) { karola.Hinlegen(); karola.Schritt(); karola.Schritt(); } { karola.RechtsDrehen(); karola.Schritt(); karola.RechtsDrehen(); } } void karolaKreisdrehen() { for(int z=0;z<5 ;z++) { for(int i=0; i<=3; i++) { for(int j=0; j<=3; j++) { karola.Hinlegen(); karola.Schritt(); } karola.LinksDrehen(); } } for(int z=0; z<5; z++) { } } //dies ist die Klammer, die die Klasse schließt
[ "javier.gonzalez@student.dsmadrid.org" ]
javier.gonzalez@student.dsmadrid.org
b88d705a73d0b76fe974416dda08ad8511a90b77
d9675e3d8bdf82e8a09fc63e122dd2c59fc46d5d
/src/main/java/in/viest/scrumserver/ScrumServerApplication.java
3e7918594033c78f8550e9e9c3b12bd99d34064c
[]
no_license
Digitanalogik/scrum-server
7ca74e43070e2a9a35c8fd12fc79a95edfe5117c
b61e8884191ae5c58dfe40174e830e72466a939a
refs/heads/master
2023-01-03T03:46:31.274943
2020-10-18T19:09:26
2020-10-18T19:09:26
301,066,640
0
0
null
2020-10-06T19:09:56
2020-10-04T07:28:34
Java
UTF-8
Java
false
false
420
java
package in.viest.scrumserver; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; import org.springframework.scheduling.annotation.EnableScheduling; @EnableScheduling @SpringBootApplication public class ScrumServerApplication { public static void main(String[] args) { SpringApplication.run(ScrumServerApplication.class, args); } }
[ "tatu.soininen@cinia.fi" ]
tatu.soininen@cinia.fi
6c72837e582c7116b5f538fed7d1b0b6ec1c6ba0
205b00431a81c33dd078ce6dca98550d5aca79ed
/app/src/main/java/com/example/tvshowv2/responses/TVShowResponse.java
45892b7ccba5eae564878970825cecc94cc6abac
[]
no_license
ahmadiyad830/tv-show-app
1ef1bb18b5bc5eba3913c9e2452e6abf2c830026
fd6fdfa45154fcbab82e368c1de81dfef4c89b60
refs/heads/master
2023-08-05T20:24:58.427024
2021-10-09T15:33:18
2021-10-09T15:33:18
null
0
0
null
null
null
null
UTF-8
Java
false
false
613
java
package com.example.tvshowv2.responses; import com.example.tvshowv2.models.TVShows; import com.google.gson.annotations.SerializedName; import java.io.Serializable; import java.util.List; public class TVShowResponse implements Serializable { @SerializedName("page") private int page; @SerializedName("pages") private int totalPages; @SerializedName("tv_shows") private List<TVShows> tvShows; public int getPage() { return page; } public int getTotalPages() { return totalPages; } public List<TVShows> getTvShows() { return tvShows; } }
[ "41261995+ahmadiyad830@users.noreply.github.com" ]
41261995+ahmadiyad830@users.noreply.github.com
e472cb00f10ef14970018da6124dcad6cc86a9c0
09f8be71f6c720a0a858df5be7b2961db7788bf4
/src/test/java/patterns/chain/ChainOfResponsibilityTest.java
a618ecf2f63a702d3de0da1449792c40b78a0160
[]
no_license
iklyubanov/java-personal-workbench
33abb8550cdb4e8844bb5e13a5fecac37418e942
1b6ff416daf44980948104e339298d3cb405e6e8
refs/heads/master
2021-06-21T05:01:03.514946
2019-04-04T21:04:43
2019-04-04T21:04:43
113,438,672
0
0
null
null
null
null
UTF-8
Java
false
false
2,854
java
package patterns.chain; import lombok.AllArgsConstructor; import lombok.Data; import org.junit.Before; import org.junit.Test; public class ChainOfResponsibilityTest { private ManagerPPower manager; private DirectorPPower director; private VicePresidentPPower vp; private PresidentPPower president; @Before public void init() { manager = new ManagerPPower(); director = new DirectorPPower(); vp = new VicePresidentPPower(); president = new PresidentPPower(); manager.setSuccessor(director); director.setSuccessor(vp); vp.setSuccessor(president); } @Test(expected = NoSuchMoneyException.class) public void checkAuthority() { manager.processRequest(new PurchaseRequest(5000, "General")); manager.processRequest(new PurchaseRequest(5001, "General")); manager.processRequest(new PurchaseRequest(50001, "Bribe")); } } abstract class PurchasePower { protected static final double BASE = 500; protected PurchasePower successor; abstract protected double getAllowable(); abstract protected String getRole(); public void setSuccessor(PurchasePower successor) { this.successor = successor; } public void processRequest(PurchaseRequest request) { if(request.getAmount() <= this.getAllowable()) { System.out.println(this.getRole() + " will approve $" + request.getAmount()); } else if (successor != null) { successor.processRequest(request); } else { throw new NoSuchMoneyException("Sorry! You're requesting $" + request.getAmount() + ". Our company don't have such amount of money!"); } } } class ManagerPPower extends PurchasePower { @Override protected double getAllowable() { return BASE * 10; } @Override protected String getRole() { return "Manager"; } } class DirectorPPower extends PurchasePower { @Override protected double getAllowable() { return BASE * 20; } @Override protected String getRole() { return "Director"; } } class VicePresidentPPower extends PurchasePower { @Override protected double getAllowable() { return BASE * 40; } @Override protected String getRole() { return "Vice President"; } } class PresidentPPower extends PurchasePower { @Override protected double getAllowable() { return BASE * 60; } @Override protected String getRole() { return "President"; } } @Data @AllArgsConstructor class PurchaseRequest { private double amount; private String purpose; } class NoSuchMoneyException extends RuntimeException { NoSuchMoneyException(String message) { super(message); System.out.println(message); } }
[ "iklyubanov@gmail.com" ]
iklyubanov@gmail.com
8867a1176bfce4b1b750b604eb6ffdcafa82a792
6069c3f31ad671a40c5c9854d589eb6dc47ca114
/AITL/AITL_git_23_1/app/src/main/java/com/allintheloop/Bean/ExhibitorListClass/FavoritedExhibitor.java
aff20a01f2fffc5086d09cb768c91821026000c4
[]
no_license
bhedaheens/AITL_git_23_1
889b7715c2c5c3a7f6f5e9306a40cd5b504df3c4
2f2132bedf4886702dcc3f4a1b9144c28d3c5730
refs/heads/master
2020-04-23T01:11:25.015574
2019-02-15T05:11:21
2019-02-15T05:11:21
170,805,011
0
0
null
null
null
null
UTF-8
Java
false
false
1,402
java
package com.allintheloop.Bean.ExhibitorListClass; import com.google.gson.annotations.Expose; import com.google.gson.annotations.SerializedName; import java.io.Serializable; import java.util.ArrayList; /** * Created by nteam on 19/5/16. */ public class FavoritedExhibitor implements Serializable { @SerializedName("data") @Expose private ArrayList<FavoriteExhibitor> favoriteExhibitors = new ArrayList<>(); public ArrayList<FavoriteExhibitor> getFavoriteExhibitors() { return favoriteExhibitors; } public void setFavoriteExhibitors(ArrayList<FavoriteExhibitor> favoriteExhibitors) { this.favoriteExhibitors = favoriteExhibitors; } public class FavoriteExhibitor { @SerializedName("exhibitor_page_id") @Expose private String exhibitor_page_id; @SerializedName("exhibitor_user_id") @Expose private String exhibitor_user_id; public String getExhibitor_page_id() { return exhibitor_page_id; } public void setExhibitor_page_id(String exhibitor_page_id) { this.exhibitor_page_id = exhibitor_page_id; } public String getExhibitor_user_id() { return exhibitor_user_id; } public void setExhibitor_user_id(String exhibitor_user_id) { this.exhibitor_user_id = exhibitor_user_id; } } }
[ "heensbheda@gmail.com" ]
heensbheda@gmail.com
d4b53a27d3a6edc8959f145c88c3cd50d96b8e67
9ea9b5c3645fabb401f51c02e8876b689ddbe2d5
/PlataTaxe1/src/java/views/exceptions/NonexistentEntityException.java
5f84a7cd8ca0ebbfc91af17a53bf072bc45f21a0
[]
no_license
roxana-andreea/Paying_taxes_platform
7420123c65404783aa0fe423c155b32ceb4571d5
cfea809c78cba9afb1bf705f509a2682babed3f5
refs/heads/master
2021-06-20T11:21:08.013548
2017-07-15T13:18:43
2017-07-15T13:18:43
78,346,920
0
0
null
null
null
null
UTF-8
Java
false
false
285
java
package views.exceptions; public class NonexistentEntityException extends Exception { public NonexistentEntityException(String message, Throwable cause) { super(message, cause); } public NonexistentEntityException(String message) { super(message); } }
[ "roxana.cazacu93@gmail.com" ]
roxana.cazacu93@gmail.com
4fc34bd85636dbdfbff2ebc697525b34e3bb199e
c602d932641e9fb8b8c3b1dc2303295bafb91703
/src/com/itheima/mybatis/dao/UserDaoImpl.java
e86eb42e0e51e68d5ce996fe914f124e6e10bef7
[]
no_license
gotoJ/mybatis-practice
1696adb1443c6fd65298e51de0e60f16e6bd4197
629a1a66f3f73838ac44a02ceb93fe55ca08dd5f
refs/heads/master
2021-01-11T14:17:46.772639
2017-02-08T09:42:02
2017-02-08T09:43:24
81,313,526
0
0
null
null
null
null
UTF-8
Java
false
false
1,944
java
package com.itheima.mybatis.dao; import java.util.List; import org.apache.ibatis.session.SqlSession; import org.apache.ibatis.session.SqlSessionFactory; import com.itheima.mybatis.po.User; /** *   * <p> * Title: UserDaoImpl * </p> *   * <p> * Description: TODO(这里用一句话描述这个类的作用)  * <p> * <p> * Company: www.itcast.com * </p> *  @author 传智.关云长   @date 2015-12-21 下午2:46:23    @version 1.0 */ public class UserDaoImpl implements UserDao { // 依赖注入 private SqlSessionFactory sqlSessionFactory; public UserDaoImpl(SqlSessionFactory sqlSessionFactory) { this.sqlSessionFactory = sqlSessionFactory; } @Override public User findUserById(int id) throws Exception { // 创建SqlSession SqlSession sqlSession = sqlSessionFactory.openSession(); // 调用SqlSession的增删改查方法 // 第一个参数:表示statement的唯一标示 User user = sqlSession.selectOne("test.findUserById", id); System.out.println(user); // 关闭资源 sqlSession.close(); return user; } @Override public List<User> findUsersByName(String name) { // 创建SqlSession SqlSession sqlSession = sqlSessionFactory.openSession(); // 调用SqlSession的增删改查方法 // 第一个参数:表示statement的唯一标示 List<User> list = sqlSession.selectOne("test.findUsersByName", name); System.out.println(list); // 关闭资源 sqlSession.close(); return list; } @Override public void insertUser(User user) { // 创建SqlSession SqlSession sqlSession = sqlSessionFactory.openSession(); // 调用SqlSession的增删改查方法 // 第一个参数:表示statement的唯一标示 sqlSession.insert("test.insertUser", user); System.out.println(user.getId()); // 提交事务 sqlSession.commit(); // 关闭资源 sqlSession.close(); } }
[ "yanzhen.hebust@gmail.com" ]
yanzhen.hebust@gmail.com
cdaad7f89d150f9eead2bd9471a23fe3fc41dd43
f577c99267dffb5591b7e933b57ecf94b8755724
/src/main/java/org/drip/specialfunction/hankel/BigH1FromBigJ.java
15278c6a2ca84d0974402945bcbf7ec5eb9f5cad
[ "Apache-2.0" ]
permissive
MacroFinanceHub/DROP
18d59cf9fedbaf335e0feb890bcfbfe344c5dfa1
faa3d6469962d1420aef13863334104056d6047b
refs/heads/master
2023-03-17T07:06:26.438651
2021-03-14T04:59:56
2021-03-14T04:59:56
null
0
0
null
null
null
null
UTF-8
Java
false
false
6,635
java
package org.drip.specialfunction.hankel; /* * -*- mode: java; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /*! * Copyright (C) 2020 Lakshmi Krishnamurthy * Copyright (C) 2019 Lakshmi Krishnamurthy * * This file is part of DROP, an open-source library targeting analytics/risk, transaction cost analytics, * asset liability management analytics, capital, exposure, and margin analytics, valuation adjustment * analytics, and portfolio construction analytics within and across fixed income, credit, commodity, * equity, FX, and structured products. It also includes auxiliary libraries for algorithm support, * numerical analysis, numerical optimization, spline builder, model validation, statistical learning, * and computational support. * * https://lakshmidrip.github.io/DROP/ * * DROP is composed of three modules: * * - DROP Product Core - https://lakshmidrip.github.io/DROP-Product-Core/ * - DROP Portfolio Core - https://lakshmidrip.github.io/DROP-Portfolio-Core/ * - DROP Computational Core - https://lakshmidrip.github.io/DROP-Computational-Core/ * * DROP Product Core implements libraries for the following: * - Fixed Income Analytics * - Loan Analytics * - Transaction Cost Analytics * * DROP Portfolio Core implements libraries for the following: * - Asset Allocation Analytics * - Asset Liability Management Analytics * - Capital Estimation Analytics * - Exposure Analytics * - Margin Analytics * - XVA Analytics * * DROP Computational Core implements libraries for the following: * - Algorithm Support * - Computation Support * - Function Analysis * - Model Validation * - Numerical Analysis * - Numerical Optimizer * - Spline Builder * - Statistical Learning * * Documentation for DROP is Spread Over: * * - Main => https://lakshmidrip.github.io/DROP/ * - Wiki => https://github.com/lakshmiDRIP/DROP/wiki * - GitHub => https://github.com/lakshmiDRIP/DROP * - Repo Layout Taxonomy => https://github.com/lakshmiDRIP/DROP/blob/master/Taxonomy.md * - Javadoc => https://lakshmidrip.github.io/DROP/Javadoc/index.html * - Technical Specifications => https://github.com/lakshmiDRIP/DROP/tree/master/Docs/Internal * - Release Versions => https://lakshmidrip.github.io/DROP/version.html * - Community Credits => https://lakshmidrip.github.io/DROP/credits.html * - Issues Catalog => https://github.com/lakshmiDRIP/DROP/issues * - JUnit => https://lakshmidrip.github.io/DROP/junit/index.html * - Jacoco => https://lakshmidrip.github.io/DROP/jacoco/index.html * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * * You may obtain a copy of the License at * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * * See the License for the specific language governing permissions and * limitations under the License. */ /** * <i>BigH1FromBigJ</i> implements the Estimator for the Cylindrical Hankel Function of the First Kind from * the Bessel Function of the First Kind. The References are: * * <br><br> * <ul> * <li> * Abramowitz, M., and I. A. Stegun (2007): <i>Handbook of Mathematics Functions</i> <b>Dover Book * on Mathematics</b> * </li> * <li> * Arfken, G. B., and H. J. Weber (2005): <i>Mathematical Methods for Physicists 6<sup>th</sup> * Edition</i> <b>Harcourt</b> San Diego * </li> * <li> * Temme N. M. (1996): <i>Special Functions: An Introduction to the Classical Functions of * Mathematical Physics 2<sup>nd</sup> Edition</i> <b>Wiley</b> New York * </li> * <li> * Watson, G. N. (1995): <i>A Treatise on the Theory of Bessel Functions</i> <b>Cambridge University * Press</b> * </li> * <li> * Wikipedia (2019): Bessel Function https://en.wikipedia.org/wiki/Bessel_function * </li> * </ul> * * <br><br> * <ul> * <li><b>Module </b> = <a href = "https://github.com/lakshmiDRIP/DROP/tree/master/ComputationalCore.md">Computational Core Module</a></li> * <li><b>Library</b> = <a href = "https://github.com/lakshmiDRIP/DROP/tree/master/FunctionAnalysisLibrary.md">Function Analysis Library</a></li> * <li><b>Project</b> = <a href = "https://github.com/lakshmiDRIP/DROP/tree/master/src/main/java/org/drip/specialfunction/README.md">Special Function Implementation Analysis</a></li> * <li><b>Package</b> = <a href = "https://github.com/lakshmiDRIP/DROP/tree/master/src/main/java/org/drip/specialfunction/hankel/README.md">Ordered Hankel Function Variant Estimators</a></li> * </ul> * * @author Lakshmi Krishnamurthy */ public class BigH1FromBigJ extends org.drip.specialfunction.definition.HankelFirstKindEstimator { private org.drip.specialfunction.definition.BesselFirstKindEstimator _besselFirstKindEstimator = null; /** * BigH1FromBigJ Constructor * * @param besselFirstKindEstimator Bessel Function of the First Kind Estimator * * @throws java.lang.Exception Thrown if the Inputs are Invalid */ public BigH1FromBigJ ( final org.drip.specialfunction.definition.BesselFirstKindEstimator besselFirstKindEstimator) throws java.lang.Exception { if (null == (_besselFirstKindEstimator = besselFirstKindEstimator)) { throw new java.lang.Exception ("BigH1FromBigJ Constructor => Invalid Inputs"); } } /** * Retrieve the Estimator of the Bessel Function of the First Kind * * @return Estimator of the Bessel Function of the First Kind */ public org.drip.specialfunction.definition.BesselFirstKindEstimator besselFirstKindEstimator() { return _besselFirstKindEstimator; } @Override public org.drip.function.definition.CartesianComplexNumber bigH1 ( final double alpha, final double z) { try { return new org.drip.function.definition.CartesianComplexNumber ( _besselFirstKindEstimator.bigJ ( alpha, z ), ( _besselFirstKindEstimator.bigJ ( alpha, z ) * java.lang.Math.cos (java.lang.Math.PI * alpha) - _besselFirstKindEstimator.bigJ ( -1. * alpha, z ) ) / java.lang.Math.sin (java.lang.Math.PI * alpha) ); } catch (java.lang.Exception e) { e.printStackTrace(); } return null; } }
[ "lakshmimv7977@gmail.com" ]
lakshmimv7977@gmail.com
796a3ff40c1023a50181ef4fefcebaece3a5f33a
bc961d975c25d555508166d497b14fcef9c53e38
/app/src/main/java/com/pwr/teamproject/shopassistant/NetworkManager.java
aaedab838b518349742ef4d43b7f4b709469ed6b
[]
no_license
Mokry667/ShopAssistantApp
f4b7089cae54eb57c5dd88dd498b1a7b59f3cfe9
1e60d6a5963cb81bfc066c7d035ec8c4391ffde6
refs/heads/master
2021-01-20T14:34:58.719961
2017-06-12T23:35:15
2017-06-12T23:35:15
90,630,336
0
0
null
null
null
null
UTF-8
Java
false
false
3,489
java
package com.pwr.teamproject.shopassistant; import android.util.Log; import java.io.BufferedReader; import java.io.InputStreamReader; import java.net.HttpURLConnection; import java.net.URL; /** * Created by mokry on 21-May-17. */ public class NetworkManager { private String API_URL = null; private String JSON; public NetworkManager() { API_URL = "http://shopassistantapi.azurewebsites.net/api/"; } public boolean isAccountValid(String username, String password){ try { URL url = new URL(API_URL + "users?login=" + username + "&pass=" + password); HttpURLConnection urlConnection = (HttpURLConnection) url.openConnection(); int responseCode = urlConnection.getResponseCode(); // if response is 200 account exist if(responseCode == 200){ return true; } else return false; } catch (Exception e) { Log.e("ERROR", e.getMessage(), e); return false; } } protected String getFromAPI(String request) { try { URL url = new URL( API_URL + request); Log.d("REQUEST", String.valueOf(url)); HttpURLConnection urlConnection = (HttpURLConnection) url.openConnection(); try { BufferedReader bufferedReader = new BufferedReader(new InputStreamReader(urlConnection.getInputStream())); StringBuilder stringBuilder = new StringBuilder(); String line; while ((line = bufferedReader.readLine()) != null) { stringBuilder.append(line).append("\n"); } bufferedReader.close(); Log.d("JSON", stringBuilder.toString()); return stringBuilder.toString(); } finally { urlConnection.disconnect(); } } catch (Exception e) { Log.e("ERROR", e.getMessage(), e); return null; } } protected String getProducts(String productName) { String request = "products?name="; productName = productName.replace(" ", "%20"); return getFromAPI(request + productName); } protected String getProductsCheapest(String productName, String lat, String lng) { String request = "products?name="; productName = productName.replace(" ", "%20"); String locationRequest = "&action=cheapest"; String latRequest = "&lat="; String lngRequest = "&lng="; return getFromAPI(request + productName + locationRequest + latRequest + lat + lngRequest + lng); } protected String getProductsClosest(String productName, String lat, String lng) { String request = "products?name="; productName = productName.replace(" ", "%20"); String locationRequest = "&action=closest"; String latRequest = "&lat="; String lngRequest = "&lng="; return getFromAPI(request + productName + locationRequest + latRequest + lat + lngRequest + lng); } protected String getStoreProducts(String productName) { String request = "storeproducts?name="; productName = productName.replace(" ", "%20"); return getFromAPI(request + productName); } protected String getStores() { String request = "stores"; return getFromAPI(request); } public String getJSON(){ return JSON; } }
[ "mokry667@gmail.com" ]
mokry667@gmail.com
7567f019f2d8b071d4c7e01f55463a0456012e01
34f9026fe840dcffc294b3a70c71e050f0b5c9c7
/distributed_system_message_passing/src/main2/MessageComparator.java
d86cc207f03aabd8f81652b349c1680c6df7c525
[]
no_license
Ronshery/overview
c18818cf6b6076c7b3ee980af931ce3fefa12eca
440feb3ebd7fffd8cf04d19f65170c6f396138cf
refs/heads/main
2023-02-22T04:41:42.066780
2021-01-25T14:49:25
2021-01-25T14:49:25
332,774,764
0
0
null
null
null
null
UTF-8
Java
false
false
546
java
package main2; import java.util.Comparator; public class MessageComparator implements Comparator<Message> { @Override public int compare(Message m1, Message m2) { if(m1.getLamportstamp() < m2.getLamportstamp()){ return -1; } else if(m1.getLamportstamp() > m2.getLamportstamp()) { return 1; } else if(m1.getRcptthread() < m2.getRcptthread()) { return -1; } else if(m1.getRcptthread() > m2.getRcptthread()) { return 1; } return 0; } }
[ "ronensh2606@googlemail.com" ]
ronensh2606@googlemail.com
aea18faf7c110b82516fb65fdbffb75c0d88aeb1
447520f40e82a060368a0802a391697bc00be96f
/apks/playstore_apps/com_idamob_tinkoff_android/source/com/google/android/gms/iid/MessengerCompat.java
97db8574b65da40a32ea9a44134a03a72b7372f5
[ "Apache-2.0" ]
permissive
iantal/AndroidPermissions
7f3343a9c29d82dbcd4ecd98b3a50ddf8d179465
d623b732734243590b5f004d167e542e2e2ae249
refs/heads/master
2023-07-19T01:29:26.689186
2019-09-30T19:01:42
2019-09-30T19:01:42
107,239,248
0
0
Apache-2.0
2023-07-16T07:41:38
2017-10-17T08:22:57
null
UTF-8
Java
false
false
2,063
java
package com.google.android.gms.iid; import android.os.Build.VERSION; import android.os.IBinder; import android.os.IInterface; import android.os.Message; import android.os.Messenger; import android.os.Parcel; import android.os.Parcelable.Creator; import android.os.RemoteException; import com.google.android.gms.common.internal.ReflectedParcelable; public class MessengerCompat implements ReflectedParcelable { public static final Parcelable.Creator<MessengerCompat> CREATOR = new f(); private Messenger a; private d b; public MessengerCompat(IBinder paramIBinder) { if (Build.VERSION.SDK_INT >= 21) { this.a = new Messenger(paramIBinder); return; } if (paramIBinder == null) { paramIBinder = null; } for (;;) { this.b = paramIBinder; return; IInterface localIInterface = paramIBinder.queryLocalInterface("com.google.android.gms.iid.IMessengerCompat"); if ((localIInterface instanceof d)) { paramIBinder = (d)localIInterface; } else { paramIBinder = new e(paramIBinder); } } } private final IBinder a() { if (this.a != null) { return this.a.getBinder(); } return this.b.asBinder(); } public final void a(Message paramMessage) throws RemoteException { if (this.a != null) { this.a.send(paramMessage); return; } this.b.a(paramMessage); } public int describeContents() { return 0; } public boolean equals(Object paramObject) { if (paramObject == null) { return false; } try { boolean bool = a().equals(((MessengerCompat)paramObject).a()); return bool; } catch (ClassCastException paramObject) {} return false; } public int hashCode() { return a().hashCode(); } public void writeToParcel(Parcel paramParcel, int paramInt) { if (this.a != null) { paramParcel.writeStrongBinder(this.a.getBinder()); return; } paramParcel.writeStrongBinder(this.b.asBinder()); } }
[ "antal.micky@yahoo.com" ]
antal.micky@yahoo.com
62e40a06da21ec54b9f25dfb084484a9ab7d1b0e
7369f6dac52b3ac53cefac15ec3045cb3dea03b2
/src/test/java/TestCases/TwitterAPI.java
f0f21a54f718e38e6b7ac56f4a235f2f6235a887
[]
no_license
mahmedk13/RestAssuredRealTime
ee4fd62b9a7fadfd424dd4ba97e354af965cf34a
cd30266ddcc3e7e2cef167e397bc370fa1e52016
refs/heads/master
2020-04-23T19:13:00.079703
2019-04-20T10:40:21
2019-04-20T10:40:21
171,395,442
0
0
null
null
null
null
UTF-8
Java
false
false
1,860
java
package TestCases; import java.util.List; import org.testng.annotations.Test; import com.aventstack.extentreports.Status; import Utility.TestSetup; import io.restassured.path.json.JsonPath; import io.restassured.response.Response; import static io.restassured.RestAssured.*; public class TwitterAPI extends TestSetup { /* * Response response = given().auth().oauth("BjApkejjTBjAJLSJqhrBwFSWR", * "lCyAiJcBuafFgk2XExYKFS0nk6SyJB0Wb6xYYDalH3dX6U0m8y", * "1049004757401001984-cGT2UHgJ2mk8FnZA8cfKfuAC0chg1U", * "K5qyT8MTvD1UhiacR7AIWCxnd8dErdtIZ0Gs6Ch59meF4") .queryParam("status", * "Good show by Mamta and Opposition and others").post( * "https://api.twitter.com/1.1/statuses/update.json").then().extract().response * (); * */ @Test public void tc01() { Response response =given() .auth() .oauth("BjApkejjTBjAJLSJqhrBwFSWR","lCyAiJcBuafFgk2XExYKFS0nk6SyJB0Wb6xYYDalH3dX6U0m8y","1049004757401001984-cGT2UHgJ2mk8FnZA8cfKfuAC0chg1U","K5qyT8MTvD1UhiacR7AIWCxnd8dErdtIZ0Gs6Ch59meF4") .queryParam("id", "1092329341747367939") .get("/show.json") .then().extract().response(); /* * response=given() .auth() .oauth("BjApkejjTBjAJLSJqhrBwFSWR", * "lCyAiJcBuafFgk2XExYKFS0nk6SyJB0Wb6xYYDalH3dX6U0m8y", * "1049004757401001984-cGT2UHgJ2mk8FnZA8cfKfuAC0chg1U", * "K5qyT8MTvD1UhiacR7AIWCxnd8dErdtIZ0Gs6Ch59meF4") //.queryParam("id", * "1091936025889378304") .post("/destroy/"+1091933139365187585L+".json") * .then().extract().response(); */ System.out.println(response.statusCode()); JsonPath jp = response.jsonPath(); List<String> list = jp.get("entities.user_mentions*.screen_name"); System.out.println(list); testLevelLogger.get().log(Status.PASS, "Called API to get status"); } }
[ "mahmedk13@gmail.com" ]
mahmedk13@gmail.com
d395f3d1f939e9d38fb902406c3579e7f4ced672
e920decf97e866a8cd982afe307bb1d7662f3d69
/src/br/com/agenda/executavel/Executavel.java
1e0ff89d84df3471be169815a1a5127e0f26d4e1
[]
no_license
nathaliacosim/crud-agenda-java
0eb16888bc7a6310478aa609a57befc677ebffef
97626aa6ab8f5d8a2be63de734aa1dc77fffcea2
refs/heads/master
2020-08-26T20:03:51.657376
2019-10-23T19:01:48
2019-10-23T19:01:48
217,131,044
0
0
null
null
null
null
UTF-8
Java
false
false
264
java
package br.com.agenda.executavel; import br.com.agenda.view.AgendaView; import java.sql.SQLException; public class Executavel { public static void main(String[] args) throws SQLException { AgendaView av = new AgendaView(); av.menu(); } }
[ "nathalia.cosim@novaandradina.org" ]
nathalia.cosim@novaandradina.org
274d84a6f130fb3b986a5c54c3f567b7f714c5e0
3a7313a8a15e6ea37213d9c42c5c8e9d93023b77
/BoaViagem/app/src/test/java/com/example/mvr/boaviagem/ExampleUnitTest.java
aa547bed93556a074a9e56dc5afef55dc4af54a2
[]
no_license
mcnvrodrigues/Android
41c480adeb21e6bdb83df55b63e5e3d61f9d0f23
4f4e75fe839b75c1d334bd354f9c83abaa5d181a
refs/heads/master
2020-05-18T20:29:11.118585
2019-05-02T19:02:58
2019-05-02T19:02:58
184,634,519
0
0
null
null
null
null
UTF-8
Java
false
false
386
java
package com.example.mvr.boaviagem; import org.junit.Test; import static org.junit.Assert.*; /** * Example local unit test, which will execute on the development machine (host). * * @see <a href="http://d.android.com/tools/testing">Testing documentation</a> */ public class ExampleUnitTest { @Test public void addition_isCorrect() { assertEquals(4, 2 + 2); } }
[ "mvr@br.ibm.com" ]
mvr@br.ibm.com
ef2b12c4f3bb79a6c872a0c0f5f24fa8bd834603
ce2d16d66eb87b42579ca70c47d5b89d3149af54
/src/main/java/br/cubas/testerabbitmq/service/CustomMessageListener.java
e0e0cc3711a2513a447790755e8b9c910548a6bf
[]
no_license
carloscubas/RabbitMQSpring
24ccabbd970585539afd601516e880c127e31629
c9cada0de81800adebe0d6dde51e24544992d031
refs/heads/master
2021-05-11T14:18:14.847893
2018-01-16T16:17:00
2018-01-16T16:17:00
117,700,942
0
0
null
null
null
null
UTF-8
Java
false
false
478
java
package br.cubas.testerabbitmq.service; import org.springframework.amqp.core.Message; import org.springframework.amqp.rabbit.annotation.RabbitListener; import org.springframework.stereotype.Service; import br.cubas.testerabbitmq.model.Employee; @Service public class CustomMessageListener { @RabbitListener(queues = "${cubas.rabbitmq.queue}") public void receiveMessage(final Employee company) { System.out.println("received: " + company.toString()); } }
[ "carlos.cubas@gmail.com" ]
carlos.cubas@gmail.com
d8e91e2142cd8f87aca4523028b0072f85200e08
d4bc9830700cbb5e663b9b987ba7930fee1fe0f1
/src/_144BinaryTreePreorderTraversal.java
7e3214293740c16bd741ee4e8900fc0f9be572d6
[]
no_license
Qstar/leetcode
e7f76a5cb6fd21c7ab75d947bba443b034804ddd
435787b0543c62b2d2687849220868c042d2e38f
refs/heads/master
2021-06-03T16:55:49.729422
2018-03-12T11:59:47
2018-03-12T11:59:47
58,041,851
0
0
null
null
null
null
UTF-8
Java
false
false
709
java
import common.TreeNode; import java.util.LinkedList; import java.util.List; import java.util.Stack; public class _144BinaryTreePreorderTraversal { public List<Integer> preorderTraversal(TreeNode root) { List<Integer> preorder = new LinkedList<>(); Stack<TreeNode> stack = new Stack<>(); TreeNode node = root; while (node != null || !stack.empty()) { while (node != null) { preorder.add(node.val); stack.push(node); node = node.left; } if (stack.size() > 0) { node = stack.pop(); node = node.right; } } return preorder; } }
[ "davesla2012@hotmail.com" ]
davesla2012@hotmail.com
1be57261ffe9ea0c7bb9e9021feaaa1b522b0898
494319b2340c581c1116d7074aa65979c407d935
/src/test/java/org/jmxtrans/embedded/util/pool/ManagedGenericKeyedObjectPoolTest.java
e2de8b99bed7abf9620f57529be149f8040ef478
[ "EPL-1.0", "CPL-1.0", "EPL-2.0", "LGPL-2.1-only", "MIT", "Apache-2.0" ]
permissive
wanghy6503/embedded-jmxtrans
adb362cd2d2b68a5d94f773b7a6fb651b8c206af
727fc3bacc6b507be6298ee4e4efaa0c44822e7e
refs/heads/master
2022-12-03T14:19:35.092561
2014-08-19T09:05:37
2014-08-19T09:05:37
23,495,910
0
0
MIT
2022-11-25T16:24:17
2014-08-30T16:36:51
null
UTF-8
Java
false
false
2,613
java
/* * Copyright (c) 2010-2013 the original author or authors * * Permission is hereby granted, free of charge, to any person obtaining * a copy of this software and associated documentation files (the * "Software"), to deal in the Software without restriction, including * without limitation the rights to use, copy, modify, merge, publish, * distribute, sublicense, and/or sell copies of the Software, and to * permit persons to whom the Software is furnished to do so, subject to * the following conditions: * * The above copyright notice and this permission notice shall be * included in all copies or substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE * LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION * OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. * */ package org.jmxtrans.embedded.util.pool; import org.apache.commons.pool.BaseKeyedPoolableObjectFactory; import org.junit.Test; import javax.management.MBeanServer; import javax.management.ObjectName; import java.lang.management.ManagementFactory; import static org.hamcrest.CoreMatchers.*; import static org.junit.Assert.*; /** * @author <a href="mailto:cleclerc@xebia.fr">Cyrille Le Clerc</a> */ public class ManagedGenericKeyedObjectPoolTest { @Test public void testMbeanAttributeAccess() throws Exception { BaseKeyedPoolableObjectFactory<String, String> factory = new BaseKeyedPoolableObjectFactory<String, String>() { @Override public String makeObject(String key) throws Exception { return key; } }; ManagedGenericKeyedObjectPool<String, String> objectPool = new ManagedGenericKeyedObjectPool<String, String>(factory); ObjectName objectName = new ObjectName("org.jmxtrans.embedded:Type=TestPool,Name=TestPool@" + System.identityHashCode(this)); MBeanServer mbeanServer = ManagementFactory.getPlatformMBeanServer(); objectName = mbeanServer.registerMBean(objectPool, objectName).getObjectName(); try { Object numIdle = mbeanServer.getAttribute(objectName, "NumIdle"); assertThat(numIdle, instanceOf(Number.class)); } finally { mbeanServer.unregisterMBean(objectName); } } }
[ "cyrille@cyrilleleclerc.com" ]
cyrille@cyrilleleclerc.com
7bb002828b55758b0f17a5dda8fd9cddab1447b1
ad047aedb697e84bbc91717e90eb4c00bf970583
/电商架构一Hibernate/dsqimo/src/com/frontend/entity/CartItem.java
5135cd16368067f45cf24ef8bf020127edd3c229
[]
no_license
luyanpu/project-training
5c9c8eadb74c9826544e6c6e9af5a342d99baa8b
7678ed12e0413150f010b53e96e25b2c702cd76a
refs/heads/master
2020-03-22T09:21:24.026358
2018-07-05T10:23:18
2018-07-05T10:23:18
139,829,392
0
0
null
null
null
null
UTF-8
Java
false
false
1,352
java
package com.frontend.entity; import javax.persistence.Column; import javax.persistence.Entity; import javax.persistence.GeneratedValue; import javax.persistence.Id; import javax.persistence.JoinColumn; import javax.persistence.ManyToOne; import javax.persistence.Table; import org.hibernate.annotations.GenericGenerator; @Entity @Table(name="cartitem") public class CartItem { private int id; private int proid; private String name; private int count; private double total; private Cart cart; @Id @GeneratedValue(generator="ciid") @GenericGenerator(name = "ciid", strategy = "native") public int getId() { return id; } public void setId(int id) { this.id = id; } @Column(name="proid") public int getProid() { return proid; } public void setProid(int proid) { this.proid = proid; } @Column(name="name") public String getName() { return name; } public void setName(String name) { this.name = name; } @Column(name="total") public double getTotal() { return total; } public void setTotal(double total) { this.total = total; } public void setCount(int count) { this.count=count; } @Column(name="count") public int getCount() { return this.count; } @ManyToOne @JoinColumn(name="cartid") public Cart getCart() { return cart; } public void setCart(Cart cart) { this.cart = cart; } }
[ "lyp_usesr@163.com" ]
lyp_usesr@163.com
9a9397a16a6a90601296431f8bda475e33d96550
e2cbb52f41c26181c49c107d8acfe44ca61e0725
/src/main/java/com/springapp/xmlTest/GerenalXml.java
ceedf289e41551e5be455d87f49d90b496512c26
[]
no_license
zzjmay123/SpringMVC
158eefec3c2acc64b189f2c77966d9612cab22e1
10cc395a69eb11ee493515f1a7b16a9ec09897d0
refs/heads/master
2020-12-25T14:23:07.841890
2016-10-15T10:49:17
2016-10-15T10:49:17
66,449,623
0
0
null
null
null
null
UTF-8
Java
false
false
6,159
java
package com.springapp.xmlTest; import com.jd.jr.pay.gate.signature.util.JdPayUtil; import javax.annotation.Resource; /** * Created by zhouzhenjiang on 2016/9/21. */ public class GerenalXml { String deskey = "Z8KMT8cT4z5ruu89znxFhRP4DdDBqLUH"; String priKey = "MIICdwIBADANBgkqhkiG9w0BAQEFAASCAmEwggJdAgEAAoGBAL60FMvs2u2xikCbANWohQQI+llOnFrobMh+Tzkn/sGVyFNVBBmyT8ej+6a6o28b2VGlMP+oOGRSjrJuqy7pwMJqMvWPxSmmMjTqbi/FYmJNJfYmcEHrf8Jwn5PFJN2bCQdsiXJfiMquvJTiSDDV9m43NCXccp/wHXr0UQ05OAYlAgMBAAECgYEAhBrNeUKXmibtxblah6eYlWX+vtT0/QibKvxMtyRclw/CWO/Aymg6WerfzezmgHaDQcq0ObX3co+6KCL/1Jy7GP/Hk32BgfFpbp90PtQXGjVp03wUobJUBlGFfIxQjnIPUMT145z7aYN0u+ycz17IhA6K3M0QSn39VaOxpp37XcECQQDp6Xfj5dZ1TPcnPMRnSbARwo6fluMmCSRKffO032UOThZkE8un5nD5VhI3KCEllhB6LiIeG35CR5yf++lBUcbRAkEA0LYZnUu8WeNaHwAlKshvquiPzk3xugjum3Gld3wrY6neMSP1F84pbGumpIMnUuglWtKaWPD5anC8sAlF6qMHFQJAFAif8Q/lT0SZQm4M8D+6abr9FiQJLl/IEO06qzoa4J/FgSrE3Yt6D5DUnI6+UAbLQHulBmkaZjjV7EnaD3MekQJAJHOJabVugex5MuzdkOlMx3aylv959lnVAoUItyOSmGd0jPSQu8Wf6nWqtxTI62vsCj66Akqj5Pknmz8jXOV4OQJBANtNmkZH79AQl3heWHnFsr6pPyiZwVopHphzifjddHu3Mvu8/nwQvgXGRu+2vXeUGGhVRlw9W8YYRfNEFiQ+L3o="; String pubKey ="MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQC+tBTL7NrtsYpAmwDVqIUECPpZTpxa6GzIfk85J/7BlchTVQQZsk/Ho/umuqNvG9lRpTD/qDhkUo6ybqsu6cDCajL1j8UppjI06m4vxWJiTSX2JnBB63/CcJ+TxSTdmwkHbIlyX4jKrryU4kgw1fZuNzQl3HKf8B169FENOTgGJQIDAQAB"; // String cert = CertUtil.getCert(); String version = "V2.0"; String merchant = "22318136"; String oTradeNum = "223181361460707816970"; public static void main(String[] args) throws IllegalAccessException, InstantiationException { GerenalXml gerenalXml = new GerenalXml(); // gerenalXml.getXMLStr(); gerenalXml.decrptXmlStr(); } public void getXMLStr() throws IllegalAccessException { // String deskey = "Z8KMT8cT4z5ruu89znxFhRP4DdDBqLUH"; // String priKey = "MIICdwIBADANBgkqhkiG9w0BAQEFAASCAmEwggJdAgEAAoGBAL60FMvs2u2xikCbANWohQQI+llOnFrobMh+Tzkn/sGVyFNVBBmyT8ej+6a6o28b2VGlMP+oOGRSjrJuqy7pwMJqMvWPxSmmMjTqbi/FYmJNJfYmcEHrf8Jwn5PFJN2bCQdsiXJfiMquvJTiSDDV9m43NCXccp/wHXr0UQ05OAYlAgMBAAECgYEAhBrNeUKXmibtxblah6eYlWX+vtT0/QibKvxMtyRclw/CWO/Aymg6WerfzezmgHaDQcq0ObX3co+6KCL/1Jy7GP/Hk32BgfFpbp90PtQXGjVp03wUobJUBlGFfIxQjnIPUMT145z7aYN0u+ycz17IhA6K3M0QSn39VaOxpp37XcECQQDp6Xfj5dZ1TPcnPMRnSbARwo6fluMmCSRKffO032UOThZkE8un5nD5VhI3KCEllhB6LiIeG35CR5yf++lBUcbRAkEA0LYZnUu8WeNaHwAlKshvquiPzk3xugjum3Gld3wrY6neMSP1F84pbGumpIMnUuglWtKaWPD5anC8sAlF6qMHFQJAFAif8Q/lT0SZQm4M8D+6abr9FiQJLl/IEO06qzoa4J/FgSrE3Yt6D5DUnI6+UAbLQHulBmkaZjjV7EnaD3MekQJAJHOJabVugex5MuzdkOlMx3aylv959lnVAoUItyOSmGd0jPSQu8Wf6nWqtxTI62vsCj66Akqj5Pknmz8jXOV4OQJBANtNmkZH79AQl3heWHnFsr6pPyiZwVopHphzifjddHu3Mvu8/nwQvgXGRu+2vXeUGGhVRlw9W8YYRfNEFiQ+L3o="; // String pubKey ="MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQC+tBTL7NrtsYpAmwDVqIUECPpZTpxa6GzIfk85J/7BlchTVQQZsk/Ho/umuqNvG9lRpTD/qDhkUo6ybqsu6cDCajL1j8UppjI06m4vxWJiTSX2JnBB63/CcJ+TxSTdmwkHbIlyX4jKrryU4kgw1fZuNzQl3HKf8B169FENOTgGJQIDAQAB"; //// String cert = CertUtil.getCert(); // // String version = "V2.0"; // String merchant = "22318136"; // String oTradeNum = "223181361460707816970"; TradeQueryInner queryTradeDTO = new TradeQueryInner(); queryTradeDTO.setVersion(version); queryTradeDTO.setMerchant(merchant); queryTradeDTO.setoTradeNum(oTradeNum); queryTradeDTO.setTradeType("1"); // 0:消费 1:退款 String xml = JdPayUtil.genReqXml(queryTradeDTO, priKey, deskey); System.out.println("query xml:" + xml); } public void decrptXmlStr() throws InstantiationException, IllegalAccessException { String rs ="<jdpay><version>V2.0</version><merchant>22318136</merchant><result><code>000000</code><desc>success</desc></result><encrypt>MThmMTdhZWQwMGJiZjA4MmVmZWVlYjZlZTYyNTZkZTAzMTRlY2I5ZjRhZGI0MTNkMmQ3NGRiYWEzZWZkNTE4ODM1MDg4MTNiMmQwNWI2OTllZmY4ZmYxMDVhZDQ1NTA0OGFhZWYxYWU0ZDJiZTM1MmNlOGU5YTlmYTIzMGFkMmUwZjRhMGQwMDZkMjRiNzdhNWQ4NjZlNmZlMzBlNzZkMDY4ZDdjMzJhNGJiMGU1OGU0NjA5Y2ZhMzBkNWJhMjdkMjBlOWM5YmE5Y2U2NWU1MzBjOTVlNTk0NGNhMzViZDZmYTQ2NWU0OGU2ZmM1YTVlOTA1MTZhYWY2NGJmNDY0MmUwYzNhZGI1ODQ2MDU3Nzk1Y2FmMzdiYzQ0MjRkODc2OWY0MjQxY2FhNzg4NjFiYmExZGIxYTBjYzFiMTA2MzhkZjQ0NTkxMDM3ODhhOTNiNGI0YzRmYjZjYTY5ZDA4NThlNmExZWU1YWVjNTFmN2JiZTc4YTZiNDljYzVmY2E3ZDhiNGVhYjk0YzhhOTNjMDhlNmExZWU1YWVjNTFmN2JhOTA3ODFiNzcwMjJhNTRkZjA4MmQ5MTlkNWNhMTZhZDBjYWMyZWMzMjVjNzIyNGE4NmRmNGNhYzlhNjk1MmY4MjhmYTkxOThkOTdlMzdmYjk3YTkxOWQ0YWVkNWJjMDQ4YzRlMjNlMjM2OGM5MmMzZTAyMTMyNDEwOWI0Y2RmYzAyZTRiNmIwMWExZmMwYTIyMWVkOGM4ZTc0Mjg5YTBjNGNkZDU2NWY1ZjZjMmEyNzlhYTBjZWM0NTQ1NmUzN2M2NTViNTJjNDdmNjI0MGJlM2QyMTU2ZDgwZjM5MTA2YWNmMWI2ZTkyN2RlZjkxYWQ3N2ZlMmU1Y2JjMzIyZjdmYjUxZGVmZmM1Yjc4ZTczMTYzMmVhZjFhZmVkNmQ2NjgwYTUxZGMzZGY1ODdhNWNhNWRkNjBlODQ0ZTkyZTZkMjJkNzMxMDc2NWQyMDQ0NjM5YTNhN2YxYjEzMmE0ZmY5OWEzYTdmMWIxMzJhNGZmOTEwMDhmMzFlZjhiOTFjMmM1MTFkYTZkYzZlZjdkNTQ1MTNmZDIwZjE3ZGI4YWY3NzEwMDhmMzFlZjhiOTFjMmMwMTJjMDc1MDBkY2RmNjgzM2FlOTNlMThhNTgyZTgwNDVlNDU1NDhlNTJjYjM5ZWQxMDA2NzVmYzRiNjdhMmM1MGRmY2ZjMTE2NWM0YjA1YmJhYWFmNGVmNzgxOWViMjMyMjE0NjM0ZDZlNzNmMjM0ZmI5ZTQ1NWJlYjQxODQ4Y2I3MmZiYWJjODYzNDRlMWM5MGY0N2ZhM2FlNDQzZjdhNGM1OTk3OTYzMWQwMGMxMWEyNzg3YTkzMDc0MzZiODAyNzg0MTRjMzYzNTU0ZmMwOWY0NjNhNDFkODk4NzY5ZDVhY2E0YTQ3MWEzZTU1MDk1MmVkNjg3MWY0MmRiZWM5NmQ5NDVhOWViZTI1YmE5NDQ4MGQwNWExZTRhY2EwNWVjMTE1Y2M4ZjZhZWI2NTVhYjI1Njk2Mzg4ZGIxZmRhOGM4ZDIzOTI5NThmODIxZTRmMDBlMGEwMTExMDY2ZjY4MzYxZjQ0N2Y4NjlhMWIxYjlkZTg3NDEyNTdiOGQ4N2ZhMGUwYzUxMTRhYThkM2E4NjYzMWVlNDM4YTc1MjBlMzhkMDM4NDZiODJkNjBlZjY2YTEyMWMxYjUwZDQ4NzBlYzE0Yjc0Zjc5YjYxZGZjNzQ5YTc3ODdkOTNjMzU5YTU1ZGVjODU3MjBhNDg4ZDM2OTMxNTkxZWY4OTNjNmIwNmRjNjY0M2Y5Yjc2Y2IzNzAxMTk3MWEzMTExM2I4MjgwNDY3ZjY0MzZjOWZmMGRjM2I4MzYwNDhmMmRjYzAzMzc0ODQwNjVkZjJmNmVlZmZlNDFlMGNhMTM4MGIxNzM5ZGUxZWJkOTU5NTg0YzYxYWQ2ZDNhZDBjYmZhOTVlNTExNWQ4ODQ3MDE5MGViODAxMTdhNjVhZDlhYzdjYTBkYzBjYWE1NmQ5NTgzZjJjNzIyM2RkZWE5ZTkyZTAzYTA1OTBmYTM1NDE3ODE1NWU5YjM1N2NmNWFmNjRhYTljYzM3N2ZiZjRlOTc5NTc0MjgyMjc1NDBiMWFmNTQ2MWM3ZjE=</encrypt></jdpay>"; QueryRefundNewResponse queryRefundResponse = JdPayUtil.parseResp(pubKey, deskey, rs, QueryRefundNewResponse.class); System.out.println(queryRefundResponse); } }
[ "zhouzhenjiang@jd.com" ]
zhouzhenjiang@jd.com
7628d84201ff4e5159c41f9e3e5e680fe50656ee
e9b2e4ee2932168ca7fe4d5bb8d16f3d414dd898
/pet-clinic-data/src/main/java/com/gurjar/chaman/cgspringpetclinic/model/Person.java
7bbf888cea162c3526e8f77aba0aa028c659c5e7
[]
no_license
ChamanGurjar/CG-Spring-Pet-Clinic
e05da12151348cb31495135d357aa3bdc38b73f7
b2f1154b21316bda3efa84fb9ede072ae5ad4c40
refs/heads/master
2022-11-30T12:13:19.418309
2020-08-19T17:40:55
2020-08-19T17:40:55
282,360,955
0
1
null
null
null
null
UTF-8
Java
false
false
444
java
package com.gurjar.chaman.cgspringpetclinic.model; import lombok.AllArgsConstructor; import lombok.Getter; import lombok.NoArgsConstructor; import lombok.Setter; import javax.persistence.MappedSuperclass; /** * @author - Chaman Gurjar * @since - 26-Jul-2020 */ @Getter @Setter @AllArgsConstructor @NoArgsConstructor @MappedSuperclass public class Person extends BaseEntity { private String firstName; private String lastName; }
[ "chamangujjar162@gmail.com" ]
chamangujjar162@gmail.com
682da4214e8fe87235e6e4dbe4e616b37cb3cf12
5fab844565cb513bcde33e71b9bdfe30b363d839
/Multimediasysteme/UE2/at/jku/tk/mms/huffman/test/BitStreamTest.java
581a5e5d883253b4e2b5ff089df65d2d1c34df82
[]
no_license
JukicD/Multimediasysteme
a6e7aad8bec4a29b78dd425b903d5d81283ec04c
95570c69c6031227be77b04392992e4fd385b8e0
refs/heads/master
2021-01-25T05:16:18.178659
2015-05-12T18:19:07
2015-05-12T18:19:07
33,734,262
0
0
null
null
null
null
UTF-8
Java
false
false
1,840
java
package at.jku.tk.mms.huffman.test; import static org.junit.Assert.assertEquals; import org.junit.Test; import at.jku.tk.mms.huffman.impl.BitStream; public class BitStreamTest { public static final String TEST_INPUT = "Two goldfish are in a tank. One says to the other, \"Do you know how to drive this thing?\""; @Test public void testBitStreamWriting() { BitStream s = new BitStream(); s.setDebug(true); s.writeBit((byte)0);// byte 1 / val 85 s.writeBit((byte)1); s.writeBit((byte)0); s.writeBit((byte)1); s.writeBit((byte)0); s.writeBit((byte)1); s.writeBit((byte)0); s.writeBit((byte)1); s.writeBit((byte)0);// byte 2 / val 85 s.writeBit((byte)1); s.writeBit((byte)0); s.writeBit((byte)1); s.writeBit((byte)0); s.writeBit((byte)1); s.writeBit((byte)0); s.writeBit((byte)1); s.writeBit((byte)0);// byte 3 / val 64 s.writeBit((byte)1);// fill with 0 s.flush(); byte[] arr = s.toByteArray(); assertEquals(3, arr.length); assertEquals(85, arr[0]); assertEquals(85, arr[1]); assertEquals(64, arr[2]); } @Test public void testBitStreamReading() { byte[]arr = new byte [] { 85, 85, 64 }; BitStream s = new BitStream(arr); s.setDebug(true); String cur = ""; int i=0; while(s.canRead()) { if(s.readBit() > 0) { cur += "1"; }else{ cur += "0"; } i++; } assertEquals(24, i); assertEquals("010101010101010101000000", cur); } @Test public void testBitStreamInOut() { BitStream in = new BitStream(TEST_INPUT.getBytes()); in.setDebug(true); BitStream out = new BitStream(); out.setDebug(true); int i=0; while(in.canRead()) { byte bit = in.readBit(); out.writeBit(bit); i++; } out.flush(); assertEquals(TEST_INPUT.length() * 8, i); String str = new String(out.toByteArray()); assertEquals(TEST_INPUT, str); } }
[ "jukic-dejan@hotmail.com" ]
jukic-dejan@hotmail.com
fbcbf1f8a78506eb82a0efbac66d83f7a5872ed4
11425ab53a20575ed6bd9457efd61b5f8cea80ef
/BE/airbnb/src/main/java/team01/airbnb/config/WebConfig.java
455d41a865b4ac1c661433768def8b58ced1c4d4
[]
no_license
ehdrhelr/airbnb
0fc8b2d5a407ddeeb21df042e9608b226970945e
34b4307bcaf49df13bf791a5ef7bcde4e1a04551
refs/heads/main
2023-05-09T15:25:34.207565
2021-05-25T08:50:42
2021-05-25T08:50:42
368,023,036
1
1
null
2021-06-04T10:06:26
2021-05-17T01:32:58
TypeScript
UTF-8
Java
false
false
1,462
java
package team01.airbnb.config; import lombok.RequiredArgsConstructor; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; import org.springframework.web.method.support.HandlerMethodArgumentResolver; import org.springframework.web.servlet.config.annotation.InterceptorRegistry; import org.springframework.web.servlet.config.annotation.WebMvcConfigurer; import team01.airbnb.config.auth.LoginUserArgumentResolver; import team01.airbnb.config.interceptor.LoginInterceptor; import team01.airbnb.config.interceptor.LogoutInterceptor; import java.util.List; @RequiredArgsConstructor @Configuration public class WebConfig implements WebMvcConfigurer { private final LoginUserArgumentResolver loginUserArgumentResolver; @Override public void addInterceptors(InterceptorRegistry registry) { registry.addInterceptor(logoutInterceptor()) .addPathPatterns("/logout"); registry.addInterceptor(loginInterceptor()) .addPathPatterns("/auth/kakao/callback"); } @Override public void addArgumentResolvers(List<HandlerMethodArgumentResolver> argumentResolvers) { argumentResolvers.add(loginUserArgumentResolver); } @Bean public LogoutInterceptor logoutInterceptor() { return new LogoutInterceptor(); } @Bean public LoginInterceptor loginInterceptor() { return new LoginInterceptor(); } }
[ "ehdrhelr@gmail.com" ]
ehdrhelr@gmail.com
45a6b5eea352636461c3d206accf10b2b849f7af
222d225e8b923d74692c39789e245e16b622bf02
/utils/src/main/java/software/amazon/awssdk/utils/async/LimitingSubscriber.java
faa8f8d2ea8a73bc32a8cc8ca648bf3bd63995e1
[ "Apache-2.0" ]
permissive
udaysagar2177/aws-sdk-java-v2
58b64cf35b57310504243b687e04e18e2f9e991f
1220ac91102d841a627740780a1a7135319bc8a1
refs/heads/master
2020-04-13T04:38:25.239152
2019-01-09T22:06:01
2019-01-09T22:06:01
162,967,132
0
0
Apache-2.0
2018-12-24T08:12:08
2018-12-24T08:12:08
null
UTF-8
Java
false
false
1,724
java
/* * Copyright 2010-2018 Amazon.com, Inc. or its affiliates. All Rights Reserved. * * Licensed under the Apache License, Version 2.0 (the "License"). * You may not use this file except in compliance with the License. * A copy of the License is located at * * http://aws.amazon.com/apache2.0 * * or in the "license" file accompanying this file. This file is distributed * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either * express or implied. See the License for the specific language governing * permissions and limitations under the License. */ package software.amazon.awssdk.utils.async; import java.util.concurrent.atomic.AtomicInteger; import org.reactivestreams.Subscriber; import org.reactivestreams.Subscription; import software.amazon.awssdk.annotations.SdkProtectedApi; @SdkProtectedApi public class LimitingSubscriber<T> extends DelegatingSubscriber<T, T> { private final int limit; private final AtomicInteger delivered = new AtomicInteger(0); private Subscription subscription; public LimitingSubscriber(Subscriber<? super T> subscriber, int limit) { super(subscriber); this.limit = limit; } @Override public void onSubscribe(Subscription subscription) { super.onSubscribe(subscription); this.subscription = subscription; } @Override public void onNext(T t) { // We may get more events even after cancelling so we ignore them. if (delivered.get() < limit) { subscriber.onNext(t); } // If we've met the limit then we can cancel the subscription if (delivered.incrementAndGet() >= limit) { subscription.cancel(); } } }
[ "shorea@amazon.com" ]
shorea@amazon.com
13bd817aa4177dcfa09b4c36a6dc7426a2e7e501
c89061b347bdcfdefd286d8caa3532bb13c3f3de
/sdk/src/main/java/com/finbourne/lusid/model/InflationSwapAllOf.java
405f0754490360cdf0bf6f79b446e5fcea3331a7
[ "MIT" ]
permissive
finbourne/lusid-sdk-java
8030942805582eecceba8ca34fb5b28e06c4df1f
ee54175d6122a2f44e9c4d762258288dfa44bf67
refs/heads/master
2023-08-18T00:48:44.799150
2023-08-16T11:16:56
2023-08-16T11:16:56
125,093,870
4
13
NOASSERTION
2023-09-14T15:05:10
2018-03-13T18:03:42
Java
UTF-8
Java
false
false
39,256
java
/* * LUSID API * # Introduction This page documents the [LUSID APIs](../../../api/swagger), which allows authorised clients to query and update their data within the LUSID platform. SDKs to interact with the LUSID APIs are available in the following languages and frameworks: * [C#](https://github.com/finbourne/lusid-sdk-csharp) * [Java](https://github.com/finbourne/lusid-sdk-java) * [JavaScript](https://github.com/finbourne/lusid-sdk-js) * [Python](https://github.com/finbourne/lusid-sdk-python) * [Angular](https://github.com/finbourne/lusid-sdk-angular) The LUSID platform is made up of a number of sub-applications. You can find the API / swagger documentation by following the links in the table below. | Application | Description | API / Swagger Documentation | |---------------|-----------------------------------------------------------------------------------|------------------------------------------------------| | LUSID | Open, API-first, developer-friendly investment data platform. | [Swagger](../../../api/swagger/index.html) | | Web app | User-facing front end for LUSID. | [Swagger](../../../app/swagger/index.html) | | Scheduler | Automated job scheduler. | [Swagger](../../../scheduler2/swagger/index.html) | | Insights | Monitoring and troubleshooting service. | [Swagger](../../../insights/swagger/index.html) | | Identity | Identity management for LUSID (in conjunction with Access) | [Swagger](../../../identity/swagger/index.html) | | Access | Access control for LUSID (in conjunction with Identity) | [Swagger](../../../access/swagger/index.html) | | Drive | Secure file repository and manager for collaboration. | [Swagger](../../../drive/swagger/index.html) | | Luminesce | Data virtualisation service (query data from multiple providers, including LUSID) | [Swagger](../../../honeycomb/swagger/index.html) | | Notification | Notification service. | [Swagger](../../../notifications/swagger/index.html) | | Configuration | File store for secrets and other sensitive information. | [Swagger](../../../configuration/swagger/index.html) | # Error Codes | Code|Name|Description | | ---|---|--- | | <a name=\"-10\">-10</a>|Server Configuration Error| | | <a name=\"-1\">-1</a>|Unknown error|An unexpected error was encountered on our side. | | <a name=\"102\">102</a>|Version Not Found| | | <a name=\"103\">103</a>|Api Rate Limit Violation| | | <a name=\"104\">104</a>|Instrument Not Found| | | <a name=\"105\">105</a>|Property Not Found| | | <a name=\"106\">106</a>|Portfolio Recursion Depth| | | <a name=\"108\">108</a>|Group Not Found| | | <a name=\"109\">109</a>|Portfolio Not Found| | | <a name=\"110\">110</a>|Property Schema Not Found| | | <a name=\"111\">111</a>|Portfolio Ancestry Not Found| | | <a name=\"112\">112</a>|Portfolio With Id Already Exists| | | <a name=\"113\">113</a>|Orphaned Portfolio| | | <a name=\"119\">119</a>|Missing Base Claims| | | <a name=\"121\">121</a>|Property Not Defined| | | <a name=\"122\">122</a>|Cannot Delete System Property| | | <a name=\"123\">123</a>|Cannot Modify Immutable Property Field| | | <a name=\"124\">124</a>|Property Already Exists| | | <a name=\"125\">125</a>|Invalid Property Life Time| | | <a name=\"126\">126</a>|Property Constraint Style Excludes Properties| | | <a name=\"127\">127</a>|Cannot Modify Default Data Type| | | <a name=\"128\">128</a>|Group Already Exists| | | <a name=\"129\">129</a>|No Such Data Type| | | <a name=\"130\">130</a>|Undefined Value For Data Type| | | <a name=\"131\">131</a>|Unsupported Value Type Defined On Data Type| | | <a name=\"132\">132</a>|Validation Error| | | <a name=\"133\">133</a>|Loop Detected In Group Hierarchy| | | <a name=\"134\">134</a>|Undefined Acceptable Values| | | <a name=\"135\">135</a>|Sub Group Already Exists| | | <a name=\"138\">138</a>|Price Source Not Found| | | <a name=\"139\">139</a>|Analytic Store Not Found| | | <a name=\"141\">141</a>|Analytic Store Already Exists| | | <a name=\"143\">143</a>|Client Instrument Already Exists| | | <a name=\"144\">144</a>|Duplicate In Parameter Set| | | <a name=\"147\">147</a>|Results Not Found| | | <a name=\"148\">148</a>|Order Field Not In Result Set| | | <a name=\"149\">149</a>|Operation Failed| | | <a name=\"150\">150</a>|Elastic Search Error| | | <a name=\"151\">151</a>|Invalid Parameter Value| | | <a name=\"153\">153</a>|Command Processing Failure| | | <a name=\"154\">154</a>|Entity State Construction Failure| | | <a name=\"155\">155</a>|Entity Timeline Does Not Exist| | | <a name=\"156\">156</a>|Concurrency Conflict Failure| | | <a name=\"157\">157</a>|Invalid Request| | | <a name=\"158\">158</a>|Event Publish Unknown| | | <a name=\"159\">159</a>|Event Query Failure| | | <a name=\"160\">160</a>|Blob Did Not Exist| | | <a name=\"162\">162</a>|Sub System Request Failure| | | <a name=\"163\">163</a>|Sub System Configuration Failure| | | <a name=\"165\">165</a>|Failed To Delete| | | <a name=\"166\">166</a>|Upsert Client Instrument Failure| | | <a name=\"167\">167</a>|Illegal As At Interval| | | <a name=\"168\">168</a>|Illegal Bitemporal Query| | | <a name=\"169\">169</a>|Invalid Alternate Id| | | <a name=\"170\">170</a>|Cannot Add Source Portfolio Property Explicitly| | | <a name=\"171\">171</a>|Entity Already Exists In Group| | | <a name=\"172\">172</a>|Entity With Id Does Not Exist| | | <a name=\"173\">173</a>|Entity With Id Already Exists| | | <a name=\"174\">174</a>|Derived Portfolio Details Do Not Exist| | | <a name=\"175\">175</a>|Entity Not In Group| | | <a name=\"176\">176</a>|Portfolio With Name Already Exists| | | <a name=\"177\">177</a>|Invalid Transactions| | | <a name=\"178\">178</a>|Reference Portfolio Not Found| | | <a name=\"179\">179</a>|Duplicate Id| | | <a name=\"180\">180</a>|Command Retrieval Failure| | | <a name=\"181\">181</a>|Data Filter Application Failure| | | <a name=\"182\">182</a>|Search Failed| | | <a name=\"183\">183</a>|Movements Engine Configuration Key Failure| | | <a name=\"184\">184</a>|Fx Rate Source Not Found| | | <a name=\"185\">185</a>|Accrual Source Not Found| | | <a name=\"186\">186</a>|Access Denied| | | <a name=\"187\">187</a>|Invalid Identity Token| | | <a name=\"188\">188</a>|Invalid Request Headers| | | <a name=\"189\">189</a>|Price Not Found| | | <a name=\"190\">190</a>|Invalid Sub Holding Keys Provided| | | <a name=\"191\">191</a>|Duplicate Sub Holding Keys Provided| | | <a name=\"192\">192</a>|Cut Definition Not Found| | | <a name=\"193\">193</a>|Cut Definition Invalid| | | <a name=\"194\">194</a>|Time Variant Property Deletion Date Unspecified| | | <a name=\"195\">195</a>|Perpetual Property Deletion Date Specified| | | <a name=\"196\">196</a>|Time Variant Property Upsert Date Unspecified| | | <a name=\"197\">197</a>|Perpetual Property Upsert Date Specified| | | <a name=\"200\">200</a>|Invalid Unit For Data Type| | | <a name=\"201\">201</a>|Invalid Type For Data Type| | | <a name=\"202\">202</a>|Invalid Value For Data Type| | | <a name=\"203\">203</a>|Unit Not Defined For Data Type| | | <a name=\"204\">204</a>|Units Not Supported On Data Type| | | <a name=\"205\">205</a>|Cannot Specify Units On Data Type| | | <a name=\"206\">206</a>|Unit Schema Inconsistent With Data Type| | | <a name=\"207\">207</a>|Unit Definition Not Specified| | | <a name=\"208\">208</a>|Duplicate Unit Definitions Specified| | | <a name=\"209\">209</a>|Invalid Units Definition| | | <a name=\"210\">210</a>|Invalid Instrument Identifier Unit| | | <a name=\"211\">211</a>|Holdings Adjustment Does Not Exist| | | <a name=\"212\">212</a>|Could Not Build Excel Url| | | <a name=\"213\">213</a>|Could Not Get Excel Version| | | <a name=\"214\">214</a>|Instrument By Code Not Found| | | <a name=\"215\">215</a>|Entity Schema Does Not Exist| | | <a name=\"216\">216</a>|Feature Not Supported On Portfolio Type| | | <a name=\"217\">217</a>|Quote Not Found| | | <a name=\"218\">218</a>|Invalid Quote Identifier| | | <a name=\"219\">219</a>|Invalid Metric For Data Type| | | <a name=\"220\">220</a>|Invalid Instrument Definition| | | <a name=\"221\">221</a>|Instrument Upsert Failure| | | <a name=\"222\">222</a>|Reference Portfolio Request Not Supported| | | <a name=\"223\">223</a>|Transaction Portfolio Request Not Supported| | | <a name=\"224\">224</a>|Invalid Property Value Assignment| | | <a name=\"230\">230</a>|Transaction Type Not Found| | | <a name=\"231\">231</a>|Transaction Type Duplication| | | <a name=\"232\">232</a>|Portfolio Does Not Exist At Given Date| | | <a name=\"233\">233</a>|Query Parser Failure| | | <a name=\"234\">234</a>|Duplicate Constituent| | | <a name=\"235\">235</a>|Unresolved Instrument Constituent| | | <a name=\"236\">236</a>|Unresolved Instrument In Transition| | | <a name=\"237\">237</a>|Missing Side Definitions| | | <a name=\"299\">299</a>|Invalid Recipe| | | <a name=\"300\">300</a>|Missing Recipe| | | <a name=\"301\">301</a>|Dependencies| | | <a name=\"304\">304</a>|Portfolio Preprocess Failure| | | <a name=\"310\">310</a>|Valuation Engine Failure| | | <a name=\"311\">311</a>|Task Factory Failure| | | <a name=\"312\">312</a>|Task Evaluation Failure| | | <a name=\"313\">313</a>|Task Generation Failure| | | <a name=\"314\">314</a>|Engine Configuration Failure| | | <a name=\"315\">315</a>|Model Specification Failure| | | <a name=\"320\">320</a>|Market Data Key Failure| | | <a name=\"321\">321</a>|Market Resolver Failure| | | <a name=\"322\">322</a>|Market Data Failure| | | <a name=\"330\">330</a>|Curve Failure| | | <a name=\"331\">331</a>|Volatility Surface Failure| | | <a name=\"332\">332</a>|Volatility Cube Failure| | | <a name=\"350\">350</a>|Instrument Failure| | | <a name=\"351\">351</a>|Cash Flows Failure| | | <a name=\"352\">352</a>|Reference Data Failure| | | <a name=\"360\">360</a>|Aggregation Failure| | | <a name=\"361\">361</a>|Aggregation Measure Failure| | | <a name=\"370\">370</a>|Result Retrieval Failure| | | <a name=\"371\">371</a>|Result Processing Failure| | | <a name=\"372\">372</a>|Vendor Result Processing Failure| | | <a name=\"373\">373</a>|Vendor Result Mapping Failure| | | <a name=\"374\">374</a>|Vendor Library Unauthorised| | | <a name=\"375\">375</a>|Vendor Connectivity Error| | | <a name=\"376\">376</a>|Vendor Interface Error| | | <a name=\"377\">377</a>|Vendor Pricing Failure| | | <a name=\"378\">378</a>|Vendor Translation Failure| | | <a name=\"379\">379</a>|Vendor Key Mapping Failure| | | <a name=\"380\">380</a>|Vendor Reflection Failure| | | <a name=\"381\">381</a>|Vendor Process Failure| | | <a name=\"382\">382</a>|Vendor System Failure| | | <a name=\"390\">390</a>|Attempt To Upsert Duplicate Quotes| | | <a name=\"391\">391</a>|Corporate Action Source Does Not Exist| | | <a name=\"392\">392</a>|Corporate Action Source Already Exists| | | <a name=\"393\">393</a>|Instrument Identifier Already In Use| | | <a name=\"394\">394</a>|Properties Not Found| | | <a name=\"395\">395</a>|Batch Operation Aborted| | | <a name=\"400\">400</a>|Invalid Iso4217 Currency Code| | | <a name=\"401\">401</a>|Cannot Assign Instrument Identifier To Currency| | | <a name=\"402\">402</a>|Cannot Assign Currency Identifier To Non Currency| | | <a name=\"403\">403</a>|Currency Instrument Cannot Be Deleted| | | <a name=\"404\">404</a>|Currency Instrument Cannot Have Economic Definition| | | <a name=\"405\">405</a>|Currency Instrument Cannot Have Lookthrough Portfolio| | | <a name=\"406\">406</a>|Cannot Create Currency Instrument With Multiple Identifiers| | | <a name=\"407\">407</a>|Specified Currency Is Undefined| | | <a name=\"410\">410</a>|Index Does Not Exist| | | <a name=\"411\">411</a>|Sort Field Does Not Exist| | | <a name=\"413\">413</a>|Negative Pagination Parameters| | | <a name=\"414\">414</a>|Invalid Search Syntax| | | <a name=\"415\">415</a>|Filter Execution Timeout| | | <a name=\"420\">420</a>|Side Definition Inconsistent| | | <a name=\"450\">450</a>|Invalid Quote Access Metadata Rule| | | <a name=\"451\">451</a>|Access Metadata Not Found| | | <a name=\"452\">452</a>|Invalid Access Metadata Identifier| | | <a name=\"460\">460</a>|Standard Resource Not Found| | | <a name=\"461\">461</a>|Standard Resource Conflict| | | <a name=\"462\">462</a>|Calendar Not Found| | | <a name=\"463\">463</a>|Date In A Calendar Not Found| | | <a name=\"464\">464</a>|Invalid Date Source Data| | | <a name=\"465\">465</a>|Invalid Timezone| | | <a name=\"601\">601</a>|Person Identifier Already In Use| | | <a name=\"602\">602</a>|Person Not Found| | | <a name=\"603\">603</a>|Cannot Set Identifier| | | <a name=\"617\">617</a>|Invalid Recipe Specification In Request| | | <a name=\"618\">618</a>|Inline Recipe Deserialisation Failure| | | <a name=\"619\">619</a>|Identifier Types Not Set For Entity| | | <a name=\"620\">620</a>|Cannot Delete All Client Defined Identifiers| | | <a name=\"650\">650</a>|The Order requested was not found.| | | <a name=\"654\">654</a>|The Allocation requested was not found.| | | <a name=\"655\">655</a>|Cannot build the fx forward target with the given holdings.| | | <a name=\"656\">656</a>|Group does not contain expected entities.| | | <a name=\"665\">665</a>|Destination directory not found| | | <a name=\"667\">667</a>|Relation definition already exists| | | <a name=\"672\">672</a>|Could not retrieve file contents| | | <a name=\"673\">673</a>|Missing entitlements for entities in Group| | | <a name=\"674\">674</a>|Next Best Action not found| | | <a name=\"676\">676</a>|Relation definition not defined| | | <a name=\"677\">677</a>|Invalid entity identifier for relation| | | <a name=\"681\">681</a>|Sorting by specified field not supported|One or more of the provided fields to order by were either invalid or not supported. | | <a name=\"682\">682</a>|Too many fields to sort by|The number of fields to sort the data by exceeds the number allowed by the endpoint | | <a name=\"684\">684</a>|Sequence Not Found| | | <a name=\"685\">685</a>|Sequence Already Exists| | | <a name=\"686\">686</a>|Non-cycling sequence has been exhausted| | | <a name=\"687\">687</a>|Legal Entity Identifier Already In Use| | | <a name=\"688\">688</a>|Legal Entity Not Found| | | <a name=\"689\">689</a>|The supplied pagination token is invalid| | | <a name=\"690\">690</a>|Property Type Is Not Supported| | | <a name=\"691\">691</a>|Multiple Tax-lots For Currency Type Is Not Supported| | | <a name=\"692\">692</a>|This endpoint does not support impersonation| | | <a name=\"693\">693</a>|Entity type is not supported for Relationship| | | <a name=\"694\">694</a>|Relationship Validation Failure| | | <a name=\"695\">695</a>|Relationship Not Found| | | <a name=\"697\">697</a>|Derived Property Formula No Longer Valid| | | <a name=\"698\">698</a>|Story is not available| | | <a name=\"703\">703</a>|Corporate Action Does Not Exist| | | <a name=\"720\">720</a>|The provided sort and filter combination is not valid| | | <a name=\"721\">721</a>|A2B generation failed| | | <a name=\"722\">722</a>|Aggregated Return Calculation Failure| | | <a name=\"723\">723</a>|Custom Entity Definition Identifier Already In Use| | | <a name=\"724\">724</a>|Custom Entity Definition Not Found| | | <a name=\"725\">725</a>|The Placement requested was not found.| | | <a name=\"726\">726</a>|The Execution requested was not found.| | | <a name=\"727\">727</a>|The Block requested was not found.| | | <a name=\"728\">728</a>|The Participation requested was not found.| | | <a name=\"729\">729</a>|The Package requested was not found.| | | <a name=\"730\">730</a>|The OrderInstruction requested was not found.| | | <a name=\"732\">732</a>|Custom Entity not found.| | | <a name=\"733\">733</a>|Custom Entity Identifier already in use.| | | <a name=\"735\">735</a>|Calculation Failed.| | | <a name=\"736\">736</a>|An expected key on HttpResponse is missing.| | | <a name=\"737\">737</a>|A required fee detail is missing.| | | <a name=\"738\">738</a>|Zero rows were returned from Luminesce| | | <a name=\"739\">739</a>|Provided Weekend Mask was invalid| | | <a name=\"742\">742</a>|Custom Entity fields do not match the definition| | | <a name=\"746\">746</a>|The provided sequence is not valid.| | | <a name=\"751\">751</a>|The type of the Custom Entity is different than the type provided in the definition.| | | <a name=\"752\">752</a>|Luminesce process returned an error.| | | <a name=\"753\">753</a>|File name or content incompatible with operation.| | | <a name=\"755\">755</a>|Schema of response from Drive is not as expected.| | | <a name=\"757\">757</a>|Schema of response from Luminesce is not as expected.| | | <a name=\"758\">758</a>|Luminesce timed out.| | | <a name=\"763\">763</a>|Invalid Lusid Entity Identifier Unit| | | <a name=\"768\">768</a>|Fee rule not found.| | | <a name=\"769\">769</a>|Cannot update the base currency of a portfolio with transactions loaded| | | <a name=\"771\">771</a>|Transaction configuration source not found| | | <a name=\"774\">774</a>|Compliance rule not found.| | | <a name=\"775\">775</a>|Fund accounting document cannot be processed.| | | <a name=\"778\">778</a>|Unable to look up FX rate from trade ccy to portfolio ccy for some of the trades.| | | <a name=\"782\">782</a>|The Property definition dataType is not matching the derivation formula dataType| | | <a name=\"783\">783</a>|The Property definition domain is not supported for derived properties| | | <a name=\"788\">788</a>|Compliance run not found failure.| | | <a name=\"790\">790</a>|Custom Entity has missing or invalid identifiers| | | <a name=\"791\">791</a>|Custom Entity definition already exists| | | <a name=\"792\">792</a>|Compliance PropertyKey is missing.| | | <a name=\"793\">793</a>|Compliance Criteria Value for matching is missing.| | | <a name=\"795\">795</a>|Cannot delete identifier definition| | | <a name=\"796\">796</a>|Tax rule set not found.| | | <a name=\"797\">797</a>|A tax rule set with this id already exists.| | | <a name=\"798\">798</a>|Multiple rule sets for the same property key are applicable.| | | <a name=\"800\">800</a>|Can not upsert an instrument event of this type.| | | <a name=\"801\">801</a>|The instrument event does not exist.| | | <a name=\"802\">802</a>|The Instrument event is missing salient information.| | | <a name=\"803\">803</a>|The Instrument event could not be processed.| | | <a name=\"804\">804</a>|Some data requested does not follow the order graph assumptions.| | | <a name=\"811\">811</a>|A price could not be found for an order.| | | <a name=\"812\">812</a>|A price could not be found for an allocation.| | | <a name=\"813\">813</a>|Chart of Accounts not found.| | | <a name=\"814\">814</a>|Account not found.| | | <a name=\"815\">815</a>|Abor not found.| | | <a name=\"816\">816</a>|Abor Configuration not found.| | | <a name=\"817\">817</a>|Reconciliation mapping not found| | | <a name=\"818\">818</a>|Attribute type could not be deleted because it doesn't exist.| | | <a name=\"819\">819</a>|Reconciliation not found.| | | <a name=\"820\">820</a>|Custodian Account not found.| | | <a name=\"821\">821</a>|Allocation Failure| | | <a name=\"822\">822</a>|Reconciliation run not found| | | <a name=\"823\">823</a>|Reconciliation break not found| | | <a name=\"824\">824</a>|Entity link type could not be deleted because it doesn't exist.| | | <a name=\"828\">828</a>|Address key definition not found.| | | <a name=\"829\">829</a>|Compliance template not found.| | | <a name=\"830\">830</a>|Action not supported| | | <a name=\"831\">831</a>|Reference list not found.| | | <a name=\"832\">832</a>|Posting Module not found.| | | <a name=\"833\">833</a>|The type of parameter provided did not match that required by the compliance rule.| | | <a name=\"834\">834</a>|The parameters provided by a rule did not match those required by its template.| | | <a name=\"835\">835</a>|PostingModuleRule has a not allowed Property Domain.| | | <a name=\"836\">836</a>|Structured result data not found.| | | <a name=\"837\">837</a>|Diary entry not found.| | | <a name=\"838\">838</a>|Diary entry could not be created.| | | <a name=\"839\">839</a>|Diary entry already exists.| | | <a name=\"861\">861</a>|Compliance run summary not found.| | | <a name=\"869\">869</a>|Conflicting instrument properties in batch.| | * * The version of the OpenAPI document: 1.0.444 * Contact: info@finbourne.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ package com.finbourne.lusid.model; import java.util.Objects; import java.util.Arrays; import com.finbourne.lusid.model.FlowConventions; import com.google.gson.TypeAdapter; import com.google.gson.annotations.JsonAdapter; import com.google.gson.annotations.SerializedName; import com.google.gson.stream.JsonReader; import com.google.gson.stream.JsonWriter; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; import java.time.OffsetDateTime; /** * InflationSwapAllOf */ @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") public class InflationSwapAllOf { public static final String SERIALIZED_NAME_START_DATE = "startDate"; @SerializedName(SERIALIZED_NAME_START_DATE) private OffsetDateTime startDate; public static final String SERIALIZED_NAME_MATURITY_DATE = "maturityDate"; @SerializedName(SERIALIZED_NAME_MATURITY_DATE) private OffsetDateTime maturityDate; public static final String SERIALIZED_NAME_FLOW_CONVENTIONS = "flowConventions"; @SerializedName(SERIALIZED_NAME_FLOW_CONVENTIONS) private FlowConventions flowConventions; public static final String SERIALIZED_NAME_FIXED_RATE = "fixedRate"; @SerializedName(SERIALIZED_NAME_FIXED_RATE) private java.math.BigDecimal fixedRate; public static final String SERIALIZED_NAME_INFLATION_CAP = "inflationCap"; @SerializedName(SERIALIZED_NAME_INFLATION_CAP) private java.math.BigDecimal inflationCap; public static final String SERIALIZED_NAME_INFLATION_FLOOR = "inflationFloor"; @SerializedName(SERIALIZED_NAME_INFLATION_FLOOR) private java.math.BigDecimal inflationFloor; public static final String SERIALIZED_NAME_INFLATION_FREQUENCY = "inflationFrequency"; @SerializedName(SERIALIZED_NAME_INFLATION_FREQUENCY) private String inflationFrequency; public static final String SERIALIZED_NAME_INFLATION_INDEX_NAME = "inflationIndexName"; @SerializedName(SERIALIZED_NAME_INFLATION_INDEX_NAME) private String inflationIndexName; public static final String SERIALIZED_NAME_INFLATION_INTERPOLATION = "inflationInterpolation"; @SerializedName(SERIALIZED_NAME_INFLATION_INTERPOLATION) private String inflationInterpolation; public static final String SERIALIZED_NAME_INFLATION_ROLL_DAY = "inflationRollDay"; @SerializedName(SERIALIZED_NAME_INFLATION_ROLL_DAY) private Integer inflationRollDay; public static final String SERIALIZED_NAME_NOTIONAL = "notional"; @SerializedName(SERIALIZED_NAME_NOTIONAL) private java.math.BigDecimal notional; public static final String SERIALIZED_NAME_OBSERVATION_LAG = "observationLag"; @SerializedName(SERIALIZED_NAME_OBSERVATION_LAG) private String observationLag; public static final String SERIALIZED_NAME_PAY_RECEIVE = "payReceive"; @SerializedName(SERIALIZED_NAME_PAY_RECEIVE) private String payReceive; /** * The available values are: QuotedSecurity, InterestRateSwap, FxForward, Future, ExoticInstrument, FxOption, CreditDefaultSwap, InterestRateSwaption, Bond, EquityOption, FixedLeg, FloatingLeg, BespokeCashFlowsLeg, Unknown, TermDeposit, ContractForDifference, EquitySwap, CashPerpetual, CapFloor, CashSettled, CdsIndex, Basket, FundingLeg, FxSwap, ForwardRateAgreement, SimpleInstrument, Repo, Equity, ExchangeTradedOption, ReferenceInstrument, ComplexBond, InflationLinkedBond, InflationSwap, SimpleCashFlowLoan */ @JsonAdapter(InstrumentTypeEnum.Adapter.class) public enum InstrumentTypeEnum { QUOTEDSECURITY("QuotedSecurity"), INTERESTRATESWAP("InterestRateSwap"), FXFORWARD("FxForward"), FUTURE("Future"), EXOTICINSTRUMENT("ExoticInstrument"), FXOPTION("FxOption"), CREDITDEFAULTSWAP("CreditDefaultSwap"), INTERESTRATESWAPTION("InterestRateSwaption"), BOND("Bond"), EQUITYOPTION("EquityOption"), FIXEDLEG("FixedLeg"), FLOATINGLEG("FloatingLeg"), BESPOKECASHFLOWSLEG("BespokeCashFlowsLeg"), UNKNOWN("Unknown"), TERMDEPOSIT("TermDeposit"), CONTRACTFORDIFFERENCE("ContractForDifference"), EQUITYSWAP("EquitySwap"), CASHPERPETUAL("CashPerpetual"), CAPFLOOR("CapFloor"), CASHSETTLED("CashSettled"), CDSINDEX("CdsIndex"), BASKET("Basket"), FUNDINGLEG("FundingLeg"), FXSWAP("FxSwap"), FORWARDRATEAGREEMENT("ForwardRateAgreement"), SIMPLEINSTRUMENT("SimpleInstrument"), REPO("Repo"), EQUITY("Equity"), EXCHANGETRADEDOPTION("ExchangeTradedOption"), REFERENCEINSTRUMENT("ReferenceInstrument"), COMPLEXBOND("ComplexBond"), INFLATIONLINKEDBOND("InflationLinkedBond"), INFLATIONSWAP("InflationSwap"), SIMPLECASHFLOWLOAN("SimpleCashFlowLoan"); private String value; InstrumentTypeEnum(String value) { this.value = value; } public String getValue() { return value; } @Override public String toString() { return String.valueOf(value); } public static InstrumentTypeEnum fromValue(String value) { for (InstrumentTypeEnum b : InstrumentTypeEnum.values()) { if (b.value.equals(value)) { return b; } } throw new IllegalArgumentException("Unexpected value '" + value + "'"); } public static class Adapter extends TypeAdapter<InstrumentTypeEnum> { @Override public void write(final JsonWriter jsonWriter, final InstrumentTypeEnum enumeration) throws IOException { jsonWriter.value(enumeration.getValue()); } @Override public InstrumentTypeEnum read(final JsonReader jsonReader) throws IOException { String value = jsonReader.nextString(); return InstrumentTypeEnum.fromValue(value); } } } public static final String SERIALIZED_NAME_INSTRUMENT_TYPE = "instrumentType"; @SerializedName(SERIALIZED_NAME_INSTRUMENT_TYPE) private InstrumentTypeEnum instrumentType; public InflationSwapAllOf startDate(OffsetDateTime startDate) { this.startDate = startDate; return this; } /** * The start date of the instrument. This is normally synonymous with the trade-date. * @return startDate **/ @ApiModelProperty(required = true, value = "The start date of the instrument. This is normally synonymous with the trade-date.") public OffsetDateTime getStartDate() { return startDate; } public void setStartDate(OffsetDateTime startDate) { this.startDate = startDate; } public InflationSwapAllOf maturityDate(OffsetDateTime maturityDate) { this.maturityDate = maturityDate; return this; } /** * The final maturity date of the instrument. This means the last date on which the instruments makes a payment of any amount. For the avoidance of doubt, that is not necessarily prior to its last sensitivity date for the purposes of risk; e.g. instruments such as Constant Maturity Swaps (CMS) often have sensitivities to rates that may well be observed or set prior to the maturity date, but refer to a termination date beyond it. * @return maturityDate **/ @ApiModelProperty(required = true, value = "The final maturity date of the instrument. This means the last date on which the instruments makes a payment of any amount. For the avoidance of doubt, that is not necessarily prior to its last sensitivity date for the purposes of risk; e.g. instruments such as Constant Maturity Swaps (CMS) often have sensitivities to rates that may well be observed or set prior to the maturity date, but refer to a termination date beyond it.") public OffsetDateTime getMaturityDate() { return maturityDate; } public void setMaturityDate(OffsetDateTime maturityDate) { this.maturityDate = maturityDate; } public InflationSwapAllOf flowConventions(FlowConventions flowConventions) { this.flowConventions = flowConventions; return this; } /** * Get flowConventions * @return flowConventions **/ @ApiModelProperty(required = true, value = "") public FlowConventions getFlowConventions() { return flowConventions; } public void setFlowConventions(FlowConventions flowConventions) { this.flowConventions = flowConventions; } public InflationSwapAllOf fixedRate(java.math.BigDecimal fixedRate) { this.fixedRate = fixedRate; return this; } /** * Fixed Rate * @return fixedRate **/ @ApiModelProperty(required = true, value = "Fixed Rate") public java.math.BigDecimal getFixedRate() { return fixedRate; } public void setFixedRate(java.math.BigDecimal fixedRate) { this.fixedRate = fixedRate; } public InflationSwapAllOf inflationCap(java.math.BigDecimal inflationCap) { this.inflationCap = inflationCap; return this; } /** * Optional cap, needed for LPI swaps. Should not be set for ZCIIS. * @return inflationCap **/ @ApiModelProperty(value = "Optional cap, needed for LPI swaps. Should not be set for ZCIIS.") public java.math.BigDecimal getInflationCap() { return inflationCap; } public void setInflationCap(java.math.BigDecimal inflationCap) { this.inflationCap = inflationCap; } public InflationSwapAllOf inflationFloor(java.math.BigDecimal inflationFloor) { this.inflationFloor = inflationFloor; return this; } /** * Optional floor, needed for LPI swaps. Should not be set for ZCIIS. * @return inflationFloor **/ @ApiModelProperty(value = "Optional floor, needed for LPI swaps. Should not be set for ZCIIS.") public java.math.BigDecimal getInflationFloor() { return inflationFloor; } public void setInflationFloor(java.math.BigDecimal inflationFloor) { this.inflationFloor = inflationFloor; } public InflationSwapAllOf inflationFrequency(String inflationFrequency) { this.inflationFrequency = inflationFrequency; return this; } /** * Frequency of inflation updated. Optional and defaults to Monthly which is the most common. However both Australian and New Zealand inflation is published Quarterly. Only tenors of 1M or 3M are supported. * @return inflationFrequency **/ @ApiModelProperty(value = "Frequency of inflation updated. Optional and defaults to Monthly which is the most common. However both Australian and New Zealand inflation is published Quarterly. Only tenors of 1M or 3M are supported.") public String getInflationFrequency() { return inflationFrequency; } public void setInflationFrequency(String inflationFrequency) { this.inflationFrequency = inflationFrequency; } public InflationSwapAllOf inflationIndexName(String inflationIndexName) { this.inflationIndexName = inflationIndexName; return this; } /** * Name of the Inflation Index * @return inflationIndexName **/ @ApiModelProperty(required = true, value = "Name of the Inflation Index") public String getInflationIndexName() { return inflationIndexName; } public void setInflationIndexName(String inflationIndexName) { this.inflationIndexName = inflationIndexName; } public InflationSwapAllOf inflationInterpolation(String inflationInterpolation) { this.inflationInterpolation = inflationInterpolation; return this; } /** * Inflation Interpolation flag, defaults to Linear but some older swaps require Flat. Supported string (enumeration) values are: [Linear, Flat]. * @return inflationInterpolation **/ @ApiModelProperty(value = "Inflation Interpolation flag, defaults to Linear but some older swaps require Flat. Supported string (enumeration) values are: [Linear, Flat].") public String getInflationInterpolation() { return inflationInterpolation; } public void setInflationInterpolation(String inflationInterpolation) { this.inflationInterpolation = inflationInterpolation; } public InflationSwapAllOf inflationRollDay(Integer inflationRollDay) { this.inflationRollDay = inflationRollDay; return this; } /** * Day of the month that inflation rolls from one month to the next. This is optional and defaults to 1, which is the typically value for the majority of inflation bonds (exceptions include Japan which rolls on the 10th and some LatAm bonds which roll on the 15th). * @return inflationRollDay **/ @ApiModelProperty(value = "Day of the month that inflation rolls from one month to the next. This is optional and defaults to 1, which is the typically value for the majority of inflation bonds (exceptions include Japan which rolls on the 10th and some LatAm bonds which roll on the 15th).") public Integer getInflationRollDay() { return inflationRollDay; } public void setInflationRollDay(Integer inflationRollDay) { this.inflationRollDay = inflationRollDay; } public InflationSwapAllOf notional(java.math.BigDecimal notional) { this.notional = notional; return this; } /** * The notional * @return notional **/ @ApiModelProperty(required = true, value = "The notional") public java.math.BigDecimal getNotional() { return notional; } public void setNotional(java.math.BigDecimal notional) { this.notional = notional; } public InflationSwapAllOf observationLag(String observationLag) { this.observationLag = observationLag; return this; } /** * Observation Lag, must be a number of Months, typically 3 or 4 but sometimes 8. * @return observationLag **/ @ApiModelProperty(required = true, value = "Observation Lag, must be a number of Months, typically 3 or 4 but sometimes 8.") public String getObservationLag() { return observationLag; } public void setObservationLag(String observationLag) { this.observationLag = observationLag; } public InflationSwapAllOf payReceive(String payReceive) { this.payReceive = payReceive; return this; } /** * PayReceive flag for the inflation leg. This field is optional and defaults to Pay. If set to Pay, this swap pays inflation and receives fixed. Supported string (enumeration) values are: [Pay, Receive]. * @return payReceive **/ @ApiModelProperty(value = "PayReceive flag for the inflation leg. This field is optional and defaults to Pay. If set to Pay, this swap pays inflation and receives fixed. Supported string (enumeration) values are: [Pay, Receive].") public String getPayReceive() { return payReceive; } public void setPayReceive(String payReceive) { this.payReceive = payReceive; } public InflationSwapAllOf instrumentType(InstrumentTypeEnum instrumentType) { this.instrumentType = instrumentType; return this; } /** * The available values are: QuotedSecurity, InterestRateSwap, FxForward, Future, ExoticInstrument, FxOption, CreditDefaultSwap, InterestRateSwaption, Bond, EquityOption, FixedLeg, FloatingLeg, BespokeCashFlowsLeg, Unknown, TermDeposit, ContractForDifference, EquitySwap, CashPerpetual, CapFloor, CashSettled, CdsIndex, Basket, FundingLeg, FxSwap, ForwardRateAgreement, SimpleInstrument, Repo, Equity, ExchangeTradedOption, ReferenceInstrument, ComplexBond, InflationLinkedBond, InflationSwap, SimpleCashFlowLoan * @return instrumentType **/ @ApiModelProperty(required = true, value = "The available values are: QuotedSecurity, InterestRateSwap, FxForward, Future, ExoticInstrument, FxOption, CreditDefaultSwap, InterestRateSwaption, Bond, EquityOption, FixedLeg, FloatingLeg, BespokeCashFlowsLeg, Unknown, TermDeposit, ContractForDifference, EquitySwap, CashPerpetual, CapFloor, CashSettled, CdsIndex, Basket, FundingLeg, FxSwap, ForwardRateAgreement, SimpleInstrument, Repo, Equity, ExchangeTradedOption, ReferenceInstrument, ComplexBond, InflationLinkedBond, InflationSwap, SimpleCashFlowLoan") public InstrumentTypeEnum getInstrumentType() { return instrumentType; } public void setInstrumentType(InstrumentTypeEnum instrumentType) { this.instrumentType = instrumentType; } @Override public boolean equals(Object o) { if (this == o) { return true; } if (o == null || getClass() != o.getClass()) { return false; } return true; } @Override public int hashCode() { return super.hashCode(); } @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class InflationSwapAllOf {\n"); sb.append(" startDate: ").append(toIndentedString(startDate)).append("\n"); sb.append(" maturityDate: ").append(toIndentedString(maturityDate)).append("\n"); sb.append(" flowConventions: ").append(toIndentedString(flowConventions)).append("\n"); sb.append(" fixedRate: ").append(toIndentedString(fixedRate)).append("\n"); sb.append(" inflationCap: ").append(toIndentedString(inflationCap)).append("\n"); sb.append(" inflationFloor: ").append(toIndentedString(inflationFloor)).append("\n"); sb.append(" inflationFrequency: ").append(toIndentedString(inflationFrequency)).append("\n"); sb.append(" inflationIndexName: ").append(toIndentedString(inflationIndexName)).append("\n"); sb.append(" inflationInterpolation: ").append(toIndentedString(inflationInterpolation)).append("\n"); sb.append(" inflationRollDay: ").append(toIndentedString(inflationRollDay)).append("\n"); sb.append(" notional: ").append(toIndentedString(notional)).append("\n"); sb.append(" observationLag: ").append(toIndentedString(observationLag)).append("\n"); sb.append(" payReceive: ").append(toIndentedString(payReceive)).append("\n"); sb.append(" instrumentType: ").append(toIndentedString(instrumentType)).append("\n"); sb.append("}"); return sb.toString(); } /** * Convert the given object to string with each line indented by 4 spaces * (except the first line). */ private String toIndentedString(Object o) { if (o == null) { return "null"; } return o.toString().replace("\n", "\n "); } }
[ "concourse@finbourne.com" ]
concourse@finbourne.com
bffc88388415d73ab51b50c7829becae2ebd64e7
95a60c91725b0d3be684505fdb6ee5e7c1f0510a
/yuntu-dpm-curd/src/main/java/com/yuntu/curd/dao/ApplicantMapper.java
96391f4c363322f3fc65547cd58d773b09d2dc09
[]
no_license
myMice/GitCourse
166eb83c35d129055e8a65bef1dc7c9fbd7d2da1
fff3e74ac151d795955f7a910962c783dfe943d4
refs/heads/master
2020-04-28T15:16:26.018281
2019-03-13T08:16:46
2019-03-13T08:16:46
175,367,246
0
0
null
null
null
null
UTF-8
Java
false
false
876
java
package com.yuntu.curd.dao; import com.yuntu.curd.bean.Applicant; import com.yuntu.curd.bean.ApplicantExample; import java.util.List; import org.apache.ibatis.annotations.Param; public interface ApplicantMapper { long countByExample(ApplicantExample example); int deleteByExample(ApplicantExample example); int deleteByPrimaryKey(Integer acId); int insert(Applicant record); int insertSelective(Applicant record); List<Applicant> selectByExample(ApplicantExample example); Applicant selectByPrimaryKey(Integer acId); int updateByExampleSelective(@Param("record") Applicant record, @Param("example") ApplicantExample example); int updateByExample(@Param("record") Applicant record, @Param("example") ApplicantExample example); int updateByPrimaryKeySelective(Applicant record); int updateByPrimaryKey(Applicant record); }
[ "zhanghao_glb@zhang.com" ]
zhanghao_glb@zhang.com
2b29407f29ba3b1a2a17e806150419010ce33d7b
c3101515ddde8a6e6ddc4294a4739256d1600df0
/GeneralApp__2.20_1.0(1)_source_from_JADX/sources/androidx/lifecycle/livedata/core/C1035R.java
0b5699a72c475ffff5898f1147ee31cfaae3e5ed
[]
no_license
Aelshazly/Carty
b56fdb1be58a6d12f26d51b46f435ea4a73c8168
d13f3a4ad80e8a7d0ed1c6a5720efb4d1ca721ee
refs/heads/master
2022-11-14T23:29:53.547694
2020-07-08T19:23:39
2020-07-08T19:23:39
278,175,183
0
0
null
null
null
null
UTF-8
Java
false
false
157
java
package androidx.lifecycle.livedata.core; /* renamed from: androidx.lifecycle.livedata.core.R */ public final class C1035R { private C1035R() { } }
[ "aelshazly@engineer.com" ]
aelshazly@engineer.com
b21dd5eb965a19a36c90ad8b55ce4d862221d6a5
4ea544f8ad52ae1799deb74605c4420ccd8b51b7
/dawncloud-consumer-feign/src/main/java/dawn/cloud/consumer/feign/controller/ConsumerController_Feign.java
0ca86baffd1c5269f324b37823738189b55fc2b8
[]
no_license
classDawn/myTest
e9298a2dc19ddc952e825b52df55d562c6680867
588bb2ddbd231f195f855c875d4cec23f4bf501d
refs/heads/master
2020-04-01T21:06:08.074349
2018-11-18T09:58:33
2018-11-18T09:58:33
153,637,141
0
0
null
2018-11-18T09:58:34
2018-10-18T14:25:19
Java
UTF-8
Java
false
false
1,071
java
package dawn.cloud.consumer.feign.controller; import dawn.cloud.api.entity.Dept; import dawn.cloud.api.service.Dept_FeignService; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; import java.util.List; @SuppressWarnings("SpringJavaInjectionPointsAutowiringInspection") @RestController public class ConsumerController_Feign { @Autowired private Dept_FeignService dept_feignService; @RequestMapping(value = "/consumer/dept/get/{id}") public Dept get(@PathVariable("id") Long id) { return this.dept_feignService.get(id); } /** * * @return */ @RequestMapping(value = "/consumer/dept/list") public List<Dept> list() { return this.dept_feignService.list(); } /** * 注意这个操作 * @param dept * @return */ @RequestMapping(value = "/consumer/dept/add") public Object add(Dept dept) { return this.dept_feignService.add(dept); } }
[ "dawncong@163.com" ]
dawncong@163.com
fc671592862b2125346462ac4d90509caa1727e4
78cc0db2b28aa7aa108791b8ca9b25315b606eea
/20200917_Cinema/src/de/telran/dao/Schedule.java
47e859d0d56c7c90c8539b24d35a9916a0a20f71
[]
no_license
LeSitar/TelRan_13M
3466dca7b909d246b0939755909576534a6a52ff
196cc4186ed66b59d93531bc384afbce900485d1
refs/heads/master
2023-01-04T04:59:04.087720
2020-10-30T13:51:16
2020-10-30T13:51:16
293,464,331
0
0
null
null
null
null
UTF-8
Java
false
false
1,471
java
package de.telran.dao; import de.telran.data.Cinema; import de.telran.data.Film; public class Schedule { private Film[] films; private int size; public Schedule (int capacity){ films = new Film[capacity]; size = 0; } public boolean addFilm(Film film){ if(size<films.length){ films[size] = film; size++; return true; } return false; } public boolean deleteFilm(Film film){ for (int i = 0; i <size ; i++) { if(films[i].equals(film)){ films[i] = films[size-1]; size--; return true; } } return false; } public void displayFilms(){ for (int i = 0; i <size ; i++) { System.out.println(films[i]); } } public void displayFilmsByCinema(String cinema){ System.out.println("In cinema " + cinema + " you can watch: "); boolean flag = false; for (int i = 0; i <size ; i++) { if (Cinema.isCinemaInArray(cinema, films[i].getCinemas())) { System.out.println(films[i].getTitle()+", " + films[i].getGenre() + "\n" + films[i].getDate()); System.out.println("------------------------------------"); flag = true; } } System.out.println(flag ? "":"no information"); // if (!flag){System.out.println("no information")}; } }
[ "lenasitars@gmail.com" ]
lenasitars@gmail.com
fbc149caa951d2587dbf567943f2b25880913a6d
3b12549e4397258ba290c43901a6a384db613e5a
/siyueli-platform-member-server-service/src/main/java/com/siyueli/platform/service/member/server/mapper/customform/param/CustomFieldOptionSearchParam.java
ceb3c1256a848b7d1956feb137bb37aad15a5019
[]
no_license
zhouxhhn/li-member
56fc91fa5e089fe3aee9e7519a1b4f4a98c539bd
54155482e60a364fd04d07fb39b17a39b4f95a6d
refs/heads/master
2020-04-05T10:25:31.586349
2018-11-09T02:25:07
2018-11-09T02:25:07
156,798,261
0
2
null
null
null
null
UTF-8
Java
false
false
150
java
package com.siyueli.platform.service.member.server.mapper.customform.param; import lombok.Data; @Data public class CustomFieldOptionSearchParam { }
[ "joey.zhou@siyue.cn" ]
joey.zhou@siyue.cn
3cb0caeae84782e03ccb3544e9f17656b2433d5c
d026f445934fb9698bc3a2aeffd182fa016d4334
/src/WriterConsole.java
36121c9b24dce90148df78aa74cc3ea457565574
[]
no_license
Partast1/AWebsite
26436a199164c4fdab7ce7eebc1da9988aa24563
a626c9149139d21a17e1d2abf2770db4f85d3260
refs/heads/master
2020-12-27T05:26:26.998816
2020-02-02T14:01:25
2020-02-02T14:01:25
237,779,681
0
0
null
null
null
null
UTF-8
Java
false
false
125
java
public class WriterConsole implements Writable { public void Write(String text){ System.out.print(text); } }
[ "43130360+Partast1@users.noreply.github.com" ]
43130360+Partast1@users.noreply.github.com
c5fb6bc8322cf5afbe806d6b05d1d5476ed44da4
aedc11e687665885561484f55d0f366c8991a0be
/Major Projects/Code Base/src/Data_Structures/Structures/InDevelopment/PriorityQueues/PQNode.java
a6c26b5b6396053f05f3c9a7806486022e272a8b
[]
no_license
phamvanthanh/JavaCode
2675a4a91fe8adfdc747099432de585117e47035
3bc335102b0849b4ceb669e1601683e5ce9743ab
refs/heads/master
2021-08-28T01:10:34.424558
2017-12-11T01:32:11
2017-12-11T01:32:11
null
0
0
null
null
null
null
UTF-8
Java
false
false
429
java
package Data_Structures.Structures.InDevelopment.PriorityQueues; public class PQNode<E> implements Comparable<PQNode<E>> { private int priority; private E elem; public PQNode(E elem, int p) { this.elem = elem; this.priority = p; } @Override public int compareTo(PQNode<E> o) { return priority - o.priority; } public E getElem() { return elem; } public int getPriority() { return priority; } }
[ "bryce@funtheemental.com" ]
bryce@funtheemental.com
c8e399e0f9f0456775fb8b21ee264ce8e0dce679
280f437d94c82656829dcec95dd0b94a385ce957
/autohosts/src/main/java/com/yeyaxi/android/autohosts/UnableToMountSystemException.java
ad5e562faa7c228de7ec0eb35e247206d84168d4
[ "MIT" ]
permissive
0359xiaodong/AutoHosts
d3a84df9d1e858ee269da15cee02db1535be9124
a5c25a20535be681d0253bf0674068100a6dccb8
refs/heads/master
2021-01-16T19:38:56.608460
2014-05-19T16:00:06
2014-05-19T16:00:06
null
0
0
null
null
null
null
UTF-8
Java
false
false
350
java
package com.yeyaxi.android.autohosts; public class UnableToMountSystemException extends Exception { public UnableToMountSystemException (Throwable ex) { super(ex); } public UnableToMountSystemException (String message) { super(message); } public UnableToMountSystemException (String message, Throwable ex) { super(message, ex); } }
[ "ss1271@gmail.com" ]
ss1271@gmail.com
cff006e4f2e362ac2718acd5a791aacef462e922
6f5cf10d234a02063058f9dde4816372b4c1a0b1
/src/main/java/me/goodandevil/skyblock/api/event/player/PlayerDepositMoneyEvent.java
7d7a377c63c22b358b5018f3cc48b8ca8cbe8c26
[]
no_license
Kaesong-Nan/SkyBlockEarth-1
5487efde7e8d21a1ec1cb0d9657be5e3454da0f9
0c3aeece541009c66a284c1e69cad831f3258af4
refs/heads/master
2022-06-03T03:20:35.670646
2019-01-04T03:23:10
2019-01-04T03:23:10
null
0
0
null
null
null
null
UTF-8
Java
false
false
692
java
package me.goodandevil.skyblock.api.event.player; import org.bukkit.OfflinePlayer; import org.bukkit.event.Event; import org.bukkit.event.HandlerList; public class PlayerDepositMoneyEvent extends Event { private static final HandlerList HANDLERS = new HandlerList(); private OfflinePlayer player; private double money; public PlayerDepositMoneyEvent(OfflinePlayer player, double money) { this.player = player; this.money = money; } public OfflinePlayer getPlayer() { return player; } public double getMoney() { return money; } @Override public HandlerList getHandlers() { return HANDLERS; } public static HandlerList getHandlerList() { return HANDLERS; } }
[ "itsgoodandevil@gmail.com" ]
itsgoodandevil@gmail.com
1bc4cb40cc7d31d3eafc3bc79b03078c2e31743e
f329bcdcc0cdd9021d237bbe7c3e7f0858b54305
/src/functionalInterface/examples/TokenValidator.java
1ae5a9a6ad83fc5f12bd1c6c8ef441c1ff2f7485
[]
no_license
wangchen0511/jdk8_simple_examples
4bb2fcbcd4fee98ffb9889cf6637a07631c20c14
5298b29c898401f356ba664f2b76d5e1a046dcf7
refs/heads/master
2021-01-10T01:34:07.741845
2015-05-25T19:08:34
2015-05-25T19:08:34
36,045,897
0
0
null
null
null
null
UTF-8
Java
false
false
138
java
package functionalInterface.examples; @FunctionalInterface public interface TokenValidator { public boolean isValid(String num); }
[ "adam701@yahoo-inc.com" ]
adam701@yahoo-inc.com
edfe8be7f4e29ea679714decc7185c9098bb1c9d
97a01bd65eacb43b95e1bd2812bb06ac7f6d4cf5
/src/Window.java
e7a75615a1eb7811031711b89b099c12a44b0310
[]
no_license
vladimir07/Git
849f72c777a4f40f8d4b122eed6efa3ed9ff7339
03622a45fb85a2445dba9eb5f1ff7585eaebf515
refs/heads/master
2021-01-19T15:40:42.818409
2015-07-08T15:27:28
2015-07-08T15:27:28
38,199,549
0
0
null
null
null
null
UTF-8
Java
false
false
2,113
java
import javax.swing.*; import java.awt.*; import java.awt.event.*; public class Window extends JFrame { JButton b1, b2; JLabel l1, l2, l3, l4; JTextField t1, t2; String a, b; int i, k; eHandler handler = new eHandler(); public Window(String s) { super(s); setLayout(new FlowLayout()); b1 = new JButton("Очистить"); b2 = new JButton("Посчитать"); l1 = new JLabel("Введите первое число: "); l2 = new JLabel("Введите второе число: "); l3 = new JLabel(""); l4 = new JLabel(""); t1 = new JTextField(10); t2 = new JTextField(10); add(b1); add(b2); add(l1); add(t1); add(l2); add(t2); add(l3); add(l4); b2.addActionListener(handler); b1.addActionListener(handler); } public class eHandler implements ActionListener { @Override public void actionPerformed(ActionEvent e) { try { if (e.getSource() == b2) {//если источник события(e.getSource()=нашей кнопке(b2)) i = Integer.parseInt(t1.getText());//i=отображение всего того что введено в поле 1(t1) k = Integer.parseInt(t2.getText());//k=отображение всего того что введено в поле 2(t2) i++; k++; a = "Ваше первое число теперь равно: " + i; b = "Ваше второе число теперь равно: " + k; l3.setText(a); l4.setText(b); } if (e.getSource() == b1) { t1.setText(null); t2.setText(null); l3.setText(null); l4.setText(null); } }catch (Exception ex){JOptionPane.showMessageDialog(null,"Bведите число!");} } } }
[ "vladimir0771@mail.ru" ]
vladimir0771@mail.ru
0a2abb1ef97701ae442b0b6b9bdc6f7c6fc43441
1e044d9cb8db63ccb847f04fa39a6dd25fc47eff
/src/main/java/com/trailblazer/api/core/rest/services/CommonService.java
354d55628958d8781d8e9c555302ebfd4c4010b9
[]
no_license
ejunika/trailblazer
f85b5e5ebfe8ee2a527315ed32adba787443a313
5cf74a5807a3edd720f70e781aee81808a40c9d4
refs/heads/master
2020-03-19T04:07:52.593650
2018-06-03T19:45:45
2018-06-03T19:45:45
135,797,357
0
0
null
null
null
null
UTF-8
Java
false
false
1,227
java
package com.trailblazer.api.core.rest.services; import java.util.List; import javax.jws.WebService; import javax.ws.rs.Consumes; import javax.ws.rs.DELETE; import javax.ws.rs.GET; import javax.ws.rs.POST; import javax.ws.rs.PUT; import javax.ws.rs.Path; import javax.ws.rs.PathParam; import javax.ws.rs.Produces; import javax.ws.rs.QueryParam; import javax.ws.rs.core.MediaType; import javax.ws.rs.core.Response; /** * @author M A AKHTAR * * @param <E> */ @WebService @Consumes(MediaType.APPLICATION_JSON) @Produces(MediaType.APPLICATION_JSON) public interface CommonService<E> { /** * @param offset * @param limit * @param rsl * @return */ @GET @Path("/") Response get(@QueryParam("offset") Integer offset, @QueryParam("limit") Integer limit, @QueryParam("rsl") List<Byte> rsl); /** * @param entity * @return */ @POST @Path("/") Response post(E entity); /** * @param id * @return */ @GET @Path("/{id}") Response get(@PathParam("id") Long id); /** * @param id * @return */ @DELETE @Path("/{id}") Response delete(@PathParam("id") Long id); /** * @param id * @param entity * @return */ @PUT @Path("/{id}") Response put(@PathParam("id") Long id, E entity); }
[ "azaz.akhtar@powerschool.com" ]
azaz.akhtar@powerschool.com
04ae6b7a1b675635e2e0d033fd82161fe45ca352
55d02c02c657aff638c62f7404f0eca31b4ff65e
/src/main/java/cucumberbase/AddcustSuccess.java
f7b4620dd9f025d0fe11ce8953ec668c9f2115ab
[]
no_license
naveenkumar15/Cucumber2
dd7db6fcbc28f65c879574e923b6e89f9a0316e8
7be9bb0c66e785a427873cf1611def6ff1460b6c
refs/heads/master
2020-04-30T02:50:16.601919
2019-03-27T11:40:18
2019-03-27T11:40:18
176,571,101
0
0
null
null
null
null
UTF-8
Java
false
false
616
java
package cucumberbase; import org.openqa.selenium.WebElement; import org.openqa.selenium.support.FindBy; import org.openqa.selenium.support.PageFactory; public class AddcustSuccess extends Basecucum { public AddcustSuccess() { PageFactory.initElements(driver, this); } @FindBy(xpath = "//b[text()='Customer ID']") private static WebElement Customerid; @FindBy(xpath = "//b[text()='Please Note Down Your CustomerID']") private static WebElement CustSucessmsg; public static WebElement getCustomerid() { return Customerid; } public static WebElement getCustSucessmsg() { return CustSucessmsg; } }
[ "navinag63@gmail.com" ]
navinag63@gmail.com
cd32eeb82ea5193c94f4a988ee0ac45c40f2a903
34b98f4569876c0bc812f7ce14eb67be85540b53
/app/src/main/java/tn/itskills/android/firebase/models/User.java
6820e9de5b194baf65c47f7eb99b7f02d2249edf
[]
no_license
imenkarray/codenite-tutorial-android-firebase
e3e55c7902c4f73ba2a376bc3c5cc565d297553a
ba079de52c7583312711cbe8772f1b2540b668ca
refs/heads/master
2021-01-22T14:29:15.756001
2016-05-28T20:29:23
2016-05-28T20:29:23
null
0
0
null
null
null
null
UTF-8
Java
false
false
252
java
package tn.itskills.android.firebase.models; /** * Created by adnenhamdouni on 24/05/2016. */ public class User { public String username; public User() { } public User(String username) { this.username = username; } }
[ "adnen.hamdouni@gmail.com" ]
adnen.hamdouni@gmail.com
840070a039c008346150280d1c92295a6fc3a494
f11090a59e184260b149d3203b88d6a53e36a1e6
/src/java/Modelo/Apartamento.java
fcfba9c75d78d510229810de860cca8dea6b7931
[]
no_license
Cristian18Salamanca/ProyectoCasaGrande
059bff79f76e065b52e4ad3be55be96ddea0d2e0
eb36067d79cea4e1da21671e0d8aa53057a2e4b8
refs/heads/master
2023-01-23T01:04:46.583797
2020-12-07T21:34:47
2020-12-07T21:34:47
319,445,965
0
0
null
null
null
null
UTF-8
Java
false
false
1,178
java
/* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ package Modelo; public class Apartamento { int id; String apa; String due; int per; int mas; int tel; public Apartamento() { } public Apartamento(String apa, String due) { this.apa = apa; this.due = due; } public int getId() { return id; } public void setId(int id) { this.id = id; } public String getApa() { return apa; } public void setApa(String apa) { this.apa = apa; } public String getDue() { return due; } public void setDue(String due) { this.due = due; } public int getPer() { return per; } public void setPer(int per) { this.per = per; } public int getMas() { return mas; } public void setMas(int mas) { this.mas = mas; } public int getTel() { return tel; } public void setTel(int tel) { this.tel = tel; } }
[ "cristian.santiago731@gmail.com" ]
cristian.santiago731@gmail.com
12209af4542410ec63e1b5acafcb5b0ce1f359b0
9ef5324c8b7bc176a781f7b3512832ac8436da7c
/src/main/java/es/uji/giant/Serena/controller/GetController.java
e3f87af8e154f84284910afe5dacacc969a5eced
[]
no_license
FCT-18-13677/Serena
9251064ace647cbf911675a24542018fbc9242d9
8829a388c94d22856db641fbc41f76e1cca6e8b0
refs/heads/master
2023-06-08T21:08:47.805647
2023-06-05T12:56:11
2023-06-05T12:56:11
245,984,903
0
1
null
2022-09-20T14:26:30
2020-03-09T08:47:32
Java
UTF-8
Java
false
false
868
java
package es.uji.giant.Serena.controller; import es.uji.giant.Serena.model.Questionnarie; import es.uji.giant.Serena.repository.QuestionnarieDao; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.http.MediaType; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.ResponseBody; import org.springframework.web.bind.annotation.RestController; import java.util.List; @RestController public class GetController { private Logger logger = LoggerFactory.getLogger(this.getClass()); @GetMapping(value = "/getQuestionnaries", produces = MediaType.APPLICATION_JSON_VALUE) public @ResponseBody List<Questionnarie> getQuestionnaries () { logger.info("Se solicitan todos los cuestionarios realizados"); return QuestionnarieDao.getAllQuestionnaries(); } }
[ "a.gascocompte@gmail.com" ]
a.gascocompte@gmail.com
98aae5de51d6ec8b9d1c7bfaaa62558929fc1c5e
e544d41ec9f3f01e5fd3cbdebf1285cb00d2d4ab
/src/com/servlets/filters/AuthenticationFilter.java
cc0bba5ca160a93937138a9863a38fbac0919f21
[]
no_license
rishabhkashyap/ServletFilterExample
4d5e7e8a190aef93efa09bb01ea544cdf451a752
f6125808a011095829113cf0856d1bc6dbde10f7
refs/heads/master
2021-01-10T05:14:22.761620
2016-04-04T04:06:00
2016-04-04T04:06:00
55,384,126
0
0
null
null
null
null
UTF-8
Java
false
false
1,768
java
package com.servlets.filters; import java.io.IOException; import javax.servlet.Filter; import javax.servlet.FilterChain; import javax.servlet.FilterConfig; import javax.servlet.ServletContext; import javax.servlet.ServletException; import javax.servlet.ServletRequest; import javax.servlet.ServletResponse; import javax.servlet.annotation.WebFilter; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpSession; /** * Servlet Filter implementation class AuthenticationFilter */ @WebFilter("/AuthenticationFilter") public class AuthenticationFilter implements Filter { /** * Default constructor. */ public AuthenticationFilter() { // TODO Auto-generated constructor stub } /** * @see Filter#destroy() */ public void destroy() { // TODO Auto-generated method stub } /** * @see Filter#doFilter(ServletRequest, ServletResponse, FilterChain) */ public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain) throws IOException, ServletException { HttpServletRequest req = (HttpServletRequest) request; HttpServletResponse res = (HttpServletResponse) response; String uri = req.getRequestURI(); System.out.println("Requested Resource::" + uri); HttpSession session = req.getSession(false); if (session == null && !(uri.endsWith("jsp") || uri.endsWith("LoginServlet"))) { System.out.println("Unauthorized access request"); res.sendRedirect("index.jsp"); } else { // pass the request along the filter chain chain.doFilter(request, response); } } /** * @see Filter#init(FilterConfig) */ public void init(FilterConfig fConfig) throws ServletException { // TODO Auto-generated method stub } }
[ "kashyap.rishab@hotmail.com" ]
kashyap.rishab@hotmail.com
486bc8045a88f557f1050b850a76dc45132773f9
c3baaa56e9ba4801f58daa5e9e11e98060acdb84
/src/Patient.java
7f4fabd7b36f3d6b7e8e3b1c9d14546432b47b75
[]
no_license
reubenpuketapu/GeneticProgramming
140e5aa11be828f05509d8df95d4ccdf32b13cb7
b34872b4d0d46b366d8b39d1828f60333d60d12b
refs/heads/master
2020-12-31T05:09:37.586582
2016-05-07T01:31:08
2016-05-07T01:31:08
58,243,653
0
0
null
null
null
null
UTF-8
Java
false
false
1,609
java
public class Patient { private int id; private int clumpThick; private int cellSize; private int cellShape; private int mAdhesion; private int epSize; private int bNucl; private int blChrom; private int nNucl; private int mitos; private int classed; public Patient(int id, int clumpThick, int cellSize, int cellShape, int mAdhesion, int epSize, int bNucl, int blChrom, int nNucl, int mitos, int classed) { this.id = id; this.clumpThick = clumpThick; this.cellSize = cellSize; this.cellShape = cellShape; this.mAdhesion = mAdhesion; this.epSize = epSize; this.bNucl = bNucl; this.blChrom = blChrom; this.nNucl = nNucl; this.mitos = mitos; this.classed = classed; } /** * @return the id */ public int getId() { return id; } /** * @return the clumpThick */ public int getClumpThick() { return clumpThick; } /** * @return the cellSize */ public int getCellSize() { return cellSize; } /** * @return the cellShape */ public int getCellShape() { return cellShape; } /** * @return the mAdhesion */ public int getmAdhesion() { return mAdhesion; } /** * @return the epSize */ public int getEpSize() { return epSize; } /** * @return the bNucl */ public int getbNucl() { return bNucl; } /** * @return the blChrom */ public int getBlChrom() { return blChrom; } /** * @return the nNucl */ public int getnNucl() { return nNucl; } /** * @return the mitos */ public int getMitos() { return mitos; } /** * @return the classed */ public int getClassed() { return classed; } }
[ "reuben.puketapu@gmail.com" ]
reuben.puketapu@gmail.com
eb07a8d1399663da1cbfaeaebeaa3131e7928813
513160b7f29f493afc6d6aac8b2560fc6d020785
/newapp/src/main/java/com/mobiletrain/newapp/fragment/main/FindFragment.java
2a80cee1f4f788aeff21d82b00caf13080d92ec1
[]
no_license
ouyangsuo/QQMusicClient
ef52b049609b5948acaa9d53b0c981fcaee065df
35df357d7ce0298423751e9860f1235c105d58ec
refs/heads/master
2021-01-20T01:18:00.009548
2017-01-04T07:52:28
2017-01-04T07:52:28
77,988,233
0
0
null
null
null
null
UTF-8
Java
false
false
679
java
package com.mobiletrain.newapp.fragment.main; import android.os.Bundle; import android.support.annotation.Nullable; import android.support.v4.app.Fragment; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import com.mobiletrain.newapp.R; /** * Created by idea on 2016/10/9. */ public class FindFragment extends Fragment { private View view; @Override public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) { if (view == null) { view = inflater.inflate(R.layout.fragment_find, container, false); } return view; } }
[ "284577461@qq.com" ]
284577461@qq.com
de0d948473ae3266ebb42637b66f2b57dc102245
9a474ca5b0649fbfd510c3c38f344d20e07cd343
/sports_web/sports-service/src/main/java/com/efida/sports/service/impl/GoodsServiceImpl.java
2c6ab1772a26977cdd6c44bb019fbf8d8fe6a84a
[]
no_license
lqdcanty/znty
8c8d1468bbc7d365708c166800e1fdbef464f96b
f2175d9adc823e33b04444b32b526ce82e054273
refs/heads/master
2020-05-13T19:13:45.738087
2019-04-16T09:04:09
2019-04-16T09:04:09
181,652,152
0
0
null
null
null
null
UTF-8
Java
false
false
1,487
java
package com.efida.sports.service.impl; import java.util.List; import java.util.Map; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import com.baomidou.mybatisplus.mapper.EntityWrapper; import com.baomidou.mybatisplus.mapper.Wrapper; import com.baomidou.mybatisplus.plugins.Page; import com.baomidou.mybatisplus.service.impl.ServiceImpl; import com.efida.sports.entity.Goods; import com.efida.sports.mapper.GoodsMapper; import com.efida.sports.service.IGoodsService; @Service public class GoodsServiceImpl extends ServiceImpl<GoodsMapper, Goods> implements IGoodsService { private static Logger log = LoggerFactory.getLogger(GoodsServiceImpl.class); @Autowired private GoodsMapper goodsMapper; @Override public Goods getGoodsByCode(String goodsCode) { Wrapper<Goods> wrapper = new EntityWrapper<Goods>(); wrapper.eq("goods_code", goodsCode); Goods goods = selectOne(wrapper); return goods; } @Override public Goods getGoodsByMatchCode(String matchCode) { Wrapper<Goods> wrapper = new EntityWrapper<Goods>(); wrapper.eq("match_code", matchCode); Goods goods = selectOne(wrapper); return goods; } @Override public List<Goods> selectGoods(Page<Goods> goods, Map<String, Object> params) { return goodsMapper.selectGoods(goods, params); } }
[ "lqdcanty@163.com" ]
lqdcanty@163.com
14ba58f34572c8bcc1bae42f6f0c340e617be336
aacb653f992a167a50f6e8d544860e4fcc97ef2e
/e3-manager/e3-manager-pojo/src/main/java/cn/e3mall/pojo/TbContent.java
21f48a1b500e16d573cbcb3c8cff191c803188e6
[]
no_license
zhuguiwei/e3-parent
6d3a605f4db7845ceafb3cf14f84b95990b22e2e
cb338a2a42930148c9bc9039764176d69783cf9d
refs/heads/master
2020-03-06T22:46:06.715658
2018-03-28T08:59:26
2018-03-28T08:59:26
127,112,620
0
0
null
null
null
null
UTF-8
Java
false
false
2,822
java
package cn.e3mall.pojo; import java.util.Date; public class TbContent { private Long id; private Long categoryId; private String title; private String subTitle; private String titleDesc; private String url; private String pic; private String pic2; private Date created; private Date updated; private String content; public TbContent(Long id, Long categoryId, String title, String subTitle, String titleDesc, String url, String pic, String pic2, Date created, Date updated, String content) { this.id = id; this.categoryId = categoryId; this.title = title; this.subTitle = subTitle; this.titleDesc = titleDesc; this.url = url; this.pic = pic; this.pic2 = pic2; this.created = created; this.updated = updated; this.content = content; } public TbContent() { super(); } public Long getId() { return id; } public void setId(Long id) { this.id = id; } public Long getCategoryId() { return categoryId; } public void setCategoryId(Long categoryId) { this.categoryId = categoryId; } public String getTitle() { return title; } public void setTitle(String title) { this.title = title == null ? null : title.trim(); } public String getSubTitle() { return subTitle; } public void setSubTitle(String subTitle) { this.subTitle = subTitle == null ? null : subTitle.trim(); } public String getTitleDesc() { return titleDesc; } public void setTitleDesc(String titleDesc) { this.titleDesc = titleDesc == null ? null : titleDesc.trim(); } public String getUrl() { return url; } public void setUrl(String url) { this.url = url == null ? null : url.trim(); } public String getPic() { return pic; } public void setPic(String pic) { this.pic = pic == null ? null : pic.trim(); } public String getPic2() { return pic2; } public void setPic2(String pic2) { this.pic2 = pic2 == null ? null : pic2.trim(); } public Date getCreated() { return created; } public void setCreated(Date created) { this.created = created; } public Date getUpdated() { return updated; } public void setUpdated(Date updated) { this.updated = updated; } public String getContent() { return content; } public void setContent(String content) { this.content = content == null ? null : content.trim(); } }
[ "1358256989@qq.com" ]
1358256989@qq.com
9fb943038c12f2a36db43780ae5868ba6e9419a5
1f1c3a575c165f7906b59fa69aca24385ab98b34
/app/src/main/java/com/jay/six/ui/activity/SettingsActivity.java
934e76111ce6ba46b6cf3a9b5f9ddf2cbba7e703
[]
no_license
Rainszz/Six
cd905b3c72f54550243a173d1ec6fbed602f48b5
b1bfeb2c9e50dd3e06b96259b4cbd7aa3a899426
refs/heads/master
2021-01-22T05:42:39.936235
2017-05-19T03:34:27
2017-05-19T03:34:27
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,492
java
package com.jay.six.ui.activity; import android.os.Bundle; import android.support.annotation.Nullable; import android.view.View; import android.widget.Button; import android.widget.LinearLayout; import com.jay.six.R; import com.jay.six.common.BaseActivity; import com.jay.six.common.Constants; import com.jay.six.common.manager.PreferencesManager; import butterknife.BindView; import butterknife.ButterKnife; import butterknife.OnClick; import cn.bmob.v3.BmobUser; public class SettingsActivity extends BaseActivity { @BindView(R.id.layout_update) LinearLayout layoutUpdate; @BindView(R.id.btn_loginout) Button btnLoginout; @Override protected void onCreate(@Nullable Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_settings); ButterKnife.bind(this); setRightVisibility(View.GONE); setTitle(getString(R.string.setting)); } @OnClick({R.id.layout_update, R.id.btn_loginout}) public void onViewClicked(View view) { switch (view.getId()) { case R.id.layout_update: break; case R.id.btn_loginout: loginout(); break; } } private void loginout() { BmobUser.logOut(SettingsActivity.this); //清除缓存用户对象 PreferencesManager.getInstance(SettingsActivity.this).put(Constants.IS_LOGIN, false); SettingsActivity.this.finish(); } }
[ "jayliu1989@live.cn" ]
jayliu1989@live.cn
d7f643b1e7e7d6dddcdf341eefbaeae757541b6d
a260bb852893fe847c8af387b1e117b7e1f84962
/qcm.edit/src-gen/qcm/provider/ReponseItemProvider.java
bb5e57e705a42407842ee1a0f990a7790726b688
[]
no_license
mollah96/qcm
f7ec1e1cbda072453e8295fc3721d4766aae3fd5
f81fa9644e93359639bfc23eb37d43deeaecd018
refs/heads/master
2020-12-12T03:18:54.548748
2020-01-15T08:06:45
2020-01-15T08:06:45
234,029,220
0
0
null
null
null
null
UTF-8
Java
false
false
5,247
java
/** */ package qcm.provider; import java.util.Collection; import java.util.List; import org.eclipse.emf.common.notify.AdapterFactory; import org.eclipse.emf.common.notify.Notification; import org.eclipse.emf.common.util.ResourceLocator; import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; import org.eclipse.emf.edit.provider.IItemLabelProvider; import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; import org.eclipse.emf.edit.provider.IItemPropertySource; import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; import org.eclipse.emf.edit.provider.ITreeItemContentProvider; import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; import org.eclipse.emf.edit.provider.ItemProviderAdapter; import org.eclipse.emf.edit.provider.ViewerNotification; import qcm.QcmPackage; import qcm.Reponse; /** * This is the item provider adapter for a {@link qcm.Reponse} object. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public class ReponseItemProvider extends ItemProviderAdapter implements IEditingDomainItemProvider, IStructuredItemContentProvider, ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { /** * This constructs an instance from a factory and a notifier. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public ReponseItemProvider(AdapterFactory adapterFactory) { super(adapterFactory); } /** * This returns the property descriptors for the adapted class. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @Override public List<IItemPropertyDescriptor> getPropertyDescriptors(Object object) { if (itemPropertyDescriptors == null) { super.getPropertyDescriptors(object); addDataPropertyDescriptor(object); addValuePropertyDescriptor(object); } return itemPropertyDescriptors; } /** * This adds a property descriptor for the Data feature. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ protected void addDataPropertyDescriptor(Object object) { itemPropertyDescriptors .add(createItemPropertyDescriptor(((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(), getResourceLocator(), getString("_UI_Reponse_data_feature"), getString("_UI_PropertyDescriptor_description", "_UI_Reponse_data_feature", "_UI_Reponse_type"), QcmPackage.Literals.REPONSE__DATA, true, false, false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null)); } /** * This adds a property descriptor for the Value feature. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ protected void addValuePropertyDescriptor(Object object) { itemPropertyDescriptors .add(createItemPropertyDescriptor(((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(), getResourceLocator(), getString("_UI_Reponse_value_feature"), getString("_UI_PropertyDescriptor_description", "_UI_Reponse_value_feature", "_UI_Reponse_type"), QcmPackage.Literals.REPONSE__VALUE, true, false, false, ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE, null, null)); } /** * This returns Reponse.gif. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @Override public Object getImage(Object object) { return overlayImage(object, getResourceLocator().getImage("full/obj16/Reponse")); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @Override protected boolean shouldComposeCreationImage() { return true; } /** * This returns the label text for the adapted class. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @Override public String getText(Object object) { String label = ((Reponse) object).getData(); return label == null || label.length() == 0 ? getString("_UI_Reponse_type") : getString("_UI_Reponse_type") + " " + label; } /** * This handles model notifications by calling {@link #updateChildren} to update any cached * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @Override public void notifyChanged(Notification notification) { updateChildren(notification); switch (notification.getFeatureID(Reponse.class)) { case QcmPackage.REPONSE__DATA: case QcmPackage.REPONSE__VALUE: fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); return; } super.notifyChanged(notification); } /** * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children * that can be created under this object. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @Override protected void collectNewChildDescriptors(Collection<Object> newChildDescriptors, Object object) { super.collectNewChildDescriptors(newChildDescriptors, object); } /** * Return the resource locator for this item provider's resources. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @Override public ResourceLocator getResourceLocator() { return QcmEditPlugin.INSTANCE; } }
[ "cheikh.fall@insa-rennes.fr" ]
cheikh.fall@insa-rennes.fr
b22363eae3dc339498cd59c67b98641810833afc
ab64dd5bf47640834914dd1226460223d18e0dd7
/src/local/charles/module/ws/ManagerException_Exception.java
a65eda5e46c36593de9e5e5ce3a09de7d6593b75
[]
no_license
dchdch1234/DSMManager
04ec3ad78ad5f11782ff77be12fddc0fdd2d6298
04ba322f48941b047847fbc6ec6d7c8789420caa
refs/heads/master
2021-03-12T22:23:26.736041
2015-05-24T13:59:31
2015-05-24T13:59:31
34,212,533
0
0
null
null
null
null
UTF-8
Java
false
false
1,103
java
package local.charles.module.ws; import javax.xml.ws.WebFault; /** * This class was generated by the JAX-WS RI. * JAX-WS RI 2.1.6 * Generated source version: 2.1 * */ @WebFault(name = "fault", targetNamespace = "urn:Manager") public class ManagerException_Exception extends Exception { /** * Java type that goes as soapenv:Fault detail element. * */ private ManagerException faultInfo; /** * * @param message * @param faultInfo */ public ManagerException_Exception(String message, ManagerException faultInfo) { super(message); this.faultInfo = faultInfo; } /** * * @param message * @param faultInfo * @param cause */ public ManagerException_Exception(String message, ManagerException faultInfo, Throwable cause) { super(message, cause); this.faultInfo = faultInfo; } /** * * @return * returns fault bean: local.charles.module.ws.ManagerException */ public ManagerException getFaultInfo() { return faultInfo; } }
[ "dchdc@Charles" ]
dchdc@Charles
f77dbd86776778c926a8823d69cd697a7d7385be
5d3fb53f8021b90e397214c1caf74e288b711ff8
/KotlinTutorial/app/src/main/java/JavaService.java
4f54dc35b5e5c5c0a4974a4b0dc28b75c2138a72
[]
no_license
anamica08/Android-Kotlin-Training
2c2815a6189d24b6ad150d7dfd685fa10f5e831e
7683d1df00743c22321c487efc54858986a5f7c5
refs/heads/master
2022-12-09T03:50:38.413650
2020-09-07T16:44:09
2020-09-07T16:44:09
279,930,870
0
0
null
null
null
null
UTF-8
Java
false
false
351
java
//this is java class public class JavaService { public static void fun(){ System.out.print("hello from JAVA!!!"); } private Integer hopeQuotient; public Integer getHopeQuotient() { return hopeQuotient; } public void setHopeQuotient(Integer hopeQuotient) { this.hopeQuotient = hopeQuotient; } }
[ "anamika@nagarro.com" ]
anamika@nagarro.com
7d9675e133c9c37a39e92a9c80b8afc719c787be
aa65ba75852735fadd7c113d32527b257f3afb6f
/components/identity/org.wso2.carbon.identity.provider/src/main/java/org/wso2/carbon/identity/provider/internal/IdentityProviderServiceComponent.java
e7d9bf3bbc489a2418bb271f5aade4ae8d43fcef
[]
no_license
Cloudxtreme/platform-3
0f2853c44604a07380de86abaad695b8744f990b
28e34d628dd4c5990b16604a5ec9aeb23be177ae
refs/heads/master
2021-05-29T14:40:32.621959
2012-12-03T12:15:43
2012-12-03T12:15:43
null
0
0
null
null
null
null
UTF-8
Java
false
false
8,148
java
/* * Copyright 2004,2005 The Apache Software Foundation. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.wso2.carbon.identity.provider.internal; import org.apache.axis2.context.ConfigurationContext; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; import org.openid4java.server.ServerAssociationStore; import org.osgi.service.component.ComponentContext; import org.wso2.carbon.identity.core.util.IdentityUtil; import org.wso2.carbon.identity.provider.IdentityAttributeService; import org.wso2.carbon.identity.provider.IdentityAttributeServiceStore; import org.wso2.carbon.identity.provider.IdentityProviderUtil; import org.wso2.carbon.identity.provider.openid.CarbonServerAssociationStore; import org.wso2.carbon.registry.core.service.RegistryService; import org.wso2.carbon.user.core.UserRealm; import org.wso2.carbon.user.core.service.RealmService; import org.wso2.carbon.utils.ConfigurationContextService; /** * @scr.component name="identity.provider.component" immediate="true" * @scr.reference name="registry.service" * interface="org.wso2.carbon.registry.core.service.RegistryService" * cardinality="1..1" policy="dynamic" bind="setRegistryService" * unbind="unsetRegistryService" * @scr.reference name="config.context.service" * interface="org.wso2.carbon.utils.ConfigurationContextService" cardinality="1..1" * policy="dynamic" bind="setConfigurationContextService" * unbind="unsetConfigurationContextService" * @scr.reference name="user.realmservice.default" interface="org.wso2.carbon.user.core.service.RealmService" * cardinality="1..1" policy="dynamic" bind="setRealmService" * unbind="unsetRealmService" * @scr.reference name="identity.core.util.service" * interface="org.wso2.carbon.identity.core.util.IdentityUtil" cardinality="1..1" * policy="dynamic" bind="setIdentityUtil" unbind="unsetIdentityUtil" * @scr.reference name="identity.attribute.service" * interface="org.wso2.carbon.identity.provider.IdentityAttributeService" * cardinality="0..n" policy="dynamic" bind="addAttributeService" * unbind="removeAttributeService" */ public class IdentityProviderServiceComponent { private static Log log = LogFactory.getLog(IdentityProviderServiceComponent.class); private static ConfigurationContext configContext; private static RealmService realmService; private static RegistryService registryService; private static ServerAssociationStore associationStore; public static RealmService getRealmService() { return realmService; } /** * */ public IdentityProviderServiceComponent() { } /** * * @param ctxt */ protected void activate(ComponentContext ctxt) { if (log.isDebugEnabled()) { log.info("Identity Provider bundle is activated"); } try { ctxt.getBundleContext().registerService(IdentityProviderUtil.class.getName(), new IdentityProviderUtil(), null); associationStore = new CarbonServerAssociationStore(); } catch (Throwable e) { log.error("Failed to initialize Identity Provider", e); } } /** * * @param ctxt */ protected void deactivate(ComponentContext ctxt) { if (log.isDebugEnabled()) { log.info("Identity Provider bundle is deactivated"); } } /** * * @param registryService */ protected void setRegistryService(RegistryService registryService) { this.registryService = registryService; if (log.isDebugEnabled()) { log.info("RegistryService set in Identity Provider bundle"); } } /** * * @param registryService */ protected void unsetRegistryService(RegistryService registryService) { this.registryService = null; if (log.isDebugEnabled()) { log.info("RegistryService unset in Identity Provider bundle"); } } /** * * @param userRealmDelegating */ protected void unsetUserRealmDelegating(UserRealm userRealmDelegating) { if (log.isDebugEnabled()) { log.info("DelegatingUserRealm set in Identity Provider bundle"); } } /** * * @param userRealmDefault */ protected void unsetUserRealmDefault(UserRealm userRealmDefault) { if (log.isDebugEnabled()) { log.info("DefaultUserRealm unset in Identity Provider bundle"); } } /** * * @param realmService */ protected void setRealmService(RealmService realmService){ if(log.isDebugEnabled()){ log.info("ReleamService is set in Identity Provider Service Bundle"); } this.realmService = realmService; } /** * * @param realmService */ protected void unsetRealmService(RealmService realmService){ if (log.isDebugEnabled()) { log.info("ReleamService is unset in Identity Provider Service Bundle"); } } protected void addAttributeService(IdentityAttributeService attributeService) { if (log.isDebugEnabled()) { log.info("IdentityAttributeService added in Identity Provider bundle"); } IdentityAttributeServiceStore.addAttributeService(attributeService); } /** * * @param attributeService */ protected void removeAttributeService(IdentityAttributeService attributeService) { if (log.isDebugEnabled()) { log.info("IdentityAttributeService removed in Identity Provider bundle"); IdentityAttributeServiceStore.removeAttributeService(attributeService); } } /** * * @param contextService */ protected void setConfigurationContextService(ConfigurationContextService contextService) { if (log.isDebugEnabled()) { log.info("ConfigurationContextService set in Identity Provider bundle"); } configContext = contextService.getServerConfigContext(); } /** * * @param contextService */ protected void unsetConfigurationContextService(ConfigurationContextService contextService) { if (log.isDebugEnabled()) { log.info("ConfigurationContextService unset in Identity Provider bundle"); } } /** * * @param identityUtil */ protected void setIdentityUtil(IdentityUtil identityUtil) { if (log.isDebugEnabled()) { log.info("IdentityUtil set in Identity Provider bundle"); } } /** * * @param identityUtil */ protected void unsetIdentityUtil(IdentityUtil identityUtil) { if (log.isDebugEnabled()) { log.info("IdentityUtil unset in Identity Provider bundle"); } } /** * * @return */ public static ConfigurationContext getConfigContext() { return configContext; } public static RegistryService getRegistryService(){ return registryService; } public static ServerAssociationStore getAssociationStore() { return associationStore; } }
[ "hasini@a5903396-d722-0410-b921-86c7d4935375" ]
hasini@a5903396-d722-0410-b921-86c7d4935375
5a87911fad8c138cb8f828b4511f43c1f8af2ec6
1e2695819670ea673f3ef2cac01393ec5ffa387f
/src/main/java/ebookBackend/serviceImp/ItemServiceImp.java
477c28fc0623230abf4ce2d8c3d19f048750f5e4
[]
no_license
sebastianj1w/SE228_Project
edeeef1d77afca5b934493891ee104035597679b
96f4c26519899bf8429dc1158fddccf8b1961afb
refs/heads/master
2023-01-11T15:03:58.781942
2019-07-08T06:23:49
2019-07-08T06:23:49
180,488,395
0
0
null
2023-01-03T19:26:23
2019-04-10T02:45:39
Java
UTF-8
Java
false
false
1,266
java
package ebookBackend.serviceImp; import ebookBackend.dao.ItemsMapper; import ebookBackend.entity.Items; import ebookBackend.entity.ItemsExample; import ebookBackend.service.ItemService; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import java.util.List; @Service public class ItemServiceImp implements ItemService { @Autowired ItemsMapper itemsMapper; public List<Items> getByOrderId(String id) { ItemsExample itemsExample = new ItemsExample(); ItemsExample.Criteria criteria = itemsExample.createCriteria(); criteria.andOrderidEqualTo(id); List<Items> bdl = itemsMapper.selectByExample(itemsExample); if (bdl.size()>0) return bdl; return null; } public void insert(Items item){ itemsMapper.insert(item); } // public List<Items> listAll() { // ItemsExample itemsExample = new ItemsExample(); // ItemsExample.Criteria criteria = itemsExample.createCriteria(); // List<Items> bdl = itemsMapper.selectByExample(itemsExample); // if (bdl.size()>0) // return bdl; // else // return null; //// return bookBasicMapper.listAll(); // } }
[ "38874198+sebastianj1w@users.noreply.github.com" ]
38874198+sebastianj1w@users.noreply.github.com
665143ca0e4ed58b0ffa774a8d5963c1ab2b4899
49735f1a0822a8cf085b813d37b81e3387f482e8
/src/day4/Magic8Ball.java
68707f6691942140ad239624c50e31f56ddceb27
[]
no_license
Ben0-2/IntroToJavaWS2
1ed4de1075ad2fcec6443c727702d2909783ce56
6b432f5505ca08ef22ec016b212178afe427b7d6
refs/heads/master
2021-06-01T09:48:00.603906
2016-07-15T18:54:28
2016-07-15T18:54:28
null
0
0
null
null
null
null
UTF-8
Java
false
false
624
java
package day4; import java.util.Random; import javax.swing.JOptionPane; public class Magic8Ball { public static void main(String[] args) { int RandomVariable = new Random().nextInt(4); JOptionPane.showInputDialog("Ask me a question..."); if (0 == RandomVariable) { JOptionPane.showMessageDialog(null, "Yes."); } if (1 == RandomVariable) { JOptionPane.showMessageDialog(null, "no"); } if (2 == RandomVariable) { JOptionPane.showMessageDialog(null, "Maybe you should ask Google?"); } if (3 == RandomVariable) { JOptionPane.showMessageDialog(null, "That is too hard for me"); } } }
[ "legomanaz@gmail.com" ]
legomanaz@gmail.com
84840487b13544aef5c721628169346ad086fc3f
ed4d18bbfa8cb3dba14438aa02eedd376d6d423a
/app/src/main/java/com/example/android/vinter_2/data/DbHelper.java
dbeb3f31894b878c4d1ba768fa6980df5d7703dc
[]
no_license
dibanezalegria/Vinter_2
7ba0b0dc7a7a179c27dcf0c06b061c479fc6434a
28973ffc59fc87467e4a62625827e220ef4e9283
refs/heads/master
2021-01-12T14:07:21.976929
2016-10-20T20:05:39
2016-10-20T20:05:39
70,166,730
0
0
null
null
null
null
UTF-8
Java
false
false
3,283
java
package com.example.android.vinter_2.data; import android.content.Context; import android.database.sqlite.SQLiteDatabase; import android.database.sqlite.SQLiteOpenHelper; import com.example.android.vinter_2.data.DbContract.PatientEntry; import com.example.android.vinter_2.data.DbContract.TestEntry; /** * Created by Daniel Ibanez on 2016-10-05. */ public class DbHelper extends SQLiteOpenHelper { private static DbHelper sInstance; public static final String DATABASE_NAME = "vintertest.db"; private static final int DATABASE_VERSION = 1; public static synchronized DbHelper getInstance(Context context) { // Use the application context, which will ensure that you // don't accidentally leak an Activity's context. if (sInstance == null) { sInstance = new DbHelper(context.getApplicationContext()); } return sInstance; } /** * Constructor should be private to prevent direct instantiation. * make call to static method "getInstance()" instead. */ private DbHelper(Context context) { super(context, DATABASE_NAME, null, DATABASE_VERSION); } @Override public void onCreate(SQLiteDatabase db) { final String SQL_CREATE_PATIENT_TABLE = "CREATE TABLE " + PatientEntry.TABLE_NAME + " (" + PatientEntry.COLUMN_ID + " INTEGER PRIMARY KEY AUTOINCREMENT," + PatientEntry.COLUMN_NAME + " TEXT NOT NULL, " + PatientEntry.COLUMN_ENTRY_NUMBER + " INTEGER, " + PatientEntry.COLUMN_NOTES + " TEXT)"; final String SQL_CREATE_TEST_TABLE = "CREATE TABLE " + TestEntry.TABLE_NAME + " (" + TestEntry.COLUMN_ID + " INTEGER PRIMARY KEY AUTOINCREMENT, " + TestEntry.COLUMN_PATIENT_ID_FK + " INTEGER NOT NULL, " + TestEntry.COLUMN_DATE + " INTEGER, " + TestEntry.COLUMN_CODE + " TEXT NOT NULL, " + TestEntry.COLUMN_CONTENT + " TEXT, " + TestEntry.COLUMN_STATUS + " INTEGER NOT NULL, " + TestEntry.COLUMN_INOUT + " INTEGER NOT NULL, " + // Set up the patient_id_fk as a foreign key to patient table "FOREIGN KEY (" + TestEntry.COLUMN_PATIENT_ID_FK + ") REFERENCES " + PatientEntry.TABLE_NAME + " (" + PatientEntry.COLUMN_ID + "));"; // // To assure the application have just one test type(code) per patient, // // it's created a UNIQUE constraint with REPLACE strategy // + // "UNIQUE (" + TestEntry.COLUMN_CODE + ", " + // TestEntry.COLUMN_PATIENT_ID_FK + ") ON CONFLICT REPLACE);"; db.execSQL(SQL_CREATE_PATIENT_TABLE); db.execSQL(SQL_CREATE_TEST_TABLE); } @Override public void onConfigure(SQLiteDatabase db) { super.onConfigure(db); // Enable foreign key constrains if (!db.isReadOnly()) { db.execSQL("PRAGMA foreign_keys=ON;"); } } @Override public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) { // TODO: Implement what to do when database version changes // Use ALTER to add columns if needed } }
[ "dibanezalegria@yahoo.com" ]
dibanezalegria@yahoo.com
362c8af7b7f5cc373b1166a1b33799c8a904dd33
db669bd036d83322a23495796c589235c13d90cb
/src/com/kit/design/pattern/factory/ingredient/Veggies.java
0c5b7b338658a4f2e43a4621a612f7bac8a9cd78
[]
no_license
KitYeungDev/JavaDesignPattern
56a00b50c87f3012ad6da84b18640b91403be69d
404ef29d14677e7169f0e2c6aeb374f0543a66dc
refs/heads/master
2021-01-19T09:00:20.952311
2017-09-24T15:08:32
2017-09-24T15:08:32
87,711,474
0
0
null
null
null
null
UTF-8
Java
false
false
123
java
package com.kit.design.pattern.factory.ingredient; /** * Created by chent on 2017/9/24. */ public interface Veggies { }
[ "developer6kit@gmail.com" ]
developer6kit@gmail.com
e0a88e17d184942c9e4ede9dda22da54f33d6d90
92f10c41bad09bee05acbcb952095c31ba41c57b
/app/src/main/java/io/github/alula/ohmygod/MainActivity3546.java
3269808003ce999d67c2c6c4bac70a0a4d74a7a6
[]
no_license
alula/10000-activities
bb25be9aead3d3d2ea9f9ef8d1da4c8dff1a7c62
f7e8de658c3684035e566788693726f250170d98
refs/heads/master
2022-07-30T05:54:54.783531
2022-01-29T19:53:04
2022-01-29T19:53:04
453,501,018
16
0
null
null
null
null
UTF-8
Java
false
false
339
java
package io.github.alula.ohmygod; import androidx.appcompat.app.AppCompatActivity; import android.os.Bundle; public class MainActivity3546 extends AppCompatActivity { @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); } }
[ "6276139+alula@users.noreply.github.com" ]
6276139+alula@users.noreply.github.com
4f52cf7d169799cb19fe18771d2a58ef78fd3119
b31c0e1da37b61c1b6e096cf752b20a0a1c7f736
/src/test/java/com/orange/FileUpload.java
50d15ef366af7aee2cba2d2894b10d49c656571d
[]
no_license
ptlseleniumgituser1/ptl-utils
f6ca5c247bf22346d6b5659676f11b0a8d11e165
5290f3df76a68868e629fe79c340df43a9949634
refs/heads/master
2021-04-27T05:15:49.763083
2018-02-23T10:05:26
2018-02-23T10:05:26
122,593,960
0
0
null
null
null
null
UTF-8
Java
false
false
1,916
java
package com.orange; import com.pragmatic.util.Constants; import org.openqa.selenium.By; import org.openqa.selenium.WebDriver; import org.openqa.selenium.chrome.ChromeDriver; import org.openqa.selenium.firefox.FirefoxDriver; import org.sikuli.script.Screen; import org.testng.Assert; import org.testng.annotations.AfterClass; import org.testng.annotations.BeforeClass; import org.testng.annotations.BeforeMethod; import org.testng.annotations.Test; import java.util.concurrent.TimeUnit; public class FileUpload { WebDriver webDriver; @BeforeClass public void beforeClass() { System.setProperty("webdriver.chrome.driver", "E:\\Software\\Drivers\\chromedriver.exe"); webDriver = new ChromeDriver(); webDriver.manage().timeouts().implicitlyWait(30, TimeUnit.SECONDS); //Implicit wait webDriver.get(Constants.ORANGE_BASE_URL); } @AfterClass public void afterClass(){ //webDriver.close(); } @Test public void testFileUpload() throws Exception { webDriver.findElement(By.id("txtUsername")).sendKeys("Admin"); webDriver.findElement(By.id("txtPassword")).sendKeys("admin"); webDriver.findElement(By.id("txtPassword")).submit(); webDriver.findElement(By.id("menu_pim_viewPimModule")).click(); //webDriver.findElement(By.id("menu_pim_addEmployee")).click(); webDriver.get("http://opensource.demo.orangehrmlive.com/index.php/pim/addEmployee"); //Click browse button webDriver.findElement(By.id("photofile")).click(); Screen screen = new Screen(); screen.type("D:\\training\\jmeterTraining\\oct2017\\java\\util\\pics\\FileUploadInputField.PNG", "D:\\training\\jmeterTraining\\oct2017\\java\\util\\pics\\FileUploadInputField.PNG"); screen.click("D:\\training\\jmeterTraining\\oct2017\\java\\util\\pics\\FileUploadOpenButton.PNG"); } }
[ "janesh_git1@pragmatictesters.com" ]
janesh_git1@pragmatictesters.com