SubSequence Class
Signature
export declare class SubSequence<T> extends BaseSegment
Extends: BaseSegment
Type Parameters
Parameter | Description |
---|---|
T |
Constructors
Constructor | Description |
---|---|
(constructor)(items) | Constructs a new instance of the SubSequence class |
Static Properties
Property | Type | Description |
---|---|---|
typeString | string |
Static Methods
Method | Return Type | Description |
---|---|---|
fromJSONObject(spec) | SubSequence<U> | |
is(segment) | segment is SubSequence<any> |
Properties
Property | Type | Description |
---|---|---|
items | Serializable<T>[] | |
type | string |
Methods
Method | Return Type | Description |
---|---|---|
append(segment) | void | |
canAppend(segment) | boolean | |
clone(start, end) | SubSequence<T> | |
createSplitSegmentAt(pos) | SubSequence<T> | |
removeRange(start, end) | boolean | |
toJSONObject() | IJSONRunSegment<T> | |
toString() | string |
Constructor Details
(constructor)
Constructs a new instance of the SubSequence
class
Signature
constructor(items: Serializable<T>[]);
Parameters
Parameter | Type | Description |
---|---|---|
items | Serializable<T>[] |
Property Details
items
Signature
items: Serializable<T>[];
Type: Serializable<T>[]
type
Signature
readonly type: string;
Type: string
typeString
Signature
static readonly typeString: string;
Type: string
Method Details
append
Signature
append(segment: ISegment): void;
Parameters
Parameter | Type | Description |
---|---|---|
segment | ISegment |
canAppend
Signature
canAppend(segment: ISegment): boolean;
Parameters
Parameter | Type | Description |
---|---|---|
segment | ISegment |
Returns
Return type: boolean
clone
Signature
clone(start?: number, end?: number): SubSequence<T>;
Parameters
Parameter | Modifiers | Type | Description |
---|---|---|---|
start | optional | number | |
end | optional | number |
Returns
Return type: SubSequence<T>
createSplitSegmentAt
Signature
protected createSplitSegmentAt(pos: number): SubSequence<T>;
Parameters
Parameter | Type | Description |
---|---|---|
pos | number |
Returns
Return type: SubSequence<T>
fromJSONObject
Signature
static fromJSONObject<U>(spec: Serializable): SubSequence<U>;
Type Parameters
Parameter | Description |
---|---|
U |
Parameters
Parameter | Type | Description |
---|---|---|
spec | Serializable |
Returns
Return type: SubSequence<U>
is
Signature
static is(segment: ISegment): segment is SubSequence<any>;
Parameters
Parameter | Type | Description |
---|---|---|
segment | ISegment |
Returns
Return type: segment is SubSequence<any>
removeRange
Signature
removeRange(start: number, end: number): boolean;
Parameters
Parameter | Type | Description |
---|---|---|
start | number | |
end | number |
Returns
Return type: boolean
toJSONObject
Signature
toJSONObject(): IJSONRunSegment<T>;
Returns
Return type: IJSONRunSegment<T>
toString
Signature
toString(): string;
Returns
Return type: string