/usr/include/ns3.27/ns3/parallel-communication-interface.h is in libns3-dev 3.27+dfsg-1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 | /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
/*
* Copyright 2013. Lawrence Livermore National Security, LLC.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 as
* published by the Free Software Foundation;
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
* Author: Steven Smith <smith84@llnl.gov>
*
*/
#ifndef NS3_PARALLEL_COMMUNICATION_INTERFACE_H
#define NS3_PARALLEL_COMMUNICATION_INTERFACE_H
#include <stdint.h>
#include <list>
#include <ns3/object.h>
#include <ns3/nstime.h>
#include <ns3/buffer.h>
#include <ns3/packet.h>
#if defined(NS3_MPI)
#include "mpi.h"
#endif
namespace ns3 {
/**
* \ingroup mpi
*
* \brief Pure virtual base class for the interface between ns-3 and
* the parallel communication layer being used.
*
* Each type of parallel communication layer is required to implement
* this interface. This interface is called through the
* MpiInterface.
*/
class ParallelCommunicationInterface
{
public:
/**
* Destructor
*/
virtual ~ParallelCommunicationInterface() {}
/**
* Deletes storage used by the parallel environment.
*/
virtual void Destroy () = 0;
/**
* \return system identification
*/
virtual uint32_t GetSystemId () = 0;
/**
* \return number of parallel tasks
*/
virtual uint32_t GetSize () = 0;
/**
* \return true if parallel communication is enabled
*/
virtual bool IsEnabled () = 0;
/**
* \param pargc number of command line arguments
* \param pargv command line arguments
*
* Sets up parallel communication interface
*/
virtual void Enable (int* pargc, char*** pargv) = 0;
/**
* Terminates the parallel environment.
* This function must be called after Destroy ()
*/
virtual void Disable () = 0;
/**
* \param p packet to send
* \param rxTime received time at destination node
* \param node destination node
* \param dev destination device
*
* Serialize and send a packet to the specified node and net device
*/
virtual void SendPacket (Ptr<Packet> p, const Time &rxTime, uint32_t node, uint32_t dev) = 0;
private:
};
} // namespace ns3
#endif /* NS3_PARALLEL_COMMUNICATION_INTERFACE_H */
|