Top Description Fields Constructors Methods
org.jruby.ir.persistence

public Class IRWriterStream

extends Object
implements IRWriterEncoder, IRPersistenceValues
Class Inheritance
All Implemented Interfaces
org.jruby.ir.persistence.IRPersistenceValues, org.jruby.ir.persistence.IRWriterEncoder
Imports
org.jcodings.Encoding, org.jcodings.specific.USASCIIEncoding, .UTF8Encoding, org.jruby.RubySymbol, org.jruby.ir.IRFlags, .IRScope, .IRScopeType, .Operation, org.jruby.ir.instructions.Instr, org.jruby.ir.operands.LocalVariable, .Operand, .OperandType, org.jruby.parser.StaticScope, java.io.File, .FileNotFoundException, .FileOutputStream, .IOException, .OutputStream, java.nio.ByteBuffer, java.util.Collections, .Comparator, .EnumSet, .HashMap, .LinkedList, .List, .Map, .Map.Entry, org.jruby.runtime.RubyEvent, .Signature, org.jruby.util.ByteList

Represents a file which is persisted to storage.

Field Summary

Modifier and TypeField and Description
private final IRWriterAnalyzer
private final ByteBuffer
private final Map<RubySymbol, Integer>
pack-priv IRScope
pack-priv int
private final Map<IRScope, Integer>
private final Map<IRScope, Integer>
private final OutputStream

Constructor Summary

AccessConstructor and Description
public
public

Method Summary

Modifier and TypeMethod and Description
public void
addScopeInstructionOffset(IRScope scope)

Record current offset as the beginning of specified scopes list of instructions.

public void
public void
public void
public void
public void
public void
public void
public void
public void
public void
public void
public void
public void
public void
public void
public void
public void
public void
public void
public void
public void
public void
public void
public void
public void
public void
public void
public void
public void
public void
public IRScope
public int
getScopeInstructionOffset(IRScope scope)

Get recorded offset for this scropes instruction list.

public boolean
private int
public void
public void
public void
public void
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

analyzerback to summary
private final IRWriterAnalyzer analyzer
bufback to summary
private final ByteBuffer buf
constantMapback to summary
private final Map<RubySymbol, Integer> constantMap
currentScopeback to summary
pack-priv IRScope currentScope
headersOffsetback to summary
pack-priv int headersOffset
scopeInstructionOffsetsback to summary
private final Map<IRScope, Integer> scopeInstructionOffsets
scopePoolOffsetsback to summary
private final Map<IRScope, Integer> scopePoolOffsets
streamback to summary
private final OutputStream stream

Constructor Detail

IRWriterStreamback to summary
public IRWriterStream(OutputStream stream)
IRWriterStreamback to summary
public IRWriterStream(File file) throws FileNotFoundException

Method Detail

addScopeInstructionOffsetback to summary
public void addScopeInstructionOffset(IRScope scope)

Record current offset as the beginning of specified scopes list of instructions.

encodeback to summary
public void encode(boolean value)

Implements org.jruby.ir.persistence.IRWriterEncoder.encode.

Annotations
@Override
encodeback to summary
public void encode(byte value)

Implements org.jruby.ir.persistence.IRWriterEncoder.encode.

Annotations
@Override
encodeback to summary
public void encode(char value)

Implements org.jruby.ir.persistence.IRWriterEncoder.encode.

Annotations
@Override
encodeback to summary
public void encode(int value)

Implements org.jruby.ir.persistence.IRWriterEncoder.encode.

Annotations
@Override
encodeback to summary
public void encode(int[] value)

Implements org.jruby.ir.persistence.IRWriterEncoder.encode.

Annotations
@Override
encodeback to summary
public void encode(long value)

Implements org.jruby.ir.persistence.IRWriterEncoder.encode.

Annotations
@Override
encodeback to summary
public void encode(float value)

Implements org.jruby.ir.persistence.IRWriterEncoder.encode.

Annotations
@Override
encodeback to summary
public void encode(EnumSet<IRFlags> values)

Implements org.jruby.ir.persistence.IRWriterEncoder.encode.

Annotations
@Override
encodeback to summary
public void encode(double value)

Implements org.jruby.ir.persistence.IRWriterEncoder.encode.

Annotations
@Override
encodeback to summary
public void encode(ByteList value)

Implements org.jruby.ir.persistence.IRWriterEncoder.encode.

Annotations
@Override
encodeback to summary
public void encode(byte[] bytes)

Implements org.jruby.ir.persistence.IRWriterEncoder.encode.

Annotations
@Override
encodeback to summary
public void encode(Encoding encoding)

Implements org.jruby.ir.persistence.IRWriterEncoder.encode.

Annotations
@Override
encodeback to summary
public void encode(RubySymbol symbol)

Implements org.jruby.ir.persistence.IRWriterEncoder.encode.

Annotations
@Override
encodeback to summary
public void encode(String value)

Implements org.jruby.ir.persistence.IRWriterEncoder.encode.

Annotations
@Override
encodeback to summary
public void encode(String[] values)

Implements org.jruby.ir.persistence.IRWriterEncoder.encode.

Annotations
@Override
encodeback to summary
public void encode(Operand operand)

Implements org.jruby.ir.persistence.IRWriterEncoder.encode.

Annotations
@Override
encodeback to summary
public void encode(Operand[] operands)

Implements org.jruby.ir.persistence.IRWriterEncoder.encode.

Annotations
@Override
encodeback to summary
public void encode(Instr instr)

Implements org.jruby.ir.persistence.IRWriterEncoder.encode.

Annotations
@Override
encodeback to summary
public void encode(IRScope value)

Implements org.jruby.ir.persistence.IRWriterEncoder.encode.

Annotations
@Override
encodeback to summary
public void encode(IRScopeType value)

Implements org.jruby.ir.persistence.IRWriterEncoder.encode.

Annotations
@Override
encodeback to summary
public void encode(Signature signature)

Implements org.jruby.ir.persistence.IRWriterEncoder.encode.

Annotations
@Override
encodeback to summary
public void encode(RubyEvent event)

Implements org.jruby.ir.persistence.IRWriterEncoder.encode.

Annotations
@Override
encodeback to summary
public void encode(StaticScope.Type value)

Implements org.jruby.ir.persistence.IRWriterEncoder.encode.

Annotations
@Override
encodeback to summary
public void encode(Operation value)

Implements org.jruby.ir.persistence.IRWriterEncoder.encode.

Annotations
@Override
encodeback to summary
public void encode(OperandType value)

Implements org.jruby.ir.persistence.IRWriterEncoder.encode.

Annotations
@Override
encodeRawback to summary
public void encodeRaw(RubySymbol symbol)

Implements org.jruby.ir.persistence.IRWriterEncoder.encodeRaw.

endEncodingback to summary
public void endEncoding(IRScope script)

Implements org.jruby.ir.persistence.IRWriterEncoder.endEncoding.

Annotations
@Override
endEncodingScopeHeaderback to summary
public void endEncodingScopeHeader(IRScope scope)

Implements org.jruby.ir.persistence.IRWriterEncoder.endEncodingScopeHeader.

Annotations
@Override
endEncodingScopeHeadersback to summary
public void endEncodingScopeHeaders(IRScope script)

Implements org.jruby.ir.persistence.IRWriterEncoder.endEncodingScopeHeaders.

Annotations
@Override
endEncodingScopeInstrsback to summary
public void endEncodingScopeInstrs(IRScope scope)

Implements org.jruby.ir.persistence.IRWriterEncoder.endEncodingScopeInstrs.

Annotations
@Override
getCurrentScopeback to summary
public IRScope getCurrentScope()

Implements org.jruby.ir.persistence.IRWriterEncoder.getCurrentScope.

getScopeInstructionOffsetback to summary
public int getScopeInstructionOffset(IRScope scope)

Get recorded offset for this scropes instruction list.

isAnalyzerback to summary
public boolean isAnalyzer()

Implements org.jruby.ir.persistence.IRWriterEncoder.isAnalyzer.

Annotations
@Override
offsetback to summary
private int offset()
startEncodingback to summary
public void startEncoding(IRScope script)

Implements org.jruby.ir.persistence.IRWriterEncoder.startEncoding.

Annotations
@Override
startEncodingScopeHeaderback to summary
public void startEncodingScopeHeader(IRScope scope)

Implements org.jruby.ir.persistence.IRWriterEncoder.startEncodingScopeHeader.

Annotations
@Override
startEncodingScopeHeadersback to summary
public void startEncodingScopeHeaders(IRScope script)

Implements org.jruby.ir.persistence.IRWriterEncoder.startEncodingScopeHeaders.

Annotations
@Override
startEncodingScopeInstrsback to summary
public void startEncodingScopeInstrs(IRScope scope)

Implements org.jruby.ir.persistence.IRWriterEncoder.startEncodingScopeInstrs.

Annotations
@Override