Questions tagged [members]

175 questions
2
votes
1 answer

How to reference a structure member through variable?

I am trying to cycle through the members of a structure using a For loop. struct Pixel{ unsigned char = Red, Green, Blue; }; in Main, I would like to have const char *color[]= {"Red", "Green", "Blue}; and be able to reference the members of…
elpablo
  • 51
  • 1
  • 4
  • 11
2
votes
1 answer

Use query.v1 to filter on member groups

How can I use query.v1 (in YAML) to filter on Members that belong to a particular member group?
vplechuc
  • 158
  • 1
  • 1
  • 4
2
votes
1 answer

How to add Group in Openfire using XMPP programmatically

I want to create GROUP in openfire using xmpp programmatically see the image.... there are two groups in image I wish to add new groups in openfire using xmpp stanzas. If success then I wish to add members in particular groups. I know how to create…
Mohsin Patel
  • 226
  • 1
  • 15
2
votes
1 answer

List Active Directory group hierarchy

I'm looking to build a script which would show Active Directory group hierarchy. Unfortunately simple Get-ADGroupMember $group -Recursive lists only members, not groups. Example: Group1 is main group - it has 3 subgroups named GroupA,B,C. So…
2
votes
1 answer

SQL Server User roles that have roles inside them

I know the title might be a bit confusing, but that was the best I could came up with. So here is my question: I have a DB that has many roles, some of these roles have as a role member other roles, so when a users is added into a role it will…
CiucaS
  • 2,010
  • 5
  • 36
  • 63
2
votes
2 answers

C++ static bool variable

I can't understand something that causes LNK2005 errors that I've encountered. Assume that you have a class A: File A.h: #ifndef A_H #define A_H class A{ public: static foo(void); private: static bool m_someVar; …
JohnJohn
  • 325
  • 1
  • 6
  • 17
2
votes
4 answers

Why in Thread class " public static final int MAX_PRIORITY" declared as int?

I have a doubt about why java developers has declared as public static final int MAX_PRIORITY public static final int MIN_PRIORITY public static final int NORMAL_PRIORITY instead of declaring public static final byte MAX_PRIORITY. Because for these…
Jay
  • 27
  • 4
2
votes
1 answer

PHP - access parent class members from nested classes

Let' suppose I have my code organized in classes and each class has its own file: main.php, having class Main config.php having class Config security.php having class Security database.php having class Database Now, Main's constructor will…
ali
  • 10,927
  • 20
  • 89
  • 138
2
votes
5 answers

C++ static members in class

Is it possible to access to access and use static members within a class without first creating a instance of that class? Ie treat the the class as some sort of dumping ground for globals James
Dark Templer
  • 277
  • 5
  • 10
2
votes
4 answers

Class A needs class B that needs class A and all its members

I'm definitely in a desperate case... Using C++, I have defined those two classes: // Console.hpp #ifndef CLASS_Console #define CLASS_Console #include #include "Window.hpp" class Console { public: Window *Win; Console(Windows…
ElementW
  • 804
  • 8
  • 23
2
votes
3 answers

Private members in Javascript. Can they be non-static?

I have this code here: var Person = (function() { var name; var PersonConstructor = function(n) { name = n; }; PersonConstructor.prototype.getName = function() { return name; }; return…
user266425
1
vote
2 answers

Getting the names of members of an array in javascript dynamically at runtime

First of all I am not sure whether it is actually possible in javascript, but still I felt it's worth asking. Ok, so what I am trying to do is get the names of the members of an array (or object as you might say) dynamically at runtime. Let me…
Anupam
  • 1,821
  • 3
  • 23
  • 41
1
vote
3 answers

java static member memory leak

I am reviewing one java code base for finding some memory leaks. During the review I have find the following scenarios. A class Class1 has in the codebase. Class1 have some instance variables and some static members. Some other classes creating…
user867662
  • 1,091
  • 4
  • 20
  • 45
1
vote
2 answers

Accessing public members of base class fails

might be a bit of a coward-ish question: I've got two classes, and declared all variables public. Why can't I access the variables from derived class?? g++ tells me: vec3d.h:76:3: error: ‘val’ was not declared in this scope template
0815ZED
  • 123
  • 1
  • 12
1
vote
5 answers

Should lookup tables be static

I have a Message class which parses text messages using lookup tables. I receive a lot of messages and create and destroy a lot of objects so I thought I declare those lookup tables as static members to prevent initializing the same tables with the…
jackhab
  • 17,128
  • 37
  • 99
  • 136