RunSegment Class
This API is deprecated and will be removed in a future release.
RunSegment is part of an abandoned prototype. Use SharedMatrix instead.
Signature
export declare class RunSegment extends SubSequence<SparseMatrixItem>
Extends: SubSequence<SparseMatrixItem
Constructors
Constructor | Description |
---|---|
(constructor)(items) | Constructs a new instance of the RunSegment class |
Static Properties
Property | Type | Description |
---|---|---|
typeString |
Static Methods
Method | Return Type | Description |
---|---|---|
fromJSONObject(spec) | RunSegment | |
is(segment) | segment is RunSegment |
Properties
Property | Type | Description |
---|---|---|
items | SparseMatrixItem[] | |
type |
Methods
Method | Return Type | Description |
---|---|---|
append(segment) | this | |
clone(start, end) | RunSegment | |
createSplitSegmentAt(pos) | RunSegment | |
getTag(pos) | any | |
removeRange(start, end) | boolean | |
setTag(pos, tag) | void |
Constructor Details
(constructor)
Constructs a new instance of the RunSegment
class
Signature
constructor(items: SparseMatrixItem[]);
Parameters
Parameter | Type | Description |
---|---|---|
items | SparseMatrixItem[] |
Property Details
items
Signature
items: SparseMatrixItem[];
Type: SparseMatrixItem[]
type
Signature
readonly type = "RunSegment";
typeString
Signature
static readonly typeString = "RunSegment";
Method Details
append
Signature
append(segment: ISegment): this;
Parameters
Parameter | Type | Description |
---|---|---|
segment | ISegment |
Returns
Return type: this
clone
Signature
clone(start?: number, end?: number): RunSegment;
Parameters
Parameter | Modifiers | Type | Description |
---|---|---|---|
start | optional | number | |
end | optional | number |
Returns
Return type: RunSegment
createSplitSegmentAt
Signature
protected createSplitSegmentAt(pos: number): RunSegment;
Parameters
Parameter | Type | Description |
---|---|---|
pos | number |
Returns
Return type: RunSegment
fromJSONObject
Signature
static fromJSONObject(spec: any): RunSegment;
Parameters
Parameter | Type | Description |
---|---|---|
spec | any |
Returns
Return type: RunSegment
getTag
Signature
getTag(pos: number): any;
Parameters
Parameter | Type | Description |
---|---|---|
pos | number |
Returns
Return type: any
is
Signature
static is(segment: ISegment): segment is RunSegment;
Parameters
Parameter | Type | Description |
---|---|---|
segment | ISegment |
Returns
Return type: segment is RunSegment
removeRange
Signature
removeRange(start: number, end: number): boolean;
Parameters
Parameter | Type | Description |
---|---|---|
start | number | |
end | number |
Returns
Return type: boolean
setTag
Signature
setTag(pos: number, tag: any): void;
Parameters
Parameter | Type | Description |
---|---|---|
pos | number | |
tag | any |