Class StackTraceFactory
- java.lang.Object
-
- org.openjdk.jmc.flightrecorder.internal.parser.v0.factories.StackTraceFactory
-
- All Implemented Interfaces:
IPoolFactory<IMCStackTrace>
final class StackTraceFactory extends java.lang.Object implements IPoolFactory<IMCStackTrace>
Factory that create anIMCStackTrace
from the stack trace pool. If the same stack trace has been created before that trace is returned instead.
-
-
Field Summary
Fields Modifier and Type Field Description private int
m_bciIndex
private int
m_fieldCount
private int
m_frameIndex
private int
m_frameTypeIndex
private int
m_lineNumberIndex
private int
m_methodIndex
private int
m_truncateIndex
private CanonicalConstantMap<IMCStackTrace>
traceMap
-
Constructor Summary
Constructors Constructor Description StackTraceFactory(ValueDescriptor[] traceDescriptors, CanonicalConstantMap<IMCStackTrace> traceMap)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description private static java.util.List<IMCFrame>
buildFilteredStackTrace(IMCFrame[] frames)
private IMCFrame
createFrame(java.lang.Object[] frameObject)
IMCStackTrace
createObject(long identifier, java.lang.Object o)
Creates a replacement object for a value in a poolprivate IMCStackTrace
createTrace(java.lang.Object o)
ContentType<IMCStackTrace>
getContentType()
-
-
-
Field Detail
-
m_frameIndex
private final int m_frameIndex
-
m_truncateIndex
private final int m_truncateIndex
-
m_methodIndex
private final int m_methodIndex
-
m_lineNumberIndex
private final int m_lineNumberIndex
-
m_frameTypeIndex
private final int m_frameTypeIndex
-
m_bciIndex
private final int m_bciIndex
-
m_fieldCount
private final int m_fieldCount
-
traceMap
private final CanonicalConstantMap<IMCStackTrace> traceMap
-
-
Constructor Detail
-
StackTraceFactory
public StackTraceFactory(ValueDescriptor[] traceDescriptors, CanonicalConstantMap<IMCStackTrace> traceMap) throws InvalidJfrFileException
- Throws:
InvalidJfrFileException
-
-
Method Detail
-
createObject
public IMCStackTrace createObject(long identifier, java.lang.Object o)
Description copied from interface:IPoolFactory
Creates a replacement object for a value in a pool- Specified by:
createObject
in interfaceIPoolFactory<IMCStackTrace>
- Parameters:
identifier
- the identifier that is used to look up the object- Returns:
- the replacement object that will be used instead
-
createTrace
private IMCStackTrace createTrace(java.lang.Object o)
-
buildFilteredStackTrace
private static java.util.List<IMCFrame> buildFilteredStackTrace(IMCFrame[] frames)
-
createFrame
private IMCFrame createFrame(java.lang.Object[] frameObject)
-
getContentType
public ContentType<IMCStackTrace> getContentType()
- Specified by:
getContentType
in interfaceIPoolFactory<IMCStackTrace>
-
-