Modifier

Partager via


Data Partition Pattern

A data partition pattern provides a way of selecting or generating a set of partitions based on the requirements specified as a regular expression.

public class CdmDataPartitionPatternDefinition extends CdmObjectDefinitionBase, CdmFileStatus

CdmDataPartitionPatternDefinition extends CdmObjectDefinition, CdmFileStatus in Python.

Constructors

Name Description
CdmDataPartitionPatternDefinition(CdmCorpusContext, string)
ctx: The corpus context.
name: The data partition pattern's name.
Initializes a new instance of the CdmDataPartitionPatternDefinition class.

Properties

Name Type Description SDK
Name string The data partition pattern's name. 1.0
RootLocation string The starting location's corpus path to use to search for inferred data partitions. 1.0
RegularExpression string The regular expression string to use to search for data partitions. 1.0
GlobPattern string The glob pattern string to use to search for data partitions. If a glob pattern and regular expression are both present, the glob pattern will be used instead. The following special characters are supported:
CharacterExplanation
*A single star matches zero or more of any character except path separators (/ or \).
**Two stars (globstar) matches zero or more directories or files.
?A question mark matches any single character that isn't a path separator.
'/' or '\'Slash and backslash are interchangeable, so a pattern that includes '\' will match a '/' character and vice versa.
1.0
Parameters List<string> The names for the replacement values extracted from the regular expression. 1.0
IsIncremental bool Denotes whether the data partition pattern is incremental. 1.6
SpecializedSchema string The corpus path of the specialized schema to use for the matched data partitions (for example, CSV). 1.0
LastFileStatusCheckTime DateTimeOffset? The last time the modified time was checked for this file. 1.0
LastFileModifiedTime DateTimeOffset? The last time this file was modified according to the object model. 1.0
LastChildFileModifiedTime DateTimeOffset? The greatest last time reported by any of the children objects about their file status check times. This property only exists because this class extends CdmFileStatus and will throw a NotImplementedException because a data partition pattern object doesn't contain any children. 1.0

Methods

Name Description Return Type
FileStatusCheckAsync() Updates the object and its children, if any, with the current time. On a data partition pattern, this API also checks for files that match the pattern described here. There will be one data partition per file matching the pattern created on the entity declaration that owns this pattern. Task
GetName() See CdmObjectDefinition.GetName(). string
IsDerivedFrom(string, ResolveOptions) See CdmObject.IsDerivedFrom(...). bool
Copy(ResolveOptions, CdmObject) See CdmObject.Copy(...). CdmObject
Validate() See CdmObject.Validate(). bool