gwt

objectify query filter by list in entity contains search parameter

怎甘沉沦 提交于 2019-12-21 11:32:49
问题 in an app i have an entity that contains a list of other entities (let's say an event holding a list of assigned employees) using objectify - i need to find all the events a particular employee is assigned to. is there a basic way to filter a query if it contains the parameter - kind of the opposite of the query in ... quick pseudocode findAll(Employee employee) { ... return ofy.query(Event.class).filter("employees.contains", employee).list(); } any help would be greatly appreciated i tried

objectify query filter by list in entity contains search parameter

你离开我真会死。 提交于 2019-12-21 11:32:33
问题 in an app i have an entity that contains a list of other entities (let's say an event holding a list of assigned employees) using objectify - i need to find all the events a particular employee is assigned to. is there a basic way to filter a query if it contains the parameter - kind of the opposite of the query in ... quick pseudocode findAll(Employee employee) { ... return ofy.query(Event.class).filter("employees.contains", employee).list(); } any help would be greatly appreciated i tried

How to handle caching of GWT theme CSS files

痴心易碎 提交于 2019-12-21 11:30:15
问题 I've got an app written with Struts/Tiles/JSP that I'm adding a GWT app to. The non-GWT portion of my app handles css caching by actually writing out the css file with a version number taken from my svn repository attached, like this "styles.css?svnbuild=12345". That way I can tell the browser to cache those css files forever and when I deploy a new version all my users download it immediately. Now I'm moving on to the GWT app and I love how it uses "longmd5sum.cache.css" as the filename so I

Sizing a HorizontalPanel cell

谁说胖子不能爱 提交于 2019-12-21 09:56:13
问题 Newbie Alert: I have been furiously looking for a way to size a particular cell of a HorizontalPanel. What I am trying to do is implement a 2-cell Horizontal Panel and set the left cell to say 200px. However, I am trying to make the right cell fill the rest of the window, not its cells contents. I cannot see the wood for the trees, please help... 回答1: HorizontalPanel horizontalPanel=new HorizontalPanel(); horizontalPanel.setWidth("100%"); Widget widget1=new Widget(); Widget widget2=new Widget

Sizing a HorizontalPanel cell

岁酱吖の 提交于 2019-12-21 09:55:32
问题 Newbie Alert: I have been furiously looking for a way to size a particular cell of a HorizontalPanel. What I am trying to do is implement a 2-cell Horizontal Panel and set the left cell to say 200px. However, I am trying to make the right cell fill the rest of the window, not its cells contents. I cannot see the wood for the trees, please help... 回答1: HorizontalPanel horizontalPanel=new HorizontalPanel(); horizontalPanel.setWidth("100%"); Widget widget1=new Widget(); Widget widget2=new Widget

Why Haven't GWT- and Script#-style Frameworks Become Dominant?

霸气de小男生 提交于 2019-12-21 09:32:45
问题 With GWT, we can write code in Java and have it translated to JavaScript code. With Script#, we can write code in C# and have it translated to JavaScript code. It sounds GWT and Script# will save web developers from suffering javascript pains. Then, why these tools haven't been dominant? Why still people dedicated to write javascript code? 回答1: Multiple reasons, and which one is most important differs from developer to deverloper. Here are two: Because JavaScript is a more nice/flexible

Why Haven't GWT- and Script#-style Frameworks Become Dominant?

被刻印的时光 ゝ 提交于 2019-12-21 09:32:37
问题 With GWT, we can write code in Java and have it translated to JavaScript code. With Script#, we can write code in C# and have it translated to JavaScript code. It sounds GWT and Script# will save web developers from suffering javascript pains. Then, why these tools haven't been dominant? Why still people dedicated to write javascript code? 回答1: Multiple reasons, and which one is most important differs from developer to deverloper. Here are two: Because JavaScript is a more nice/flexible

How to genearte JSON on the client

为君一笑 提交于 2019-12-21 09:21:40
问题 In the project, I have to send complex JSON commands form the server to the client. Is it effective to generate JSONObjects ( Strings, Numbers, etc.) convert them to the string and then send them via RequestBuilder or is there a more effective method. Is it effective to convert JSON objects to string (via the .toString method on the Object) Code example: JSONObject retObject = new JSONObject(); retObject.put("NumberVar", new JSONNumber(1)); retObject.put("StringVar", new JSONString(

GWT: Putting raw HTML inside a Label

雨燕双飞 提交于 2019-12-21 08:27:08
问题 Is there a way to put raw HTML inside of a Label widget with GWT? The constructor and setText() methods automatically escape the text for HTML (so < appears as < , etc). What I need is something like: String matched = "two"; List<String> values = Arrays.asList("one", "two", "three"); StringBuilder sb = new StringBuilder(); for (String v : values){ if (v.equals(matched)){ sb.append("<b>" + v + "<b>"); } else { sb.append(v); } sb.append(", "); } Label label = new Label(); label.setRawText(sb

can I develop android applications using gwt?

大兔子大兔子 提交于 2019-12-21 07:35:12
问题 (or is there a way to convert gwt apps to android apps?) 回答1: It is not entirely correct to say that GWT is meant to create code that runs in a browser. GWT translates Java to Javascript and includes ui support and other goodies for web apps. There are a few native application wrappers that take Javascript applications and make them native for Android (or other mobile operating systems) with additional support for device access through Javascript apis. With a glue layer in between GWT and a