Class PersonGenderizerCommand

  • All Implemented Interfaces:
    com.optimaize.command4j.Command<org.nameapi.ontology5.input.entities.person.InputPerson,​org.nameapi.ontology5.services.genderizer.GenderizerResult>, com.optimaize.command4j.commands.CombinableCommand<org.nameapi.ontology5.input.entities.person.InputPerson,​org.nameapi.ontology5.services.genderizer.GenderizerResult>

    public class PersonGenderizerCommand
    extends NameApiBaseCommand<org.nameapi.client.services.genderizer.persongenderizer.RestPort,​org.nameapi.ontology5.input.entities.person.InputPerson,​org.nameapi.ontology5.services.genderizer.GenderizerResult>
    Attempts to detect the person's gender based on the inputs, especially the person's name.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      org.nameapi.ontology5.services.genderizer.GenderizerResult call​(com.google.common.base.Optional<org.nameapi.ontology5.input.entities.person.InputPerson> arg, com.optimaize.command4j.ExecutionContext ec)  
      protected Callable<org.nameapi.client.services.genderizer.persongenderizer.RestPort> createPort​(com.optimaize.command4j.ExecutionContext ec)  
      • Methods inherited from class com.optimaize.anythingworks.client.rest.RestBaseCommand

        createCacheKey, getHost, getPort, getPortUrlFactory, makeBaseUrl
      • Methods inherited from class com.optimaize.command4j.commands.BaseCommand

        and, andThen, concat, getName, ifNotNullOr, ifTrueOr, toString, withValue
    • Constructor Detail

      • PersonGenderizerCommand

        public PersonGenderizerCommand()
    • Method Detail

      • call

        public org.nameapi.ontology5.services.genderizer.GenderizerResult call​(@NotNull
                                                                               com.google.common.base.Optional<org.nameapi.ontology5.input.entities.person.InputPerson> arg,
                                                                               @NotNull
                                                                               com.optimaize.command4j.ExecutionContext ec)
                                                                        throws Exception
        Throws:
        Exception
      • createPort

        @NotNull
        protected Callable<org.nameapi.client.services.genderizer.persongenderizer.RestPort> createPort​(@NotNull
                                                                                                        com.optimaize.command4j.ExecutionContext ec)
        Specified by:
        createPort in class com.optimaize.anythingworks.client.rest.RestBaseCommand<org.nameapi.client.services.genderizer.persongenderizer.RestPort,​org.nameapi.ontology5.input.entities.person.InputPerson,​org.nameapi.ontology5.services.genderizer.GenderizerResult>