Thanks in advance.
I am researching if it is possible for unix (solaris) to print directly printers with IP addresses. Without adding all the ip addresses to the hosts file? There are more than a hundred printers and managing them in a hosts file would be tedius, prone to error, and time... (4 Replies)
im just trying to have some fun and kill some time writing a c++ program that has a person type in a car make and model then gives them a year and a price. or something like that. i always have problems getting it goin but once the ball is rolling im usually pretty good. anyone wanna help me out? ... (1 Reply)
Hi, i have a question about C++. Is it possible to declare a class with a member ot the same class? For example, a linked list or i want to convert this C code to C++ class (Elemento)
typedef struct elemento
{
char name;
char value;
List<struct elemento> ltElementos;
... (7 Replies)
How can I print the memory address of a pointer using printf (or any other STDOUT functions?). I see in Linux its %p but not in unix, help?
thanks (5 Replies)
Hi all!
I am trying to register a device in an existing device class, but I am
having trouble getting the pointer to an existing class.
I can create a class in a module, get the pointer to it and then use
it to register the device with:
*cl = class_create(THIS_MODULE, className);... (0 Replies)
I have the two class definition as follows.
class A { public: int a; };
class B : virtual public A{ };
The size of class A is shown as 4, and size of class B is shown as 16. Why is this effect ?. (2 Replies)
I need help with a tcl code. I have a variable "myIP" which reads IP address from socket. How do I use regex to find out if it belongs to a group for e.g., 50.65.75.240/28 or 50.65.75.128/25 etc. (2 Replies)
I have a class
and want to print values in MOD using
L = new Layer* ;
How can I print the values in MOD using this object L???
class Layer
{
public :
Model* MODP;
Model* MODS; (1 Reply)
Hello All,
I am a learner in C++. I was testing my inheritance knowledge with following piece of code.
#include <iostream>
using namespace std;
class base
{
public :
void display()
{
cout << "In base display()" << endl;
}
void display(int k)
{... (2 Replies)
Discussion started by: anand.shah
2 Replies
LEARN ABOUT PHP
is_a
IS_A(3) 1 IS_A(3)is_a - Checks if the object is of this class or has this class as one of its parentsSYNOPSIS
bool is_a FALSE (object $object, string $class_name, [bool $allow_string])
DESCRIPTION
Checks if the given $object is of this class or has this class as one of its parents.
PARAMETERS
o $object
- The tested object
o $class_name
- The class name
o $allow_string
- If this parameter set to FALSE, string class name as $object is not allowed. This also prevents from calling autoloader if the
class doesn't exist.
RETURN VALUES
Returns TRUE if the object is of this class or has this class as one of its parents, FALSE otherwise.
CHANGELOG
+--------+---------------------------------------------------+
|Version | |
| | |
| | Description |
| | |
+--------+---------------------------------------------------+
| 5.3.9 | |
| | |
| | Added $allow_string parameter |
| | |
| 5.3.0 | |
| | |
| | This function is no longer deprecated, and will |
| | therefore no longer throw E_STRICT warnings. |
| | |
| 5.0.0 | |
| | |
| | This function became deprecated in favour of the |
| | instanceof operator. Calling this function will |
| | result in an E_STRICT warning. |
| | |
+--------+---------------------------------------------------+
EXAMPLES
Example #1
is_a(3) example
<?php
// define a class
class WidgetFactory
{
var $oink = 'moo';
}
// create a new object
$WF = new WidgetFactory();
if (is_a($WF, 'WidgetFactory')) {
echo "yes, $WF is still a WidgetFactory
";
}
?>
Example #2
Using the instanceof operator in PHP 5
<?php
if ($WF instanceof WidgetFactory) {
echo 'Yes, $WF is a WidgetFactory';
}
?>
SEE ALSO get_class(3), get_parent_class(3), is_subclass_of(3).
PHP Documentation Group IS_A(3)