public static Kind read(VersionedDataInputStream s) throws IOException { int key = s.readByte(); switch(key) { case 1: return SINGLETON; case 2: return PERCFLOW; case 3: return PEROBJECT; case 4: return FROMSUPER; case 5: return PERTYPEWITHIN; } throw new BCException("weird kind " + key); } }
public static AdviceKind read(VersionedDataInputStream s) throws IOException { int key = s.readByte(); switch (key) { case 1:
protected static Set<ResolvedMember> readSuperMethodsCalled(VersionedDataInputStream s) throws IOException { Set<ResolvedMember> ret = new HashSet<ResolvedMember>(); int n = -1; if (s.isAtLeast169()) { n = s.readByte(); } else { n = s.readInt(); } if (n < 0) { throw new BCException("Problem deserializing type munger"); } for (int i = 0; i < n; i++) { ret.add(ResolvedMemberImpl.readResolvedMember(s, null)); } return ret; }
protected static List<String> readInTypeAliases(VersionedDataInputStream s) throws IOException { if (s.getMajorVersion() >= AjAttribute.WeaverVersionInfo.WEAVER_VERSION_MAJOR_AJ150) { int count = -1; if (s.isAtLeast169()) { count = s.readByte(); } else { count = s.readInt(); } if (count != 0) { List<String> aliases = new ArrayList<String>(); for (int i = 0; i < count; i++) { aliases.add(s.readUTF()); } return aliases; } } return null; }
public static Pointcut read(VersionedDataInputStream s, ISourceContext context) throws IOException { boolean hasTestMethod = s.readBoolean(); ResolvedMember resolvedTestMethod = null; if (hasTestMethod) { // should always have a test method unless @AJ style resolvedTestMethod = ResolvedMemberImpl.readResolvedMember(s, context); } IfPointcut ret = new IfPointcut(resolvedTestMethod, s.readByte()); ret.readLocation(context, s); return ret; }
if (!s.isAtLeast169() || (b = s.readByte()) == 0) { ois = new ObjectInputStream(s); boolean validLocation = (Boolean) ois.readObject();
public static AnnotationTypePattern read(VersionedDataInputStream s, ISourceContext context) throws IOException { byte version = s.readByte(); if (version > VERSION) { throw new BCException("BindingAnnotationTypePattern was written by a more recent version of AspectJ"); } AnnotationTypePattern ret = new BindingAnnotationTypePattern(UnresolvedType.read(s), s.readShort()); ret.readLocation(context, s); return ret; } }
public static ISignaturePattern readCompoundSignaturePattern(VersionedDataInputStream s, ISourceContext context) throws IOException { byte key = s.readByte(); switch (key) { case PATTERN: return SignaturePattern.read(s, context); case AND: return AndSignaturePattern.readAndSignaturePattern(s, context); case OR: return OrSignaturePattern.readOrSignaturePattern(s, context); case NOT: return NotSignaturePattern.readNotSignaturePattern(s, context); default: throw new BCException("unknown SignatureTypePattern kind: " + key); } }
public static AdviceAttribute read(VersionedDataInputStream s, ISourceContext context) throws IOException { AdviceKind kind = AdviceKind.read(s); if (kind == AdviceKind.Around) { return new AdviceAttribute(kind, Pointcut.read(s, context), s.readByte(), s.readInt(), s.readInt(), context, s.readBoolean(), ResolvedMemberImpl.readResolvedMemberArray(s, context), FileUtil.readBooleanArray(s), UnresolvedType.readArray(s)); } else { return new AdviceAttribute(kind, Pointcut.read(s, context), s.readByte(), s.readInt(), s.readInt(), context); } }
public static Declare read(VersionedDataInputStream s, ISourceContext context) throws IOException { byte kind = s.readByte(); switch (kind) { case ERROR_OR_WARNING: return DeclareErrorOrWarning.read(s, context); case DOMINATES: return DeclarePrecedence.read(s, context); case PARENTS: return DeclareParents.read(s, context); case SOFT: return DeclareSoft.read(s, context); case ANNOTATION: return DeclareAnnotation.read(s, context); case PARENTSMIXIN: return DeclareParentsMixin.read(s, context); case TYPE_ERROR_OR_WARNING: return DeclareTypeErrorOrWarning.read(s, context); default: throw new RuntimeException("unimplemented"); } }
public static AnnotationTypePattern read(VersionedDataInputStream s, ISourceContext context) throws IOException { WildAnnotationTypePattern ret; byte version = s.readByte(); if (version > VERSION) { throw new BCException("ExactAnnotationTypePattern was written by a newer version of AspectJ"); } TypePattern t = TypePattern.read(s, context); ret = new WildAnnotationTypePattern(t); ret.readLocation(context, s); if (s.getMajorVersion() >= WeaverVersionInfo.WEAVER_VERSION_MAJOR_AJ160) { if (s.readBoolean()) { ret.setForParameterAnnotationMatch(); } } if (s.getMajorVersion() >= WeaverVersionInfo.WEAVER_VERSION_MAJOR_AJ160M2) { int annotationValueCount = s.readInt(); if (annotationValueCount > 0) { Map<String, String> aValues = new HashMap<String, String>(); for (int i = 0; i < annotationValueCount; i++) { String key = s.readUTF(); String val = s.readUTF(); aValues.put(key, val); } ret.annotationValues = aValues; } } return ret; }
public static AnnotationTypePattern read(VersionedDataInputStream s, ISourceContext context) throws IOException { ExactAnnotationTypePattern ret; byte version = s.readByte(); if (version > VERSION) { throw new BCException("ExactAnnotationTypePattern was written by a newer version of AspectJ");
public static TypePattern readTypePattern150(VersionedDataInputStream s, ISourceContext context) throws IOException { byte version = s.readByte(); if (version > EXACT_VERSION) { throw new BCException("ExactTypePattern was written by a more recent version of AspectJ"); } TypePattern ret = new ExactTypePattern(s.isAtLeast169() ? s.readSignatureAsUnresolvedType() : UnresolvedType.read(s), s .readBoolean(), s.readBoolean()); ret.setAnnotationTypePattern(AnnotationTypePattern.read(s, context)); ret.setTypeParameters(TypePatternList.read(s, context)); ret.readLocation(context, s); return ret; }
public static AnnotationTypePattern read(VersionedDataInputStream s, ISourceContext context) throws IOException { byte key = s.readByte(); switch (key) { case EXACT: return ExactAnnotationTypePattern.read(s, context); case BINDING: return BindingAnnotationTypePattern.read(s, context); case NOT: return NotAnnotationTypePattern.read(s, context); case OR: return OrAnnotationTypePattern.read(s, context); case AND: return AndAnnotationTypePattern.read(s, context); case WILD: return WildAnnotationTypePattern.read(s, context); case EXACTFIELD: return ExactAnnotationFieldTypePattern.read(s, context); case BINDINGFIELD: return BindingAnnotationFieldTypePattern.read(s, context); case BINDINGFIELD2: return BindingAnnotationFieldTypePattern.read2(s, context); case ELLIPSIS_KEY: return ELLIPSIS; case ANY_KEY: return ANY; } throw new BCException("unknown TypePattern kind: " + key); }
public static TypePattern read(VersionedDataInputStream s, ISourceContext context) throws IOException { byte key = s.readByte(); switch (key) { case WILD: return WildTypePattern.read(s, context); case EXACT: return ExactTypePattern.read(s, context); case BINDING: return BindingTypePattern.read(s, context); case ELLIPSIS_KEY: return ELLIPSIS; case ANY_KEY: return ANY; case NO_KEY: return NO; case NOT: return NotTypePattern.read(s, context); case OR: return OrTypePattern.read(s, context); case AND: return AndTypePattern.read(s, context); case ANY_WITH_ANNO: return AnyWithAnnotationTypePattern.read(s, context); case HAS_MEMBER: return HasMemberTypePattern.read(s, context); case TYPE_CATEGORY: return TypeCategoryTypePattern.read(s, context); } throw new BCException("unknown TypePattern kind: " + key); }
public static TypePattern readTypePattern150(VersionedDataInputStream s, ISourceContext context) throws IOException { byte version = s.readByte(); if (version > VERSION) { throw new BCException("WildTypePattern was written by a more recent version of AspectJ, cannot read");
public static Pointcut read(VersionedDataInputStream s, ISourceContext context) throws IOException { byte kind = s.readByte(); Pointcut ret;