File: FileSystemHandler.xs

package info (click to toggle)
libwx-perl 1%3A0.9932-9
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 5,300 kB
  • sloc: cpp: 11,064; perl: 8,603; ansic: 711; makefile: 53
file content (146 lines) | stat: -rw-r--r-- 3,014 bytes parent folder | download | duplicates (7)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
#############################################################################
## Name:        ext/filesys/XS/FileSystemHandler.xs
## Purpose:     XS for Wx::FileSystemhandler
## Author:      Mattia Barbon
## Modified by:
## Created:     28/04/2001
## RCS-ID:      $Id: FileSystemHandler.xs 2393 2008-05-14 20:54:52Z mbarbon $
## Copyright:   (c) 2001-2008 Mattia Barbon
## Licence:     This program is free software; you can redistribute it and/or
##              modify it under the same terms as Perl itself
#############################################################################

#include <wx/filesys.h>
#include <wx/fs_inet.h>
#include <wx/fs_zip.h>
#include <wx/fs_mem.h>

#undef THIS

MODULE=Wx PACKAGE=Wx::FileSystemHandler

#if 0 // protected!

wxString
wxFileSystemHandler::GetAnchor( location )
    wxString location

wxString
wxFileSystemHandler::GetLeftLocation( location )
    wxString location

wxString
wxFileSystemHandler::GetMimeTypeFromExt( location )
    wxString location

wxString
wxFileSystemHandler::GetProtocol( location )
    wxString location

wxString
wxFileSystemHandler::GetRightLocation( location )
    wxString location

#endif

MODULE=Wx PACKAGE=Wx::InternetFSHandler

#if wxUSE_FS_INET

wxInternetFSHandler*
wxInternetFSHandler::new()

#endif

MODULE=Wx PACKAGE=Wx::ZipFSHandler

wxZipFSHandler*
wxZipFSHandler::new()

MODULE=Wx PACKAGE=Wx::ArchiveFSHandler

#if WXPERL_W_VERSION_GE( 2, 7, 2 )

wxArchiveFSHandler*
wxArchiveFSHandler::new()

#endif

MODULE=Wx PACKAGE=Wx::MemoryFSHandler

wxMemoryFSHandler*
wxMemoryFSHandler::new()

void
AddImageFile( name, image, type )
    wxString name
    wxImage* image
    wxBitmapType type
  CODE:
    wxMemoryFSHandler::AddFile( name, *image, type );

void
AddBitmapFile( name, bitmap, type )
    wxString name
    wxBitmap* bitmap
    wxBitmapType type
  CODE:
    wxMemoryFSHandler::AddFile( name, *bitmap, type );

void
AddTextFile( name, string )
    wxString name
    wxString string
  CODE:
    wxMemoryFSHandler::AddFile( name, string );

void
AddBinaryFile( name, scalar )
    wxString name
    SV* scalar
  PREINIT:
    STRLEN len;
    char* data = SvPV( scalar, len );
  CODE:
    wxMemoryFSHandler::AddFile( name, data, len );

#if WXPERL_W_VERSION_GE( 2, 8, 5 )

void
AddTextFileWithMimeType( name, string, mimetype )
    wxString name
    wxString string
    wxString mimetype
  CODE:
    wxMemoryFSHandler::AddFileWithMimeType( name, string, mimetype );

void
AddBinaryFileWithMimeType( name, scalar, mimetype )
    wxString name
    SV* scalar
    wxString mimetype
  PREINIT:
    STRLEN len;
    char* data = SvPV( scalar, len );
  CODE:
    wxMemoryFSHandler::AddFileWithMimeType( name, data, len, mimetype );

#endif

void
RemoveFile( name )
    wxString name
  CODE:
    wxMemoryFSHandler::RemoveFile( name );

MODULE=Wx PACKAGE=Wx::PlFileSystemHandler

#include "cpp/fshandler.h"

wxPlFileSystemHandler*
wxPlFileSystemhandler::new()
  CODE:
    RETVAL = new wxPlFileSystemHandler( CLASS );
  OUTPUT:
    RETVAL