UNPKG

@rcsb/rcsb-saguaro-3d

Version:
46 lines (45 loc) 3.28 kB
import { SaguaroChain, StructureViewerInterface, SaguaroPosition, SaguaroRange, ViewerManagerFactoryInterface } from "../StructureViewerInterface"; import { PluginContext } from "molstar/lib/mol-plugin/context"; import { StructureRepresentationRegistry } from "molstar/lib/mol-repr/structure/registry"; import { ColorTheme } from "molstar/lib/mol-theme/color"; import { Subscription } from "rxjs"; import { RcsbFvStateInterface } from "../../RcsbFvState/RcsbFvStateInterface"; export declare class StructureViewer<R, L, S extends {}> implements StructureViewerInterface<R, L, S> { private readonly structureViewerManagerFactory; private callbackManager; private actionManager; constructor(structureViewerManagerFactory: ViewerManagerFactoryInterface<R, L, S>); init(stateManager: RcsbFvStateInterface, args: S): void; clear(): Promise<void>; load(loadConfig: R): Promise<L | undefined>; load(loadConfig: R[]): Promise<(L | undefined)[]>; removeStructure(loadConfig: R | R[]): Promise<void>; setBackground(color: number): void; select(modelId: string, labelAsymId: string, begin: number, end: number, mode: 'select' | 'hover', operation: 'add' | 'set', operatorName?: string): void; select(selection: Array<SaguaroPosition>, mode: 'select' | 'hover', operation: 'add' | 'set'): void; select(selection: Array<SaguaroRange>, mode: 'select' | 'hover', operation: 'add' | 'set'): void; clearSelection(mode: 'select' | 'hover', option?: SaguaroChain): void; setFocus(modelId: string, labelAsymId: string, begin: number, end: number, operatorName?: string): void; clearFocus(): void; cameraFocus(modelId: string, labelAsymId: string, positions: Array<number>, operatorName?: string): void; cameraFocus(modelId: string, labelAsymId: string, begin: number, end: number, operatorName?: string): void; createComponent(componentLabel: string, modelId: string, labelAsymId: string, begin: number, end: number, representationType: StructureRepresentationRegistry.BuiltIn, operatorName?: string): Promise<void>; createComponent(componentLabel: string, modelId: string, labelAsymId: string, representationType: StructureRepresentationRegistry.BuiltIn, operatorName?: string): Promise<void>; createComponent(componentLabel: string, residues: Array<SaguaroPosition>, representationType: StructureRepresentationRegistry.BuiltIn): Promise<void>; createComponent(componentLabel: string, residues: Array<SaguaroRange>, representationType: StructureRepresentationRegistry.BuiltIn): Promise<void>; isComponent(componentLabel: string): boolean; colorComponent(componentLabel: string, color: ColorTheme.BuiltIn): Promise<void>; getComponentSet(): Set<string>; removeComponent(componentLabel?: string): Promise<void>; displayComponent(componentLabel: string): boolean; displayComponent(componentLabel: string, visibilityFlag: boolean): void; subscribeRepresentationChange(): Subscription; subscribeHover(): Subscription; subscribeSelection(): Subscription; pluginCall(f: (plugin: PluginContext) => void): void; subscribeModelChange(): Subscription; modelChange(): void; unsubscribe(): void; resetCamera(): void; exportLoadedStructures(): Promise<void>; }