Which is The best datepicker for jHipster? - datepicker

I want to use datepicker in jHipster v4.8.2 project with Angular 4. I tried this answer
but it didn't work. I would be thankful if you have an idea.

As mentioned here you can use NgbTimepicker on "Instant" (= a java.time.Instant object), which jhipster.tech recommends to be most probably used instead of a "ZonedDateTime" (see Field types), or use the PrimeNG support - here you can see a code example in detail.
You can also find my PrimeNG calendar-module implementation here - trying to get the example app from Full Stack Development with JHipster done.

Related

In SAPUI5, they provide samples for codes. How to actually use those?

I just started using SAPUI5 and I am actually curious on how the samples work.
For example:
https://sapui5.hana.ondemand.com/#/entity/sap.f.FlexibleColumnLayout/sample/sap.f.sample.FlexibleColumnLayoutColumnResize
I downloaded it and opened using Atom IDE. However, I don`t see any mock data or .json.
Is that on purpose? I was actually expecting to see the code for the sample, with the sample data.
Thank you very much.
The data gets loaded from https://sapui5.hana.ondemand.com/test-resources/sap/f/demokit/sample/FlexibleColumnLayoutColumnResize/webapp/data/sections.json
see line 21 in Component.js: var oProductsModel = new JSONModel("./data/sections.json");
You can find details on how to set up a JSON model in Step 7 of SAPUI5 Walkthrough - a tutorial with all major UI5 development paradigms.

HtmlElements and Thucydides

I want to use HtmlElements with my test-project based on Thucydides framework.
It's not clear where to start and how it can be used.
If I use it as in example in main project README, it does not populate elements without additional magic. Is there any examples or start guides?
You can find required magic in htmlelements-thucydides module. Long story short you just need to use BlockPageObject from the package above instead of PageObject provided by Thucydides. Here is a working example as well.

cachingactivitymapper usage example

We implemented a GWT app using a MVP pattern.
Now we wanted to use cachingactivitymapper in that application.
I searched on the web for how to use this. I couldnt get anything.
Can anyone please provide me the example of using cachingactivitymapper.
Thanks,
Sree
You can easily set up one example via Spring Roo ( if you dont get trippped by spring roo related errors). Reference - http://gwtsts.blogspot.in/2011/03/part-iii-exploring-roo-generated-gwt.html
Some other example GitHub projects -
https://github.com/ashtonthomas/beans
https://github.com/ashtonthomas/gwt-seminar

Unicode normalization in GWT [duplicate]

I tried
s=Normalizer.normalize(s, Normalizer.Form.NFD).replaceAll("[^\\p{ASCII}]", "");
But it seems that GWT API doesn't provide such fonction.
I tried also :
s=s.replace("é",e);
But it doesn't work either
The scenario is I'am trying to générate token from the clicked Widget's text for the history management
You can take ASCII folding filter from Lucene and add to your project. You can just take foldToASCII() method from ASCIIFoldingFilter (the method does not have any dependencies). There is also a patch in Jira that has a full class for that without any dependencies - see here. It should be compiled by GWT without any problems. License should be also OK, since it is Apache License, but don't quote me on it - you should ask a real lawyer.
#okrasz, the foldToASCII() worked but I found a shorter one Transform a String to URL standard String in Java

What is the use GWT generator?

I have seen that GWT framework is having generator feature.
In what case we have to use gwt generator option and why it is needed?
Can anyone tell me simply why,what is gwt generator? Done some googling. But not much helpful stuffs...
From this tutorial:
Generators allow the GWT coder to generate Java code at compile time and have it then be compiled along with the rest of the project into JavaScript.
This tutorial uses the example of generating a Map of values at compile time based on a properties file.
I've done GWT development for 3 years now and I've written one generator :) I've written a couple of linkers for experimental purposes so I think they are more common, though still rare. The classic case is where you want to write
X x = GWT.create(X.class)
and have the particular subclass or implementation of X constructed at compile time based on, perhaps, annotations in the provided X class or interface. GWT uses them for things like the CSSResource.
Search for "GWT Generator Experiments" site:development.lombardi.com on google for some info about what I did.
One of the use cases is to mimic reflection on the client side by building a factory class on the fly. I remember answering a question posted by you earlier on how to do this
How to create new instance from class name in gwt?
So i guess you already know the application. What else are you looking for? Can you be precise?
I've started using GWT Generators where I needed Java Reflection. I've documented One of the use cases for using GWT generators here:
http://jpereira.eu/2011/01/30/wheres-my-java-reflection/
Hope it helps.
If you refer to code generator, yes, there will a tool supporting GWT 2.1 code generation. For more details and a quick start, see http://www.springsource.org/roo/start
A general roo intro is here http://blog.springsource.com/2009/05/01/roo-part-1/
Another visual tutorial is at http://www.thescreencast.com/2010/05/how-to-gwt-roo.html
Check out this implementation:
http://samuelschmid.blogspot.com/2012/05/using-generator-for-generic-class.html
You can create new Instances of classes on client with foo.newInstance("fully.qualified.class.name");