+}
+
+//=============================================================================
+/*!
+ * StdMeshers_NumberOfSegments_i::BuildDistribution
+ *
+ * Builds point distribution according to passed function
+ */
+//=============================================================================
+SMESH::double_array* StdMeshers_NumberOfSegments_i::BuildDistributionExpr( const char* func,
+ CORBA::Long nbSeg,
+ CORBA::Long conv )
+{
+ ASSERT( myBaseImpl );
+ try
+ {
+ SMESH::double_array_var aRes = new SMESH::double_array();
+ const std::vector<double>& res = this->GetImpl()->BuildDistributionExpr( func, nbSeg, conv );
+ aRes->length( res.size() );
+ for (size_t i = 0; i < res.size(); i++)
+ aRes[i] = res[i];
+ return aRes._retn();
+ }
+ catch( SALOME_Exception& S_ex )
+ {
+ THROW_SALOME_CORBA_EXCEPTION( S_ex.what(), SALOME::BAD_PARAM );
+ }
+}
+
+SMESH::double_array*
+StdMeshers_NumberOfSegments_i::BuildDistributionTab( const SMESH::double_array& func,
+ CORBA::Long nbSeg,
+ CORBA::Long conv )
+{
+ ASSERT( myBaseImpl );
+
+ std::vector<double> tbl( func.length() );
+ for ( size_t i = 0; i < tbl.size(); i++ )
+ tbl[i] = func[i];
+
+ try
+ {
+ SMESH::double_array_var aRes = new SMESH::double_array();
+ const std::vector<double>& res = this->GetImpl()->BuildDistributionTab( tbl, nbSeg, conv );
+ aRes->length( res.size() );
+ for (size_t i = 0; i < res.size(); i++)
+ aRes[i] = res[i];
+ return aRes._retn();
+ }
+ catch( SALOME_Exception& S_ex )
+ {
+ THROW_SALOME_CORBA_EXCEPTION( S_ex.what(), SALOME::BAD_PARAM );
+ }