Questions tagged [classname]

Classname may refer to classes in scripting languages and markup languages. Typically, a class denotes a certain part of the application which can be manipulated.

620 questions
4
votes
2 answers

C++ multiple callback member functions from different classes without std and boost

I'm new to C++ and I don't want to use any libraries because I want to really understand whats going on internally. Additionally I try to keep my library-use as low as possible (to improve performance and) to make it as platform-independent as…
clotodex
  • 193
  • 2
  • 10
4
votes
1 answer

Ambiguous Class Namespace Issue

I... feel really silly asking this, but I'm not sure how to resolve the problem. This is a little snippit of my code (Objective-C++): #include "eq/eq.h" namespace eqOther { class Window : public eq::Window //<-- Error occurs here { …
Stephen Furlani
  • 6,794
  • 4
  • 31
  • 60
4
votes
6 answers

PHP: Get class name of passed var?

I have a function that gets a class passed to it as a parameter. I would like to get the class name of the passed class as a string. I tried putting this method in the passed class: function getClassName() { return __CLASS__; } but…
JD Isaacks
  • 56,088
  • 93
  • 276
  • 422
4
votes
2 answers

Magnific Popup - add additional class to iframe

First of all , thanks for the great "Magnific Popup" plugin! I have a beginner' question. I'm using an iframe type. I'm showing several types of sites in the iframe , most of them are responsive and takes all the width of iframe. But in some cases…
Ivan Chernykh
  • 41,617
  • 13
  • 134
  • 146
4
votes
4 answers

How to convert the current class name of asp.net usercontrols to string on c#?

So I have tried GetType() but for some reason, It does include the namespace... Does C# not have a property for a class specifying its name? For example: public class Parent : System.Web.UI.UserControl { public someFunction(){ Child…
Jronny
  • 2,164
  • 4
  • 30
  • 41
4
votes
1 answer

How to get name of class if I know only a bound method in python?

In pyton code I've got a bound method of some object. Knowing only this bound method I would like to know what is the class of that object. Is it possible? Here is sample code: >>> class x: ... def method(self): ... pass ... >>>…
running.t
  • 5,329
  • 3
  • 32
  • 50
4
votes
3 answers

Is it possible to get the class name from a static method?

Possible Duplicate: Getting the class name from a static method in Java When you are inside of a static method, is there a way to get the class name (a string containing the name) without typing the class name itself? For example, typing…
javanewbie
3
votes
1 answer

Which is the best way to name namespace and class

1) A Namespace "Domain\Customer" with a Class "Model" namespace MyDomain\Customer; class Model { } class Repository { } namespace MyDomain\City; class Model { } class Repository { } 2) A Namespace "MyDomain" with a class "CustomerModel" ?…
Yanik Lupien
  • 120
  • 1
  • 5
3
votes
1 answer

Why this __METHOD__NAME__ requires a memory copy?

The idea is from https://stackoverflow.com/a/15775519/1277762 I added a '\0' at end of string_view so we can use data() for printf, spdlog, et al. I use this macro to print function name with class name. However, I find that the compiler is not…
Kang Jianbin
  • 73
  • 1
  • 5
3
votes
2 answers

Error using Selenium (Python): Unable to find class in HTML source code

I'm learning how to use Selenium. I was doing some testing, but got this error: selenium.common.exceptions.NoSuchElementException: Message: Unable to locate element: .layout layout-base My Code: from selenium import webdriver from…
Yuu10
  • 53
  • 3
3
votes
3 answers

Choosing informative class names

I'm having a hard time coming up with informative and useful class names. One class I am have this problem with makes requests to websites/servers. I thought it would only be fitting to name this class ServerRequest which is within the package of…
Paramount
  • 1,109
  • 14
  • 27
3
votes
2 answers

Replace part of class name via jquery based on active class

I have a ul menu with three li classes: .1-is-on, .2-is-off, .3-is-off. Whichever li with the class .active, should show the "on" part of the class name. By default on page load, 1-is-on has .active assigned to it. When I click on 2-is-off .active…
Wonka
  • 8,244
  • 21
  • 73
  • 121
3
votes
2 answers

In Java, can imported class have same simple-name as importing class? Are there any restrictions?

If I have a class names ClassX in package a.b.c, and I want to import the class a.b.x.ClassX Is there some restriction in Java preventing me from doing so? As far as usage goes, I can always use the fully qualified name of the imported class,…
Shailesh Tainwala
  • 6,299
  • 12
  • 58
  • 69
3
votes
1 answer

Get elements by class name with Elm.Browser.Dom

I know I can get an Element by id with Browser.Dom.getElement. But how can I get a List Element by classname?
Amparo
  • 784
  • 1
  • 4
  • 21
3
votes
2 answers

php: new object from "ClassName" and array of args

I have string containing classname and an array of args. $classname($args) works, but in this case I have only 1 argument in constructor Anyone know, how to do this with args expanded?
guai
  • 780
  • 1
  • 12
  • 29