Subversion Repositories mdb

Rev

Rev 56 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
2 andreas 1
/*
2
 * Copyright (C) 2015 by Andreas Theofilu <andreas@theosys.at>
3
 *
4
 * All rights reserved. No warranty, explicit or implicit, provided.
5
 *
6
 * NOTICE:  All information contained herein is, and remains
7
 * the property of Andreas Theofilu and his suppliers, if any.
8
 * The intellectual and technical concepts contained
9
 * herein are proprietary to Andreas Theofilu and its suppliers and
10
 * may be covered by European and Foreign Patents, patents in process,
11
 * and are protected by trade secret or copyright law.
12
 * Dissemination of this information or reproduction of this material
13
 * is strictly forbidden unless prior written permission is obtained
14
 * from Andreas Theofilu.
15
 */
16
 
17
#ifndef __MDB__
18
#define __MDB__
19
 
59 andreas 20
#include <pthread.h>
21
 
11 andreas 22
#define PAGE_NONE			0
23
#define PAGE_TITLE			1
24
#define PAGE_ARTIST			2
25
#define PAGE_ALBUM			3
26
#define PAGE_GENRE			4
27
#define PAGE_QUEUE			5
28
#define PAGE_PLAYLIST		6
29
 
32 andreas 30
#define FILE_TYPE_MP3		1
31
#define FILE_TYPE_FLAC		2
32
 
56 andreas 33
#define MAX_HANDLES			100
34
 
2 andreas 35
struct SOCKETS
36
{
37
	int sockfd;
38
	int newfd;
39
};
40
 
11 andreas 41
extern int currentPage;
19 andreas 42
extern struct SOCKETS soc;
56 andreas 43
extern int _s1[];
11 andreas 44
 
59 andreas 45
pthread_attr_t pattr;
46
 
2 andreas 47
int parseCommand(int s1, char *cmd);
48
void *processCommands(void *pV_data);
49
 
56 andreas 50
void handleInit();
51
void handleAdd(int fd);
52
void handleDelete(int fd);
53
void handleWrite(char *txt);
54
 
2 andreas 55
#endif