@Override public Arg clone() { return (Arg)super.clone(); }
@Override public Function addAnnotation(Annotation a) { return (Function)super.addAnnotation(a); }
@Override public TaggedTypeRefDeclaration addModifiers(Modifier... mds) { return (TaggedTypeRefDeclaration) super.addModifiers(mds); } //public String resove
@Override public boolean replaceChild(Element child, Element by) { if (child == getValueType()) { setValueType((TypeRef) by); return true; } return super.replaceChild(child, by); }
private void privatize(Declaration d) { List<Modifier> modifiers = new ArrayList<Modifier>(d.getModifiers()); modifiers.remove(ModifierType.Public); modifiers.remove(ModifierType.Protected); modifiers.add(0, ModifierType.Private); d.setModifiers(modifiers); }
if (vs.getBits() > 0) { for (Declaration vd : vds) { vd.addAnnotation(new Annotation(result.config.runtime.typeRef(JNAeratorConfig.Runtime.Ann.Bits), expr(vs.getBits()))); vd.importDetails(mutatedType, true); vd.moveAllCommentsBefore(); if (!(mutatedType instanceof Primitive) && !result.config.noComments) { vd.addToCommentBefore("C type : " + mutatedType);
@Override // @Deprecated public TypeRef getValueType() { return super.getValueType(); }
void toDirectFakePointer(Result result, Declaration decl) { decl.setValueType(typeRef(long.class)); decl.addAnnotation(new Annotation(typeRef(Ptr.class))); }
Declaration d = skipDeclaration(function); if (d != null) { d.addToCommentBefore(ex.toString()); declarations.addDeclaration(d); implementations.addDeclaration(d.clone());
declaration.addModifiers(ModifierType.Public, ModifierType.Static, ModifierType.Final); if (!result.config.noComments) { declaration.importComments(element, addFileComment ? getFileCommentContent(element) : null);
decl.addModifiers(ModifierType.Public, ModifierType.Abstract); decl.reorganizeModifiers(); decl.addModifiers(ModifierType.Public, ModifierType.Abstract); decl.reorganizeModifiers();
String commentAfter = getCommentAfterOnSameLine(retval.startTokenIndex, null); if (retval.declaration != null) { retval.declaration.setCommentBefore(retval.preComment); retval.declaration.setCommentAfter(commentAfter); retval.declaration.addModifiers(retval.modifiers);
@Override public void setValueType(TypeRef valueType) { super.setValueType((FunctionSignature)valueType); } public void accept(Visitor visitor) {
@Override public Element getNextChild(Element child) { Element e = super.getNextChild(child); if (e != null) return e; return getNextSibling(args, child); }
public void setValueType(TypeRef valueType) { if (valueType == null) valueType = null; this.valueType = changeValue(this, this.valueType, valueType); }
if (vs.getBits() > 0) { for (Declaration vd : vds) { vd.addAnnotation(new Annotation(result.config.runtime.typeRef(JNAeratorConfig.Runtime.Ann.Bits), expr(vs.getBits()))); vd.importDetails(mutatedType, true); vd.moveAllCommentsBefore(); if (!(mutatedType instanceof Primitive) && !result.config.noComments) { vd.addToCommentBefore("C type : " + mutatedType);
@Override public FunctionSignature getValueType() { return (FunctionSignature)super.getValueType(); } @Override
void toDirectFakePointer(Result result, Declaration decl) { decl.setValueType(typeRef(long.class)); decl.addAnnotation(new Annotation(typeRef(Ptr.class))); }
Declaration d = skipDeclaration(function); if (d != null) { d.addToCommentBefore(ex.toString()); declarations.addDeclaration(d); implementations.addDeclaration(d.clone());