diff options
author | Manolo Carrasco <manolo@apache.org> | 2015-01-30 14:24:11 +0100 |
---|---|---|
committer | Manolo Carrasco <manolo@apache.org> | 2015-01-30 14:24:11 +0100 |
commit | 1feb9ec1fb76507e3377377a8ccb317495e4d161 (patch) | |
tree | 10a696c929b94999900d1c6e0da2fa225266a9f1 | |
parent | c6a06834dc0ed891c1dec4ab58332abd22865ca8 (diff) | |
download | gwtquery-1feb9ec1fb76507e3377377a8ccb317495e4d161.tar.gz gwtquery-1feb9ec1fb76507e3377377a8ccb317495e4d161.zip |
Adding javadoc to new methods
-rw-r--r-- | gwtquery-core/src/main/java/com/google/gwt/query/client/plugins/ajax/Ajax.java | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/gwtquery-core/src/main/java/com/google/gwt/query/client/plugins/ajax/Ajax.java b/gwtquery-core/src/main/java/com/google/gwt/query/client/plugins/ajax/Ajax.java index 429b00eb..a9bebd48 100644 --- a/gwtquery-core/src/main/java/com/google/gwt/query/client/plugins/ajax/Ajax.java +++ b/gwtquery-core/src/main/java/com/google/gwt/query/client/plugins/ajax/Ajax.java @@ -462,6 +462,14 @@ public class Ajax extends GQuery { return this; } + /** + * Load an external resource using the link tag element. + * It is appended to the head of the document. + * + * @param rel Specifies the relationship between the current document and the linked document. + * @param url Specifies the location of the linked document + * @return a Promise which will be resolved when the external resource has been loaded. + */ public static Promise loadLink(final String rel, final String url) { GQuery link = $("link[rel='" + rel + "'][href^='" + url + "']"); if (link.isEmpty()) { @@ -487,6 +495,11 @@ public class Ajax extends GQuery { } } + /** + * Load an external html resource using the link tag element, it sets + * the relationship between the current document as 'import'. + * It is very useful to import web-components. + */ public static Promise importHtml(String url) { return loadLink("import", url); } |