JavaFX and Scene Builder - Pig Latin Translator

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hey it's random code here and today i want to showcase little pig latin translator i created in javafx and scenebuilder so first let me just showcase on example so for example if we input paris it's gonna be translated into picolatin and it now has become a wrist pay i guess and how pick that just works simply we found to find the first vowel which in this case is a and then take everything before the first vowel which in this case is just p and moves to the back so you get a wrist p and then we add a y so we get a risk pay we can do like command and we get anime and so on but first let's have a quick look inside scene builder we just have two text fields which is our input and output ids and a button with an action call and then some simple text to showcase what is what and give an understanding of the program so first have a quick look of how the javafx is set up and then after i was going to showcase how we do the pick latin translation but this is actually very very important concept that my javafx and my playing job is separated so the pickle item translation is done in pure java and is created inside its own class and whenever we do any kind of stuff using picolate and translation we just simply create an object and use this object to translate some text so inside the controller we have our pickle and translator we have our text fields our input output and we have our own action button call translate which simply translates our text from our so we use our pixel and translator to translate to get our input.gettext translate it to picladen save it in a string called translated and we then check if translate is not equal to null and we just output the translated six inside our output field is null which means it wasn't able to translate if there was no valves just output possible let's have a look at how we actually do our pick latin translation so inside my piccolatin translator class i have two methods method checks if a character is vowel and a method that translates to big button so we first have this method which is used to do the translation where we simply check if a character is inside the string containing all the vowels vowel return true if not return false very simple and then what we do would we first take the length of the input word we then have index set to minus one and then go through each of the letters in our word check if this letter is a vowel then return the index asks this position if you do not find any vowels we're going to change the index and when we then check here if our index is still -1 we'll just return null and stop the translation but if we have found a vowel so we have an index we then simply take our top string of our word from our index to the end of the word that's how substring works so let's say we had paris before or index is going to be one it's then going to take everything from one to the end so aries plus our word substring from the beginning to the index which is going to be zero one in this case which is going to be our p take our aries add up e and then add a and that is how our pick weapon translation works relatively simple and i think there might actually be a different way of doing piccolo translation where you can actually do it if there isn't a vowel maybe i don't know but this is like the basic way of doing pick up translation and i thought it was a quite funny little quick program i can do where we need input i can't think anything it just needs to be a word and it translated into the gladden so if you enjoyed this quick showcase of my pick latin translator please leave a like and subscribe and i wish all a wonderful day
Info
Channel: Random code
Views: 40
Rating: undefined out of 5
Keywords: SoftwareEngineeringStudent, pig latin, programming, java, tutorial, software engineering, javafx, scene builder, translator, pig latin translator, pig latin translator app, pig latin translator using java, python code to pig latin translator, pig latin word in java, pig latin java program, #pig latin translator, pig latin source code java, piglatin sentence in java, pig latin javascript, pig latin word, pig latin language, latin, python pig latin tutorial, pig latin program
Id: _NyPFYnubQg
Channel Id: undefined
Length: 4min 2sec (242 seconds)
Published: Thu Dec 16 2021
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.