Graphviz  2.41.20170921.2350
gv_php_init.c
Go to the documentation of this file.
1 /* $Id$ $Revision$ */
2 /* vim:set shiftwidth=4 ts=8: */
3 
4 /*************************************************************************
5  * Copyright (c) 2011 AT&T Intellectual Property
6  * All rights reserved. This program and the accompanying materials
7  * are made available under the terms of the Eclipse Public License v1.0
8  * which accompanies this distribution, and is available at
9  * http://www.eclipse.org/legal/epl-v10.html
10  *
11  * Contributors: See CVS logs. Details at http://www.graphviz.org/
12  *************************************************************************/
13 
14 #include <php.h>
15 #undef PACKAGE_BUGREPORT
16 #undef PACKAGE_NAME
17 #undef PACKAGE_STRING
18 #undef PACKAGE_TARNAME
19 #undef PACKAGE_VERSION
20 
21 #include "gvc.h"
22 #include "gvplugin.h"
23 #include "gvcjob.h"
24 #include "gvcint.h"
25 
26 static size_t gv_string_writer (GVJ_t *job, const char *s, size_t len)
27 {
28  return PHPWRITE(s, len);
29 }
30 
31 static size_t gv_channel_writer (GVJ_t *job, const char *s, size_t len)
32 {
33  return PHPWRITE(s, len);
34 }
35 
37 {
38  gvc->write_fn = gv_string_writer;
39 }
40 
42 {
43  gvc->write_fn = gv_channel_writer;
44 }
45 
void gv_writer_reset(GVC_t *gvc)
Definition: gv_dummy_init.c:5
Definition: gvcjob.h:271
void gv_string_writer_init(GVC_t *gvc)
Definition: gv_dummy_init.c:3
Definition: gvcint.h:70
Definition: grammar.c:79
#define NULL
Definition: logic.h:39
GVC_t * gvc
Definition: htmlparse.c:87
void gv_channel_writer_init(GVC_t *gvc)
Definition: gv_dummy_init.c:4
size_t(* write_fn)(GVJ_t *job, const char *s, size_t len)
Definition: gvcint.h:92