Helpviewer/FlashCookieManager/FlashCookie.py

Sun, 09 Aug 2015 17:18:21 +0200

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Sun, 09 Aug 2015 17:18:21 +0200
changeset 4359
ac1dda9f3f19
child 4370
54dbb658f9e6
permissions
-rw-r--r--

Started adding code for a Flash cookie manager.

# -*- coding: utf-8 -*-

# Copyright (c) 2015 Detlev Offenbach <detlev@die-offenbachs.de>
#

"""
Module implementing the Flash cookie class.
"""

from __future__ import unicode_literals

from PyQt5.QtCore import QDateTime


class FlashCookie(object):
    """
    Class implementing the Flash cookie.
    """
    def __init(self):
        """
        Constructor
        """
        self.name = ""
        self.origin = ""
        self.size = 0
        self.path = ""
        self.contents = ""
        self.lastModified = QDateTime()
    
    def __eq__(self, other):
        """
        Special method to compare to another Flash cookie.
        
        @param other reference to the other Flash cookie
        @type FlashCookie
        @return flag indicating equality of the two cookies
        @rtype bool
        """
        return (self.name == other.name and
                self.path == other.path)

eric ide

mercurial