def addAssemblyCage(derivation, negatives, positives):
 addCageGroove(derivation, negatives, positives)
 for pegCenterX in derivation.pegCenterXs:
  addPositivePeg(derivation, positives, pegCenterX, (- derivation.pegY))
  addPositivePeg(derivation, positives, pegCenterX, derivation.pegY)
 translate.translateNegativesPositives(negatives, positives, Vector3(0.0, (- derivation.halfSeparationWidth)))
 femaleNegatives = []
 femalePositives = []
 addCageGroove(derivation, femaleNegatives, femalePositives)
 for pegCenterX in derivation.pegCenterXs:
  addNegativePeg(derivation, femaleNegatives, pegCenterX, (- derivation.pegY))
  addNegativePeg(derivation, femaleNegatives, pegCenterX, derivation.pegY)
 translate.translateNegativesPositives(femaleNegatives, femalePositives, Vector3(0.0, derivation.halfSeparationWidth))
 negatives += femaleNegatives
 positives += femalePositives

def addAssemblyCage ( derivation , negatives , positives ) : addCageGroove ( derivation , negatives , positives ) for pegCenterX in derivation . pegCenterXs : addPositivePeg ( derivation , positives , pegCenterX , ( - derivation . pegY ) ) addPositivePeg ( derivation , positives , pegCenterX , derivation . pegY ) translate . translateNegativesPositives ( negatives , positives , Vector3 ( 0.0 , ( - derivation . halfSeparationWidth ) ) ) femaleNegatives = [ ] femalePositives = [ ] addCageGroove ( derivation , femaleNegatives , femalePositives ) for pegCenterX in derivation . pegCenterXs : addNegativePeg ( derivation , femaleNegatives , pegCenterX , ( - derivation . pegY ) ) addNegativePeg ( derivation , femaleNegatives , pegCenterX , derivation . pegY ) translate . translateNegativesPositives ( femaleNegatives , femalePositives , Vector3 ( 0.0 , derivation . halfSeparationWidth ) ) negatives += femaleNegatives positives += femalePositives
add assembly linear bearing cage .