def copyartifact(registry, xml_parent, data):
 copyartifact = XML.SubElement(xml_parent, 'hudson.plugins.copyartifact.CopyArtifactPermissionProperty', plugin='copyartifact')
 if ((not data) or (not data.get('projects', None))):
  raise JenkinsJobsException('projects string must exist and not be empty')
 projectlist = XML.SubElement(copyartifact, 'projectNameList')
 for project in str(data.get('projects')).split(','):
  XML.SubElement(projectlist, 'string').text = project

def copyartifact ( registry , xml_parent , data ) : copyartifact = XML . SubElement ( xml_parent , 'hudson.plugins.copyartifact.CopyArtifactPermissionProperty' , plugin = 'copyartifact' ) if ( ( not data ) or ( not data . get ( 'projects' , None ) ) ) : raise JenkinsJobsException ( 'projects string must exist and not be empty' ) projectlist = XML . SubElement ( copyartifact , 'projectNameList' ) for project in str ( data . get ( 'projects' ) ) . split ( ',' ) : XML . SubElement ( projectlist , 'string' ) . text = project
yaml: copyartifact specify a list of projects that have access to copy the artifacts of this project .