Package 

Class RiveFile

  • All Implemented Interfaces:
    java.lang.AutoCloseable

    @Stable() 
    public final class RiveFile
     implements AutoCloseable
                        

    A Rive file which contains one or more artboards, state machines, and view model instances.

    A Rive file is created from the Rive editor and is exported as a .riv file.

    Create an instance of this class using rememberRiveFile or RiveFile.fromSource. When using the latter, make sure to call close when you are done with the file to release its resources.

    The this object can be used to query the file for its contents, such as artboards names. It can then be passed to rememberArtboard to create an Artboard, and then to RiveUI for rendering.

    Queries are cached for performance.