public abstract class Transcoder extends Object
Modifier and Type | Field and Description |
---|---|
org.jcodings.Encoding |
inEncoding |
RubyCoderResult |
lastResult |
org.jcodings.Encoding |
outEncoding |
protected Ruby |
runtime |
static Set<Charset> |
UNICODE_CHARSETS |
Constructor and Description |
---|
Transcoder(ThreadContext context,
org.jcodings.Encoding outEncoding,
org.jcodings.Encoding inEncoding) |
Modifier and Type | Method and Description |
---|---|
abstract org.jruby.util.ByteList |
convert(ThreadContext context,
org.jruby.util.ByteList value,
boolean is7BitASCII) |
abstract RubyCoderResult |
econvConvert(ThreadContext context,
org.jruby.util.ByteList value,
org.jruby.util.ByteList dest) |
abstract org.jruby.util.ByteList |
econvStrConvert(ThreadContext context,
org.jruby.util.ByteList value,
boolean finish) |
abstract org.jruby.util.ByteList |
finish(org.jcodings.Encoding altEncoding) |
RaiseException |
getLastError() |
RubyCoderResult |
getLastResult() |
static Transcoder |
open(ThreadContext context,
byte[] sourceEncoding,
byte[] destinationEncoding,
int ecflags,
IRubyObject replacement) |
static Transcoder |
open0(ThreadContext context,
byte[] sourceEncoding,
byte[] destinationEncoding,
int ecflags,
IRubyObject replacement) |
abstract RubyCoderResult |
primitiveConvert(ThreadContext context,
org.jruby.util.ByteList inBuffer,
org.jruby.util.ByteList outBuffer,
int outOffset,
int outLimit,
org.jcodings.Encoding inEncoding,
boolean is7BitASCII,
int flags) |
static org.jruby.util.ByteList |
strConvEnc(ThreadContext context,
org.jruby.util.ByteList value,
org.jcodings.Encoding fromEncoding,
org.jcodings.Encoding toEncoding) |
static org.jruby.util.ByteList |
strConvEncOpts(ThreadContext context,
org.jruby.util.ByteList value,
org.jcodings.Encoding fromEncoding,
org.jcodings.Encoding toEncoding,
int ecflags,
IRubyObject ecopts)
This will try and transcode the supplied ByteList to the supplied toEncoding.
|
abstract org.jruby.util.ByteList |
transcode(ThreadContext context,
org.jruby.util.ByteList value) |
abstract org.jruby.util.ByteList |
transcode(ThreadContext context,
org.jruby.util.ByteList value,
boolean is7BitASCII) |
abstract RubyCoderResult |
transcode(ThreadContext context,
org.jruby.util.ByteList value,
org.jruby.util.ByteList dest) |
static org.jruby.util.ByteList |
transcode(ThreadContext context,
org.jruby.util.ByteList value,
org.jcodings.Encoding fromEncoding,
org.jcodings.Encoding toEncoding,
IRubyObject opts,
boolean is7BitASCII) |
protected final Ruby runtime
public final org.jcodings.Encoding outEncoding
public final org.jcodings.Encoding inEncoding
public RubyCoderResult lastResult
public Transcoder(ThreadContext context, org.jcodings.Encoding outEncoding, org.jcodings.Encoding inEncoding)
public static Transcoder open(ThreadContext context, byte[] sourceEncoding, byte[] destinationEncoding, int ecflags, IRubyObject replacement)
public static Transcoder open0(ThreadContext context, byte[] sourceEncoding, byte[] destinationEncoding, int ecflags, IRubyObject replacement)
public static org.jruby.util.ByteList strConvEncOpts(ThreadContext context, org.jruby.util.ByteList value, org.jcodings.Encoding fromEncoding, org.jcodings.Encoding toEncoding, int ecflags, IRubyObject ecopts)
public static org.jruby.util.ByteList strConvEnc(ThreadContext context, org.jruby.util.ByteList value, org.jcodings.Encoding fromEncoding, org.jcodings.Encoding toEncoding)
public static org.jruby.util.ByteList transcode(ThreadContext context, org.jruby.util.ByteList value, org.jcodings.Encoding fromEncoding, org.jcodings.Encoding toEncoding, IRubyObject opts, boolean is7BitASCII)
public abstract RubyCoderResult transcode(ThreadContext context, org.jruby.util.ByteList value, org.jruby.util.ByteList dest)
public abstract RubyCoderResult econvConvert(ThreadContext context, org.jruby.util.ByteList value, org.jruby.util.ByteList dest)
public abstract org.jruby.util.ByteList transcode(ThreadContext context, org.jruby.util.ByteList value)
public abstract org.jruby.util.ByteList transcode(ThreadContext context, org.jruby.util.ByteList value, boolean is7BitASCII)
public abstract org.jruby.util.ByteList convert(ThreadContext context, org.jruby.util.ByteList value, boolean is7BitASCII)
public abstract org.jruby.util.ByteList econvStrConvert(ThreadContext context, org.jruby.util.ByteList value, boolean finish)
public abstract RubyCoderResult primitiveConvert(ThreadContext context, org.jruby.util.ByteList inBuffer, org.jruby.util.ByteList outBuffer, int outOffset, int outLimit, org.jcodings.Encoding inEncoding, boolean is7BitASCII, int flags)
public abstract org.jruby.util.ByteList finish(org.jcodings.Encoding altEncoding)
public RubyCoderResult getLastResult()
public RaiseException getLastError()
Copyright © 2001-2017 JRuby. All Rights Reserved.