1. Project Clover database Tue Dec 20 2016 21:24:09 CET
  2. Package com.xpn.xwiki.internal.cache.rendering

File RenderingCacheConfiguration.java

 

Code metrics

0
0
0
1
56
11
0
-
-
0
-

Classes

Class Line # Actions
RenderingCacheConfiguration 32 0 - 0 0
-1.0 -
 

Contributing tests

No tests hitting this source file were found.

Source view

1    /*
2    * See the NOTICE file distributed with this work for additional
3    * information regarding copyright ownership.
4    *
5    * This is free software; you can redistribute it and/or modify it
6    * under the terms of the GNU Lesser General Public License as
7    * published by the Free Software Foundation; either version 2.1 of
8    * the License, or (at your option) any later version.
9    *
10    * This software is distributed in the hope that it will be useful,
11    * but WITHOUT ANY WARRANTY; without even the implied warranty of
12    * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13    * Lesser General Public License for more details.
14    *
15    * You should have received a copy of the GNU Lesser General Public
16    * License along with this software; if not, write to the Free
17    * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
18    * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
19    */
20    package com.xpn.xwiki.internal.cache.rendering;
21   
22    import org.xwiki.component.annotation.Role;
23    import org.xwiki.model.reference.DocumentReference;
24   
25    /**
26    * Configuration of the rendering cache.
27    *
28    * @version $Id: 500d7ccf44cb914892d9445e62e769335e9f8707 $
29    * @since 2.4M1
30    */
31    @Role
 
32    public interface RenderingCacheConfiguration
33    {
34    /**
35    * @return true if the rendering cache system is enabled in general
36    */
37    boolean isEnabled();
38   
39    /**
40    * @return the time to live for each element in the cache
41    */
42    int getDuration();
43   
44    /**
45    * @return the size of the cache
46    */
47    int getSize();
48   
49    /**
50    * Indicate if the provided document's rendering result should be cached.
51    *
52    * @param documentReference the reference of the document
53    * @return true if the document should be cached, false otherwise
54    */
55    boolean isCached(DocumentReference documentReference);
56    }