pymel.core.general.createAttrPatterns¶
- createAttrPatterns(*args, **kwargs)¶
Create a new instance of an attribute pattern given a pattern type (e.g. XML) and a string or data file containing the description of the attribute tree in the pattern’s format.
Flags:
Long Name / Short Name Argument Types Properties patternDefinition / pd unicode Hardcoded string containing the pattern definition, for simpler formats that don’t really need a separate file for definition. patternFile / pf unicode File where the pattern information can be found patternType / pt unicode Name of the pattern definition type to use in creating this instance of the pattern. Flag can have multiple arguments, passed either as a tuple or a list. Derived from mel command maya.cmds.createAttrPatterns
Example:
import pymel.core as pm import maya.cmds as cmds pm.createAttrPatterns( patternType="xmlPattern", patternFile="patterns/patternFile.xml" ) // Result: [myXMLPattern] //