From: g0dil Date: Fri, 22 Dec 2006 08:59:56 +0000 (+0000) Subject: Fix Doxygen builder file globbing X-Git-Url: http://g0dil.de/git?a=commitdiff_plain;h=cd9dd31c21fb021fe2c27ff52419b0e93340a964;p=senf.git Fix Doxygen builder file globbing Add MAXWIDTH support to Dia2Png builder Start Socket library documentation git-svn-id: https://svn.berlios.de/svnroot/repos/senf/trunk@173 270642c3-0616-0410-b53a-bc976706d245 --- diff --git a/Packets/structure.dia b/Packets/structure.dia index d8685bf..f6ea11f 100644 Binary files a/Packets/structure.dia and b/Packets/structure.dia differ diff --git a/Socket/FileHandle.hh b/Socket/FileHandle.hh index 963689d..d11f2ee 100644 --- a/Socket/FileHandle.hh +++ b/Socket/FileHandle.hh @@ -20,15 +20,6 @@ // Free Software Foundation, Inc., // 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. - -/** \mainpage The SENF Socket Library - -\section arch Overall Architecture - -\image html "../../SocketLibrary-classes.png" Class Diagram - - */ - #ifndef HH_FileHandle_ #define HH_FileHandle_ 1 diff --git a/Socket/Mainpage.dox b/Socket/Mainpage.dox new file mode 100644 index 0000000..09e881b --- /dev/null +++ b/Socket/Mainpage.dox @@ -0,0 +1,90 @@ +/** \mainpage The SENF Socket Library + + The Socket library provides a high level and object oriented + abstraction of the BSD socket API. The abstraction is based on + several concepts: + + \li The basic visible interface is a handle object + (senf::FileHandle and it's derived classes) + \li The socket interface relies on a policy framework to configure + it's functionality + \li The rest of the socket API is accessible using a classic + inheritance hierarchy of protocol classes + + The handle/body architecture provides automatic reference counted + management of socket instances, the policy framework provides + highly efficient access to the most important socket functions + (like reading and writing) and the inheritance hierarchy provides + convenient access to the multitude of special and protocol + dependent options. + + \see \ref usage \n + \ref extend \n + \ref implementation + */ + +/** \page usage Using the Socket Library + + \section socket_handle The socket handle + + Whenever you use the socket library, what you will be dealing with + are senf::FileHandle derived instances. The socket library relies + on reference counting to automatically manage the underlying + socket representation. This frees you of having to manage the + socket lifetime explicitly. + + \attention It is very important, to (almost) always pass the socket + handle by value. The socket handle is a very lightweight + class and designed to be used like an ordinary built-in type. This + is very important in combination with the policy interface. + + \section policy_framework The policy framework + + The policy framework conceptually implements a list of parallel + inheritance hierarchies each covering a specific interface aspect + of the socket handle. The socket handle itself only provides + minimal functionality. All further functionality is relayed to a + policy class, or more precisely, to a group of policy classes, one + for each policy axis. The policy axis are + +
+
addressingPolicy
+
configures, whether a socket is + addressable and if so, configures the address type
+ +
framingPolicy
+
configures the type of framing the socket provides: either no + framing providing a simple i/o stream or packet framing
+ +
communicationPolicy
+
configures,if and how the communication partner is + selected
+ +
readPolicy
+
configures the readability of the socket
+ +
writePolicy
+
configures the writability of the socket
+ +
bufferingPolicy
+
configures, if and how buffering is configured for a socket
+
+ + */ + +/** \page extend Extending the Library + */ + +/** \page implementation Implementation notes + + \image html "../../SocketLibrary-classes.png" Class hierarchy + */ + + + +// Local Variables: +// mode: c++ +// mode: flyspell +// mode: auto-fill +// ispell-local-dictionary: "american" +// End: diff --git a/Socket/SConscript b/Socket/SConscript index 8925f1f..ffd61cd 100644 --- a/Socket/SConscript +++ b/Socket/SConscript @@ -15,5 +15,5 @@ SENFSCons.Lib(env, LIBS = [ 'Utils' ]) SENFSCons.Doxygen(env, extra_sources = [ - env.Dia2Png('SocketLibrary-classes.dia') - ]) + env.Dia2Png('SocketLibrary-classes.dia'), +]) diff --git a/Socket/SocketLibrary-classes.dia b/Socket/SocketLibrary-classes.dia index 679f3d1..c0e9d1f 100644 Binary files a/Socket/SocketLibrary-classes.dia and b/Socket/SocketLibrary-classes.dia differ diff --git a/doclib/senf.css b/doclib/senf.css index 86b4cd2..51702a9 100644 --- a/doclib/senf.css +++ b/doclib/senf.css @@ -44,7 +44,7 @@ body { #content2 { /* need non-zero top padding here to prevent margin propagation */ padding: 10px 0 0 142px; - max-width: 60em; + max-width: 62em; } a { @@ -131,7 +131,7 @@ div.qindex { color: #726921; white-space: nowrap; text-align: right; - max-width: 60em; + max-width: 62em; } #footer span { @@ -148,3 +148,20 @@ div.qindex { text-decoration: underline; } +dl.attention { + border: 1px solid #AADD88; + background-color: #EEFFDD; + padding: 4px; +} + +dl.warning { + border: 1px solid #DDAA88; + background-color: #FFEEDD; + padding: 4px; +} + +dl.note { + border: 1px solid A0C2C2; + background-color: #F0F8F8; + padding: 4px; +} \ No newline at end of file diff --git a/senfscons/Dia2Png.py b/senfscons/Dia2Png.py index d536ebf..a518464 100644 --- a/senfscons/Dia2Png.py +++ b/senfscons/Dia2Png.py @@ -17,11 +17,14 @@ def dia_getSize(env,source): def dia2png_generator(source, target, env, for_signature): if for_signature: - return "$DIACOM -t png -s $DIA2PNGDPI $TARGET $SOURCE" + return "$DIACOM -t png -s $DIA2PNGDPI,$DIA2PNGMAXWIDTH $TARGET $SOURCE" size = dia_getSize(env,source) if not size: return None; size[0] = size[0]*int(env['DIA2PNGDPI'])/72 size[1] = size[1]*int(env['DIA2PNGDPI'])/72 + if size[0] > env['DIA2PNGMAXWIDTH']: + size[1] = size[1]*env['DIA2PNGMAXWIDTH']/size[0] + size[0] = env['DIA2PNGMAXWIDTH'] return env.Action("$DIACOM -t png -s %dx%d -e $TARGET $SOURCE" % tuple(size)) Dia2Png = SCons.Builder.Builder(suffix = ".png", @@ -33,6 +36,7 @@ def generate(env): env['BUILDERS']['Dia2Png'] = Dia2Png env['DIACOM'] = "dia" env['DIA2PNGDPI'] = 115 + env['DIA2PNGMAXWIDTH'] = 800 def exists(env): return env.Detect("dia") diff --git a/senfscons/Doxygen.py b/senfscons/Doxygen.py index db9fc5c..f379f91 100644 --- a/senfscons/Doxygen.py +++ b/senfscons/Doxygen.py @@ -127,9 +127,9 @@ def DoxySourceScan(node, env, path): for root, dirs, files in entries: for f in files: filename = os.path.normpath(os.path.join(root, f)) - if ( reduce(lambda x, y: x or fnmatch(filename, y), + if ( reduce(lambda x, y: x or fnmatch(f, y), file_patterns, False) - and not reduce(lambda x, y: x or fnmatch(filename, y), + and not reduce(lambda x, y: x or fnmatch(f, y), exclude_patterns, False) ): sources.append(filename) @@ -187,7 +187,7 @@ def doxyNodeHtmlDir(node): if not node.sources : return None data = DoxyfileParse(node.sources[0].abspath) if data.get("GENERATE_HTML",'YES').upper() != 'YES' : return None - return os.path.normpath(os.path.join( node.sources[0].abspath, + return os.path.normpath(os.path.join( node.sources[0].dir.abspath, data.get("OUTPUT_DIRECTORY","."), data.get("HTML_OUTPUT","html") ))