File Persistence.h¶
File List > include > SpinGenApi > Persistence.h
Go to the documentation of this file
//=============================================================================
// Copyright (c) 2026 FLIR Integrated Imaging Solutions, Inc. All Rights Reserved.
//
// This software is the confidential and proprietary information of FLIR
// Integrated Imaging Solutions, Inc. ("Confidential Information"). You
// shall not disclose such Confidential Information and shall use it only in
// accordance with the terms of the license agreement you entered into
// with FLIR Integrated Imaging Solutions, Inc. (FLIR).
//
// FLIR MAKES NO REPRESENTATIONS OR WARRANTIES ABOUT THE SUITABILITY OF THE
// SOFTWARE, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE
// IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
// PURPOSE, OR NON-INFRINGEMENT. FLIR SHALL NOT BE LIABLE FOR ANY DAMAGES
// SUFFERED BY LICENSEE AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
// THIS SOFTWARE OR ITS DERIVATIVES.
//=============================================================================
#ifndef SPINNAKER_GENAPI_PERSISTENCE_H
#define SPINNAKER_GENAPI_PERSISTENCE_H
#include "Types.h"
#include "Pointer.h"
#include "ISelectorDigit.h"
#include "GCString.h"
#include "GCStringVector.h"
#include <list>
#include <iostream>
namespace Spinnaker
{
namespace GenApi
{
interface SPINNAKER_API_ABSTRACT IPersistScript
{
virtual void SetInfo(GenICam::gcstring & Info) = 0;
virtual void PersistFeature(IValue & item) = 0;
};
class SPINNAKER_API CFeatureBag : public IPersistScript
{
public:
CFeatureBag();
virtual ~CFeatureBag();
virtual void SetInfo(GenICam::gcstring& Info);
virtual void PersistFeature(IValue& item);
bool LoadFromBag(INodeMap* pNodeMap, bool Verify = true, GenICam::gcstring_vector* pErrorList = NULL);
int64_t StoreToBag(INodeMap* pNodeMap, const int MaxNumPersistSkriptEntries = -1);
bool operator==(const CFeatureBag& FeatureBag) const;
void* GetFeatureBagHandle();
private:
void* m_featureBag;
};
// note: this method must be inlined because it uses istream in the parameter list
SPINNAKER_API std::istream& EatComments(std::istream& is);
// note: this method must be inlined because it uses istream in the parameter list
SPINNAKER_API std::istream& operator>>(std::istream& is, CFeatureBag& FeatureBag);
// note: this method must be inlined because it uses ostream in the parameter list
SPINNAKER_API std::ostream& operator<<(std::ostream& os, const CFeatureBag& FeatureBag);
} // namespace GenApi
} // namespace Spinnaker
#endif // SPINNAKER_GENAPI_PERSISTENCE_H