small stuff

This commit is contained in:
Robin Müller 2020-10-05 00:12:52 +02:00
parent f955cd9eee
commit a7fe23c300

View File

@ -1,35 +1,40 @@
#include "FileSystemMessage.h"
#include "../objectmanager/ObjectManagerIF.h"
void FileSystemMessage::setCreateFileCommand(CommandMessage* message,
store_address_t storeId) {
message->setCommand(CREATE_FILE);
message->setParameter2(storeId.raw);
}
void FileSystemMessage::setDeleteFileCommand(
CommandMessage* message, store_address_t storageID) {
message->setCommand(DELETE_FILE);
message->setParameter2(storageID.raw);
CommandMessage* message, store_address_t storeId) {
message->setCommand(DELETE_FILE);
message->setParameter2(storeId.raw);
}
void FileSystemMessage::setCreateDirectoryCommand(
CommandMessage* message, store_address_t storageID) {
CommandMessage* message, store_address_t storeId) {
message->setCommand(CREATE_DIRECTORY);
message->setParameter2(storageID.raw);
message->setParameter2(storeId.raw);
}
void FileSystemMessage::setDeleteDirectoryCommand(
CommandMessage* message, store_address_t storageID) {
CommandMessage* message, store_address_t storeId) {
message->setCommand(DELETE_DIRECTORY);
message->setParameter2(storageID.raw);
message->setParameter2(storeId.raw);
}
void FileSystemMessage::setWriteCommand(CommandMessage* message,
store_address_t storageID) {
store_address_t storeId) {
message->setCommand(APPEND_TO_FILE);
message->setParameter2(storageID.raw);
message->setParameter2(storeId.raw);
}
void FileSystemMessage::setReadCommand(CommandMessage* message,
store_address_t storageID) {
store_address_t storeId) {
message->setCommand(READ_FROM_FILE);
message->setParameter2(storageID.raw);
message->setParameter2(storeId.raw);
}
void FileSystemMessage::setReadReply(CommandMessage* message,
@ -38,12 +43,6 @@ void FileSystemMessage::setReadReply(CommandMessage* message,
message->setParameter2(storageID.raw);
}
void FileSystemMessage::setCreateFileCommand(CommandMessage *message,
store_address_t storeId) {
message->setCommand(CREATE_FILE);
message->setParameter2(storeId.raw);
}
store_address_t FileSystemMessage::getStoreId(const CommandMessage* message) {
store_address_t temp;
temp.raw = message->getParameter2();