public class

LongArrayConverter

extends Object
implements ParameterConverter
java.lang.Object
   ↳ com.atlassian.jira.webwork.parameters.LongArrayConverter

Class Overview

A implementation of ParameterConverter for Long[] objects

Introduced / changed as part of JRA-15664

Summary

Public Constructors
LongArrayConverter()
Public Methods
Object convertParameter(String[] parameterValues, Class paramType)
This is called to perform the conversion.
Protected Methods
void checkPrimitiveInput(String parameterValue, Class paramType, String bundleKey)
Throws a PropertyEditorException just like webwork1 when a value is a primitive AND the string is empty
boolean isEmpty(String parameterValue)
The same test that webwork1 uses for null-able Longs/Integers/Shorts/Bytes
[Expand]
Inherited Methods
From class java.lang.Object
From interface com.atlassian.jira.webwork.parameters.ParameterConverter

Public Constructors

public LongArrayConverter ()

Public Methods

public Object convertParameter (String[] parameterValues, Class paramType)

This is called to perform the conversion. The parameterValues will always be a String[] of length 1 or more. It can never be null.

Parameters
parameterValues a String[] that is never null and at least length 1 or more.
paramType the type of the target object
Returns
  • a converted object of the right type

Protected Methods

protected void checkPrimitiveInput (String parameterValue, Class paramType, String bundleKey)

Throws a PropertyEditorException just like webwork1 when a value is a primitive AND the string is empty

Parameters
parameterValue the value in play
paramType the type of parameter
bundleKey the webwork1 bundle key to use

protected boolean isEmpty (String parameterValue)

The same test that webwork1 uses for null-able Longs/Integers/Shorts/Bytes

Parameters
parameterValue the parameter value
Returns
  • true if its an empty string