1 58 package org.apache.ecs.wml; 59 60 import org.apache.ecs.Element; 61 import org.apache.ecs.SinglePartElement; 62 63 69 public class Meta extends org.apache.ecs.SinglePartElement 70 { 71 75 public Meta() { 76 setBeginEndModifier('/'); 77 setElementType("meta"); 78 } 79 80 84 public Meta setCache(String time) 85 { 86 addAttribute("http-equiv", "Cache-Control"); 87 addAttribute("content", "max-age=" + time); 88 return this; 89 } 90 91 94 public Meta setExpired() 95 { 96 addAttribute("http-equiv", "Expired"); 97 addAttribute("content", "Thu, 01 Dec 1994 16:00:00 GMT"); 98 return this; 99 } 100 101 105 public Meta setName(String name, String value) 106 { 107 addAttribute("name", name); 108 addAttribute("content", value); 109 return this; 110 } 111 112 117 public Meta setHttpEquiv(String name, String value) 118 { 119 addAttribute("http-equiv", name); 120 addAttribute("content", value); 121 return this; 122 } 123 124 } 125 | Popular Tags |