UNPKG

@nfdi4plants/swate-components

Version:

Customizable React components for ontology annotation, based on Swate and the ARC.

194 lines 9.08 kB
import { Option } from '@fable-org/fable-library-js/Option.js'; import { int32 } from '@fable-org/fable-library-js/Int32.js'; export declare function Pattern_handleGroupPatterns(pattern: string): string; export declare const Pattern_ExcelNumberFormat = "\"(?<numberFormat>(.*?))\""; export declare const Pattern_TermAnnotationShortPattern = "(?<idspace>\\w+?):(?<localid>\\w+)"; export declare const Pattern_TermAnnotationURIPattern = "http://purl.obolibrary.org/obo/(?<idspace>\\w+?)_(?<localid>\\w+)"; export declare const Pattern_TermAnnotationURIPattern_lessRestrictive = ".*\\/(?<idspace>\\w+?)[:_](?<localid>\\w+)"; export declare const Pattern_TermAnnotationURIPattern_MS_RO_PO = ".*252F(?<idspace>\\w+?)_(?<localid>\\w+)"; export declare const Pattern_IOTypePattern = "(Input|Output)\\s*\\[(?<iotype>.+)\\]"; export declare const Pattern_InputPattern = "Input\\s*\\[(?<iotype>.+)\\]"; export declare const Pattern_OutputPattern = "Output\\s*\\[(?<iotype>.+)\\]"; export declare const Pattern_CommentPattern = "Comment\\s*\\[(?<commentKey>.+)\\]"; /** * Matches, if the input string matches the given regex pattern. */ export declare function ActivePatterns_$007CRegex$007C_$007C(pattern: string, input: string): Option<any>; /** * Matches any column header starting with some text, followed by one whitespace and a term name inside squared brackets. */ export declare function ActivePatterns_$007CReferenceColumnHeader$007C_$007C(input: string): Option<{ Annotation: string; }>; /** * Matches any column header starting with some text, followed by one whitespace and a term name inside squared brackets. */ export declare function ActivePatterns_$007CTermColumn$007C_$007C(input: string): Option<{ TermColumnType: string; TermName: string; }>; /** * Matches a "Unit" column header. */ export declare function ActivePatterns_$007CUnitColumnHeader$007C_$007C(input: string): Option<string>; /** * Matches a "Parameter [Term]" or "Parameter Value [Term]" column header and returns the Term string. */ export declare function ActivePatterns_$007CParameterColumnHeader$007C_$007C(input: string): Option<string>; /** * Matches a "Factor [Term]" or "Factor Value [Term]" column header and returns the Term string. */ export declare function ActivePatterns_$007CFactorColumnHeader$007C_$007C(input: string): Option<string>; /** * Matches a "Characteristic [Term]" or "Characteristics [Term]" or "Characteristics Value [Term]" column header and returns the Term string. */ export declare function ActivePatterns_$007CCharacteristicColumnHeader$007C_$007C(input: string): Option<string>; /** * Matches a "Component [Term]" or "Component Value [Term]" column header and returns the Term string. */ export declare function ActivePatterns_$007CComponentColumnHeader$007C_$007C(input: string): Option<string>; /** * Matches a short term string and returns the term source ref and the annotation number strings. * * Example: "MS:1003022" --> term source ref: "MS"; annotation number: "1003022" */ export declare function ActivePatterns_$007CTermAnnotationShort$007C_$007C(input: string): Option<{ IDSpace: string; LocalID: string; }>; /** * Matches a term string (either short or URI) and returns the term source ref and the annotation number strings. * * Example 1: "MS:1003022" --> term source ref: "MS"; annotation number: "1003022" * * Example 2: "http://purl.obolibrary.org/obo/MS_1003022" --> term source ref: "MS"; annotation number: "1003022" */ export declare function ActivePatterns_$007CTermAnnotation$007C_$007C(input: string): Option<{ IDSpace: string; LocalID: string; }>; /** * Matches a "Term Source REF (ShortTerm)" column header and returns the ShortTerm as Term Source Ref and Annotation Number. * * Example: "Term Source REF (MS:1003022)" --> term source ref: "MS"; annotation number: "1003022" */ export declare function ActivePatterns_$007CTSRColumnHeader$007C_$007C(input: string): Option<{ IDSpace: string; LocalID: string; }>; /** * Matches a "Term Accession Number (ShortTerm)" column header and returns the ShortTerm as Term Source Ref and Annotation Number. * * Example: "Term Accession Number (MS:1003022)" --> term source ref: "MS"; annotation number: "1003022" */ export declare function ActivePatterns_$007CTANColumnHeader$007C_$007C(input: string): Option<{ IDSpace: string; LocalID: string; }>; /** * Matches a "Input [InputType]" column header and returns the InputType as string. */ export declare function ActivePatterns_$007CInputColumnHeader$007C_$007C(input: string): Option<string>; /** * Matches a "Output [OutputType]" column header and returns the OutputType as string. */ export declare function ActivePatterns_$007COutputColumnHeader$007C_$007C(input: string): Option<string>; /** * Matches auto-generated readable table names. Mainly used in ArcAssay.addTable(). Default tables will get such a name. * * Will match "New Table 10" and return the number `10`. */ export declare function ActivePatterns_$007CAutoGeneratedTableName$007C_$007C(input: string): Option<int32>; export declare function ActivePatterns_$007CComment$007C_$007C(input: string): Option<string>; export declare function tryParseReferenceColumnHeader(str: string): Option<{ Annotation: string; }>; export declare function tryParseTermAnnotationShort(str: string): Option<{ IDSpace: string; LocalID: string; }>; /** * This function can be used to extract `IDSPACE:LOCALID` (or: `Term Accession`) from Swate header strings or obofoundry conform URI strings. * * **Example 1:** "http://purl.obolibrary.org/obo/GO_000001" --> "GO:000001" * * **Example 2:** "Term Source REF (NFDI4PSO:0000064)" --> "NFDI4PSO:0000064" */ export declare function tryParseTermAnnotation(str: string): Option<{ IDSpace: string; LocalID: string; }>; /** * Tries to parse 'str' to term accession and returns it in the format `Some "termsourceref:localtan"`. Exmp.: `Some "MS:000001"` */ export declare function tryGetTermAnnotationShortString(str: string): Option<string>; /** * Parses 'str' to term accession and returns it in the format "termsourceref:localtan". Exmp.: "MS:000001" */ export declare function getTermAnnotationShortString(str: string): string; /** * This function is used to parse Excel numberFormat string to term name. * * **Example 1:** "0.00 "degree Celsius"" --> "degree Celsius" */ export declare function tryParseExcelNumberFormat(headerStr: string): Option<string>; /** * This function is used to match both Input and Output columns and capture the IOType as `iotype` group. * * **Example 1:** "Input [Sample]" --> "Sample" */ export declare function tryParseIOTypeHeader(headerStr: string): Option<string>; /** * Matches any column header starting with some text, followed by one whitespace and a term name inside squared brackets. */ export declare function tryParseTermColumn(input: string): Option<{ TermColumnType: string; TermName: string; }>; /** * Matches a "Unit" column header. */ export declare function tryParseUnitColumnHeader(input: string): Option<string>; /** * Matches a "Parameter [Term]" or "Parameter Value [Term]" column header and returns the Term string. */ export declare function tryParseParameterColumnHeader(input: string): Option<string>; /** * Matches a "Factor [Term]" or "Factor Value [Term]" column header and returns the Term string. */ export declare function tryParseFactorColumnHeader(input: string): Option<string>; /** * Matches a "Characteristic [Term]" or "Characteristics [Term]" or "Characteristics Value [Term]" column header and returns the Term string. */ export declare function tryParseCharacteristicColumnHeader(input: string): Option<string>; /** * Matches a "Component [Term]" or "Characteristics [Term]" or "Component Value [Term]" column header and returns the Term string. */ export declare function tryParseComponentColumnHeader(input: string): Option<string>; /** * Matches a "Term Source REF (ShortTerm)" column header and returns the ShortTerm as Term Source Ref and Annotation Number. * * Example: "Term Source REF (MS:1003022)" --> term source ref: "MS"; annotation number: "1003022" */ export declare function tryParseTSRColumnHeader(input: string): Option<{ IDSpace: string; LocalID: string; }>; /** * Matches a "Term Accession Number (ShortTerm)" column header and returns the ShortTerm as Term Source Ref and Annotation Number. * * Example: "Term Accession Number (MS:1003022)" --> term source ref: "MS"; annotation number: "1003022" */ export declare function tryParseTANColumnHeader(input: string): Option<{ IDSpace: string; LocalID: string; }>; /** * Matches a "Input [InputType]" column header and returns the InputType as string. */ export declare function tryParseInputColumnHeader(input: string): Option<string>; /** * Matches a "Output [OutputType]" column header and returns the OutputType as string. */ export declare function tryParseOutputColumnHeader(input: string): Option<string>; //# sourceMappingURL=Regex.fs.d.ts.map