Winston Gutkowski wrote:Simple answer: No.
An "if" statement in Java is equivalent to a 'if' or 'branch' statement in the lower-level language that Java has been compiled into. If you're really interested, there are probably specifications for how the JVM expects it to behave, but basically an "IF" is an"IF".
It's about the simplest computer instruction there is.
HIH
Winston
Campbell Ritchie wrote:Not sure I understand the exact problem, but have you come across Stream.collect(Collectors.partitioningBy()?
Campbell Ritchie wrote:Not sure I understand the exact problem, but have you come across Stream.collect(Collectors.partitioningBy()?
public static <T> Collector<T, ?, Map<Boolean, List<T>>> partitioningBy(Predicate<? super T> predicate) {
return partitioningBy(predicate, toList());
class DoMarvellousThingsWithTheServerList{
//instance
ServerObject serverObject;
//here come the consecutive ArrayList ItemsToCompare from another class
//and I need to separate the first ItemToCompare object with the second ItemToCompare in two different variables,
//and then a third ItemToCompare array should be compared with the second one, then the fourth with the third,
//there is an Utility class called DiffUtil that runs this comparation if I furnish two Array variables oldItem and NewItem
public void InjectFromServer(ArrayList<ServerObject> itemToCompare){
//here should happen the magic
//and every new instance should be loaded also as List in the user interface
//I thought to something like the operator %2, or to take the Hash of everyObject is coming, or to Serialize the object
// but I do not have any idea what is the most elegant, efficient way to proceed
}
}
tony narloch wrote:
Thanks so far I found really informative the book "Kotlin in Action" i won in Java ranchPete Letkeman wrote:Interesting for many reasons including, many of the Effective Java concepts have already been implemented in Kotlin.
Now/soon you can read about effective Kotlin programming see
https://leanpub.com/effectivekotlin
Pete Letkeman wrote:The same people (Jet Brains) who made Kotlin have also created Anko which is marketed as "Pleasant Android application development".
With the official release of Android Studio 3 Kotlin is baked in, however it does not appear as though Anko is. You can read about Anko on it's GitHub site https://github.com/Kotlin/anko.
From what I gather Anko can help streamline your layouts, SQL, intents, dialogs, fragments and more. There appears to be many different tutorials regarding Anko.
I was wondering:
Have you started using Anko? If you have started using Anko that is?
Jeanne Boyarsky wrote:
Giovanni Montano wrote:I will work in Dutch and I have been hired for a position where I do not have seniors.
A mentor doesn't have to be senior to you...
Pete Letkeman wrote:
As far as I know (I could be wrong) you can only compile an Objective C application for iOS using a Mac/Apple computer.
- You can create Android programs using Mac/Apple systems.
Stephan van Hulst wrote:Well, while this is really interesting stuff, I don't think you really need to know that much about it to be a good Java programmer. Every little bit helps though.