File |
Line |
com\helger\jcodemodel\JEnumConstant.java |
157 |
com\helger\jcodemodel\JVar.java |
194 |
}
/**
* Adds an annotation to this variable.
*
* @param clazz
* The annotation class to annotate the field with
*/
@Nonnull
public JAnnotationUse annotate (@Nonnull final AbstractJClass clazz)
{
if (m_aAnnotations == null)
m_aAnnotations = new ArrayList <JAnnotationUse> ();
final JAnnotationUse a = new JAnnotationUse (clazz);
m_aAnnotations.add (a);
return a;
}
/**
* Adds an annotation to this variable.
*
* @param clazz
* The annotation class to annotate the field with
*/
@Nonnull
public JAnnotationUse annotate (@Nonnull final Class <? extends Annotation> clazz)
{
return annotate (m_aType.owner ().ref (clazz));
}
@Nonnull
public <W extends IJAnnotationWriter <?>> W annotate2 (@Nonnull final Class <W> clazz)
{
return TypedAnnotationWriter.create (clazz, this);
}
/**
* {@link IJAnnotatable#annotations()}
*/
@Nonnull
public Collection <JAnnotationUse> annotations ()
{
if (m_aAnnotations == null)
m_aAnnotations = new ArrayList <JAnnotationUse> ();
return Collections.unmodifiableList (m_aAnnotations);
} |
File |
Line |
com\helger\jcodemodel\JEnumConstant.java |
184 |
com\helger\jcodemodel\JPackage.java |
518 |
com\helger\jcodemodel\JVar.java |
223 |
return annotate (m_aType.owner ().ref (clazz));
}
@Nonnull
public <W extends IJAnnotationWriter <?>> W annotate2 (@Nonnull final Class <W> clazz)
{
return TypedAnnotationWriter.create (clazz, this);
}
/**
* {@link IJAnnotatable#annotations()}
*/
@Nonnull
public Collection <JAnnotationUse> annotations ()
{
if (m_aAnnotations == null)
m_aAnnotations = new ArrayList <JAnnotationUse> ();
return Collections.unmodifiableList (m_aAnnotations);
} |
File |
Line |
com\helger\jcodemodel\JEnumConstant.java |
157 |
com\helger\jcodemodel\JMethod.java |
361 |
com\helger\jcodemodel\JVar.java |
194 |
}
/**
* Adds an annotation to this variable.
*
* @param clazz
* The annotation class to annotate the field with
*/
@Nonnull
public JAnnotationUse annotate (@Nonnull final AbstractJClass clazz)
{
if (m_aAnnotations == null)
m_aAnnotations = new ArrayList <JAnnotationUse> ();
final JAnnotationUse a = new JAnnotationUse (clazz);
m_aAnnotations.add (a);
return a;
}
/**
* Adds an annotation to this variable.
*
* @param clazz
* The annotation class to annotate the field with
*/
@Nonnull
public JAnnotationUse annotate (@Nonnull final Class <? extends Annotation> clazz)
{
return annotate (m_aType.owner ().ref (clazz)); |
File |
Line |
com\helger\jcodemodel\util\JCValueEnforcer.java |
1032 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
1066 |
@Nonnull final BigDecimal aUpperBoundInclusive)
{
notNull (aValue, sName);
notNull (aLowerBoundInclusive, "LowerBoundInclusive");
notNull (aUpperBoundInclusive, "UpperBoundInclusive");
if (aValue.compareTo (aLowerBoundInclusive) < 0 || aValue.compareTo (aUpperBoundInclusive) > 0)
throw new IllegalArgumentException ("The value of '" +
sName +
"' must be >= " +
aLowerBoundInclusive +
" and <= " +
aUpperBoundInclusive +
"! The current value is: " +
aValue);
return aValue;
}
/**
* Check if
* <code>nValue ≥ nLowerBoundInclusive && nValue ≤ nUpperBoundInclusive</code>
*
* @param aValue
* Value
* @param sName
* Name
* @param aLowerBoundInclusive
* Lower bound
* @param aUpperBoundInclusive
* Upper bound
* @return The value
*/
public static BigInteger isBetweenInclusive (@Nonnull final BigInteger aValue, |
File |
Line |
com\helger\jcodemodel\JDefinedClass.java |
806 |
com\helger\jcodemodel\JEnumConstant.java |
185 |
com\helger\jcodemodel\JPackage.java |
519 |
com\helger\jcodemodel\JVar.java |
224 |
}
@Nonnull
public <W extends IJAnnotationWriter <?>> W annotate2 (@Nonnull final Class <W> clazz)
{
return TypedAnnotationWriter.create (clazz, this);
}
@Nonnull
public Collection <JAnnotationUse> annotations ()
{
if (m_aAnnotations == null)
m_aAnnotations = new ArrayList <JAnnotationUse> ();
return Collections.unmodifiableCollection (m_aAnnotations); |
File |
Line |
com\helger\jcodemodel\util\JCValueEnforcer.java |
1255 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
1289 |
@Nonnull final BigDecimal aUpperBoundExclusive)
{
notNull (aValue, sName);
notNull (aLowerBoundExclusive, "LowerBoundInclusive");
notNull (aUpperBoundExclusive, "UpperBoundInclusive");
if (aValue.compareTo (aLowerBoundExclusive) <= 0 || aValue.compareTo (aUpperBoundExclusive) >= 0)
throw new IllegalArgumentException ("The value of '" +
sName +
"' must be > " +
aLowerBoundExclusive +
" and < " +
aUpperBoundExclusive +
"! The current value is: " +
aValue);
return aValue;
} |
File |
Line |
com\helger\jcodemodel\JEnumConstant.java |
184 |
com\helger\jcodemodel\JMethod.java |
390 |
com\helger\jcodemodel\JVar.java |
223 |
return annotate (m_aType.owner ().ref (clazz));
}
@Nonnull
public <W extends IJAnnotationWriter <?>> W annotate2 (@Nonnull final Class <W> clazz)
{
return TypedAnnotationWriter.create (clazz, this);
}
/**
* {@link IJAnnotatable#annotations()}
*/
@Nonnull
public Collection <JAnnotationUse> annotations ()
{
if (m_aAnnotations == null) |
File |
Line |
com\helger\jcodemodel\JMethod.java |
390 |
com\helger\jcodemodel\JPackage.java |
518 |
return annotate (owner ().ref (clazz));
}
@Nonnull
public <W extends IJAnnotationWriter <?>> W annotate2 (@Nonnull final Class <W> clazz)
{
return TypedAnnotationWriter.create (clazz, this);
}
@Nonnull
public Collection <JAnnotationUse> annotations ()
{
if (m_aAnnotations == null) |
File |
Line |
com\helger\jcodemodel\JEnumConstant.java |
168 |
com\helger\jcodemodel\JMethod.java |
373 |
com\helger\jcodemodel\JPackage.java |
507 |
com\helger\jcodemodel\JVar.java |
206 |
if (m_aAnnotations == null)
m_aAnnotations = new ArrayList <JAnnotationUse> ();
final JAnnotationUse a = new JAnnotationUse (clazz);
m_aAnnotations.add (a);
return a;
}
/**
* Adds an annotation to this variable.
*
* @param clazz
* The annotation class to annotate the field with
*/
@Nonnull
public JAnnotationUse annotate (@Nonnull final Class <? extends Annotation> clazz)
{
return annotate (m_aType.owner ().ref (clazz)); |
File |
Line |
com\helger\jcodemodel\JDefinedClass.java |
806 |
com\helger\jcodemodel\JMethod.java |
391 |
}
@Nonnull
public <W extends IJAnnotationWriter <?>> W annotate2 (@Nonnull final Class <W> clazz)
{
return TypedAnnotationWriter.create (clazz, this);
}
@Nonnull
public Collection <JAnnotationUse> annotations ()
{
if (m_aAnnotations == null) |
File |
Line |
com\helger\jcodemodel\util\JavadocEscapeWriter.java |
84 |
com\helger\jcodemodel\util\UnicodeEscapeWriter.java |
104 |
public void write (@Nonnull final char [] buf,
@Nonnegative final int off,
@Nonnegative final int len) throws IOException
{
for (int i = 0; i < len; i++)
write (buf[off + i]);
}
@Override
public void write (@Nonnull final char [] buf) throws IOException |
File |
Line |
com\helger\jcodemodel\JDefinedClass.java |
796 |
com\helger\jcodemodel\JEnumConstant.java |
157 |
com\helger\jcodemodel\JMethod.java |
361 |
com\helger\jcodemodel\JVar.java |
194 |
}
@Nonnull
public JAnnotationUse annotate (@Nonnull final AbstractJClass clazz)
{
if (m_aAnnotations == null)
m_aAnnotations = new ArrayList <JAnnotationUse> ();
final JAnnotationUse a = new JAnnotationUse (clazz);
m_aAnnotations.add (a);
return a;
}
@Nonnull
public <W extends IJAnnotationWriter <?>> W annotate2 (@Nonnull final Class <W> clazz) |
File |
Line |
com\helger\jcodemodel\AbstractCodeWriter.java |
67 |
com\helger\jcodemodel\util\UnicodeEscapeWriter.java |
59 |
{
private static final BitSet ESCAPE = new BitSet (128);
static
{
for (int i = 0; i < 0x20; i++)
if (i != '\t' && i != '\r' && i != '\n')
ESCAPE.set (i, true);
} |
File |
Line |
com\helger\jcodemodel\JAnnotationArrayMember.java |
389 |
com\helger\jcodemodel\JDefinedClass.java |
789 |
return this;
}
/**
* Adds a new annotation to the array.
*/
@Nonnull
public JAnnotationUse annotate (@Nonnull final Class <? extends Annotation> clazz)
{
return annotate (owner ().ref (clazz));
}
/**
* Adds a new annotation to the array.
*/
@Nonnull
public JAnnotationUse annotate (@Nonnull final AbstractJClass clazz)
{ |
File |
Line |
com\helger\jcodemodel\JArrayClass.java |
115 |
com\helger\jcodemodel\JNullType.java |
94 |
public Iterator <AbstractJClass> _implements ()
{
return Collections.<AbstractJClass> emptyList ().iterator ();
}
@Override
public boolean isInterface ()
{
return false;
}
@Override
public boolean isAbstract ()
{
return false;
}
@Override |
File |
Line |
com\helger\jcodemodel\JFormatter.java |
825 |
com\helger\jcodemodel\JFormatter.java |
914 |
aClassToBeWritten.fullName () +
")");
AbstractJClass aRealReference = aReference;
if (aRealReference instanceof JAnonymousClass)
{
// get the super class of the anonymous class
aRealReference = ((JAnonymousClass) aRealReference).base ();
}
if (aRealReference instanceof JNarrowedClass)
{
// Remove the generic arguments
aRealReference = aRealReference.erasure ();
}
// Is it an inner class?
final AbstractJClass aOuter = aRealReference.outer (); |
File |
Line |
com\helger\jcodemodel\JCast.java |
91 |
com\helger\jcodemodel\JOpBinary.java |
85 |
com\helger\jcodemodel\JOpTernary.java |
108 |
com\helger\jcodemodel\JOpUnary.java |
96 |
f.print ("((").generable (_type).print (')').generable (_object).print (')');
}
@Override
public boolean equals (final Object o)
{
if (o == this)
return true;
if (o == null || getClass () != o.getClass ())
return false;
final JCast rhs = (JCast) o; |
File |
Line |
com\helger\jcodemodel\JBreak.java |
59 |
com\helger\jcodemodel\JContinue.java |
59 |
public JBreak (@Nullable final JLabel label)
{
m_aLabel = label;
}
@Nullable
public JLabel label ()
{
return m_aLabel;
}
public void state (@Nonnull final JFormatter f)
{
if (m_aLabel == null)
f.print ("break;").newline (); |
File |
Line |
com\helger\jcodemodel\JAnnotationArrayMember.java |
408 |
com\helger\jcodemodel\JDefinedClass.java |
804 |
_values.add (a);
return a;
}
@Nonnull
public <W extends IJAnnotationWriter <?>> W annotate2 (@Nonnull final Class <W> clazz)
{
return TypedAnnotationWriter.create (clazz, this);
}
/**
* {@link IJAnnotatable#annotations()}
*
* @see #getAllAnnotations()
*/
@SuppressWarnings ({ "unchecked", "rawtypes" }) |
File |
Line |
com\helger\jcodemodel\JArrayClass.java |
142 |
com\helger\jcodemodel\JNarrowedClass.java |
306 |
}
//
// Equality is based on value
//
@Override
public boolean equals (final Object obj)
{
if (obj == this)
return true;
if (obj == null || !getClass ().equals (obj.getClass ()))
return false;
final JArrayClass rhs = (JArrayClass) obj; |
File |
Line |
com\helger\jcodemodel\JEnumConstant.java |
222 |
com\helger\jcodemodel\JVar.java |
262 |
f.print (m_sName);
}
@Override
public boolean equals (final Object o)
{
if (o == this)
return true;
if (o == null || getClass () != o.getClass ())
return false;
final JEnumConstant rhs = (JEnumConstant) o; |
File |
Line |
com\helger\jcodemodel\JNarrowedClass.java |
145 |
com\helger\jcodemodel\JNarrowedClass.java |
164 |
buf.append (m_aBasis.fullName ());
buf.append ('<');
boolean bFirst = true;
for (final AbstractJClass c : m_aArgs)
{
if (bFirst)
bFirst = false;
else
buf.append (',');
buf.append (c.fullName ()); |
File |
Line |
com\helger\jcodemodel\util\JCValueEnforcer.java |
1323 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
1331 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
1339 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
1347 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
1355 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
1363 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
1371 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
1379 |
public static void isArrayOfsLen (@Nonnull final Object [] aArray,
@Nonnegative final int nOfs,
@Nonnegative final int nLen)
{
notNull (aArray, "Array");
_isArrayOfsLen (aArray.length, nOfs, nLen);
}
public static void isArrayOfsLen (@Nonnull final boolean [] aArray, |
File |
Line |
com\helger\jcodemodel\JAtomDouble.java |
80 |
com\helger\jcodemodel\JAtomInt.java |
67 |
com\helger\jcodemodel\JStringLiteral.java |
77 |
f.print (Double.toString (_what));
}
@Override
public boolean equals (final Object o)
{
if (o == this)
return true;
if (o == null || getClass () != o.getClass ())
return false;
final JAtomDouble rhs = (JAtomDouble) o; |
File |
Line |
com\helger\jcodemodel\JForEach.java |
95 |
com\helger\jcodemodel\JForLoop.java |
120 |
}
@Nonnull
public JBlock body ()
{
if (m_aBody == null)
m_aBody = new JBlock ();
return m_aBody;
}
public void state (@Nonnull final JFormatter f)
{
f.print ("for ("); |
File |
Line |
com\helger\jcodemodel\JArray.java |
150 |
com\helger\jcodemodel\JArrayCompRef.java |
93 |
com\helger\jcodemodel\JAssignment.java |
117 |
com\helger\jcodemodel\JAtom.java |
70 |
com\helger\jcodemodel\JAtomDouble.java |
80 |
com\helger\jcodemodel\JAtomFloat.java |
81 |
com\helger\jcodemodel\JAtomInt.java |
67 |
com\helger\jcodemodel\JAtomLong.java |
69 |
com\helger\jcodemodel\JCast.java |
91 |
com\helger\jcodemodel\JEnumConstant.java |
222 |
com\helger\jcodemodel\JEnumConstantRef.java |
104 |
com\helger\jcodemodel\JFieldRef.java |
206 |
com\helger\jcodemodel\JOpBinary.java |
85 |
com\helger\jcodemodel\JOpTernary.java |
109 |
com\helger\jcodemodel\JOpUnary.java |
96 |
com\helger\jcodemodel\JStringLiteral.java |
77 |
com\helger\jcodemodel\JVar.java |
262 |
f.print ('}');
}
@Override
public boolean equals (final Object o)
{
if (o == this)
return true;
if (o == null || getClass () != o.getClass ())
return false;
final JArray rhs = (JArray) o; |
File |
Line |
com\helger\jcodemodel\meta\ClassFiller.java |
104 |
com\helger\jcodemodel\meta\DecidedErrorTypesModelsAdapter.java |
242 |
for (final Element enclosedElement : element.getEnclosedElements ())
{
if (enclosedElement.getKind ().equals (ElementKind.INTERFACE) ||
enclosedElement.getKind ().equals (ElementKind.CLASS)) |
File |
Line |
com\helger\jcodemodel\util\JavadocEscapeWriter.java |
99 |
com\helger\jcodemodel\util\UnicodeEscapeWriter.java |
119 |
public void write (@Nonnull final String buf,
@Nonnegative final int off,
@Nonnegative final int len) throws IOException
{
write (buf.toCharArray (), off, len);
}
@Override
public void write (@Nonnull final String buf) throws IOException |
File |
Line |
com\helger\jcodemodel\util\JCValueEnforcer.java |
165 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
185 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
205 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
225 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
245 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
265 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
285 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
305 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
325 |
public static <T> T [] notEmpty (final T [] aValue, final String sName)
{
notNull (aValue, sName);
if (aValue.length == 0)
throw new IllegalArgumentException ("The value of the array '" + sName + "' may not be empty!");
return aValue;
}
/**
* Check that the passed Array is neither <code>null</code> nor empty.
*
* @param aValue
* The Array to check.
* @param sName
* The name of the value (e.g. the parameter name)
* @return The passed value and never <code>null</code>.
* @throws IllegalArgumentException
* if the passed value is empty
*/
@Nonnull
public static boolean [] notEmpty (final boolean [] aValue, final String sName) |
File |
Line |
com\helger\jcodemodel\AbstractJGenerifiableImpl.java |
63 |
com\helger\jcodemodel\JInvocation.java |
367 |
public void declare (@Nonnull final JFormatter f)
{
if (_typeVariables != null && !_typeVariables.isEmpty ())
{
f.print ('<');
int nIndex = 0;
for (final JTypeVar aTypeVar : _typeVariables.values ()) |
File |
Line |
com\helger\jcodemodel\JArray.java |
151 |
com\helger\jcodemodel\JArrayCompRef.java |
94 |
com\helger\jcodemodel\JAssignment.java |
118 |
com\helger\jcodemodel\JAtom.java |
71 |
com\helger\jcodemodel\JAtomDouble.java |
81 |
com\helger\jcodemodel\JAtomFloat.java |
82 |
com\helger\jcodemodel\JAtomInt.java |
68 |
com\helger\jcodemodel\JAtomLong.java |
70 |
com\helger\jcodemodel\JCast.java |
92 |
com\helger\jcodemodel\JEnumConstant.java |
223 |
com\helger\jcodemodel\JEnumConstantRef.java |
105 |
com\helger\jcodemodel\JFieldRef.java |
207 |
com\helger\jcodemodel\JInvocation.java |
449 |
com\helger\jcodemodel\JOpBinary.java |
86 |
com\helger\jcodemodel\JOpTernary.java |
110 |
com\helger\jcodemodel\JOpUnary.java |
97 |
com\helger\jcodemodel\JStringLiteral.java |
78 |
com\helger\jcodemodel\JVar.java |
263 |
}
@Override
public boolean equals (final Object o)
{
if (o == this)
return true;
if (o == null || getClass () != o.getClass ())
return false;
final JArray rhs = (JArray) o; |
File |
Line |
com\helger\jcodemodel\JDirectClass.java |
137 |
com\helger\jcodemodel\JNullType.java |
103 |
}
@Override
public boolean isAbstract ()
{
return false;
}
@Override
@Nonnull
protected AbstractJClass substituteParams (final JTypeVar [] variables,
final List <? extends AbstractJClass> bindings)
{
return this;
} |
File |
Line |
com\helger\jcodemodel\JDoLoop.java |
77 |
com\helger\jcodemodel\JForEach.java |
95 |
com\helger\jcodemodel\JForLoop.java |
120 |
com\helger\jcodemodel\JSynchronizedBlock.java |
72 |
}
@Nonnull
public JBlock body ()
{
if (m_aBody == null)
m_aBody = new JBlock ();
return m_aBody;
}
public void state (@Nonnull final JFormatter f)
{
f.print ("do"); |
File |
Line |
com\helger\jcodemodel\util\JCValueEnforcer.java |
877 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
908 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
939 |
final short nUpperBoundInclusive)
{
if (nValue < nLowerBoundInclusive || nValue > nUpperBoundInclusive)
throw new IllegalArgumentException ("The value of '" +
sName +
"' must be >= " +
nLowerBoundInclusive +
" and <= " +
nUpperBoundInclusive +
"! The current value is: " +
nValue);
return nValue;
}
/**
* Check if
* <code>nValue ≥ nLowerBoundInclusive && nValue ≤ nUpperBoundInclusive</code>
*
* @param nValue
* Value
* @param sName
* Name
* @param nLowerBoundInclusive
* Lower bound
* @param nUpperBoundInclusive
* Upper bound
* @return The value
*/
public static int isBetweenInclusive (final int nValue, |
File |
Line |
com\helger\jcodemodel\util\JCValueEnforcer.java |
1100 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
1131 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
1162 |
final short nUpperBoundExclusive)
{
if (nValue <= nLowerBoundExclusive || nValue >= nUpperBoundExclusive)
throw new IllegalArgumentException ("The value of '" +
sName +
"' must be > " +
nLowerBoundExclusive +
" and < " +
nUpperBoundExclusive +
"! The current value is: " +
nValue);
return nValue;
}
/**
* Check if
* <code>nValue > nLowerBoundInclusive && nValue < nUpperBoundInclusive</code>
*
* @param nValue
* Value
* @param sName
* Name
* @param nLowerBoundExclusive
* Lower bound
* @param nUpperBoundExclusive
* Upper bound
* @return The value
*/
public static int isBetweenExclusive (final int nValue, |
File |
Line |
com\helger\jcodemodel\JCase.java |
102 |
com\helger\jcodemodel\JDoLoop.java |
77 |
com\helger\jcodemodel\JForEach.java |
95 |
com\helger\jcodemodel\JForLoop.java |
120 |
com\helger\jcodemodel\JSynchronizedBlock.java |
72 |
}
@Nonnull
public JBlock body ()
{
if (m_aBody == null)
m_aBody = new JBlock ();
return m_aBody;
}
public void state (@Nonnull final JFormatter f)
{
f.indent (); |
File |
Line |
com\helger\jcodemodel\meta\Annotator.java |
169 |
com\helger\jcodemodel\meta\Annotator.java |
343 |
_annotationUse.param (name, actualEnumConstantValue ((VariableElement) value));
}
catch (final ClassNotFoundException ex)
{
Logger.getLogger (Annotator.class.getName ()).log (Level.WARNING,
"Not processing annotation argument: {0}: {1}",
new Object [] { name, value }); |
File |
Line |
com\helger\jcodemodel\meta\Annotator.java |
392 |
com\helger\jcodemodel\meta\Annotator.java |
399 |
catch (final NoSuchFieldException ex)
{
throw new IllegalStateException (MessageFormat.format ("Unable to load enum constant: {0}.{1}",
enumClassElement.getQualifiedName ().toString (),
variableElement.getSimpleName ().toString ()),
ex);
} |
File |
Line |
com\helger\jcodemodel\meta\Annotator.java |
411 |
com\helger\jcodemodel\meta\Annotator.java |
418 |
catch (final IllegalArgumentException ex)
{
throw new IllegalStateException (MessageFormat.format ("Unable to load enum constant actual value: {0}.{1}",
enumClassElement.getQualifiedName ().toString (),
variableElement.getSimpleName ().toString ()),
ex);
} |
File |
Line |
com\helger\jcodemodel\meta\ClassFiller.java |
89 |
com\helger\jcodemodel\meta\ClassFiller.java |
125 |
environment.put (typeVariable.name (), typeVariable);
for (final TypeMirror type : parameter.getBounds ())
{
typeVariable.bound ((AbstractJClass) _modelsAdapter.toJType (type, environment)); |
File |
Line |
com\helger\jcodemodel\AbstractJClassContainer.java |
167 |
com\helger\jcodemodel\JDirectClass.java |
98 |
public String fullName ()
{
if (getOuter () instanceof AbstractJClassContainer <?>)
return ((AbstractJClassContainer <?>) getOuter ()).fullName () + '.' + name (); |
File |
Line |
com\helger\jcodemodel\JAnnotationArrayMember.java |
410 |
com\helger\jcodemodel\JEnumConstant.java |
185 |
com\helger\jcodemodel\JMethod.java |
391 |
com\helger\jcodemodel\JPackage.java |
519 |
com\helger\jcodemodel\JVar.java |
224 |
}
@Nonnull
public <W extends IJAnnotationWriter <?>> W annotate2 (@Nonnull final Class <W> clazz)
{
return TypedAnnotationWriter.create (clazz, this);
}
/**
* {@link IJAnnotatable#annotations()}
*
* @see #getAllAnnotations()
*/
@SuppressWarnings ({ "unchecked", "rawtypes" }) |
File |
Line |
com\helger\jcodemodel\JDefinedClass.java |
801 |
com\helger\jcodemodel\JPackage.java |
507 |
if (m_aAnnotations == null)
m_aAnnotations = new ArrayList <JAnnotationUse> ();
final JAnnotationUse a = new JAnnotationUse (clazz);
m_aAnnotations.add (a);
return a;
}
@Nonnull
public <W extends IJAnnotationWriter <?>> W annotate2 (@Nonnull final Class <W> clazz) |
File |
Line |
com\helger\jcodemodel\JNullType.java |
96 |
com\helger\jcodemodel\JTypeVar.java |
167 |
return Collections.<AbstractJClass> emptyList ().iterator ();
}
@Override
public boolean isInterface ()
{
return false;
}
@Override
public boolean isAbstract ()
{
return false;
}
@Override
@Nonnull
protected AbstractJClass substituteParams (final JTypeVar [] variables, |
File |
Line |
com\helger\jcodemodel\meta\TypeMirrorToJTypeVisitor.java |
125 |
com\helger\jcodemodel\meta\TypeMirrorToJTypeVisitor.java |
239 |
return componentType.array ();
}
catch (final CodeModelBuildingException ex)
{
throw new RuntimeCodeModelBuildingException (ex);
}
catch (final ErrorTypeFound ex)
{
throw new RuntimeErrorTypeFound (ex);
}
}
@Override
public AbstractJType visitDeclared (final DeclaredType t, final Void p) |
File |
Line |
com\helger\jcodemodel\util\JCValueEnforcer.java |
533 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
556 |
public static <T extends Iterable <?>> T notEmptyNoNullValue (final T aValue, final String sName)
{
notEmpty (aValue, sName);
noNullValue (aValue, sName);
return aValue;
}
/**
* Check that the passed map is neither <code>null</code> nor empty and that
* no <code>null</code> value is contained.
*
* @param <T>
* Type to be checked and returned
* @param aValue
* The map to check.
* @param sName
* The name of the value (e.g. the parameter name)
* @return The passed value and never <code>null</code>.
* @throws IllegalArgumentException
* if the passed value is empty or a <code>null</code> value is
* contained
*/
@Nonnull
public static <T extends Map <?, ?>> T notEmptyNoNullValue (final T aValue, final String sName) |
File |
Line |
com\helger\jcodemodel\AbstractJGenerifiableImpl.java |
110 |
com\helger\jcodemodel\JInvocation.java |
357 |
}
@Nonnull
public List <JTypeVar> typeParamList ()
{
if (_typeVariables == null)
return Collections.<JTypeVar> emptyList ();
return new ArrayList <JTypeVar> (_typeVariables.values ()); |
File |
Line |
com\helger\jcodemodel\JAnnotationArrayMember.java |
390 |
com\helger\jcodemodel\JDefinedClass.java |
790 |
com\helger\jcodemodel\JMethod.java |
378 |
}
/**
* Adds a new annotation to the array.
*/
@Nonnull
public JAnnotationUse annotate (@Nonnull final Class <? extends Annotation> clazz)
{
return annotate (owner ().ref (clazz));
}
/**
* Adds a new annotation to the array.
*/
@Nonnull
public JAnnotationUse annotate (@Nonnull final AbstractJClass clazz) |
File |
Line |
com\helger\jcodemodel\JCase.java |
102 |
com\helger\jcodemodel\JDoLoop.java |
77 |
com\helger\jcodemodel\JForEach.java |
95 |
com\helger\jcodemodel\JForLoop.java |
120 |
com\helger\jcodemodel\JSynchronizedBlock.java |
72 |
com\helger\jcodemodel\JWhileLoop.java |
75 |
}
@Nonnull
public JBlock body ()
{
if (m_aBody == null)
m_aBody = new JBlock ();
return m_aBody;
}
public void state (@Nonnull final JFormatter f)
{ |
File |
Line |
com\helger\jcodemodel\JAnnotationUse.java |
433 |
com\helger\jcodemodel\JAnnotationUse.java |
487 |
public JAnnotationUse paramArray (@Nonnull final String name, @Nonnull final Enum <?>... values)
{
paramArray (name).params (values);
return this;
}
/**
* Adds a member value pair to this annotation
*
* @param name
* The simple name for this annotation
* @param value
* The {@link JEnumConstant} which is member value for this annotation
* @return The {@link JAnnotationUse}. More member value pairs can be added to
* it using the same or the overloaded methods.
*/
@Nonnull
public JAnnotationUse param (@Nonnull final String name, @Nonnull final JEnumConstant value) |
File |
Line |
com\helger\jcodemodel\meta\DecidedErrorTypesModelsAdapter.java |
154 |
com\helger\jcodemodel\meta\DecidedErrorTypesModelsAdapter.java |
192 |
public JDefinedClass getClass (final TypeElement element) throws CodeModelBuildingException, ErrorTypeFound
{
final Element enclosingElement = element.getEnclosingElement ();
if (enclosingElement instanceof PackageElement)
{
final PackageElement packageElement = (PackageElement) enclosingElement; |
File |
Line |
com\helger\jcodemodel\meta\TypeMirrorToJTypeVisitor.java |
126 |
com\helger\jcodemodel\meta\TypeMirrorToJTypeVisitor.java |
149 |
com\helger\jcodemodel\meta\TypeMirrorToJTypeVisitor.java |
240 |
}
catch (final CodeModelBuildingException ex)
{
throw new RuntimeCodeModelBuildingException (ex);
}
catch (final ErrorTypeFound ex)
{
throw new RuntimeErrorTypeFound (ex);
}
}
@Override
public AbstractJType visitDeclared (final DeclaredType t, final Void p) |
File |
Line |
com\helger\jcodemodel\util\JCValueEnforcer.java |
1323 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
1331 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
1339 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
1347 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
1355 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
1363 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
1371 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
1379 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
1387 |
public static void isArrayOfsLen (@Nonnull final Object [] aArray,
@Nonnegative final int nOfs,
@Nonnegative final int nLen)
{
notNull (aArray, "Array");
_isArrayOfsLen (aArray.length, nOfs, nLen);
} |
File |
Line |
com\helger\jcodemodel\JCodeModel.java |
423 |
com\helger\jcodemodel\JCodeModel.java |
627 |
{
final JPackage [] pkgs = m_aPackages.values ().toArray (new JPackage [m_aPackages.size ()]);
// avoid concurrent modification exception
for (final JPackage pkg : pkgs) |
File |
Line |
com\helger\jcodemodel\JErrorClass.java |
121 |
com\helger\jcodemodel\JTypeWildcard.java |
159 |
throw new JErrorClassUsedException (m_sMessage);
}
@Override
public boolean isInterface ()
{
return false;
}
@Override
public boolean isAbstract ()
{
return false;
}
@Override
public boolean isError ()
{
return true; |
File |
Line |
com\helger\jcodemodel\util\JCValueEnforcer.java |
348 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
393 |
public static <T extends Collection <?>> T notEmpty (final T aValue, final String sName)
{
notNull (aValue, sName);
if (aValue.isEmpty ())
throw new IllegalArgumentException ("The value of the collection '" + sName + "' may not be empty!"); |
File |
Line |
com\helger\jcodemodel\JAnnotationUse.java |
427 |
com\helger\jcodemodel\JAnnotationUse.java |
481 |
public JAnnotationUse param (@Nonnull final String name, @Nonnull final Enum <?> value)
{
return _addValue (name, wrap (value));
}
@Nonnull
public JAnnotationUse paramArray (@Nonnull final String name, @Nonnull final Enum <?>... values) |
File |
Line |
com\helger\jcodemodel\JCodeModel.java |
424 |
com\helger\jcodemodel\JCodeModel.java |
628 |
com\helger\jcodemodel\JCodeModel.java |
648 |
final JPackage [] pkgs = m_aPackages.values ().toArray (new JPackage [m_aPackages.size ()]);
// avoid concurrent modification exception
for (final JPackage pkg : pkgs) |
File |
Line |
com\helger\jcodemodel\JDirectClass.java |
130 |
com\helger\jcodemodel\JNullType.java |
90 |
}
@Override
@Nonnull
public Iterator <AbstractJClass> _implements ()
{
return Collections.<AbstractJClass> emptyList ().iterator ();
}
@Override
public boolean isAbstract () |
File |
Line |
com\helger\jcodemodel\util\JCHashCodeGenerator.java |
280 |
com\helger\jcodemodel\util\JCHashCodeGenerator.java |
430 |
public JCHashCodeGenerator append (@Nullable final Object x)
{
_checkClosed ();
m_nHC = JCHashCodeCalculator.append (m_nHC, x);
return this;
}
/**
* Object hash code generation.
*
* @param x
* Array to add
* @return this
*/
@Nonnull
public JCHashCodeGenerator append (@Nullable final Enum <?> x) |
File |
Line |
com\helger\jcodemodel\JAnnotationUse.java |
410 |
com\helger\jcodemodel\JAnnotationUse.java |
433 |
com\helger\jcodemodel\JAnnotationUse.java |
456 |
com\helger\jcodemodel\JAnnotationUse.java |
487 |
com\helger\jcodemodel\JAnnotationUse.java |
511 |
public JAnnotationUse paramArray (@Nonnull final String name, @Nonnull final String... values)
{
paramArray (name).params (values);
return this;
}
/**
* Adds a member value pair to this annotation
*
* @param name
* The simple name for this annotation
* @param value
* The enum class which is member value for this annotation
* @return The {@link JAnnotationUse}. More member value pairs can be added to
* it using the same or the overloaded methods.
*/
@Nonnull
public JAnnotationUse param (@Nonnull final String name, @Nonnull final Enum <?> value) |
File |
Line |
com\helger\jcodemodel\meta\TypeMirrorToJTypeVisitor.java |
125 |
com\helger\jcodemodel\meta\TypeMirrorToJTypeVisitor.java |
176 |
com\helger\jcodemodel\meta\TypeMirrorToJTypeVisitor.java |
239 |
return componentType.array ();
}
catch (final CodeModelBuildingException ex)
{
throw new RuntimeCodeModelBuildingException (ex);
}
catch (final ErrorTypeFound ex)
{
throw new RuntimeErrorTypeFound (ex);
}
} |
File |
Line |
com\helger\jcodemodel\util\JCHashCodeGenerator.java |
295 |
com\helger\jcodemodel\util\JCHashCodeGenerator.java |
490 |
public JCHashCodeGenerator append (@Nullable final Enum <?> x)
{
_checkClosed ();
m_nHC = JCHashCodeCalculator.append (m_nHC, x);
return this;
}
/**
* Array hash code generation.
*
* @param x
* Array to add
* @return this
*/
@Nonnull
public JCHashCodeGenerator append (@Nullable final boolean [] x) |
File |
Line |
com\helger\jcodemodel\AbstractJClassContainer.java |
254 |
com\helger\jcodemodel\JPackage.java |
184 |
public final CLASSTYPE _class (final int nMods, @Nonnull final String sName) throws JClassAlreadyExistsException
{
return _class (nMods, sName, EClassType.CLASS);
}
@Nonnull
public final CLASSTYPE _interface (@Nonnull final String sName) throws JClassAlreadyExistsException |
File |
Line |
com\helger\jcodemodel\AbstractJClassContainer.java |
266 |
com\helger\jcodemodel\JPackage.java |
255 |
public final CLASSTYPE _interface (final int nMods, @Nonnull final String sName) throws JClassAlreadyExistsException
{
return _class (nMods, sName, EClassType.INTERFACE);
}
@Nonnull
public final CLASSTYPE _annotationTypeDeclaration (@Nonnull final String sName) throws JClassAlreadyExistsException |
File |
Line |
com\helger\jcodemodel\JArrayClass.java |
117 |
com\helger\jcodemodel\JTypeVar.java |
167 |
return Collections.<AbstractJClass> emptyList ().iterator ();
}
@Override
public boolean isInterface ()
{
return false;
}
@Override
public boolean isAbstract ()
{
return false;
}
@Override |
File |
Line |
com\helger\jcodemodel\meta\TypeMirrorToJTypeVisitor.java |
149 |
com\helger\jcodemodel\meta\TypeMirrorToJTypeVisitor.java |
177 |
}
catch (final CodeModelBuildingException ex)
{
throw new RuntimeCodeModelBuildingException (ex);
}
catch (final ErrorTypeFound ex)
{
throw new RuntimeErrorTypeFound (ex);
}
} |
File |
Line |
com\helger\jcodemodel\util\JavadocEscapeWriter.java |
107 |
com\helger\jcodemodel\util\UnicodeEscapeWriter.java |
127 |
public void write (@Nonnull final String buf) throws IOException
{
write (buf.toCharArray (), 0, buf.length ());
}
} |
File |
Line |
com\helger\jcodemodel\util\JCHashCodeGenerator.java |
295 |
com\helger\jcodemodel\util\JCHashCodeGenerator.java |
490 |
com\helger\jcodemodel\util\JCHashCodeGenerator.java |
503 |
public JCHashCodeGenerator append (@Nullable final Enum <?> x)
{
_checkClosed ();
m_nHC = JCHashCodeCalculator.append (m_nHC, x);
return this;
}
/**
* Array hash code generation.
*
* @param x
* Array to add
* @return this
*/
@Nonnull
public JCHashCodeGenerator append (@Nullable final boolean [] x) |
File |
Line |
com\helger\jcodemodel\util\JCHashCodeGenerator.java |
310 |
com\helger\jcodemodel\util\JCHashCodeGenerator.java |
325 |
com\helger\jcodemodel\util\JCHashCodeGenerator.java |
340 |
com\helger\jcodemodel\util\JCHashCodeGenerator.java |
355 |
com\helger\jcodemodel\util\JCHashCodeGenerator.java |
370 |
com\helger\jcodemodel\util\JCHashCodeGenerator.java |
385 |
com\helger\jcodemodel\util\JCHashCodeGenerator.java |
400 |
com\helger\jcodemodel\util\JCHashCodeGenerator.java |
415 |
com\helger\jcodemodel\util\JCHashCodeGenerator.java |
430 |
com\helger\jcodemodel\util\JCHashCodeGenerator.java |
445 |
public JCHashCodeGenerator append (@Nullable final boolean [] x)
{
_checkClosed ();
m_nHC = JCHashCodeCalculator.append (m_nHC, x);
return this;
}
/**
* Array hash code generation.
*
* @param x
* Array to add
* @return this
*/
@Nonnull
public JCHashCodeGenerator append (@Nullable final byte [] x) |
File |
Line |
com\helger\jcodemodel\util\JCValueEnforcer.java |
648 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
655 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
662 |
public static short isGE0 (final short nValue, final String sName)
{
if (nValue < 0)
throw new IllegalArgumentException ("The value of '" + sName + "' must be >= 0! The current value is: " + nValue);
return nValue;
}
public static int isGE0 (final int nValue, final String sName) |
File |
Line |
com\helger\jcodemodel\util\JCValueEnforcer.java |
701 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
708 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
715 |
public static short isGT0 (final short nValue, final String sName)
{
if (nValue <= 0)
throw new IllegalArgumentException ("The value of '" + sName + "' must be > 0! The current value is: " + nValue);
return nValue;
}
public static int isGT0 (final int nValue, final String sName) |
File |
Line |
com\helger\jcodemodel\util\JCValueEnforcer.java |
754 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
761 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
768 |
public static short isLE0 (final short nValue, final String sName)
{
if (nValue > 0)
throw new IllegalArgumentException ("The value of '" + sName + "' must be <= 0! The current value is: " + nValue);
return nValue;
}
public static int isLE0 (final int nValue, final String sName) |
File |
Line |
com\helger\jcodemodel\util\JCValueEnforcer.java |
807 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
814 |
com\helger\jcodemodel\util\JCValueEnforcer.java |
821 |
public static short isLT0 (final short nValue, final String sName)
{
if (nValue >= 0)
throw new IllegalArgumentException ("The value of '" + sName + "' must be < 0! The current value is: " + nValue);
return nValue;
}
public static int isLT0 (final int nValue, final String sName) |
File |
Line |
com\helger\jcodemodel\writer\OutputStreamCodeWriter.java |
105 |
com\helger\jcodemodel\writer\SingleStreamCodeWriter.java |
103 |
return new FilterOutputStream (m_aPS)
{
@Override
public void close ()
{
// don't let this stream close
}
};
}
@Override
public void close () throws IOException
{
m_aPS.close (); |