Reputation: 1677
I have two classes Link
and MetaData
(code below). The classes are in the same folder. However, in documentation generated by Doxygen the class Link
is documented but the class MetaData
is not. Any ideas why this is?
Link:
#include <string.h>
#include <dbus-c++/dbus.h>
#ifndef LINK_H_
#define LINK_H_
typedef ::DBus::Struct< std::string, std::string > Link_Dbus_t;
class Link {
private:
const char* mUrl;
const char* mExpirationDate;
public:
Link();
virtual ~Link();
Link(const Link& l);
void setUrl(const char* url);
void setExpirationDate(const char* date);
const char* getUrl();
const char* getExpirationDate();
void operator << (const Link_Dbus_t& link_info);
};
Link_Dbus_t& operator << (Link_Dbus_t& link_info, Link& link);
#endif /* LINK_H_ */
MetaData:
#include <vector>
#include <iostream>
#include <string.h>
#include <dbus-c++/dbus.h>
#include "MetadataAttributes.h"
using namespace std;
#ifndef METADATA_H_
#define METADATA_H_
typedef vector< metadataStruct_Dbus_t > metadataVector_Dbus_t;
class MetaData : public vector <MetadataAttributes> {
private:
const char* mSize;
const char* mRev;
const char* mModified;
const char* mPath;
const char* mIcon;
const char* mRoot;
const char* mMimeType;
const char* mHash;
int mRevision;
int mBytes;
bool mThumbExists;
bool mIsDir;
bool mIsDeleted;
vector<MetaData> mLinkedMetaData;
public:
enum ePrintWhat {
PRINT_METADATA_OF_FILES_AND_FOLDERS,
PRINT_REVISION_FILES,
PRINT_SEARCHED_FILES,
PRINT_RESTORED_FILE,
PRINT_COPIED_FILE,
PRINT_CREATED_FOLDER,
PRINT_DELETED_FILE_OR_FOLDER,
PRINT_MOVED_FILE
};
MetaData();
virtual ~MetaData();
MetaData(const MetaData& m);
void setSize(const char* size);
void setRev(const char* rev);
void setModified(const char* modified);
void setPath(const char* path);
void setIcon(const char* icon);
void setRoot(const char* root);
void setMimeType(const char* mimeType);
void setHash(const char* hash);
void setRevision(int revision);
void setBytes(int bytes);
void thumbExists(bool thumbExists);
void isDir(bool isDir);
void isDeleted(bool isDeleted);
const char* getSize();
const char* getRev();
const char* getModified();
const char* getPath();
const char* getIcon();
const char* getRoot();
const char* getMimeType();
const char* getHash();
int getRevision();
int getBytes();
bool thumbExists();
bool isDir();
bool isDeleted();
vector<MetaData>* getLinkedMetaData();
void printMetadata(ePrintWhat printWhat);
void operator << (const metadataVector_Dbus_t data_vec);
};
metadataVector_Dbus_t &operator << (metadataVector_Dbus_t& s1, const MetaData &s2);
#endif /* METADATA_H_ */
EDIT: I detected that when I isolate the two classes MetaData and Session then the MetaData class is not documented. There is in any way a file conflict. Here's the Session class:
#include <iostream>
#include "Account.h"
#include "MetaData.h"
#include "Link.h"
#include "WatchThread.h"
#include <map>
#include <json/json.h>
#include <oauth.h>
#include <string.h>
#include <curl/curl.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <time.h>
#include <pthread.h>
#include <sys/time.h>
using namespace std;
#ifndef SESSION_H_
#define SESSION_H_
class Session {
private:
typedef void (*TransferFinishedCallback)(unsigned int,const char*);
typedef void (*WatchCallback)(unsigned int, const char*, bool,bool);
typedef void (*WatchThreadInitedCallback)(unsigned int);
unsigned int mThread_id;
map<unsigned int,WatchThread> mWatchThreads;
map<unsigned int,pthread_t> mDownloadThreads;
map<unsigned int,pthread_t> mUploadThreads;
const char* mConsumer_key;
const char* mConsumer_secret;
const char* mRequestToken;
const char* mRequestTokenSecret;
const char* mAccessToken;
const char* mAcccessTokenSecret;
bool jsonParseErrorIsOccured(const char* c);
void jsonParseLink(json_object* jobj,Link *link);
void jsonParseAccountInfo(json_object* jobj, Account *account);
void jsonParseMetadata(json_object* jobj,MetaData *metadata);
void jsonParseArray(json_object* jobj, char* key, MetaData *metadata);
void parseTokenAndSecretValueFromString(const char* s, const char* &token, const char* &secret);
char* getMetaDataUrl(const char* fileOrFolderPath, const char* hash, bool list, bool include_deleted, const char* rev);
public:
Session();
Session(const char* mConsumer_key,const char* mConsumer_secret);
virtual ~Session();
Session(const Session& s);
struct arg_struct;
struct watch_struct;
const char* login();
bool login(const char* accessToken, const char* accessTokenSecret);
void acquireAccessToken(const char* &accessToken, const char* &accessTokenSecret);
bool userIsAuthorized();
Account* getAccountInfo();
MetaData* getMetaDataOfFileOrFolder(const char* fileOrFolderPath,const char* hash, bool list, bool include_deleted,
const char* rev);
MetaData* getMetDataOfFileRevisions(const char* filePath,const char* revLimit);
unsigned int getFile(const char* filePath,const char* targetFilePath, const char* rev, TransferFinishedCallback callback);
void stopDownloading(unsigned int id);
unsigned int putFile(const char* filePath, const char* targetFilePath,bool overwrite, const char* parent_rev, TransferFinishedCallback callback);
void stopUploading(unsigned int id);
MetaData* restoreFileToRevision(const char* filePath, const char* rev);
MetaData* searchForFileInFolder(const char* folderPath,const char* query,const char* fileLimit, bool include_deleted);
Link* createShareableLink(const char* fileOrFolderPath);
Link* getLinkToFile(const char* filepath);
unsigned int getThumbnail(const char* imageFilePath, const char* format, const char* size, const char* targetFilePath, TransferFinishedCallback callback);
MetaData* copyFolderOrFileTo(const char* root,const char* from_path, const char* to_path);
MetaData* createFolder(const char* root, const char* targetPath);
MetaData* deleteFileOrFolder(const char* root, const char* fileOrFolderPath);
MetaData* moveFileOrFolderTo(const char* root, const char* from_path, const char* to_path);
unsigned int watchFileOrFolder(const char* fileOrFolderPath, unsigned int updateInterval,WatchCallback callback_finish,WatchThreadInitedCallback callback_init, bool recursive);
const char* getRequestToken();
const char* getRequestTokenSecret();
const char* getAccessToken();
const char* getAccessTokenSecret();
void deleteWatchThreadWithId(unsigned int id);
void stopWatchThread(unsigned int id);
vector<int> runningWatchThreads();
vector<int> runningDownloadThreads();
vector<int> runningUploadThreads();
void setAccessToken(const char* accessToken, const char* accessTokenSecret);
};
#endif /* SESSION_H_ */
Upvotes: 0
Views: 156
Reputation: 8288
There are two likely causes, either an error in your Doxygen configuration file, or a conflict in another file in the directory.
To review the Doxygen configuration file, generate a default Doxyfile
(doxygen -s -g
), and review the differences between the default configuration and the version you are using. For any differences you may want to try setting the value to the default from the Doxyfile
to determine if that makes a difference. Pay particular attention to the EXTRACT_*
, HIDE_*
and SHOW_*
options.
To determine if it may be a file conflict, temporarily remove all other files from the directory and determine if Documentation is generated in isolation. If it is, re-add files until the class is no longer generated, and then review the added files to determine what if anything might be causing a conflict with MetaData
. If it is not documented even in isolation, review your Doxygen configuration file again.
As an experiment I placed the two files described in a temporary directory along with a default generated Doxyfile
from Doxygen 1.7.6.1. Both classes were documented, however their members were not linked. Changing the Doxyfile
to specify EXTRACT_ALL=YES
caused the members to all be documented.
Upvotes: 1