/usr/include/sbml/common/operationReturnValues.h is in libsbml5-dev 5.13.0+dfsg-1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 | /**
* @file operationReturnValues.h
* @brief Enumeration of values returned by operations within libSBML.
* @author Sarah Keating
*
* <!--------------------------------------------------------------------------
* This file is part of libSBML. Please visit http://sbml.org for more
* information about SBML, and the latest version of libSBML.
*
* Copyright (C) 2013-2016 jointly by the following organizations:
* 1. California Institute of Technology, Pasadena, CA, USA
* 2. EMBL European Bioinformatics Institute (EMBL-EBI), Hinxton, UK
* 3. University of Heidelberg, Heidelberg, Germany
*
* Copyright (C) 2009-2013 jointly by the following organizations:
* 1. California Institute of Technology, Pasadena, CA, USA
* 2. EMBL European Bioinformatics Institute (EMBL-EBI), Hinxton, UK
*
* Copyright (C) 2006-2008 by the California Institute of Technology,
* Pasadena, CA, USA
*
* Copyright (C) 2002-2005 jointly by the following organizations:
* 1. California Institute of Technology, Pasadena, CA, USA
* 2. Japan Science and Technology Agency, Japan
*
* This library is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation. A copy of the license agreement is provided
* in the file named "LICENSE.txt" included with this software distribution and
* also available online as http://sbml.org/software/libsbml/license.html
* ---------------------------------------------------------------------- -->*/
#ifndef LIBSBML_OPERATION_RETURN_VALUES_H
#define LIBSBML_OPERATION_RETURN_VALUES_H
#include <sbml/common/extern.h>
LIBSBML_CPP_NAMESPACE_BEGIN
BEGIN_C_DECLS
/**
* @enum OperationReturnValues_t
* LibSBML diagnostic return codes.
*
* Many methods in libSBML return a status code to indicate whether the
* operation requested by the caller succeeded or failed. This enumeration
* lists all the possible return codes from any libSBML methods.
*/
typedef enum
{
LIBSBML_OPERATION_SUCCESS = 0
/*!< The operation was successful. */
, LIBSBML_INDEX_EXCEEDS_SIZE = -1
/*!< An index parameter exceeded the bounds of a data array or other
* collection used in the operation. This return value is typically
* returned by methods that take index numbers to refer to lists
* of objects, when the caller has provided an index that exceeds
* the bounds of the list. LibSBML provides methods for checking the
* size of list/sequence/collection structures, and callers should
* verify the sizes before calling methods that take index numbers. */
, LIBSBML_UNEXPECTED_ATTRIBUTE = -2
/*!< The attribute that is the subject of this operation is not valid
* for the combination of SBML Level and Version for the underlying
* object. This can happen because libSBML strives to offer a uniform
* API for all SBML Levels and Versions, but some object attributes and
* elements are not defined for all SBML Levels and Versions. Calling
* programs are expected to be aware of which object structures they
* are working with, but when errors of this kind occur, they are
* reported using this return value. */
, LIBSBML_OPERATION_FAILED = -3
/*!< The requested action could not be performed. This can occur in
* a variety of contexts, such as passing a null object as a parameter
* in a situation where it does not make sense to permit a null object.
*/
, LIBSBML_INVALID_ATTRIBUTE_VALUE = -4
/*!< A value passed as an argument to the method is not of a type that
* is valid for the operation or kind of object involved. For example,
* this return code is used when a calling program attempts to set an
* SBML object identifier to a string whose syntax does not conform to
* the SBML identifier syntax. */
, LIBSBML_INVALID_OBJECT = -5
/*!< The object passed as an argument to the method is not of a type
* that is valid for the operation or kind of object involved. For
* example, handing an invalidly-constructed ASTNode to a method
* expecting an ASTNode will result in this error. */
, LIBSBML_DUPLICATE_OBJECT_ID = -6
/*!< There already exists an object with this identifier in the
* context where this operation is being attempted. This error is
* typically returned in situations where SBML object identifiers must be
* unique, such as attempting to add two species with the same identifier
* to a model. */
, LIBSBML_LEVEL_MISMATCH = -7
/*!< The SBML Level associated with the object does not match the Level
* of the parent object. This error can happen when an SBML component
* such as a species or compartment object is created outside of a model
* and a calling program then attempts to add the object to a model that
* has a different SBML Level defined. */
, LIBSBML_VERSION_MISMATCH = -8
/*!< The SBML Version within the SBML Level associated with the object
* does not match the Version of the parent object. This error can
* happen when an SBML component such as a species or compartment object
* is created outside of a model and a calling program then attempts to
* add the object to a model that has a different SBML Level+Version
* combination. */
, LIBSBML_INVALID_XML_OPERATION = -9
/*!< The XML operation attempted is not valid for the object or context
* involved. This error is typically returned by the XML interface layer
* of libSBML, when a calling program attempts to construct or manipulate
* XML in an invalid way. */
, LIBSBML_NAMESPACES_MISMATCH = -10
/*!< The SBML Namespaces associated with the object
* do not match the SBML Namespaces of the parent object. This error can
* happen when an SBML component such as a species or compartment object
* is created outside of a model and a calling program then attempts to
* add the object to a model that has a different SBML Namespaces
* combination. */
, LIBSBML_DUPLICATE_ANNOTATION_NS = -11
/*!< There already exists a top level annotation with the same namespace as
* annotation being appended. This error is
* typically returned in situations where the appendAnnotation function
* is being used to add an annotation that has a namespace that is already
* present in the existing annotation. */
, LIBSBML_ANNOTATION_NAME_NOT_FOUND = -12
/*!< The existing annotation does not have a top-level element with
* the given name. This error is
* typically returned in situations where the
* replaceTopLevelAnnotationElement function or
* the removeTopLevelAnnotationElement function
* is being used to replace or remove an annotation with a name that does
* not match the name of any top-level element that is already
* present in the existing annotation. */
, LIBSBML_ANNOTATION_NS_NOT_FOUND = -13
/*!< The existing annotation does not have a top-level element with
* the given namespace. This error is
* typically returned in situations where the
* replaceTopLevelAnnotationElement function or
* the removeTopLevelAnnotationElement function
* is being used to replace or remove an annotation with a namespace that does
* not match the namespace of any top-level element that is already
* present in the existing annotation. */
, LIBSBML_MISSING_METAID = -14
/*!< The requested action cannot be performed as the target object does not have
* the metaid attribute set. */
, LIBSBML_DEPRECATED_ATTRIBUTE = -15
/*!< The attribute that is the subject of this operation has been deprecated
* for the combination of SBML Level and Version for the underlying
* object. */
/* ---------------------------------------------------------------------------
*
* Return codes for package extension
*
* -------------------------------------------------------------------------- */
, LIBSBML_PKG_VERSION_MISMATCH = -20
/*!< The Version of package extension within the SBML Level and version
* associated with the object does not match the Version of the parent
* object. This error can happen when an SBML component such as a layout
* or group object is created outside of a model and a calling program
* then attempts to add the object to a model that has a different SBML
* Level+Version+Package Version combination. */
, LIBSBML_PKG_UNKNOWN = -21
/*!< The required package extension is unknown. This error is typically
* returned when creating an object of SBase derived class with the required
* package, creating an object of SBMLNamespaces or its derived class with the
* required package, or invoking functions depending on the required package.
* To avoid this error, the library of the required package needs to be
* linked.
*/
, LIBSBML_PKG_UNKNOWN_VERSION = -22
/*!< The required version of the package extension is unknown. This error
* is typically returned when creating an object of SBase derived class with
* the required package, creating an object of SBMLNamespaces or its derived
* class with the required package, or invoking functions depending on the
* required package. This error may be avoided by updating the library of the
* required package to be linked.
*/
, LIBSBML_PKG_DISABLED = -23
/*!< The required package extension is disabled. This error is typically
* returned when creating an object of SBase derived class with the required
* package, creating an object of SBMLNamespaces or its derived class with the
* required package, or invoking functions depending on the required package.
* To avoid this error, the library of the required package needs to be enabled.
*/
, LIBSBML_PKG_CONFLICTED_VERSION = -24
/*!< Another version of the required package extension has already been enabled
* in the target SBase object, or enabled in the model to/in which the target
* object to be added/contained. This error is typically returned when adding an
* object of some SBase derived class with the required package to other SBase
* derived object, or when enabling the required package in the target object.
* To avoid this error, the conflict of versions need to be avoided.
*/
, LIBSBML_PKG_CONFLICT = -25
/*!< Another SBML package extension for the same URI has already been registered.
* This error is typically returned when adding a SBML package extension to the
* SBMLExtensionRegistry. To avoid this error, ensure that SBML package
* extensions are only registered once.
*/
/* ---------------------------------------------------------------------------
*
* Return codes for conversion extensions
*
* -------------------------------------------------------------------------- */
, LIBSBML_CONV_INVALID_TARGET_NAMESPACE = -30
/*!< The target namespace is not a valid SBML namespace. while
* attempting to convert the SBML document using
* SBMLLevelVersionConverter::convert() or related methods, the target
* namespace has been found to be invalid or unset. (The function
* SBMLNamespaces::isValidCombination() may be useful in
* detecting this situation and preventing the error.)
*/
, LIBSBML_CONV_PKG_CONVERSION_NOT_AVAILABLE = -31
/*!< Conversions involving packages are not available in the specified
* routine. This error is typically returned when calling a converter
* that does not have the functionality to deal with SBML Level 3
* packages. To avoid this error, ensure that the requested
* ConversionProperties specifies packages.
*/
, LIBSBML_CONV_INVALID_SRC_DOCUMENT = -32
/*!< The document on which conversion is being requested is invalid and
* the requested conversion cannot be performed. This error is
* typically returned when a conversion routine has been given an
* invalid target document or the conversion requires a certain degree
* of validity that is not present in the document. To avoid this
* error, use the SBMLDocument::checkConsistency() function to find and
* resolve errors before passing the document to a conversion method.
*/
, LIBSBML_CONV_CONVERSION_NOT_AVAILABLE = -33
/*!< Conversion with the given properties is not yet available.
*/
, LIBSBML_CONV_PKG_CONSIDERED_UNKNOWN = -34
/*!< The package that is being stripped is not an enabled
* package but considered by libSBML to be an unrecognized
* package. This error is typically returned when calling
* the StripPackage converter requesting that a package
* for which code is not available be stripped. Thus the
* containing document will not be altered as the elements
* and attributes for this package are stored as unknown package
* information and will be written out as such.
*/
} OperationReturnValues_t;
/**
* This method takes an SBML operation return value and returns a string representing
* the code.
*
* @param returnValue the operation return value to convert to a string
*
* @return a human readable name for the given
* @if clike #OperationReturnValues_t value@else operation return value @endif.
*
* @note The caller does not own the returned string and is therefore not
* allowed to modify it.
*/
LIBSBML_EXTERN
const char *
OperationReturnValue_toString (int returnValue);
END_C_DECLS
LIBSBML_CPP_NAMESPACE_END
#endif /* LIBSBML_OPERATION_RETURN_VALUES_H */
|