Home | History | Annotate | Download | only in shadows
      1 package com.xtremelabs.robolectric.shadows;
      2 
      3 import android.text.ClipboardManager;
      4 import com.xtremelabs.robolectric.internal.Implementation;
      5 import com.xtremelabs.robolectric.internal.Implements;
      6 
      7 @Implements(ClipboardManager.class)
      8 public class ShadowClipboardManager {
      9     private CharSequence text;
     10 
     11     @Implementation
     12     public void setText(CharSequence text) {
     13         this.text = text;
     14     }
     15 
     16     @Implementation
     17     public CharSequence getText() {
     18         return text;
     19     }
     20 
     21     @Implementation
     22     public boolean hasText() {
     23         return text != null && text.length() > 0;
     24     }
     25 }
     26