parameters: (ioScatterPlotBlocksJson)
docstring: tests to see if a scatterplot block contains 'all variables': true and,\n     if so, construct a scatterplot block for each variable
docstring_summary: tests to see if a scatterplot block contains 'all variables': true and,\n     if so, construct a scatterplot block for each variable
docstring_tokens: tests to see if a scatterplot block contains all variables : true and \ n if so construct a scatterplot block for each variable
function: def TestForAndConstructAllScatterPlots(ioScatterPlotBlocksJson):
    "tests to see if a scatterplot block contains 'all variables': true and,\n     if so, construct a scatterplot block for each variable"
    if PhactoriDbg(100):
      myDebugPrint3('TestForAndConstructAllScatterPlots entered\n', 100)
    spBlocks = ioScatterPlotBlocksJson
    blocksToPop = []
    constructAllVariablesFlag = False
    for blockName, blockParamsJson in spBlocks.items():
      if PhactoriDbg():
        myDebugPrint3("testing block named " + blockName + " for all variables\n")
      if PhactoriDbg():
        myDebugPrint3("  json is: " + str(blockParamsJson) + "\n")
      testVal = getParameterFromBlock(blockParamsJson, "all variables", False)
      if testVal == True:
        constructAllVariablesFlag = True
        blockToPop = blockName
        blockToCopy = blockParamsJson
        #there should be only one like this
        break
  
    if constructAllVariablesFlag == False:
      #don't construct all variables
      if PhactoriDbg(100):
        myDebugPrint3('TestForAndConstructAllScatterPlots returning, no all variables\n', 100)
      return
  
    global gPipeAndViewsState
    paraviewSource = gPipeAndViewsState.mIncomingDefaultOperation.GetPvFilter()
    pointDataInfo = paraviewSource.GetPointDataInformation()
    cellDataInfo = paraviewSource.GetCellDataInformation()
  
    numPointArrays = pointDataInfo.GetNumberOfArrays()
    for ii in range(numPointArrays):
      pointArray = pointDataInfo.GetArray(ii)
      pointArrayName = pointArray.GetName()
      if pointArrayName != "GlobalNodeId":
        ConstructAndAddScatterPlotsJson(spBlocks, blockToCopy,
            pointArrayName, pointArray.GetNumberOfComponents(),
            "GlobalNodeId")
    numCellArrays = cellDataInfo.GetNumberOfArrays()
    for ii in range(numCellArrays):
      cellArray = cellDataInfo.GetArray(ii)
      cellArrayName = cellArray.GetName()
      if cellArrayName != "GlobalElementId":
        ConstructAndAddScatterPlotsJson(spBlocks, blockToCopy,
            cellArray.GetName(), pointArray.GetNumberOfComponents(),
            "GlobalElementId")
  
    gPipeAndViewsState.mImageSetCounter += 1
  
    spBlocks.pop(blockToPop, None)
  
    if PhactoriDbg(100):
      myDebugPrint3('TestForAndConstructAllScatterPlots returning\n', 100)
function_tokens: def TestForAndConstructAllScatterPlots ( ioScatterPlotBlocksJson ) : if PhactoriDbg ( 100 ) : myDebugPrint3 ( 'TestForAndConstructAllScatterPlots entered\n' , 100 ) spBlocks = ioScatterPlotBlocksJson blocksToPop = [ ] constructAllVariablesFlag = False for blockName , blockParamsJson in spBlocks . items ( ) : if PhactoriDbg ( ) : myDebugPrint3 ( "testing block named " + blockName + " for all variables\n" ) if PhactoriDbg ( ) : myDebugPrint3 ( "  json is: " + str ( blockParamsJson ) + "\n" ) testVal = getParameterFromBlock ( blockParamsJson , "all variables" , False ) if testVal == True : constructAllVariablesFlag = True blockToPop = blockName blockToCopy = blockParamsJson #there should be only one like this break if constructAllVariablesFlag == False : #don't construct all variables if PhactoriDbg ( 100 ) : myDebugPrint3 ( 'TestForAndConstructAllScatterPlots returning, no all variables\n' , 100 ) return global gPipeAndViewsState paraviewSource = gPipeAndViewsState . mIncomingDefaultOperation . GetPvFilter ( ) pointDataInfo = paraviewSource . GetPointDataInformation ( ) cellDataInfo = paraviewSource . GetCellDataInformation ( ) numPointArrays = pointDataInfo . GetNumberOfArrays ( ) for ii in range ( numPointArrays ) : pointArray = pointDataInfo . GetArray ( ii ) pointArrayName = pointArray . GetName ( ) if pointArrayName != "GlobalNodeId" : ConstructAndAddScatterPlotsJson ( spBlocks , blockToCopy , pointArrayName , pointArray . GetNumberOfComponents ( ) , "GlobalNodeId" ) numCellArrays = cellDataInfo . GetNumberOfArrays ( ) for ii in range ( numCellArrays ) : cellArray = cellDataInfo . GetArray ( ii ) cellArrayName = cellArray . GetName ( ) if cellArrayName != "GlobalElementId" : ConstructAndAddScatterPlotsJson ( spBlocks , blockToCopy , cellArray . GetName ( ) , pointArray . GetNumberOfComponents ( ) , "GlobalElementId" ) gPipeAndViewsState . mImageSetCounter += 1 spBlocks . pop ( blockToPop , None ) if PhactoriDbg ( 100 ) : myDebugPrint3 ( 'TestForAndConstructAllScatterPlots returning\n' , 100 )