File: testcontext.c

package info (click to toggle)
gman 0.0.8-6
  • links: PTS
  • area: main
  • in suites: woody
  • size: 244 kB
  • ctags: 354
  • sloc: ansic: 3,208; makefile: 60
file content (15 lines) | stat: -rw-r--r-- 374 bytes parent folder | download | duplicates (8)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#include <stdio.h>
#include "context.h"

main()
{
	int i;
	AppContext context(NULL);
	context.set_value("test",(void*)1234);
	context.set_value("v_size",(void*)1024);
	context.restore_default("test");
	context.display_values();
	i = (int)context.get_value("v_size");
	printf("v_size = %d, h_size = %d, test = %d",i,context.get_value("h_size"),context.get_value("test"));
}