Skip to content

Commit

Permalink
Update List2.h
Browse files Browse the repository at this point in the history
  • Loading branch information
CJohnny authored Apr 7, 2017
1 parent 6dd89c4 commit 304e500
Showing 1 changed file with 12 additions and 13 deletions.
25 changes: 12 additions & 13 deletions linearList2/List2.h
Original file line number Diff line number Diff line change
@@ -1,34 +1,33 @@
#ifndef NODE_H
#define NODE_H
#ifndef LIST_H
#define LIST_H
#include "Node.h"

class List{

private:

int* m_pList;
Node* m_pList;
int m_length;


public:
List();
~List(); //包括头节点,释放
~List(); //包括头节点,释放
// void deleteList();
void clearList(); //除了头节点,释放
void clearList(); //除了头节点,释放
void listTraverse();
bool listEmpty();
bool initList();
bool getElem(int i, int* e);
bool priorElem(int* currentElem, int* preElem);
bool nextElem(int* currentElem, int* nextElem);
bool listInsert(int i, int* e);
bool listDelete(int i, int* e);
bool getElem(int i, Node* pNode);
bool priorElem(Node* currentNode, Node* preNode);
bool nextElem(Node* currentNode, Node* nextNode);
bool listInsert(int i, Node* pNode);
bool listDelete(int i, Node* pNode);
bool listInsertHead(Node* pNode);
bool listInsertTail(Node* pNode);
int listLength();
int locateElem(int*e);
int locateElem(Node* pNode);
};



#endif // NODE_H
#endif // LIST_H

0 comments on commit 304e500

Please sign in to comment.