Questions tagged [subobject]

If struct B has variable object pointing to struct A (In higher languages other than C this will be seen as "B extends A"), then an instance of B is said to contain an A subobject. The term generally crops up in discussions of multiple inheritance and virtual inheritance:

If struct B has variable object pointing to struct A (In higher languages other than C this will be seen as "B extends A"), then an instance of B is said to contain an A subobject. The term generally crops up in discussions of multiple inheritance and virtual inheritance:

26 questions
15
votes
3 answers

What is dynamic type of object

What i think is that dynamic type means dynamically allocated object using new. In the following case, do you say p points to dynamic type or static type of object? In standard, it doesn't say about dynamic type being dynamic object. 1.3.3 - The…
user103214
  • 3,478
  • 6
  • 26
  • 37
6
votes
1 answer

java design: repetitive methods of sub-objects

When I was working on a project of mine and had to use a lot of nested objects, I became very unsure of my design of structure in Java when I wanted to set an instance variable of a deeply nested object from the upper object. It feels like I miss a…
lokipoki
  • 63
  • 4
3
votes
1 answer

access anonymous Subobject C++ (cout)

class Parent { ... friend ostream& operator<<(ostream&, const Parent&); }; class Child : public Parent { ... friend ostream& operator<<(ostream&, const Child&); }; ostream& operator<< (ostream& os, const Parent& p) { os << ...…
SimonH
  • 1,385
  • 15
  • 35
2
votes
1 answer

Filtering sub-objects in PowerShell using Select-Object

Many of you are familiar with the calculated properties possible in PowerShell, to raise a property needed from a sub-object level. I.e. if I'd like to know the owner of a process (i.e. notepad) as a non-admim I could fetch the process with WMI and…
Dennis
  • 871
  • 9
  • 29
2
votes
1 answer

Storage duration of a replaced subobject

Regarding the code below int main() { struct S { int i; } s { 42 }; new (&s.i) int { 43 }; } [basic.stc]/2 says The dynamic storage duration is associated with objects created by a new-expression. There is similar question where it was…
2
votes
1 answer

C99/C11 Self-referencing Sub-object Initialization possible?

I should first say I don't think what I want to do is possible (having read what I think are the relevant parts of the ISO C99) but here is rough idea of what I have now: struct foo { int x; int *y; }; #define FOO_INITIALIZER(name) \ { …
2
votes
1 answer

Editable parameter in DataTable of PrimeNg in Angular2 doesn't work with sub object

I have a problem with the DataTable of primeng with Angular 2 when I use sub object. When I put the editable parameter at true. The value disappear. This is my object : export class Car { year: number; type: {`enter code here` …
1
vote
2 answers

Dynamic type of an expression dealing with a base class subobject

I am asking the question again because the only other question that is like this is approaching 10 years old, and contains incorrect information about expressions involving base class subobjects: [defns.dynamic.type] defines the dynamic type of a…
Krystian S
  • 1,586
  • 7
  • 23
1
vote
2 answers

mongodb import csv to json with subobjects

I have file.csv with similar to this structure loremipsum; machine, metal As i understand, succeful import will looks like { text: "loremipsum", << string tags: ["machine","metal"] << object with two fields } The best result i get { …
Lopol2010
  • 79
  • 2
  • 13
1
vote
1 answer

Exceptions on template non-type arguments

The C++17 standard says: A template-argument for a non-type template-parameter shall be a converted constant expression... while the value of the constant expression shall not shall not be the address of a string literal a subobject some…
Vahagn
  • 4,670
  • 9
  • 43
  • 72
1
vote
3 answers

Some puzzles about the subobject in the C++ Standard

The C++ Standard define the concept "dynamic type" of a glvalue as follows: dynamic type type of the most derived object (1.8) to which the glvalue denoted by a glvalue expression refers [Example: if a pointer (8.3.1) p whose static type…
xskxzr
  • 12,442
  • 12
  • 37
  • 77
1
vote
1 answer

multiline text in semantic mediawiki subobjects

Is it possible to assign a multiline text value in a semantic mediawiki subobject ? I'd like to do something like {{#subobject: |multiline=line1 a list on line 2: *list item 1 on line3 *list item 2 on line4 |foo=bar }} setting multiline texts for…
c.holtermann
  • 113
  • 1
  • 9
0
votes
2 answers

How can I access multiply nested sub objects in javascript?

I have a larger code which handles and sorts data. In it I want to work with objects to keep it easier and better structured. I have multiple categories and all of them have different nested subobjects, which I have trouble accessing…
Tomtetot
  • 5
  • 4
0
votes
1 answer

Unreal Engine : Why use subobject when creating Actor?

RootComponent = CreateDefaultSubobject(TEXT("RootComponent")); I want to know the reason why we make subobject here. I used a translator because I couldn't speak English well. Thank You.
조태양
  • 1
  • 1
0
votes
1 answer

Change nested object values in a powershell object

I have the following object, and I would like to change a nested value in the object without changing all the other nested objects. The object I would like to change is in a variable. $object.Tophashtable.MidHashtable1.array1[0].linenumber = 1 …
Roel
  • 1
  • 2
1
2