|
by: Lenard Lindstrom |
last post by:
I was wondering if anyone has suggested having Python determine
a method's kind from its first parameter. 'self' is a de facto
reserved word; 'cls' is a good indicator of a class method
( __new__ is a special case ). The closest to this I could find
was the 2002-12-04 posting 'metaclasses and static methods'
by Michele Simionato. The...
|
by: Edward Diener |
last post by:
This simple code example gives me the message, "TypeError: 'staticmethod'
object is not callable".
class X(object):
def Y(x):
print x
Y = staticmethod(Y)
ad = { 1 : Y }
def Z(self):
self.ad(3)
|
by: Ivan Voras |
last post by:
Can this be done: (this example doesn't work)
----
class A:
def a_lengthy_method(self, params):
# do some work depending only on data in self and params
class B:
|
by: Fuzzyman |
last post by:
Hello,
To create a classic (old style) class, I write :
class foo:
pass
To do the equivalent as a new style class, I write :
class foo(object):
|
by: simonwittber |
last post by:
>>> gen = iterator()
>>> gen.next
<method-wrapper object at 0x009D1B70>
>>> gen.next
<method-wrapper object at 0x009D1BB0>
>>> gen.next
<method-wrapper object at 0x009D1B70>
>>> gen.next
<method-wrapper object at 0x009D1BB0>
>>> gen.next is gen.next
|
|
by: James Fortune |
last post by:
I have a lot of respect for David Fenton and Allen Browne, but I don't
understand why people who know how to write code to completely replace
a front end do not write something that will automate the code that
implements managing unbound controls on forms given the superior
performance of unbound controls in a client/server environment. I can...
|
by: MLH |
last post by:
I have a form, bound to a query. Its RecordSource property
is a query named frmEnterLienAmounts. The form has a few
bound controls and some unbound controls. The unbound
controls are calculated fields whose DefaultValue property
is set to something like
DLookUp("","tblVehicleJobs","=Forms!frmEnterLienAmounts!VehicleJobID")
The form...
|
by: Astley Le Jasper |
last post by:
Sorry for the numpty question ...
How do you find the reference name of an object?
So if i have this
bob = modulename.objectname()
how do i find that the name is 'bob'
|
by: IceMan85 |
last post by:
Hi to all, I have spent the whole morning trying, with no success to pickle an object that I have created.
The error that I get is : Can't pickle 'SRE_Match' object: <_sre.SRE_Match object at 0x2a969c0ad0>
the complete stack is the following :
Traceback (most recent call last):
File "manager.py", line 305, in ?
commandLineExec...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it. ...
|
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in...
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
|
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
|