Package Exports
- functional-types
- functional-types/lib/FileType
- functional-types/lib/Folder
- functional-types/lib/TableAnnotation
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (functional-types) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
functional-types
Index
Modules
- "DateTime"
- "FileType"
- "Folder/Arbitraries"
- "Folder/index"
- "Label"
- "String"
- "TableAnnotation"
- "Vertex/Arbitraries"
- "Vertex/index"
- "index"
functional-types
Interfaces
functional-types › "Folder/index" › Attributes
Interface: Attributes
Hierarchy
- Attributes
Index
Properties
Properties
folder
• folder: string
Defined in Folder/index.ts:29
id
• id: string
Defined in Folder/index.ts:28
name
• name: string
Defined in Folder/index.ts:30
type
• type: FT.FileType
Defined in Folder/index.ts:31
functional-types › "Folder/index" › Folder
Interface: Folder
Hierarchy
- Folder
Index
Properties
Properties
created_at
• created_at: string
Defined in Folder/index.ts:23
id
• id: string
Defined in Folder/index.ts:21
name
• name: string
Defined in Folder/index.ts:22
updated_at
• updated_at: string
Defined in Folder/index.ts:24
functional-types › "Folder/index" › Metadata
Interface: Metadata
Hierarchy
- Metadata
Index
Properties
Properties
bucket
• bucket: string
Defined in Folder/index.ts:40
content_type
• content_type: string
Defined in Folder/index.ts:42
created_at
• created_at: string
Defined in Folder/index.ts:44
generation
• generation: string
Defined in Folder/index.ts:41
id
• id: string
Defined in Folder/index.ts:36
kind
• kind: string
Defined in Folder/index.ts:35
media_link
• media_link: string
Defined in Folder/index.ts:38
name
• name: string
Defined in Folder/index.ts:39
self_link
• self_link: string
Defined in Folder/index.ts:37
size
• size: string
Defined in Folder/index.ts:43
updated_at
• updated_at: string
Defined in Folder/index.ts:45
functional-types › "Label" › Label
Interface: Label
Hierarchy
- Label
Index
Properties
Properties
color
• color: string
Defined in Label.ts:6
id
• id: string
Defined in Label.ts:4
name
• name: string
Defined in Label.ts:5
functional-types › "TableAnnotation" › TableAnnotation
Interface: TableAnnotation
Hierarchy
- TableAnnotation
Index
Properties
Properties
boundingBoxesByPage
• boundingBoxesByPage: BoundingBoxesByPage
Defined in TableAnnotation.ts:22
created_at
• created_at: string
Defined in TableAnnotation.ts:23
file
• file: string
Defined in TableAnnotation.ts:21
id
• id: string
Defined in TableAnnotation.ts:20
updated_at
• updated_at: string
Defined in TableAnnotation.ts:24
functional-types › "Vertex/index" › BoundingBox
Interface: BoundingBox
Hierarchy
BoundingBox
Index
Properties
Properties
boundingPoly
• boundingPoly: Poly
Defined in Vertex/index.ts:47
columns
• columns: Line[]
Defined in Vertex/index.ts:49
rows
• rows: Line[]
Defined in Vertex/index.ts:48
functional-types › "Vertex/index" › Corners
Interface: Corners
Hierarchy
- Corners
Index
Properties
Properties
end
• end: Vertex
Defined in Vertex/index.ts:71
start
• start: Vertex
Defined in Vertex/index.ts:70
functional-types › "Vertex/index" › LabeledBoundingBox
Interface: LabeledBoundingBox
Hierarchy
-
↳ LabeledBoundingBox
Index
Properties
Properties
boundingPoly
• boundingPoly: Poly
Inherited from BoundingBox.boundingPoly
Defined in Vertex/index.ts:47
columns
• columns: Line[]
Inherited from BoundingBox.columns
Defined in Vertex/index.ts:49
id
• id: string
Defined in Vertex/index.ts:65
label
• label: string
Defined in Vertex/index.ts:66
rows
• rows: Line[]
Inherited from BoundingBox.rows
Defined in Vertex/index.ts:48
functional-types › "Vertex/index" › Vertex
Interface: Vertex
Hierarchy
- Vertex
Index
Properties
Properties
x
• x: number
Defined in Vertex/index.ts:35
y
• y: number
Defined in Vertex/index.ts:36
Modules
Module: "DateTime"
Index
Variables
Functions
Variables
Const getCurrentUnixTimestamp
• getCurrentUnixTimestamp: function = Date.now
Defined in DateTime.ts:14
getCurrentUnixTimestamp :: () -> IntType declaration:
▸ (): number
Functions
Const getCurrentDate
▸ getCurrentDate(): Date
Defined in DateTime.ts:16
Returns: Date
Const getUnixTimestamp
▸ getUnixTimestamp(date: Date): number
Defined in DateTime.ts:6
getUnixTimestamp :: Date -> IntParameters:
| Name | Type |
|---|---|
date |
Date |
Returns: number
Module: "FileType"
Index
Type aliases
Variables
- contentTypes
- documentTypes
- fileContentTypes
- fileTypes
- fromContentType
- fromDocumentContentType
- fromImageContentType
- imageContentTypes
- imageTypes
- toContentType
- toDocumentContentType
- toImageContentType
Functions
Type aliases
ContentType
Ƭ ContentType: DocumentContentType | ImageContentType
Defined in FileType.ts:26
DocumentContentType
Ƭ DocumentContentType: "application/pdf" | "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet" | "application/json"
Defined in FileType.ts:19
DocumentType
Ƭ DocumentType: "pdf" | "excel" | "json"
Defined in FileType.ts:13
FileType
Ƭ FileType: DocumentType | ImageType
Defined in FileType.ts:17
ImageContentType
Ƭ ImageContentType: "image/png" | "image/jpeg"
Defined in FileType.ts:24
ImageType
Ƭ ImageType: "png" | "jpeg"
Defined in FileType.ts:15
Variables
Const contentTypes
• contentTypes: ContentType[] = values(FileTypeToContentType)
Defined in FileType.ts:151
contentTypes: [ContentType]Const documentTypes
• documentTypes: DocumentType[] = keys(DocumentTypeToContentType)
Defined in FileType.ts:112
documentTypes: [DocumentType]Const fileContentTypes
• fileContentTypes: DocumentContentType[] = values( DocumentTypeToContentType )
Defined in FileType.ts:133
contentTypes: [DocumentContentType]Const fileTypes
• fileTypes: FileType[] = keys(FileTypeToContentType)
Defined in FileType.ts:126
fileTypes: [FileType]Const fromContentType
• fromContentType: function = prop( __, ContentTypeToFileType )
Defined in FileType.ts:252
fromContentType :: ContentType -> FileTypeType declaration:
▸ (contentType: ContentType): FileType
Parameters:
| Name | Type |
|---|---|
contentType |
ContentType |
Const fromDocumentContentType
• fromDocumentContentType: function = prop(__, ContentTypeToDocumentType)
Defined in FileType.ts:234
fromDocumentContentType :: DocumentContentType -> DocumentTypeType declaration:
▸ (contentType: DocumentContentType): DocumentType
Parameters:
| Name | Type |
|---|---|
contentType |
DocumentContentType |
Const fromImageContentType
• fromImageContentType: function = prop(__, ContentTypeToImageType)
Defined in FileType.ts:243
fromImageContentType :: DocumentContentType -> DocumentTypeType declaration:
▸ (contentType: ImageContentType): ImageType
Parameters:
| Name | Type |
|---|---|
contentType |
ImageContentType |
Const imageContentTypes
• imageContentTypes: ImageContentType[] = values( ImageTypeToContentType )
Defined in FileType.ts:142
imageContentTypes: [DocumentContentType]Const imageTypes
• imageTypes: ImageType[] = keys(ImageTypeToContentType)
Defined in FileType.ts:119
imageTypes: [DocumentType]Const toContentType
• toContentType: function = prop( __, FileTypeToContentType )
Defined in FileType.ts:224
toContentType :: FileType -> ContentTypeType declaration:
▸ (fileType: FileType): ContentType
Parameters:
| Name | Type |
|---|---|
fileType |
FileType |
Const toDocumentContentType
• toDocumentContentType: function = prop(__, DocumentTypeToContentType)
Defined in FileType.ts:206
toDocumentContentType :: DocumentType -> DocumentContentTypeType declaration:
▸ (fileType: DocumentType): DocumentContentType
Parameters:
| Name | Type |
|---|---|
fileType |
DocumentType |
Const toImageContentType
• toImageContentType: function = prop(__, ImageTypeToContentType)
Defined in FileType.ts:215
toImageContentType :: DocumentType -> ImageContentTypeType declaration:
▸ (imageType: ImageType): ImageContentType
Parameters:
| Name | Type |
|---|---|
imageType |
ImageType |
Functions
Const isContentType
▸ isContentType(a: unknown): a is ContentType
Defined in FileType.ts:198
isContentType :: a -> boolParameters:
| Name | Type |
|---|---|
a |
unknown |
Returns: a is ContentType
Const isDocumentContentType
▸ isDocumentContentType(a: unknown): a is DocumentContentType
Defined in FileType.ts:182
isDocumentContentType :: a -> boolParameters:
| Name | Type |
|---|---|
a |
unknown |
Returns: a is DocumentContentType
Const isDocumentType
▸ isDocumentType(a: unknown): a is DocumentType
Defined in FileType.ts:158
isDocumentType :: a -> boolParameters:
| Name | Type |
|---|---|
a |
unknown |
Returns: a is DocumentType
Const isFileType
▸ isFileType(a: unknown): a is ImageType
Defined in FileType.ts:174
isFileType :: a -> boolParameters:
| Name | Type |
|---|---|
a |
unknown |
Returns: a is ImageType
Const isImageContentType
▸ isImageContentType(a: unknown): a is ImageContentType
Defined in FileType.ts:190
isDocumentContentType :: a -> boolParameters:
| Name | Type |
|---|---|
a |
unknown |
Returns: a is ImageContentType
Const isImageType
▸ isImageType(a: unknown): a is ImageType
Defined in FileType.ts:166
isImageType :: a -> boolParameters:
| Name | Type |
|---|---|
a |
unknown |
Returns: a is ImageType
functional-types › "Folder/Arbitraries"
Module: "Folder/Arbitraries"
Index
Functions
Functions
Const file
▸ file(): Arbitrary‹File›
Defined in Folder/Arbitraries.ts:47
Returns: Arbitrary‹File›
Const filesByType
▸ filesByType(): Arbitrary‹FilesByType›
Defined in Folder/Arbitraries.ts:57
Returns: Arbitrary‹FilesByType›
Const folder
▸ folder(): Arbitrary‹Folder›
Defined in Folder/Arbitraries.ts:29
Returns: Arbitrary‹Folder›
Const invalidFolderObject
▸ invalidFolderObject(): Arbitrary‹Record‹string, any››
Defined in Folder/Arbitraries.ts:5
Returns: Arbitrary‹Record‹string, any››
Const metadata
▸ metadata(): Arbitrary‹Metadata›
Defined in Folder/Arbitraries.ts:32
Returns: Arbitrary‹Metadata›
Const nonFolderObject
▸ nonFolderObject(): Arbitrary‹unknown›
Defined in Folder/Arbitraries.ts:15
Returns: Arbitrary‹unknown›
functional-types › "Folder/index"
Module: "Folder/index"
Index
Interfaces
Type aliases
Variables
Functions
Type aliases
File
Ƭ File: Attributes & object
Defined in Folder/index.ts:48
FilesByType
Ƭ FilesByType: Record‹FT.DocumentType, File[]›
Defined in Folder/index.ts:50
Variables
Const getAttributesFromName
• getAttributesFromName: function = pipe( split('/'), E.fromPredicate( (segments: string[]) => segments.length >= 2, () => new Error('Invalid file name format.') ), E.map(([folder, ...names]: string[]) => { const name = names.join('/'); return { id: join('/')([folder, name]), folder, name, }; }) )
Defined in Folder/index.ts:157
getAttributesFromName :: String -> Either Attributes ErrorType declaration:
▸ (name: string): E.Either‹Error, Omit‹Attributes, "type"››
Parameters:
| Name | Type |
|---|---|
name |
string |
Functions
Const fromMetadata
▸ fromMetadata(metadata: Metadata): Left‹Error› | Right‹object›
Defined in Folder/index.ts:180
fromMetadata :: Metadata -> EitherParameters:
| Name | Type |
|---|---|
metadata |
Metadata |
Returns: Left‹Error› | Right‹object›
Const isFile
▸ isFile(a: unknown): a is File
Defined in Folder/index.ts:130
isFile :: a -> boolParameters:
| Name | Type |
|---|---|
a |
unknown |
Returns: a is File
Const isFileArray
▸ isFileArray(a: unknown): a is File[]
Defined in Folder/index.ts:138
isFileArray :: a -> boolParameters:
| Name | Type |
|---|---|
a |
unknown |
Returns: a is File[]
Const isFilesByType
▸ isFilesByType(a: unknown): a is FilesByType
Defined in Folder/index.ts:146
isFilesByType :: a -> boolParameters:
| Name | Type |
|---|---|
a |
unknown |
Returns: a is FilesByType
Const isFolder
▸ isFolder(a: unknown): a is Folder
Defined in Folder/index.ts:57
isFolder -> boolParameters:
| Name | Type |
|---|---|
a |
unknown |
Returns: a is Folder
Const isMetadata
▸ isMetadata(a: unknown): a is Metadata
Defined in Folder/index.ts:107
isMetadata :: a -> boolParameters:
| Name | Type |
|---|---|
a |
unknown |
Returns: a is Metadata
Const make
▸ make(name: string): (Anonymous function)
Defined in Folder/index.ts:71
make :: String -> FolderParameters:
| Name | Type |
|---|---|
name |
string |
Returns: (Anonymous function)
Module: "index"
Index
References
References
F
• F:
FT
• FT:
L
• L:
T
• T:
V
• V:
Module: "Label"
Index
Interfaces
Type aliases
Variables
Functions
Type aliases
ColorMappings
Ƭ ColorMappings: Record‹string, string›
Defined in Label.ts:9
Variables
Const toColorMappings
• toColorMappings: function = reduce( (acc: ColorMappings, label: Label) => assoc(label.id, label.color)(acc), {} )
Defined in Label.ts:29
toColorMappings :: [Label] -> ColorMappingsType declaration:
▸ (labels: Label[]): ColorMappings
Parameters:
| Name | Type |
|---|---|
labels |
Label[] |
Functions
Const isLabel
▸ isLabel(a: unknown): a is Label
Defined in Label.ts:16
isLabel :: a -> boolParameters:
| Name | Type |
|---|---|
a |
unknown |
Returns: a is Label
Module: "String"
Index
Variables
Variables
Const getRandomId
• getRandomId: IO‹string› = uuid
Defined in String.ts:9
getRandomId: IO String
functional-types › "TableAnnotation"
Module: "TableAnnotation"
Index
Interfaces
Type aliases
Functions
Type aliases
BoundingBoxes
Ƭ BoundingBoxes: Dictionary‹LabeledBoundingBox›
Defined in TableAnnotation.ts:15
BoundingBoxesByPage
Ƭ BoundingBoxesByPage: BoundingBoxes[]
Defined in TableAnnotation.ts:17
TableAnnotationBase
Ƭ TableAnnotationBase: Pick‹TableAnnotation, "file" | "boundingBoxesByPage"›
Defined in TableAnnotation.ts:27
Functions
Const isBoundingBoxes
▸ isBoundingBoxes(a: unknown): a is BoundingBoxes
Defined in TableAnnotation.ts:37
isBoundingBoxes :: a -> boolParameters:
| Name | Type |
|---|---|
a |
unknown |
Returns: a is BoundingBoxes
Const isBoundingBoxesByPage
▸ isBoundingBoxesByPage(a: unknown): a is BoundingBoxesByPage
Defined in TableAnnotation.ts:47
isBoundingBoxesByPage :: a -> boolParameters:
| Name | Type |
|---|---|
a |
unknown |
Returns: a is BoundingBoxesByPage
Const isTableAnnotation
▸ isTableAnnotation(a: unknown): a is TableAnnotation
Defined in TableAnnotation.ts:67
isTableAnnotation :: a -> boolParameters:
| Name | Type |
|---|---|
a |
unknown |
Returns: a is TableAnnotation
Const isTableAnnotationBase
▸ isTableAnnotationBase(a: unknown): a is TableAnnotationBase
Defined in TableAnnotation.ts:55
isTableAnnotationBase :: a -> boolParameters:
| Name | Type |
|---|---|
a |
unknown |
Returns: a is TableAnnotationBase
Const make
▸ make(__namedParameters: object): (Anonymous function)
Defined in TableAnnotation.ts:82
make :: (String, BoundingBoxesByPage) -> IO TableAnnotationParameters:
▪ __namedParameters: object
| Name | Type |
|---|---|
boundingBoxesByPage |
Dictionary‹LabeledBoundingBox›[] |
file |
string |
Returns: (Anonymous function)
functional-types › "Vertex/Arbitraries"
Module: "Vertex/Arbitraries"
Index
Functions
Functions
Const boundingBox
▸ boundingBox(): Arbitrary‹BoundingBox›
Defined in Vertex/Arbitraries.ts:23
Returns: Arbitrary‹BoundingBox›
Const poly
▸ poly(): Arbitrary‹Poly›
Defined in Vertex/Arbitraries.ts:20
Returns: Arbitrary‹Poly›
Const vertex
▸ vertex(): Arbitrary‹Vertex›
Defined in Vertex/Arbitraries.ts:14
Returns: Arbitrary‹Vertex›
Const withHeaderArguments
▸ withHeaderArguments(): Arbitrary‹object›
Defined in Vertex/Arbitraries.ts:35
Returns: Arbitrary‹object›
functional-types › "Vertex/index"
Module: "Vertex/index"
Index
Interfaces
Type aliases
Variables
- getBottomLeft
- getBottomRight
- getCornersFromPoly
- getTopLeft
- getTopRight
- getX
- getXs
- getY
- getYs
- heightOf
- widthOf
Functions
- append
- hasHeader
- hasHeaderColumn
- hasHeaderRow
- isBoundingBox
- isLabeledBoundingBox
- isLine
- isPoly
- isVertex
- lengthOf
- makeBoundingBox
- makeLabeledBoundingBox
- makeLine
- makePoly
- makeVertex
- withHeader
- withHeaderColumn
- withHeaderRow
Type aliases
Line
Defined in Vertex/index.ts:39
Poly
Ƭ Poly: [Vertex, Vertex, Vertex, Vertex]
Defined in Vertex/index.ts:44
[TopLeft, TopRight, BottomLeft, BottomRight]
WithHeader
Ƭ WithHeader: WithHeaderRow‹A› | WithHeaderColumn‹A›
Defined in Vertex/index.ts:60
WithHeaderColumn
Ƭ WithHeaderColumn: A & object
Defined in Vertex/index.ts:56
WithHeaderRow
Ƭ WithHeaderRow: A & object
Defined in Vertex/index.ts:52
Variables
Const getBottomLeft
• getBottomLeft: function = nth(2)
Defined in Vertex/index.ts:392
getBottomLeft :: Poly -> VertexType declaration:
Parameters:
| Name | Type |
|---|---|
poly |
Poly |
Const getBottomRight
• getBottomRight: function = nth(3)
Defined in Vertex/index.ts:399
getBottomRight :: Poly -> VertexType declaration:
Parameters:
| Name | Type |
|---|---|
poly |
Poly |
Const getCornersFromPoly
• getCornersFromPoly: function = applySpec({ start: head, end: last, })
Defined in Vertex/index.ts:241
getCornersFromPoly :: Poly -> CornersType declaration:
Parameters:
| Name | Type |
|---|---|
poly |
Poly |
Const getTopLeft
• getTopLeft: function = nth(0)
Defined in Vertex/index.ts:378
getTopLeft :: Poly -> VertexType declaration:
Parameters:
| Name | Type |
|---|---|
poly |
Poly |
Const getTopRight
• getTopRight: function = nth(1)
Defined in Vertex/index.ts:385
getTopRight :: Poly -> VertexType declaration:
Parameters:
| Name | Type |
|---|---|
poly |
Poly |
Const getX
• getX: function = pipe(head, prop<'x', number>('x'))
Defined in Vertex/index.ts:309
getX :: Line -> IntType declaration:
▸ (line: Line): number
Parameters:
| Name | Type |
|---|---|
line |
Line |
Const getXs
• getXs: function = map(getX)
Defined in Vertex/index.ts:323
getXs :: [Line] -> [Int]Type declaration:
▸ (lines: Line[]): number[]
Parameters:
| Name | Type |
|---|---|
lines |
Line[] |
Const getY
• getY: function = pipe(head, prop<'y', number>('y'))
Defined in Vertex/index.ts:302
getY :: Line -> IntType declaration:
▸ (line: Line): number
Parameters:
| Name | Type |
|---|---|
line |
Line |
Const getYs
• getYs: function = map(getY)
Defined in Vertex/index.ts:316
getYs :: [Line] -> [Int]Type declaration:
▸ (lines: Line[]): number[]
Parameters:
| Name | Type |
|---|---|
lines |
Line[] |
Const heightOf
• heightOf: function = converge(subtract, [ pipe(getBottomLeft, prop('y')), pipe(getTopLeft, prop('y')), ])
Defined in Vertex/index.ts:508
heightOf :: Poly -> IntType declaration:
▸ (poly: Poly): number
Parameters:
| Name | Type |
|---|---|
poly |
Poly |
Const widthOf
• widthOf: function = converge(subtract, [ pipe(getTopRight, prop('x')), pipe(getTopLeft, prop('x')), ])
Defined in Vertex/index.ts:498
widthOf :: Poly -> IntType declaration:
▸ (poly: Poly): number
Parameters:
| Name | Type |
|---|---|
poly |
Poly |
Functions
Const append
▸ append<**A**>(boundingBox: A): (Anonymous function)
Defined in Vertex/index.ts:361
append :: BoundingBox -> ([Int], [Int]) -> BoundingBoxType parameters:
▪ A: BoundingBox
Parameters:
| Name | Type |
|---|---|
boundingBox |
A |
Returns: (Anonymous function)
Const hasHeader
▸ hasHeader<**A**>(a: A): a is WithHeader
Defined in Vertex/index.ts:149
hasHeader :: a -> boolType parameters:
▪ A: BoundingBox
Parameters:
| Name | Type |
|---|---|
a |
A |
Const hasHeaderColumn
▸ hasHeaderColumn<**A**>(a: A): a is WithHeaderColumn
Defined in Vertex/index.ts:140
hasHeaderColumn :: a -> boolType parameters:
▪ A: BoundingBox
Parameters:
| Name | Type |
|---|---|
a |
A |
Returns: a is WithHeaderColumn
Const hasHeaderRow
▸ hasHeaderRow<**A**>(a: A): a is WithHeaderRow
Defined in Vertex/index.ts:131
hasHeaderRow :: a -> boolType parameters:
▪ A: BoundingBox
Parameters:
| Name | Type |
|---|---|
a |
A |
Const isBoundingBox
▸ isBoundingBox(a: unknown): a is BoundingBox
Defined in Vertex/index.ts:119
isBoundingBox :: a -> boolParameters:
| Name | Type |
|---|---|
a |
unknown |
Returns: a is BoundingBox
Const isLabeledBoundingBox
▸ isLabeledBoundingBox(a: unknown): a is LabeledBoundingBox
Defined in Vertex/index.ts:330
isLabeledBoundingBox :: a -> boolParameters:
| Name | Type |
|---|---|
a |
unknown |
Returns: a is LabeledBoundingBox
Const isLine
▸ isLine(a: unknown): a is Line
Defined in Vertex/index.ts:87
isLine :: a -> boolParameters:
| Name | Type |
|---|---|
a |
unknown |
Returns: a is Line
Const isPoly
▸ isPoly(a: unknown): a is Poly
Defined in Vertex/index.ts:99
isPoly :: a -> boolParameters:
| Name | Type |
|---|---|
a |
unknown |
Returns: a is Poly
Const isVertex
▸ isVertex(a: unknown): a is Vertex
Defined in Vertex/index.ts:79
isVertex :: a -> boolParameters:
| Name | Type |
|---|---|
a |
unknown |
Returns: a is Vertex
Const lengthOf
▸ lengthOf(__namedParameters: [any, any]): number
Defined in Vertex/index.ts:518
lengthOf :: Line -> IntParameters:
| Name | Type |
|---|---|
__namedParameters |
[any, any] |
Returns: number
Const makeBoundingBox
▸ makeBoundingBox(boundingPoly: Poly, ys: number[], xs: number[]): BoundingBox
Defined in Vertex/index.ts:283
makeBoundingBox :: (Poly, [Int], [Int]) -> BoundingBoxParameters:
| Name | Type |
|---|---|
boundingPoly |
Poly |
ys |
number[] |
xs |
number[] |
Returns: BoundingBox
Const makeLabeledBoundingBox
▸ makeLabeledBoundingBox(id: string, label: string, boundingPoly: Poly, ys: number[], xs: number[]): LabeledBoundingBox
Defined in Vertex/index.ts:338
makeLabeledBoundingBox :: (String, String, Poly, [Int], [Int]) -> LabeledBoundingBoxParameters:
| Name | Type |
|---|---|
id |
string |
label |
string |
boundingPoly |
Poly |
ys |
number[] |
xs |
number[] |
Returns: LabeledBoundingBox
Const makeLine
▸ makeLine(x0: number, y0: number, x1: number, y1: number): Line
Defined in Vertex/index.ts:164
makeVertex :: (Int, Int, Int, Int) -> LineParameters:
| Name | Type |
|---|---|
x0 |
number |
y0 |
number |
x1 |
number |
y1 |
number |
Returns: Line
Const makePoly
▸ makePoly(...coords: [number, number, number, number]): Poly
Defined in Vertex/index.ts:229
makePoly :: (Int, Int, Int, Int) -> PolyParameters:
| Name | Type |
|---|---|
...coords |
[number, number, number, number] |
Returns: Poly
Const makeVertex
▸ makeVertex(x: number, y: number): Vertex
Defined in Vertex/index.ts:157
makeVertex :: (Int, Int) -> VertexParameters:
| Name | Type |
|---|---|
x |
number |
y |
number |
Returns: Vertex
Const withHeader
▸ withHeader(vertex: Vertex): (Anonymous function)
Defined in Vertex/index.ts:483
withHeader :: Vertex -> ReaderEither BoundingBox (WithHeader BoundingBox) BoundingBoxParameters:
| Name | Type |
|---|---|
vertex |
Vertex |
Returns: (Anonymous function)
Const withHeaderColumn
▸ withHeaderColumn(x: number): (Anonymous function)
Defined in Vertex/index.ts:446
withHeaderColumn :: Int -> ReaderEither BoundingBox BoundingBox (WithHeaderColumn BoundingBox)Parameters:
| Name | Type |
|---|---|
x |
number |
Returns: (Anonymous function)
Const withHeaderRow
▸ withHeaderRow(y: number): (Anonymous function)
Defined in Vertex/index.ts:408
withHeaderRow :: Int -> ReaderEither BoundingBox BoundingBox (WithHeaderRow BoundingBox)Parameters:
| Name | Type |
|---|---|
y |
number |
Returns: (Anonymous function)