<commit_before>/**
 * FILE : differentialoperator.hpp
 */
/* OpenCMISS-Zinc Library
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#ifndef CMZN_DIFFFERENTIALOPERATOR_HPP__
#define CMZN_DIFFFERENTIALOPERATOR_HPP__

#include "zinc/differentialoperator.h"

namespace OpenCMISS
{
namespace Zinc
{

class Differentialoperator
{
private:
	cmzn_differentialoperator_id id;

public:

	Differentialoperator() : id(0)
	{  }

	// takes ownership of C handle, responsibility for destroying it
	explicit Differentialoperator(cmzn_differentialoperator_id in_differential_operator_id) :
		id(in_differential_operator_id)
	{  }

	Differentialoperator(const Differentialoperator& differentialOperator) :
		id(cmzn_differentialoperator_access(differentialOperator.id))
	{	}

	Differentialoperator& operator=(const Differentialoperator& differentialOperator)
	{
		cmzn_differentialoperator_id temp_id = cmzn_differentialoperator_access(differentialOperator.id);
		if (0 != id)
		{
			cmzn_differentialoperator_destroy(&id);
		}
		id = temp_id;
		return *this;
	}

	~Differentialoperator()
	{
		if (0 != id)
		{
			cmzn_differentialoperator_destroy(&id);
		}
	}

	cmzn_differentialoperator_id getId() const
	{
		return id;
	}
};

}  // namespace Zinc
}
<commit_msg>Add missing isValid() method to differential operator class. https://tracker.physiomeproject.org/show_bug.cgi?id=3694<commit_after>/**
 * FILE : differentialoperator.hpp
 */
/* OpenCMISS-Zinc Library
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#ifndef CMZN_DIFFFERENTIALOPERATOR_HPP__
#define CMZN_DIFFFERENTIALOPERATOR_HPP__

#include "zinc/differentialoperator.h"

namespace OpenCMISS
{
namespace Zinc
{

class Differentialoperator
{
private:
	cmzn_differentialoperator_id id;

public:

	Differentialoperator() : id(0)
	{  }

	// takes ownership of C handle, responsibility for destroying it
	explicit Differentialoperator(cmzn_differentialoperator_id in_differential_operator_id) :
		id(in_differential_operator_id)
	{  }

	Differentialoperator(const Differentialoperator& differentialOperator) :
		id(cmzn_differentialoperator_access(differentialOperator.id))
	{	}

	Differentialoperator& operator=(const Differentialoperator& differentialOperator)
	{
		cmzn_differentialoperator_id temp_id = cmzn_differentialoperator_access(differentialOperator.id);
		if (0 != id)
		{
			cmzn_differentialoperator_destroy(&id);
		}
		id = temp_id;
		return *this;
	}

	~Differentialoperator()
	{
		if (0 != id)
		{
			cmzn_differentialoperator_destroy(&id);
		}
	}

	bool isValid() const
	{
		return (0 != id);
	}

	cmzn_differentialoperator_id getId() const
	{
		return id;
	}
};

}  // namespace Zinc
}

{'fraction_non_alphanumeric': 0.09299966181941156, 'fraction_numerical': 0.006425431180250254, 'mean_word_length': 5.049079754601227, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 1, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3391408', 'n_tokens_mistral': 1077, 'n_tokens_neox': 961, 'n_words': 216}