test_class.declarator: builder = SilentChemObjectBuilder.getInstance()
test_class.modifier: private
test_class.original_string: private IChemObjectBuilder      builder = SilentChemObjectBuilder.getInstance();
test_class.type: IChemObjectBuilder
test_class.var_name: builder
test_class.declarator: lpcheck = new LonePairElectronChecker()
test_class.modifier: private
test_class.original_string: private LonePairElectronChecker lpcheck = new LonePairElectronChecker();
test_class.type: LonePairElectronChecker
test_class.var_name: lpcheck
test_class.file: descriptor/qsaratomic/src/test/java/org/openscience/cdk/qsar/descriptors/atomic/PiElectronegativityDescriptorTest.java
test_class.identifier: PiElectronegativityDescriptorTest
test_class.superclass: extends AtomicDescriptorTest
test_case.body: @Test
      public void testPiElectronegativity2() throws ClassNotFoundException, CDKException, java.lang.Exception {
          double[] testResult = {0.0, 0.0, 3.2849, 0.0, 0.0, 0.0, 3.2849, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0,
                  0.0, 0.0, 0.0};/*
                                  * from Petra online:
                                  * http://www2.chemie.uni-erlangen
                                  * .de/services/petra/smiles.phtml
                                  */
          IAtomicDescriptor descriptor = new PiElectronegativityDescriptor();
  
          SmilesParser sp = new SmilesParser(DefaultChemObjectBuilder.getInstance());
          IAtomContainer mol = sp.parseSmiles("CCOCCCO");
  
          AtomContainerManipulator.percieveAtomTypesAndConfigureAtoms(mol);
          addExplicitHydrogens(mol);
  
          LonePairElectronChecker lpcheck = new LonePairElectronChecker();
          lpcheck.saturate(mol);
  
          for (int i = 0; i < mol.getAtomCount(); i++) {
              double result = ((DoubleResult) descriptor.calculate(mol.getAtom(i), mol).getValue()).doubleValue();
              //	        logger.debug(mol.getAtom(i).getSymbol()+"-result: "+result);
              if (result == 0.0)
                  Assert.assertEquals(testResult[i], result, 0.0001);
              else {
                  Assert.assertTrue(result != 0.0);
                  Assert.assertEquals(testResult[i], result, 0.2);
              }
          }
      }
test_case.class_method_signature: PiElectronegativityDescriptorTest.testPiElectronegativity2()
test_case.full_signature: @Test public void testPiElectronegativity2()
test_case.identifier: testPiElectronegativity2
test_case.invocations: getInstance parseSmiles percieveAtomTypesAndConfigureAtoms addExplicitHydrogens saturate getAtomCount doubleValue getValue calculate getAtom assertEquals assertTrue assertEquals
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testPiElectronegativity2()
focal_class.declarator: maxIterations   = -1
focal_class.modifier: private
focal_class.original_string: private int                   maxIterations   = -1;
focal_class.type: int
focal_class.var_name: maxIterations
focal_class.declarator: maxResonStruc   = -1
focal_class.modifier: private
focal_class.original_string: private int                   maxResonStruc   = -1;
focal_class.type: int
focal_class.var_name: maxResonStruc
focal_class.declarator: lpeChecker      = true
focal_class.modifier: private
focal_class.original_string: private boolean               lpeChecker      = true;
focal_class.type: boolean
focal_class.var_name: lpeChecker
focal_class.declarator: NAMES = {"elecPiA"}
focal_class.modifier: private static final
focal_class.original_string: private static final String[] NAMES = {"elecPiA"};
focal_class.type: String[]
focal_class.var_name: NAMES
focal_class.declarator: electronegativity
focal_class.modifier: private
focal_class.original_string: private PiElectronegativity   electronegativity;
focal_class.type: PiElectronegativity
focal_class.var_name: electronegativity
focal_class.file: descriptor/qsaratomic/src/main/java/org/openscience/cdk/qsar/descriptors/atomic/PiElectronegativityDescriptor.java
focal_class.identifier: PiElectronegativityDescriptor
focal_class.interfaces: implements IAtomicDescriptor
focal_class.class_method_signature: PiElectronegativityDescriptor.PiElectronegativityDescriptor()
focal_class.full_signature: public  PiElectronegativityDescriptor()
focal_class.identifier: PiElectronegativityDescriptor
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.signature:  PiElectronegativityDescriptor()
focal_class.class_method_signature: PiElectronegativityDescriptor.getSpecification()
focal_class.full_signature: @Override public DescriptorSpecification getSpecification()
focal_class.identifier: getSpecification
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: DescriptorSpecification
focal_class.signature: DescriptorSpecification getSpecification()
focal_class.class_method_signature: PiElectronegativityDescriptor.setParameters(Object[] params)
focal_class.full_signature: @Override public void setParameters(Object[] params)
focal_class.identifier: setParameters
focal_class.modifiers: @Override public
focal_class.parameters: (Object[] params)
focal_class.return: void
focal_class.signature: void setParameters(Object[] params)
focal_class.class_method_signature: PiElectronegativityDescriptor.getParameters()
focal_class.full_signature: @Override public Object[] getParameters()
focal_class.identifier: getParameters
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: Object[]
focal_class.signature: Object[] getParameters()
focal_class.class_method_signature: PiElectronegativityDescriptor.getDescriptorNames()
focal_class.full_signature: @Override public String[] getDescriptorNames()
focal_class.identifier: getDescriptorNames
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: String[]
focal_class.signature: String[] getDescriptorNames()
focal_class.class_method_signature: PiElectronegativityDescriptor.calculate(IAtom atom, IAtomContainer atomContainer)
focal_class.full_signature: @Override public DescriptorValue calculate(IAtom atom, IAtomContainer atomContainer)
focal_class.identifier: calculate
focal_class.modifiers: @Override public
focal_class.parameters: (IAtom atom, IAtomContainer atomContainer)
focal_class.return: DescriptorValue
focal_class.signature: DescriptorValue calculate(IAtom atom, IAtomContainer atomContainer)
focal_class.class_method_signature: PiElectronegativityDescriptor.getParameterNames()
focal_class.full_signature: @Override public String[] getParameterNames()
focal_class.identifier: getParameterNames
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: String[]
focal_class.signature: String[] getParameterNames()
focal_class.class_method_signature: PiElectronegativityDescriptor.getParameterType(String name)
focal_class.full_signature: @Override public Object getParameterType(String name)
focal_class.identifier: getParameterType
focal_class.modifiers: @Override public
focal_class.parameters: (String name)
focal_class.return: Object
focal_class.signature: Object getParameterType(String name)
focal_class.superclass: extends AbstractAtomicDescriptor
focal_method.body: @Override
      public DescriptorValue calculate(IAtom atom, IAtomContainer atomContainer) {
          IAtomContainer clone;
          IAtom localAtom;
          try {
              clone = (IAtomContainer) atomContainer.clone();
              AtomContainerManipulator.percieveAtomTypesAndConfigureAtoms(clone);
              if (lpeChecker) {
                  LonePairElectronChecker lpcheck = new LonePairElectronChecker();
                  lpcheck.saturate(atomContainer);
              }
              localAtom = clone.getAtom(atomContainer.indexOf(atom));
          } catch (CloneNotSupportedException e) {
              return new DescriptorValue(getSpecification(), getParameterNames(), getParameters(), new DoubleResult(
                      Double.NaN), NAMES, null);
          } catch (CDKException e) {
              return new DescriptorValue(getSpecification(), getParameterNames(), getParameters(), new DoubleResult(
                      Double.NaN), NAMES, null);
          }
  
          if (maxIterations != -1 && maxIterations != 0) electronegativity.setMaxIterations(maxIterations);
          if (maxResonStruc != -1 && maxResonStruc != 0) electronegativity.setMaxResonStruc(maxResonStruc);
  
          double result = electronegativity.calculatePiElectronegativity(clone, localAtom);
  
          return new DescriptorValue(getSpecification(), getParameterNames(), getParameters(), new DoubleResult(result),
                                     NAMES);
      }
focal_method.class_method_signature: PiElectronegativityDescriptor.calculate(IAtom atom, IAtomContainer atomContainer)
focal_method.full_signature: @Override public DescriptorValue calculate(IAtom atom, IAtomContainer atomContainer)
focal_method.identifier: calculate
focal_method.invocations: clone percieveAtomTypesAndConfigureAtoms saturate getAtom indexOf getSpecification getParameterNames getParameters getSpecification getParameterNames getParameters setMaxIterations setMaxResonStruc calculatePiElectronegativity getSpecification getParameterNames getParameters
focal_method.modifiers: @Override public
focal_method.parameters: (IAtom atom, IAtomContainer atomContainer)
focal_method.return: DescriptorValue
focal_method.signature: DescriptorValue calculate(IAtom atom, IAtomContainer atomContainer)