Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

315
Visualizações
Sort List of Objects in Java

I have 6 list of Objects in Java with a data structure like this:

Class MyObj {
    int identifier;
    Class someOtherClass;
}

Every List in the 6 Lists is a List<MyObj>.

I want to build a final list which does merge sort while reading all the 6 lists and prepare a final list.

I believe Merge Sort or similar solution is the way to go. I looked at comparator example as well but could not find one matching my requirements. Can someone suggest a library or existing API that can help me accomplish this task?

I also found a solution at How to Sort a List<T> by a property in the object but it does inArray sort, it does not tke account of multiple Lists.

All 6 Lists are already Sorted, I need combined sorted List

over 4 years ago · Santiago Trujillo
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda