001 package org.gwtbootstrap3.client.ui.base;
002
003 /*
004 * #%L
005 * GwtBootstrap3
006 * %%
007 * Copyright (C) 2013 GwtBootstrap3
008 * %%
009 * Licensed under the Apache License, Version 2.0 (the "License");
010 * you may not use this file except in compliance with the License.
011 * You may obtain a copy of the License at
012 *
013 * http://www.apache.org/licenses/LICENSE-2.0
014 *
015 * Unless required by applicable law or agreed to in writing, software
016 * distributed under the License is distributed on an "AS IS" BASIS,
017 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
018 * See the License for the specific language governing permissions and
019 * limitations under the License.
020 * #L%
021 */
022
023 import org.gwtbootstrap3.client.ui.constants.Placement;
024 import org.gwtbootstrap3.client.ui.constants.Trigger;
025
026 /**
027 * @author Joshua Godi
028 */
029 public interface HasHover {
030 /**
031 * Set whether or not to animate the displaying of the hover widget
032 *
033 * @param isAnimated boolean to animate or not
034 */
035 void setIsAnimated(boolean isAnimated);
036
037 /**
038 * Get whether or not the hover widget will be animated
039 *
040 * @return boolean true = animated, false = not animated
041 */
042 boolean isAnimated();
043
044 /**
045 * Set to make the hover widget display HTML code
046 *
047 * @param isHtml boolean to render HTML code or not
048 */
049 void setIsHtml(boolean isHtml);
050
051 /**
052 * Get whether or not the hover widget will render HTML
053 *
054 * @return boolean true = render HTML, false = don't render HTML
055 */
056 boolean isHtml();
057
058 /**
059 * Sets the placement of the hover component
060 *
061 * @param placement Placement of the hover component
062 */
063 void setPlacement(Placement placement);
064
065 /**
066 * Get the Placement of the hover component
067 *
068 * @return Placement of the hover component
069 */
070 Placement getPlacement();
071
072 /**
073 * Set what will trigger the showing of the hover component
074 *
075 * @param trigger Trigger how the hover component will show
076 */
077 void setTrigger(Trigger trigger);
078
079 /**
080 * Get the hover component's trigger
081 *
082 * @return Trigger how the hover component will show
083 */
084 Trigger getTrigger();
085
086 /**
087 * Set the delay in MS that the hover component takes to display
088 *
089 * @param showDelayMs int number of MS to delay the display
090 */
091 void setShowDelayMs(int showDelayMs);
092
093 /**
094 * Get the delay in MS to show the hover component
095 *
096 * @return int delay in MS
097 */
098 int getShowDelayMs();
099
100 /**
101 * Set the delay in MS that the hover component takes to hide
102 *
103 * @param hideDelayMs int number of MS to delay the hide
104 */
105 void setHideDelayMs(int hideDelayMs);
106
107 /**
108 * Get the delay in MS to hide the hover component
109 *
110 * @return int delay in MS
111 */
112 int getHideDelayMs();
113
114 /**
115 * Sets the custom container that the hover's HTML will render in
116 *
117 * @param container String selector of where to render the hover's HTML code
118 */
119 void setContainer(String container);
120
121 /**
122 * Get where the hover will render it's HTML code
123 *
124 * @return String selector where the hover renders to
125 */
126 String getContainer();
127 }