Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 5991145
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 22, 20262026-05-22T23:20:42+00:00 2026-05-22T23:20:42+00:00

I am modeling a power subsystem in Java. A simple SQLite database contains a

  • 0

I am modeling a power subsystem in Java. A simple SQLite database contains a set of Line Replaceable Units (LRUs) and the connections between them. I am writing a Power Model API to simplify queries of the data store, using DDD patterns and repositories.

I am seeking an appropriate Java collection to model the query results. There are some special cases in a LRU connection stream that have to be modeled:

  1. Initially, there’s a Power Distribution Unit (PDU) with multiple ports (<=16) that feeds power to downstream LRUs.
  2. Typical connections in a power stream involve a single source LRU where power originates and a single Sink LRU where power is drained.
  3. However, downstream there could be a single source LRU connected to multiple sink LRUs.
  4. There are no cycles in a power stream.

The inclusion of #3 above has led me to think about returning query results from the API as a tree. But the only tree I’ve found in java.util is a TreeMap key-value paired red-black tree, which doesn’t seem appropriate (or I can’t think of an appropriate abstraction for modeling power streams with it.) I’ve also been considering a LinkedHashSet, but I’m not convinced it is appropriate either. It’s not clear to me how a node in this structure would point to downstream nodes.

I’m not concerned about efficiency in time or space at this point. My API just has to work by supplying power connection information to external clients (i.e., the Presentation Tier of a Java-based Power Monitoring & Control app.) There are also no restrictions on the use of open source data types/libraries.

In general computer science parlance, what I’m really seeking is a Directed-Acyclic-Graph (DAG).

Is there an implementation of that for Java?
Am I correct that a DAG is appropriate for my scenario?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-22T23:20:43+00:00Added an answer on May 22, 2026 at 11:20 pm

    For this particular problem. I’ve decided to use a LinkedListMultimap from Guava.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

In OOP modeling, is there any distinction between a has-a relationship and a composed-of
I'm modeling a chess game on Java, and I'm having some problem. Here's what
I'm looking for a good modeling tool to use for designing java applications that
I'm modeling a database relationship in django, and I'd like to have other opinions.
Assuming you were modeling a Q&A database using MySQL, I am aware of two
This is somewhat a continuation of Database Modeling: Facebook like messages . I'm trying
I am modeling a database for use in a softball league website. I'm not
I'm having trouble modeling a particular database structure I'm working on. To be short,
We are using Power Designer for Database Modelling and whenever something is changed in
I am developing a Data Modeling Software that is implemented in Java. This application

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.