Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 5AEA3200C33 for ; Sat, 25 Feb 2017 02:30:49 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id 597B8160B79; Sat, 25 Feb 2017 01:30:49 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id A28B3160B69 for ; Sat, 25 Feb 2017 02:30:48 +0100 (CET) Received: (qmail 16004 invoked by uid 500); 25 Feb 2017 01:30:47 -0000 Mailing-List: contact dev-help@polygene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@polygene.apache.org Delivered-To: mailing list dev@polygene.apache.org Received: (qmail 15993 invoked by uid 99); 25 Feb 2017 01:30:47 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd3-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 25 Feb 2017 01:30:47 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd3-us-west.apache.org (ASF Mail Server at spamd3-us-west.apache.org) with ESMTP id 6708118DBE5 for ; Sat, 25 Feb 2017 01:30:47 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd3-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -2.347 X-Spam-Level: X-Spam-Status: No, score=-2.347 tagged_above=-999 required=6.31 tests=[RP_MATCHES_RCVD=-2.999, SPF_NEUTRAL=0.652] autolearn=disabled Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd3-us-west.apache.org [10.40.0.10]) (amavisd-new, port 10024) with ESMTP id GzJFWky-j673 for ; Sat, 25 Feb 2017 01:30:46 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTP id 1BBF75F56F for ; Sat, 25 Feb 2017 01:30:46 +0000 (UTC) Received: from jira-lw-us.apache.org (unknown [207.244.88.139]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id 0619BE08C2 for ; Sat, 25 Feb 2017 01:30:45 +0000 (UTC) Received: from jira-lw-us.apache.org (localhost [127.0.0.1]) by jira-lw-us.apache.org (ASF Mail Server at jira-lw-us.apache.org) with ESMTP id 502D22413A for ; Sat, 25 Feb 2017 01:30:44 +0000 (UTC) Date: Sat, 25 Feb 2017 01:30:44 +0000 (UTC) From: "Niclas Hedhman (JIRA)" To: dev@polygene.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Closed] (POLYGENE-36) Java 8 Predicates to be used for Constraints? MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Sat, 25 Feb 2017 01:30:49 -0000 [ https://issues.apache.org/jira/browse/POLYGENE-36?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Niclas Hedhman closed POLYGENE-36. ---------------------------------- Resolution: Won't Fix After investigating the consequences of this, I am against this change. Just because a more abstract abstraction can be used, doesn't mean that it should be used. We prize explicit expressions over obscure generalities, and we should not start here. > Java 8 Predicates to be used for Constraints? > --------------------------------------------- > > Key: POLYGENE-36 > URL: https://issues.apache.org/jira/browse/POLYGENE-36 > Project: Polygene > Issue Type: Improvement > Reporter: Niclas Hedhman > Assignee: Niclas Hedhman > Fix For: 3.0 > > > In Java 8, the Predicate class is suitable to be used for Constraints. And I think we should leverage the versatility of this on Ver 3.0 > The difference is that the Predicate.test() method is lacking the Annotation argument, which often used to pass arguments to the constraint. But we can equally easily inject the annotation instead. > I think that that org.qi4j.api.constraint.Constraint class has no purpose, other than for compatibility reason, but I might be wrong. -- This message was sent by Atlassian JIRA (v6.3.15#6346)