You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
47 lines
1.3 KiB
47 lines
1.3 KiB
//===- FileAction.h -------------------------------------------------------===//
|
|
//
|
|
// The MCLinker Project
|
|
//
|
|
// This file is distributed under the University of Illinois Open Source
|
|
// License. See LICENSE.TXT for details.
|
|
//
|
|
//===----------------------------------------------------------------------===//
|
|
#ifndef MCLD_MC_FILEACTION_H_
|
|
#define MCLD_MC_FILEACTION_H_
|
|
#include "mcld/MC/InputAction.h"
|
|
#include "mcld/Support/FileHandle.h"
|
|
|
|
namespace mcld {
|
|
|
|
class ContextFactory;
|
|
|
|
/** \class ContextAction
|
|
* \brief ContextAction is a command object to create input's LDContext.
|
|
*/
|
|
class ContextAction : public InputAction {
|
|
public:
|
|
explicit ContextAction(unsigned int pPosition);
|
|
|
|
bool activate(InputBuilder& pBuilder) const;
|
|
};
|
|
|
|
/** \class MemoryAreaAction
|
|
* \brief MemoryAreaAction is a command object to create input's MemoryArea.
|
|
*/
|
|
class MemoryAreaAction : public InputAction {
|
|
public:
|
|
MemoryAreaAction(unsigned int pPosition,
|
|
FileHandle::OpenModeEnum pMode,
|
|
FileHandle::PermissionEnum pPerm = FileHandle::System);
|
|
|
|
bool activate(InputBuilder& pBuilder) const;
|
|
|
|
private:
|
|
FileHandle::OpenMode m_Mode;
|
|
FileHandle::Permission m_Permission;
|
|
};
|
|
|
|
} // namespace mcld
|
|
|
|
#endif // MCLD_MC_FILEACTION_H_
|