namechain.cxx (d291ea28) | namechain.cxx (a0d53b35) |
---|---|
1/************************************************************** 2 * 3 * Licensed to the Apache Software Foundation (ASF) under one 4 * or more contributor license agreements. See the NOTICE file 5 * distributed with this work for additional information 6 * regarding copyright ownership. The ASF licenses this file 7 * to you under the Apache License, Version 2.0 (the 8 * "License"); you may not use this file except in compliance --- 115 unchanged lines hidden (view full) --- 124NameChain::Add_Segment( const char * i_sSeg ) 125{ 126 aSegments.push_back( NameSegment(i_sSeg) ); 127} 128 129List_TplParameter & 130NameChain::Templatize_LastSegment() 131{ | 1/************************************************************** 2 * 3 * Licensed to the Apache Software Foundation (ASF) under one 4 * or more contributor license agreements. See the NOTICE file 5 * distributed with this work for additional information 6 * regarding copyright ownership. The ASF licenses this file 7 * to you under the Apache License, Version 2.0 (the 8 * "License"); you may not use this file except in compliance --- 115 unchanged lines hidden (view full) --- 124NameChain::Add_Segment( const char * i_sSeg ) 125{ 126 aSegments.push_back( NameSegment(i_sSeg) ); 127} 128 129List_TplParameter & 130NameChain::Templatize_LastSegment() 131{ |
132 csv_assert( aSegments.size() > 0 ); | 132 csv_assert( ! aSegments.empty() ); |
133 134 return aSegments.back().AddTemplate(); 135} 136 137intt 138NameChain::Compare( const NameChain & i_rChain ) const 139{ 140 intt nResult = intt(aSegments.size()) - intt(i_rChain.aSegments.size()); --- 12 unchanged lines hidden (view full) --- 153 } 154 155 return 0; 156} 157 158const String & 159NameChain::LastSegment() const 160{ | 133 134 return aSegments.back().AddTemplate(); 135} 136 137intt 138NameChain::Compare( const NameChain & i_rChain ) const 139{ 140 intt nResult = intt(aSegments.size()) - intt(i_rChain.aSegments.size()); --- 12 unchanged lines hidden (view full) --- 153 } 154 155 return 0; 156} 157 158const String & 159NameChain::LastSegment() const 160{ |
161 if ( aSegments.size() > 0 ) | 161 if ( ! aSegments.empty() ) |
162 return aSegments.back().Name(); 163 return String::Null_(); 164} 165 166void 167NameChain::Get_Text( StreamStr & o_rPreName, 168 StreamStr & o_rName, 169 StreamStr & o_rPostName, --- 21 unchanged lines hidden --- | 162 return aSegments.back().Name(); 163 return String::Null_(); 164} 165 166void 167NameChain::Get_Text( StreamStr & o_rPreName, 168 StreamStr & o_rName, 169 StreamStr & o_rPostName, --- 21 unchanged lines hidden --- |