Import Geant4 5.0.0 source tree
This commit is contained in:
@@ -0,0 +1,174 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * DISCLAIMER *
|
||||
// * *
|
||||
// * The following disclaimer summarizes all the specific disclaimers *
|
||||
// * of contributors to this software. The specific disclaimers,which *
|
||||
// * govern, are listed with their locations in: *
|
||||
// * http://cern.ch/geant4/license *
|
||||
// * *
|
||||
// * Neither the authors of this software system, nor their employing *
|
||||
// * institutes,nor the agencies providing financial support for this *
|
||||
// * work make any representation or warranty, express or implied, *
|
||||
// * regarding this software system or assume any liability for its *
|
||||
// * use. *
|
||||
// * *
|
||||
// * This code implementation is the intellectual property of the *
|
||||
// * GEANT4 collaboration. *
|
||||
// * By copying, distributing or modifying the Program (or any work *
|
||||
// * based on the Program) you indicate your acceptance of this *
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// -*- C++ -*-
|
||||
// AID-GENERATED
|
||||
// =========================================================================
|
||||
// This class was generated by AID - Abstract Interface Definition
|
||||
// DO NOT MODIFY, but use the org.freehep.aid.Aid utility to regenerate it.
|
||||
// =========================================================================
|
||||
#ifndef HEPREP_HEPREPATTRIBUTE_H
|
||||
#define HEPREP_HEPREPATTRIBUTE_H 1
|
||||
|
||||
// Copyright 2000-2002, FreeHEP.
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
#include "HEPREP/HepRepConstants.h"
|
||||
|
||||
namespace HEPREP {
|
||||
|
||||
class HepRepAttValue;
|
||||
|
||||
/**
|
||||
* HepRepAttribute interface.
|
||||
*
|
||||
* @author Mark Donszelmann
|
||||
*/
|
||||
class HepRepAttribute {
|
||||
|
||||
public:
|
||||
/// Destructor.
|
||||
virtual ~HepRepAttribute() { /* nop */; }
|
||||
|
||||
/**
|
||||
* Adds an attValue.
|
||||
*
|
||||
* @param attValue to be added.
|
||||
* @return false only if the value is immediately written to a stream.
|
||||
*/
|
||||
virtual bool addAttValue(HepRepAttValue * attValue) = 0;
|
||||
|
||||
|
||||
/**
|
||||
* Adds a char* attValue as a String.
|
||||
* This call is mapped to addAttValue(std::string, std::string, int); and necessary
|
||||
* because C++ converts char* into bool and would thus call addAttValue(std::string, bool, int)
|
||||
* for a call such as addAttValue("drawAs", "Cylinder", 0);
|
||||
*
|
||||
* @param key name of attValue
|
||||
* @param value value of attValue
|
||||
* @param showLabel show this as label
|
||||
* @return false if an IOException was created.
|
||||
*/
|
||||
bool addAttValue(std::string key, char* value, int showLabel = HepRepConstants::SHOW_NONE) {
|
||||
return addAttValue(key, std::string(value), showLabel);
|
||||
}
|
||||
|
||||
/**
|
||||
* Adds an attValue.
|
||||
*
|
||||
* @param key name of attValue
|
||||
* @param value value of attValue
|
||||
* @param showLabel show this as label
|
||||
* @return false only if the value is immediately written to a stream.
|
||||
*/
|
||||
virtual bool addAttValue(std::string key, std::string value, int showLabel = HepRepConstants::SHOW_NONE) = 0;
|
||||
|
||||
/**
|
||||
* Adds an attValue.
|
||||
*
|
||||
* @param key name of attValue
|
||||
* @param value value of attValue
|
||||
* @param showLabel show this as label
|
||||
* @return false only if the value is immediately written to a stream.
|
||||
*/
|
||||
virtual bool addAttValue(std::string key, int value, int showLabel = HepRepConstants::SHOW_NONE) = 0;
|
||||
|
||||
/**
|
||||
* Adds an attValue.
|
||||
*
|
||||
* @param key name of attValue
|
||||
* @param value value of attValue
|
||||
* @param showLabel show this as label
|
||||
* @return false only if the value is immediately written to a stream.
|
||||
*/
|
||||
virtual bool addAttValue(std::string key, double value, int showLabel = HepRepConstants::SHOW_NONE) = 0;
|
||||
|
||||
/**
|
||||
* Adds an attValue.
|
||||
*
|
||||
* @param key name of attValue
|
||||
* @param value value of attValue
|
||||
* @param showLabel show this as label
|
||||
* @return false only if the value is immediately written to a stream.
|
||||
*/
|
||||
virtual bool addAttValue(std::string key, bool value, int showLabel = HepRepConstants::SHOW_NONE) = 0;
|
||||
|
||||
/**
|
||||
* Adds a Color attValue.
|
||||
*
|
||||
* @param key name of attValue
|
||||
* @param value value of attValue
|
||||
* @param showLabel show this as label
|
||||
* @return false only if the value is immediately written to a stream.
|
||||
*/
|
||||
virtual bool addAttValue(std::string key, std::vector<double> value, int showLabel = HepRepConstants::SHOW_NONE) = 0;
|
||||
|
||||
/**
|
||||
* Adds a Color attValue.
|
||||
*
|
||||
* @param key name of attValue
|
||||
* @param red color
|
||||
* @param green color
|
||||
* @param blue color
|
||||
* @param alpha value
|
||||
* @param showLabel show this as label
|
||||
* @return false only if the value is immediately written to a stream.
|
||||
*/
|
||||
virtual bool addAttValue(std::string key, double red, double green, double blue, double alpha = 1.0, int showLabel = HepRepConstants::SHOW_NONE) = 0;
|
||||
|
||||
/**
|
||||
* Remove the attvalue named by key.
|
||||
*
|
||||
* @param key name of the attValue to be removed.
|
||||
* @return removed HepRepAttValue, or null if not removed.
|
||||
*/
|
||||
virtual HepRepAttValue * removeAttValue(std::string key) = 0;
|
||||
|
||||
/**
|
||||
* Returns the attValue specified by name. This attValue is normally searched
|
||||
* on the node itself and then on its type, moving up the typetree.
|
||||
*
|
||||
* @param name of attribute value.
|
||||
* @return attribute value.
|
||||
*/
|
||||
virtual HepRepAttValue * getAttValue(std::string name) = 0;
|
||||
|
||||
/**
|
||||
* Returns a collection of all attribute values from this node.
|
||||
*
|
||||
* @return collection of HepRepAttValues.
|
||||
*/
|
||||
virtual std::vector<HepRepAttValue *> * getAttValuesFromNode() = 0;
|
||||
|
||||
/**
|
||||
* Returns a named attribute value from this node.
|
||||
*
|
||||
* @param lowerCaseName name in all lowercase.
|
||||
* @return corresponding HepRepAttValue.
|
||||
*/
|
||||
virtual HepRepAttValue * getAttValueFromNode(std::string lowerCaseName) = 0;
|
||||
}; // class
|
||||
}; // namespace HEPREP
|
||||
#endif /* ifndef HEPREP_HEPREPATTRIBUTE_H */
|
||||
Reference in New Issue
Block a user