Esempio n. 1
0
 /** \brief swap content of this and other pointers.
  *  \param other element to swap content with.
  */
 void swap(this_type &other)
 {
   pointer tmp=other.release();
   assert( other.get()==NULL );
   other.t_=get();
   t_=tmp;
 }
Esempio n. 2
0
 void swap(this_type& m)
     {
         WLock();
         m.WLock();
         parent_type::swap(m);
         m.WUnlock();
         WUnlock();
     }
Esempio n. 3
0
 bool operator<(const this_type& m) const
     {
         bool ret;
         RLock();
         m.RLock();
         ret = parent_type::operator<(m);
         m.RUnlock();
         RUnlock();
         return ret;
     }
Esempio n. 4
0
      bool operator==( this_type const& other ) const
      {
	if (empty()) 
	  return other.empty();

	return (low_ == other.low_) && (high_ == other.high_);
      }
Esempio n. 5
0
 tensor( this_type const& expr,
         Geo_t const& geom, Basis_i_t const& fev )
     :
     M_tensor_expr( expr.expression(), geom, fev ),
     M_inv( vf::detail::ExtractGm<Geo_t>::get( geom )->nPoints() )
 {
 }
Esempio n. 6
0
		bool operator < (const this_type& rhs) const
		{
			value_type lhs_value = value();
			value_type rhs_value = rhs.value();
			if(lhs_value == rhs_value)
				return m_index < rhs.m_index;
			return lhs_value < rhs_value;
		}
Esempio n. 7
0
 //! @brief Deep comparison
 bool        operator==      (this_type const &rhs) const
 {
     return
         (!*this && !rhs) ||
         (*this && rhs && (
             (this->get() == rhs.get()) ||
             (**this == *rhs) ) );
 }
Esempio n. 8
0
	BStr::BStr(const this_type & val) :
		m_str(nullptr)
	{
		if (val.m_str) {
			m_str = ::SysAllocStringLen(val.m_str, val.size());
			if (!m_str)
				CheckCom(E_OUTOFMEMORY);
		}
	}
Esempio n. 9
0
                        void enque(value_type const q)
                        {
                        	{
	                        	libmaus2::parallel::ScopePosixSpinLock llock(lock);
        	                        Q.push_back(q);
				}

                                semaphore.post();
                                
                                if ( parent )
	                                parent->enque(q);
                        }
Esempio n. 10
0
			static void copy(
				this_type const & from,
				this_type & to,
				uint64_t const blockid,
				uint64_t const numblocks
				)
			{
				uint64_t const blocksize = (from.H.size()+numblocks-1) / numblocks;
				uint64_t const idlow = blockid*blocksize;
				uint64_t const idhigh = std::min(idlow+blocksize,from.H.size());
				
				for ( uint64_t i = idlow; i < idhigh; ++i )
					if ( from.H[i].first != base_type::unused() )
						to.insert(from.H[i].first,from.H[i].second);
			}
Esempio n. 11
0
 static inline comparable_type apply(this_type const& input)
 {
     return comparable_type(input.radius());
 }
Esempio n. 12
0
 tensor( this_type const& expr,
         Geo_t const& geom, Basis_i_t const& fev )
     :
     M_tensor_expr( expr.expression(), geom, fev )
 {
 }
Esempio n. 13
0
 tensor( this_type const& expr, Geo_t const& geom )
     :
     M_tensor_expr( expr.expression(), geom )
 {
 }
Esempio n. 14
0
				iterator operator++(int)
				{
					iterator copy = *this;
					v = owner->decode();
					return copy;
				}
Esempio n. 15
0
 friend std::ptrdiff_t operator- (const this_type& i, const this_type& i2)
 { return i2.distance_to(i); }
Esempio n. 16
0
 friend
 bool operator== ( const this_type& lhs, const this_type& rhs ) {
   return lhs.absolute() == rhs.absolute() ? true : false;
 }
Esempio n. 17
0
				iterator(this_type * rowner)
				: owner(rowner), v(owner->decode())
				{

				}
Esempio n. 18
0
 friend difference_type operator- (const this_type& i, const this_type& i2)
 { return i2.distance_to(i); }
Esempio n. 19
0
 friend bool operator== (const this_type& i, const this_type& i2)
 { return i.equal(i2); }
Esempio n. 20
0
 /*!
  * Lexicographically compares the argument string literal to a part of this string
  *
  * \pre <tt>pos <= size()</tt>
  * \param pos Starting position within this string to perform comparison to
  * \param n Length of the substring of this string to perform comparison to
  * \param that Comparand
  * \return Zero if the comparand equals this string, a negative value if this string is less than the comparand,
  *         a positive value if this string is greater than the comparand.
  *
  * \b Throws: An <tt>std::exception</tt>-based exception if \a pos is out of range.
  */
 int compare(size_type pos, size_type n, this_type const& that) const
 {
     return compare(pos, n, that.c_str(), that.size());
 }
Esempio n. 21
0
 /** \brief comapre pointers.
  *  \param other element to compare with.
  *  \return true if this pointer is less then other, false otherwise.
  */
 bool operator<(const this_type &other) const
 {
   return get()<other.get();
 }
Esempio n. 22
0
 friend bool operator==(const this_type& l, const this_type& r)
 {
     return l.size() == r.size() &&
            ngx_strncmp(l.data(), r.data(), l.size()) == 0
         ;
 }
Esempio n. 23
0
 static inline typename similar_type<this_type, P1, P2>::type apply(this_type const& input)
 {
     return comparable::haversine<P1, P2, CalculationType>(input.radius());
 }
Esempio n. 24
0
	/** @brief this=右辺値か判定。
	    @param[in] i_right 右辺値。
	 */
	public: bool operator==(this_type const& i_right) const
	{
		return this->get_malloc() == i_right.get_malloc()
			&& this->get_free() == i_right.get_free();
	}
Esempio n. 25
0
 /*!
  * Lexicographically compares the argument string to this string
  *
  * \param that Comparand
  * \return Zero if the comparand equals this string, a negative value if this string is less than the comparand,
  *         a positive value if this string is greater than the comparand.
  */
 int compare(this_type const& that) const
 {
     return compare(0, m_Len, that.c_str(), that.size());
 }
Esempio n. 26
0
 fixed_size_vector(const this_type& v, allocator* alloc = default_allocator()) :
     begin_(elements_), size_(0), capacity_(count), allocator_(alloc)
 {
     insert(end(), v.begin(), v.end());
 }
Esempio n. 27
0
 friend bool operator< (const this_type& i, const this_type& i2)
 { return i.less(i2); }
Esempio n. 28
0
				iterator operator++()
				{
					v = owner->decode();
					return *this;
				}
Esempio n. 29
0
 void
 add( this_type const& f )
 {
     M_vector->add( f.container() );
 }
Esempio n. 30
0
	member_array(const this_type& o) : base_class(o.base()) { }