org.chorem.pollen.services
Class PollenServiceFunctions

java.lang.Object
  extended by org.chorem.pollen.services.PollenServiceFunctions

public class PollenServiceFunctions
extends Object

Usefull functions for the service (and higher) layers.

Since:
1.3
Author:
tchemit

Nested Class Summary
static class PollenServiceFunctions.DateChoiceCreator
           
static class PollenServiceFunctions.ImageChoiceCreator
           
static class PollenServiceFunctions.PersonToListCreator
           
static class PollenServiceFunctions.TextChoiceCreator
           
static class PollenServiceFunctions.TopiaIdExtractor
           
static class PollenServiceFunctions.VotingListCreator
           
 
Field Summary
static com.google.common.base.Function<Choice,String> CHOICE_TO_NAME
           
static com.google.common.base.Function<ChoiceType,String> CHOICE_TYPE_TO_PROPERTY_NAME
           
 
Constructor Summary
protected PollenServiceFunctions()
           
 
Method Summary
static void fillChoiceList(List<Choice> choiceList, int max, com.google.common.base.Function<Choice,Choice> function)
           
static void fillVotingList(VotingList votingList, com.google.common.base.Function<PersonToList,PersonToList> persontoListCreator, int max)
           
static com.google.common.base.Function<Choice,Choice> newChoiceCreator(ChoiceType choiceType)
           
static PollenServiceFunctions.DateChoiceCreator newDateChoiceCreator()
           
static PollenServiceFunctions.ImageChoiceCreator newImageChoiceCreator()
           
static com.google.common.base.Function<PersonToList,PersonToList> newPersonToListCreator()
           
static com.google.common.base.Function<Result,PollResult> newResultToBeanFunction(Poll poll)
           
static PollenServiceFunctions.TextChoiceCreator newTextChoiceCreator()
           
static PollenServiceFunctions.TopiaIdExtractor newTopiaIdExtractor()
           
static com.google.common.base.Function<VotingList,VotingList> newVotingListCreator(com.google.common.base.Function<PersonToList,PersonToList> persontoListCreator)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CHOICE_TO_NAME

public static final com.google.common.base.Function<Choice,String> CHOICE_TO_NAME

CHOICE_TYPE_TO_PROPERTY_NAME

public static final com.google.common.base.Function<ChoiceType,String> CHOICE_TYPE_TO_PROPERTY_NAME
Constructor Detail

PollenServiceFunctions

protected PollenServiceFunctions()
Method Detail

fillChoiceList

public static void fillChoiceList(List<Choice> choiceList,
                                  int max,
                                  com.google.common.base.Function<Choice,Choice> function)

fillVotingList

public static void fillVotingList(VotingList votingList,
                                  com.google.common.base.Function<PersonToList,PersonToList> persontoListCreator,
                                  int max)

newTopiaIdExtractor

public static PollenServiceFunctions.TopiaIdExtractor newTopiaIdExtractor()

newTextChoiceCreator

public static PollenServiceFunctions.TextChoiceCreator newTextChoiceCreator()

newImageChoiceCreator

public static PollenServiceFunctions.ImageChoiceCreator newImageChoiceCreator()

newDateChoiceCreator

public static PollenServiceFunctions.DateChoiceCreator newDateChoiceCreator()

newChoiceCreator

public static com.google.common.base.Function<Choice,Choice> newChoiceCreator(ChoiceType choiceType)

newVotingListCreator

public static com.google.common.base.Function<VotingList,VotingList> newVotingListCreator(com.google.common.base.Function<PersonToList,PersonToList> persontoListCreator)

newPersonToListCreator

public static com.google.common.base.Function<PersonToList,PersonToList> newPersonToListCreator()

newResultToBeanFunction

public static com.google.common.base.Function<Result,PollResult> newResultToBeanFunction(Poll poll)


Copyright © 2009-2012 CodeLutin. All Rights Reserved.