1 #ifndef __JTOOLS__JROUTER__ 
    2 #define __JTOOLS__JROUTER__ 
   16 namespace JPP { 
using namespace JTOOLS; }
 
   20   using JLANG::JComparisonAvailable;
 
   26   template<class JAddress_t, bool has_eq = JComparisonAvailable<JAddress_t>::has_eq>
 
   33   template<
class JAddress_t>
 
   35     protected std::deque<JAddress_t>
 
   45       std::deque<JAddress_t>()
 
   63       static JAddress_t address;
 
   74       static_cast<std::deque<JAddress_t>&
>(*this).clear();
 
   87       std::swap(this->
first, router.first);
 
   89       static_cast<std::deque<JAddress_t>&
>(*this).swap(router);
 
  100       this->
first = router.first;
 
  102       if (router.size() > this->size()) {
 
  103         this->resize(router.size());
 
  118         this->push_back(address);
 
  122       } 
else if (id < this->
first) {
 
  124         this->insert(this->begin(), this->first - 
id, getDefaultAddress());
 
  128         this->at(0) = address;
 
  132         const size_t index = (size_t) (
id - this->first);
 
  134         if (index >= this->size()) {
 
  135           this->resize(index + 1, getDefaultAddress());
 
  138         this->at(index) = address;
 
  151       return (
id >= this->
first && id < this->
first + (
int) this->size());
 
  161     const JAddress_t& 
get(
const int id) 
const 
  163       return this->at(
id - this->
first);
 
  174   template<
class JAddress_t>
 
  176     public JRouter<JAddress_t, false>
 
  238         return __is_valid && address == __address;
 
  265       defaultAddress(address)
 
  276       return defaultAddress.is_valid();
 
  287       return defaultAddress.getAddress();
 
  298       defaultAddress = JAddress(address);
 
  308     bool has(
const int id)
 const 
  310       return (this->in_range(
id) && !this->defaultAddress.equals(
this->get(
id)));
 
then usage $script< detector file >< detectorfile > nIf the range of floors is the first detector file is aligned to the second before the comparison nIn this
 
then echo The file $DIR KM3NeT_00000001_00000000 root already please rename or remove it first
 
JArgument< T >::argument_type argument_type