Example usage for com.liferay.portal.kernel.util StringPool NOT_EQUAL

List of usage examples for com.liferay.portal.kernel.util StringPool NOT_EQUAL

Introduction

In this page you can find the example usage for com.liferay.portal.kernel.util StringPool NOT_EQUAL.

Prototype

String NOT_EQUAL

To view the source code for com.liferay.portal.kernel.util StringPool NOT_EQUAL.

Click Source Link

Usage

From source file:com.liferay.tasks.service.persistence.impl.TasksEntryFinderImpl.java

License:Open Source License

protected String getAssetTagTagIds(long[] assetTagIds, boolean equalsOperator) {

    StringBundler sb = new StringBundler((assetTagIds.length * 4) + 1);

    sb.append(" (");

    for (int i = 0; i < assetTagIds.length; i++) {
        sb.append("AssetEntries_AssetTags.tagId ");

        if (equalsOperator) {
            sb.append(StringPool.EQUAL);
        } else {/*w w w  .  j  ava 2 s.c  o  m*/
            sb.append(StringPool.NOT_EQUAL);
        }

        sb.append(" ? ");

        if ((i + 1) != assetTagIds.length) {
            if (equalsOperator) {
                sb.append("OR ");
            } else {
                sb.append("AND ");
            }
        }
    }

    sb.append(StringPool.CLOSE_PARENTHESIS);

    return sb.toString();
}