consistent namespace

This commit is contained in:
Hieu Hoang 2014-10-09 12:52:06 +01:00
parent e7916239d5
commit bf089b56ac
9 changed files with 12 additions and 26 deletions

View File

@ -28,7 +28,6 @@
#include <xmlrpc-c/server_abyss.hpp> #include <xmlrpc-c/server_abyss.hpp>
using namespace Moses; using namespace Moses;
using namespace MosesCmd;
using namespace std; using namespace std;
typedef std::map<std::string, xmlrpc_c::value> params_t; typedef std::map<std::string, xmlrpc_c::value> params_t;
@ -491,7 +490,7 @@ public:
{ {
// should the score breakdown be reported in a more structured manner? // should the score breakdown be reported in a more structured manner?
ostringstream buf; ostringstream buf;
MosesCmd::OutputAllFeatureScores(path.GetScoreBreakdown(),buf); Moses::OutputAllFeatureScores(path.GetScoreBreakdown(),buf);
nBestXMLItem["fvals"] = xmlrpc_c::value_string(buf.str()); nBestXMLItem["fvals"] = xmlrpc_c::value_string(buf.str());
} }

View File

@ -55,12 +55,11 @@ POSSIBILITY OF SUCH DAMAGE.
using namespace std; using namespace std;
using namespace Moses; using namespace Moses;
using namespace MosesCmd;
//keys //keys
enum gridkey {lmbr_p,lmbr_r,lmbr_prune,lmbr_scale}; enum gridkey {lmbr_p,lmbr_r,lmbr_prune,lmbr_scale};
namespace MosesCmd namespace Moses
{ {
class Grid class Grid

View File

@ -53,9 +53,8 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
using namespace std; using namespace std;
using namespace Moses; using namespace Moses;
using namespace MosesCmd;
namespace MosesCmd namespace Moses
{ {
void OutputFeatureWeightsForHypergraph(std::ostream &outputSearchGraphStream) void OutputFeatureWeightsForHypergraph(std::ostream &outputSearchGraphStream)

View File

@ -51,9 +51,8 @@ POSSIBILITY OF SUCH DAMAGE.
#include "IOWrapper.h" #include "IOWrapper.h"
using namespace std; using namespace std;
using namespace Moses;
namespace MosesCmd namespace Moses
{ {
IOWrapper::IOWrapper(const std::vector<FactorType> &inputFactorOrder IOWrapper::IOWrapper(const std::vector<FactorType> &inputFactorOrder

View File

@ -57,10 +57,6 @@ namespace Moses
class ScoreComponentCollection; class ScoreComponentCollection;
class Hypothesis; class Hypothesis;
class Factor; class Factor;
}
namespace MosesCmd
{
/** Helper class that holds misc variables to write data out to command line. /** Helper class that holds misc variables to write data out to command line.
*/ */

View File

@ -13,9 +13,8 @@
#include <set> #include <set>
using namespace std; using namespace std;
using namespace Moses;
namespace MosesCmd namespace Moses
{ {
size_t bleu_order = 4; size_t bleu_order = 4;

View File

@ -19,7 +19,7 @@
namespace MosesCmd namespace Moses
{ {
class Edge; class Edge;

View File

@ -10,12 +10,11 @@
#include "mbr.h" #include "mbr.h"
using namespace std; using namespace std;
using namespace Moses;
namespace MosesCmd namespace Moses
{ {
TranslationTask::TranslationTask(InputType* source, MosesCmd::IOWrapper &ioWrapper, TranslationTask::TranslationTask(InputType* source, Moses::IOWrapper &ioWrapper,
bool outputSearchGraphSLF, bool outputSearchGraphSLF,
boost::shared_ptr<HypergraphOutput<Manager> > hypergraphOutput) : boost::shared_ptr<HypergraphOutput<Manager> > hypergraphOutput) :
m_source(source), m_source(source),

View File

@ -7,12 +7,8 @@
namespace Moses namespace Moses
{ {
class InputType; class InputType;
class OutputCollector; class OutputCollector;
}
namespace MosesCmd
{
class IOWrapper; class IOWrapper;
@ -26,7 +22,7 @@ class TranslationTask : public Moses::Task
public: public:
TranslationTask(Moses::InputType* source, MosesCmd::IOWrapper &ioWrapper, TranslationTask(Moses::InputType* source, Moses::IOWrapper &ioWrapper,
bool outputSearchGraphSLF, bool outputSearchGraphSLF,
boost::shared_ptr<Moses::HypergraphOutput<Moses::Manager> > hypergraphOutput); boost::shared_ptr<Moses::HypergraphOutput<Moses::Manager> > hypergraphOutput);
@ -39,7 +35,7 @@ public:
private: private:
Moses::InputType* m_source; Moses::InputType* m_source;
MosesCmd::IOWrapper &m_ioWrapper; Moses::IOWrapper &m_ioWrapper;
bool m_outputSearchGraphSLF; bool m_outputSearchGraphSLF;
boost::shared_ptr<Moses::HypergraphOutput<Moses::Manager> > m_hypergraphOutput; boost::shared_ptr<Moses::HypergraphOutput<Moses::Manager> > m_hypergraphOutput;