4 // Fraunhofer Institute for Open Communication Systems (FOKUS)
6 // The contents of this file are subject to the Fraunhofer FOKUS Public License
7 // Version 1.0 (the "License"); you may not use this file except in compliance
8 // with the License. You may obtain a copy of the License at
9 // http://senf.berlios.de/license.html
11 // The Fraunhofer FOKUS Public License Version 1.0 is based on,
12 // but modifies the Mozilla Public License Version 1.1.
13 // See the full license text for the amendments.
15 // Software distributed under the License is distributed on an "AS IS" basis,
16 // WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
17 // for the specific language governing rights and limitations under the License.
19 // The Original Code is Fraunhofer FOKUS code.
21 // The Initial Developer of the Original Code is Fraunhofer-Gesellschaft e.V.
22 // (registered association), Hansastraße 27 c, 80686 Munich, Germany.
23 // All Rights Reserved.
26 // Stefan Sauer <ssauer@berlios.de>
29 // Definition of non-inline non-template functions
32 #include "NDPOptions.hh"
35 //-/////////////////////////////////////////////////////////////////////////////////////////////////
36 SENF_PACKET_TLV_REGISTRY_REGISTER( senf::NDPSourceLLAddressTLVParser );
37 SENF_PACKET_TLV_REGISTRY_REGISTER( senf::NDPTargetLLAddressTLVParser );
38 SENF_PACKET_TLV_REGISTRY_REGISTER( senf::NDPPrefixInformationTLVParser );
39 SENF_PACKET_TLV_REGISTRY_REGISTER( senf::NDPMTUTLVParser );
41 prefix_ void senf::NDPSourceLLAddressTLVParser::dump(std::ostream & os) const
43 os << "Source Link-layer Address Option:" << "\n";
44 os << senf::fieldName("Link-layer Address") << source() << "\n";
47 prefix_ void senf::NDPTargetLLAddressTLVParser::dump(std::ostream & os) const
49 os << "Target Link-layer Address Option:" << "\n";
50 os << senf::fieldName("Link-layer Address") << target() << "\n";
53 prefix_ void senf::NDPPrefixInformationTLVParser::dump(std::ostream & os) const
55 os << "Prefix Information Option:" << "\n";
56 os << senf::fieldName("Prefix Length") << unsigned(prefixLength()) << "\n";
57 os << senf::fieldName("On-link Flag") << unsigned(l()) << "\n";
58 os << senf::fieldName("Autonomous Address-configuration Flag") << unsigned(a()) << "\n";
59 os << senf::fieldName("Reserved(6Bit)") << unsigned(reserved1()) << "\n";
60 os << senf::fieldName("Valid Lifetime") << unsigned(validLifetime()) << "\n";
61 os << senf::fieldName("Preferred Lifetime") << unsigned(preferredLifetime()) << "\n";
62 os << senf::fieldName("Reserved(32Bit)") << unsigned(reserved2()) << "\n";
63 os << senf::fieldName("Prefix") << prefix() << "\n";
67 prefix_ void senf::NDPMTUTLVParser::dump(std::ostream & os) const
69 os << "MTU Information Option:" << "\n";
70 os << senf::fieldName("MTU") << unsigned(mtu()) << "\n";
74 //-/////////////////////////////////////////////////////////////////////////////////////////////////