Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
eb693ce2
Commit
eb693ce2
authored
Oct 26, 2001
by
Fred Drake
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added docs for PyObject_CallFunctionObArgs() and PyObject_CallMethodObArgs().
Minor cleanups & markup consistency fixes.
parent
092ecb09
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
32 additions
and
11 deletions
+32
-11
Doc/api/abstract.tex
Doc/api/abstract.tex
+32
-11
No files found.
Doc/api/abstract.tex
View file @
eb693ce2
...
...
@@ -183,31 +183,52 @@ determination.
\bifuncindex
{
apply
}
\end{cfuncdesc}
\begin{cfuncdesc}
{
PyObject*
}{
PyObject
_
CallFunction
}{
PyObject *callable
_
object
,
char *format,
...
}
Call a callable Python object
\var
{
callable
_
object
}
, with a variable
\begin{cfuncdesc}
{
PyObject*
}{
PyObject
_
CallFunction
}{
PyObject *callable,
char *format,
\moreargs
}
Call a callable Python object
\var
{
callable
}
, with a variable
number of C arguments. The C arguments are described using a
\cfunction
{
Py
_
BuildValue()
}
style format string. The format may be
\NULL
, indicating that no arguments are provided. Returns the
result of the call on success, or
\NULL
{}
on failure. This is the
equivalent of the Python expression
\samp
{
apply(
\var
{
callable
_
object
}
\var
{
args
}
)
}
or
\samp
{
\var
{
callable
_
object
}
(*
\var
{
args
}
)
}
.
equivalent of the Python expression
\samp
{
apply(
\var
{
callable
}
,
\var
{
args
}
)
}
or
\samp
{
\var
{
callable
}
(*
\var
{
args
}
)
}
.
\bifuncindex
{
apply
}
\end{cfuncdesc}
\begin{cfuncdesc}
{
PyObject*
}{
PyObject
_
CallMethod
}{
PyObject *o,
char *method, char *format, ...
}
char *method, char *format,
\moreargs
}
Call the method named
\var
{
m
}
of object
\var
{
o
}
with a variable
number of C arguments. The C arguments are described by a
\cfunction
{
Py
_
BuildValue()
}
format string. The format may be
\NULL
,
indicating that no arguments are provided. Returns the result of the
call on success, or
\NULL
{}
on failure. This is the equivalent of
the Python expression
\samp
{
\var
{
o
}
.
\var
{
method
}
(
\var
{
args
}
)
}
. Note
that special method names, such as
\method
{__
add
__
()
}
,
\method
{__
getitem
__
()
}
, and so on are not supported. The specific
abstract-object routines for these must be used.
the Python expression
\samp
{
\var
{
o
}
.
\var
{
method
}
(
\var
{
args
}
)
}
.
\end{cfuncdesc}
\begin{cfuncdesc}
{
PyObject*
}{
PyObject
_
CallFunctionObArgs
}{
PyObject *callable,
\moreargs
,
\code
{
NULL
}}
Call a callable Python object
\var
{
callable
}
, with a variable
number of
\ctype
{
PyObject*
}
arguments. The arguments are provided
as a variable number of parameters followed by
\NULL
.
Returns the result of the call on success, or
\NULL
{}
on failure.
\versionadded
{
2.2
}
\end{cfuncdesc}
\begin{cfuncdesc}
{
PyObject*
}{
PyObject
_
CallMethodObArgs
}{
PyObject *o,
PyObject *name,
\moreargs
,
\code
{
NULL
}}
Calls a method of the object
\var
{
o
}
, where the name of the method
is given as a Python string object in
\var
{
name
}
. It is called with
a variable number of
\ctype
{
PyObject*
}
arguments. The arguments are
provided as a variable number of parameters followed by
\NULL
.
Returns the result of the call on success, or
\NULL
{}
on failure.
\versionadded
{
2.2
}
\end{cfuncdesc}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment