
class SmartDateStaticPart extends AbstractSmartDatePart
{
    constructor(placeholder)
    {
        super(placeholder, true);
        this._cleanedValue = placeholder;
    }
    
    /**
     * @param {SmartDateCheckState} state
     * @returns {Boolean}
     */
    parse(state)
    {
        let value = state.value();
        let index = state.valueIndex();
        
        while (index < value.length && !this._isNumericSymbol(value[index])) {
            index++;
        }
        
        this._parsedValue = value.substring(state.valueIndex(), index);
        this._state = AbstractSmartDatePart.STATE_COMPLETE;

        state.setValueIndex(index);
        
        return true;
    }
}
