Example usage for com.liferay.portal.kernel.search Summary setMaxContentLength

List of usage examples for com.liferay.portal.kernel.search Summary setMaxContentLength

Introduction

In this page you can find the example usage for com.liferay.portal.kernel.search Summary setMaxContentLength.

Prototype

public void setMaxContentLength(int maxContentLength) 

Source Link

Usage

From source file:ca.efendi.datafeeds.search.CJProductIndexer.java

License:Apache License

@Override
protected Summary doGetSummary(final Document document, final Locale locale, final String snippet,
        final PortletRequest portletRequest, final PortletResponse portletResponse) throws Exception {
    final Summary summary = createSummary(document);
    summary.setMaxContentLength(200);
    return summary;
}

From source file:com.liferay.blade.samples.modelsummarycontributor.ModelSummaryContributor.java

License:Apache License

@Override
public Summary getSummary(Document document, Locale locale, String snippet) {

    Summary summary = _createSummary(document);

    summary.setMaxContentLength(128);

    return summary;
}

From source file:com.liferay.blogs.internal.search.BlogsEntryIndexer.java

License:Open Source License

@Override
protected Summary doGetSummary(Document document, Locale locale, String snippet, PortletRequest portletRequest,
        PortletResponse portletResponse) {

    Summary summary = createSummary(document);

    summary.setMaxContentLength(200);

    return summary;
}

From source file:com.liferay.bookmarks.search.BookmarksFolderIndexer.java

License:Open Source License

@Override
protected Summary doGetSummary(Document document, Locale locale, String snippet, PortletRequest portletRequest,
        PortletResponse portletResponse) {

    Summary summary = createSummary(document, Field.TITLE, Field.DESCRIPTION);

    summary.setMaxContentLength(200);

    return summary;
}

From source file:com.liferay.calendar.search.CalendarIndexer.java

License:Open Source License

@Override
protected Summary doGetSummary(Document document, Locale locale, String snippet, PortletRequest portletRequest,
        PortletResponse portletResponse) {

    Summary summary = createSummary(document, Field.NAME, Field.DESCRIPTION);

    summary.setMaxContentLength(200);

    return summary;
}

From source file:com.liferay.calendar.util.CalendarBookingIndexer.java

License:Open Source License

@Override
protected Summary doGetSummary(Document document, Locale locale, String snippet, PortletURL portletURL,
        PortletRequest portletRequest, PortletResponse portletResponse) {

    String calendarBookingId = document.get(Field.ENTRY_CLASS_PK);

    portletURL.setParameter("mvcPath", "/view_calendar_booking.jsp");
    portletURL.setParameter("calendarBookingId", calendarBookingId);

    Summary summary = createSummary(document, Field.TITLE, Field.DESCRIPTION);

    summary.setMaxContentLength(200);
    summary.setPortletURL(portletURL);//w w  w. j av  a 2  s.c o  m

    return summary;
}

From source file:com.liferay.calendar.util.CalendarIndexer.java

License:Open Source License

@Override
protected Summary doGetSummary(Document document, Locale locale, String snippet, PortletRequest portletRequest,
        PortletResponse portletResponse) {

    String calendarId = document.get(Field.ENTRY_CLASS_PK);

    Summary summary = createSummary(document, Field.NAME, Field.DESCRIPTION);

    summary.setMaxContentLength(200);

    return summary;
}

From source file:com.liferay.configuration.admin.web.internal.search.ConfigurationModelIndexer.java

License:Open Source License

@Override
protected Summary doGetSummary(Document document, Locale locale, String snippet, PortletRequest portletRequest,
        PortletResponse portletResponse) throws Exception {

    Summary summary = createSummary(document, Field.TITLE, Field.DESCRIPTION);

    summary.setMaxContentLength(200);

    return summary;
}

From source file:com.liferay.docs.guestbook.search.GuestbookEntryModelSummaryContributor.java

License:Open Source License

@Override
public Summary getSummary(Document document, Locale locale, String snippet) {

    Summary summary = createSummary(document);

    summary.setMaxContentLength(128);

    return summary;
}

From source file:com.liferay.docs.guestbook.search.GuestbookModelSummaryContributor.java

License:Open Source License

@Override
public Summary getSummary(Document document, Locale locale, String snippet) {

    Summary summary = createSummary(document);

    summary.setMaxContentLength(200);

    return summary;
}