Questions tagged [hierarchy]
For issues relating to creating, maintaining, or displaying a hierarchy of data or resources, etc.
                                	
	hierarchy
    
                            
                        
                    
            2,858
            questions
        
        
            671
            votes
        
        
            38
            answers
        
        
            438k
            views
        
    Attempt to present UIViewController on UIViewController whose view is not in the window hierarchy
                Just started using Xcode 4.5 and I got this error in the console:
  Warning: Attempt to present < finishViewController: 0x1e56e0a0 > on < ViewController: 0x1ec3e000> whose view is not in the ...
            
        
       
    
            432
            votes
        
        
            3
            answers
        
        
            290k
            views
        
    How to view hierarchical package structure in Eclipse package explorer
                OK here's what I would like: in the Eclipse package explorer, I see the following: (dot represents a clickable arrow that I can use to expand the folder)
PROJECT
 Source Folder 
         Package
 ...
            
        
       
    
            220
            votes
        
        
            15
            answers
        
        
            435k
            views
        
    Getting activity from context in android
                This one has me stumped.
I need to call an activity method from within a custom layout class. The problem with this is that I don't know how to access the activity from within the layout.
...
            
        
       
    
            115
            votes
        
        
            2
            answers
        
        
            113k
            views
        
    JPA: How to have one-to-many relation of the same Entity type
                There's an Entity Class "A". Class A might have children of the same type "A". Also "A" should hold it's parent if it is a child.  
Is this possible? If so how should I map the relations in the ...
            
        
       
    
            101
            votes
        
        
            5
            answers
        
        
            40k
            views
        
    Moving a git repository up one hierarchy level
                Git beginner question:
I have a small private webproject which is versioned locally with msysgit. There is no exterior repository, as it's only for me, so i can bascially do whatever I want.
I've ...
            
        
       
    
            91
            votes
        
        
            17
            answers
        
        
            113k
            views
        
    Warning: Attempt to present * on * whose view is not in the window hierarchy - swift
                I'm trying to present a ViewController if there is any saved data in the data model. But I get the following error: 
  Warning: Attempt to present * on *whose view is not in the window hierarchy" 
...
            
        
       
    
            76
            votes
        
        
            4
            answers
        
        
            32k
            views
        
    How should I deal with object hierarchies in a RESTful API?
                I am currently designing the API for an existing PHP application, and to this end am investigating REST as a sensible architectural approach.
I believe I have a reasonable grasp of the key concepts, ...
            
        
       
    
            69
            votes
        
        
            3
            answers
        
        
            99k
            views
        
    SQL Server OPENJSON read nested json
                I have some json that I would like to parse in SQL Server 2016.  There is a hierarchy structure of Projects->Structures->Properties.  I would like to write a query that parses the whole hierarchy but ...
            
        
       
    
            50
            votes
        
        
            3
            answers
        
        
            65k
            views
        
    SQL Server: How to get all child records given a parent id in a self referencing table
                Hi I have a table which references itself and I need to be able to select the parent and all it's child records from a given parent Id.
My table is as follows:
ID   | ParentID | Name         
-------...
            
        
       
    
            49
            votes
        
        
            2
            answers
        
        
            63k
            views
        
    How can I list all classes loaded in a specific class loader
                For debug reasons, and curiosity, I wish to list all classes loaded to a specific class loader.
Seeing as most methods of a class loader are protected, what is the best way to accomplish what I want?
...
            
        
       
    
            48
            votes
        
        
            9
            answers
        
        
            28k
            views
        
    SQL - How to store and navigate hierarchies?
                What are the ways that you use to model and retrieve hierarchical info in a database?
            
        
       
    
            46
            votes
        
        
            1
            answer
        
        
            40k
            views
        
    How to design a hierarchical role based access control system
                Basic deal is, we have a custom built "kickstart" for our projects. For this we are looking at redoing the user control. I know there are a lot of questions out there about general rbac, but I cannot ...
            
        
       
    
            40
            votes
        
        
            2
            answers
        
        
            30k
            views
        
    How to mix inheritance strategies with JPA annotations and Hibernate?
                According to the Hibernate Reference Documentation it should be possible to mix different inheritance mapping strategies when using Hibernate's XML-Metadata:
http://docs.jboss.org/hibernate/stable/...
            
        
       
    
            36
            votes
        
        
            3
            answers
        
        
            15k
            views
        
    Object Browser inside the Android Studio
                I need to navigate through the whole android api objects inside the Android Studio to find out classes that extend an individual class and also list of class and interfaces that is extended by an ...
            
        
       
    
            36
            votes
        
        
            14
            answers
        
        
            99k
            views
        
    Eclipse The hierarchy of the type ... is inconsistent with @Configurable annotation
                I am developing a Spring/Vaadin/Hibernate application.
Everything works but I still have the following error markers in Eclipse STS 2.8.1:
The hierarchy of the type BankView is inconsistent
The ...
            
        
       
    
            35
            votes
        
        
            5
            answers
        
        
            28k
            views
        
    How should a REST URL schema look like for a tree hierarchy?
                Let's assume that I have stores, shelves in a store, and products on a shelf. So in order to get a list of products on a shelf in a store, I'd use the following request:
GET http://server/stores/123/...
            
        
       
    
            34
            votes
        
        
            3
            answers
        
        
            15k
            views
        
    Maven naming conventions for hierarchical multiple module projects
                I've got a question on Maven naming conventions (groupId, artifactId and directory names) in a multiple module project with a hierarchical directory structrure.
Research
Before asking, I went ...
            
        
       
    
            30
            votes
        
        
            3
            answers
        
        
            20k
            views
        
    Setting property value on child instance to a fixed value with Autofixture
                Is it possible to assign a fixed value to a property on a child instance when building a parent with Autofixture? It will add default values to all the properties on the child instance like a charm, ...
            
        
       
    
            29
            votes
        
        
            3
            answers
        
        
            41k
            views
        
    Get all parents for a child
                I want to retrieve the parentid of an id, if that parentid has a parent again retrieve it, and so on.
Kind of hierarchy table.
id----parentid
1-----1
5-----1
47894--5
47897--47894
am new to sql ...
            
        
       
    
            28
            votes
        
        
            2
            answers
        
        
            35k
            views
        
    How to use enum with grouping and subgrouping hierarchy/nesting
                I have one enum 'class' called Example as follows:
enum Example {
//enums belonging to group A:
   enumA1,
   enumA2,
   enumA3,
//enums belonging to group B:
   enumB1,
   enumB2,
   enumB3,
//enums ...
            
        
       
    
            28
            votes
        
        
            3
            answers
        
        
            32k
            views
        
    How can I split my javascript code into separate files?
                I'm reading the Javascript Guide from Mozilla
And when they contrasted JS to Java , It got me thinking, Java code is easily split up with each class in his own file. after futher search , I understand ...
            
        
       
    
            27
            votes
        
        
            2
            answers
        
        
            29k
            views
        
    Construct hierarchy tree from flat list with parent field? [duplicate]
                I have a list of "page" objects with a parent field. This parent field references another object in the list. I would like to create a tree hierarchy from this list based on this field.
Here is what ...
            
        
       
    
            23
            votes
        
        
            1
            answer
        
        
            7k
            views
        
    Implementing NSCopying in Subclass of Subclass
                I have a small class hierarchy that I'm having trouble implementing copyWithZone: for. I've read the NSCopying documentation, and I can't find the correct answer.
Take two classes: Shape and Square. ...
            
        
       
    
            23
            votes
        
        
            7
            answers
        
        
            20k
            views
        
    C# algorithm for generating hierarchy
                I've got a text file that looks like this:
{ Id = 1, ParentId = 0, Position = 0, Title = "root" }
{ Id = 2, ParentId = 1, Position = 0, Title = "child 1" }
{ Id = 3, ParentId = 1, Position = 1, Title ...
            
        
       
    
            23
            votes
        
        
            6
            answers
        
        
            23k
            views
        
    Building hierarchy objects from flat list of parent/child
                I have a list of items in a hierarchy, and I'm attempting to parse this list out into an actual hierarchy of objects. I'm using modified pre-order tree traversal to store/iterate through this list, ...
            
        
       
    
            23
            votes
        
        
            2
            answers
        
        
            17k
            views
        
    Counting number of children in hierarchical SQL data
                for a simple data structure such as so:
ID    parentID    Text        Price
1                 Root
2     1           Flowers
3     1           Electro
4     2           Rose        10
5     2         ...
            
        
       
    
            23
            votes
        
        
            2
            answers
        
        
            10k
            views
        
    Smooth transitioning between tree, cluster, radial tree, and radial cluster layouts
                For a project, I need to interactively change hierarchical data layout of a visualization - without any change of the underlying data whatsoever. The layouts capable of switching between themselves ...
            
        
       
    
            22
            votes
        
        
            5
            answers
        
        
            18k
            views
        
    Getting hierarchy data from self-referencing tables
                Let's say you have the following table: 
items(item_id, item_parent)  
... and it is a self-referencing table - item_parent refers to item_id.
What SQL query would you use to SELECT all items in ...
            
        
       
    
            21
            votes
        
        
            5
            answers
        
        
            5k
            views
        
    LINQ sort a flat list based on childorder
                I am currently trying to figure out a good way to sort my elements with LINQ and C#, but I am kinda failing to do so.
For the problem let assume you have the following Table
---TempTable
ID (int)
...
            
        
       
    
            20
            votes
        
        
            7
            answers
        
        
            37k
            views
        
    Is it possible to create a recursive query in Access?
                I have a job table
Id
ParentID
jobName
jobStatus
The root ParentID is 0.
Is it possible in Access to create a query to find a root for a given job?
The database is MDB with no linked tables. The ...
            
        
       
    
            20
            votes
        
        
            2
            answers
        
        
            5k
            views
        
    Ruby Exception or Error?
                I have noticed that in the Ruby exception hierarchy, there are "errors" such as ArgumentError and there are "exceptions" such as SignalException. Is there a certain practise of naming exceptions? ...
            
        
       
    
            19
            votes
        
        
            8
            answers
        
        
            49k
            views
        
    MySQL Recursive get all child from parent
                i have this case using recursive query on Mysql to find lv 2 and lv3 child on one table...
database structure i'm using: 
id name parent
1    A    0
2    B    0
3    C    0
4    D    1
5    E    1
6  ...
            
        
       
    
            19
            votes
        
        
            1
            answer
        
        
            10k
            views
        
    Elasticsearch - using the path hierarchy tokenizer to access different level of categories
                I'm very new in Elasticsearch and have a question about the hierarchical tokenizer of a path. Here is my code example:
My mapping code:
PUT /my_index
{
  "settings": {
    "analysis": {
      "...
            
        
       
    
            19
            votes
        
        
            1
            answer
        
        
            3k
            views
        
    Consistent approach for renaming namespaces in C++
                When using nested namespaces sometimes fully qualified names end up being quite long. I know I can use namespace abc = aaa::bbb::ccc for reducing the amount of typing (it may also improve readability ...
            
        
       
    
            18
            votes
        
        
            4
            answers
        
        
            14k
            views
        
    How to find where an abstract method is implemented in Eclipse?
                I would like to find where an abstract method is implemented, in which class? Is there a link in Eclipse like call hierarchy/open declaration or something like that that shows where the method ...
            
        
       
    
            18
            votes
        
        
            3
            answers
        
        
            46k
            views
        
    MySQL - Recursing a tree structure
                I have a database table which link locations together; a location can be in a location, which can be inside another location.
location (<id>, ....)
location_parent (<location_id>, <...
            
        
       
    
            18
            votes
        
        
            3
            answers
        
        
            40k
            views
        
    How to properly bind scope between directive and controller with angularJS
                I'm trying to generate an n-level hierarchical unordered list with anugularJS, and have been able to successfully do so.  But now, I'm having scope issues between the directive and controller.  I need ...
            
        
       
    
            18
            votes
        
        
            3
            answers
        
        
            7k
            views
        
    Can I bind a WPF TreeView to a single root node?
                Say I have a binary tree, where the root of the data structure is just a tree node. For each node, the children are accessible through the Children property. Here's what I tried. The TreeRoot is a ...
            
        
       
    
            18
            votes
        
        
            2
            answers
        
        
            28k
            views
        
    Use d3 log scale instead of linear scale
                I'm trying to do a chart based on http://mbostock.github.com/d3/talk/20111116/bar-hierarchy.html, the only difference being that I'd like to use a log scale for the x-axis.
Here's my fiddle: http://...
            
        
       
    
            18
            votes
        
        
            8
            answers
        
        
            13k
            views
        
    How do you sort a tree stored using the nested set model?
                When I refer to nested set model I mean what is described here.
I need to build a new system for storing "categories" (I can't think of better word for it) in a user defined hierarchy.  Since the ...
            
        
       
    
            17
            votes
        
        
            5
            answers
        
        
            27k
            views
        
    Category Hierarchy (PHP/MySQL)
                I am trying to get my all categories and sub-categories from MySQL database in a hierarchy:
My result should be like that (just example):    
  
  Cat A
  
  Sub-Cat 1
  
  Sub_Sub_Cat 1
  ...
            
        
       
    
            17
            votes
        
        
            3
            answers
        
        
            35k
            views
        
    Flat PHP Array to Hierarchy Tree
                I have an array with the following keys
id   
parent_id
name
A sample array:
array(7) {
  [0]=>
  array(3) {
    ["id"]=>
    string(1) "4"
    ["parent_id"]=>
    string(1) "0"
    ["name"...
            
        
       
    
            17
            votes
        
        
            1
            answer
        
        
            6k
            views
        
    Convert delimited string into hierarchical JSON with JQuery
                I have an array of strings that describe the parent/child relationship by being delimited with dashes.  So, if Bob's boss was Jim and Jim's boss was Fred, Bob's entry in the array would be "Fred-Jim-...
            
        
       
    
            17
            votes
        
        
            1
            answer
        
        
            12k
            views
        
    Tree drawing orientation
                I've made a slightly modified tree using the tree layout. I needed to orient the tree right-to-left instead of the regular left-to-right orientation that's the default. What is the right and proper d3:...
            
        
       
    
            17
            votes
        
        
            5
            answers
        
        
            11k
            views
        
    Best practice for naming subclasses
                I am often in a situation where I have a concept represented by an interface or class, and then I have a series of subclasses/subinterfaces which extend it.
For example:
A  generic "DoiGraphNode&...
            
        
       
    
            17
            votes
        
        
            2
            answers
        
        
            8k
            views
        
    C++ : Multiple inheritance with polymorphism
                (pardon the noob question in advance)
I have 4 classes:
class Person {};
class Student : public Person {};
class Employee : public Person {};
class StudentEmployee : public Student, public Employee {...
            
        
       
    
            16
            votes
        
        
            6
            answers
        
        
            15k
            views
        
    Is it good practice to often use instanceof?
                The scenario. I'm writting game-related code. In that game a Player(its also a class) has a list of Item. There are other types of items that inherit from Item, for example ContainerItem, DurableItem ...
            
        
       
    
            16
            votes
        
        
            2
            answers
        
        
            5k
            views
        
    Does ruby provide a method to show the hierarchy calls?
                That's all, i want to see what are the clases that inherits a fixed class. There is a method for this in Ruby?
Aptana offers an option that shows this, but is there any method?
Thanks
            
        
       
    
            16
            votes
        
        
            3
            answers
        
        
            25k
            views
        
    how to encode this data to parent / children structure in JSON
                I am working with d3.js to visualise families of animals (organisms) (up to 4000 at a time) as a tree graph, though the data source could just as well be a directory listing, or list of namespaced ...
            
        
       
    
            15
            votes
        
        
            3
            answers
        
        
            2k
            views
        
    Clojure states within states within states
                I'd love to hear what advice the Clojure gurus here have about managing state in hierarchies. I find I'm often using {:structures {:like {:this {:with {:many 'levels}} }  }   } and if I want to track ...