Class DefaultResponseMapFactory

  • All Implemented Interfaces:
    ResponseMapFactory

    public class DefaultResponseMapFactory
    extends java.lang.Object
    implements ResponseMapFactory
    Implements the contract of ResponseMapFactory with LinkedHashMap. This is the default of graphql-java since a long time and changing it could cause breaking changes.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.util.Map<java.lang.String,​java.lang.Object> createInsertionOrdered​(java.util.List<java.lang.String> keys, java.util.List<java.lang.Object> values)
      The general contract is that the resulting map keeps the insertion orders of keys.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • DefaultResponseMapFactory

        public DefaultResponseMapFactory()
    • Method Detail

      • createInsertionOrdered

        public java.util.Map<java.lang.String,​java.lang.Object> createInsertionOrdered​(java.util.List<java.lang.String> keys,
                                                                                             java.util.List<java.lang.Object> values)
        Description copied from interface: ResponseMapFactory
        The general contract is that the resulting map keeps the insertion orders of keys. Values are nullable but keys are not. Implementations are free to create or to reuse map instances.
        Specified by:
        createInsertionOrdered in interface ResponseMapFactory
        Parameters:
        keys - the keys like k1, k2, ..., kn
        values - the values like v1, v2, ..., vn
        Returns:
        a new or reused map instance with (k1,v1), (k2, v2), ... (kn, vn)