Ignore:
Timestamp:
09/21/04 15:32:23 (17 years ago)
Author:
Daniel Lawson <dlawson@…>
Branches:
4.0.1-hotfixes, cachetimestamps, develop, dpdk-ndag, etsilive, getfragoff, help, libtrace4, master, ndag_format, pfring, rc-4.0.1, rc-4.0.2, rc-4.0.3, rc-4.0.4, ringdecrementfix, ringperformance, ringtimestampfixes
Children:
d5e7d91
Parents:
6f34090
Message:

finished rest of libtrace api.
fixed memleak with calling strdup() on inet_ntoa on ip_src/ip_dst

File:
1 edited

Legend:

Unmodified
Added
Removed
  • swig/python/libtrace.py

    r6f34090 rf2794ea  
    290290    def trace_get_udp(*args): return _libtrace.Packet_trace_get_udp(*args)
    291291    def trace_get_icmp(*args): return _libtrace.Packet_trace_get_icmp(*args)
     292    def trace_get_link(*args): return _libtrace.Packet_trace_get_link(*args)
    292293    def trace_get_seconds(*args): return _libtrace.Packet_trace_get_seconds(*args)
     294    def trace_get_erf_timestamp(*args): return _libtrace.Packet_trace_get_erf_timestamp(*args)
     295    def trace_get_timeval(*args): return _libtrace.Packet_trace_get_timeval(*args)
     296    def trace_get_capture_length(*args): return _libtrace.Packet_trace_get_capture_length(*args)
     297    def trace_get_wire_lenth(*args): return _libtrace.Packet_trace_get_wire_lenth(*args)
     298    def trace_get_link_type(*args): return _libtrace.Packet_trace_get_link_type(*args)
     299    def trace_get_direction(*args): return _libtrace.Packet_trace_get_direction(*args)
     300    def trace_bpf_filter(*args): return _libtrace.Packet_trace_bpf_filter(*args)
    293301
    294302class PacketPtr(Packet):
     
    298306        _swig_setattr(self, Packet,self.__class__,Packet)
    299307_libtrace.Packet_swigregister(PacketPtr)
     308
     309class Filter(_object):
     310    __swig_setmethods__ = {}
     311    __setattr__ = lambda self, name, value: _swig_setattr(self, Filter, name, value)
     312    __swig_getmethods__ = {}
     313    __getattr__ = lambda self, name: _swig_getattr(self, Filter, name)
     314    def __repr__(self):
     315        return "<C libtrace_filter_t instance at %s>" % (self.this,)
     316    def __init__(self, *args):
     317        _swig_setattr(self, Filter, 'this', _libtrace.new_Filter(*args))
     318        _swig_setattr(self, Filter, 'thisown', 1)
     319    def trace_bpf_filter(*args): return _libtrace.Filter_trace_bpf_filter(*args)
     320
     321class FilterPtr(Filter):
     322    def __init__(self, this):
     323        _swig_setattr(self, Filter, 'this', this)
     324        if not hasattr(self,"thisown"): _swig_setattr(self, Filter, 'thisown', 0)
     325        _swig_setattr(self, Filter,self.__class__,Filter)
     326_libtrace.Filter_swigregister(FilterPtr)
    300327
    301328class Trace(_object):
Note: See TracChangeset for help on using the changeset viewer.