diff --git a/org.ntlab.traceAnalyzer/src/org/ntlab/deltaExtractor/Alias.java b/org.ntlab.traceAnalyzer/src/org/ntlab/deltaExtractor/Alias.java new file mode 100644 index 0000000..dac8427 --- /dev/null +++ b/org.ntlab.traceAnalyzer/src/org/ntlab/deltaExtractor/Alias.java @@ -0,0 +1,72 @@ +package org.ntlab.deltaExtractor; +import org.ntlab.trace.MethodExecution; +import org.ntlab.trace.Statement; +import org.ntlab.trace.TracePoint; +/** + * �I�u�W�F�N�g�̎Q�Ə��(�G�C���A�X)��\���N���X + * @author Isitani + * + */ +public class Alias { + private String objectId; + private TracePoint occurrencePoint; // ���Y�I�u�W�F�N�g�̎Q�Ƃ��s���Ă�����s�ӏ��ɑΉ�����TracePoint + private AliasType aliasType; + private int index; + + public enum AliasType { + // ���\�b�h�ւ̓��� + FORMAL_PARAMETER, + THIS, + METHOD_INVOCATION, + CONSTRACTOR_INVOCATION, + + // �ǐՃI�u�W�F�N�g�̐؂�ւ� + FIELD, + CONTAINER, + ARRAY_ELEMENT, + ARRAY, + ARRAY_CREATE, + + // ���\�b�h����̏o�� + ACTUAL_ARGUMENT, + RECEIVER, + RETURN_VALUE + } + + public Alias(AliasType aliasType, int index, String objectId, TracePoint occurrencePoint) { + this.aliasType = aliasType; + this.index = index; + this.objectId = objectId; + this.occurrencePoint = occurrencePoint; + } + + public AliasType getAliasType() { + return aliasType; + } + + public int getIndex() { + return index; + } + + public String getObjectId() { + return objectId; + } + + public TracePoint getOccurrencePoint() { + return occurrencePoint; + } + + public MethodExecution getMethodExecution() { + return occurrencePoint.getMethodExecution(); + } + + public String getMethodSignature() { + return occurrencePoint.getMethodExecution().getCallerSideSignature(); + } + + public int getLineNo() { + Statement statement = occurrencePoint.getStatement(); + return statement.getLineNo(); + } + +} \ No newline at end of file