Options
All
  • Public
  • Public/Protected
  • All
Menu

Class ImageSource

Hierarchy

  • ImageSource

Index

Constructors

constructor

  • Parameters

    • Optional nativeSource: any

    Returns ImageSource

Properties

android

android: any

height

height: number

ios

ios: any

rotationAngle

rotationAngle: number

width

width: number

Methods

fromAsset

fromBase64

  • fromBase64(source: string): Promise<boolean>
  • Parameters

    • source: string

    Returns Promise<boolean>

fromData

  • fromData(data: any): Promise<boolean>
  • Parameters

    • data: any

    Returns Promise<boolean>

fromFile

  • fromFile(path: string): Promise<boolean>
  • Parameters

    • path: string

    Returns Promise<boolean>

fromResource

  • fromResource(name: string): Promise<boolean>
  • Parameters

    • name: string

    Returns Promise<boolean>

loadFromBase64

  • loadFromBase64(source: string): boolean
  • Parameters

    • source: string

    Returns boolean

loadFromData

  • loadFromData(data: any): boolean
  • Parameters

    • data: any

    Returns boolean

loadFromFile

  • loadFromFile(path: string): boolean
  • Parameters

    • path: string

    Returns boolean

loadFromFontIconCode

  • loadFromFontIconCode(source: string, font: Font, color: Color): boolean
  • Parameters

    Returns boolean

loadFromResource

  • loadFromResource(name: string): boolean
  • Parameters

    • name: string

    Returns boolean

resize

  • Parameters

    • maxSize: number
    • Optional options: any

    Returns ImageSource

saveToFile

  • saveToFile(path: string, format: "png" | "jpeg" | "jpg", quality?: number): boolean
  • Parameters

    • path: string
    • format: "png" | "jpeg" | "jpg"
    • Optional quality: number

    Returns boolean

setNativeSource

  • setNativeSource(nativeSource: any): void
  • Parameters

    • nativeSource: any

    Returns void

toBase64String

  • toBase64String(format: "png" | "jpeg" | "jpg", quality?: number): string
  • Parameters

    • format: "png" | "jpeg" | "jpg"
    • Optional quality: number

    Returns string

Static fromAsset

Static fromBase64

  • Parameters

    • source: string

    Returns Promise<ImageSource>

Static fromBase64Sync

  • Parameters

    • source: string

    Returns ImageSource

Static fromData

  • Parameters

    • data: any

    Returns Promise<ImageSource>

Static fromDataSync

  • Parameters

    • data: any

    Returns ImageSource

Static fromFile

  • Parameters

    • path: string

    Returns Promise<ImageSource>

Static fromFileOrResourceSync

  • Parameters

    • path: string

    Returns ImageSource

Static fromFileSync

  • Parameters

    • path: string

    Returns ImageSource

Static fromFontIconCodeSync

  • Parameters

    Returns ImageSource

Static fromResource

  • Parameters

    • name: string

    Returns Promise<ImageSource>

Static fromResourceSync

  • Parameters

    • name: string

    Returns ImageSource

Static fromUrl

  • Parameters

    • url: string

    Returns Promise<ImageSource>

Legend

  • Module
  • Object literal
  • Variable
  • Function
  • Function with type parameter
  • Index signature
  • Type alias
  • Enumeration
  • Enumeration member
  • Property
  • Method
  • Interface
  • Interface with type parameter
  • Constructor
  • Property
  • Method
  • Index signature
  • Class
  • Class with type parameter
  • Constructor
  • Property
  • Method
  • Accessor
  • Index signature
  • Inherited constructor
  • Inherited property
  • Inherited method
  • Inherited accessor
  • Protected property
  • Protected method
  • Protected accessor
  • Private property
  • Private method
  • Private accessor
  • Static property
  • Static method