1/*
2 * Copyright 2012 Haiku, Inc. All rights reserved.
3 * Distributed under the terms of the MIT License.
4 *
5 * Authors:
6 *		Pawe�� Dziepak, pdziepak@quarnos.org
7 */
8#ifndef NFS4OBJECT_H
9#define NFS4OBJECT_H
10
11#include "FileInfo.h"
12#include "NFS4Defs.h"
13#include "RPCServer.h"
14
15
16struct OpenStateCookie;
17struct OpenState;
18
19class NFS4Object {
20public:
21			bool		HandleErrors(uint32& attempt, uint32 nfs4Error,
22							RPC::Server* server, OpenStateCookie* cookie = NULL,
23							OpenState* state = NULL, uint32* sequence = NULL);
24
25			status_t	ConfirmOpen(const FileHandle& fileHandle,
26							OpenState* state, uint32* sequence);
27
28	static	uint32		IncrementSequence(uint32 error);
29
30	inline				NFS4Object();
31
32			FileInfo	fInfo;
33			FileSystem*	fFileSystem;
34};
35
36
37inline
38NFS4Object::NFS4Object()
39	:
40	fFileSystem(NULL)
41{
42}
43
44
45#endif	// NFS4OBJECT_H
46
47